[PowerPC] Add support for EBB and PMU registers
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
2 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3
4 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_EBBREGSET)
5 (PPC_LINUX_SIZEOF_PMUREGSET): Declare.
6 * nat/ppc-linux.h (PPC_FEATURE2_EBB, NT_PPC_EBB, NT_PPC_PMU):
7 Define if not already defined.
8 * features/rs6000/power-ebb.xml: New file.
9 * features/rs6000/power-linux-pmu.xml: New file.
10 * features/rs6000/powerpc-isa207-vsx32l.xml: Include ebb and pmu
11 features.
12 * features/rs6000/powerpc-isa207-vsx64l.xml: Likewise.
13 * features/rs6000/powerpc-isa207-vsx32l.c: Re-generate.
14 * features/rs6000/powerpc-isa207-vsx64l.c: Re-generate.
15 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Re-generate.
16 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Re-generate.
17 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
18 fetch_regset with ebb and pmu regsets.
19 (store_register, store_ppc_registers): Call store_regset with ebb
20 and pmu regsets.
21 (ppc_linux_nat_target::read_description): Set isa207 field in the
22 features struct if ebb and pmu are avaiable.
23 * ppc-linux-tdep.c (ppc32_regmap_ebb, ppc32_regmap_pmu)
24 (ppc32_linux_ebbregset, ppc32_linux_pmuregset): New globals.
25 (ppc_linux_iterate_over_regset_sections): Call back with the ebb
26 and pmu regsets.
27 (ppc_linux_core_read_description): Check if the pmu section is
28 present and set isa207 in the features struct.
29 * ppc-linux-tdep.h (ppc32_linux_ebbregset)
30 (ppc32_linux_pmuregset): Declare.
31 * ppc-tdep.h (struct gdbarch_tdep) <ppc_mmcr0_regnum>: New field.
32 <ppc_mmcr2_regnum, ppc_siar_regnum, ppc_sdar_regnum>: New fields.
33 <ppc_sier_regnum>: New field.
34 (enum): <PPC_BESCR_REGNUM, PPC_EBBHR_REGNUM, PPC_EBBRR_REGNUM>:
35 New enum values.
36 <PPC_MMCR0_REGNUM, PPC_MMCR2_REGNUM, PPC_SIAR_REGNUM>: New enum
37 values.
38 <PPC_SDAR_REGNUM, PPC_SIER_REGNUM>: New enum values.
39 (PPC_IS_EBB_REGNUM, PPC_IS_PMU_REGNUM): Define.
40 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate the
41 ebb and pmu features.
42
43 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
44 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
45
46 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa207_vsx32l)
47 (tdesc_powerpc_isa207_vsx64l): Declare.
48 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_TARREGSET): Define.
49 (struct ppc_linux_features) <isa207>: New field.
50 (ppc_linux_no_features): Add initializer for isa207 field.
51 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
52 new tdescs.
53 * nat/ppc-linux.h (PPC_FEATURE2_ARCH_2_07, PPC_FEATURE2_TAR)
54 (NT_PPC_TAR): Define if not already defined.
55 * features/Makefile (WHICH): Add rs6000/powerpc-isa207-vsx32l and
56 rs6000/powerpc-isa207-vsx64l.
57 (XMLTOC): Add rs6000/powerpc-isa207-vsx32l.xml and
58 rs6000/powerpc-isa207-vsx64l.xml.
59 * features/rs6000/power-tar.xml: New file.
60 * features/rs6000/powerpc-isa207-vsx32l.xml: New file.
61 * features/rs6000/powerpc-isa207-vsx64l.xml: New file.
62 * features/rs6000/powerpc-isa207-vsx32l.c: Generate.
63 * features/rs6000/powerpc-isa207-vsx64l.c: Generate.
64 * regformats/rs6000/powerpc-isa207-vsx32l.dat: Generate.
65 * regformats/rs6000/powerpc-isa207-vsx64l.dat: Generate.
66 * ppc-linux-nat.c (fetch_register, fetch_ppc_registers): Call
67 fetch_regset with the TAR regset.
68 (store_register, store_ppc_registers): Call store_regset with the
69 TAR regset.
70 (ppc_linux_nat_target::read_description): Set isa207 field in the
71 features struct if needed.
72 * ppc-linux-tdep.c: Include
73 features/rs6000/powerpc-isa207-vsx32l.c and
74 features/rs6000/powerpc-isa207-vsx64l.c.
75 (ppc32_regmap_tar, ppc32_linux_tarregset): New globals.
76 (ppc_linux_iterate_over_regset_sections): Call back with the tar
77 regset.
78 (ppc_linux_core_read_description): Check if the tar section is
79 present and set isa207 in the features struct.
80 (_initialize_ppc_linux_tdep): Call
81 initialize_tdesc_powerpc_isa207_vsx32l and
82 initialize_tdesc_powerpc_isa207_vsx64l.
83 * ppc-linux-tdep.h (ppc32_linux_tarregset): Declare.
84 * ppc-tdep.h (gdbarch_tdep) <ppc_tar_regnum>: New field.
85 (enum) <PPC_TAR_REGNUM>: New enum value.
86 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate tar
87 feature.
88 (ppc_process_record_op31): Record changes to TAR.
89
90 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
91 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
92
93 * arch/ppc-linux-tdesc.h (tdesc_powerpc_isa205_ppr_dscr_vsx32l)
94 (tdesc_powerpc_isa205_ppr_dscr_vsx64l): Declare.
95 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_PPRREGSET)
96 (PPC_LINUX_SIZEOF_DSCRREGSET): Define.
97 (struct ppc_linux_features) <ppr_dscr>: New field.
98 (ppc_linux_no_features): Add initializer for ppr_dscr field.
99 * arch/ppc-linux-common.c (ppc_linux_match_description): Return
100 new tdescs.
101 * nat/ppc-linux.h (PPC_FEATURE2_DSCR, NT_PPC_PPR, NT_PPC_DSCR):
102 Define if not already defined.
103 * features/Makefile (WHICH): Add
104 rs6000/powerpc-isa205-ppr-dscr-vsx32l and
105 rs6000/powerpc-isa205-ppr-dscr-vsx64l.
106 (XMLTOC): Add rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
107 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml.
108 * features/rs6000/power-dscr.xml: New file.
109 * features/rs6000/power-ppr.xml: New file.
110 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml: New file.
111 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml: New file.
112 * features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c: Generate.
113 * features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c: Generate.
114 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx32l.dat: Generate.
115 * regformats/rs6000/powerpc-isa205-ppr-dscr-vsx64l.dat: Generate.
116 * ppc-linux-nat.c: Include <sys/uio.h>.
117 (fetch_regset, store_regset, check_regset): New functions.
118 (fetch_register, fetch_ppc_registers): Call fetch_regset with
119 DSCR and PPR regsets.
120 (store_register, store_ppc_registers): Call store_regset with
121 DSCR and PPR regsets.
122 (ppc_linux_get_hwcap2): New function.
123 (ppc_linux_nat_target::read_description): Call
124 ppc_linux_get_hwcap2 and check_regset, set ppr_dscr field in the
125 features struct if needed.
126 * ppc-linux-tdep.c: Include
127 features/rs6000/powerpc-isa205-ppr-dscr-vsx32l.c and
128 features/rs6000/powerpc-isa205-ppr-dscr-vsx64l.c.
129 (ppc32_regmap_ppr, ppc32_regmap_dscr, ppc32_linux_pprregset)
130 (ppc32_linux_dscrregset): New globals.
131 (ppc_linux_iterate_over_regset_sections): Call back with the ppr
132 and dscr regsets.
133 (ppc_linux_core_read_description): Check if the ppr and dscr
134 sections are present and set ppr_dscr in the features struct.
135 (_initialize_ppc_linux_tdep): Call
136 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx32l and
137 initialize_tdesc_powerpc_isa205_ppr_dscr_vsx64l.
138 * ppc-linux-tdep.h (ppc32_linux_pprregset)
139 (ppc32_linux_dscrregset): Declare.
140 * ppc-tdep.h (struct gdbarch_tdep) <ppc_ppr_regnum>: New field.
141 <ppc_dscr_regnum>: New field.
142 (enum) <PPC_PPR_REGNUM, PPC_DSCR_REGNUM>: New enum values.
143 * rs6000-tdep.c (rs6000_gdbarch_init): Look for and validate ppr
144 and dscr features.
145 (ppc_process_record_op31): Record changes to PPR and DSCR.
146
147 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
148
149 * rs6000-tdep.c (rs6000_gdbarch_init): Replace line wrapping by a
150 second initializer line for the have_* variables. Initialize
151 have_fpu to 0 instead of 1.
152
153 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
154
155 * arch/ppc-linux-common.c (ppc_linux_match_description):
156 Parenthesize tdesc assignements and indent them properly.
157
158 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
159
160 * ppc-linux-nat.c (fetch_register): Change if statement to else
161 if.
162 (store_register): Likewise.
163
164 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
165
166 * rs6000-tdep.c: Remove reggroups.h include.
167 (rs6000_pseudo_register_reggroup_p): Remove.
168 (rs6000_gdbarch_init): Remove call to
169 set_tdesc_pseudo_register_reggroup_p.
170
171 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
172
173 * reggroups.c (default_register_reggroup_p): Return true for
174 decfloat registers and float_reggroup.
175
176 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
177
178 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): Remove.
179 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): Replace
180 ppc_linux_collect_vrregset by regcache_collect_regset.
181
182 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
183
184 * linux-tdep.c (linux_collect_regset_section_cb): Use
185 std::vector<gdb_byte> instead of char * and malloc for buf.
186 Remove xfree.
187
188 2018-10-26 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
189
190 * xcoffread.c (read_xcoff_symtab): Pass deduced language to
191 symtab_start instead of always using language_unknown.
192
193 2018-10-26 Andrew Burgess <andrew.burgess@embecosm.com>
194
195 * riscv-tdep.c (riscv_read_misa_reg): Update comment, remove
196 READ_P parameter, catch and ignore register access errors from
197 either the old or new MISA location.
198 (riscv_has_feature): Update call to riscv_read_misa_reg.
199
200 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
201
202 * python/py-function.c (convert_values_to_python): Return
203 gdbpy_ref<>. Add header comment.
204 (fnpy_call): Adjust.
205
206 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
207
208 * python/py-cmd.c (cmdpy_completer_helper): Return gdbpy_ref<>.
209 (cmdpy_completer_handle_brkchars): Adjust.
210 (cmdpy_completer): Adjust.
211
212 2018-10-25 Andrew Burgess <andrew.burgess@embecosm.com>
213
214 * riscv-linux-nat.c (riscv_linux_nat_target::fetch_registers):
215 Pass correct regnum to raw_supply_zeroed.
216
217 2018-10-23 Hafiz Abid Qadeer <abidh@codesourcery.com>
218
219 * regcache.c (cooked_read_test): Add CSKY to the list of
220 architectures with a save_reggroup
221
222 2018-10-23 Simon Marchi <simon.marchi@polymtl.ca>
223
224 PR gdb/23368
225 * infrun.c (follow_exec): In the follow_exec_mode_new case,
226 transfer terminal state from old new new inferior.
227 * terminal.h (swap_terminal_info): New function.
228 * inflow.c (swap_terminal_info): New function.
229
230 2018-10-23 Tom Tromey <tom@tromey.com>
231
232 * record-btrace.c (get_thread_current_frame_id): Rename from
233 get_thread_current_frame. Return a frame_id.
234 (record_btrace_start_replaying): Update.
235
236 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
237
238 * riscv-tdep.c (riscv_register_name): Use the user-friendly names
239 for CSRs.
240
241 2018-10-23 Joel Brobecker <brobecker@adacore.com>
242
243 * riscv-tdep.c (riscv_gdbarch_init): Set the gdbarch's
244 have_nonsteppable_watchpoint attribute to 1.
245
246 2018-10-23 Andrew Burgess <andrew.burgess@embecosm.com>
247
248 * riscv-tdep.c (riscv_gdb_reg_names): Update comment, and all
249 register names.
250 (struct register_alias): Rename to...
251 (struct riscv_register_alias): ...this, and update comment.
252 (riscv_register_aliases): Update type, and alias names. Remove
253 CSR names from this list.
254 (riscv_register_name): Use riscv_gdb_reg_names for int and float
255 register names. Add an extra assertion.
256 (riscv_is_regnum_a_named_csr): New function.
257 (riscv_register_reggroup_p): Use riscv_is_regnum_a_named_csr.
258
259 2018-10-22 Jim Wilson <jimw@sifive.com>
260
261 * riscv-tdep.c (riscv_push_dummy_call) <in_reg>: Check for value in
262 FP reg smaller than FP reg size, and fill with -1 instead of 0.
263
264 * riscv-tdep.c (riscv_fpreg_d_type, riscv_fpreg_q_type): New.
265 (riscv_register_type): Use them.
266 (riscv_print_one_register_info): Handle union of floats same as float.
267 * riscv-tdep.h (struct gdbarch_tdep): Add riscv_fpreg_d_type and
268 riscv_fpreg_q_type fields.
269
270 2018-10-21 Simon Marchi <simon.marchi@ericsson.com>
271
272 * gdbarch.sh (gdbarch_num_cooked_regs): New.
273 * gdbarch.h: Re-generate.
274 * ax-gdb.c (gen_expr): Use gdbarch_num_cooked_regs.
275 * dwarf2-frame.c (dwarf2_frame_cache): Likewise.
276 * eval.c (evaluate_subexp_standard): Likewise.
277 * findvar.c (value_of_register): Likewise.
278 (value_of_register_lazy): Likewise.
279 (address_from_register): Likewise.
280 * frame.c (get_frame_register_bytes): Likewise.
281 * gdbarch-selftests.c (register_to_value_test): Likewise.
282 * h8300-tdep.c (h8300_register_type): Likewise.
283 * i386-tdep.c (i386_dbx_reg_to_regnum): Likewise.
284 (i386_svr4_reg_to_regnum): Likewise.
285 * infcmd.c (default_print_registers_info): Likewise.
286 (registers_info): Likewise.
287 (print_vector_info): Likewise.
288 (default_print_float_info): Likewise.
289 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Likewise.
290 * mdebugread.c (mdebug_reg_to_regnum): Likewise.
291 * mi/mi-main.c (mi_cmd_data_list_register_names): Likewise.
292 (mi_cmd_data_list_changed_registers): Likewise.
293 (mi_cmd_data_list_register_values): Likewise.
294 (mi_cmd_data_write_register_values): Likewise.
295 (mi_cmd_trace_frame_collected): Likewise.
296 * mips-tdep.c (print_gp_register_row): Likewise.
297 (mips_print_registers_info): Likewise.
298 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
299 * regcache.c (init_regcache_descr): Likewise.
300 (register_size): Likewise.
301 (register_dump::dump): Likewise.
302 (cooked_read_test): Likewise.
303 (cooked_write_test): Likewise.
304 * rs6000-tdep.c (rs6000_register_sim_regno): Likewise.
305 (rs6000_gdbarch_init): Likewise.
306 * stabsread.c (stab_reg_to_regnum): Likewise.
307 * stack.c (info_frame_command): Likewise.
308 * target-descriptions.c (tdesc_register_name): Likewise.
309 * trad-frame.c (trad_frame_alloc_saved_regs): Likewise.
310 * tui/tui-regs.c (tui_show_register_group): Likewise.
311 * user-regs.c (user_reg_map_name_to_regnum): Likewise.
312 (user_reg_map_regnum_to_name): Likewise.
313 (value_of_user_reg): Likewise.
314 (maintenance_print_user_registers): Likewise.
315 * xtensa-tdep.c (xtensa_find_register_by_name): Likewise.
316 (xtensa_register_name): Likewise.
317 (xtensa_register_type): Likewise.
318 (xtensa_reg_to_regnum): Likewise.
319 (xtensa_pseudo_register_read): Likewise.
320 (xtensa_pseudo_register_write): Likewise.
321
322 2018-10-21 Simon Marchi <simon.marchi@polymtl.ca>
323
324 * amd64-tdep.c (amd64_pseudo_register_read_value): Use
325 correctly-sized buffer with raw_read.
326 (amd64_pseudo_register_write): Use correctly-sized buffer for
327 raw_read/raw_write.
328
329 2018-10-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
330
331 * typeprint.c (_initialize_typeprint): Fix wrong prefixname arg
332 in add_prefix_cmd of set print type.
333
334 2018-10-19 Tom Tromey <tom@tromey.com>
335
336 PR tui/18388:
337 * NEWS: Mention tabset deprecation.
338 * tui/tui-win.c (tui_tab_width, internal_tab_width): New globals.
339 (update_tab_width): New function.
340 (tui_set_tab_width, tui_show_tab_width): New functions.
341 (tui_set_tab_width_command): Use update_tab_width.
342 (_initialize_tui_win): Move to end of file. Deprecate "tabset".
343 Add new "set tui tab-width" command.
344 * tui/tui-source.c (tui_set_source_content): Update.
345 * tui/tui-disasm.c (tui_set_disassem_content): Update.
346 * tui/tui-data.h (tui_default_tab_len, tui_set_default_tab_len):
347 Don't declare.
348 (tui_tab_width): Declare.
349 * tui/tui-data.c (default_tab_len, tui_default_tab_len)
350 (tui_set_default_tab_len): Remove.
351
352 2018-10-19 Tom Tromey <tom@tromey.com>
353
354 * tui/tui-io.h (key_is_start_sequence, key_is_end_sequence)
355 (key_is_backspace, tui_getc): Don't declare.
356 * tui/tui-io.c (key_is_start_sequence): Now static.
357 (key_is_end_sequence, key_is_backspace): Remove.
358 (tui_getc): Now static.
359
360 2018-10-19 Tom Tromey <tom@tromey.com>
361
362 * symfile.c (reread_symbols): Clear "static_links".
363
364 2018-10-19 Alan Hayward <alan.hayward@arm.com>
365
366 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_SIZE): New
367 define.
368 (aarch64_linux_sigframe_init): Extra boundary checks.
369
370 2018-10-19 Andreas Arnez <arnez@linux.ibm.com>
371
372 * s390-tdep.c (s390_pseudo_register_type): For v0-v15 don't yield
373 the possibly non-existent tdesc type 'vec128', but the type of raw
374 register v16 instead.
375
376 2018-10-19 Gary Benson <gbenson@redhat.com>
377
378 * cli/cli-interp.c (cli_interp::~cli_interp): New function.
379
380 2018-10-18 Sergio Durigan Junior <sergiodj@redhat.com>
381
382 PR cli/23785
383 * cli/cli-dump.c (restore_binary_file): Check if "file" is
384 NULL.
385
386 2018-10-17 Paul Koning <paul_koning@dell.com>
387
388 * charset.c (convert_between_encodings): Fix unsigned overflow.
389
390 2018-10-17 John Baldwin <jhb@FreeBSD.org>
391
392 * fbsd-nat.c (fbsd_nat_target::info_proc) Use
393 fbsd_info_proc_mappings_header and fbsd_info_proc_mappings_entry.
394 * fbsd-tdep.c (fbsd_vm_map_entry_flags): Mark static.
395 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
396 New functions.
397 (fbsd_core_info_proc_mappings): Use fbsd_info_proc_mappings_header
398 and fbsd_info_proc_mappings_header.
399 * fbsd-tdep.h (fbsd_vm_map_entry_flags): Remove.
400 (fbsd_info_proc_mappings_header, fbsd_info_proc_mappings_entry):
401 New.
402
403 2018-10-17 Joel Brobecker <brobecker@adacore.com>
404
405 * MAINTAINERS (Responsible Maintainers): Add Rainer Orth as
406 Solaris Maintainer.
407
408 2018-10-15 Tom Tromey <tom@tromey.com>
409
410 * tui/tui.c (strcat_to_buf): Remove casts.
411 * tui/tui-winsource.c (tui_show_source_line)
412 (tui_set_is_exec_point_at, tui_line_is_displayed): Remove casts.
413 * tui/tui-wingeneral.c (tui_refresh_win, box_win): Remove casts.
414 * tui/tui-windata.c (tui_first_data_item_displayed)
415 (tui_delete_data_content_windows, tui_erase_data_content)
416 (tui_display_all_data, tui_display_data_from)
417 (tui_refresh_data_win, tui_vertical_data_scroll): Remove casts.
418 * tui/tui-win.c (tui_set_win_height)
419 (make_invisible_and_set_new_height, parse_scrolling_args): Remove
420 casts.
421 * tui/tui-win.c (tui_resize_all): Remove casts.
422 (tui_scroll_backward_command, tui_set_focus)
423 (tui_set_tab_width_command): Likewise.
424 * tui/tui-source.c (tui_vertical_source_scroll): Remove cast.
425 * tui/tui-regs.c (tui_show_register_group): Remove cast.
426 * tui/tui-layout.c (tui_set_layout_by_name): Remove cast.
427 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Remove cast.
428 * tui/tui-data.c (tui_partial_win_by_name, tui_free_win_content):
429 Remove casts.
430
431 2018-10-15 Simon Marchi <simon.marchi@ericsson.com>
432
433 * MAINTAINERS (Responsible Maintainers): Add Alan Hayward as
434 AArch64/ARM maintainer.
435
436 2018-10-11 Gary Benson <gbenson@redhat.com>
437
438 * interps.h (interp::m_name): Make private and mutable.
439 * interps.c (interp::~interp): Free m_name.
440
441 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
442 Simon Marchi <simark@simark.ca>
443
444 * README (`configure' options): Add documentation for new
445 "--enable-unit-tests" option.
446 * acinclude.m4: Include "selftest.m4".
447 * configure: Regenerate.
448 * configure.ac: Use "GDB_AC_SELFTEST".
449 * maint.c (maintenance_selftest): Update message informing
450 that selftests have been disabled.
451 (maintenance_info_selftests): Likewise.
452 * selftest.m4: New file.
453
454 2018-10-10 Gary Benson <gbenson@redhat.com>
455
456 * remote.c (remote_target::remote_send_printf): Add
457 missing va_end found by Coverity.
458
459 2018-10-10 Markus Metzger <markus.t.metzger@intel.com>
460
461 * btrace.c (ftrace_update_function): Add indirect jump heuristic.
462
463 2018-10-09 Tom Tromey <tom@tromey.com>
464
465 * configure: Rebuild.
466 * sanitize.m4 (AM_GDB_UBSAN): Default to no.
467 * NEWS: Update --enable-ubsan documentation.
468
469 2018-10-09 Gary Benson <gbenson@redhat.com>
470
471 * dwarf2read.c (create_dwp_hash_table): Fix buffer overrun
472 found by Coverity.
473
474 2018-10-08 Tom Tromey <tom@tromey.com>
475
476 * riscv-fbsd-tdep.c (riscv_fbsd_sigframe_init): Remove unused
477 variable.
478 (riscv_fbsd_init_abi): Likewise.
479
480 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
481 * valops.c (value_struct_elt_for_reference): Rename local variable
482 to work around the shadowing a previous local warning.
483
484 2018-10-08 John Baldwin <jhb@FreeBSD.org>
485
486 * Makefile.in (ALLDEPFILES): Add riscv-fbsd-nat.c.
487 * NEWS: Mention new FreeBSD/riscv native configuration.
488 * configure.host: Add riscv*-*-freebsd*.
489 * configure.nat: Likewise.
490 * riscv-fbsd-nat.c: New file.
491
492 2018-10-08 John Baldwin <jhb@FreeBSD.org>
493
494 * Makefile.in (ALL_TARGET_OBS): Add riscv-fbsd-tdep.o.
495 (HFILES_NO_SRCDIR): Add riscv-fbsd-tdep.h.
496 (ALLDEPFILES): Add riscv-fbsd-tdep.c.
497 * NEWS: Mention new FreeBSD/riscv target.
498 * configure.tgt: Add riscv*-*-freebsd*.
499 * riscv-fbsd-tdep.c: New file.
500 * riscv-fbsd-tdep.h: New file.
501
502 2018-10-08 John Baldwin <jhb@FreeBSD.org>
503
504 * regcache.h (struct regcache_map_entry): Note that this type can
505 be used with traditional frame caches.
506 * trad-frame.c (trad_frame_set_reg_regmap): New.
507 * trad-frame.h (trad_frame_set_reg_regmap): New.
508
509 2018-10-08 Weimin Pan <weimin.pan@oracle.com>
510
511 PR c++/16841
512 * valops.c (get_virtual_base_offset): New function.
513 (value_struct_elt_for_reference): Use it to get virtual base offset
514 and add it in calculating class member address.
515
516 2018-10-08 John Darrington <john@darrington.wattle.id.au>
517
518 * dwarf2read.c (dwarf2_cu) <producer_is_codewarrior>: New field.
519 (check_producer): Check if the producer is codewarrior.
520 (producer_is_codewarrior): New function.
521 (lnp_state_machine::record_line): Ignore is_stmt flag for records
522 produced by codewarrior.
523 (dwarf2_cu::dwarf2_cu): Initialize producer_is_codewarrior.
524
525 2018-10-06 Tom Tromey <tom@tromey.com>
526
527 PR python/19399:
528 * python/py-inferior.c: Add "architecture" entry.
529 (infpy_architecture): New function.
530
531 2018-10-06 Tom Tromey <tom@tromey.com>
532
533 PR python/21765:
534 * python/py-symbol.c (gdbpy_initialize_symbols): Redefine
535 SYMBOL_VARIABLES_DOMAIN, SYMBOL_FUNCTIONS_DOMAIN,
536 SYMBOL_TYPES_DOMAIN. Define SYMBOL_MODULE_DOMAIN,
537 SYMBOL_COMMON_BLOCK_DOMAIN, SYMBOL_LOC_COMMON_BLOCK.
538
539 2018-10-06 Tom Tromey <tom@tromey.com>
540
541 PR build/17077:
542 * Makefile.in (OPCODES_CFLAGS): Remove "-I$(OPCODES_SRC)/..".
543 * arc-tdep.c, frv-tdep.c, lm32-tdep.c, mep-tdep.c,
544 microblaze-tdep.c, or1k-tdep.h: Use ../opcodes, not opcodes, in
545 #include.
546
547 2018-10-06 Tom Tromey <tom@tromey.com>
548
549 * python/py-breakpoint.c (bppy_get_location): Handle a
550 bp_breakpoint without a location.
551
552 2018-10-06 Tom Tromey <tom@tromey.com>
553
554 * python/lib/gdb/function/strfns.py (_MemEq, _StrLen, _StrEq)
555 (_RegEx): Reformat help text.
556 * python/lib/gdb/function/caller_is.py (CallerIs, CallerMatches)
557 (AnyCallerIs, AnyCallerMatches): Reformat help text.
558 * python/lib/gdb/function/as_string.py (_AsString): Reformat help
559 text.
560 * python/lib/gdb/command/xmethods.py (InfoXMethod)
561 (EnableXMethod, DisableXMethod): Remove help indentation.
562 Capitalize meta-syntactic variables.
563 * python/lib/gdb/command/unwinders.py (InfoUnwinder)
564 (EnableUnwinder, DisableUnwinder): Remove help indentation.
565 Capitalize meta-syntactic variables.
566 * python/lib/gdb/command/explore.py (ExploreCommand)
567 (ExploreValueCommand, ExploreTypeCommand): Reformat help text.
568 * python/lib/gdb/command/type_printers.py (InfoTypePrinter)
569 (EnableTypePrinter, DisableTypePrinter): Remove help indentation.
570 * python/lib/gdb/command/pretty_printers.py (InfoPrettyPrinter):
571 Remove help indentation.
572 (EnablePrettyPrinter, DisablePrettyPrinter): Likewise.
573 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter)
574 (DisableFrameFilter, SetFrameFilterPriority)
575 (ShowFrameFilterPriority, InfoFrameFilter): Reword help text.
576
577 2018-10-06 Tom Tromey <tom@tromey.com>
578
579 PR tui/28819:
580 * tui/tui-io.c (gdb_wgetch): New function.
581 (tui_mld_getc, tui_getc): Use it.
582
583 2018-10-05 Tom Tromey <tom@tromey.com>
584
585 * sol-thread.c (sol_thread_target::wait): Rename inner
586 "save_ptid".
587
588 2018-10-04 Tom Tromey <tom@tromey.com>
589
590 * configure: Rebuild.
591 * warning.m4 (AM_GDB_WARNINGS): Add -Wshadow=local.
592
593 2018-10-04 Tom Tromey <tom@tromey.com>
594
595 * guile/scm-frame.c (gdbscm_frame_read_var): Remove inner
596 declaration of "block".
597
598 2018-10-04 Tom Tromey <tom@tromey.com>
599
600 * common/filestuff.c (fdwalk): Remove inner declaration of
601 "result".
602
603 2018-10-04 Tom Tromey <tom@tromey.com>
604
605 * msp430-tdep.c (msp430_push_dummy_call): Rename inner
606 "structs_addr" and hoist declaration.
607
608 2018-10-04 Tom Tromey <tom@tromey.com>
609
610 * linux-tdep.c (linux_make_mappings_corefile_notes): Introduce new
611 variable "size".
612
613 2018-10-04 Tom Tromey <tom@tromey.com>
614
615 * mdebugread.c (parse_partial_symbols): Use std::string.
616
617 2018-10-04 Tom Tromey <tom@tromey.com>
618
619 * ctf.c (SET_ARRAY_FIELD): Rename "u32".
620 * p-valprint.c (pascal_val_print): Split inner "i" variable.
621 * xtensa-tdep.c (xtensa_push_dummy_call): Declare "i" in loop
622 header.
623 * xstormy16-tdep.c (xstormy16_push_dummy_call): Declare "val" in
624 more inner scope.
625 * xcoffread.c (read_xcoff_symtab): Rename inner "symbol".
626 * varobj.c (varobj_update): Rename inner "newobj",
627 "type_changed".
628 * valprint.c (generic_emit_char): Rename inner "buf".
629 * valops.c (find_overload_match): Rename inner "temp".
630 (value_struct_elt_for_reference): Declare "v" in more inner
631 scope.
632 * v850-tdep.c (v850_push_dummy_call): Rename "len".
633 * unittests/array-view-selftests.c (run_tests): Rename inner
634 "vec".
635 * tui/tui-stack.c (tui_show_frame_info): Declare "i" in loop
636 header.
637 * tracepoint.c (merge_uploaded_trace_state_variables): Declare
638 "tsv" in more inner scope.
639 (print_one_static_tracepoint_marker): Rename inner
640 "tuple_emitter".
641 * tic6x-tdep.c (tic6x_analyze_prologue): Declare "inst" lower.
642 (tic6x_push_dummy_call): Don't redeclare "addr".
643 * target-float.c: Declare "dto" lower.
644 * symtab.c (lookup_local_symbol): Rename inner "sym".
645 (find_pc_sect_line): Rename inner "pc".
646 * stack.c (print_frame): Don't redeclare "gdbarch".
647 (return_command): Rename inner "gdbarch".
648 * s390-tdep.c (s390_prologue_frame_unwind_cache): Renam inner
649 "sp".
650 * rust-lang.c (rust_internal_print_type): Declare "i" in loop
651 header.
652 * rs6000-tdep.c (ppc_process_record): Rename inner "addr".
653 * riscv-tdep.c (riscv_push_dummy_call): Declare "info" in inner
654 scope.
655 * remote.c (remote_target::update_thread_list): Don't redeclare
656 "tp".
657 (remote_target::process_initial_stop_replies): Rename inner
658 "thread".
659 (remote_target::remote_parse_stop_reply): Don't redeclare "p".
660 (remote_target::wait_as): Don't redeclare "stop_reply".
661 (remote_target::get_thread_local_address): Rename inner
662 "result".
663 (remote_target::get_tib_address): Likewise.
664
665 * regcache.c (cooked_read_test): Rename "regnum".
666 * record-btrace.c (cmd_record_btrace_start): Rename inner
667 "exception".
668 * ppc-sysv-tdep.c (ppc64_sysv_abi_return_value): Declare "i" in
669 loop header.
670 * ppc-linux-tdep.c (ppc_linux_syscall_record): Declare "i" in loop
671 header.
672 (ppu2spu_sniffer): Rename inner "buf".
673 * parse.c (operator_check_standard): Rename inner "type",
674 "objfile".
675 * p-valprint.c (pascal_val_print): Introduce new scope for
676 "low_bound", "high_bound".
677 * p-exp.y (yylex): Declare "i" in loop header.
678 * objfiles.c (objfile_relocate1): Declare "i" in loop header.
679 Lower declaration of "s".
680 * nios2-tdep.c (nios2_analyze_prologue): Declare "i" in loop
681 header.
682 (nios2_push_dummy_call): Rename "len".
683 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Rename static
684 "buf".
685 (linux_xfer_osdata_fds, linux_xfer_osdata_shm)
686 (linux_xfer_osdata_sem, linux_xfer_osdata_msg)
687 (linux_xfer_osdata_modules): Likewise.
688 * mips-tdep.c (mips_eabi_push_dummy_call): Rename outer "len".
689 (mips_n32n64_push_dummy_call, mips_o32_push_dummy_call)
690 (mips_o64_push_dummy_call): Likewise.
691 * microblaze-tdep.c (microblaze_analyze_prologue): Rename inner
692 "op".
693 * mi/mi-main.c (list_available_thread_groups): Rename inner
694 "tuple_emitter".
695 (mi_cmd_data_read_memory): Rename inner "opts".
696 * mi/mi-cmd-var.c (varobj_update_one): Rename inner
697 "tuple_emitter".
698 * mep-tdep.c (mep_analyze_prologue): Declare "rn" in loop header.
699 * mdebugread.c (parse_symbol): Rename inner "b". Declare "f" in
700 more inner scope.
701 (parse_partial_symbols): Rename inner "pst", "p", "name"
702 * main.c (captured_main_1): Rename inner "i"s.
703 * machoread.c (macho_symfile_read_all_oso): Don't redeclare
704 "oso2".
705 * linux-tdep.c (linux_info_proc): Rename inner "filename".
706 * linespec.c (linespec_lexer_lex_string): Rename inner "p".
707 * infrun.c (handle_no_resumed): Don't redeclare "thread".
708 (handle_signal_stop): Rename inner "gdbarch".
709 (handle_command): Declare "signum" in loop header.
710 * ia64-tdep.c (ia64_pseudo_register_read): Don't redeclare
711 "status".
712 (examine_prologue): Rename inner "sol" and "sof".
713 (ia64_extract_return_value): Rename inner "val". Declare another
714 "val" in a more inner scope.
715 * hppa-bsd-tdep.c (hppabsd_find_global_pointer): Declare "buf" in
716 inner scope.
717 * guile/scm-symbol.c (gdbscm_lookup_symbol): Rename inner
718 "except".
719 * findvar.c (default_read_var_value): Don't redeclare "addr".
720 * f-exp.y (yylex): Declare "i" in loop header.
721 * eval.c (evaluate_subexp_standard): Don't redeclare "type".
722 Rename inner "type", "expect_type".
723 (evaluate_subexp_for_sizeof): Rename inner "pc".
724 * elfread.c (elf_symfile_read): Rename inner "abfd".
725 * dwarf2read.c (read_debug_names_from_section): Don't redeclare
726 "bytes_read".
727 (process_psymtab_comp_unit_reader): Don't redeclare "gdbarch".
728 (add_partial_subprogram): Rename inner "lowpc" and "highpc".
729 (dwarf_decode_line_header): Rename inner "lh".
730 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Don't redeclare
731 "offset". Declare "i" in loop header.
732 (disassemble_dwarf_expression): Rename inner "addr_size".
733 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Rename
734 inner "result".
735 (dwarf_expr_context::execute_stack_op): Rename inner "offset".
736 * dwarf2-frame.c (decode_frame_entry_1): Rename inner "length"s.
737 * disasm.c (do_mixed_source_and_assembly_deprecated): Rename inner
738 "inner_list_emitter".
739 (do_mixed_source_and_assembly): Rename inner "tuple_emitter".
740 * disasm-selftests.c (print_one_insn_test): Wrap "bplen"
741 declaration in a block.
742 * csky-tdep.c (csky_analyze_prologue): Declare "offset" lower.
743 * cp-valprint.c (cp_print_value_fields): Don't redeclare
744 "obstack_final_size".
745 * cp-support.c (inspect_type): Declare "i" in loop header.
746 * compile/compile.c (compile_instance::insert_symbol_error):
747 Rename inner "e".
748 * common/agent.c (agent_run_command): Remove inner "ret"
749 declaration.
750 * coffread.c (coff_symfile_read): Rename inner "name".
751 (coff_symfile_read): Rename inner "abfd".
752 * cli/cli-utils.c (get_number_trailer): Rename inner "val".
753 * cli/cli-cmds.c (print_disassembly): Rename inner "low" and
754 "high".
755 * c-exp.y (lex_one_token): Move "len" declaration lower.
756 * breakpoint.c (create_longjmp_master_breakpoint): Don't redeclare
757 "gdbarch".
758 (create_exception_master_breakpoint): Likewise. Don't redeclare
759 "b".
760 (watch_command_1): Declare "mark" later.
761 (clear_command): Don't shadow "a" or "b".
762 (delete_command): Rename inner "b".
763 (delete_trace_command): Likewise.
764 * arm-tdep.c (thumb_process_displaced_32bit_insn): Rename inner
765 "op".
766 (arm_gdbarch_init): Remove inner "e_flags".
767 * arch/arm-get-next-pcs.c (thumb_get_next_pcs_raw): Declare
768 "offset" in inner blocks.
769
770 2018-10-04 Simon Marchi <simon.marchi@ericsson.com>
771
772 * dwarf-index-write.c (file_write): Don't write if the vector is
773 empty.
774
775 2018-10-05 Tom de Vries <tdevries@suse.de>
776
777 * python/py-progspace.c (pspy_solib_name): Fix type mismatch in
778 PyArg_ParseTuple call.
779
780 2018-10-05 Tom de Vries <tdevries@suse.de>
781
782 * python/py-record-btrace.c (recpy_bt_goto): Fix type mismatch in
783 PyArg_ParseTuple call.
784
785 2018-10-04 Joel Brobecker <brobecker@adacore.com>
786
787 * psymtab.c (recursively_search_psymtabs): Reformat parameters
788 to avoid exceeding 80 characters per line limit.
789
790 2018-10-04 Tom Tromey <tom@tromey.com>
791
792 * symfile.c (syms_from_objfile_1, finish_new_objfile)
793 (reread_symbols): Update.
794 * complaints.h (clear_complaints): Remove argument.
795 * complaints.c (enum complaint_series): Remove.
796 (series): Remove global.
797 (complaint_internal): Update.
798 (clear_complaints): Remove argument.
799
800 2018-10-04 Tom Tromey <tom@tromey.com>
801
802 * symfile.c (symbol_file_add_with_addrs): Do not print "no
803 debugging symbols" message if there is a separate debug objfile.
804
805 2018-10-04 Tom Tromey <tom@tromey.com>
806
807 PR cli/19551:
808 * symfile.c (symbol_file_add_with_addrs): Update output.
809 * psymtab.c (require_partial_symbols): Update output.
810
811 2018-10-04 Tom Tromey <tom@tromey.com>
812
813 PR cli/22234:
814 * complaints.c: Emit \n.
815
816 2018-10-04 Tom Tromey <tom@tromey.com>
817
818 * symfile.c (symbol_file_add_with_addrs, symbol_file_clear)
819 (separate_debug_file_exists, find_separate_debug_file)
820 (add_symbol_file_command, reread_symbols, allocate_symtab)
821 (allocate_compunit_symtab): Use filtered printing, not
822 unfiltered.
823 * psymtab.c (require_partial_symbols, dump_psymtab)
824 (allocate_psymtab): Use filtered printing, not unfiltered.
825
826 2018-10-04 Tom Tromey <tom@tromey.com>
827
828 * complaints.c (complaint_internal): Correctly check complaint
829 count.
830
831 2018-10-04 Tom Tromey <tom@tromey.com>
832
833 * complaints.h (struct complaints): Remove declaration.
834 * complaints.c (clear_complaints): Remove an unused variable.
835
836 2018-10-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
837
838 * MAINTAINERS (Write After Approval): Add self.
839
840 2018-10-03 Tom Tromey <tom@tromey.com>
841
842 * guile/scm-value.c (gdbscm_value_to_string): Initialize
843 "buffer_contents".
844 * coffread.c (coff_symtab_read): Initialize "newobj".
845
846 2018-10-03 Simon Marchi <simon.marchi@polymtl.ca>
847
848 * dwarf2read.c (read_func_scope): Remove struct keyword in
849 range-based for.
850
851 2018-10-03 Tom Tromey <tom@tromey.com>
852
853 * README: Mention --enable-ubsan.
854 * NEWS: Mention --enable-ubsan.
855 * acinclude.m4: Include sanitize.m4.
856 * configure: Rebuild.
857 * configure.ac: Call AM_GDB_UBSAN.
858 * sanitize.m4: New file.
859
860 2018-10-03 Tom Tromey <tom@tromey.com>
861
862 * expression.h (enum exp_opcode): Use uint8_t as base type.
863 * expprint.c (op_name): Handle invalid opcodes.
864
865 2018-10-03 Tom Tromey <tom@tromey.com>
866
867 * parse.c (prefixify_expression): Add assert.
868 (parse_exp_in_context_1): Throw exception if the expression is
869 empty.
870
871 2018-10-03 Tom Tromey <tom@tromey.com>
872
873 * dwarf2read.c (read_signed_leb128): Work in ULONGEST.
874
875 2018-10-03 Tom Tromey <tom@tromey.com>
876
877 * c-exp.y (parse_number): Work in unsigned. Remove casts.
878
879 2018-10-03 Tom Tromey <tom@tromey.com>
880
881 * dwarf2read.c (read_subrange_type): Make "negative_mask"
882 unsigned.
883
884 2018-10-03 Tom Tromey <tom@tromey.com>
885
886 * findvar.c (extract_integer): Do work in an unsigned type.
887
888 2018-10-03 Tom Tromey <tom@tromey.com>
889
890 * common/enum-flags.h (enum_flags::operator~): Add static assert.
891 * symfile-add-flags.h (enum symfile_add_flag): Use unsigned as
892 base type.
893 * objfile-flags.h (enum objfile_flag): Use unsigned as base type.
894 * gdbtypes.h (enum type_instance_flag_value): Use unsigned as base
895 type.
896 * c-lang.h (enum c_string_type_values): Use unsigned as base
897 type.
898 * btrace.h (enum btrace_thread_flag): Use unsigned as base type.
899
900 2018-10-03 Tom Tromey <tom@tromey.com>
901
902 * dwarf2-frame.h (dwarf2_frame_state_reg_info)
903 <~dwarf2_frame_state_reg_info>: Update.
904 <dwarf2_frame_state_reg_info>: Update.
905 <alloc_regs>: Add assertion. Update.
906 <reg>: Now a std::vector.
907 <num_regs>: Remove.
908 <swap>: Update.
909 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
910 (execute_cfa_program_test, dwarf2_frame_cache): Update.
911
912 2018-10-03 Tom Tromey <tom@tromey.com>
913
914 * namespace.c (add_using_directive): Don't pass NULL to memcpy.
915
916 2018-10-03 Philippe Waroquiers <philippe.waroquiers@skynet.be>
917
918 * tid-parse.c (tid_is_in_list): Fix wrong 'See' comment.
919
920 2018-10-02 Tom Tromey <tom@tromey.com>
921
922 * aarch64-linux-tdep.c (aarch64_linux_sigframe_init): Use pulongest.
923
924 2018-10-02 John Darrington <john@darrington.wattle.id.au>
925
926 * NEWS: Mention changed commands.
927 * ser-uds.c: New file.
928 * configure.ac (SER_HARDWIRE): Add ser-uds.o.
929 * configure: Regenerate.
930 * Makefile.in: Add new file.
931 * serial.c (serial_open): Check if filename is a socket
932 and lookup the appropriate interface accordingly.
933
934 2018-10-01 Alan Hayward <alan.hayward@arm.com>
935
936 * aarch64-linux-tdep.c (AARCH64_SIGCONTEXT_RESERVED_OFFSET): Add
937 define.
938 (AARCH64_EXTRA_MAGIC): Likewise.
939 (AARCH64_FPSIMD_MAGIC): Likewise.
940 (AARCH64_SVE_MAGIC): Likewise.
941 (AARCH64_EXTRA_DATAP_OFFSET): Likewise.
942 (AARCH64_FPSIMD_FPSR_OFFSET): Likewise.
943 (AARCH64_FPSIMD_FPCR_OFFSET): Likewise.
944 (AARCH64_FPSIMD_V0_OFFSET): Likewise.
945 (AARCH64_FPSIMD_VREG_SIZE): Likewise.
946 (AARCH64_SVE_CONTEXT_VL_OFFSET): Likewise.
947 (AARCH64_SVE_CONTEXT_REGS_OFFSET): Likewise.
948 (AARCH64_SVE_CONTEXT_P_REGS_OFFSET): Likewise.
949 (AARCH64_SVE_CONTEXT_FFR_OFFSET): Likewise.
950 (AARCH64_SVE_CONTEXT_SIZE): Likewise.
951 (read_aarch64_ctx): Add function.
952 (aarch64_linux_sigframe_init): Detect FP registers.
953
954 2018-10-01 Alan Hayward <alan.hayward@arm.com>
955
956 * aarch64-tdep.c (AARCH64_Q0_REGNUM): Move to here.
957 (AARCH64_D0_REGNUM): Likewise.
958 (AARCH64_S0_REGNUM): Likewise.
959 (AARCH64_H0_REGNUM): Likewise.
960 (AARCH64_B0_REGNUM): Likewise.
961 (AARCH64_SVE_V0_REGNUM): Likewise.
962 * arch/aarch64.h (AARCH64_Q0_REGNUM): Move from here.
963 (AARCH64_D0_REGNUM): Likewise.
964 (AARCH64_S0_REGNUM): Likewise.
965 (AARCH64_H0_REGNUM): Likewise.
966 (AARCH64_B0_REGNUM): Likewise.
967 (AARCH64_SVE_V0_REGNUM): Likewise.
968
969 2018-10-01 Gary Benson <gbenson@redhat.com>
970
971 * gdb_proc_service.h (gdb_prfpregset_t): Remove typedef.
972 * proc-service.c (ps_lgetfpregs, ps_lsetfpregs): Use
973 prfpregset_t instead of gdb_prfpregset_t.
974 * configure.ac (PRFPREGSET_T_BROKEN): Remove check.
975 * configure, config.in: Rebuild.
976
977 2018-10-01 Gary Benson <gbenson@redhat.com>
978
979 * common/gdb_proc_service.h: New file, factored out from...
980 * gdb_proc_service.h: Moved common code to the above file.
981 * Makefile.in (HFILES_NO_SRCDIR): Add the above new file.
982
983 2018-10-01 Gary Benson <gbenson@redhat.com>
984
985 * gdb_proc_service.h: Use elf_gregset_t if prgregset_t is
986 undefined. Use elf_fpregset_t if prfpregset_t is undefined.
987
988 2018-10-01 Gary Benson <gbenson@redhat.com>
989
990 * configure.ac: Check if sys/procfs.h defines elf_fpregset_t.
991 (AC_CHECK_HEADERS): Check for linux/elf.h.
992 * configure, config.in: Rebuild.
993 * gdb_proc_service.h: Include linux/elf.h if sys/procfs.h
994 doesn't define elf_fpregset_t.
995
996 2018-10-01 Gary Benson <gbenson@redhat.com>
997
998 * gdb_proc_service.h: Whitespace change.
999
1000 2018-10-01 Tom Tromey <tom@tromey.com>
1001
1002 * unittests/scoped_mmap-selftests.c: Don't check HAVE_UNISTD_H.
1003 * unittests/scoped_fd-selftests.c: Don't check HAVE_UNISTD_H.
1004 * common/scoped_fd.h: Don't check HAVE_UNISTD_H.
1005
1006 2018-10-01 Tom Tromey <tom@tromey.com>
1007
1008 * README: Minor change.
1009
1010 2018-09-30 Pedro Alves <palves@redhat.com>
1011
1012 * darwin-nat-info.c (darwin_debug_regions_recurse)
1013 (info_mach_exceptions_command): Remove unused local variables.
1014 * darwin-nat.c (darwin_decode_notify_message)
1015 (darwin_nat_target::resume, darwin_nat_target::mourn_inferior)
1016 (darwin_stop_inferior, darwin_setup_exceptions)
1017 (darwin_nat_target::kill, darwin_attach_pid, darwin_ptrace_him)
1018 (darwin_nat_target::attach, darwin_nat_target::detach)
1019 (darwin_read_write_inferior, darwin_read_dyld_info): Remove unused
1020 local variables.
1021 * i386-darwin-nat.c (i386_darwin_dr_set): Remove unused local
1022 variables.
1023
1024 2018-09-29 Tom Tromey <tom@tromey.com>
1025
1026 * README: Remove some leftover text.
1027
1028 2018-09-29 Tom Tromey <tom@tromey.com>
1029
1030 * PROBLEMS: Rewrite.
1031 * README: Update.
1032
1033 2018-09-28 John Baldwin <jhb@FreeBSD.org>
1034
1035 * disasm-selftests.c (print_one_insn_test): Add bfd_arch_riscv to
1036 case with explicit breakpoint kind.
1037 * riscv-tdep.c (show_use_compressed_breakpoints): Remove
1038 'additional_info' and related logic.
1039 (riscv_debug_breakpoints): New variable.
1040 (riscv_breakpoint_kind_from_pc): Use the length of the existing
1041 instruction to determine the breakpoint kind.
1042 (_initialize_riscv_tdep): Add 'set/show debug riscv breakpoints'
1043 flag. Update description of 'set/show riscv
1044 use-compressed-breakpoints' flag.
1045
1046 2018-09-28 Andrew Burgess <andrew.burgess@embecosm.com>
1047
1048 (NEWS): Mention changes to frame related commands.
1049 * cli/cli-decode.c (add_cmd_suppress_notification): New function.
1050 (add_prefix_cmd_suppress_notification): New function.
1051 (add_com_suppress_notification): Call
1052 add_cmd_suppress_notification.
1053 * command.h (add_cmd_suppress_notification): Declare.
1054 (add_prefix_cmd_suppress_notification): Declare.
1055 * mi/mi-cmd-stack.c: Add 'safe-ctype.h' include.
1056 (parse_frame_specification): Moved from stack.c, with
1057 simplification to handle a single argument.
1058 (mi_cmd_stack_select_frame): Use parse_frame_specification, the
1059 switch to the selected frame. Add a header comment.
1060 * stack.c: Remove 'safe-ctype.h' include.
1061 (find_frame_for_function): Add declaration.
1062 (find_frame_for_address): New function.
1063 (parse_frame_specification): Moved into mi/mi-cmd-stack.c.
1064 (frame_selection_by_function_completer): New function.
1065 (info_frame_command): Rename to...
1066 (info_frame_command_core): ...this, and update parameter types.
1067 (select_frame_command): Rename to...
1068 (select_frame_command_core): ...this, and update parameter types.
1069 (frame_command): Rename to...
1070 (frame_command_core): ...this, and update parameter types.
1071 (class frame_command_helper): New class to wrap implementations of
1072 frame related sub-commands.
1073 (frame_apply_cmd_list): New static global.
1074 (frame_cmd_list): Make static.
1075 (select_frame_cmd_list): New global for sub-commands.
1076 (info_frame_cmd_list): New global for sub-commands.
1077 (_initialize_stack): Register sub-commands for 'frame',
1078 'select-frame', and 'info frame'. Update 'frame apply' commands
1079 to use frame_apply_cmd_list. Move function local static
1080 frame_apply_list to file static frame_apply_cmd_list for
1081 consistency.
1082 * stack.h (select_frame_command): Delete declarationn.
1083 (select_frame_for_mi): Declare new function.
1084
1085 2018-09-26 Andrew Burgess <andrew.burgess@embecosm.com>
1086
1087 * riscv-tdep.c (riscv_insn::decode): Decode c.lui.
1088 (riscv_scan_prologue): Split handling of AUIPC, LUI, ADD, ADDI,
1089 and NOP.
1090
1091 2018-09-26 Simon Marchi <simon.marchi@ericsson.com>
1092
1093 * elf32-nds32.c (elf32_nds32_allocate_dynrelocs): Remove.
1094
1095 2018-09-26 Tom Tromey <tom@tromey.com>
1096
1097 * valops.c (auto_abandon): Remove dead code.
1098
1099 2018-09-26 Tom Tromey <tom@tromey.com>
1100
1101 * tui/tui-win.c (WIN_HEIGHT_USAGE): Remove extra ">"s.
1102
1103 2018-09-24 Tom Tromey <tom@tromey.com>
1104
1105 * common/pathstuff.c (get_standard_cache_dir): Make
1106 "xdg_cache_home" and "home" const.
1107 * top.c (init_history): Make "tmpenv" const.
1108 * main.c (get_init_files): Make "homedir" const.
1109
1110 2018-09-23 Tom Tromey <tom@tromey.com>
1111
1112 PR python/18852:
1113 * python/py-param.c (get_set_value): Use gdbpy_handle_exception.
1114
1115 2018-09-23 Tom Tromey <tom@tromey.com>
1116
1117 * python/py-function.c (fnpy_call): Use gdbpy_handle_exception.
1118 * python/py-cmd.c (cmdpy_function): Use gdbpy_handle_exception.
1119 * python/python-internal.h (gdbpy_handle_exception): Declare.
1120 * python/py-utils.c (gdbpy_handle_exception): New function.
1121
1122 2018-09-23 Tom Tromey <tom@tromey.com>
1123
1124 PR python/17284:
1125 * python/py-type.c (typy_template_argument): Check for negative
1126 argument number.
1127
1128 2018-09-23 Tom Tromey <tom@tromey.com>
1129
1130 PR python/14062:
1131 * python/python.c (gdbpy_run_events): Do not ignore exceptions.
1132
1133 2018-09-23 Tom Tromey <tom@tromey.com>
1134
1135 PR python/18170:
1136 * python/py-value.c (valpy_int): Allow conversion from pointer
1137 type.
1138
1139 2018-09-23 Tom Tromey <tom@tromey.com>
1140
1141 PR python/20126:
1142 * python/py-value.c (valpy_int): Respect type sign.
1143
1144 2018-09-23 Tom Tromey <tom@tromey.com>
1145
1146 PR python/18352;
1147 * python/py-value.c (valpy_float): Allow conversions from int or
1148 char.
1149 (valpy_int, valpy_long): Allow conversions from float.
1150
1151 2018-09-23 Tom Tromey <tom@tromey.com>
1152
1153 * ctf.c (ctf_start): Use gdb_fopen_cloexec.
1154 * common/scoped_mmap.c (mmap_file): Use gdb_open_cloexec.
1155
1156 2018-09-23 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1157
1158 * amd64-sol2-tdep.c (amd64_sol2_sigtramp_p): Also recognize
1159 __sighndlr.
1160 * i386-sol2-tdep.c (i386_sol2_sigtramp_p): Likewise.
1161
1162 2018-08-02 Jon Turney <jon.turney@dronecode.org.uk>
1163
1164 * windows-nat.c (windows_nat_target::wait): Remove a spurious
1165 target_terminal::ours().
1166
1167 2018-09-23 Simon Marchi <simon.marchi@ericsson.com>
1168
1169 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): Change type
1170 of vl to ULONGEST.
1171
1172 2018-09-21 Yacov Simhony <ysimhony@gmail.com>
1173
1174 * breakpoint.c (update_inserted_breakpoint_locations): Remove
1175 redundant condition.
1176
1177 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1178
1179 * proc-utils.h (PROC_CTL_WORD_TYPE): Remove.
1180
1181 * procfs.c: Don't check for PR_MODEL_NATIVE definition.
1182 * sparc-sol2-nat.c: Likewise. Remove Linux, __arch64__ references.
1183 * sol-thread.c (ps_pdmodel): Don't guard definition.
1184
1185 * procfs.c: Fix formatting.
1186
1187 * procfs.c (sysset_t_alloc): Remove.
1188 (create_procinfo): Use XNEW instead of sysset_t_alloc.
1189 (procfs_debug_inferior): Likewise.
1190 (procfs_set_exec_trap): Likewise.
1191 (proc_set_traced_sysentry): Don't allocate argp dynamically.
1192 (proc_set_traced_sysexit): Likewise.
1193
1194 * procfs.c (create_procinfo): Use xsnprintf to fix ARI warning.
1195 (dead_procinfo): Likewise.
1196 (proc_warn): Likewise.
1197 (proc_error): Likewise.
1198 (proc_get_LDT_entry): Likewise.
1199 (do_attach): Likewise.
1200 (procfs_target::pid_to_str): Likewise.
1201 (iterate_over_mappings): Likewise.
1202
1203 * procfs.c (create_procinfo): Fix ARI warning.
1204 (proc_get_status): Likewise.
1205 (proc_stop_process): Likewise.
1206 (proc_run_process): Likewise.
1207 (proc_kill): Likewise.
1208 (proc_get_LDT_entry): Likewise.
1209 (procfs_find_LDT_entry): Likewise.
1210 (proc_update_threads): Likewise.
1211 (proc_iterate_over_threads): Likewise.
1212 (do_attach): Likewise.
1213 (procfs_xfer_memory): Likewise.
1214 (invalidate_cache): Likewise.
1215 (procfs_target::resume): Likewise.
1216 (procfs_init_inferior): Likewise.
1217 (procfs_set_exec_trap): Likewise.
1218 (procfs_target::thread_alive): Likewise.
1219 (procfs_target::pid_to_exec_file): Likewise.
1220 (iterate_over_mappings): Likewise.
1221 (procfs_target::make_corefile_notes): Likewise.
1222 * sol-thread.c (sol_thread_target::thread_alive): Likewise.
1223
1224 * procfs.c (procfs_find_LDT_entry): Silence ARI warning.
1225 (procfs_find_LDT_entry): Likewise.
1226 * sol-thread.c (ps_lgetLDT): Likewise.
1227
1228 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1229
1230 PR tdep/17903
1231 * procfs.c (procfs_target): Declare pid_to_exec_file.
1232 (procfs_target::pid_to_exec_file): New.
1233
1234 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1235
1236 * auxv.c (default_print_auxv_entry): Reflect AT_SUN_CAP_HW1
1237 renaming.
1238 Handle AT_SUN_EMULATOR, AT_SUN_BRANDNAME, AT_SUN_BRAND_AUX1,
1239 AT_SUN_BRAND_AUX2, AT_SUN_BRAND_AUX3, AT_SUN_CAP_HW2.
1240
1241 2018-09-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1242
1243 * i386-v4-nat.c (regmap, supply_gregset, fill_gregset)
1244 (supply_fpregset, fill_fpregset): Move ...
1245 * i386-sol2-nat.c [PR_MODEL_NATIVE != PR_MODEL_LP64]: ... here.
1246 Remove HAVE_GREGSET_T, HAVE_FPREGET_T guards.
1247 Remove references to ioctl-based procfs.
1248 Include <sys/reg.h>.
1249 Remove PR_MODEL_NATIVE guards.
1250 * configure.nat <sol2, i386> (NATDEPFILES): Remove i386-v4-nat.o.
1251 * Makefile.in (ALLDEPFILES): Remove i386-v4-nat.c.
1252
1253 2018-09-19 Xavier Roirand <roirand@adacore.com>
1254
1255 PR gdb/20981:
1256 * solib-darwin.c (darwin_get_dyld_bfd): New function.
1257 (darwin_solib_get_all_image_info_addr_at_init): Update call.
1258 (darwin_solib_create_inferior_hook): Handle unrelocated dyld.
1259
1260 2018-09-19 John Baldwin <jhb@FreeBSD.org>
1261
1262 * fbsd-tdep.c (fbsd_print_sockaddr_in): Style fix.
1263 (fbsd_print_sockaddr_in6): Likewise.
1264
1265 2018-09-19 Richard Bunt <richard.bunt@arm.com>
1266 Chris January <chris.january@arm.com>
1267
1268 * eval.c (skip_undetermined_arglist): Skip argument list helper.
1269 (evaluate_subexp_standard): Return a dummy type when
1270 honoring EVAL_SKIP in OP_VAR_VALUE and handle skipping in the
1271 OP_F77_UNDETERMINED_ARGLIST case.
1272 * expression.h (enum noside): Update comment.
1273
1274 2018-09-19 George Vasick <george.vasick@oracle.com>
1275
1276 * solib-svr4.c (svr4_same_1): Also handle amd64 ld.so.1.
1277
1278 2018-09-19 Stefan Teleman <stefan.teleman@oracle.com>
1279 April Chin <april.chin@oracle.com>
1280 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1281
1282 * procfs.c (MAX_PROC_NAME_SIZE): Allow for 6-digit PID_MAX and
1283 uint_t lwpid_t.
1284 (create_procinfo): Print pids in /proc without leading zeros.
1285
1286 2018-09-18 Sandra Loosemore <sandra@codesourcery.com>
1287
1288 * nios2-tdep.c (nios2_gcc_target_options): New.
1289 (nios2_gdb_arch_init): Install new hook.
1290
1291 2018-09-18 Simon Marchi <simon.marchi@ericsson.com>
1292
1293 * patches/0001-Fix-PR-gdb-23558-Use-system-s-getcwd-when-cross-comp.patch:
1294 New file.
1295 * update-gnulib.sh: Apply patch.
1296 * configure: Re-generate.
1297
1298 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1299
1300 * infcmd.c (_initialize_infcmd): Remove "running" from "info proc"
1301 description. Make "info proc" command descriptions more
1302 consistent.
1303
1304 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1305
1306 * NEWS: Mention 'info proc files' command.
1307
1308 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1309
1310 * fbsd-nat.c (fbsd_nat_target::info_proc): List open file
1311 descriptors for IP_FILES and IP_ALL.
1312
1313 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1314
1315 * fbsd-tdep.c (KF_FLAGS, KF_OFFSET, KF_VNODE_TYPE, KF_SOCK_DOMAIN)
1316 (KF_SOCK_TYPE, KF_SOCK_PROTOCOL, KF_SA_LOCAL, KF_SA_PEER)
1317 (KINFO_FILE_TYPE_SOCKET, KINFO_FILE_TYPE_PIPE)
1318 (KINFO_FILE_TYPE_FIFO, KINFO_FILE_TYPE_KQUEUE)
1319 (KINFO_FILE_TYPE_CRYPTO, KINFO_FILE_TYPE_MQUEUE)
1320 (KINFO_FILE_TYPE_SHM, KINFO_FILE_TYPE_SEM, KINFO_FILE_TYPE_PTS)
1321 (KINFO_FILE_TYPE_PROCDESC, KINFO_FILE_FD_TYPE_ROOT)
1322 (KINFO_FILE_FD_TYPE_JAIL, KINFO_FILE_FD_TYPE_TRACE)
1323 (KINFO_FILE_FD_TYPE_CTTY, KINFO_FILE_FLAG_READ)
1324 (KINFO_FILE_FLAG_WRITE, KINFO_FILE_FLAG_APPEND)
1325 (KINFO_FILE_FLAG_ASYNC, KINFO_FILE_FLAG_FSYNC)
1326 (KINFO_FILE_FLAG_NONBLOCK, KINFO_FILE_FLAG_DIRECT)
1327 (KINFO_FILE_FLAG_HASLOCK, KINFO_FILE_FLAG_EXEC)
1328 (KINFO_FILE_VTYPE_VREG, KINFO_FILE_VTYPE_VDIR)
1329 (KINFO_FILE_VTYPE_VCHR, KINFO_FILE_VTYPE_VLNK)
1330 (KINFO_FILE_VTYPE_VSOCK, KINFO_FILE_VTYPE_VFIFO, FBSD_AF_UNIX)
1331 (FBSD_AF_INET, FBSD_AF_INET6, FBSD_SOCK_STREAM, FBSD_SOCK_DGRAM)
1332 (FBSD_SOCK_SEQPACKET, FBSD_IPPROTO_ICMP, FBSD_IPPROTO_TCP)
1333 (FBSD_IPPROTO_UDP, FBSD_IPPROTO_SCTP): New defines.
1334 (struct fbsd_sockaddr_in, struct fbsd_sockaddr_in6)
1335 (struct fbsd_sockaddr_un): New types.
1336 (fbsd_file_fd, fbsd_file_type, fbsd_file_flags, fbsd_ipproto)
1337 (fbsd_print_sockaddr_in, fbsd_print_sockaddr_in6)
1338 (fbsd_info_proc_files_header, fbsd_info_proc_files_entry)
1339 (fbsd_core_info_proc_files): New functions.
1340 (fbsd_core_info_proc): List open file descriptors for IP_FILES and
1341 IP_ALL.
1342 * fbsd-tdep.h (fbsd_info_proc_files_header)
1343 (fbsd_info_proc_files_entry): New.
1344
1345 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1346
1347 * defs.h (enum info_proc_what) [IP_FILES]: New value.
1348 * infcmd.c (info_proc_cmd_files): New function.
1349 (_initialize_infcmd): Register 'info proc files' command.
1350
1351 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1352
1353 * gnulib/aclocal-m4-deps.mk: Re-generate.
1354 * gnulib/aclocal.m4: Re-generate.
1355 * gnulib/config.in: Re-generate.
1356 * gnulib/configure: Re-generate.
1357 * gnulib/import/Makefile.am: Re-generate.
1358 * gnulib/import/Makefile.in: Re-generate.
1359 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
1360 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
1361 * gnulib/import/arpa_inet.in.h: New file.
1362 * gnulib/import/inet_ntop.c: New file.
1363 * gnulib/import/m4/arpa_inet_h.m4: New file.
1364 * gnulib/import/m4/inet_ntop.m4: New file.
1365 * gnulib/import/m4/netinet_in_h.m4: New file.
1366 * gnulib/import/m4/socklen.m4: New file.
1367 * gnulib/import/m4/sockpfaf.m4: New file.
1368 * gnulib/import/m4/stdalign.m4: New file.
1369 * gnulib/import/m4/sys_uio_h.m4: New file.
1370 * gnulib/import/netinet_in.in.h: New file.
1371 * gnulib/import/stdalign.in.h: New file.
1372 * gnulib/import/sys_socket.c: New file.
1373 * gnulib/import/sys_socket.in.h: New file.
1374 * gnulib/import/sys_uio.in.h: New file.
1375 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add inet_ntop
1376 module.
1377
1378 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1379
1380 * gnulib/aclocal-m4-deps.mk: New file.
1381 * gnulib/update-gnulib.sh: Generate "aclocal-m4-deps.mk"
1382 deterministically.
1383
1384 2018-09-18 John Baldwin <jhb@FreeBSD.org>
1385
1386 * fbsd-tdep.c (fbsd_core_vnode_path): Use KF_PATH instead of
1387 KVE_PATH.
1388
1389 2018-09-18 Tom Tromey <tom@tromey.com>
1390
1391 * compile/compile-object-load.c (struct
1392 link_hash_table_cleanup_data): Add constructor and destructor.
1393 Use DISABLE_COPY_AND_ASSIGN.
1394 (~link_hash_table_cleanup_data): Rename from
1395 link_hash_table_free. Now a destructor.
1396 (copy_sections): Use gdb::unique_xmalloc_ptr. Remove cleanups.
1397
1398 2018-09-18 Tom Tromey <tom@tromey.com>
1399
1400 * compile/compile-object-run.c (do_module_cleanup): Use delete.
1401 * compile/compile-object-load.c (struct munmap_list): Move to
1402 header file.
1403 (munmap_list::add): Rename from munmap_list_add; rewrite.
1404 (munmap_list::~munmap_list): Rename from munmap_list_free.
1405 (munmap_listp_free_cleanup): Remove.
1406 (compile_object_load): Update.
1407 * compile/compile-object-load.h (struct munmap_list): Move from
1408 compile-object-load.c. Rewrite.
1409
1410 2018-09-18 Alan Hayward <alan.hayward@arm.com>
1411
1412 * aarch64-tdep.c (pass_in_v): Use register size.
1413 (aarch64_extract_return_value): Likewise.
1414 (aarch64_store_return_value): Likewise.
1415
1416 2018-09-18 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1417
1418 * utils.c (dump_core) [HAVE_SETRLIMIT]: Cast RLIM_INFINITY to
1419 rlim_t.
1420
1421 2018-09-17 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1422
1423 * python/lib/gdb/command/frame_filters.py (EnableFrameFilter):
1424 Fix short help line.
1425
1426 2018-09-17 Tom Tromey <tom@tromey.com>
1427
1428 PR python/20445:
1429 * configure: Rebuild.
1430 * configure.ac: Conditionally use -DNDEBUG for Python.
1431
1432 2018-09-17 Tom Tromey <tom@tromey.com>
1433
1434 * configure: Rebuild.
1435 * configure.ac: Use gmp as a library dependency when checking for
1436 mpfr.
1437
1438 2018-09-17 Pedro Alves <palves@redhat.com>
1439
1440 * python/py-inferior.c (find_inferior_object): Delete.
1441
1442 2018-09-17 Simon Marchi <simon.marchi@ericsson.com>
1443
1444 * compile/compile-cplus-types.c
1445 (compile_cplus_instance::enter_scope): Don't use new_scope after
1446 std::move.
1447
1448 2018-09-17 Tom Tromey <tom@tromey.com>
1449
1450 * common/pathstuff.c (get_standard_cache_dir): Use
1451 ~/Library/Caches on macOS.
1452 * common/pathstuff.h (get_standard_cache_dir): Update comment.
1453
1454 2018-09-17 Simon Marchi <simon.marchi@polymtl.ca>
1455
1456 PR python/23669
1457 * breakpoint.c (commands_cmd_element): New.
1458 (_initialize_breakpoint): Assign commands_cmd_element.
1459 * breakpoint.h (commands_cmd_element): New.
1460 * cli/cli-script.c (while_cmd_element, if_command,
1461 define_cmd_element): New.
1462 (command_name_equals): Remove.
1463 (process_next_line): Compare commands by pointer, not by name.
1464 (_initialize_cli_script): Assign the various cmd_list_element
1465 variables.
1466 * compile/compile.c (compile_cmd_element): New.
1467 (_initialize_compile): Assign compile_cmd_element.
1468 * compile/compile.h (compile_cmd_element): New.
1469 * guile/guile.c (guile_cmd_element): New.
1470 (install_gdb_commands): Assign guile_cmd_element.
1471 * guile/guile.h (guile_cmd_element): New.
1472 * python/python.c (python_cmd_element): New.
1473 (_initialize_python): Assign python_cmd_element.
1474 * python/python.h (python_cmd_element): New.
1475 * tracepoint.c (while_stepping_cmd_element): New.
1476 (_initialize_tracepoint): Assign while_stepping_cmd_element.
1477 * tracepoint.h (while_stepping_cmd_element): New.
1478
1479 2018-09-17 Tom Tromey <tom@tromey.com>
1480
1481 * infrun.c (save_infcall_suspend_state): Return
1482 infcall_suspend_state_up.
1483 (save_infcall_control_state): Return infcall_control_state_up.
1484 * inferior.h (save_infcall_suspend_state)
1485 (save_infcall_control_state): Declare later. Return unique
1486 pointers.
1487
1488 2018-09-17 Tom Tromey <tom@tromey.com>
1489
1490 * infrun.c (struct stop_context): Declare constructor,
1491 destructor, "changed" method.
1492 (stop_context::stop_context): Rename from save_stop_context.
1493 (stop_context::~stop_context): Rename from
1494 release_stop_context_cleanup.
1495 (normal_stop): Update.
1496 (stop_context::changed): Rename from stop_context_changed. Return
1497 bool.
1498
1499 2018-09-17 Tom Tromey <tom@tromey.com>
1500
1501 * inferior.h (struct infcall_suspend_state_deleter): New.
1502 (infcall_suspend_state_up): New typedef.
1503 (struct infcall_control_state_deleter): New.
1504 (infcall_control_state_up): New typedef.
1505 (make_cleanup_restore_infcall_suspend_state)
1506 (make_cleanup_restore_infcall_control_state): Don't declare.
1507 * infcall.c (call_function_by_hand_dummy): Update.
1508 * infrun.c (do_restore_infcall_suspend_state_cleanup)
1509 (make_cleanup_restore_infcall_suspend_state): Remove.
1510 (do_restore_infcall_control_state_cleanup)
1511 (make_cleanup_restore_infcall_control_state): Remove.
1512
1513 2018-09-17 Tom Tromey <tom@tromey.com>
1514
1515 * gdbthread.h (struct thread_control_state): Add initializer.
1516 (class thread_info) <control>: Remove initializer.
1517 * inferior.h (struct inferior_control_state): Add initializer.
1518 (class inferior) <control>: Remove initializer.
1519 (exit_inferior_1): Update.
1520 * infrun.c (struct infcall_control_state): Add constructors.
1521 (save_infcall_control_state): Use new.
1522 (restore_infcall_control_state, discard_infcall_control_state):
1523 Use delete.
1524
1525 2018-09-17 Tom Tromey <tom@tromey.com>
1526
1527 * infrun.c (struct infcall_suspend_state) <registers>: Now a
1528 unique_ptr.
1529 <siginfo_data>: Now a unique_xmalloc_ptr.
1530 (save_infcall_suspend_state, restore_infcall_suspend_state)
1531 (discard_infcall_suspend_state)
1532 (get_infcall_suspend_state_regcache): Update.
1533
1534 2018-09-17 Tom Tromey <tom@tromey.com>
1535
1536 * gdbthread.h (struct thread_suspend_state): Add initializers.
1537 (class thread_info) <suspend>: Remove initializer.
1538 * infrun.c (struct infcall_suspend_state): Add initializers.
1539 (save_infcall_suspend_state): Use new.
1540 (discard_infcall_suspend_state): Use delete.
1541
1542 2018-09-16 Tom Tromey <tom@tromey.com>
1543
1544 * python/python-internal.h (CPYCHECKER_STEALS_REFERENCE_TO_ARG):
1545 Remove.
1546 * python/py-varobj.c (py_varobj_iter_ctor): Change pyiter to
1547 rvalue reference. Remove CPYCHECKER_STEALS_REFERENCE_TO_ARG.
1548 (py_varobj_iter_new): Likewise.
1549 (py_varobj_get_iterator): Use gdbpy_ref.
1550
1551 2018-09-16 Tom Tromey <tom@tromey.com>
1552
1553 * python/py-threadevent.c (py_get_event_thread): Simplify.
1554 * python/py-inferior.c (infpy_thread_from_thread_handle):
1555 Return immediately after calling thread_to_thread_object. Use
1556 Py_RETURN_NONE.
1557 (thread_to_thread_object): Set the exception on a NULL return.
1558
1559 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1560
1561 * Makefile.in (LIBGDB_OBS): Sort COMMON_OBS.
1562
1563 2018-09-16 Tom Tromey <tom@tromey.com>
1564
1565 * python/python-internal.h (CPYCHECKER_RETURNS_BORROWED_REF):
1566 Remove.
1567
1568 2018-09-16 Tom Tromey <tom@tromey.com>
1569
1570 * python/python-internal.h (thread_to_thread_object): Change
1571 return type.
1572 * python/py-inferior.c (thread_to_thread_object): Return a new
1573 reference.
1574 (infpy_thread_from_thread_handle): Update.
1575 * python/py-infthread.c (gdbpy_selected_thread): Update.
1576 * python/py-stopevent.c (create_stop_event_object): Update.
1577 * python/py-threadevent.c (py_get_event_thread): Return a new
1578 reference.
1579 (py_get_event_thread): Update.
1580 * python/py-event.h (py_get_event_thread): Change return type.
1581 * python/py-continueevent.c (create_continue_event_object):
1582 Update.
1583
1584 2018-09-16 Tom Tromey <tom@tromey.com>
1585
1586 * python/py-progspace.c (pspy_get_objfiles): Update.
1587 * python/python-internal.h (objfile_to_objfile_object): Change
1588 return type.
1589 * python/py-newobjfileevent.c (create_new_objfile_event_object):
1590 Update.
1591 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1592 Update.
1593 * python/python.c (gdbpy_get_current_objfile): Update.
1594 (gdbpy_objfiles): Update.
1595 * python/py-objfile.c (objfpy_get_owner, gdbpy_lookup_objfile):
1596 Update.
1597 (objfile_to_objfile_object): Return a new reference.
1598 * python/py-symtab.c (stpy_get_objfile): Update.
1599 * python/py-prettyprint.c (find_pretty_printer_from_objfiles):
1600 Update.
1601
1602 2018-09-16 Tom Tromey <tom@tromey.com>
1603
1604 * python/py-inferior.c (infpy_get_progspace): Update.
1605 * python/python-internal.h (pspace_to_pspace_object): Change
1606 return type.
1607 * python/py-newobjfileevent.c
1608 (create_clear_objfiles_event_object): Update.
1609 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers):
1610 Update.
1611 * python/python.c (gdbpy_get_current_progspace): Update.
1612 (gdbpy_progspaces): Update.
1613 * python/py-progspace.c (pspace_to_pspace_object): Return a new
1614 reference.
1615 * python/py-objfile.c (objfpy_get_progspace): Update.
1616 * python/py-prettyprint.c (find_pretty_printer_from_progspace):
1617 Update.
1618
1619 2018-09-16 Tom Tromey <tom@tromey.com>
1620
1621 * python/lib/gdb/__init__.py (current_progspace, objfiles)
1622 (solib_name, block_for_pc, find_pc_line): New functions.
1623 (execute_unwinders): Update.
1624 * python/py-block.c (gdbpy_block_for_pc): Remove.
1625 * python/py-inferior.c (infpy_get_progspace): New function.
1626 (inferior_object_getset) <progspace>: Add.
1627 * python/py-progspace.c (pspy_objfiles): Rewrite.
1628 (pspy_solib_name, pspy_block_for_pc)
1629 (pspy_find_pc_line, pspy_is_valid): New functions.
1630 (progspace_object_methods): Add entries for solib_name,
1631 block_for_pc, find_pc_line, is_valid.
1632 * python/python-internal.h (gdbpy_block_for_pc)
1633 (build_objfiles_list): Don't declare.
1634 * python/python.c: Don't include solib.h.
1635 (gdbpy_solib_name, gdbpy_find_pc_line)
1636 (gdbpy_get_current_progspace, build_objfiles_list)
1637 (gdbpy_objfiles): Remove.
1638 (GdbMethods) <current_progspace, objfiles, block_for_pc,
1639 solib_name, find_pc_line>: Remove entries.
1640
1641 2018-09-16 Tom Tromey <tom@tromey.com>
1642
1643 * top.c (new_ui_command): Use GNU style for metasyntactic
1644 variables.
1645 * breakpoint.c (stopat_command): Use GNU style for metasyntactic
1646 variables.
1647 * maint.c (maintenance_translate_address): Remove "<>" around
1648 text.
1649 * interps.c (interpreter_exec_cmd): Use GNU style for
1650 metasyntactic variables.
1651 * nto-procfs.c (nto_procfs_target_info): Use GNU style for
1652 metasyntactic variables.
1653 * tracepoint.c (tfind_range_command): Use GNU style for
1654 metasyntactic variables.
1655 (tfind_outside_command): Likewise.
1656 (_initialize_tracepoint): Likewise.
1657 * remote.c (extended_remote_target::create_inferior): Use GNU
1658 style for metasyntactic variables.
1659 * sparc64-tdep.c (adi_examine_command): Use GNU style for
1660 metasyntactic variables.
1661 (adi_assign_command): Likewise.
1662
1663 2018-09-16 Tom Tromey <tom@tromey.com>
1664
1665 * disasm.c (show_disassembler_options_sfunc): Use GNU style for
1666 metasyntactic variables. Print message if no disassembler options
1667 are available.
1668
1669 2018-09-15 Tom Tromey <tom@tromey.com>
1670
1671 * infcmd.c (get_inferior_args): Return const char *.
1672 * inferior.h (get_inferior_args): Return type now const.
1673 * linux-tdep.c (linux_fill_prpsinfo): Update.
1674 * procfs.c (procfs_target::make_corefile_notes): Update.
1675
1676 2018-09-07 Tom Tromey <tom@tromey.com>
1677
1678 * python/python.c (execute_gdb_command): Call bpstat_do_actions
1679 inside the TRY.
1680
1681 2018-09-14 Sandra Loosemore <sandra@codesourcery.com>
1682
1683 * nios2-tdep.c (nios2_type_align): New.
1684 (nios2_gdb_arch_init): Install type_align hook.
1685
1686 2018-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1687
1688 * eval.c (fake_method::fake_method): Call xzalloc directly for a
1689 type that is neither object file owned, nor gdbarch owned.
1690 * gdbtypes.c (get_type_gdbarch): Add an assert that returned
1691 gdbarch is non-NULL.
1692 (alloc_type_instance): Allocate non-objfile owned types on the
1693 gdbarch obstack.
1694 (copy_type_recursive): Allocate TYPE_FIELDS and TYPE_RANGE_DATA
1695 using TYPE_ALLOC to ensure memory is allocated on the correct
1696 obstack.
1697 * gdbtypes.h (TYPE_ALLOC): Allocate space on either the objfile
1698 obstack, or the gdbarch obstack.
1699 (TYPE_ZALLOC): Rewrite using TYPE_ALLOC.
1700
1701 2018-09-14 Tom Tromey <tom@tromey.com>
1702
1703 * infcall.c (call_function_by_hand_dummy): Remove unnecessary
1704 block.
1705
1706 2018-09-14 Tom Tromey <tom@tromey.com>
1707
1708 * nat/fork-inferior.c (get_startup_shell): Remove "static".
1709
1710 2018-09-13 Tom Tromey <tom@tromey.com>
1711
1712 * python/py-inferior.c (infpy_thread_from_thread_handle): Now
1713 static.
1714
1715 2018-09-13 Tom Tromey <tom@tromey.com>
1716
1717 * exec.c (try_open_exec_file): Use std::string.
1718
1719 2018-09-13 Tom Tromey <tom@tromey.com>
1720
1721 * utils.h (gdb_bfd_errmsg): Return std::string.
1722 * exec.c (exec_file_attach): Update.
1723 * compile/compile-object-load.c (compile_object_load): Update.
1724 * utils.c (gdb_bfd_errmsg): Return std::string.
1725
1726 2018-09-13 Tom Tromey <tom@tromey.com>
1727
1728 * procfs.c (struct procinfo_deleter): New.
1729 (procinfo_up): New typedef.
1730 (do_destroy_procinfo_cleanup): Remove.
1731 (procfs_target::info_proc): Use procinfo_up. Remove cleanups.
1732
1733 2018-09-13 Tom Tromey <tom@tromey.com>
1734
1735 * source.c (add_path): Use gdb::unique_xmalloc_ptr.
1736
1737 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1738 2018-09-13 Tom Tromey <tom@tromey.com>
1739
1740 * python/py-progspace.c (PSPY_REQUIRE_VALID): New macro.
1741 (pspy_get_objfiles): New function.
1742 (progspace_object_methods): New.
1743 (pspace_object_type): Add tp_methods callback.
1744 * python/python-internal.h (build_objfiles_list): New
1745 declaration.
1746 * python/python.c (build_objfiles_list): New function.
1747 (gdbpy_objfiles): Implement using build_objfiles_list.
1748 * NEWS: Mention the Progspace.objfiles method.
1749
1750 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1751
1752 * python/py-inferior.c (infpy_get_progspace): New function.
1753 (inferior_object_getset): Add progspace property.
1754 * NEWS: Mention the new property.
1755
1756 2018-09-13 Tom Tromey <tom@tromey.com>
1757
1758 PR rust/23650:
1759 * rust-lang.c (rust_evaluate_subexp): Use field name, not "foo".
1760
1761 2018-09-13 Tom Tromey <tom@tromey.com>
1762
1763 PR rust/23626:
1764 * rust-lang.c (rust_enum_variant): Now static.
1765 (rust_empty_enum_p): New function.
1766 (rust_print_enum, rust_evaluate_subexp, rust_print_struct_def):
1767 Handle empty enum.
1768
1769 2018-09-13 Simon Marchi <simon.marchi@ericsson.com>
1770
1771 * python/py-inferior.c (infpy_repr): New.
1772 (inferior_object_type): Register infpy_repr.
1773 * python/py-objfile.c (objfpy_repr): New.
1774 (objfile_object_type): Register objfpy_repr.
1775
1776 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1777
1778 * fbsd-nat.c (fbsd_nat_target::info_proc): Remove unused variable.
1779
1780 2018-09-12 John Baldwin <jhb@FreeBSD.org>
1781
1782 * aarch64-fbsd-tdep.h (AARCH64_FBSD_SIZEOF_GREGSET): Fix comment
1783 typo.
1784
1785 2018-09-12 Sergio Durigan Junior <sergiodj@redhat.com>
1786
1787 * common/common-utils.c: Don't include '<sys/stat.h>'.
1788 (is_regular_file): Move to...
1789 * common/filestuff.c (is_regular_file): ... here.
1790 * common/common-utils.h (is_regular_file): Move to...
1791 * common/filestuff.h (is_regular_file): ... here.
1792
1793 2018-09-12 Simon Marchi <simon.marchi@ericsson.com>
1794
1795 * skip.c (debug_skip): New variable.
1796 (skiplist_entry::do_skip_file_p): Add debug output.
1797 (skiplist_entry::do_skip_gfile_p): Likewise.
1798 (skiplist_entry::skip_function_p): Likewise.
1799 (_initialize_step_skip): Create debug command.
1800 * NEWS: Mention set/show debug skip.
1801
1802 2018-09-11 Xavier Roirand <roirand@adacore.com>
1803
1804 * darwin-nat.c (should_disable_startup_with_shell):
1805 New function.
1806 (darwin_nat_target::create_inferior): Add call.
1807
1808 2018-09-11 Xavier Roirand <roirand@adacore.com>
1809
1810 * darwin-nat.h (struct darwin_thread_info) <gdb_port,
1811 inf_port, msg_state>: Initialize.
1812 (struct darwin_thread_info) <signaled, single_step>: Change
1813 type and initialize.
1814 (struct darwin_thread_info) <event>: Initialize.
1815
1816 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1817
1818 PR gdb/23555
1819 PR gdb/23558
1820 * gnulib/import/m4/getcwd-path-max.m4: Add cross-compilation
1821 guesses.
1822
1823 2018-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1824
1825 Revert:
1826 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
1827
1828 PR gdb/23555
1829 PR gdb/23558
1830 * gnulib/aclocal.m4: Regenerate.
1831 * gnulib/config.in: Regenerate.
1832 * gnulib/configure: Regenerate.
1833 * gnulib/import/Makefile.am: Update.
1834 * gnulib/import/Makefile.in: Update.
1835 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
1836 * gnulib/import/_Noreturn.h: ... this.
1837 * gnulib/import/alloca.in.h: Update.
1838 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
1839 * gnulib/import/arg-nonnull.h: ... this.
1840 * gnulib/import/assure.h: Update.
1841 * gnulib/import/at-func.c: Update.
1842 * gnulib/import/basename-lgpl.c: Update.
1843 * gnulib/import/extra/snippet/c++defs.h: Rename to...
1844 * gnulib/import/c++defs.h: ... this.
1845 * gnulib/import/canonicalize-lgpl.c: Update.
1846 * gnulib/import/cdefs.h: Update.
1847 * gnulib/import/chdir-long.c: Update.
1848 * gnulib/import/chdir-long.h: Update.
1849 * gnulib/import/cloexec.c: Update.
1850 * gnulib/import/cloexec.h: Update.
1851 * gnulib/import/close.c: Update.
1852 * gnulib/import/closedir.c: Update.
1853 * gnulib/import/config.charset: Update.
1854 * gnulib/import/dirent-private.h: Update.
1855 * gnulib/import/dirent.in.h: Update.
1856 * gnulib/import/dirfd.c: Update.
1857 * gnulib/import/dirname-lgpl.c: Update.
1858 * gnulib/import/dirname.h: Update.
1859 * gnulib/import/dosname.h: Update.
1860 * gnulib/import/dup-safer-flag.c: Update.
1861 * gnulib/import/dup-safer.c: Update.
1862 * gnulib/import/dup.c: Update.
1863 * gnulib/import/dup2.c: Update.
1864 * gnulib/import/errno.in.h: Update.
1865 * gnulib/import/error.c: Update.
1866 * gnulib/import/error.h: Update.
1867 * gnulib/import/exitfail.c: Update.
1868 * gnulib/import/exitfail.h: Update.
1869 * gnulib/import/extra/update-copyright: Update.
1870 * gnulib/import/fchdir.c: Update.
1871 * gnulib/import/fcntl.c: Update.
1872 * gnulib/import/fcntl.in.h: Update.
1873 * gnulib/import/fd-hook.c: Update.
1874 * gnulib/import/fd-hook.h: Update.
1875 * gnulib/import/fd-safer-flag.c: Update.
1876 * gnulib/import/fd-safer.c: Update.
1877 * gnulib/import/fdopendir.c: Update.
1878 * gnulib/import/filename.h: Update.
1879 * gnulib/import/filenamecat-lgpl.c: Update.
1880 * gnulib/import/filenamecat.h: Update.
1881 * gnulib/import/flexmember.h: Update.
1882 * gnulib/import/float+.h: Update.
1883 * gnulib/import/float.c: Update.
1884 * gnulib/import/float.in.h: Update.
1885 * gnulib/import/fnmatch.c: Update.
1886 * gnulib/import/fnmatch.in.h: Update.
1887 * gnulib/import/fnmatch_loop.c: Update.
1888 * gnulib/import/fpucw.h: Update.
1889 * gnulib/import/frexp.c: Update.
1890 * gnulib/import/frexpl.c: Update.
1891 * gnulib/import/fstat.c: Update.
1892 * gnulib/import/fstatat.c: Update.
1893 * gnulib/import/getcwd-lgpl.c: Update.
1894 * gnulib/import/getcwd.c: Update.
1895 * gnulib/import/getdtablesize.c: Update.
1896 * gnulib/import/getlogin_r.c: Update.
1897 * gnulib/import/getprogname.c: Update.
1898 * gnulib/import/getprogname.h: Update.
1899 * gnulib/import/gettext.h: Update.
1900 * gnulib/import/gettimeofday.c: Update.
1901 * gnulib/import/glob-libc.h: Update.
1902 * gnulib/import/glob.c: Update.
1903 * gnulib/import/glob.in.h: Update.
1904 * gnulib/import/glob_internal.h: Update.
1905 * gnulib/import/glob_pattern_p.c: Update.
1906 * gnulib/import/globfree.c: Update.
1907 * gnulib/import/hard-locale.c: Update.
1908 * gnulib/import/hard-locale.h: Update.
1909 * gnulib/import/intprops.h: Update.
1910 * gnulib/import/inttypes.in.h: Update.
1911 * gnulib/import/isnan.c: Update.
1912 * gnulib/import/isnand-nolibm.h: Update.
1913 * gnulib/import/isnand.c: Update.
1914 * gnulib/import/isnanl-nolibm.h: Update.
1915 * gnulib/import/isnanl.c: Update.
1916 * gnulib/import/itold.c: Update.
1917 * gnulib/import/libc-config.h: Update.
1918 * gnulib/import/limits.in.h: Update.
1919 * gnulib/import/localcharset.c: Update.
1920 * gnulib/import/localcharset.h: Update.
1921 * gnulib/import/localtime-buffer.c: Update.
1922 * gnulib/import/localtime-buffer.h: Update.
1923 * gnulib/import/lstat.c: Update.
1924 * gnulib/import/m4/00gnulib.m4: Update.
1925 * gnulib/import/m4/__inline.m4: Update.
1926 * gnulib/import/m4/absolute-header.m4: Update.
1927 * gnulib/import/m4/alloca.m4: Update.
1928 * gnulib/import/m4/builtin-expect.m4: Update.
1929 * gnulib/import/m4/canonicalize.m4: Update.
1930 * gnulib/import/m4/chdir-long.m4: Update.
1931 * gnulib/import/m4/close.m4: Update.
1932 * gnulib/import/m4/closedir.m4: Update.
1933 * gnulib/import/m4/configmake.m4: Update.
1934 * gnulib/import/m4/d-ino.m4: Update.
1935 * gnulib/import/m4/d-type.m4: Update.
1936 * gnulib/import/m4/dirent_h.m4: Update.
1937 * gnulib/import/m4/dirfd.m4: Update.
1938 * gnulib/import/m4/dirname.m4: Update.
1939 * gnulib/import/m4/double-slash-root.m4: Update.
1940 * gnulib/import/m4/dup.m4: Update.
1941 * gnulib/import/m4/dup2.m4: Update.
1942 * gnulib/import/m4/eealloc.m4: Update.
1943 * gnulib/import/m4/environ.m4: Update.
1944 * gnulib/import/m4/errno_h.m4: Update.
1945 * gnulib/import/m4/error.m4: Update.
1946 * gnulib/import/m4/exponentd.m4: Update.
1947 * gnulib/import/m4/exponentl.m4: Update.
1948 * gnulib/import/m4/extensions.m4: Update.
1949 * gnulib/import/m4/extern-inline.m4: Update.
1950 * gnulib/import/m4/fchdir.m4: Update.
1951 * gnulib/import/m4/fcntl-o.m4: Update.
1952 * gnulib/import/m4/fcntl.m4: Update.
1953 * gnulib/import/m4/fcntl_h.m4: Update.
1954 * gnulib/import/m4/fdopendir.m4: Update.
1955 * gnulib/import/m4/filenamecat.m4: Update.
1956 * gnulib/import/m4/flexmember.m4: Update.
1957 * gnulib/import/m4/float_h.m4: Update.
1958 * gnulib/import/m4/fnmatch.m4: Update.
1959 * gnulib/import/m4/fnmatch_h.m4: Update.
1960 * gnulib/import/m4/fpieee.m4: Update.
1961 * gnulib/import/m4/frexp.m4: Update.
1962 * gnulib/import/m4/frexpl.m4: Update.
1963 * gnulib/import/m4/fstat.m4: Update.
1964 * gnulib/import/m4/fstatat.m4: Update.
1965 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
1966 * gnulib/import/m4/getcwd-path-max.m4: Update.
1967 * gnulib/import/m4/getcwd.m4: Update.
1968 * gnulib/import/m4/getdtablesize.m4: Update.
1969 * gnulib/import/m4/getlogin.m4: Update.
1970 * gnulib/import/m4/getlogin_r.m4: Update.
1971 * gnulib/import/m4/getpagesize.m4: Update.
1972 * gnulib/import/m4/getprogname.m4: Update.
1973 * gnulib/import/m4/gettimeofday.m4: Update.
1974 * gnulib/import/m4/glibc21.m4: Update.
1975 * gnulib/import/m4/glob.m4: Update.
1976 * gnulib/import/m4/glob_h.m4: Update.
1977 * gnulib/import/m4/gnulib-cache.m4: Update.
1978 * gnulib/import/m4/gnulib-common.m4: Update.
1979 * gnulib/import/m4/gnulib-comp.m4: Update.
1980 * gnulib/import/m4/gnulib-tool.m4: Update.
1981 * gnulib/import/m4/hard-locale.m4: Update.
1982 * gnulib/import/m4/include_next.m4: Update.
1983 * gnulib/import/m4/inttypes-pri.m4: Update.
1984 * gnulib/import/m4/inttypes.m4: Update.
1985 * gnulib/import/m4/isnand.m4: Update.
1986 * gnulib/import/m4/isnanl.m4: Update.
1987 * gnulib/import/m4/largefile.m4: Update.
1988 * gnulib/import/m4/limits-h.m4: Update.
1989 * gnulib/import/m4/localcharset.m4: Update.
1990 * gnulib/import/m4/locale-fr.m4: Update.
1991 * gnulib/import/m4/locale-ja.m4: Update.
1992 * gnulib/import/m4/locale-zh.m4: Update.
1993 * gnulib/import/m4/localtime-buffer.m4: Update.
1994 * gnulib/import/m4/longlong.m4: Update.
1995 * gnulib/import/m4/lstat.m4: Update.
1996 * gnulib/import/m4/malloc.m4: Update.
1997 * gnulib/import/m4/malloca.m4: Update.
1998 * gnulib/import/m4/math_h.m4: Update.
1999 * gnulib/import/m4/mbrtowc.m4: Update.
2000 * gnulib/import/m4/mbsinit.m4: Update.
2001 * gnulib/import/m4/mbsrtowcs.m4: Update.
2002 * gnulib/import/m4/mbstate_t.m4: Update.
2003 * gnulib/import/m4/memchr.m4: Update.
2004 * gnulib/import/m4/memmem.m4: Update.
2005 * gnulib/import/m4/mempcpy.m4: Update.
2006 * gnulib/import/m4/memrchr.m4: Update.
2007 * gnulib/import/m4/mkdir.m4: Update.
2008 * gnulib/import/m4/mkstemp.m4: Update.
2009 * gnulib/import/m4/mmap-anon.m4: Update.
2010 * gnulib/import/m4/mode_t.m4: Update.
2011 * gnulib/import/m4/msvc-inval.m4: Update.
2012 * gnulib/import/m4/msvc-nothrow.m4: Update.
2013 * gnulib/import/m4/multiarch.m4: Update.
2014 * gnulib/import/m4/nocrash.m4: Update.
2015 * gnulib/import/m4/off_t.m4: Update.
2016 * gnulib/import/m4/onceonly.m4: Update.
2017 * gnulib/import/m4/open-cloexec.m4: Update.
2018 * gnulib/import/m4/open.m4: Update.
2019 * gnulib/import/m4/openat.m4: Update.
2020 * gnulib/import/m4/opendir.m4: Update.
2021 * gnulib/import/m4/pathmax.m4: Update.
2022 * gnulib/import/m4/rawmemchr.m4: Update.
2023 * gnulib/import/m4/readdir.m4: Update.
2024 * gnulib/import/m4/readlink.m4: Update.
2025 * gnulib/import/m4/realloc.m4: Update.
2026 * gnulib/import/m4/rename.m4: Update.
2027 * gnulib/import/m4/rewinddir.m4: Update.
2028 * gnulib/import/m4/rmdir.m4: Update.
2029 * gnulib/import/m4/save-cwd.m4: Update.
2030 * gnulib/import/m4/secure_getenv.m4: Update.
2031 * gnulib/import/m4/setenv.m4: Update.
2032 * gnulib/import/m4/signal_h.m4: Update.
2033 * gnulib/import/m4/ssize_t.m4: Update.
2034 * gnulib/import/m4/stat-time.m4: Update.
2035 * gnulib/import/m4/stat.m4: Update.
2036 * gnulib/import/m4/std-gnu11.m4: Update.
2037 * gnulib/import/m4/stdbool.m4: Update.
2038 * gnulib/import/m4/stddef_h.m4: Update.
2039 * gnulib/import/m4/stdint.m4: Update.
2040 * gnulib/import/m4/stdio_h.m4: Update.
2041 * gnulib/import/m4/stdlib_h.m4: Update.
2042 * gnulib/import/m4/strchrnul.m4: Update.
2043 * gnulib/import/m4/strdup.m4: Update.
2044 * gnulib/import/m4/strerror.m4: Update.
2045 * gnulib/import/m4/string_h.m4: Update.
2046 * gnulib/import/m4/strstr.m4: Update.
2047 * gnulib/import/m4/strtok_r.m4: Update.
2048 * gnulib/import/m4/sys_socket_h.m4: Update.
2049 * gnulib/import/m4/sys_stat_h.m4: Update.
2050 * gnulib/import/m4/sys_time_h.m4: Update.
2051 * gnulib/import/m4/sys_types_h.m4: Update.
2052 * gnulib/import/m4/tempname.m4: Update.
2053 * gnulib/import/m4/time_h.m4: Update.
2054 * gnulib/import/m4/unistd-safer.m4: Update.
2055 * gnulib/import/m4/unistd_h.m4: Update.
2056 * gnulib/import/m4/warn-on-use.m4: Update.
2057 * gnulib/import/m4/wchar_h.m4: Update.
2058 * gnulib/import/m4/wchar_t.m4: Update.
2059 * gnulib/import/m4/wctype_h.m4: Update.
2060 * gnulib/import/m4/wint_t.m4: Update.
2061 * gnulib/import/malloc.c: Update.
2062 * gnulib/import/malloc/scratch_buffer.h: Update.
2063 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2064 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2065 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2066 * gnulib/import/malloca.c: Update.
2067 * gnulib/import/malloca.h: Update.
2068 * gnulib/import/malloca.valgrind: Update.
2069 * gnulib/import/math.in.h: Update.
2070 * gnulib/import/mbrtowc.c: Update.
2071 * gnulib/import/mbsinit.c: Update.
2072 * gnulib/import/mbsrtowcs-impl.h: Update.
2073 * gnulib/import/mbsrtowcs-state.c: Update.
2074 * gnulib/import/mbsrtowcs.c: Update.
2075 * gnulib/import/memchr.c: Update.
2076 * gnulib/import/memmem.c: Update.
2077 * gnulib/import/mempcpy.c: Update.
2078 * gnulib/import/memrchr.c: Update.
2079 * gnulib/import/mkdir.c: Update.
2080 * gnulib/import/mkstemp.c: Update.
2081 * gnulib/import/msvc-inval.c: Update.
2082 * gnulib/import/msvc-inval.h: Update.
2083 * gnulib/import/msvc-nothrow.c: Update.
2084 * gnulib/import/msvc-nothrow.h: Update.
2085 * gnulib/import/open.c: Update.
2086 * gnulib/import/openat-die.c: Update.
2087 * gnulib/import/openat-priv.h: Update.
2088 * gnulib/import/openat-proc.c: Update.
2089 * gnulib/import/openat.c: Update.
2090 * gnulib/import/openat.h: Update.
2091 * gnulib/import/opendir.c: Update.
2092 * gnulib/import/pathmax.h: Update.
2093 * gnulib/import/pipe-safer.c: Update.
2094 * gnulib/import/rawmemchr.c: Update.
2095 * gnulib/import/readdir.c: Update.
2096 * gnulib/import/readlink.c: Update.
2097 * gnulib/import/realloc.c: Update.
2098 * gnulib/import/ref-add.sin: Update.
2099 * gnulib/import/ref-del.sin: Update.
2100 * gnulib/import/rename.c: Update.
2101 * gnulib/import/rewinddir.c: Update.
2102 * gnulib/import/rmdir.c: Update.
2103 * gnulib/import/same-inode.h: Update.
2104 * gnulib/import/save-cwd.c: Update.
2105 * gnulib/import/save-cwd.h: Update.
2106 * gnulib/import/scratch_buffer.h: Update.
2107 * gnulib/import/secure_getenv.c: Update.
2108 * gnulib/import/setenv.c: Update.
2109 * gnulib/import/signal.in.h: Update.
2110 * gnulib/import/stat-time.c: Update.
2111 * gnulib/import/stat-time.h: Update.
2112 * gnulib/import/stat-w32.c: Update.
2113 * gnulib/import/stat-w32.h: Update.
2114 * gnulib/import/stat.c: Update.
2115 * gnulib/import/stdbool.in.h: Update.
2116 * gnulib/import/stddef.in.h: Update.
2117 * gnulib/import/stdint.in.h: Update.
2118 * gnulib/import/stdio.in.h: Update.
2119 * gnulib/import/stdlib.in.h: Update.
2120 * gnulib/import/str-two-way.h: Update.
2121 * gnulib/import/strchrnul.c: Update.
2122 * gnulib/import/strdup.c: Update.
2123 * gnulib/import/streq.h: Update.
2124 * gnulib/import/strerror-override.c: Update.
2125 * gnulib/import/strerror-override.h: Update.
2126 * gnulib/import/strerror.c: Update.
2127 * gnulib/import/string.in.h: Update.
2128 * gnulib/import/stripslash.c: Update.
2129 * gnulib/import/strnlen1.c: Update.
2130 * gnulib/import/strnlen1.h: Update.
2131 * gnulib/import/strstr.c: Update.
2132 * gnulib/import/strtok_r.c: Update.
2133 * gnulib/import/sys_stat.in.h: Update.
2134 * gnulib/import/sys_time.in.h: Update.
2135 * gnulib/import/sys_types.in.h: Update.
2136 * gnulib/import/tempname.c: Update.
2137 * gnulib/import/tempname.h: Update.
2138 * gnulib/import/time.in.h: Update.
2139 * gnulib/import/unistd--.h: Update.
2140 * gnulib/import/unistd-safer.h: Update.
2141 * gnulib/import/unistd.in.h: Update.
2142 * gnulib/import/unsetenv.c: Update.
2143 * gnulib/import/verify.h: Update.
2144 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2145 * gnulib/import/wchar.in.h: Update.
2146 * gnulib/import/wctype.in.h: Update.
2147 * gnulib/import/xalloc-oversized.h: Update.
2148 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2149 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2150
2151 2018-09-10 Simon Marchi <simon.marchi@ericsson.com>
2152
2153 * record-btrace.c (get_thread_current_frame): Remove
2154 old_inferior_ptid.
2155
2156 2018-09-10 Jerome Guitton <guitton@adacore.com>
2157
2158 * ada-lang.c (ada_value_struct_elt): Call ada_to_fixed_type
2159 with check_tag to 1 if and only if the type is tagged and the
2160 component being searched cannot been found in the current
2161 view. Otherwise, always call ada_to_fixed_type with
2162 check_tag to 0.
2163
2164 2018-09-10 Xavier Roirand <roirand@adacore.com>
2165
2166 * ada-lang.c (ada_is_access_to_unconstrained_array): Remove static
2167 declaration.
2168 * ada-lang.h: add ada_is_access_to_unconstrained_array prototype.
2169 * ada-varobj.c (ada_varobj_get_number_of_children,
2170 ada_varobj_describe_child, ada_value_is_changeable_p): Cleanup code.
2171
2172 2018-09-10 Xavier Roirand <roirand@adacore.com>
2173
2174 * ada-valprint.c (ada_value_print): Use type instead of
2175 enclosing type.
2176
2177 2018-09-10 Xavier Roirand <roirand@adacore.com>
2178
2179 * ada-lang.c (ada_value_subscript): Handle case when parameter is
2180 an array of access to unconstrained array.
2181
2182 2018-09-10 Xavier Roirand <roirand@adacore.com>
2183
2184 * ada-lang.c (ada_is_access_to_unconstrained_array): New function.
2185 (ada_check_typedef): Use it.
2186
2187 2018-09-10 Xavier Roirand <roirand@adacore.com>
2188
2189 * ada-varobj.c (ada_varobj_describe_struct_child)
2190 (ada_varobj_describe_child): Handle union case like struct one.
2191
2192 2018-09-10 Tom Tromey <tom@tromey.com>
2193
2194 PR python/18380:
2195 * python/python.c (_initialize_python): Make example in "python"
2196 help work in Python 3.
2197
2198 2018-09-10 Eli Zaretskii <eliz@gnu.org>
2199
2200 * Makefile.in (transformed_name): Use INSTALL_SCRIPT instead of
2201 INSTALL_PROGRAM to install gdb-add-index.sh. Don't append
2202 $(EXEEXT) to the script, as it is not a program.
2203
2204 2018-09-09 Simon Marchi <simon.marchi@ericsson.com>
2205
2206 * python/py-prettyprint.c (pretty_print_one_value): Return
2207 gdbpy_ref<>.
2208 (print_string_repr): Adjust.
2209 (apply_varobj_pretty_printer): Return gdbpy_ref<>.
2210 * python/python-internal.h (apply_varobj_pretty_printer): Return
2211 gdbpy_ref<>.
2212 * varobj.c (varobj_value_get_print_value): Adjust.
2213
2214 2018-09-08 Tom Tromey <tom@tromey.com>
2215
2216 PR python/16047:
2217 * python/py-prettyprint.c (pretty_print_one_value): Check for
2218 to_string method.
2219
2220 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2221
2222 * ada-lang.c (resolve_subexp): Pass correct OPLEN in call to
2223 replace_operator_with_call.
2224
2225 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2226
2227 * ada-lang.c (ada_value_cast): Remove unnecessary parentheses.
2228
2229 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2230
2231 * ada-typeprint.c (print_range): Print the bounds using TYPE
2232 rather than its TYPE_TARGET_TYPE.
2233
2234 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2235
2236 * ada-lang.c (ada_to_fixed_value): Minor reformatting in
2237 call to ada_to_fixed_value_create.
2238
2239 2018-09-08 Jerome Guitton <guitton@adacore.com>
2240
2241 * ada-lang.c (ada_decode): strip dot prefix in symbol name.
2242
2243 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2244
2245 * ada-lang.c (ada_exception_sal): Replace gdb_assert calls
2246 by calls to error.
2247
2248 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2249
2250 * ada-lang.c (ada_unhandled_exception_name_addr_from_raise):
2251 Move update of loop variable "fi".
2252
2253 2018-09-08 Joel Brobecker <brobecker@adacore.com>
2254
2255 * ada-lang.c (value_assign_to_component): In the case of
2256 big-endian targets, extract the bits of the given VAL
2257 using an src_offset of zero if container is not a scalar.
2258
2259 2018-09-06 Simon Ser <contact@emersion.fr>
2260
2261 PR gdb/23105
2262 * fbsd-nat.c (fbsd_nat_target::xfer_partial): Add support for
2263 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
2264 * fbsd-tdep.c (fbsd_make_note_desc): New.
2265 (fbsd_make_corefile_notes): Write NT_PROCSTAT_AUXV,
2266 NT_PROCSTAT_VMMAP and NT_PROCSTAT_PS_STRINGS notes.
2267 * target.h (enum target_object) Add FreeBSD-specific
2268 TARGET_OBJECT_FREEBSD_VMMAP and TARGET_OBJECT_FREEBSD_PS_STRINGS.
2269
2270 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2271
2272 * compile/compile-c.h (generate_c_for_variable_locations):
2273 Change reference to pointer.
2274 * compile/compile-c-support.c (compile_program) <compute>:
2275 Likewise.
2276 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
2277 (generate_c_for_for_one_variable): Likewise
2278 (generate_c_for_variable_locations): Likewise
2279 * compile/compile-c-types.c (compile_c_instance::convert_type):
2280 Likewise
2281 * compile/compile-cplus-symbols.c (convert_one_symbol):
2282 std::move the scope passed to enter_scope.
2283 * compile/compile-cplus-types.c
2284 (compile_cplus_instance::enter_scope): Make parameter
2285 rvalue-reference.
2286 (compile_cplus_instance::new_scope): Change reference to
2287 pointer.
2288 (compile_cplus_instance::convert_type): Likewise
2289 (compile_cplus_convert_typedef): std::move the scope passed to
2290 enter_scope.
2291 (compile_cplus_convert_struct_or_union): Likewise.
2292 (compile_cplus_convert_enum): Likewise.
2293 (compile_cplus_convert_namespace): Likewise.
2294 * compile/compile-cplus.h (compile_cplus_instance)
2295 <enter_scope>: Make parameter rvalue-reference.
2296 * compile/compile-internal.h (compile_instance)
2297 <get_cached_type>: Likewise
2298 * compile/compile-loc2c.c (push): Likewise
2299 (pushf): Likewise
2300 (unary): Likewise
2301 (binary): Likewise
2302 (print_label): Likewise
2303 (pushf_register_address): Likewise
2304 (pushf_register): Likewise
2305 (do_compile_dwarf_expr_to_c): Likewise
2306 (compile_dwarf_expr_to_c): Likewise
2307 (compile_dwarf_bounds_to_c): Likewise
2308 * compile/compile.c (compile_instance::get_cached_type):
2309 Likewise
2310 * compile/compile.h (compile_dwarf_expr_to_c): Likewise.
2311 (compile_dwarf_bounds_to_c): Likewise
2312 * dwarf2loc.c (locexpr_generate_c_location): Likewise.
2313 (dwarf2_compile_property_to_c): Likewise
2314 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise
2315 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
2316 Likewise
2317
2318 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2319
2320 * tui/tui-data.h (struct tui_win_element) <highlight>: Remove.
2321 * tui/tui-data.c (init_content_element): Don't initialize it.
2322
2323 2018-09-06 Simon Marchi <simon.marchi@ericsson.com>
2324
2325 * tui/tui-data.h (struct tui_win_info)
2326 <detail::opaque>: Remove.
2327 * tui/tui-data.c (init_win_info): Remove assignment.
2328
2329 2018-09-05 Tom Tromey <tom@tromey.com>
2330
2331 * warning.m4 (AM_GDB_WARNINGS): Add -Wformat when testing
2332 -Wformat-nonliteral.
2333 * target-float.c (host_float_ops<T>::to_string)
2334 (host_float_ops<T>::from_string): Use
2335 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
2336 * configure: Rebuild.
2337
2338 2018-09-05 Simon Marchi <simon.marchi@ericsson.com>
2339
2340 * printcmd.c (printf_c_string): Use
2341 DIAGNOSTIC_IGNORE_FORMAT_NONLITERAL.
2342 (printf_wide_c_string, printf_pointer, ui_printf): Likewise.
2343
2344 2018-09-05 Tom Tromey <tom@tromey.com>
2345
2346 * cli/cli-cmds.c (shell_escape, edit_command): Remove cast.
2347
2348 2018-09-05 Tom de Vries <tdevries@suse.de>
2349
2350 * dwarf2loc.c (sect_variable_value): Call indirect_synthetic_pointer
2351 with resolve_abstract_p == true.
2352 (indirect_synthetic_pointer): Add resolve_abstract_p parameter,
2353 defaulting to false. Propagate resolve_abstract_p to
2354 dwarf2_fetch_die_loc_sect_off.
2355 * dwarf2loc.h (dwarf2_fetch_die_loc_sect_off): Add resolve_abstract_p
2356 parameter, defaulting to false.
2357 * dwarf2read.c (read_variable): Add variable to abstract_to_concrete.
2358 (dwarf2_fetch_die_loc_sect_off): Add and handle resolve_abstract_p
2359 parameter.
2360 * dwarf2read.h (struct die_info): Forward-declare.
2361 (die_info_ptr): New typedef.
2362 (struct dwarf2_per_objfile): Add abstract_to_concrete field.
2363
2364 2018-09-05 Joel Brobecker <brobecker@adacore.com>
2365
2366 GDB 8.2 released.
2367
2368 2018-09-04 Sergio Durigan Junior <sergiodj@redhat.com>
2369 Pedro Alves <palves@redhat.com>
2370
2371 * gnulib/Makefile.in (aclocal_m4_deps): Move to
2372 "aclocal-m4-deps.mk". Include file here.
2373 $(srcdir)/aclocal.m4: Add "configure.ac".
2374 * gnulib/aclocal-m4-deps.mk: New file.
2375 * gnulib/update-gnulib.sh: Automatically update
2376 "aclocal-m4-deps.mk".
2377
2378 2018-09-04 Tom Tromey <tom@tromey.com>
2379
2380 * configure: Rebuild.
2381 * configure.ac: Remove multi-ice code.
2382
2383 2018-09-04 Tom Tromey <tom@tromey.com>
2384
2385 * Makefile.in (GDB_WARN_CFLAGS_NO_DEFS): Remove.
2386 (ada-exp.o): Update.
2387
2388 2018-09-04 Tom Tromey <tom@tromey.com>
2389
2390 * Makefile.in (printcmd.o, target-float.o): Remove.
2391 (GDB_WARN_CFLAGS_NO_FORMAT): Remove.
2392
2393 2018-09-04 Tom Tromey <tom@tromey.com>
2394
2395 * gnulib/Makefile.in: Remove obsolete comment.
2396 * Makefile.in: Remove obsolete comment.
2397
2398 2018-09-04 Andrew Burgess <andrew.burgess@embecosm.com>
2399
2400 * riscv-tdep.c (riscv_frame_cache): Fix ARI warning, don't end a
2401 line with '+'.
2402
2403 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2404
2405 * riscv-tdep.c: Add 'prologue-value.h' include.
2406 (struct riscv_unwind_cache): New struct.
2407 (riscv_debug_unwinder): New global.
2408 (riscv_scan_prologue): Update arguments, capture register details
2409 from prologue scan.
2410 (riscv_skip_prologue): Reformat arguments line, move end of
2411 prologue calculation into riscv_scan_prologue.
2412 (riscv_frame_cache): Update return type, create
2413 riscv_unwind_cache, scan the prologue, and fill in remaining cache
2414 details.
2415 (riscv_frame_this_id): Use frame id computed in riscv_frame_cache.
2416 (riscv_frame_prev_register): Use the trad_frame within the
2417 riscv_unwind_cache.
2418 (_initialize_riscv_tdep): Add 'set/show debug riscv unwinder'
2419 flag.
2420
2421 2018-09-03 Andrew Burgess <andrew.burgess@embecosm.com>
2422
2423 * trad-frame.h (trad_frame_set_realreg): Declare.
2424 (trad_frame_set_addr): Declare.
2425 * trad-frame.c (trad_frame_set_realreg): Define new function.
2426 (trad_frame_set_addr): Define new function.
2427 (trad_frame_set_reg_realreg): Use new function.
2428 (trad_frame_set_reg_addr): Use new function.
2429
2430 2018-09-01 Keith Seitz <keiths@redhat.com>
2431
2432 * compile/compile-cplus-types.c (compile_cplus_debug_output_1): Use
2433 pulongest instead of "%lld".
2434 * compile/compile-cplus-symbols.c (gcc_cplus_convert_symbol): Remove
2435 ATTRIBUTE_UNUSED.
2436
2437 2018-08-31 Tom Tromey <tom@tromey.com>
2438
2439 * dwarf2read.c (dwarf2_add_field): Set the TYPE_LENGTH of the
2440 variant part type.
2441
2442 2018-08-31 Pedro Alves <palves@redhat.com>
2443
2444 * gdbarch.h: Regenerate.
2445
2446 2018-08-31 Pedro Alves <palves@redhat.com>
2447
2448 * gdbarch.sh (have_nonsteppable_watchpoint): Add comment.
2449 * target.h (Hardware watchpoint interfaces): Describe
2450 continuable/steppable/non-steppable watchpoints.
2451 * gdbarch.h, gdbarch.c: Regenerate.
2452
2453 2018-08-31 Pedro Alves <palves@redhat.com>
2454
2455 * nto-procfs.c (nto_procfs_target::have_continuable_watchpoint):
2456 Delete.
2457 * s390-linux-nat.c
2458 (s390_linux_nat_target::have_continuable_watchpoint): Delete.
2459 * target.h (target_ops::have_continuable_watchpoint): Delete.
2460 (target_have_continuable_watchpoint): Delete.
2461 * x86-nat.h (x86_nat_target::have_continuable_watchpoint): Delete.
2462 * target-delegates.c: Regenerate.
2463
2464 2018-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2465
2466 * gnulib/Makefile.in (aclocal_m4_deps): Update according to
2467 the files present in "gnulib/import/m4/".
2468
2469 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2470
2471 * riscv-tdep.c (riscv_insn::decode): Decode c.addi4spn, c.sd,
2472 c.sw, c.swsp, and c.sdsp.
2473
2474 2018-08-30 Andrew Burgess <andrew.burgess@embecosm.com>
2475
2476 * riscv-tdep.c (struct riscv_inferior_data): Delete.
2477 (riscv_read_misa_reg): Don't cache value read into inferior data.
2478 (riscv_new_inferior_data): Delete.
2479 (riscv_inferior_data_cleanup): Delete.
2480 (riscv_inferior_data): Delete.
2481 (riscv_invalidate_inferior_data): Delete.
2482 (_initialize_riscv_tdep): Remove initialisation of inferior data.
2483
2484 2018-08-30 Simon Marchi <simon.marchi@ericsson.com>
2485
2486 * compile/compile-cplus-types.c
2487 (compile_cplus_instance::leave_scope): Take the address of scope
2488 object.
2489 (compile_cplus_instance::convert_qualified_base): Compare quals
2490 to 0.
2491
2492 2018-08-30 Keith Seitz <keiths@redhat.com>
2493
2494 * compile/compile-cplus-types.c (compile_cplus_instance::enter_scope):
2495 Use "%s" and host_address_to_string instead of "%p" in printf.
2496
2497 2018-08-29 Keith Seitz <keiths@redhat.com>
2498
2499 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Add compile-cplus-symbols.c
2500 and compile-cplus-types.c.
2501 (HFILES_NO_SRCDIR): Add gcc-cp-plugin.h.
2502 * c-lang.c (cplus_language_defn): Set C++ compile functions.
2503 * c-lang.h (cplus_get_compile_context, cplus_compute_program):
2504 Declare.
2505 * compile/compile-c-support.c: Include compile-cplus.h.
2506 (load_libcompile): Templatize.
2507 (get_compile_context): "New" function.
2508 (c_get_compile_context): Use get_compile_context.
2509 (cplus_get_compile_context): New function.
2510 (cplus_push_user_expression, cplus_pop_user_expression)
2511 (cplus_add_code_header, cplus_add_input, cplus_compile_program)
2512 (cplus_compute_program): Define new structs/functions.
2513 * compile/compile-cplus-symmbols.c: New file.
2514 * compile/compile-cplus-types.c: New file.
2515 * compile/compile-cplus.h: New file.
2516 * compile/compile-internal.h (debug_compile_oracle, GCC_TYPE_NONE):
2517 Declare.
2518 * compile/compile-object-load.c (get_out_value_type): Use
2519 strncmp_iw when comparing symbol names.
2520 (compile_object_load): Add mst_bss and mst_data.
2521 * compile/compile.c (_initialize_compile): Remove
2522 -Wno-implicit-function-declaration from `compile_args'.
2523 * compile/gcc-cp-plugin.h: New file.
2524 * NEWS: Mention C++ compile support and new debug options.
2525
2526 2018-08-29 Keith Seitz <keiths@redhat.com>
2527
2528 * linespec.c (collect_info::add_symbol): Make virtual.
2529 (struct symbol_searcher_collect_info): New struct.
2530 (symbol_searcher::find_all_symbols): New method.
2531 * symtab.h (class symbol_searcher): New class.
2532
2533 2018-08-29 Keith Seitz <keiths@redhat.com>
2534
2535 * linespec.c (struct linespec) <function_symbols, label_symbols>:
2536 Change to vector of block_symbol. Update all users.
2537 (struct collect_info) <symbols>: Likewise.
2538 (collect_info::add_symbol): Take block_symbol as argument.
2539 Update all callers.
2540 (decode_compound_collector) <m_symbols>: Change type to vector
2541 of block_symbol. Update all users.
2542 (decode_compound_collector::operator ()): Change parameter type
2543 to block_symbol.
2544 (find_method, find_function_symbols, find_linespec_symbols)
2545 (find_label_symbols_in_block, find_label_symbols): Change symbol
2546 vectors to block_symbol vectors.
2547 * symtab.h (symbol_found_callback_ftype): Change parameter type to
2548 block_symbol.
2549
2550 2018-08-29 Keith Seitz <keiths@redhat.com>
2551
2552 * linespec.c (symbolp): Remove typedef and VEC definitions.
2553 (bound_minimal_symbol_d): Likewise.
2554
2555 2018-08-29 Keith Seitz <keiths@redhat.com>
2556
2557 * linespec.c (decode_compound_collector::decode_compound_collector):
2558 Remove initialization for `m_symtabs'.
2559 (decode_compound_collector::release_symbols): Change return type
2560 to std::vector. Update all callers.
2561 (class decode_compound_collector) <m_symbols>: Change type to
2562 std::vector.
2563 (lookup_prefix_sym): Change return type to std::vector. Update all
2564 callers.
2565 (compare_symbols): Remove.
2566 (std_compare_symbols): Rename to `compare_symbols'.
2567 (find_method): Change `sym_classes' parameter to std::vector.
2568 Update all callers. Use std::sort to sort sym_classes.
2569 (find_linespec_symbols): Remove cleanup.
2570
2571 2018-08-29 Keith Seitz <keiths@redhat.com>
2572
2573 * linespec.c (struct linespec) <minimal_symbols>: Change type to
2574 std::vector. Update all users.
2575 (convert_linespec_to_sals): Use std::sort to sort minimal symbols.
2576 (struct collect_info) <minimal_symbols>: Likewise.
2577 (compare_msymbols): Return bool. Change parameters to const
2578 bound_minimal_symbol references.
2579 (find_method, find_function_symbols, find_linespec_symbols): Change
2580 `minsyms' parameter to std::vector. Update all callers.
2581
2582 2018-08-29 Keith Seitz <keiths@redhat.com>
2583
2584 * linespec.c (struct linespec) <label_symbols>: Change type to
2585 std::vector. Update all users.
2586 (find_label_symbols_in_block): Change `result' parameter to
2587 std::vector. Update all callers.
2588 (find_label_symbols): Return std::vector. Update all callers.
2589
2590 2018-08-29 Keith Seitz <keiths@redhat.com>
2591
2592 * linespec.c (struct linespec) <function_symbols>: Change type to
2593 std::vector. Update all users.
2594 (struct collect_info) <function_symbols>: Likewise.
2595 (convert_linespec_to_sals): Use std::sort to sort function_symbols.
2596 (std_compare_symbols): New function.
2597 (find_method, find_function_symbols, find_linespec_symbols)
2598 (find_label_symbols_in_block): Change `symbols' parameter to
2599 std::vector. Update all callers.
2600 (find_label_symbols): Likewise for `function_symbols' and
2601 `label_funcs_ret'.
2602
2603 2018-08-29 Keith Seitz <keiths@redhat.com>
2604
2605 * linespec.c (symtab_vector_up): Define.
2606 (struct linespec) <file_symtabs>: Change type to std::vector *.
2607 Update all uses.
2608 (struct collect_info) <file_symtabs>: Likewise.
2609 (collect_symtabs_from_filename): Return symtab_vector_up.
2610 Update all callers.
2611 (decode_objc): Remove cleanup.
2612 (symtab_collector::symtab_collector): Initialize `m_symtabs'.
2613 (symtab_collector::release_symtabs): Return symtab_vector_up.
2614 Update all callers.
2615 (class symtab_collector) <m_symtabs>: Change type to symtab_vector_up.
2616 Update all users.
2617 (collect_symtabs_from_filename, symtabs_from_filename): Return
2618 symtab_vector_up. Update all callers.
2619
2620 2018-08-29 Tom Tromey <tom@tromey.com>
2621
2622 * csky-tdep.c (csky_analyze_prologue): Use
2623 core_addr_to_string_nz.
2624
2625 2018-08-29 Tom Tromey <tom@tromey.com>
2626
2627 * windows-nat.c (struct xlate_exception) <them>: Change type to
2628 DWORD.
2629 (xlate): Fix formatting. Remove last entry.
2630 (struct xlate_exception, xlate): Comment out.
2631 (windows_nat_target::resume): Use ranged for.
2632
2633 2018-08-29 Jim Wilson <jimw@sifive.com>
2634
2635 * riscv-linux-nat.c: Include elf/common.h instead of elf.h.
2636 (riscv_linux_nat_target::fetch_registers): Use NT_FPREGSET instead
2637 of NT_PRFPREG.
2638 (riscv_linux_nat_target::store_registers): Likewise.
2639
2640 2018-08-29 Sergio Durigan Junior <sergiodj@redhat.com>
2641
2642 PR gdb/23555
2643 PR gdb/23558
2644 * gnulib/aclocal.m4: Regenerate.
2645 * gnulib/config.in: Regenerate.
2646 * gnulib/configure: Regenerate.
2647 * gnulib/import/Makefile.am: Update.
2648 * gnulib/import/Makefile.in: Update.
2649 * gnulib/import/extra/snippet/_Noreturn.h: Rename to...
2650 * gnulib/import/_Noreturn.h: ... this.
2651 * gnulib/import/alloca.in.h: Update.
2652 * gnulib/import/extra/snippet/arg-nonnull.h: Rename to...
2653 * gnulib/import/arg-nonnull.h: ... this.
2654 * gnulib/import/assure.h: Update.
2655 * gnulib/import/at-func.c: Update.
2656 * gnulib/import/basename-lgpl.c: Update.
2657 * gnulib/import/extra/snippet/c++defs.h: Rename to...
2658 * gnulib/import/c++defs.h: ... this.
2659 * gnulib/import/canonicalize-lgpl.c: Update.
2660 * gnulib/import/cdefs.h: Update.
2661 * gnulib/import/chdir-long.c: Update.
2662 * gnulib/import/chdir-long.h: Update.
2663 * gnulib/import/cloexec.c: Update.
2664 * gnulib/import/cloexec.h: Update.
2665 * gnulib/import/close.c: Update.
2666 * gnulib/import/closedir.c: Update.
2667 * gnulib/import/config.charset: Update.
2668 * gnulib/import/dirent-private.h: Update.
2669 * gnulib/import/dirent.in.h: Update.
2670 * gnulib/import/dirfd.c: Update.
2671 * gnulib/import/dirname-lgpl.c: Update.
2672 * gnulib/import/dirname.h: Update.
2673 * gnulib/import/dosname.h: Update.
2674 * gnulib/import/dup-safer-flag.c: Update.
2675 * gnulib/import/dup-safer.c: Update.
2676 * gnulib/import/dup.c: Update.
2677 * gnulib/import/dup2.c: Update.
2678 * gnulib/import/errno.in.h: Update.
2679 * gnulib/import/error.c: Update.
2680 * gnulib/import/error.h: Update.
2681 * gnulib/import/exitfail.c: Update.
2682 * gnulib/import/exitfail.h: Update.
2683 * gnulib/import/extra/update-copyright: Update.
2684 * gnulib/import/fchdir.c: Update.
2685 * gnulib/import/fcntl.c: Update.
2686 * gnulib/import/fcntl.in.h: Update.
2687 * gnulib/import/fd-hook.c: Update.
2688 * gnulib/import/fd-hook.h: Update.
2689 * gnulib/import/fd-safer-flag.c: Update.
2690 * gnulib/import/fd-safer.c: Update.
2691 * gnulib/import/fdopendir.c: Update.
2692 * gnulib/import/filename.h: Update.
2693 * gnulib/import/filenamecat-lgpl.c: Update.
2694 * gnulib/import/filenamecat.h: Update.
2695 * gnulib/import/flexmember.h: Update.
2696 * gnulib/import/float+.h: Update.
2697 * gnulib/import/float.c: Update.
2698 * gnulib/import/float.in.h: Update.
2699 * gnulib/import/fnmatch.c: Update.
2700 * gnulib/import/fnmatch.in.h: Update.
2701 * gnulib/import/fnmatch_loop.c: Update.
2702 * gnulib/import/fpucw.h: Update.
2703 * gnulib/import/frexp.c: Update.
2704 * gnulib/import/frexpl.c: Update.
2705 * gnulib/import/fstat.c: Update.
2706 * gnulib/import/fstatat.c: Update.
2707 * gnulib/import/getcwd-lgpl.c: Update.
2708 * gnulib/import/getcwd.c: Update.
2709 * gnulib/import/getdtablesize.c: Update.
2710 * gnulib/import/getlogin_r.c: Update.
2711 * gnulib/import/getprogname.c: Update.
2712 * gnulib/import/getprogname.h: Update.
2713 * gnulib/import/gettext.h: Update.
2714 * gnulib/import/gettimeofday.c: Update.
2715 * gnulib/import/glob-libc.h: Update.
2716 * gnulib/import/glob.c: Update.
2717 * gnulib/import/glob.in.h: Update.
2718 * gnulib/import/glob_internal.h: Update.
2719 * gnulib/import/glob_pattern_p.c: Update.
2720 * gnulib/import/globfree.c: Update.
2721 * gnulib/import/hard-locale.c: Update.
2722 * gnulib/import/hard-locale.h: Update.
2723 * gnulib/import/intprops.h: Update.
2724 * gnulib/import/inttypes.in.h: Update.
2725 * gnulib/import/isnan.c: Update.
2726 * gnulib/import/isnand-nolibm.h: Update.
2727 * gnulib/import/isnand.c: Update.
2728 * gnulib/import/isnanl-nolibm.h: Update.
2729 * gnulib/import/isnanl.c: Update.
2730 * gnulib/import/itold.c: Update.
2731 * gnulib/import/libc-config.h: Update.
2732 * gnulib/import/limits.in.h: Update.
2733 * gnulib/import/localcharset.c: Update.
2734 * gnulib/import/localcharset.h: Update.
2735 * gnulib/import/localtime-buffer.c: Update.
2736 * gnulib/import/localtime-buffer.h: Update.
2737 * gnulib/import/lstat.c: Update.
2738 * gnulib/import/m4/00gnulib.m4: Update.
2739 * gnulib/import/m4/__inline.m4: Update.
2740 * gnulib/import/m4/absolute-header.m4: Update.
2741 * gnulib/import/m4/alloca.m4: Update.
2742 * gnulib/import/m4/builtin-expect.m4: Update.
2743 * gnulib/import/m4/canonicalize.m4: Update.
2744 * gnulib/import/m4/chdir-long.m4: Update.
2745 * gnulib/import/m4/close.m4: Update.
2746 * gnulib/import/m4/closedir.m4: Update.
2747 * gnulib/import/m4/configmake.m4: Update.
2748 * gnulib/import/m4/d-ino.m4: Update.
2749 * gnulib/import/m4/d-type.m4: Update.
2750 * gnulib/import/m4/dirent_h.m4: Update.
2751 * gnulib/import/m4/dirfd.m4: Update.
2752 * gnulib/import/m4/dirname.m4: Update.
2753 * gnulib/import/m4/double-slash-root.m4: Update.
2754 * gnulib/import/m4/dup.m4: Update.
2755 * gnulib/import/m4/dup2.m4: Update.
2756 * gnulib/import/m4/eealloc.m4: Update.
2757 * gnulib/import/m4/environ.m4: Update.
2758 * gnulib/import/m4/errno_h.m4: Update.
2759 * gnulib/import/m4/error.m4: Update.
2760 * gnulib/import/m4/exponentd.m4: Update.
2761 * gnulib/import/m4/exponentl.m4: Update.
2762 * gnulib/import/m4/extensions.m4: Update.
2763 * gnulib/import/m4/extern-inline.m4: Update.
2764 * gnulib/import/m4/fchdir.m4: Update.
2765 * gnulib/import/m4/fcntl-o.m4: Update.
2766 * gnulib/import/m4/fcntl.m4: Update.
2767 * gnulib/import/m4/fcntl_h.m4: Update.
2768 * gnulib/import/m4/fdopendir.m4: Update.
2769 * gnulib/import/m4/filenamecat.m4: Update.
2770 * gnulib/import/m4/flexmember.m4: Update.
2771 * gnulib/import/m4/float_h.m4: Update.
2772 * gnulib/import/m4/fnmatch.m4: Update.
2773 * gnulib/import/m4/fnmatch_h.m4: Update.
2774 * gnulib/import/m4/fpieee.m4: Update.
2775 * gnulib/import/m4/frexp.m4: Update.
2776 * gnulib/import/m4/frexpl.m4: Update.
2777 * gnulib/import/m4/fstat.m4: Update.
2778 * gnulib/import/m4/fstatat.m4: Update.
2779 * gnulib/import/m4/getcwd-abort-bug.m4: Update.
2780 * gnulib/import/m4/getcwd-path-max.m4: Update.
2781 * gnulib/import/m4/getcwd.m4: Update.
2782 * gnulib/import/m4/getdtablesize.m4: Update.
2783 * gnulib/import/m4/getlogin.m4: Update.
2784 * gnulib/import/m4/getlogin_r.m4: Update.
2785 * gnulib/import/m4/getpagesize.m4: Update.
2786 * gnulib/import/m4/getprogname.m4: Update.
2787 * gnulib/import/m4/gettimeofday.m4: Update.
2788 * gnulib/import/m4/glibc21.m4: Update.
2789 * gnulib/import/m4/glob.m4: Update.
2790 * gnulib/import/m4/glob_h.m4: Update.
2791 * gnulib/import/m4/gnulib-cache.m4: Update.
2792 * gnulib/import/m4/gnulib-common.m4: Update.
2793 * gnulib/import/m4/gnulib-comp.m4: Update.
2794 * gnulib/import/m4/gnulib-tool.m4: Update.
2795 * gnulib/import/m4/hard-locale.m4: Update.
2796 * gnulib/import/m4/include_next.m4: Update.
2797 * gnulib/import/m4/inttypes-pri.m4: Update.
2798 * gnulib/import/m4/inttypes.m4: Update.
2799 * gnulib/import/m4/isnand.m4: Update.
2800 * gnulib/import/m4/isnanl.m4: Update.
2801 * gnulib/import/m4/largefile.m4: Update.
2802 * gnulib/import/m4/limits-h.m4: Update.
2803 * gnulib/import/m4/localcharset.m4: Update.
2804 * gnulib/import/m4/locale-fr.m4: Update.
2805 * gnulib/import/m4/locale-ja.m4: Update.
2806 * gnulib/import/m4/locale-zh.m4: Update.
2807 * gnulib/import/m4/localtime-buffer.m4: Update.
2808 * gnulib/import/m4/longlong.m4: Update.
2809 * gnulib/import/m4/lstat.m4: Update.
2810 * gnulib/import/m4/malloc.m4: Update.
2811 * gnulib/import/m4/malloca.m4: Update.
2812 * gnulib/import/m4/math_h.m4: Update.
2813 * gnulib/import/m4/mbrtowc.m4: Update.
2814 * gnulib/import/m4/mbsinit.m4: Update.
2815 * gnulib/import/m4/mbsrtowcs.m4: Update.
2816 * gnulib/import/m4/mbstate_t.m4: Update.
2817 * gnulib/import/m4/memchr.m4: Update.
2818 * gnulib/import/m4/memmem.m4: Update.
2819 * gnulib/import/m4/mempcpy.m4: Update.
2820 * gnulib/import/m4/memrchr.m4: Update.
2821 * gnulib/import/m4/mkdir.m4: Update.
2822 * gnulib/import/m4/mkstemp.m4: Update.
2823 * gnulib/import/m4/mmap-anon.m4: Update.
2824 * gnulib/import/m4/mode_t.m4: Update.
2825 * gnulib/import/m4/msvc-inval.m4: Update.
2826 * gnulib/import/m4/msvc-nothrow.m4: Update.
2827 * gnulib/import/m4/multiarch.m4: Update.
2828 * gnulib/import/m4/nocrash.m4: Update.
2829 * gnulib/import/m4/off_t.m4: Update.
2830 * gnulib/import/m4/onceonly.m4: Update.
2831 * gnulib/import/m4/open-cloexec.m4: Update.
2832 * gnulib/import/m4/open.m4: Update.
2833 * gnulib/import/m4/openat.m4: Update.
2834 * gnulib/import/m4/opendir.m4: Update.
2835 * gnulib/import/m4/pathmax.m4: Update.
2836 * gnulib/import/m4/rawmemchr.m4: Update.
2837 * gnulib/import/m4/readdir.m4: Update.
2838 * gnulib/import/m4/readlink.m4: Update.
2839 * gnulib/import/m4/realloc.m4: Update.
2840 * gnulib/import/m4/rename.m4: Update.
2841 * gnulib/import/m4/rewinddir.m4: Update.
2842 * gnulib/import/m4/rmdir.m4: Update.
2843 * gnulib/import/m4/save-cwd.m4: Update.
2844 * gnulib/import/m4/secure_getenv.m4: Update.
2845 * gnulib/import/m4/setenv.m4: Update.
2846 * gnulib/import/m4/signal_h.m4: Update.
2847 * gnulib/import/m4/ssize_t.m4: Update.
2848 * gnulib/import/m4/stat-time.m4: Update.
2849 * gnulib/import/m4/stat.m4: Update.
2850 * gnulib/import/m4/std-gnu11.m4: Update.
2851 * gnulib/import/m4/stdbool.m4: Update.
2852 * gnulib/import/m4/stddef_h.m4: Update.
2853 * gnulib/import/m4/stdint.m4: Update.
2854 * gnulib/import/m4/stdio_h.m4: Update.
2855 * gnulib/import/m4/stdlib_h.m4: Update.
2856 * gnulib/import/m4/strchrnul.m4: Update.
2857 * gnulib/import/m4/strdup.m4: Update.
2858 * gnulib/import/m4/strerror.m4: Update.
2859 * gnulib/import/m4/string_h.m4: Update.
2860 * gnulib/import/m4/strstr.m4: Update.
2861 * gnulib/import/m4/strtok_r.m4: Update.
2862 * gnulib/import/m4/sys_socket_h.m4: Update.
2863 * gnulib/import/m4/sys_stat_h.m4: Update.
2864 * gnulib/import/m4/sys_time_h.m4: Update.
2865 * gnulib/import/m4/sys_types_h.m4: Update.
2866 * gnulib/import/m4/tempname.m4: Update.
2867 * gnulib/import/m4/time_h.m4: Update.
2868 * gnulib/import/m4/unistd-safer.m4: Update.
2869 * gnulib/import/m4/unistd_h.m4: Update.
2870 * gnulib/import/m4/warn-on-use.m4: Update.
2871 * gnulib/import/m4/wchar_h.m4: Update.
2872 * gnulib/import/m4/wchar_t.m4: Update.
2873 * gnulib/import/m4/wctype_h.m4: Update.
2874 * gnulib/import/m4/wint_t.m4: Update.
2875 * gnulib/import/malloc.c: Update.
2876 * gnulib/import/malloc/scratch_buffer.h: Update.
2877 * gnulib/import/malloc/scratch_buffer_grow.c: Update.
2878 * gnulib/import/malloc/scratch_buffer_grow_preserve.c: Update.
2879 * gnulib/import/malloc/scratch_buffer_set_array_size.c: Update.
2880 * gnulib/import/malloca.c: Update.
2881 * gnulib/import/malloca.h: Update.
2882 * gnulib/import/malloca.valgrind: Update.
2883 * gnulib/import/math.in.h: Update.
2884 * gnulib/import/mbrtowc.c: Update.
2885 * gnulib/import/mbsinit.c: Update.
2886 * gnulib/import/mbsrtowcs-impl.h: Update.
2887 * gnulib/import/mbsrtowcs-state.c: Update.
2888 * gnulib/import/mbsrtowcs.c: Update.
2889 * gnulib/import/memchr.c: Update.
2890 * gnulib/import/memmem.c: Update.
2891 * gnulib/import/mempcpy.c: Update.
2892 * gnulib/import/memrchr.c: Update.
2893 * gnulib/import/mkdir.c: Update.
2894 * gnulib/import/mkstemp.c: Update.
2895 * gnulib/import/msvc-inval.c: Update.
2896 * gnulib/import/msvc-inval.h: Update.
2897 * gnulib/import/msvc-nothrow.c: Update.
2898 * gnulib/import/msvc-nothrow.h: Update.
2899 * gnulib/import/open.c: Update.
2900 * gnulib/import/openat-die.c: Update.
2901 * gnulib/import/openat-priv.h: Update.
2902 * gnulib/import/openat-proc.c: Update.
2903 * gnulib/import/openat.c: Update.
2904 * gnulib/import/openat.h: Update.
2905 * gnulib/import/opendir.c: Update.
2906 * gnulib/import/pathmax.h: Update.
2907 * gnulib/import/pipe-safer.c: Update.
2908 * gnulib/import/rawmemchr.c: Update.
2909 * gnulib/import/readdir.c: Update.
2910 * gnulib/import/readlink.c: Update.
2911 * gnulib/import/realloc.c: Update.
2912 * gnulib/import/ref-add.sin: Update.
2913 * gnulib/import/ref-del.sin: Update.
2914 * gnulib/import/rename.c: Update.
2915 * gnulib/import/rewinddir.c: Update.
2916 * gnulib/import/rmdir.c: Update.
2917 * gnulib/import/same-inode.h: Update.
2918 * gnulib/import/save-cwd.c: Update.
2919 * gnulib/import/save-cwd.h: Update.
2920 * gnulib/import/scratch_buffer.h: Update.
2921 * gnulib/import/secure_getenv.c: Update.
2922 * gnulib/import/setenv.c: Update.
2923 * gnulib/import/signal.in.h: Update.
2924 * gnulib/import/stat-time.c: Update.
2925 * gnulib/import/stat-time.h: Update.
2926 * gnulib/import/stat-w32.c: Update.
2927 * gnulib/import/stat-w32.h: Update.
2928 * gnulib/import/stat.c: Update.
2929 * gnulib/import/stdbool.in.h: Update.
2930 * gnulib/import/stddef.in.h: Update.
2931 * gnulib/import/stdint.in.h: Update.
2932 * gnulib/import/stdio.in.h: Update.
2933 * gnulib/import/stdlib.in.h: Update.
2934 * gnulib/import/str-two-way.h: Update.
2935 * gnulib/import/strchrnul.c: Update.
2936 * gnulib/import/strdup.c: Update.
2937 * gnulib/import/streq.h: Update.
2938 * gnulib/import/strerror-override.c: Update.
2939 * gnulib/import/strerror-override.h: Update.
2940 * gnulib/import/strerror.c: Update.
2941 * gnulib/import/string.in.h: Update.
2942 * gnulib/import/stripslash.c: Update.
2943 * gnulib/import/strnlen1.c: Update.
2944 * gnulib/import/strnlen1.h: Update.
2945 * gnulib/import/strstr.c: Update.
2946 * gnulib/import/strtok_r.c: Update.
2947 * gnulib/import/sys_stat.in.h: Update.
2948 * gnulib/import/sys_time.in.h: Update.
2949 * gnulib/import/sys_types.in.h: Update.
2950 * gnulib/import/tempname.c: Update.
2951 * gnulib/import/tempname.h: Update.
2952 * gnulib/import/time.in.h: Update.
2953 * gnulib/import/unistd--.h: Update.
2954 * gnulib/import/unistd-safer.h: Update.
2955 * gnulib/import/unistd.in.h: Update.
2956 * gnulib/import/unsetenv.c: Update.
2957 * gnulib/import/verify.h: Update.
2958 * gnulib/import/extra/snippet/warn-on-use.h: Update.
2959 * gnulib/import/wchar.in.h: Update.
2960 * gnulib/import/wctype.in.h: Update.
2961 * gnulib/import/xalloc-oversized.h: Update.
2962 * gnulib/update-gnulib.sh (GNULIB_COMMIT_SHA1): Set to
2963 "53e2c179f26a890fa6685af4b6c1397ee370433b".
2964
2965 2018-08-16 Gary Benson <gbenson@redhat.com>
2966
2967 PR gdb/13000:
2968 * gdb/main.c (captured_main_1): Exit with nonzero status
2969 in batch mode if the last command to be executed failed.
2970 * NEWS: Mention the above.
2971
2972 2018-08-29 Simon Marchi <simon.marchi@ericsson.com>
2973
2974 * csky-tdep.c (csky_memory_insert_breakpoint): Remove newline at
2975 end of warning message.
2976
2977 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2978
2979 PR gdb/22943:
2980 * aarch64-tdep.c (is_hfa_or_hva): Remove function.
2981 (aarch64_extract_return_value): Use
2982 aapcs_is_vfp_call_or_return_candidate.
2983 (aarch64_return_in_memory): Likewise.
2984 (aarch64_store_return_value): Likewise.
2985
2986 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2987
2988 * aarch64-tdep.c
2989 (aapcs_is_vfp_call_or_return_candidate): Make static
2990 (pass_in_v_or_stack): Remove function.
2991 (pass_in_v_vfp_candidate): New function.
2992 (aarch64_push_dummy_call): Check for float register candidates.
2993
2994 2018-08-29 Alan Hayward <alan.hayward@arm.com>
2995
2996 * aarch64-tdep.c (HA_MAX_NUM_FLDS): New macro.
2997 (aapcs_is_vfp_call_or_return_candidate_1): New function.
2998 (aapcs_is_vfp_call_or_return_candidate): Likewise.
2999
3000 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
3001
3002 PR build/23399
3003 * common/agent.c (IPA_SYM_STRUCT_NAME): Define.
3004 (struct ipa_sym_addresses): Rename to...
3005 (struct ipa_sym_addresses_common): ... this.
3006 * common/agent.h (IPA_SYM): Use IPA_SYM_STRUCT_NAME.
3007
3008 2018-08-28 Tom Tromey <tom@tromey.com>
3009
3010 * c-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3011 (token_fifo): Now a std::vector.
3012 (yylex, c_parse): Update.
3013 * d-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3014 (token_fifo): Now a std::vector.
3015 (yylex, d_parse): Update.
3016 * go-exp.y (struct token_and_value): Remove typedef and DEF_VEC.
3017 (token_fifo): Now a std::vector.
3018 (yylex, go_parse): Update.
3019
3020 2018-08-28 Simon Marchi <simon.marchi@ericsson.com>
3021
3022 * parser-defs.h (struct type_stack) <elements>: Change type to
3023 std::vector<union type_stack_elt>.
3024 <depth, size>: Remove.
3025 * parse.c (parse_exp_in_context_1): Adjust.
3026 (type_stack_reserve): Remove.
3027 (check_type_stack_depth): Remove.
3028 (insert_into_type_stack): Adjust to std::vector.
3029 (insert_type): Likewise.
3030 (push_type): Likewise.
3031 (push_type_int): Likewise.
3032 (insert_type_address_space): Likewise.
3033 (pop_type): Likewise.
3034 (pop_type_int): Likewise.
3035 (pop_typelist): Likewise.
3036 (pop_type_stack): Likewise.
3037 (append_type_stack): Likewise.
3038 (push_type_stack): Likewise.
3039 (get_type_stack): Likewise.
3040 (type_stack_cleanup): Likewise.
3041 (push_typelist): Likewise.
3042 (follow_types): Likewise.
3043 (_initialize_parse): Likewise.
3044
3045 2018-08-28 Hafiz Abid Qadeer <abidh@codesourcery.com>
3046
3047 * NEWS: Mention csky target.
3048
3049 2018-08-28 Jiangshuai Li <jiangshuai_li@c-sky.com>
3050 Hafiz Abid Qadeer <abidh@codesourcery.com>
3051 Don Breazeal <donb@codesourcery.com>
3052
3053 * csky-linux-tdep.c: New file.
3054 * csky-tdep.c: Likewise.
3055 * csky-tdep.h: Likewise.
3056 * Makefile.in (ALL_TARGET_OBS): Add csky-linux-tdep.o and
3057 csky-tdep.o.
3058 (HFILES_NO_SRCDIR): Add csky-tdep.h.
3059 (ALLDEPFILES): Add csky-linux-tdep.c and csky-tdep.c
3060 * configure.tgt: Add csky support.
3061
3062 2018-08-27 Jan Vrany <jan.vrany@fit.cvut.cz>
3063
3064 * python/py-framefilter.c (py_print_frame): Print frame architecture
3065 when printing on an MI output.
3066
3067 2018-08-27 Tom Tromey <tom@tromey.com>
3068
3069 PR build/23087:
3070 * configure: Rebuild.
3071 * warning.m4 (AM_GDB_WARNINGS): Remove -Wno-narrowing.
3072
3073 2018-08-27 Tom Tromey <tom@tromey.com>
3074
3075 * aarch64-linux-tdep.c
3076 (aarch64_linux_iterate_over_regset_sections) <sve_regmap>: Add
3077 casts to int.
3078
3079 2018-08-27 Tom Tromey <tom@tromey.com>
3080
3081 * ppc64-tdep.c (insn_d, insn_ds, insn_xfx): Add casts to
3082 unsigned.
3083 (ppc64_standard_linkage1, ppc64_standard_linkage2)
3084 (ppc64_standard_linkage3, ppc64_standard_linkage4)
3085 (ppc64_standard_linkage5, ppc64_standard_linkage6)
3086 (ppc64_standard_linkage7, ppc64_standard_linkage8): Add casts to
3087 unsigned.
3088
3089 2018-08-27 Tom Tromey <tom@tromey.com>
3090
3091 * xtensa-tdep.h (XTREG_END): Add cast to unsigned.
3092 (XTENSA_GDBARCH_TDEP_INSTANTIATE): Likewise.
3093
3094 2018-08-27 Tom Tromey <tom@tromey.com>
3095
3096 * tramp-frame.h (TRAMP_SENTINEL_INSN): Redefine.
3097 * tilegx-linux-tdep.c (tilegx_linux_rt_sigframe): Use
3098 ULONGEST_MAX.
3099 * tic6x-linux-tdep.c (tic6x_linux_rt_sigreturn_tramp_frame): Use
3100 ULONGEST_MAX.
3101 * sparc64-linux-tdep.c (sparc64_linux_rt_sigframe): Use
3102 ULONGEST_MAX.
3103 * sparc-linux-tdep.c (sparc32_linux_sigframe)
3104 (sparc32_linux_rt_sigframe): Use ULONGEST_MAX.
3105 * ppc-nbsd-tdep.c (ppcnbsd_sigtramp, ppcnbsd2_sigtramp): Use
3106 ULONGEST_MAX.
3107 * ppc-linux-tdep.c (ppc32_linux_sigaction_tramp_frame)
3108 (ppc64_linux_sigaction_tramp_frame)
3109 (ppc32_linux_sighandler_tramp_frame)
3110 (ppc64_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
3111 * nios2-linux-tdep.c (nios2_r1_linux_rt_sigreturn_tramp_frame)
3112 (nios2_r2_linux_rt_sigreturn_tramp_frame): Use ULONGEST_MAX.
3113 * mn10300-linux-tdep.c (am33_linux_sigframe)
3114 (am33_linux_rt_sigframe): Use ULONGEST_MAX.
3115 * mips64-obsd-tdep.c (mips64obsd_sigframe): Use ULONGEST_MAX.
3116 * mips-linux-tdep.c (mips_linux_o32_sigframe)
3117 (mips_linux_o32_rt_sigframe, mips_linux_n32_rt_sigframe)
3118 (mips_linux_n64_rt_sigframe, micromips_linux_o32_sigframe)
3119 (micromips_linux_o32_rt_sigframe, micromips_linux_n32_rt_sigframe)
3120 (micromips_linux_n64_rt_sigframe): Use ULONGEST_MAX.
3121 * mips-fbsd-tdep.c (mips_fbsd_sigframe, mipsn32_fbsd_sigframe)
3122 (mips64_fbsd_sigframe): Use ULONGEST_MAX.
3123 * microblaze-linux-tdep.c
3124 (microblaze_linux_sighandler_tramp_frame): Use ULONGEST_MAX.
3125 * i386-nbsd-tdep.c (i386nbsd_sigtramp_sc16, i386nbsd_sigtramp_sc2)
3126 (i386nbsd_sigtramp_si2, i386nbsd_sigtramp_si31)
3127 (i386nbsd_sigtramp_si4): Use ULONGEST_MAX.
3128 * hppa-nbsd-tdep.c (hppanbsd_sigtramp_si4): Use ULONGEST_MAX.
3129 * common/common-types.h (ULONGEST_MAX): New define.
3130 (CORE_ADDR_MAX): Fix formatting.
3131 * bfin-linux-tdep.c (bfin_linux_sigframe): Use ULONGEST_MAX.
3132 * arm-obsd-tdep.c (armobsd_sigframe): Use ULONGEST_MAX.
3133 * arm-linux-tdep.c (arm_linux_sigreturn_tramp_frame)
3134 (arm_linux_rt_sigreturn_tramp_frame)
3135 (arm_eabi_linux_sigreturn_tramp_frame)
3136 (arm_eabi_linux_rt_sigreturn_tramp_frame)
3137 (thumb2_eabi_linux_sigreturn_tramp_frame)
3138 (thumb2_eabi_linux_rt_sigreturn_tramp_frame)
3139 (arm_linux_restart_syscall_tramp_frame)
3140 (arm_kernel_linux_restart_syscall_tramp_frame): Use ULONGEST_MAX.
3141 * arm-fbsd-tdep.c (arm_fbsd_sigframe): Use ULONGEST_MAX.
3142 * aarch64-linux-tdep.c (aarch64_linux_rt_sigframe): Use
3143 ULONGEST_MAX.
3144 * aarch64-fbsd-tdep.c (aarch64_fbsd_sigframe): Use ULONGEST_MAX.
3145
3146 2018-08-27 Tom Tromey <tom@tromey.com>
3147
3148 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Use
3149 CORE_ADDR_MAX.
3150 * mips-tdep.c (mips_deal_with_atomic_sequence)
3151 (micromips_deal_with_atomic_sequence): Use CORE_ADDR_MAX.
3152 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw)
3153 (arm_deal_with_atomic_sequence_raw): Use CORE_ADDR_MAX.
3154 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Use
3155 CORE_ADDR_MAX.
3156 * aarch64-tdep.c (aarch64_software_single_step): Use
3157 CORE_ADDR_MAX.
3158
3159 2018-08-27 Tom Tromey <tom@tromey.com>
3160
3161 * linespec.c (complete_linespec_component): Add cast to "char".
3162 * completer.c (completion_tracker::build_completion_result): Add
3163 cast to "char".
3164
3165 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3166
3167 * solist.h (struct solist, struct target_so_ops): Fix
3168 indentation.
3169
3170 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3171
3172 * ada-tasks.c (ada_task_info_s): Remove typedef.
3173 (DEF_VEC_O(ada_task_info_s)): Remove.
3174 (struct ada_tasks_inferior_data): Initialize fields.
3175 <task_list>: Make an std::vector.
3176 (get_ada_tasks_inferior_data): Allocate with new.
3177 (ada_get_task_number): Adjust.
3178 (get_task_number_from_id): Likewise.
3179 (valid_task_id): Likewise.
3180 (ada_get_task_info_from_ptid): Likewise.
3181 (iterate_over_live_ada_tasks): Likewise.
3182 (add_ada_task): Likewise.
3183 (read_known_tasks): Likewise.
3184 (ada_build_task_list): Likewise.
3185 (print_ada_task_info): Likewise.
3186 (info_task): Likewise.
3187 (task_command_1): Likewise.
3188
3189 2018-08-26 Simon Marchi <simon.marchi@polymtl.ca>
3190
3191 * ada-lang.c (add_angle_brackets): Return std::string.
3192
3193 2018-08-25 Simon Marchi <simon.marchi@polymtl.ca>
3194
3195 * python/py-threadevent.c (py_get_event_thread): Initialize
3196 pythread.
3197
3198 2018-08-24 Pedro Alves <palves@redhat.com>
3199
3200 * python/py-bpevent.c (create_breakpoint_event_object): Use
3201 copy-initialization.
3202 * python/py-continueevent.c (emit_continue_event): Use
3203 copy-initialization.
3204 * python/py-exitedevent.c (create_exited_event_object): Return a
3205 gdbpy_ref<>.
3206 (emit_exited_event): Use copy-initialization.
3207 * python/py-inferior.c (python_new_inferior)
3208 (python_inferior_deleted, add_thread_object): Use
3209 copy-initialization.
3210 * python/py-infevents.c (create_inferior_call_event_object)
3211 (create_register_changed_event_object)
3212 (create_memory_changed_event_object): Return a gdbpy_ref<>.
3213 (emit_inferior_call_event, emit_memory_changed_event)
3214 (emit_register_changed_event): Use copy-initialization.
3215 * python/py-newobjfileevent.c (create_new_objfile_event_object):
3216 Return a gdbpy_ref<>.
3217 (emit_new_objfile_event): Use copy-initialization.
3218 (create_clear_objfiles_event_object): Return a gdbpy_ref<>.
3219 (emit_clear_objfiles_event): Use copy-initialization.
3220 * python/py-signalevent.c (create_signal_event_object): Use
3221 copy-initialization.
3222 * python/py-threadevent.c (create_thread_event_object): Use
3223 copy-initialization.
3224
3225 2018-08-24 Pedro Alves <palves@redhat.com>
3226 Simon Marchi <simon.marchi@ericsson.com>
3227
3228 PR gdb/23379
3229 * python/py-continueevent.c: Include "gdbthread.h".
3230 (create_continue_event_object): Add intro comment. Add 'ptid'
3231 parameter. Use it to find thread to pass to
3232 create_thread_event_object.
3233 (emit_continue_event): Pass PTID down to
3234 create_continue_event_object.
3235 * python/py-event.h (py_get_event_thread): Declare.
3236 (create_thread_event_object): Remove default from 'thread'
3237 parameter.
3238 * python/py-stopevent.c (create_stop_event_object): Use
3239 py_get_event_thread.
3240 * python/py-threadevent.c (get_event_thread): Rename to ...
3241 (py_get_event_thread): ... this, make extern, add 'ptid' parameter
3242 and use it to find the thread.
3243 (create_thread_event_object): Assert that THREAD isn't null.
3244 Don't find the event thread here.
3245
3246 2018-08-23 Kevin Buettner <kevinb@redhat.com>
3247
3248 * block.h (blockrange, blockranges): New struct declarations.
3249 (struct block): Add new field named `ranges'.
3250 (BLOCK_RANGES, BLOCK_NRANGES, BLOCK_RANGE, BLOCK_CONTIGUOUS_P)
3251 (BLOCK_RANGE_START, BLOCK_RANGE_END, BLOCK_ENTRY_PC): New
3252 macros for accessing ranges in struct block.
3253 (make_blockranges): New declaration.
3254 block.c (make_blockranges): New function.
3255 * dwarf2read.c (dwarf2_record_block_ranges): Fill in BLOCK_RANGES
3256 for block.
3257 * symtab.h (find_pc_partial_function): Add new parameter `block'.
3258 * blockframe.c (cache_pc_function_block): New static global.
3259 (clear_pc_function_cache): Clear cache_pc_function_block.
3260 (find_pc_partial_function): Move comment to symtab.h. Add
3261 support for non-contiguous blocks.
3262 * cli/cli-cmds.c (block.h): Include.
3263 (print_disassembly): Handle printing of non-contiguous blocks.
3264 (disassemble_current_function): Likewise.
3265 (disassemble_command): Likewise.
3266
3267 * ax-gdb.c (gen_var_ref): Use BLOCK_ENTRY_PC in place of
3268 BLOCK_START.
3269 * blockframe.c (get_pc_function_start): Likewise.
3270 * compile/compile-c-symbols.c (convert_one_symbol): Likewise.
3271 (gcc_symbol_address): Likewise.
3272 * compile/compile-object-run.c (compile_object_run): Likewise.
3273 * compile/compile.c (get_expr_block_and_pc): Likewise.
3274 * dwarf2loc.c (dwarf2_find_location_expression): Likewise.
3275 (func_addr_to_tail_call_list): Likewise.
3276 * findvar.c (default_read_var_value): Likewise.
3277 * inline-frame.c (inline_frame_this_id): Likewise.
3278 (skip-inline_frames): Likewise.
3279 * infcmd.c (until_next_command): Likewise.
3280 * linespec.c (convert_linespec_to_sals): Likewise.
3281 * parse.c (parse_exp_in_context_1): Likewise.
3282 * printcmd.c (build_address_symbolic): likewise.
3283 (info_address_command): Likewise.
3284 symtab.c (find_function_start_sal): Likewise.
3285 (skip_prologue_sal): Likewise.
3286 (find_function_alias_target): Likewise.
3287 (find_gnu_ifunc): Likewise.
3288 * stack.c (find_frame_funname): Likewise.
3289 * symtab.c (fixup_symbol_section): Likewise.
3290 (find_function_start_sal): Likewise.
3291 (skip_prologue_sal): Likewsie.
3292 (find_function_alias_target): Likewise.
3293 (find_gnu_ifunc): Likewise.
3294 * tracepoint.c (info_scope_command): Likewise.
3295 * value.c (value_fn_field): Likewise.
3296
3297 * infrun.c (fill_in_stop_func): Use find_function_entry_range_from_pc
3298 in place of find_pc_partial_function.
3299 * blockframe.c (find_function_entry_range_from_pc): New function.
3300 * symtab.h (find_function_entry_range_from_pc): Declare and document.
3301 * objfiles.c (objfile_relocate1): Relocate start and end addresses
3302 for each range in a block.
3303
3304
3305 2018-08-23 Xavier Roirand <roirand@adacore.com>
3306
3307 * machoread.c (macho_symfile_read_all_oso): Remove uneeded
3308 incrementation.
3309
3310 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3311
3312 * solib-svr4.c (read_program_headers_from_bfd): Return
3313 gdb::optional<gdb::byte_vector>.
3314 (svr4_exec_displacement): Adjust.
3315
3316 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3317
3318 * solib-svr4.c (read_program_header): Return
3319 gdb::optional<gdb::byte_vector>, remove p_sect_size param.
3320 (find_program_interpreter): Return
3321 gdb::optional<gdb::byte_vector>.
3322 (scan_dyntag_auxv): Adjust.
3323 (enable_break): Adjust.
3324 (svr4_exec_displacement): Adjust.
3325
3326 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3327
3328 * inf-child.h (inf_child_target) <terminal_save_inferior>: New.
3329 * inf-child.c (inf_child_target::terminal_save_inferior): New.
3330
3331 2018-08-22 Simon Marchi <simon.marchi@polymtl.ca>
3332
3333 * guile/scm-string.c (gdbscm_scm_from_printf): Use
3334 string_vprintf.
3335 * guile/scm-utils.c (gdbscm_printf): Likewise.
3336 * serial.c (serial_printf): Likewise.
3337 * xml-support.c (gdb_xml_parser::vdebug): Likewise.
3338
3339 2018-08-22 Jan Vrany <jan.vrany@fit.cvut.cz>
3340
3341 * stack.c (print_frame): Print frame architecture when printing on
3342 an MI output.
3343 * NEWS: Mention new "arch" attribute in frame output.
3344
3345 2018-08-21 Alan Hayward <alan.hayward@arm.com>
3346
3347 * arch/aarch64.h (aarch64_regnum): Update comment.
3348
3349 2018-08-21 Alan Hayward <alan.hayward@arm.com>
3350
3351 * NEWS: Add SVE to 8.2 section.
3352
3353 2018-08-21 Pedro Alves <palves@redhat.com>
3354
3355 * guile/scm-utils.c (gdbscm_parse_function_args_1): New, factored
3356 out from gdbscm_parse_function_args.
3357 (gdbscm_parse_function_args): Rework to use gdbscm_wrap and
3358 gdbscm_parse_function_args_1.
3359
3360 2018-08-21 Simon Marchi <simon.marchi@ericsson.com>
3361
3362 PR gdb/17816
3363 * m32c-tdep.c (m32c_decode_srcdest4): Remove unnecessary ternary
3364 operator.
3365
3366 2018-08-19 Simon Marchi <simon.marchi@polymtl.ca>
3367
3368 * solib-svr4.c (svr4_exec_displacement): Fix formatting.
3369
3370 2018-08-19 Michael Spang <spang@google.com>
3371
3372 PR gdb/11786
3373 * solib-svr4.c (svr4_exec_displacement): Ignore memsz fields
3374 for PT_TLS segments.
3375
3376 2018-08-18 Kevin Buettner <kevinb@redhat.com>
3377
3378 * dwarf2expr.h (struct dwarf_expr_context): Add virtual method
3379 dwarf_variable_value.
3380 * dwarf2-frame.c (class dwarf_expr_executor):
3381 Add override for dwarf_variable_value.
3382 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Likewise.
3383 (class symbol_needs_eval_context): Likewise.
3384 (indirect_synthetic_pointer): Add forward declaration.
3385 (sect_variable_value): New function.
3386 (dwarf2_compile_expr_to_ax): Add case for DW_OP_GNU_variable_value.
3387 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Add case
3388 for DW_OP_GNU_variable_value.
3389
3390 2018-08-16 Tom Tromey <tom@tromey.com>
3391
3392 * top.c (read_command_file): Update.
3393 (command_line_input): Remove "repeat" argument.
3394 * ada-lang.c (get_selections): Update.
3395 * linespec.c (decode_line_2): Update.
3396 * defs.h (command_line_input): Remove argument.
3397 * cli/cli-script.c (read_next_line): Update.
3398 * python/py-gdb-readline.c: Update.
3399
3400 2018-08-17 Tom Tromey <tom@tromey.com>
3401
3402 * cli/cli-script.c (read_next_line): Pass 0 as repeat argument to
3403 command_line_input.
3404
3405 2018-08-15 Tom Tromey <tom@tromey.com>
3406
3407 * aarch64-linux-tdep.c (aarch64_linux_core_read_vq): Use pulongest.
3408
3409 2018-08-14 Jan Vrany <jan.vrany@fit.cvut.cz>
3410
3411 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Add -a option.
3412 If used, use find_pc_partial_function to find address range
3413 to disassemble.
3414 * mi/mi-main.c (mi_cmd_list_features): Report
3415 "data-disassemble-a-option" feature.
3416 * NEWS: Mention new -data-disassemble option -a.
3417
3418 2018-08-13 Tom Tromey <tom@tromey.com>
3419
3420 * common/common-defs.h (_FORTIFY_SOURCE): Define.
3421
3422 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3423
3424 * aarch64-linux-tdep.c (aarch64_linux_supply_sve_regset): New function.
3425 (aarch64_linux_collect_sve_regset): Likewise.
3426 (aarch64_linux_iterate_over_regset_sections): Check for SVE.
3427 * regcache.h (regcache_map_entry_size): New function.
3428
3429 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3430
3431 * aarch64-linux-tdep.c (SVE_HEADER_SIZE_LENGTH): Add define.
3432 (SVE_HEADER_MAX_SIZE_LENGTH): Likewise.
3433 (SVE_HEADER_VL_LENGTH): Likewise.
3434 (SVE_HEADER_MAX_VL_LENGTH): Likewise.
3435 (SVE_HEADER_FLAGS_LENGTH): Likewise.
3436 (SVE_HEADER_RESERVED_LENGTH): Likewise.
3437 (SVE_HEADER_SIZE_OFFSET): Likewise.
3438 (SVE_HEADER_MAX_SIZE_OFFSET): Likewise.
3439 (SVE_HEADER_VL_OFFSET): Likewise.
3440 (SVE_HEADER_MAX_VL_OFFSET): Likewise.
3441 (SVE_HEADER_FLAGS_OFFSET): Likewise.
3442 (SVE_HEADER_RESERVED_OFFSET): Likewise.
3443 (SVE_HEADER_SIZE): Likewise.
3444 (aarch64_linux_core_read_vq): Add function.
3445 (aarch64_linux_core_read_description): Check for SVE section.
3446
3447 2018-08-13 Alan Hayward <alan.hayward@arm.com>
3448
3449 * aarch64-fbsd-tdep.c
3450 (aarch64_fbsd_iterate_over_regset_sections): Add supply_size and
3451 collect_size.
3452 * aarch64-linux-tdep.c
3453 (aarch64_linux_iterate_over_regset_sections): Likewise.
3454 * alpha-linux-tdep.c
3455 (alpha_linux_iterate_over_regset_sections):
3456 * alpha-nbsd-tdep.c
3457 (alphanbsd_iterate_over_regset_sections): Likewise.
3458 * amd64-fbsd-tdep.c
3459 (amd64fbsd_iterate_over_regset_sections): Likewise.
3460 * amd64-linux-tdep.c
3461 (amd64_linux_iterate_over_regset_sections): Likewise.
3462 * arm-bsd-tdep.c
3463 (armbsd_iterate_over_regset_sections): Likewise.
3464 * arm-fbsd-tdep.c
3465 (arm_fbsd_iterate_over_regset_sections): Likewise.
3466 * arm-linux-tdep.c
3467 (arm_linux_iterate_over_regset_sections): Likewise.
3468 * corelow.c (get_core_registers_cb): Likewise.
3469 (core_target::fetch_registers): Likewise.
3470 * fbsd-tdep.c (fbsd_collect_regset_section_cb): Likewise.
3471 * frv-linux-tdep.c (frv_linux_iterate_over_regset_sections): Likewise.
3472 * gdbarch.h (void): Regenerate.
3473 * gdbarch.sh: Add supply_size and collect_size.
3474 * hppa-linux-tdep.c (hppa_linux_iterate_over_regset_sections): Likewise.
3475 * hppa-nbsd-tdep.c (hppanbsd_iterate_over_regset_sections): Likewise.
3476 * hppa-obsd-tdep.c (hppaobsd_iterate_over_regset_sections): Likewise.
3477 * i386-fbsd-tdep.c (i386fbsd_iterate_over_regset_sections): Likewise.
3478 * i386-linux-tdep.c (i386_linux_iterate_over_regset_sections): Likewise.
3479 * i386-tdep.c (i386_iterate_over_regset_sections): Likewise.
3480 * ia64-linux-tdep.c (ia64_linux_iterate_over_regset_sections): Likewise.
3481 * linux-tdep.c (linux_collect_regset_section_cb): Likewise.
3482 * m32r-linux-tdep.c (m32r_linux_iterate_over_regset_sections): Likewise.
3483 * m68k-bsd-tdep.c (m68kbsd_iterate_over_regset_sections): Likewise.
3484 * m68k-linux-tdep.c (m68k_linux_iterate_over_regset_sections): Likewise.
3485 * mips-fbsd-tdep.c (mips_fbsd_iterate_over_regset_sections): Likewise.
3486 * mips-linux-tdep.c (mips_linux_iterate_over_regset_sections): Likewise.
3487 * mips-nbsd-tdep.c (mipsnbsd_iterate_over_regset_sections): Likewise.
3488 * mips64-obsd-tdep.c (mips64obsd_iterate_over_regset_sections): Likewise.
3489 * mn10300-linux-tdep.c (am33_iterate_over_regset_sections): Likewise.
3490 * nios2-linux-tdep.c (nios2_iterate_over_regset_sections): Likewise.
3491 * ppc-fbsd-tdep.c (ppcfbsd_iterate_over_regset_sections): Likewise.
3492 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections): Likewise.
3493 * ppc-nbsd-tdep.c (ppcnbsd_iterate_over_regset_sections): Likewise.
3494 * ppc-obsd-tdep.c (ppcobsd_iterate_over_regset_sections): Likewise.
3495 * riscv-linux-tdep.c (riscv_linux_iterate_over_regset_sections): Likewise.
3496 * rs6000-aix-tdep.c (rs6000_aix_iterate_over_regset_sections): Likewise.
3497 * s390-linux-tdep.c (s390_iterate_over_regset_sections): Likewise.
3498 * score-tdep.c (score7_linux_iterate_over_regset_sections): Likewise.
3499 * sh-tdep.c (sh_iterate_over_regset_sections): Likewise.
3500 * sparc-tdep.c (sparc_iterate_over_regset_sections): Likewise.
3501 * tilegx-linux-tdep.c (tilegx_iterate_over_regset_sections): Likewise.
3502 * vax-tdep.c (vax_iterate_over_regset_sections): Likewise.
3503 * xtensa-tdep.c (xtensa_iterate_over_regset_sections): Likewise.
3504
3505 2018-08-10 Simon Marchi <simon.marchi@ericsson.com>
3506
3507 * nat/linux-osdata.c (commandline_from_pid): Replace xstrprintf
3508 with string_printf.
3509
3510 2018-08-10 Keith Seitz <keiths@redhat.com>
3511
3512 * compile/compile-c-support.c (add_code_header, add_code_footer):
3513 Move into policy class.
3514 (c_push_user_expression, pop_user_expression_nop)
3515 (c_add_code_header, c_add_code_footer, c_add_input): New policy class.
3516 (compile_program): New host class.
3517 (c_compile_program): New typedef.
3518 (c_compute_porgram): Use c_compile_program.
3519
3520 2018-08-10 Keith Seitz <keiths@redhat.com>
3521
3522 * compile/compile-internal.h (compile_instance::~compile_instance):
3523 Remove calls to htab_delete.
3524 <m_type_map, m_symbol_err_map>: Switch type to htab_up.
3525 * compile.c (compile_instance::compile_instance): Initialize
3526 htab unique pointers.
3527 (compile_instance::get_cached_type, compile_instance::insert_type)
3528 (compile_instance::error_symbol_once): Update for unique_ptr.
3529
3530 2018-08-10 Keith Seitz <keiths@redhat.com>
3531
3532 * compile/compile-c-symbols.c (struct symbol_error)
3533 (hash_symbol_error, eq_symbol_error, del_symbol_error)
3534 (compile_instance::insert_symbol_error)
3535 (compile_instance::error_symbol_once): Move to ...
3536 * compile/compile.c: ... here.
3537
3538 2018-08-10 Keith Seitz <keiths@redhat.com>
3539
3540 * compile/compile-c-support.c (c_get_compile_context): Use `new'
3541 instead of `new_compile_instance'.
3542 * compile/compile-c-symbols.c (compile_instance::insert_symbol_error):
3543 Update description.
3544 If the symbol error map is not initialized, create it.
3545 (generate_c_for_for_one_symbol): Do not check/initialize
3546 the symbol error map.
3547 * compile/compile-c-types.c (compile_c_instance): Make a class.
3548 Update all callers.
3549 (compile_instance::compile_instance): Initialize the type cache.
3550 (get_cached_type): New function.
3551 (insert_type): Update description.
3552 (compile_c_instance::m_default_cflags): Define.
3553 (convert_type): Update description. Use get_cached_type.
3554 (delete_instance): Moved to destructor.
3555 (new_compile_instance): Moved to constructor.
3556 * compile/compile-c.h (compile_c_instance): Make class inheriting
3557 from compile_instance.
3558 <base>: Remove field.
3559 <type_map, symbol_err_map>: Move to base class.
3560 <c_plugin>: Rename to `m_plugin' and remove pointer type.
3561 * compile/compile-internal.h (compile_instance): Make class.
3562 <type_map_t, symbol_err_map_t>: Define.
3563 <fe>: Rename to `m_gcc_fe'.
3564 <scope, block, gcc_target_options>: Add `m_' prefix.
3565 <m_type_map, m_symbol_err_map>: New fields, moved from
3566 compile_c_instance.
3567 <destroy>: Remove.
3568 (convert_type, new_compile_instance): Remove.
3569 * compile/compile.c (cleanup_compile_instance): Remove.
3570 (compile_to_object): Use unique_ptr to eliminate cleanups.
3571 (compile_instance::set_print_callback, compile_instance::version)
3572 (compile_instance::set_verbose)
3573 (compile_instance::set_driver_filename)
3574 (compile_instance::set_triplet_regexp)
3575 (compile_instance::set_arguments)
3576 (compile_instance::set_source_file)
3577 (compile_instance::compile): Define.
3578
3579 2018-08-10 Keith Seitz <keiths@redhat.com>
3580
3581 * Makefile.in (HFILES_NO_SRCDIR): Add compile/gcc-c-plugin.h.
3582 * compile/compile-c-types.c: Define GCC_METHODN macros and include
3583 gcc-c-fe.def to define C plugin.
3584 (delete_instance): Delete `c_plugin'.
3585 (new_compile_instance): Initialize `c_plugin'.
3586 * compile/compile-c.h: Include gcc_c_plugin.h.
3587 (struct compile_c_instance) <c_plugin>: New member.
3588 * gcc-c-plugin.h: New file.
3589 Update all callers with API change.
3590
3591 2018-08-10 Keith Seitz <keiths@redhat.com>
3592
3593 * Makefile.in (SUBDIR_GCC_COMPILE_SRCS): Move header files ...
3594 (HFILES_NO_SRCDIR): ... to here.
3595 Add compile-internal.h and compile-c.h.
3596 * compile/compile-c-support.c: Include compile-c.h.
3597 * compile/compile-c-symbols.c: Include compile-c.h.
3598 (generate_c_for_variable_locations): Update comment.
3599 * compile/compile-c-types.c: Include compile-c.h.
3600 * compile/compile-c.h: New file -- moved C language declarations
3601 from other files here.
3602 * compile/compile-internal.h: Do not include hashtab.h or
3603 common/enum-flags.h.
3604 (gcc_qualifiers_flags, struct compile_c_instance, C_CTX)
3605 (gcc_convert_symbol, gcc_symbol_address)
3606 (generate_c_for_variable_locations, c_get_mode_for_size)
3607 (c_get_range_decl_name): Definitions moved to compile-c.h.
3608 * compile/compile-loc2c.c: Include compile-c.h.
3609
3610 2018-08-10 Keith Seitz <keiths@redhat.com>
3611
3612 * compile/compile-c-symbols.c (symbol_substitution_name): Rename to ...
3613 (c_symbol_substitution_name): ... this.
3614 Update all callers.
3615
3616 2018-08-10 Keith Seitz <keiths@redhat.com>
3617
3618 * compile/compile-c-support.c (c_compute_program): Use
3619 unique_xmalloc_ptr to eliminate cleanup.
3620 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
3621 Return a unique_xmalloc_ptr and eliminate cleanup.
3622 * compile/compile-internal.h (generate_c_for_variable_locations):
3623 Return unique_xmalloc_ptr and update description.
3624
3625 2018-08-10 Alan Hayward <alan.hayward@arm.com>
3626
3627 * corelow.c (core_target::get_core_register_section): Rename
3628 min_size to section_min_size.
3629
3630 2018-08-09 Jim Wilson <jimw@sifive.com>
3631
3632 * Makefile.in (ALL_TARGET_OBS): Add riscv-linux-tdep.c.
3633 (ALLDEPFILES): Add riscv-linux-nat.c, and riscv-linux-tdep.c.
3634 * NEWS: Mention new GNU/Linux RISC-V target.
3635 * configure.host: Add riscv*-*-linux*.
3636 * configure.nat: Add riscv*.
3637 * configure.tgt: Add riscv*-*-linux*.
3638 * riscv-linux-nat.c: New file.
3639 * riscv-linux-tdep.c: New file.
3640
3641 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3642
3643 * infrun.c (resume): Make static, add forward declaration.
3644 (proceed): Update header comment.
3645 * infrun.h (resume): Delete declaration.
3646
3647 2018-08-09 Tom Tromey <tom@tromey.com>
3648
3649 * riscv-tdep.h: Minor formatting fixes.
3650
3651 2018-08-09 Simon Marchi <simon.marchi@ericsson.com>
3652
3653 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
3654 * dwarf-index-cache.c (create_dir_and_check): Likewise.
3655 (test_mkdir_recursive): Likewise.
3656 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
3657
3658 2018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
3659
3660 * valarith.c (value_subscripted_rvalue): If an array is not in
3661 memory, and we don't know the upper bound, then we can't know that
3662 the requested element exists or not.
3663
3664 2018-08-08 Simon Marchi <simon.marchi@ericsson.com>
3665
3666 * target.c (str_comma_list_concat_elem): Fix typo in comment.
3667 (target_options_to_string): Add comment.
3668
3669 2018-08-08 Tom Tromey <tom@tromey.com>
3670
3671 * unittests/scoped_mmap-selftests.c: Check result of "write".
3672
3673 2018-08-08 Jim Wilson <jimw@sifive.com>
3674
3675 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
3676 (decode_register_index_short): New.
3677 (decode_j_type_insn, decode_cj_type_insn): New.
3678 (decode_b_type_insn, decode_cb_type_insn): New.
3679 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
3680 local xlen. Check xlen when decoding ambiguous compressed insns. In
3681 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
3682 is_c_sw_insn instead of is_sw_insn.
3683 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
3684 (riscv_software_single_step): New.
3685 * riscv-tdep.h (riscv_software_single_step): Declare.
3686
3687 * riscv-tdep.c (riscv_isa_xlen): Drop static.
3688 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
3689
3690 2018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
3691
3692 PR gdb/18050:
3693 * target.c (dispose_inferior): Don't dispose of inferiors that are
3694 already killed.
3695
3696 2018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
3697
3698 * remote.c (remote_target::download_tracepoint): Change char* to
3699 const char*.
3700
3701 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
3702
3703 * target.h (target_options_to_string): Return an std::string.
3704 * target.c (str_comma_list_concat_elem): Return void, use
3705 std::string.
3706 (do_option): Likewise.
3707 (target_options_to_string): Return an std::string.
3708 * linux-nat.c (linux_nat_target::wait): Adjust.
3709 * target-debug.h (target_debug_print_options): Adjust.
3710
3711 2018-08-07 Tom Tromey <tom@tromey.com>
3712
3713 * Makefile.in (CPPFLAGS): New variable.
3714 (INTERNAL_CPPFLAGS): Use it.
3715
3716 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3717
3718 * NEWS: Mention the index cache.
3719
3720 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3721
3722 * common/pathstuff.h (get_standard_cache_dir): New.
3723 * common/pathstuff.c (get_standard_cache_dir): New.
3724 * build-id.h (build_id_to_string): New.
3725 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
3726 DEBUG_STR_SUFFIX): Move to here.
3727 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
3728 DEBUG_STR_SUFFIX): Move from there.
3729 (write_psymtabs_to_index): Make non-static, add basename
3730 parameter. Write to temporary files, rename when done.
3731 (save_gdb_index_command): Adjust call to
3732 write_psymtabs_to_index.
3733 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
3734 field.
3735 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
3736 (get_gdb_index_contents_from_cache): New.
3737 (get_gdb_index_contents_from_cache_dwz): New.
3738 (dwarf2_initialize_objfile): Read index from cache.
3739 (dwarf2_build_psymtabs): Save to index.
3740 * dwarf-index-cache.h: New file.
3741 * dwarf-index-cache.c: New file.
3742 * dwarf-index-write.h: New file.
3743
3744 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3745
3746 * gnulib/aclocal.m4: Re-generate.
3747 * gnulib/config.in: Re-generate.
3748 * gnulib/configure: Re-generate.
3749 * gnulib/import/Makefile.am: Re-generate.
3750 * gnulib/import/Makefile.in: Re-generate.
3751 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
3752 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3753 * gnulib/import/m4/mkdir.m4: New file.
3754 * gnulib/import/mkdir.c: New file.
3755 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
3756 module.
3757
3758 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3759
3760 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
3761 * common/scoped_mmap.c: New file.
3762 * common/scoped_mmap.h (destroy): New method.
3763 (~scoped_mmap, reset): Use destroy.
3764 (scoped_mmap): New move constructor.
3765 (mmap_file): New declaration.
3766 * unittests/scoped_mmap-selftests.c (test_normal,
3767 test_invalid_filename, run_tests): New functions.
3768 (_initialize_scoped_mmap_selftests): Register selftest.
3769
3770 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3771
3772 * dwarf2read.c (read_gdb_index_from_section): Rename to...
3773 (read_gdb_index_from_buffer): ... this. Remove section
3774 parameter, add buffer parameter.
3775 (get_gdb_index_contents_ftype,
3776 get_gdb_index_contents_dwz_ftype): New typedefs.
3777 (dwarf2_read_gdb_index): Add callback parameters to get the
3778 index contents.
3779 (get_gdb_index_contents_from_section): New.
3780 (dwarf2_initialize_objfile): Update call to
3781 dwarf2_read_gdb_index.
3782
3783 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
3784
3785 * common/filestuff.h (gdb_fopen_cloexec): New overload.
3786 (gdb_open_cloexec): Likewise.
3787 * nat/linux-osdata.c (command_from_pid): Use string_printf.
3788 (commandline_from_pid): Likewise.
3789 (linux_xfer_osdata_threads): Likewise.
3790 (linux_xfer_osdata_fds): Likewise.
3791 * ada-lang.c (is_package_name): Likewise.
3792 * auxv.c (procfs_xfer_auxv): Likewise.
3793 * breakpoint.c (print_one_breakpoint_location): Use
3794 uiout::field_fmt.
3795 (print_one_catch_solib): Use string_printf.
3796 * coff-pe-read.c (add_pe_exported_sym): Likewise.
3797 (add_pe_forwarded_sym): Likewise.
3798 * dwarf2read.c (create_type_unit_group): Likewise.
3799 (build_error_marker_type): Likewise.
3800 * infcall.c (get_function_name): Likewise.
3801 * valprint.c (print_converted_chars_to_obstack): Likewise.
3802 * xtensa-tdep.c (xtensa_register_type): Likewise.
3803
3804 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
3805
3806 * remote.c (remote_target::download_tracepoint): Fix format
3807 string errors.
3808
3809 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3810
3811 * tracefile.c: Include common/byte-vector.h.
3812 (trace_save): Change type of buf to gdb::byte_vector. Initialize
3813 with trace_regblock_size if needed. Update uses of buf.
3814
3815 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3816
3817 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
3818 std::vector<unsigned char>.
3819 * tracepoint.c (collection_list::collection_list): Remove
3820 m_regs_mask initializer from initializer list. Resize
3821 m_regs_mask using the largest remote register number.
3822 (collection_list::add_remote_register): Remove size check on
3823 m_regs_mask. Use at to access element.
3824 (collection_list::stringify): Change type of temp_buf to
3825 gdb::char_vector. Update uses of temp_buf. Resize if needed to
3826 stringify the register mask. Use pack_hex_byte for the register
3827 mask.
3828
3829 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3830
3831 * tracepoint.h (class collection_list) <add_register>: Remove.
3832 <add_remote_register, add_ax_registers, add_local_register>:
3833 Declare.
3834 <add_memrange>: Add scope parameter.
3835 * tracepoint.c (encode_actions_1): Likewise.
3836 (collection_list::add_register): Rename to ...
3837 (collection_list::add_remote_register): ... this. Update
3838 comment.
3839 (collection_list::add_ax_registers, add_local_register): New
3840 methods.
3841 (collection_list::add_memrange): Add scope parameter. Call
3842 add_local_register instead of add_register.
3843 (finalize_tracepoint_aexpr): New function.
3844 (collection_list::collect_symbol): Update calls to add_memrange.
3845 Call add_local_register instead of add_register. Call
3846 add_ax_registers. Call finalize_tracepoint_aexpr.
3847 (encode_actions_1): Get remote regnos for $reg action. Call
3848 add_remote_register, add_ax_registers, and add_local_register.
3849 Update call to add_memrange. Call finalize_tracepoint_aexpr.
3850 (validate_actionline): Call finalize_tracepoint_aexpr.
3851
3852 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3853
3854 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
3855 Replace array buf with gdb::char_vector buf, of size
3856 get_remote_packet_size (). Replace references to buf and
3857 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
3858 and xsnprintf with snprintf. Raise errors if the buffer is too
3859 small.
3860
3861 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3862
3863 * remote.c (remote_target::download_tracepoint): Fix the has_more
3864 predicate in the QTDP action list iteration.
3865
3866 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
3867
3868 * remote.c (remote_target::download_tracepoint): Fix indentation
3869 in for block.
3870
3871 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
3872
3873 * proc-api.c (_initialize_proc_api): Remove c, unused.
3874 * procfs.c (procfs_init_inferior): Remove signals, unused.
3875 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
3876 unused.
3877
3878 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
3879 Andrew Burgess <andrew.burgess@embecosm.com>
3880
3881 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
3882 'W_STOPCODE (0)' as this could be ambiguous.
3883
3884 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
3885
3886 * ser-tcp.c (net_open): Fix thinko when deciding whether to
3887 disable TCP's Nagle algorithm (use "ai_protocol" instead of
3888 "ai_socktype").
3889
3890 2018-08-02 Tom Tromey <tom@tromey.com>
3891
3892 PR symtab/16842.
3893 * dwarf2read.c (read_func_scope): Set symtab on template parameter
3894 symbols.
3895 (process_structure_scope): Likewise.
3896
3897 2018-08-02 Xavier Roirand <roirand@adacore.com>
3898
3899 PR gdb/22629:
3900 * darwin-nat.c (darwin_kill_inferior): Fix handling of
3901 kill inferior.
3902
3903 2018-08-02 Tom Tromey <tom@tromey.com>
3904
3905 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
3906 (darwin_suspend_inferior, darwin_resume_inferior)
3907 (darwin_decode_notify_message, darwin_resume_inferior_threads)
3908 (darwin_check_new_threads): Check result of get_darwin_inferior.
3909
3910 2018-07-31 Joel Brobecker <brobecker@adacore.com>
3911
3912 GDB 8.1.1 released.
3913
3914 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
3915
3916 * varobj.c (varobj_get_path_expr_parent): Report an error if
3917 parent is a dynamic varobj.
3918
3919 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3920
3921 * gnulib/aclocal.m4: Re-generate.
3922 * gnulib/config.in: Re-generate.
3923 * gnulib/configure: Re-generate.
3924 * gnulib/import/Makefile.in: Re-generate.
3925 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
3926 * gnulib/import/m4/onceonly.m4: Re-generate.
3927
3928 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
3929
3930 * target-descriptions.c (struct xml_test_tdesc): New.
3931 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
3932 (record_xml_tdesc): Update.
3933 (maintenance_check_xml_descriptions): Update.
3934 * target-descriptions.h (record_xml_tdesc): Update comment.
3935
3936 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
3937
3938 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
3939 checking array bounds are defined.
3940
3941 2018-07-30 Tom Tromey <tom@tromey.com>
3942
3943 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
3944 irreflexivity violation.
3945
3946 2018-07-30 Tom Tromey <tom@tromey.com>
3947
3948 * cli/cli-decode.c (lookup_cmd): Remove lint code.
3949 * value.c (unpack_long): Remove lint code.
3950 * valops.c (value_ind): Remove lint code.
3951 * valarith.c (value_x_binop, value_x_unop, value_equal)
3952 (value_pos): Remove lint code.
3953
3954 2018-07-28 Tom de Vries <tdevries@suse.de>
3955
3956 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
3957 with undefined upper bound as <optimized out>.
3958
3959 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
3960
3961 * gcore.in: Rename variable "name" to "prefix". Expand
3962 "usage" text.
3963
3964 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
3965
3966 * windows-nat.c (windows_nat_target::create_inferior): Update to
3967 call close() in global namespace.
3968
3969 2018-07-26 Tom Tromey <tom@tromey.com>
3970
3971 * dwarf-index-write.c (add_address_entry): Don't add objfile
3972 offsets.
3973 * dbxread.c (find_stab_function): Rename from
3974 find_stab_function_addr. Return a bound_minimal_symbol.
3975 (read_dbx_symtab): Use raw_text_low, raw_text_high.
3976 Don't add objfile offsets.
3977 (end_psymtab): Use raw_text_low, raw_text_high,
3978 MSYMBOL_VALUE_RAW_ADDRESS.
3979 (read_ofile_symtab): Update.
3980 (process_one_symbol): Update.
3981 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
3982 offsets.
3983 (dw2_relocate): Remove.
3984 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
3985 searching addrmap.
3986 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
3987 Update.
3988 (process_psymtab_comp_unit_reader, add_partial_symbol)
3989 (add_partial_subprogram, dwarf2_ranges_read): Update.
3990 (load_partial_dies): Update.
3991 (add_address_entry): Don't add objfile offsets.
3992 (dwarf2_build_include_psymtabs): Update.
3993 (create_addrmap_from_aranges): Don't add objfile offsets.
3994 (dw2_find_pc_sect_compunit_symtab): Update.
3995 * mdebugread.c (parse_symbol): Don't add objfile offsets.
3996 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
3997 Update.
3998 (parse_partial_symbols): Don't add objfile offsets. Use
3999 raw_text_low, raw_text_high. Update.
4000 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
4001 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
4002 or call 'relocate' quick function. Clear psymbol_map.
4003 * psympriv.h (struct partial_symbol) <address>: Add section
4004 offset.
4005 <set_unrelocated_address>: Rename from set_address.
4006 <raw_text_low, raw_text_high>: New methods.
4007 <text_low, text_high>: Add objfile parameter.
4008 (add_psymbol_to_bcache): Add 'section' parameter. Call
4009 set_unrelocated_address.
4010 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4011 (find_pc_psymbol): Update.
4012 (fixup_psymbol_section, relocate_psymtabs): Remove.
4013 (dump_psymtab, psym_functions): Update.
4014 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
4015 parameter.
4016 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
4017 (start_psymtab_common): Update.
4018 * symfile-debug.c (debug_qf_relocate): Remove.
4019 (debug_sym_quick_functions): Update.
4020 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
4021 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
4022 Update.
4023
4024 2018-07-26 Tom Tromey <tromey@redhat.com>
4025
4026 * dbxread.c (end_psymtab): Use text_high_valid and
4027 text_low_valid.
4028 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
4029 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
4030 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
4031 Update comment.
4032 <text_low_valid, text_high_valid>: New fields.
4033 <set_text_low, set_text_high>: Update.
4034 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
4035
4036 2018-07-26 Tom Tromey <tom@tromey.com>
4037
4038 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
4039 Update.
4040 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
4041 textlow and texthigh fields.
4042 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
4043 Update.
4044 * mdebugread.c (parse_lines, parse_partial_symbols)
4045 (psymtab_to_symtab_1): Update.
4046 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
4047 Rename fields. Update comment. Now private.
4048 <text_low, text_high, set_text_low, set_text_high>: New methods.
4049 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4050 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
4051 (start_psymtab_common, maintenance_info_psymtabs)
4052 (maintenance_check_psymtabs): Update.
4053 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
4054 texthigh fields.
4055 (scan_xcoff_symtab): Update.
4056
4057 2018-07-26 Tom Tromey <tromey@redhat.com>
4058
4059 * psympriv.h (struct partial_symbol) <unrelocated_address,
4060 address, set_address>: New methods.
4061 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
4062 (fixup_psymbol_section, relocate_psymtabs): Update.
4063 (print_partial_symbols): Add 'objfile' parameter. Update.
4064 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
4065 Update.
4066
4067 2018-07-26 Tom Tromey <tom@tromey.com>
4068
4069 * dwarf-index-write.c (write_psymbols, debug_names::insert)
4070 (debug_names::write_psymbols): Update.
4071 * psympriv.h (struct partial_symbol): Derive from
4072 general_symbol_info.
4073 <obj_section>: New method.
4074 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
4075 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
4076 (find_pc_sect_psymbol, fixup_psymbol_section)
4077 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
4078 (print_partial_symbols, recursively_search_psymtabs)
4079 (compare_psymbols, psymbol_hash, psymbol_compare)
4080 (add_psymbol_to_bcache, maintenance_check_psymtabs)
4081 (psymbol_name_matches, psym_fill_psymbol_map): Update.
4082
4083 2018-07-26 Tom Tromey <tromey@redhat.com>
4084
4085 * dbxread.c (end_psymtab): Remove dead code.
4086
4087 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
4088
4089 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
4090 DWARF unwinders are disabled.
4091 * dwarf2-frame.c: Add dwarf2read.h include.
4092 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
4093 disabled.
4094 (dwarf2_frame_unwinders_enabled_p): Define.
4095 (show_dwarf_unwinders_enabled_p): New function.
4096 (_initialize_dwarf2_frame): Register switch to control DWARF
4097 unwinder use.
4098 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
4099 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
4100 (show_dwarf_cmdlist): Remove static keyword.
4101 * dwarf2read.h (set_dwarf_cmdlist): Declare.
4102 (show_dwarf_cmdlist): Declare.
4103 * NEWS: Document new feature.
4104
4105 2018-07-26 Tom de Vries <tdevries@suse.de>
4106
4107 PR breakpoints/23366
4108 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
4109
4110 2018-07-26 Tom de Vries <tdevries@suse.de>
4111
4112 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
4113 DW_AT_count can't be translated to a dynamic prop.
4114
4115 2018-07-25 Tom de Vries <tdevries@suse.de>
4116
4117 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
4118 try/catch.
4119
4120 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
4121
4122 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
4123
4124 2018-07-25 Joel Brobecker <brobecker@adacore.com>
4125
4126 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
4127
4128 2018-07-24 Keith Seitz <keiths@redhat.comt
4129
4130 PR symtab/23010
4131 * dwarf2read.c (dw2_add_symbol_to_list): New function.
4132 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
4133 instead of add_symbol_to_list.
4134 (read_file_scope): Call prepare_one_comp_unit before reading
4135 any other DIEs.
4136
4137 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
4138
4139 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
4140
4141 2018-07-24 Tom Tromey <tom@tromey.com>
4142
4143 * utils.c (malloc, realloc, free): Don't declare.
4144 * configure, config.in: Rebuild.
4145 * configure.ac: Don't check for declarations of free, malloc, or
4146 realloc.
4147
4148 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4149
4150 * aarch64-linux-nat.c
4151 (aarch64_linux_nat_target::stopped_data_address): Remove unused
4152 variable.
4153 * arm-linux-nat.c (fetch_regs): Likewise.
4154 (store_regs): Likewise.
4155 (fetch_vfp_regs): Likewise.
4156 (store_vfp_regs): Likewise.
4157 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
4158 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
4159 (arm_linux_nat_target::insert_watchpoint): Likewise.
4160 (arm_linux_nat_target::remove_watchpoint): Likewise.
4161 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
4162 Likewise.
4163 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
4164 Likewise.
4165 * ppc-linux-nat.c (fetch_register): Likewise.
4166 (fetch_all_gp_regs): Likewise.
4167 (fetch_ppc_registers): Likewise.
4168 (store_all_gp_regs): Likewise.
4169 (store_ppc_registers): Likewise.
4170 (hwdebug_insert_point): Likewise.
4171 (can_use_watchpoint_cond_accel): Likewise.
4172 * remote-sim.c (gdb_os_write_stdout): Likewise.
4173
4174 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
4175 Tom Tromey <tom@tromey.com>
4176
4177 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
4178 test for it.
4179 * configure: Rebuild.
4180
4181 2018-07-22 Tom Tromey <tom@tromey.com>
4182
4183 * regformats/regdat.sh: Define xmltarget_${name} inside
4184 #ifndef IN_PROCESS_AGENT.
4185
4186 2018-07-22 Tom Tromey <tom@tromey.com>
4187
4188 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
4189
4190 2018-07-22 Tom Tromey <tom@tromey.com>
4191
4192 * symfile.c (reread_symbols): Notify iter, not objfile.
4193
4194 2018-07-22 Tom Tromey <tom@tromey.com>
4195
4196 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
4197 Use arch_ops.
4198 (ravenscar_thread_target::prepare_to_store): Likewise.
4199
4200 2018-07-22 Tom Tromey <tom@tromey.com>
4201
4202 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
4203 unused variable. Call value_fetch_lazy when needed.
4204 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
4205 Remove unused variable. Call value_fetch_lazy when needed.
4206
4207 2018-07-22 Tom Tromey <tom@tromey.com>
4208
4209 * m32c-tdep.c (mark_dma): Return void.
4210 (make_regs): Remove unused declarations.
4211
4212 2018-07-22 Tom Tromey <tom@tromey.com>
4213
4214 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
4215 cmdscm_get_valid_command_smob_arg_unsafe for effect.
4216 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
4217 bkscm_get_valid_block_smob_arg_unsafe for effect.
4218
4219 2018-07-22 Tom Tromey <tom@tromey.com>
4220
4221 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
4222 value_type.
4223
4224 2018-07-22 Tom Tromey <tom@tromey.com>
4225
4226 * windows-nat.c (saved_context): Conditionally define.
4227 * remote.c (remote_target::remote_btrace_maybe_reopen):
4228 Conditionally declare "warned".
4229 * inflow.c (sigquit_ours): Conditionally define.
4230 (new_tty): Move "tty" declaration inside #if.
4231 * guile/guile.c (guile_datadir): Conditionally define.
4232 * charset.c (set_be_le_names): Move some declarations inside #if.
4233 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
4234 #if.
4235 (parse_xml_btrace_conf): Likewise.
4236
4237 2018-07-22 Tom Tromey <tom@tromey.com>
4238
4239 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
4240
4241 2018-07-22 Tom Tromey <tom@tromey.com>
4242
4243 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
4244 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
4245 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
4246 * buildsym-legacy.c (get_macro_table): Remove unused variable.
4247 * stack.c (frame_apply_level_command): Remove unused variable.
4248 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
4249 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
4250 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
4251 unused variable.
4252 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
4253 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
4254 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
4255 variable.
4256 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
4257 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
4258 variable.
4259 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
4260 Remove unused variable.
4261 * cli/cli-script.c (recurse_read_control_structure): Remove unused
4262 variable.
4263 * common/tdesc.c (print_xml_feature::visit): Remove unused
4264 variable.
4265 * compile/compile-object-load.c (store_regs): Remove unused
4266 variables.
4267 * complaints.c (clear_complaints): Remove unused variable.
4268 * corelow.c (core_target_open): Remove unused variable.
4269 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
4270 variable.
4271 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
4272 variable.
4273 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
4274 variable.
4275 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
4276 variable.
4277 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
4278 variable.
4279 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
4280 variable.
4281 * ia64-tdep.c (examine_prologue): Remove unused variable.
4282 * infcall.c (run_inferior_call): Remove unused variable.
4283 * inferior.c (exit_inferior): Remove unused variable.
4284 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
4285 * linespec.c (decode_line_2): Remove unused variable.
4286 * linux-nat.c (super_close): Remove.
4287 * linux-tdep.c (linux_info_proc): Remove unused variable.
4288 * mi/mi-main.c (mi_execute_command): Remove unused variable.
4289 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
4290 Remove unused variable.
4291 * parse.c (find_minsym_type_and_address): Remove unused variable.
4292 * printcmd.c (info_symbol_command, printf_floating): Remove unused
4293 variable.
4294 * python/py-breakpoint.c (bppy_set_commands): Remove unused
4295 variable.
4296 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
4297 variables.
4298 * record-btrace.c (record_btrace_target::store_registers): Remove
4299 unused variable.
4300 (cmd_show_record_btrace_cpu): Remove unused variable.
4301 * riscv-tdep.c (riscv_register_reggroup_p)
4302 (riscv_push_dummy_call, riscv_return_value): Remove unused
4303 variable.
4304 * rust-exp.y (literal): Remove unused variable.
4305 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
4306 unused variable.
4307 <STRUCTOP_ANONYMOUS>: Likewise.
4308 * s390-linux-tdep.c (s390_linux_init_abi_31)
4309 (s390_linux_init_abi_64): Remove unused variable.
4310 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
4311 (file_select_thread, net_windows_open, _initialize_ser_windows):
4312 Remove unused variables.
4313 * symtab.c (find_pc_sect_line): Remove unused variable.
4314 * target-memory.c (compute_garbled_blocks): Remove unused
4315 variable.
4316 (target_write_memory_blocks): Remove unused variable.
4317 * target.c (target_stack::unpush): Remove unused variables.
4318 * tracepoint.c (start_tracing, all_tracepoint_actions)
4319 (merge_uploaded_trace_state_variables)
4320 (print_one_static_tracepoint_marker): Remove unused variable.
4321 * unittests/basic_string_view/element_access/char/1.cc (test01):
4322 Remove unused variable.
4323 * windows-nat.c (windows_continue, windows_add_all_dlls)
4324 (do_initial_windows_stuff, windows_nat_target::create_inferior):
4325 Remove unused variables.
4326
4327 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
4328
4329 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
4330 attr_profile in HAVE_ELF.
4331 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
4332 HAVE_ELF.
4333
4334 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
4335
4336 * frame.c (frame_register_unwind): Change parameter name.
4337 (frame_unwind_register): Likewise.
4338 (frame_unwind_register_value): Likewise.
4339 (frame_unwind_register_signed): Likewise.
4340 (frame_unwind_register_unsigned): Likewise.
4341 * frame.h (frame_register_unwind): Likewise.
4342 (frame_unwind_register): Likewise.
4343 (frame_unwind_register_value): Likewise.
4344 (frame_unwind_register_signed): Likewise.
4345 (frame_unwind_register_unsigned): Likewise.
4346 (frame_unwind_arch): Likewise.
4347
4348 2018-07-20 Maciej W. Rozycki <macro@mips.com>
4349
4350 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
4351 ISA maintenance.
4352
4353 2018-07-20 Maciej W. Rozycki <macro@mips.com>
4354
4355 * mips-linux-nat.c (mips_linux_nat_target::read_description):
4356 Call `get_ptrace_pid' rather than extracting the ptrace PID by
4357 hand.
4358
4359 2018-07-20 Keith Seitz <keiths@redhat.com>
4360
4361 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
4362 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
4363 m_compunit_symtab, m_language>: Add "m_" prefix.
4364 Update all uses.
4365 * buildsym.c: Update all uses.
4366
4367 2018-07-20 Tom Tromey <tom@tromey.com>
4368
4369 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
4370 * buildsym.h (record_line_ftype): Remove typedef.
4371
4372 2018-07-20 Tom Tromey <tom@tromey.com>
4373
4374 * buildsym-legacy.h (augment_type_symtab): Don't declare.
4375 (end_expandable_symtab): Likewise.
4376 (end_symtab_get_static_block): Likewise.
4377 (end_symtab_from_static_block): Likewise.
4378 * buildsym-legacy.c (augment_type_symtab): Remove.
4379 (end_expandable_symtab): Remove.
4380 (end_symtab_get_static_block): Remove.
4381 (end_symtab_from_static_block): Remove.
4382
4383 2018-07-20 Tom Tromey <tom@tromey.com>
4384
4385 * dwarf2read.c: Include buildsym.h.
4386 (struct dwarf2_cu) <builder>: New method.
4387 (fixup_go_packaging): Update.
4388 (process_full_comp_unit, process_full_type_unit): Update. Don't
4389 use scoped_free_pendings.
4390 (using_directives): Add "cu" parameter, remove "language".
4391 (read_import_statement, setup_type_unit_groups, )
4392 (read_func_scope, read_lexical_block_scope)
4393 (dwarf2_record_block_ranges, read_namespace): Update.
4394 (lnp_state_machine::lnp_state_machine): Add cu parameter.
4395 (lnp_state_machine::handle_end_sequence): Update.
4396 (class lnp_state_machine) <m_cu>: New member.
4397 <m_record_line_callback>: Remove.
4398 <m_currently_recording_lines>: New member.
4399 (lnp_state_machine::handle_set_file): Update.
4400 (noop_record_line): Remove.
4401 (dwarf_record_line_p): Add cu parameter.
4402 (dwarf_record_line_1, dwarf_finish_line): Likewise.
4403 (lnp_state_machine::record_line)
4404 (lnp_state_machine::lnp_state_machine)
4405 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
4406 (dwarf_decode_lines): Update.
4407 (dwarf2_start_subfile): Add cu parameter.
4408 (dwarf2_start_symtab, new_symbol): Update.
4409 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
4410 Remove dwarf2_per_objfile parameter.
4411 (dwarf_decode_macros): Update.
4412
4413 2018-07-20 Tom Tromey <tom@tromey.com>
4414
4415 * stabsread.c (define_symbol): Update.
4416 * buildsym-legacy.h (get_buildsym_compunit): Declare.
4417 * dwarf2read.c (new_symbol): Update.
4418 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
4419 * cp-namespace.c: Include buildsym.h.
4420 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
4421 * buildsym-legacy.c (get_buildsym_compunit): New function.
4422
4423 2018-07-20 Tom Tromey <tom@tromey.com>
4424
4425 * xcoffread.c: Include buildsym-legacy.h.
4426 * windows-nat.c: Include buildsym-legacy.h.
4427 * stabsread.c: Include buildsym-legacy.h.
4428 * mdebugread.c: Include buildsym-legacy.h.
4429 * buildsym-legacy.h: New file.
4430 * buildsym-legacy.c: New file, from buildsym.c.
4431 * go32-nat.c: Include buildsym-legacy.h.
4432 * dwarf2read.c: Include buildsym-legacy.h.
4433 * dbxread.c: Include buildsym-legacy.h.
4434 * cp-namespace.c: Include buildsym-legacy.h.
4435 * coffread.c: Include buildsym-legacy.h.
4436 * buildsym.h: Move some contents to buildsym-legacy.h.
4437 * buildsym.c: Include buildsym-legacy.h. Move many functions to
4438 buildsym-legacy.c.
4439 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
4440
4441 2018-07-20 Tom Tromey <tom@tromey.com>
4442
4443 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
4444 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
4445 (buildsym_compunit::buildsym_compunit)
4446 (buildsym_compunit::~buildsym_compunit)
4447 (buildsym_compunit::get_macro_table): Define.
4448
4449 2018-07-20 Tom Tromey <tom@tromey.com>
4450
4451 * buildsym.c (reset_symtab_globals): Remove.
4452 (buildsym_compunit::end_symtab_from_static_block): Update.
4453 (buildsym_compunit::augment_type_symtab): Update.
4454 (end_symtab_from_static_block): Call free_buildsym_compunit.
4455 (augment_type_symtab, end_symtab, end_expandable_symtab):
4456 Likewise.
4457
4458 2018-07-20 Tom Tromey <tom@tromey.com>
4459
4460 * arch-utils.c: Do not include buildsym.h.
4461 * mipsread.c: Do not include buildsym.h.
4462 * machoread.c: Do not include buildsym.h.
4463 * elfread.c: Do not include buildsym.h.
4464
4465 2018-07-20 Tom Tromey <tom@tromey.com>
4466
4467 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
4468 initialization.
4469 (buildsym_compunit): Add new constructor.
4470 (struct buildsym_compunit) <get_last_source_file, finish_block,
4471 record_block_range, start_subfile, patch_subfile_names,
4472 push_subfile, pop_subfile, record_line, get_compunit_symtab,
4473 set_last_source_start_addr, get_last_source_start_addr,
4474 get_local_using_directives, set_local_using_directives,
4475 get_global_using_directives, outermost_context_p,
4476 get_current_context_stack, get_context_stack_depth,
4477 get_current_subfile, get_local_symbols, get_file_symbols,
4478 get_global_symbols, record_debugformat, record_producer,
4479 push_context, pop_context, end_symtab_get_static_block,
4480 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
4481 New public methods.
4482 <record_pending_block, finish_block_internal, make_blockvector,
4483 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
4484 private methods.
4485 Update all users.
4486
4487 2018-05-22 Tom Tromey <tom@tromey.com>
4488
4489 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4490 parameter.
4491 (finish_block_internal): Update.
4492
4493 2018-07-20 Tom Tromey <tom@tromey.com>
4494
4495 * buildsym.c (record_pending_block): Move earlier. Remove objfile
4496 parameter.
4497 (finish_block_internal): Update.
4498
4499 2018-07-20 Tom Tromey <tom@tromey.com>
4500
4501 * buildsym.h (EXTERN): Don't define or undef.
4502 * buildsym.c (EXTERN): Don't define.
4503
4504 2018-07-20 Tom Tromey <tom@tromey.com>
4505
4506 * buildsym.c: Remove TODO comment.
4507
4508 2018-07-20 Tom Tromey <tom@tromey.com>
4509
4510 * coffread.c (coff_symtab_read): Update.
4511 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
4512 (xcoff_new_init): Update.
4513 * mipsread.c (mipscoff_new_init): Update.
4514 * mdebugread.c (mdebug_build_psymtabs): Update.
4515 * elfread.c (elf_new_init): Update.
4516 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
4517 Update.
4518 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
4519 (coffstab_build_psymtabs, elfstab_build_psymtabs)
4520 (stabsect_build_psymtabs): Update.
4521 * buildsym.h (buildsym_init): Don't declare.
4522 * buildsym.c: Update comment.
4523 (prepare_for_building): Remove.
4524 (start_symtab, restart_symtab): Update.
4525 (reset_symtab_globals): Update comment.
4526 (buildsym_init): Remove.
4527
4528 2018-07-20 Tom Tromey <tom@tromey.com>
4529
4530 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
4531 * stabsread.c (patch_block_stabs, define_symbol, read_type)
4532 (read_enum_type, common_block_start, common_block_end)
4533 (cleanup_undefined_types_1, finish_global_stabs): Update.
4534 * mdebugread.c (psymtab_to_symtab_1): Update.
4535 * dwarf2read.c (fixup_go_packaging, read_func_scope)
4536 (read_lexical_block_scope, new_symbol): Update.
4537 * dbxread.c (process_one_symbol): Update.
4538 * coffread.c (coff_symtab_read, process_coff_symbol)
4539 (coff_read_enum_type): Update.
4540 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
4541 declare.
4542 (get_local_symbols, get_file_symbols, get_global_symbols): New
4543 functions.
4544 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
4545 m_global_symbols.
4546 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
4547 (~scoped_free_pendings): Update.
4548 (finish_block, prepare_for_building, reset_symtab_globals)
4549 (end_symtab_get_static_block, end_symtab_with_blockvector)
4550 (augment_type_symtab, push_context): Update.
4551 (get_local_symbols, get_file_symbols, get_global_symbols): New
4552 functions.
4553 (buildsym_init): Update.
4554
4555 2018-07-20 Tom Tromey <tom@tromey.com>
4556
4557 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
4558 (process_full_type_unit): Likewise.
4559 (dwarf2_start_symtab): Set list_in_scope.
4560
4561 2018-07-20 Tom Tromey <tom@tromey.com>
4562
4563 * dwarf2read.c (process_psymtab_comp_unit_reader)
4564 (build_type_psymtabs_reader): Do not set list_in_scope.
4565
4566 2018-07-20 Tom Tromey <tom@tromey.com>
4567
4568 * buildsym.c (free_pendings): Remove.
4569 (add_symbol_to_list, scoped_free_pendings)
4570 (finish_block_internal, buildsym_init): Update.
4571
4572 2018-07-20 Tom Tromey <tom@tromey.com>
4573
4574 * xcoffread.c (read_xcoff_symtab): Update.
4575 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
4576 Update.
4577 * dbxread.c (process_one_symbol): Update.
4578 * coffread.c (coff_symtab_read): Update.
4579 * buildsym.h (finish_block): Update.
4580 * buildsym.c (finish_block): Remove "listhead" argument.
4581 (end_symtab_get_static_block): Update.
4582
4583 2018-07-20 Tom Tromey <tom@tromey.com>
4584
4585 * buildsym.h (class scoped_free_pendings): Remove constructor.
4586 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
4587 method.
4588 <m_pending_block_obstack, m_pending_blocks>: New members.
4589 (pending_block_obstack, pending_blocks): Remove.
4590 (scoped_free_pendings::scoped_free_pendings): Default.
4591 (~scoped_free_pendings): Update.
4592 (free_pending_blocks): Remove.
4593 (finish_block_internal, record_pending_block, make_blockvector)
4594 (end_symtab_get_static_block, augment_type_symtab, push_context)
4595 (buildsym_init): Update.
4596
4597 2018-07-20 Tom Tromey <tom@tromey.com>
4598
4599 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
4600 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
4601 members.
4602 (pending_addrmap, pending_addrmap_obstack)
4603 (pending_addrmap_interesting): Remove.
4604 (scoped_free_pendings, record_block_range, make_blockvector)
4605 (prepare_for_building, reset_symtab_globals, buildsym_init):
4606 Update.
4607
4608 2018-07-20 Tom Tromey <tom@tromey.com>
4609
4610 * xcoffread.c (process_linenos): Update.
4611 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
4612 * mdebugread.c (psymtab_to_symtab_1): Update.
4613 * dwarf2read.c (setup_type_unit_groups)
4614 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
4615 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
4616 * dbxread.c (process_one_symbol): Update.
4617 * coffread.c (coff_symtab_read, enter_linenos)
4618 (process_coff_symbol): Update.
4619 * buildsym.h (current_subfile): Don't declare.
4620 (get_current_subfile): Declare.
4621 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
4622 member.
4623 (start_subfile, free_buildsym_compunit, push_subfile)
4624 (prepare_for_building, start_symtab): Update.
4625 (get_current_subfile): New function.
4626
4627 2018-07-20 Tom Tromey <tom@tromey.com>
4628
4629 * coffread.c (coff_symtab_read): Update.
4630 * xcoffread.c (read_xcoff_symtab): Update.
4631 * dwarf2read.c (new_symbol): Update.
4632 (read_func_scope, read_lexical_block_scope): Update.
4633 * dbxread.c (process_one_symbol): Update.
4634 * buildsym.h (context_stack, context_stack_depth): Don't declare.
4635 (outermost_context_p): Remove macro.
4636 (outermost_context_p, get_current_context_stack)
4637 (get_context_stack_depth): Declare.
4638 (pop_context): Return struct context_stack.
4639 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
4640 member.
4641 (context_stack_size): Remove.
4642 (INITIAL_CONTEXT_STACK_SIZE): Remove.
4643 (prepare_for_building, end_symtab_get_static_block)
4644 (augment_type_symtab, push_context): Update.
4645 (pop_context): Return struct context_stack.
4646 (outermost_context_p, get_current_context_stack)
4647 (get_context_stack_depth): New functions.
4648 (buildsym_init): Update.
4649
4650 2018-07-20 Tom Tromey <tom@tromey.com>
4651
4652 * rust-exp.y: Now a pure parser. Update all rules.
4653 (%union): Move earlier.
4654 (current_parser, work_obstack): Remove globals.
4655 (rust_parser, ~rust_parser): Update.
4656 (class rust_parser) <copy_name, concat3, crate_name, super_name,
4657 lex_character, lex_number, lex_string, lex_identifier,
4658 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
4659 convert_name, convert_params_to_expression,
4660 convert_ast_to_expression, ast_basic_type, ast_operation,
4661 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
4662 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
4663 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
4664 ast_array_type, ast_slice_type, ast_reference_type,
4665 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
4666 (rust_parse): Update.
4667 (rustyyerror, rustyylex): Add parser parameter.
4668 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
4669 (rust_lex_stringish_test, rust_lex_test_sequence)
4670 (rust_lex_test_trailing_dot, rust_lex_test_completion)
4671 (rust_lex_test_push_back, rust_lex_tests): Update.
4672
4673 2018-07-19 Pedro Alves <palves@redhat.com>
4674
4675 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
4676 gdb::unique_xmalloc_ptr.
4677 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
4678 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
4679 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
4680 copy-initialization.
4681 * guile/scm-pretty-print.c (ppscm_print_children): Use
4682 gdb::unique_xmalloc_ptr instead of cleanups.
4683 (gdbscm_apply_val_pretty_printer): Remove cleanups.
4684 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
4685 gdb::unique_xmalloc_ptr.
4686 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4687 Adjust to use gdb::unique_xmalloc_ptr.
4688 * guile/scm-utils.c (extract_arg): Adjust.
4689 * guile/scm-value.c (gdbscm_value_field): Adjust to use
4690 gdb::unique_xmalloc_ptr instead of a cleanup.
4691
4692 2018-07-19 Tom Tromey <tom@tromey.com>
4693
4694 * utils.c (do_value_free_to_mark)
4695 (make_cleanup_value_free_to_mark): Remove.
4696 * utils.h (make_cleanup_value_free_to_mark): Remove.
4697
4698 2018-07-19 Pedro Alves <palves@redhat.com>
4699
4700 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
4701 forwarding reference.
4702
4703 2018-07-18 Pedro Alves <palves@redhat.com>
4704
4705 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
4706 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
4707 cleanup.
4708
4709 2018-07-18 Pedro Alves <palves@redhat.com>
4710
4711 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
4712 exceptions.
4713 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
4714 (gdbscm_wrap): New.
4715 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
4716 directly instead of a cleanup.
4717 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
4718 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
4719 (vlscm_binop_gdbthrow): New, factored out from ...
4720 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
4721 (vlscm_rich_compare): Use gdbscm_wrap.
4722 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
4723 instead of a cleanup.
4724 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
4725 cleanup.
4726 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
4727 Use xfree directly instead of a cleanup.
4728 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
4729 Adjust to use gdbscm_wrap and scoped_value_mark.
4730 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
4731 (gdbscm_value_address, gdbscm_value_dereference)
4732 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
4733 scoped_value_mark.
4734 (gdbscm_value_dynamic_type): Use scoped_value_mark.
4735 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
4736 scoped_value_mark.
4737 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
4738 gdbscm_wrap and scoped_value_mark.
4739 (gdbscm_value_to_string): Use xfree directly instead of a
4740 cleanup. Move 'buffer' unique_ptr to TRY scope.
4741 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
4742 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
4743 scoped_value_mark.
4744 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
4745 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
4746 scoped_value_mark.
4747 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
4748 gdbscm_wrap.
4749
4750 2018-07-18 Tom de Vries <tdevries@suse.de>
4751
4752 * findvar.c (default_read_var_value): Also resolve dynamic type for
4753 LOC_OPTIMIZED_OUT vars.
4754
4755 2018-07-18 Maciej W. Rozycki <macro@mips.com>
4756
4757 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
4758 decoding.
4759
4760 2018-07-17 Tom Tromey <tom@tromey.com>
4761
4762 * guile/scm-param.c (pascm_set_func, pascm_show_func)
4763 (compute_enum_list, pascm_set_param_value_x)
4764 (gdbscm_parameter_value): Update.
4765 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
4766 (gdbscm_scm_to_host_string): Update.
4767 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
4768 Update.
4769 * guile/scm-cmd.c (cmdscm_add_completion): Update.
4770 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
4771 * guile/scm-string.c (gdbscm_scm_to_string): Return
4772 unique_xmalloc_ptr.
4773 (gdbscm_scm_to_host_string): Likewise.
4774
4775 2018-07-17 Tom Tromey <tom@tromey.com>
4776
4777 * guile/guile.c (gdbscm_eval_from_control_command): Update.
4778 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
4779 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
4780 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
4781 unique_xmalloc_ptr.
4782
4783 2018-07-17 Tom Tromey <tom@tromey.com>
4784
4785 * guile/scm-param.c (pascm_signal_setshow_error): Update.
4786 * guile/guile-internal.h (gdbscm_exception_message_to_string):
4787 Update.
4788 * guile/scm-cmd.c (cmdscm_function): Update.
4789 * guile/scm-pretty-print.c
4790 (ppscm_print_exception_unless_memory_error): Update.
4791 * guile/scm-exception.c (gdbscm_exception_message_to_string):
4792 Return unique_xmalloc_ptr.
4793
4794 2018-07-17 Tom Tromey <tom@tromey.com>
4795
4796 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
4797 Use string_printf.
4798
4799 2018-07-17 Jim Wilson <jimw@sifive.com>
4800
4801 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
4802 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
4803 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
4804 unecessary braces after EF_RISCV_RVC test. Delete call to
4805 set_gdbarch_decr_pc_after_break.
4806
4807 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
4808 RISCV_LAST_FP_REGNUM + 1.
4809 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
4810
4811 2018-07-17 Tom Tromey <tom@tromey.com>
4812
4813 * configure.ac: Remove --disable-gdbcli.
4814 * configure: Rebuild.
4815 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
4816 (SUBDIR_CLI_CFLAGS): Remove.
4817 (SFILES): Use SUBDIR_CLI_SRCS.
4818 (COMMON_OBS): Use SUBDIR_CLI_OBS.
4819
4820 2018-07-17 Tom Tromey <tom@tromey.com>
4821
4822 PR gdb/18624:
4823 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
4824
4825 2018-07-16 Jim Wilson <jimw@sifive.com>
4826
4827 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
4828
4829 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4830
4831 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
4832 variable.
4833 (libunwind_frame_sniffer): Likewise.
4834 (libunwind_frame_prev_register): Likewise.
4835 (libunwind_sigtramp_frame_sniffer): Likewise.
4836 * ia64-tdep.c (ia64_access_reg): Likewise.
4837 (ia64_access_rse_reg): Likewise.
4838 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
4839 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
4840
4841 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4842
4843 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
4844
4845 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
4846
4847 * remote-sim.c (gdbsim_target::close,
4848 gdbsim_target::mourn_inferior): Remove unused variables.
4849
4850 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
4851
4852 * ia64-tdep.c (ktab_buf): New global.
4853 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
4854 (get_kernel_table): Adjust.
4855
4856 2018-07-16 Tom Tromey <tom@tromey.com>
4857
4858 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
4859 * dwarf2read.c (using_directives, new_symbol): Use
4860 outermost_context_p.
4861 * dbxread.c (process_one_symbol): Use outermost_context_p.
4862 * coffread.c (coff_symtab_read): Use outermost_context_p.
4863
4864 2018-07-16 Tom Tromey <tom@tromey.com>
4865
4866 * dwarf2read.c (using_directives, read_func_scope)
4867 (read_lexical_block_scope): Update.
4868 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
4869 * buildsym.h (local_using_directives, global_using_directives):
4870 Don't declare.
4871 (get_local_using_directives, set_local_using_directives)
4872 (get_global_using_directives): Declare.
4873 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
4874 m_global_using_directives>: New members.
4875 (finish_block_internal, prepare_for_building)
4876 (reset_symtab_globals, end_symtab_get_static_block)
4877 (push_context): Update.
4878 (get_local_using_directives, set_local_using_directives)
4879 (get_global_using_directives): New functions.
4880 (buildsym_init): Update.
4881
4882 2018-07-16 Tom Tromey <tom@tromey.com>
4883
4884 * xcoffread.c (xcoff_initial_scan): Don't call
4885 free_pending_blocks.
4886 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
4887 * buildsym.h (class scoped_free_pendings): Add constructor.
4888 (free_pending_blocks): Don't declare.
4889 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
4890 (free_pending_blocks): Now static.
4891
4892 2018-07-16 Tom Tromey <tom@tromey.com>
4893
4894 * buildsym.h (push_subfile, pop_subfile): Update declarations.
4895 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
4896 member.
4897 (struct subfile_stack): Remove.
4898 (subfile_stack): Remove.
4899 (push_subfile, pop_subfile, buildsym_init): Update.
4900
4901 2018-07-16 Tom Tromey <tom@tromey.com>
4902
4903 * buildsym.c (push_subfile): Use gdb_assert.
4904 (pop_subfile): Use gdb_assert.
4905
4906 2018-07-16 Tom Tromey <tom@tromey.com>
4907
4908 * buildsym.h (merge_symbol_lists): Remove.
4909 * buildsym.c (merge_symbol_lists): Remove.
4910
4911 2018-07-16 Tom Tromey <tom@tromey.com>
4912
4913 * stabsread.c (scan_file_globals): Update comment.
4914 * stabsread.h (scan_file_globals): Move from buildsym.h.
4915 * buildsym.h (scan_file_globals): Move to stabsread.h.
4916
4917 2018-07-16 Tom Tromey <tom@tromey.com>
4918
4919 * xcoffread.c (xcoff_new_init): Update.
4920 * mipsread.c (mipscoff_new_init): Update.
4921 * mdebugread.c (mdebug_build_psymtabs): Update.
4922 * elfread.c (elf_new_init): Update.
4923 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
4924 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
4925 * buildsym.h (buildsym_new_init): Don't declare.
4926 * buildsym.c (buildsym_new_init): Remove.
4927
4928 2018-07-16 Tom Tromey <tom@tromey.com>
4929
4930 * stabsread.h (within_function): Move from buildsym.h.
4931 * stabsread.c (start_stabs): Clear within_function.
4932 * coffread.c (coff_start_symtab): Clear within_function.
4933 * buildsym.h (within_function): Move to stabsread.h.
4934 * buildsym.c (prepare_for_building): Update.
4935
4936 2018-07-16 Tom Tromey <tom@tromey.com>
4937
4938 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
4939 * dwarf2read.c (dwarf2_start_symtab): Don't set
4940 processing_gcc_compilation.
4941 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
4942
4943 2018-07-16 Tom Tromey <tom@tromey.com>
4944
4945 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
4946 (next_symbol_text_func): Move from buildsym.h.
4947 * stabsread.c (hashname): Move from buildsym.c.
4948 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
4949 (next_symbol_text_func, hashname): Move to stabsread.h.
4950 * buildsym.c: Don't include bcache.h
4951 (hashname): Move to stasbread.c.
4952
4953 2018-07-16 Tom Tromey <tom@tromey.com>
4954
4955 * buildsym.h (context_stack_size): Don't declare.
4956 * buildsym.c (context_stack_size): New global.
4957
4958 2018-07-16 Tom Tromey <tom@tromey.com>
4959
4960 * dbxread.c (processing_acc_compilation): New global.
4961 * buildsym.h (processing_acc_compilation): Don't declare.
4962
4963 2018-07-16 Tom Tromey <tom@tromey.com>
4964
4965 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
4966 * dbxread.c (read_ofile_symtab): Update.
4967 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
4968 * buildsym.h (last_source_start_addr): Remove.
4969 (set_last_source_start_addr, get_last_source_start_addr):
4970 Declare.
4971 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
4972 parameter.
4973 (struct buildsym_compunit) <m_last_source_start_addr>: New
4974 member.
4975 (prepare_for_building): Remove start_addr parameter.
4976 (start_symtab, restart_symtab, end_symtab_get_static_block)
4977 (end_symtab_with_blockvector): Update.
4978 (set_last_source_start_addr, get_last_source_start_addr): New
4979 functions.
4980
4981 2018-07-16 Tom Tromey <tom@tromey.com>
4982
4983 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
4984 member.
4985 (have_line_numbers): Remove.
4986 (record_line, prepare_for_building, end_symtab_get_static_block)
4987 (augment_type_symtab): Update.
4988
4989 2018-07-16 Tom Tromey <tom@tromey.com>
4990
4991 * buildsym.c (~buildsym_compunit): Free the macro table.
4992 (struct buildsym_compunit) <get_macro_table, release_macros>: New
4993 methods.
4994 <m_pending_macros>: New member.
4995 (pending_macros): Remove.
4996 (~scoped_free_pendings, get_macro_table, prepare_for_building)
4997 (reset_symtab_globals, end_symtab_get_static_block)
4998 (end_symtab_with_blockvector, augment_type_symtab)
4999 (buildsym_init): Update.
5000
5001 2018-07-16 Tom Tromey <tom@tromey.com>
5002
5003 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
5004 parameter.
5005 (buildsym_compunit::set_last_source_file): New method.
5006 <m_last_source_file>: New member.
5007 (prepare_for_building): Remove "name" parameter.
5008 (start_symtab, restart_symtab, reset_symtab_globals): Update.
5009 (last_source_file): Remove.
5010 (set_last_source_file, get_last_source_file): Update.
5011
5012 2018-07-16 Tom Tromey <tom@tromey.com>
5013
5014 * buildsym.c (prepare_for_building): Add assert.
5015
5016 2018-07-16 Tom Tromey <tom@tromey.com>
5017
5018 * buildsym.c (~buildsym_compunit): Update.
5019 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
5020 (start_subfile, patch_subfile_names)
5021 (end_symtab_with_blockvector): Update.
5022
5023 2018-07-16 Tom Tromey <tom@tromey.com>
5024
5025 * buildsym.c (struct buildsym_compunit): Add constructor,
5026 destructor, initializers.
5027 (start_buildsym_compunit): Remove.
5028 (free_buildsym_compunit): Use "delete".
5029 (start_symtab, restart_symtab): Use "new".
5030
5031 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
5032
5033 * symfile.c (set_objfile_default_section_offset): Remove struct
5034 keyword.
5035
5036 2018-07-14 Stafford Horne <shorne@gmail.com>
5037
5038 * (Responsible Maintainers): Add myself as or1k maintainer.
5039
5040 2018-07-13 Tom Tromey <tom@tromey.com>
5041
5042 * symfile.c (set_objfile_default_section_offset): Use extra braces
5043 around initializer.
5044
5045 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5046
5047 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
5048 non-branching basr.
5049
5050 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5051
5052 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5053 unittests/cli-utils-selftests.c
5054 * unittests/cli-utils-selftests.c: New file.
5055
5056 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5057
5058 * NEWS: Mention new commands. Mention change to 'thread apply'.
5059
5060 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5061
5062 * thread.c (thr_try_catch_cmd): New function.
5063 (thread_apply_all_command): Handle qcs flags.
5064 (thread_apply_command): Handle qcs flags.
5065 (taas_command): New function.
5066 (tfaas_command): New function.
5067 (_initialize_thread): Update to setup the new commands 'taas
5068 and 'tfaas'. Change doc string for 'thread apply'.
5069
5070 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5071
5072 * stack.c: (trailing_outermost_frame): New function, mostly
5073 extracted from backtrace_command_1.
5074 (leading_innermost_frame): New function.
5075 (backtrace_command_1): Update to call trailing_outermost_frame.
5076 (frame_apply_command_count): New function.
5077 (frame_apply_level_command): New function.
5078 (frame_apply_all_command): New function.
5079 (frame_apply_command): New function.
5080 (faas_command): New function.
5081 (frame_cmd_list): New variable.
5082 (_initialize_stack): Update to setup the new commands 'frame apply'
5083 and 'faas'.
5084
5085 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5086
5087 * cli-utils.c (number_or_range_parser::get_number): Only handle
5088 numbers or convenience var as numbers.
5089 (parse_flags): New function.
5090 (parse_flags_qcs): New function.
5091 (number_or_range_parser::finished): Ensure parsing end is detected
5092 before end of string.
5093 * cli-utils.h (parse_flags): New function.
5094 (parse_flags_qcs): New function.
5095 (number_or_range_parser): Remove m_finished bool.
5096 (number_or_range_parser::skip_range): Set m_in_range to false.
5097
5098 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
5099
5100 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
5101 on Windows.
5102
5103 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5104 Jan Kratochvil <jan.kratochvil@redhat.com>
5105 Paul Fertser <fercerpav@gmail.com>
5106 Tsutomu Seki <sekiriki@gmail.com>
5107 Pedro Alves <palves@redhat.com>
5108
5109 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5110 'unittests/parse-connection-spec-selftests.c'.
5111 (COMMON_SFILES): Add 'common/netstuff.c'.
5112 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
5113 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
5114 * common/netstuff.c: New file.
5115 * common/netstuff.h: New file.
5116 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
5117 (wait_for_connect): Update comment. New parameter
5118 'gdb::optional<int> sock' instead of 'struct serial *scb'.
5119 Use 'sock' directly instead of 'scb->fd'.
5120 (try_connect): New function, with code from 'net_open'.
5121 (net_open): Rewrite main loop to deal with multiple
5122 sockets/addresses. Handle IPv6-style hostnames; implement
5123 support for IPv6 connections.
5124 * unittests/parse-connection-spec-selftests.c: New file.
5125
5126 2018-07-11 Pedro Alves <palves@redhat.com>
5127
5128 PR gdb/23377
5129 * remote.c (remote_target::remote_detach_pid): Call
5130 set_current_process.
5131
5132 2018-07-11 Pedro Alves <palves@redhat.com>
5133
5134 * h8300-tdep.c (h8300_gdbarch_init): Remove
5135 set_gdbarch_ecoff_reg_to_regnum calls.
5136
5137 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
5138
5139 PR c++/23373
5140 * c-typeprint.c (c_type_print_base_struct_union): Don't print
5141 offsets/sizes for static members of a class/struct.
5142
5143 2018-07-11 Alan Hayward <alan.hayward@arm.com>
5144
5145 * target-descriptions.c (tdesc_register_bitsize): Rename.
5146 * target-descriptions.h (tdesc_register_bitsize): Likewise.
5147 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
5148 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
5149
5150 2018-07-10 Tom Tromey <tom@tromey.com>
5151
5152 * breakpoint.c (moribund_locations): Now static and a
5153 std::vector.
5154 (breakpoint_init_inferior, moribund_breakpoint_here_p)
5155 (build_bpstat_chain, update_global_location_list)
5156 (breakpoint_retire_moribund): Update.
5157 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
5158 VEC.
5159
5160 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
5161
5162 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
5163 (riscv_register_reggroup_p): Use new function, remove unneeded
5164 parenthesis.
5165 (riscv_push_dummy_call): Extend assert to compare against xlen or
5166 flen based on register type.
5167
5168 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
5169
5170 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
5171
5172 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
5173
5174 * remote.c (show_hardware_watchpoint_limit): New function.
5175 (show_hardware_watchpoint_length_limit): New function.
5176 (show_hardware_breakpoint_limit): New function.
5177 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
5178 where appropriate, update help text.
5179
5180 2018-07-09 Tom Tromey <tom@tromey.com>
5181
5182 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
5183 (CLIBS): Don't mention NAT_CLIBS.
5184
5185 2018-07-09 Tom Tromey <tom@tromey.com>
5186
5187 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
5188 (LIBGDB_OBS, clean mostlyclean): Update.
5189 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
5190
5191 2018-07-09 Tom Tromey <tom@tromey.com>
5192
5193 * Makefile.in (%.c: %.y): Use ECHO_YACC.
5194 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
5195 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
5196
5197 2018-07-09 Tom Tromey <tom@tromey.com>
5198
5199 * Makefile.in (ALLDEPFILES): Remove exec.c.
5200 (COMMON_OBS): Remove exec.o.
5201 (COMMON_SFILES): Add exec.c.
5202
5203 2018-07-09 Tom Tromey <tom@tromey.com>
5204
5205 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
5206
5207 2018-07-09 Tom Tromey <tom@tromey.com>
5208
5209 * Makefile.in (clean mostlyclean): Remove stamp-version.
5210 (version.c): Depend on stamp-version.
5211 (stamp-version): New rule, from version.c rule.
5212
5213 2018-07-09 Tom Tromey <tom@tromey.com>
5214
5215 * Makefile.in (init.c): Depend on stamp-init.
5216 (stamp-init): New rule, from init.c rule.
5217 (clean mostlyclean): Remove stamp-init.
5218
5219 2018-07-09 Tom Tromey <tom@tromey.com>
5220
5221 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
5222 SUBDIR_GCC_COMPILE_SRCS.
5223
5224 2018-07-09 Tom Tromey <tom@tromey.com>
5225
5226 * Makefile.in (init.c): Remove some unused sed rules.
5227
5228 2018-07-09 Tom Tromey <tom@tromey.com>
5229
5230 * Makefile.in (TSOBS): Remove.
5231 (INIT_FILES): Update.
5232 (LIBGDB_OBS): Update.
5233 (COMMON_SFILES): Add inflow.c.
5234 (SFILES): Remove inflow.c.
5235
5236 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
5237
5238 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
5239
5240 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
5241
5242 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
5243 get_saveloc_name, is_signal_frame_name, step_name,
5244 init_remote_name, create_addr_space_name,
5245 destroy_addr_space_name, search_unwind_table_name,
5246 find_dyn_list_name): Constify.
5247
5248 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
5249
5250 * darwin-nat.c (darwin_pthread_kill): New function.
5251 (darwin_resume_thread): Use darwin_pthread_kill.
5252
5253 2018-07-05 Tom de Vries <tdevries@suse.de>
5254
5255 * macroexp.c (macro_buffer) <operator=>: New member function.
5256
5257 2018-07-04 Tom Tromey <tom@tromey.com>
5258
5259 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
5260
5261 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
5262
5263 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
5264 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
5265 * maint.c: Likewise.
5266 * top.c: Likewise.
5267
5268 2018-07-04 Joel Brobecker <brobecker@adacore.com>
5269
5270 * NEWS: Create a new section for the next release branch.
5271 Rename the section of the current branch, now that it has
5272 been cut.
5273
5274 2018-07-04 Joel Brobecker <brobecker@adacore.com>
5275
5276 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
5277 * version.in: Bump version to 8.2.50.DATE-git.
5278
5279 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
5280 Pedro Alves <palves@redhat.com>
5281
5282 * linux-nat.c (linux_init_ptrace): Rename to ...
5283 (linux_init_ptrace_procfs): ... this. Call
5284 linux_proc_init_warnings.
5285 (linux_nat_target::post_attach)
5286 (linux_nat_target::post_startup_inferior): Adjust.
5287 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
5288 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
5289
5290 2018-07-04 Tom de Vries <tdevries@suse.de>
5291
5292 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
5293 check ...
5294 (read_comp_unit_head): ... here.
5295
5296 2018-07-03 Tom Tromey <tom@tromey.com>
5297
5298 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
5299 (stop_tracing, tstatus_command)
5300 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
5301 (print_one_static_tracepoint_marker): Update.
5302 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
5303 std::vector.
5304 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
5305 VEC.
5306 (all_tracepoints, static_tracepoints_here): Return std::vector.
5307
5308 2018-07-03 Tom Tromey <tom@tromey.com>
5309
5310 * common/ptid.c (ptid_equal): Remove.
5311 * common/ptid.h (ptid_equal): Don't declare.
5312 * ada-tasks.c: Update.
5313 * breakpoint.c: Update.
5314 * common/agent.c: Update.
5315 * corelow.c: Update.
5316 * darwin-nat-info.c: Update.
5317 * darwin-nat.c: Update.
5318 * dcache.c: Update.
5319 * dtrace-probe.c: Update.
5320 * dummy-frame.c: Update.
5321 * fbsd-nat.c: Update.
5322 * frame.c: Update.
5323 * gdbthread.h: Update.
5324 * gnu-nat.c: Update.
5325 * go32-nat.c: Update.
5326 * inf-loop.c: Update.
5327 * inf-ptrace.c: Update.
5328 * infcall.c: Update.
5329 * infcmd.c: Update.
5330 * inflow.c: Update.
5331 * infrun.c: Update.
5332 * linux-fork.c: Update.
5333 * linux-nat.c: Update.
5334 * linux-thread-db.c: Update.
5335 * mi/mi-cmd-var.c: Update.
5336 * mi/mi-interp.c: Update.
5337 * mi/mi-main.c: Update.
5338 * nto-procfs.c: Update.
5339 * ppc-linux-tdep.c: Update.
5340 * procfs.c: Update.
5341 * python/py-inferior.c: Update.
5342 * python/py-record-btrace.c: Update.
5343 * python/py-record.c: Update.
5344 * ravenscar-thread.c: Update.
5345 * regcache.c: Update.
5346 * remote-sim.c: Update.
5347 * remote.c: Update.
5348 * sol-thread.c: Update.
5349 * solib.c: Update.
5350 * target.c: Update.
5351 * tui/tui-stack.c: Update.
5352 * varobj.c: Update.
5353 * windows-nat.c: Update.
5354 * windows-tdep.c: Update.
5355
5356 2018-07-03 Tom Tromey <tom@tromey.com>
5357
5358 * common/ptid.c (ptid_match): Remove.
5359 * common/ptid.h (ptid_match): Don't declare.
5360 * fbsd-nat.c: Update.
5361 * infcmd.c: Update.
5362 * infrun.c: Update.
5363 * linux-nat.c: Update.
5364 * record-btrace.c: Update.
5365 * regcache.c: Update.
5366 * remote.c: Update.
5367
5368 2018-07-03 Tom Tromey <tom@tromey.com>
5369
5370 * common/ptid.c (ptid_tid_p): Remove.
5371 * common/ptid.h (ptid_tid_p): Don't declare.
5372 * sol-thread.c: Update.
5373
5374 2018-07-03 Tom Tromey <tom@tromey.com>
5375
5376 * common/ptid.c (ptid_lwp_p): Remove.
5377 * common/ptid.h (ptid_lwp_p): Don't declare.
5378 * fbsd-nat.c: Update.
5379 * linux-nat.c: Update.
5380 * nat/linux-procfs.c: Update.
5381 * nat/x86-linux-dregs.c: Update.
5382 * sol-thread.c: Update.
5383
5384 2018-07-03 Tom Tromey <tom@tromey.com>
5385
5386 * common/ptid.c (ptid_is_pid): Remove.
5387 * common/ptid.h (ptid_is_pid): Don't declare.
5388 * infrun.c: Update.
5389 * linux-nat.c: Update.
5390 * mi/mi-interp.c: Update.
5391 * remote.c: Update.
5392 * thread.c: Update.
5393
5394 2018-07-03 Tom Tromey <tom@tromey.com>
5395
5396 * common/ptid.c (ptid_get_tid): Remove.
5397 * common/ptid.h (ptid_get_tid): Don't declare.
5398 * ada-tasks.c: Update.
5399 * aix-thread.c: Update.
5400 * bsd-uthread.c: Update.
5401 * darwin-nat.c: Update.
5402 * fbsd-nat.c: Update.
5403 * i386-darwin-nat.c: Update.
5404 * infrun.c: Update.
5405 * linux-tdep.c: Update.
5406 * nto-procfs.c: Update.
5407 * ppc-ravenscar-thread.c: Update.
5408 * python/py-infthread.c: Update.
5409 * ravenscar-thread.c: Update.
5410 * sol-thread.c: Update.
5411 * sparc-ravenscar-thread.c: Update.
5412 * windows-nat.c: Update.
5413
5414 2018-07-03 Tom Tromey <tom@tromey.com>
5415
5416 * common/ptid.c (ptid_get_lwp): Remove.
5417 * common/ptid.h (ptid_get_lwp): Don't declare.
5418 * aarch64-linux-nat.c: Update.
5419 * ada-tasks.c: Update.
5420 * aix-thread.c: Update.
5421 * amd64-linux-nat.c: Update.
5422 * arm-linux-nat.c: Update.
5423 * corelow.c: Update.
5424 * fbsd-nat.c: Update.
5425 * fbsd-tdep.c: Update.
5426 * gnu-nat.c: Update.
5427 * i386-cygwin-tdep.c: Update.
5428 * i386-gnu-nat.c: Update.
5429 * i386-linux-nat.c: Update.
5430 * ia64-linux-nat.c: Update.
5431 * inf-ptrace.c: Update.
5432 * infrun.c: Update.
5433 * linux-fork.c: Update.
5434 * linux-nat.c: Update.
5435 * linux-tdep.c: Update.
5436 * linux-thread-db.c: Update.
5437 * mips-linux-nat.c: Update.
5438 * nat/aarch64-linux-hw-point.c: Update.
5439 * nat/aarch64-linux.c: Update.
5440 * nat/linux-btrace.c: Update.
5441 * nat/linux-osdata.c: Update.
5442 * nat/linux-procfs.c: Update.
5443 * nat/x86-linux-dregs.c: Update.
5444 * obsd-nat.c: Update.
5445 * ppc-fbsd-nat.c: Update.
5446 * ppc-linux-nat.c: Update.
5447 * procfs.c: Update.
5448 * python/py-infthread.c: Update.
5449 * ravenscar-thread.c: Update.
5450 * remote.c: Update.
5451 * s390-linux-nat.c: Update.
5452 * sol-thread.c: Update.
5453 * sol2-tdep.c: Update.
5454 * spu-linux-nat.c: Update.
5455 * x86-linux-nat.c: Update.
5456 * xtensa-linux-nat.c: Update.
5457
5458 2018-07-03 Tom Tromey <tom@tromey.com>
5459
5460 * common/ptid.c (ptid_get_pid): Remove.
5461 * common/ptid.h (ptid_get_pid): Don't declare.
5462 * aarch64-linux-nat.c: Update.
5463 * ada-lang.c: Update.
5464 * aix-thread.c: Update.
5465 * alpha-bsd-nat.c: Update.
5466 * amd64-fbsd-nat.c: Update.
5467 * amd64-linux-nat.c: Update.
5468 * arm-linux-nat.c: Update.
5469 * arm-nbsd-nat.c: Update.
5470 * auxv.c: Update.
5471 * break-catch-syscall.c: Update.
5472 * breakpoint.c: Update.
5473 * bsd-uthread.c: Update.
5474 * corelow.c: Update.
5475 * ctf.c: Update.
5476 * darwin-nat.c: Update.
5477 * fbsd-nat.c: Update.
5478 * fbsd-tdep.c: Update.
5479 * gcore.c: Update.
5480 * gnu-nat.c: Update.
5481 * hppa-nbsd-nat.c: Update.
5482 * hppa-obsd-nat.c: Update.
5483 * i386-fbsd-nat.c: Update.
5484 * ia64-linux-nat.c: Update.
5485 * inf-ptrace.c: Update.
5486 * infcmd.c: Update.
5487 * inferior.c: Update.
5488 * inferior.h: Update.
5489 * inflow.c: Update.
5490 * infrun.c: Update.
5491 * linux-fork.c: Update.
5492 * linux-nat.c: Update.
5493 * linux-tdep.c: Update.
5494 * linux-thread-db.c: Update.
5495 * m68k-bsd-nat.c: Update.
5496 * mi/mi-interp.c: Update.
5497 * mi/mi-main.c: Update.
5498 * mips-linux-nat.c: Update.
5499 * mips-nbsd-nat.c: Update.
5500 * mips64-obsd-nat.c: Update.
5501 * nat/aarch64-linux-hw-point.c: Update.
5502 * nat/aarch64-linux.c: Update.
5503 * nat/linux-btrace.c: Update.
5504 * nat/linux-osdata.c: Update.
5505 * nat/linux-procfs.c: Update.
5506 * nat/x86-linux-dregs.c: Update.
5507 * nto-procfs.c: Update.
5508 * obsd-nat.c: Update.
5509 * ppc-linux-nat.c: Update.
5510 * ppc-nbsd-nat.c: Update.
5511 * ppc-obsd-nat.c: Update.
5512 * proc-service.c: Update.
5513 * procfs.c: Update.
5514 * python/py-inferior.c: Update.
5515 * python/py-infthread.c: Update.
5516 * ravenscar-thread.c: Update.
5517 * record.c: Update.
5518 * remote-sim.c: Update.
5519 * remote.c: Update.
5520 * rs6000-nat.c: Update.
5521 * s390-linux-nat.c: Update.
5522 * sh-nbsd-nat.c: Update.
5523 * sol-thread.c: Update.
5524 * sparc-nat.c: Update.
5525 * sparc64-tdep.c: Update.
5526 * spu-linux-nat.c: Update.
5527 * spu-tdep.c: Update.
5528 * target-debug.h: Update.
5529 * target.c: Update.
5530 * thread.c: Update.
5531 * tid-parse.c: Update.
5532 * tracefile-tfile.c: Update.
5533 * vax-bsd-nat.c: Update.
5534 * windows-nat.c: Update.
5535 * x86-linux-nat.c: Update.
5536 * x86-nat.c: Update.
5537
5538 2018-07-03 Tom Tromey <tom@tromey.com>
5539
5540 * common/ptid.c (pid_to_ptid): Remove.
5541 * common/ptid.h (pid_to_ptid): Don't declare.
5542 * aix-thread.c: Update.
5543 * arm-linux-nat.c: Update.
5544 * common/ptid.c: Update.
5545 * common/ptid.h: Update.
5546 * corelow.c: Update.
5547 * ctf.c: Update.
5548 * darwin-nat.c: Update.
5549 * fbsd-nat.c: Update.
5550 * fork-child.c: Update.
5551 * gnu-nat.c: Update.
5552 * go32-nat.c: Update.
5553 * inf-ptrace.c: Update.
5554 * infcmd.c: Update.
5555 * inferior.c: Update.
5556 * infrun.c: Update.
5557 * linux-fork.c: Update.
5558 * linux-nat.c: Update.
5559 * nat/aarch64-linux-hw-point.c: Update.
5560 * nat/fork-inferior.c: Update.
5561 * nat/x86-linux-dregs.c: Update.
5562 * nto-procfs.c: Update.
5563 * obsd-nat.c: Update.
5564 * procfs.c: Update.
5565 * progspace.c: Update.
5566 * remote.c: Update.
5567 * rs6000-nat.c: Update.
5568 * s390-linux-nat.c: Update.
5569 * sol-thread.c: Update.
5570 * spu-linux-nat.c: Update.
5571 * target.c: Update.
5572 * top.c: Update.
5573 * tracefile-tfile.c: Update.
5574 * windows-nat.c: Update.
5575
5576 2018-07-03 Tom Tromey <tom@tromey.com>
5577
5578 * common/ptid.h (ptid_build): Don't declare.
5579 * common/ptid.c (ptid_build): Remove.
5580 * aix-thread.c: Update.
5581 * bsd-kvm.c: Update.
5582 * bsd-uthread.c: Update.
5583 * common/agent.c: Update.
5584 * common/ptid.c: Update.
5585 * common/ptid.h: Update.
5586 * corelow.c: Update.
5587 * darwin-nat.c: Update.
5588 * fbsd-nat.c: Update.
5589 * gnu-nat.c: Update.
5590 * linux-fork.c: Update.
5591 * linux-nat.c: Update.
5592 * linux-thread-db.c: Update.
5593 * nat/linux-osdata.c: Update.
5594 * nat/linux-procfs.c: Update.
5595 * nto-procfs.c: Update.
5596 * obsd-nat.c: Update.
5597 * proc-service.c: Update.
5598 * procfs.c: Update.
5599 * ravenscar-thread.c: Update.
5600 * remote-sim.c: Update.
5601 * remote.c: Update.
5602 * sol-thread.c: Update.
5603 * target.c: Update.
5604 * windows-nat.c: Update.
5605
5606 2018-07-03 Tom Tromey <tom@tromey.com>
5607
5608 * infrun.c (follow_exec): Use exit_inferior_silent.
5609 * inferior.c (exit_inferior_num_silent): Remove.
5610 * inferior.h (exit_inferior_num_silent): Don't declare.
5611
5612 2018-07-03 Tom Tromey <tom@tromey.com>
5613
5614 PR cli/23340:
5615 * darwin-nat.c (darwin_attach_pid): Reset inferior and
5616 inferior_ptid on error.
5617
5618 2018-07-02 Maciej W. Rozycki <macro@mips.com>
5619 Simon Marchi <simon.marchi@polymtl.ca>
5620
5621 PR tdep/8282
5622 * disasm.h (gdb_disassembler): Add
5623 `m_disassembler_options_holder'. member
5624 * disasm.c (get_all_disassembler_options): New function.
5625 (gdb_disassembler::gdb_disassembler): Use it.
5626 (gdb_buffered_insn_length_init_dis): Likewise.
5627 (gdb_buffered_insn_length): Adjust accordingly.
5628 (set_disassembler_options): Handle options with arguments.
5629 (show_disassembler_options_sfunc): Likewise. Add a leading new
5630 line if showing options with descriptions.
5631 (disassembler_options_completer): Adapt to using the
5632 `disasm_options_and_args_t' structure.
5633 * mips-tdep.c (mips_disassembler_options): New variable.
5634 (mips_disassembler_options_o32): Likewise.
5635 (mips_disassembler_options_n32): Likewise.
5636 (mips_disassembler_options_n64): Likewise.
5637 (gdb_print_insn_mips): Don't set `disassembler_options'.
5638 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
5639 functions.
5640 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
5641 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
5642 `gdbarch_disassembler_options_implicit' and
5643 `gdbarch_valid_disassembler_options'.
5644 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
5645 `disasm_options_and_args_t' structure.
5646 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
5647 method.
5648 (valid_disassembler_options): Switch from `disasm_options_t' to
5649 the `disasm_options_and_args_t' structure.
5650 * NEWS: Document `set disassembler-options' support for the MIPS
5651 target.
5652 * gdbarch.h: Regenerate.
5653 * gdbarch.c: Regenerate.
5654
5655 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
5656
5657 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
5658
5659 2018-06-29 Joel Brobecker <brobecker@adacore.com>
5660
5661 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
5662 parameter in call to amd64_target_description.
5663 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
5664 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
5665 (amd64fbsd_init_abi): Likewise.
5666 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
5667 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5668 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5669 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
5670
5671 2018-06-29 Pedro Alves <palves@redhat.com>
5672
5673 * gdb/amd64-tdep.h (amd64_create_target_description): Add
5674 "segments" parameter.
5675 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
5676 (_initialize_amd64_tdep): Update call to
5677 amd64_create_target_description.
5678 (amd64_target_description): Add "segments" parameter. Adjust
5679 the implementation to use it.
5680 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
5681 call to amd64_create_target_description.
5682 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
5683 * gdb/arch/amd64.h (amd64_create_target_description): Add
5684 "segments" register.
5685 * gdb/arch/amd64.c (amd64_create_target_description): Add
5686 "segments" parameter. Call create_feature_i386_64bit_segments
5687 only if SEGMENTS is true.
5688 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
5689 call to amd64_create_target_description.
5690
5691 2018-06-29 Pedro Alves <palves@redhat.com>
5692
5693 * thread.c (thread_target_id_str): New, factored out from ...
5694 (print_thread_info_1): ... here. Use it to compute the max
5695 "Target Id" column width.
5696
5697 2018-06-29 Pedro Alves <palves@redhat.com>
5698
5699 * remote.c (remote_target::extra_thread_info): Delete
5700 'display_buf' and 'n' locals. from the cache, regardless of
5701 packet mechanims is in use. Use cache for qThreadExtra and qP
5702 methods too.
5703
5704 2018-06-29 Pedro Alves <palves@redhat.com>
5705
5706 * blockframe.c (find_pc_sect_containing_function): New function.
5707 * breakpoint.c (print_breakpoint_location): Don't call
5708 find_pc_sect_function.
5709 * linespec.c (create_sals_line_offset): Record the location's
5710 symbol in the sal.
5711 * linespec.c (convert_address_location_to_sals): Fill in sal's
5712 symbol with find_pc_sect_containing_function.
5713 * symtab.c (find_function_start_sal): Rename to ...
5714 (find_function_start_sal_1): ... this.
5715 (find_function_start_sal): Reimplement as wrapper around
5716 find_function_start_sal_1, and use
5717 find_pc_sect_containing_function to fill in the sal's symbol.
5718 (find_function_start_sal(symbol*, bool)): Adjust.
5719 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
5720 comments.
5721 (find_pc_sect_containing_function): Declare.
5722
5723 2018-06-29 Pedro Alves <palves@redhat.com>
5724
5725 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
5726 true if the the location has no symbol.
5727
5728 2018-06-28 Tom Tromey <tom@tromey.com>
5729
5730 * NEWS: Mention --enable-codesign.
5731 * silent-rules.mk (ECHO_SIGN): New variable.
5732 * configure.ac: Add --enable-codesign.
5733 * configure: Rebuild.
5734 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
5735 (gdb$(EXEEXT)): Optionally invoke codesign.
5736
5737 2018-06-28 Pedro Alves <palves@redhat.com>
5738
5739 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
5740 comments.
5741 (switch_to_thread_no_regs): Adjust comment.
5742 * infcmd.c (stop_pc): Delete.
5743 (post_create_inferior, info_program_command): Replace references
5744 to stop_pc with references to thread_info->suspend.stop_pc.
5745 * inferior.h (stop_pc): Delete declaration.
5746 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
5747 (handle_inferior_event_1, handle_signal_stop)
5748 (process_event_stop_test, keep_going_stepped_thread)
5749 (handle_step_into_function, handle_step_into_function_backward)
5750 (print_stop_location): Replace references to stop_pc with
5751 references to thread_info->suspend.stop_pc.
5752 (struct infcall_suspend_state) <stop_pc>: Delete field.
5753 (save_infcall_suspend_state, restore_infcall_suspend_state):
5754 Remove references to inf_stat->stop_pc.
5755 * linux-fork.c (fork_load_infrun_state): Likewise.
5756 * record-btrace.c (record_btrace_set_replay): Likewise.
5757 * record-full.c (record_full_goto_entry): Likewise.
5758 * remote.c (print_one_stopped_thread): Likewise.
5759 * target.c (target_resume): Extend comment.
5760 * thread.c (set_executing_thread): New.
5761 (set_executing): Use it.
5762 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
5763 Remove references to stop_pc.
5764
5765 2018-06-28 Pedro Alves <palves@redhat.com>
5766
5767 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
5768 Moving fetching stop_pc until after ecs->event_thread is refreshed.
5769
5770 2018-06-28 Tom Tromey <tom@tromey.com>
5771
5772 * coffread.c (coff_symfile_finish): Update.
5773 * xcoffread.c (xcoff_symfile_finish): Update.
5774 * elfread.c (elf_symfile_finish): Update.
5775 * symfile.h (dwarf2_free_objfile): Don't declare.
5776 * dwarf2read.c (_initialize_dwarf2_read): Use
5777 register_objfile_data_with_cleanup.
5778 (dwarf2_free_objfile): Now static. Change signature.
5779
5780 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5781
5782 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
5783 option "-o" to add-symbol-file-load to add an offset to each
5784 section's load address.
5785 * symfile.c (set_objfile_default_section_offset): New function.
5786
5787 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5788
5789 * symfile.c (add_symbol_file_command): Make sure that sections
5790 with the same name are sorted in the same order.
5791
5792 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5793
5794 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
5795 require the second argument. If omitted, load sections at the
5796 addresses specified in the file.
5797
5798 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5799
5800 * symfile.c (symbol_file_command, symbol_file_add_main_1)
5801 (_initialize_symfile): Add option "-o" to symbol-file to add an
5802 offset to each section of the symbol file.
5803
5804 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
5805
5806 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
5807
5808 2018-06-27 Tom Tromey <tom@tromey.com>
5809
5810 * stack.c (_initialize_stack): Update "func" help text.
5811
5812 2018-06-27 Tom Tromey <tom@tromey.com>
5813
5814 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
5815 std::vector.
5816 (unwind_infopy_str, pyuw_create_unwind_info)
5817 (unwind_infopy_add_saved_register, pyuw_sniffer)
5818 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
5819 Update.
5820 (struct saved_reg): Add constructor.
5821 <value>: Now a gdbpy_ref<>.
5822
5823 2018-06-27 Tom Tromey <tom@tromey.com>
5824
5825 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
5826
5827 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5828
5829 * gdb-gdb.py.in: Format using autopep8.
5830
5831 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5832
5833 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
5834 (type_lookup_function): Recognize CORE_ADDR values.
5835
5836 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5837
5838 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
5839 print tag_name.
5840
5841 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5842
5843 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
5844 <__lt__>: Add.
5845
5846 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5847
5848 * gdb-gdb.py: Move to...
5849 * gdb-gdb.py.in: ... here.
5850 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
5851 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
5852 dependencies.
5853 (distclean): Remove gdb-gdb.py when cleaning.
5854 (gdb-gdb.py, gdb-gdb.gdb): New rules.
5855 * configure: Re-generate.
5856
5857 2018-06-27 Pedro Alves <palves@redhat.com>
5858
5859 * proc-service.c (get_ps_regcache): New.
5860 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
5861 (ps_lsetfpregs): Use it.
5862
5863 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
5864
5865 PR gdb/21695
5866 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
5867 (dwarf_decode_lines_1): Adjust.
5868
5869 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
5870
5871 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
5872 override.
5873 <info_proc>: Likewise.
5874
5875 2018-06-26 Joel Brobecker <brobecker@adacore.com>
5876
5877 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
5878 to windows_fetch_one_register, and only handle the case of
5879 fetching one register. Move the code that reloads the context
5880 and iterates over all registers if R is negative to...
5881 (windows_nat_target::fetch_registers): ... here.
5882 (do_windows_store_inferior_registers): Rename to
5883 windows_store_one_register, and only handle the case of storing
5884 one register. Move the code that handles the case where r is
5885 negative to...
5886 (windows_nat_target::store_registers) ... here.
5887
5888 2018-06-26 Tom Tromey <tom@tromey.com>
5889
5890 PR rust/22574:
5891 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
5892 * rust-lang.c (rust_print_struct_def): Add podata parameter.
5893 Update.
5894 (rust_internal_print_type): Add podata parameter.
5895 (rust_print_type): Update.
5896
5897 2018-06-26 Tom Tromey <tom@tromey.com>
5898
5899 * typeprint.h (struct print_offset_data) <update, finish,
5900 maybe_print_hole>: New methods.
5901 <indentation>: New constant.
5902 * typeprint.c (print_offset_data::indentation): Define.
5903 (print_offset_data::maybe_print_hole, print_offset_data::update)
5904 (print_offset_data::finish): Move from c-typeprint.c and rename.
5905 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
5906 (print_spaces_filtered_with_print_options): Update.
5907 (c_print_type_union_field_offset, maybe_print_hole)
5908 (c_print_type_struct_field_offset): Move to typeprint.c and
5909 rename.
5910 (c_type_print_base_struct_union): Update.
5911
5912 2018-06-25 Pedro Alves <palves@redhat.com>
5913
5914 * gdbthread.h (thread_info_ref, delete_thread)
5915 (delete_thread_silent, first_thread_of_inferior)
5916 (any_thread_of_inferior, switch_to_thread)
5917 (enable_thread_stack_temporaries)
5918 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
5919 (get_last_thread_stack_temporary)
5920 (value_in_thread_stack_temporaries, can_access_registers_thread):
5921 Spell out "struct thread_info" instead of just "thread_info".
5922 * inferior.h (notice_new_inferior): Likewise.
5923
5924 2018-06-25 Pedro Alves <palves@redhat.com>
5925
5926 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5927 pass thread_info pointer to delete_thread.
5928 (windows_nat_target::detach): Pass inferior pointer to
5929 detach_inferior.
5930 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
5931 delete_thread.
5932 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
5933 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
5934 and pass a thread_info pointer to delete_thread.
5935 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
5936 pass thread_info pointer to delete_thread.
5937 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
5938 delete_thread_silent call.
5939 * procfs.c (procfs_target::detach): Pass inferior pointer to
5940 detach_inferior.
5941 (procfs_target::wait): Pass thread_info pointer to delete_thread.
5942 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
5943 delete_thread_silent call.
5944 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
5945 pass thread_info pointer to delete_thread.
5946 (windows_nat_target::detach): Pass inferior pointer to
5947 delete_inferior.
5948
5949 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5950
5951 * regcache.c (readable_regcache::read_part): Fix asserts.
5952 (reg_buffer::raw_collect_part): New function.
5953 (regcache::write_part): Fix asserts.
5954 (reg_buffer::raw_supply_part): New function.
5955 (regcache::transfer_regset_register): New helper function.
5956 (regcache::transfer_regset): Call new functions.
5957 (regcache_supply_regset): Use gdb_byte*.
5958 (regcache::supply_regset): Likewise.
5959 (regcache_collect_regset): Likewise.
5960 (regcache::collect_regset): Likewise.
5961 * regcache.h (reg_buffer::raw_collect_part): New declaration.
5962 (reg_buffer::raw_supply_part): Likewise.
5963 (regcache::transfer_regset_register): Likewise.
5964 (regcache::transfer_regset): Use gdb_byte*.
5965
5966 2018-06-22 Alan Hayward <alan.hayward@arm.com>
5967
5968 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
5969
5970 2018-06-21 Pedro Alves <palves@redhat.com>
5971
5972 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
5973 instead of a ptid_t. All callers adjusted.
5974 * ada-tasks.c (ada_get_task_number): Likewise. All callers
5975 adjusted.
5976 (print_ada_task_info, display_current_task_id, task_command_1):
5977 Adjust.
5978 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
5979 inferior_thread.
5980 (breakpoint_kind): Adjust.
5981 (remove_breakpoints_pid): Rename to ...
5982 (remove_breakpoints_inf): ... this. Adjust to take an inferior
5983 pointer. All callers adjusted.
5984 (bpstat_clear_actions): Use inferior_thread.
5985 (get_bpstat_thread): New.
5986 (bpstat_do_actions): Use it.
5987 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
5988 to take a thread_info pointer. All callers adjusted.
5989 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
5990 (breakpoint_re_set_thread): Use inferior_thread.
5991 * breakpoint.h (struct inferior): Forward declare.
5992 (bpstat_stop_status): Update.
5993 (remove_breakpoints_pid): Delete.
5994 (remove_breakpoints_inf): New.
5995 * bsd-uthread.c (bsd_uthread_target::wait)
5996 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
5997 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
5998 (maint_btrace_packet_history_cmd)
5999 (maint_btrace_clear_packet_history_cmd): Adjust.
6000 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
6001 inferior_thread.
6002 * cli/cli-interp.c: Include "inferior.h".
6003 * common/refcounted-object.h (struct
6004 refcounted_object_ref_policy): New.
6005 * compile/compile-object-load.c: Include gdbthread.h.
6006 (store_regs): Use inferior_thread.
6007 * corelow.c (core_target::close): Use current_inferior.
6008 (core_target_open): Adjust to use first_thread_of_inferior and use
6009 the current inferior.
6010 * ctf.c (ctf_target::close): Adjust to use current_inferior.
6011 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
6012 <thread>: ... this new field. All references adjusted.
6013 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
6014 Take a thread_info pointer instead of a ptid_t.
6015 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
6016 (dummy_frame_discard, register_dummy_frame_dtor): Take a
6017 thread_info pointer instead of a ptid_t.
6018 * elfread.c: Include "inferior.h".
6019 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
6020 Use inferior_thread.
6021 * eval.c (evaluate_subexp): Likewise.
6022 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
6023 inferior_thread.
6024 * gdb_proc_service.h (struct thread_info): Forward declare.
6025 (struct ps_prochandle) <ptid>: Delete, replaced by ...
6026 <thread>: ... this new field. All references adjusted.
6027 * gdbarch.h, gdbarch.c: Regenerate.
6028 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
6029 'thread' parameter. All implementations and callers adjusted.
6030 * gdbthread.h (thread_info) <set_running>: New method.
6031 (delete_thread, delete_thread_silent): Take a thread_info pointer
6032 instead of a ptid.
6033 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
6034 (first_thread_of_process): Delete, replaced by ...
6035 (first_thread_of_inferior): ... this new function. All callers
6036 adjusted.
6037 (any_live_thread_of_process): Delete, replaced by ...
6038 (any_live_thread_of_inferior): ... this new function. All callers
6039 adjusted.
6040 (switch_to_thread, switch_to_no_thread): Declare.
6041 (is_executing): Delete.
6042 (enable_thread_stack_temporaries): Update comment.
6043 <enable_thread_stack_temporaries>: Take a thread_info pointer
6044 instead of a ptid_t. Incref the thread.
6045 <~enable_thread_stack_temporaries>: Decref the thread.
6046 <m_ptid>: Delete
6047 <m_thr>: New.
6048 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
6049 (get_last_thread_stack_temporary)
6050 (value_in_thread_stack_temporaries, can_access_registers_thread):
6051 Take a thread_info pointer instead of a ptid_t. All callers
6052 adjusted.
6053 * infcall.c (get_call_return_value): Use inferior_thread.
6054 (run_inferior_call): Work with thread pointers instead of ptid_t.
6055 (call_function_by_hand_dummy): Work with thread pointers instead
6056 of ptid_t. Use thread_info_ref.
6057 * infcmd.c (proceed_thread_callback): Access thread's state
6058 directly.
6059 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
6060 access thread's state directly.
6061 (continue_command): Use inferior_thread.
6062 (info_program_command): Use find_thread_ptid and access thread
6063 state directly.
6064 (proceed_after_attach_callback): Use thread state directly.
6065 (notice_new_inferior): Take a thread_info pointer instead of a
6066 ptid_t. All callers adjusted.
6067 (exit_inferior): Take an inferior pointer instead of a pid. All
6068 callers adjusted.
6069 (exit_inferior_silent): New.
6070 (detach_inferior): Delete.
6071 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
6072 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
6073 (detach_inferior_command, kill_inferior_command): Use
6074 find_inferior_id instead of valid_gdb_inferior_id and
6075 gdb_inferior_id_to_pid.
6076 (inferior_command): Use inferior and thread pointers.
6077 * inferior.h (struct thread_info): Forward declare.
6078 (notice_new_inferior): Take a thread_info pointer instead of a
6079 ptid_t. All callers adjusted.
6080 (detach_inferior): Delete declaration.
6081 (exit_inferior, exit_inferior_silent): Take an inferior pointer
6082 instead of a pid. All callers adjusted.
6083 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
6084 (valid_gdb_inferior_id): Delete.
6085 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
6086 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
6087 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
6088 ...
6089 <inf>: ... this new field.
6090 <step_ptid>: Delete, replaced by ...
6091 <step_thread>: ... this new field.
6092 (get_displaced_stepping_state): Take an inferior pointer instead
6093 of a pid. All callers adjusted.
6094 (displaced_step_in_progress_any_inferior): Adjust.
6095 (displaced_step_in_progress_thread): Take a thread pointer instead
6096 of a ptid_t. All callers adjusted.
6097 (displaced_step_in_progress, add_displaced_stepping_state): Take
6098 an inferior pointer instead of a pid. All callers adjusted.
6099 (get_displaced_step_closure_by_addr): Adjust.
6100 (remove_displaced_stepping_state): Take an inferior pointer
6101 instead of a pid. All callers adjusted.
6102 (displaced_step_prepare_throw, displaced_step_prepare)
6103 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
6104 All callers adjusted.
6105 (start_step_over): Adjust.
6106 (infrun_thread_ptid_changed): Remove bit updating ptids in the
6107 displaced step queue.
6108 (do_target_resume): Adjust.
6109 (fetch_inferior_event): Use inferior_thread.
6110 (context_switch, get_inferior_stop_soon): Take an
6111 execution_control_state pointer instead of a ptid_t. All callers
6112 adjusted.
6113 (switch_to_thread_cleanup): Delete.
6114 (stop_all_threads): Use scoped_restore_current_thread.
6115 * inline-frame.c: Include "gdbthread.h".
6116 (inline_state) <inline_state>: Take a thread pointer instead of a
6117 ptid_t. All callers adjusted.
6118 <ptid>: Delete, replaced by ...
6119 <thread>: ... this new field.
6120 (find_inline_frame_state): Take a thread pointer instead of a
6121 ptid_t. All callers adjusted.
6122 (skip_inline_frames, step_into_inline_frame)
6123 (inline_skipped_frames, inline_skipped_symbol): Take a thread
6124 pointer instead of a ptid_t. All callers adjusted.
6125 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
6126 (inline_skipped_frames, inline_skipped_symbol): Likewise.
6127 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
6128 pointers directly.
6129 * linux-nat.c (get_detach_signal): Likewise.
6130 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
6131 (thread_db_notice_clone): Adjust.
6132 (thread_db_find_new_threads_silently)
6133 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
6134 a thread pointer instead of a ptid_t. All callers adjusted.
6135 * mi/mi-cmd-var.c: Include "inferior.h".
6136 (mi_cmd_var_update_iter): Update to use thread pointers.
6137 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
6138 inferior directly.
6139 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
6140 out to ...
6141 (mi_output_running): ... this new function.
6142 (mi_on_resume_1): Adjust to use it.
6143 (mi_user_selected_context_changed): Adjust to use inferior_thread.
6144 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
6145 directly.
6146 (interrupt_thread_callback): : Adjust to use thread and inferior
6147 pointers.
6148 * proc-service.c: Include "gdbthread.h".
6149 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
6150 * progspace-and-thread.c: Include "inferior.h".
6151 * progspace.c: Include "inferior.h".
6152 * python/py-exitedevent.c (create_exited_event_object): Adjust to
6153 hold a reference to an inferior_object.
6154 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
6155 inferior_thread.
6156 * python/py-inferior.c (struct inferior_object): Give the type a
6157 tag name instead of a typedef.
6158 (python_on_normal_stop): No need to check if the current thread is
6159 listed.
6160 (inferior_to_inferior_object): Change return type to
6161 inferior_object. All callers adjusted.
6162 (find_thread_object): Delete, bits factored out to ...
6163 (thread_to_thread_object): ... this new function.
6164 * python/py-infthread.c (create_thread_object): Use
6165 inferior_to_inferior_object.
6166 (thpy_is_stopped): Use thread pointer directly.
6167 (gdbpy_selected_thread): Use inferior_thread.
6168 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
6169 field, replaced with ...
6170 <thread>: ... this new field. All users adjusted.
6171 (btpy_insn_or_gap_new): Drop const.
6172 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
6173 callers adjusted.
6174 * python/py-record.c: Include "gdbthread.h".
6175 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
6176 a ptid_t. All callers adjusted.
6177 (gdbpy_current_recording): Use inferior_thread.
6178 * python/py-record.h (recpy_record_object) <ptid>: Delete
6179 field, replaced with ...
6180 <thread>: ... this new field. All users adjusted.
6181 (recpy_element_object) <ptid>: Delete
6182 field, replaced with ...
6183 <thread>: ... this new field. All users adjusted.
6184 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
6185 a ptid_t. All callers adjusted.
6186 * python/py-threadevent.c: Include "gdbthread.h".
6187 (get_event_thread): Use thread_to_thread_object.
6188 * python/python-internal.h (struct inferior_object): Forward
6189 declare.
6190 (find_thread_object, find_inferior_object): Delete declarations.
6191 (thread_to_thread_object, inferior_to_inferior_object): New
6192 declarations.
6193 * record-btrace.c: Include "inferior.h".
6194 (require_btrace_thread): Use inferior_thread.
6195 (record_btrace_frame_sniffer)
6196 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
6197 (get_thread_current_frame): Use scoped_restore_current_thread and
6198 switch_to_thread.
6199 (get_thread_current_frame): Use thread pointer directly.
6200 (record_btrace_replay_at_breakpoint): Use thread's inferior
6201 pointer directly.
6202 * record-full.c: Include "inferior.h".
6203 * regcache.c: Include "gdbthread.h".
6204 (get_thread_arch_regcache): Use the inferior's address space
6205 directly.
6206 (get_thread_regcache, registers_changed_thread): New.
6207 * regcache.h (get_thread_regcache(thread_info *thread)): New
6208 overload.
6209 (registers_changed_thread): New.
6210 (remote_target) <remote_detach_1>: Swap order of parameters.
6211 (remote_add_thread): <remote_add_thread>: Return the new thread.
6212 (get_remote_thread_info(ptid_t)): New overload.
6213 (remote_target::remote_notice_new_inferior): Use thread pointers
6214 directly.
6215 (remote_target::process_initial_stop_replies): Use
6216 thread_info::set_running.
6217 (remote_target::remote_detach_1, remote_target::detach)
6218 (extended_remote_target::detach): Adjust.
6219 * stack.c (frame_show_address): Use inferior_thread.
6220 * target-debug.h (target_debug_print_thread_info_pp): New.
6221 * target-delegates.c: Regenerate.
6222 * target.c (default_thread_address_space): Delete.
6223 (memory_xfer_partial_1): Use current_inferior.
6224 (target_detach): Use current_inferior.
6225 (target_thread_address_space): Delete.
6226 (generic_mourn_inferior): Use current_inferior.
6227 * target.h (struct target_ops) <thread_address_space>: Delete.
6228 (target_thread_address_space): Delete.
6229 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
6230 pointers directly.
6231 (delete_thread_1, delete_thread, delete_thread_silent): Take a
6232 thread pointer instead of a ptid_t. Adjust all callers.
6233 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
6234 (first_thread_of_process): Delete, replaced by ...
6235 (first_thread_of_inferior): ... this new function. All callers
6236 adjusted.
6237 (any_thread_of_process): Rename to ...
6238 (any_thread_of_inferior): ... this, and take an inferior pointer.
6239 (any_live_thread_of_process): Rename to ...
6240 (any_live_thread_of_inferior): ... this, and take an inferior
6241 pointer.
6242 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
6243 (value_in_thread_stack_temporaries)
6244 (get_last_thread_stack_temporary): Take a thread pointer instead
6245 of a ptid_t. Adjust all callers.
6246 (thread_info::set_running): New.
6247 (validate_registers_access): Use inferior_thread.
6248 (can_access_registers_ptid): Rename to ...
6249 (can_access_registers_thread): ... this, and take a thread
6250 pointer.
6251 (print_thread_info_1): Adjust to compare thread pointers instead
6252 of ptids.
6253 (switch_to_no_thread, switch_to_thread): Make extern.
6254 (scoped_restore_current_thread::~scoped_restore_current_thread):
6255 Use m_thread pointer directly.
6256 (scoped_restore_current_thread::scoped_restore_current_thread):
6257 Use inferior_thread.
6258 (thread_command): Use thread pointer directly.
6259 (thread_num_make_value_helper): Use inferior_thread.
6260 * top.c (execute_command): Use inferior_thread.
6261 * tui/tui-interp.c: Include "inferior.h".
6262 * varobj.c (varobj_create): Use inferior_thread.
6263 (value_of_root_1): Use find_thread_global_id instead of
6264 global_thread_id_to_ptid.
6265
6266 2018-06-21 Alan Hayward <alan.hayward@arm.com>
6267
6268 * regcache.c (readable_regcache::read_part): Avoid memcpy when
6269 possible.
6270 (regcache::write_part): Likewise.
6271 (readable_regcache::cooked_read_part): Update comment.
6272 (readable_regcache::cooked_write_part): Likewise.
6273 * regcache.h: (readable_regcache::read_part): Likewise.
6274 (regcache::write_part): Likewise.
6275
6276 2018-06-21 Richard Bunt <richard.bunt@arm.com>
6277 Dirk Schubert <dirk.schubert@arm.com>
6278
6279 * aarch64-linux-nat.c (post_attach): New.
6280 (aarch64_linux_nat_target::post_attach): Override post_attach to
6281 record the number of hardware debug registers.
6282
6283 2018-06-20 Tom Tromey <tom@tromey.com>
6284
6285 * python/py-param.c (add_setshow_generic): Make parameters const.
6286 (parmpy_init): Update.
6287
6288 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
6289
6290 * regcache.h (regcache_cooked_read_ftype): Rename to...
6291 (register_read_ftype): ...this, change type to function_view.
6292 (class reg_buffer) <save>: Remove src parameter.
6293 (readonly_detached_regcache) <readonly_detached_regcache>: Make
6294 parameter non-const in first overload. Remove src parameter in
6295 second overload.
6296 * regcache.c (do_cooked_read): Remove.
6297 (readonly_detached_regcache::readonly_detached_regcache): Make
6298 parameter non-const, adjust call to other constructor.
6299 (reg_buffer::save): Remove src parameter.
6300 * frame.c (do_frame_register_read): Remove.
6301 (frame_save_as_regcache): Use lambda function.
6302 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
6303 parameter to ppu2spu_data *.
6304 (ppu2spu_sniffer): Use lambda function.
6305
6306 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
6307
6308 * record-full.c (record_full_target::insert_breakpoint): Remove
6309 "struct" keyword, add const.
6310
6311 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
6312
6313 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
6314 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
6315 * configure.ac: Remove AC_PREREQ, add missing quoting.
6316 * gnulib/configure.ac: Modernize usage of
6317 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
6318 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
6319 (AUTOMAKE_VERSION): Bump to 1.15.1.
6320 * configure: Re-generate.
6321 * config.in: Re-generate.
6322 * aclocal.m4: Re-generate.
6323 * gnulib/aclocal.m4: Re-generate.
6324 * gnulib/config.in: Re-generate.
6325 * gnulib/configure: Re-generate.
6326 * gnulib/import/Makefile.in: Re-generate.
6327
6328 2018-06-19 Pedro Alves <palves@redhat.com>
6329
6330 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
6331 (lookup_minimal_symbol_by_pc_section): ... here with
6332 gdb_assert_not_reached added.
6333
6334 2018-06-19 Pedro Alves <palves@redhat.com>
6335
6336 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
6337 parameter with a block parameter. Compare location's block symbol
6338 with the frame's block instead of addresses.
6339 (skip_inline_frames): Pass the current block instead of the
6340 frame's address. Break out as soon as we determine the frame
6341 should not be skipped.
6342
6343 2018-06-18 Tom Tromey <tom@tromey.com>
6344
6345 * solib-aix.c (solib_aix_get_section_offsets): Return
6346 unique_xmalloc_ptr.
6347 (solib_aix_solib_create_inferior_hook): Update.
6348
6349 2018-06-18 Tom Tromey <tom@tromey.com>
6350
6351 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
6352
6353 2018-06-18 Tom Tromey <tom@tromey.com>
6354
6355 * solib-frv.c (frv_relocate_main_executable): Use
6356 unique_xmalloc_ptr.
6357 * solib-dsbt.c (dsbt_relocate_main_executable): Use
6358 unique_xmalloc_ptr.
6359
6360 2018-06-18 Tom Tromey <tom@tromey.com>
6361
6362 * objfiles.h (inhibit_section_map_updates): Update.
6363 (resume_section_map_updates, resume_section_map_updates_cleanup):
6364 Remove.
6365 * solib-svr4.c (svr4_handle_solib_event): Update.
6366 * objfiles.c (inhibit_section_map_updates): Return
6367 scoped_restore_tmpl<int>.
6368 (resume_section_map_updates, resume_section_map_updates_cleanup):
6369 Remove.
6370
6371 2018-06-18 Tom Tromey <tom@tromey.com>
6372
6373 * valprint.h (read_string): Update.
6374 * valprint.c (read_string): Change type of "buffer".
6375 (val_print_string): Update.
6376 * python/py-value.c (valpy_string): Update.
6377 * language.h (struct language_defn) <la_get_string>: Change
6378 type of "buffer".
6379 (default_get_string, c_get_string): Update.
6380 * language.c (default_get_string): Change type of "buffer".
6381 * guile/scm-value.c (gdbscm_value_to_string): Update.
6382 * c-lang.c (c_get_string): Change type of "buffer".
6383
6384 2018-06-18 Tom Tromey <tom@tromey.com>
6385
6386 * ser-mingw.c (struct pipe_state_destroyer): New.
6387 (pipe_state_up): New typedef.
6388 (cleanup_pipe_state): Remove.
6389 (pipe_windows_open): Use pipe_state_up. Don't release argv.
6390
6391 2018-06-18 Tom Tromey <tom@tromey.com>
6392
6393 * rust-lang.h (rust_yyerror): Don't declare.
6394 * rust-lang.c (rust_language_defn): Update.
6395 * rust-exp.y (yyerror): Now static.
6396 * parse.c (parse_exp_in_context_1): Update.
6397 * p-lang.h (p_yyerror): Don't declare.
6398 * p-lang.c (p_language_defn): Update.
6399 * p-exp.y (yyerror): Now static.
6400 * opencl-lang.c (opencl_language_defn): Update.
6401 * objc-lang.c (objc_language_defn): Update.
6402 * m2-lang.h (m2_yyerror): Don't declare.
6403 * m2-lang.c (m2_language_defn): Update.
6404 * m2-exp.y (yyerror): Now static.
6405 * language.h (struct language_defn) <la_error>: Remove.
6406 * language.c (unk_lang_error): Remove.
6407 (unknown_language_defn, auto_language_defn): Remove.
6408 * go-lang.h (go_yyerror): Don't declare.
6409 * go-lang.c (go_language_defn): Update.
6410 * go-exp.y (yyerror): Now static.
6411 * f-lang.h (f_yyerror): Don't declare.
6412 * f-lang.c (f_language_defn): Update.
6413 * f-exp.y (yyerror): Now static.
6414 * d-lang.h (d_yyerror): Don't declare.
6415 * d-lang.c (d_language_defn): Update.
6416 * d-exp.y (yyerror): Now static.
6417 * c-lang.h (c_yyerror): Don't declare.
6418 * c-lang.c (c_language_defn, cplus_language_defn)
6419 (asm_language_defn, minimal_language_defn): Update.
6420 * c-exp.y (yyerror): Now static.
6421 * ada-lang.h (ada_yyerror): Don't declare.
6422 * ada-lang.c (ada_language_defn): Update.
6423 * ada-exp.y (yyerror): Now static.
6424
6425 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6426
6427 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
6428 (store_sveregs_to_thread): Likewise.
6429 (aarch64_linux_fetch_inferior_registers): Check for SVE.
6430 (aarch64_linux_store_inferior_registers): Likewise.
6431 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
6432 function.
6433 (aarch64_sve_regs_copy_to_regcache): Likewise.
6434 (aarch64_sve_regs_copy_from_regcache): Likewise.
6435 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
6436 declaration.
6437 (aarch64_sve_regs_copy_to_regcache): Likewise.
6438 (aarch64_sve_regs_copy_from_regcache): Likewise.
6439 (sve_context): Structure from Linux headers.
6440 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
6441 (SVE_SIG_ZREG_SIZE): Likewise.
6442 (SVE_SIG_PREG_SIZE): Likewise.
6443 (SVE_SIG_FFR_SIZE): Likewise.
6444 (SVE_SIG_REGS_OFFSET): Likewise.
6445 (SVE_SIG_ZREGS_OFFSET): Likewise.
6446 (SVE_SIG_ZREG_OFFSET): Likewise.
6447 (SVE_SIG_ZREGS_SIZE): Likewise.
6448 (SVE_SIG_PREGS_OFFSET): Likewise.
6449 (SVE_SIG_PREG_OFFSET): Likewise.
6450 (SVE_SIG_PREGS_SIZE): Likewise.
6451 (SVE_SIG_FFR_OFFSET): Likewise.
6452 (SVE_SIG_REGS_SIZE): Likewise.
6453 (SVE_SIG_CONTEXT_SIZE): Likewise.
6454 (SVE_PT_REGS_MASK): Likewise.
6455 (SVE_PT_REGS_FPSIMD): Likewise.
6456 (SVE_PT_REGS_SVE): Likewise.
6457 (SVE_PT_VL_INHERIT): Likewise.
6458 (SVE_PT_VL_ONEXEC): Likewise.
6459 (SVE_PT_REGS_OFFSET): Likewise.
6460 (SVE_PT_FPSIMD_OFFSET): Likewise.
6461 (SVE_PT_FPSIMD_SIZE): Likewise.
6462 (SVE_PT_SVE_ZREG_SIZE): Likewise.
6463 (SVE_PT_SVE_PREG_SIZE): Likewise.
6464 (SVE_PT_SVE_FFR_SIZE): Likewise.
6465 (SVE_PT_SVE_FPSR_SIZE): Likewise.
6466 (SVE_PT_SVE_FPCR_SIZE): Likewise.
6467 (__SVE_SIG_TO_PT): Likewise.
6468 (SVE_PT_SVE_OFFSET): Likewise.
6469 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
6470 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
6471 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
6472 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
6473 (SVE_PT_SVE_PREG_OFFSET): Likewise.
6474 (SVE_PT_SVE_PREGS_SIZE): Likewise.
6475 (SVE_PT_SVE_FFR_OFFSET): Likewise.
6476 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
6477 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
6478 (SVE_PT_SVE_SIZE): Likewise.
6479 (SVE_PT_SIZE): Likewise.
6480 (HAS_SVE_STATE): New define.
6481
6482 2018-06-18 Alan Hayward <alan.hayward@arm.com>
6483
6484 * nat/aarch64-sve-linux-sigcontext.h: New file.
6485 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
6486 new files.
6487 (SVE_VQ_MIN): Likewise.
6488 (SVE_VQ_MAX): Likewise.
6489 (SVE_VL_MIN): Likewise.
6490 (SVE_VL_MAX): Likewise.
6491 (SVE_NUM_ZREGS): Likewise.
6492 (SVE_NUM_PREGS): Likewise.
6493 (sve_vl_valid): Likewise.
6494 (struct user_sve_header): Likewise.
6495
6496 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
6497 Richard Bunt <Richard.Bunt@arm.com>
6498
6499 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
6500 was requested by GDB.
6501
6502 2018-06-15 Tom de Vries <tdevries@suse.de>
6503
6504 * MAINTAINERS (Write After Approval): Add Tom de Vries.
6505
6506 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
6507
6508 * gnulib/update-gnulib.sh: Print expected versions of
6509 autoconf/aclocal.
6510
6511 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
6512
6513 * arch-utils.c (default_type_align): Use type_length_units.
6514 * gdbtypes.c (type_align): Use type_length_units.
6515
6516 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6517
6518 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
6519 of 'define' command.
6520
6521 2018-06-14 Tom de Vries <tdevries@suse.de>
6522
6523 PR cli/22573
6524 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
6525 get_no_prettyformat_print_options.
6526
6527 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
6528
6529 * sparc-nat.h: Include target.h.
6530 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
6531 <fetch_registers>: Remove this argument in function call.
6532 <store_registers>: Remove this argument in function call, remove
6533 extra semicolon.
6534 <low_forget_process>: Call sparc64_forget_process instead of
6535 sparc_forget_process.
6536
6537 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6538
6539 * procfs.c (_initialize_procfs): Use add_inf_child_target.
6540 (procfs_target::make_corefile_notes): Adjust to new
6541 target_read_alloc return type.
6542
6543 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6544 Stephen Roberts <stephen.roberts@arm.com>
6545
6546 PR gdb/22882
6547 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
6548 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
6549 Move should_notify_stop local into more inner scope.
6550
6551 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6552 Stephen Roberts <stephen.roberts@arm.com>
6553
6554 PR gdb/22882
6555 * infrun.c (resume_1): Add call to mark_async_event_handler.
6556
6557 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
6558
6559 * infrun.c (do_target_wait): Change old version of $pc printed.
6560
6561 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
6562
6563 * dwarf2read.c (read_index_from_section): Rename to...
6564 (read_gdb_index_from_section): ... this, update all callers.
6565 (dwarf2_read_index): Rename to...
6566 (dwarf2_read_gdb_index): ... this, update all callers.
6567
6568 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
6569
6570 * gdb/hppa-linux-nat.c
6571 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
6572 hppa_linux_nat_target::fetch_registers.
6573
6574 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6575
6576 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
6577 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
6578 (AARCH64_DWARF_SVE_FFR): Likewise.
6579 (AARCH64_DWARF_SVE_P0): Likewise.
6580 (AARCH64_DWARF_SVE_Z0): Likewise.
6581
6582 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6583
6584 * common/common-regcache.h (raw_compare): New function.
6585 * regcache.c (regcache::raw_compare): Likewise.
6586 * regcache.h (regcache::raw_compare): New declaration.
6587
6588 2018-06-11 Alan Hayward <alan.hayward@arm.com>
6589
6590 * common/common-regcache.h (reg_buffer_common): New structure.
6591 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
6592 (reg_buffer::raw_supply): Likewise.
6593 (reg_buffer::raw_supply_integer): Likewise.
6594 (reg_buffer::raw_supply_zeroed): Likewise.
6595 (reg_buffer::raw_collect): Likewise.
6596 (reg_buffer::raw_collect_integer): Likewise.
6597 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
6598 (reg_buffer::raw_supply): Likewise.
6599 (reg_buffer::raw_supply_integer): Likewise.
6600 (reg_buffer::raw_supply_zeroed): Likewise.
6601 (reg_buffer::raw_collect): Likewise.
6602 (reg_buffer::raw_collect_integer): Likewise.
6603
6604 2018-06-10 Tom Tromey <tom@tromey.com>
6605
6606 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
6607 (class remote_state) <stop_reply_queue>: Now std::vector.
6608 (remote_state::~remote_state)
6609 (remote_target::stop_reply_queue_length): Update.
6610 (struct queue_iter_param, remove_child_of_pending_fork)
6611 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
6612 (check_pending_event_prevents_wildcard_vcont_callback)
6613 (remove_stop_reply_for_inferior)
6614 (remove_stop_reply_of_remote_state)
6615 (remote_notif_remove_once_on_match)
6616 (stop_reply_match_ptid_and_ws)
6617 (remote_kill_child_of_pending_fork): Remove.
6618 (remote_target::remove_new_fork_children)
6619 (remote_target::check_pending_events_prevent_wildcard_vcont)
6620 (remote_target::discard_pending_stop_replies)
6621 (remote_target::discard_pending_stop_replies_in_queue)
6622 (remote_target::remote_notif_remove_queued_reply)
6623 (remote_target::queued_stop_reply)
6624 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
6625 (remote_target::wait, remote_target::kill_new_fork_children)
6626 (remote_target::async): Update.
6627
6628 2018-06-10 Tom Tromey <tom@tromey.com>
6629
6630 * record-full.c (record_full_arch_list_cleanups): Remove.
6631 (record_full_message): Use try/catch.
6632 (record_full_wait_cleanups): Remove.
6633 (record_full_wait_1): Use try/catch.
6634 (record_full_restore): Likewise.
6635
6636 2018-06-10 Tom Tromey <tom@tromey.com>
6637
6638 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
6639 declare VEC. Add constructor.
6640 <in_target_beneath>: Now bool.
6641 (record_full_breakpoints): Now a std::vector, static.
6642 (record_full_sync_record_breakpoints)
6643 (record_full_init_record_breakpoints)
6644 (record_full_target::insert_breakpoint)
6645 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
6646
6647 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
6648
6649 * dwarf2read.c (process_cu_includes): Remove struct keyword.
6650 * serial.c (serial_interface_lookup): Remove struct keyword.
6651
6652 2018-06-10 Tom Tromey <tom@tromey.com>
6653
6654 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
6655 method.
6656 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
6657 a method.
6658 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
6659 method.
6660 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
6661 "beneath" as a method.
6662 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
6663 Use "beneath" as a method.
6664
6665 2018-06-10 Tom Tromey <tom@tromey.com>
6666
6667 * tracefile.c (struct trace_file_writer_deleter): New.
6668 <operator()>: Rename from trace_file_writer_xfree.
6669 (trace_file_writer_up): New typedef.
6670 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
6671
6672 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6673
6674 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
6675 <m_registers, m_register_status>: Change type to
6676 std::unique_ptr.
6677 * regcache.c (reg_buffer::reg_buffer): Use new instead of
6678 XCNEWVEC.
6679
6680 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
6681
6682 * common/common-regcache.h (enum register_status): Add
6683 underlying type "signed char".
6684 * regcache.h (reg_buffer) <m_register_status>: Change type to
6685 register_status *.
6686 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
6687 register_status instead of signed char.
6688 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
6689 (reg_buffer::get_register_status): Remove cast.
6690 (readable_regcache::raw_read): Remove cast.
6691 (readable_regcache::cooked_read): Remove cast.
6692
6693 2018-06-09 Tom Tromey <tom@tromey.com>
6694
6695 * source.c (reverse_search_command, forward_search_command): Use
6696 scoped_fd.
6697
6698 2018-06-09 Tom Tromey <tom@tromey.com>
6699
6700 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
6701 (serial_ops_list): Now static, std::vector.
6702 (serial_interface_lookup, serial_add_interface): Update.
6703
6704 2018-06-09 Tom Tromey <tom@tromey.com>
6705
6706 * dwarf2read.c (process_cu_includes): Update.
6707 (process_full_comp_unit): Update.
6708 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
6709 std::vector.
6710
6711 2018-06-08 Paul Koning <paul_koning@dell.com>
6712
6713 PR gdb/23252
6714
6715 * python/python.c (do_start_initialization):
6716 Avoid call to internal Python API.
6717 (init__gdb_module): New function.
6718
6719 2018-06-08 Gary Benson <gbenson@redhat.com>
6720
6721 * linux-thread-db.c (valprint.h): New include.
6722 (struct check_thread_db_info): New structure.
6723 (check_thread_db_on_load, tdb_testinfo): New static globals.
6724 (check_thread_db, check_thread_db_callback): New functions.
6725 (try_thread_db_load_1): Run integrity checks if requested.
6726 (maintenance_check_libthread_db): New function.
6727 (_initialize_thread_db): Register "maint check libthread-db"
6728 and "maint set/show check-libthread-db".
6729 * NEWS: Mention the above new commands.
6730
6731 2018-06-08 Tom Tromey <tom@tromey.com>
6732
6733 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
6734 now a method.
6735
6736 2018-06-08 Tom Tromey <tom@tromey.com>
6737
6738 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
6739
6740 2018-06-08 Tom Tromey <tom@tromey.com>
6741
6742 * common/btrace-common.h (struct btrace_data): Add constructor,
6743 destructor, move assignment operator.
6744 <empty, clear, fini>: New methods.
6745 <format>: Initialize.
6746 (btrace_data_init, btrace_data_fini, btrace_data_clear)
6747 (btrace_data_empty): Don't declare.
6748 * common/btrace-common.c (btrace_data_init): Remove.
6749 (btrace_data::fini): Rename from btrace_data_fini.
6750 (btrace_data::empty): Rename from btrace_data_empty.
6751 (btrace_data::clear): Rename from btrace_data_clear. Return
6752 bool.
6753 * btrace.h (make_cleanup_btrace_data): Don't declare.
6754 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
6755 (parse_xml_btrace): Update.
6756 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
6757 (maint_btrace_clear_packet_history_cmd): Update.
6758
6759 2018-06-07 Pedro Alves <palves@redhat.com>
6760
6761 * target.h (target_ops) <beneath>: Now a method. All references
6762 updated.
6763 (class target_stack): New.
6764 * target.c (g_target_stack): New.
6765 (g_current_top_target): Delete.
6766 (current_top_target): Get the top target out of g_target_stack.
6767 (target_stack::push, target_stack::unpush): New.
6768 (push_target, unpush_target): Reimplement.
6769 (target_is_pushed): Reimplement in terms of g_target_stack.
6770 (target_ops::beneath, target_stack::find_beneath): New.
6771
6772 2018-06-07 Pedro Alves <palves@redhat.com>
6773
6774 * target.h (find_target_beneath): Delete declaration.
6775 * target.c (find_target_beneath): Delete definition.
6776 * aix-thread.c: All callers of find_target_beneath adjusted to
6777 call target_ops::beneath instead.
6778 * bsd-uthread.c: Likewise.
6779 * linux-thread-db.c: Likewise.
6780 * ravenscar-thread.c: Likewise.
6781 * sol-thread.c: Likewise.
6782 * spu-multiarch.c: Likewise.
6783
6784 2018-06-07 Pedro Alves <palves@redhat.com>
6785
6786 * target.h (target_ops) <beneath>: Now a method. All references
6787 updated.
6788 (target_ops) <m_beneath>: New.
6789 * target.c (target_ops::beneath): New.
6790 * corelow.c: Adjust all references to target_ops::beneath.
6791 * linux-thread-db.c: Likewise.
6792 * make-target-delegates: Likewise.
6793 * record-btrace.c: Likewise.
6794 * record-full.c: Likewise.
6795 * remote.c: Likewise.
6796 * target.c: Likewise.
6797 * target-delegates.c: Regenerate.
6798
6799 2018-06-07 Pedro Alves <palves@redhat.com>
6800
6801 * target.h (target_stack): Delete.
6802 (current_top_target): Declare function.
6803 * target.c (target_stack): Delete.
6804 (g_current_top_target): New.
6805 (current_top_target): New function.
6806 * auxv.c: Use current_top_target instead of target_stack
6807 throughout.
6808 * avr-tdep.c: Likewise.
6809 * breakpoint.c: Likewise.
6810 * corefile.c: Likewise.
6811 * elfread.c: Likewise.
6812 * eval.c: Likewise.
6813 * exceptions.c: Likewise.
6814 * frame.c: Likewise.
6815 * gdbarch-selftests.c: Likewise.
6816 * gnu-v3-abi.c: Likewise.
6817 * ia64-tdep.c: Likewise.
6818 * ia64-vms-tdep.c: Likewise.
6819 * infcall.c: Likewise.
6820 * infcmd.c: Likewise.
6821 * infrun.c: Likewise.
6822 * linespec.c: Likewise.
6823 * linux-tdep.c: Likewise.
6824 * minsyms.c: Likewise.
6825 * ppc-linux-nat.c: Likewise.
6826 * ppc-linux-tdep.c: Likewise.
6827 * procfs.c: Likewise.
6828 * regcache.c: Likewise.
6829 * remote.c: Likewise.
6830 * rs6000-tdep.c: Likewise.
6831 * s390-linux-nat.c: Likewise.
6832 * s390-tdep.c: Likewise.
6833 * solib-aix.c: Likewise.
6834 * solib-darwin.c: Likewise.
6835 * solib-dsbt.c: Likewise.
6836 * solib-spu.c: Likewise.
6837 * solib-svr4.c: Likewise.
6838 * solib-target.c: Likewise.
6839 * sparc-tdep.c: Likewise.
6840 * sparc64-tdep.c: Likewise.
6841 * spu-tdep.c: Likewise.
6842 * symfile.c: Likewise.
6843 * symtab.c: Likewise.
6844 * target-descriptions.c: Likewise.
6845 * target-memory.c: Likewise.
6846 * target.c: Likewise.
6847 * target.h: Likewise.
6848 * tracefile-tfile.c: Likewise.
6849 * tracepoint.c: Likewise.
6850 * valops.c: Likewise.
6851 * valprint.c: Likewise.
6852 * value.c: Likewise.
6853 * windows-tdep.c: Likewise.
6854 * mi/mi-main.c: Likewise.
6855
6856 2018-06-07 Tom Tromey <tom@tromey.com>
6857
6858 * valprint.h (build_address_symbolic): Declare.
6859 * printcmd.c (print_address_symbolic): Update.
6860 (build_address_symbolic): Change "name" and "filename" to
6861 std::string.
6862 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
6863 Update.
6864 * defs.h (build_address_symbolic): Remove declaration.
6865
6866 2018-06-07 Alan Hayward <alan.hayward@arm.com>
6867
6868 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
6869 (aarch64_vnv_type): Add function.
6870 (aarch64_pseudo_register_name): Add V regs for SVE.
6871 (aarch64_pseudo_register_type): Likewise.
6872 (aarch64_pseudo_register_reggroup_p): Likewise.
6873 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
6874 (aarch64_pseudo_read_value): Add V regs for SVE.
6875 (aarch64_pseudo_write_2): Use V0 offset for SVE
6876 (aarch64_pseudo_write): Add V regs for SVE.
6877 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
6878
6879 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
6880
6881 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
6882 (sve_vl_from_vq): Likewise.
6883
6884 2018-06-05 Tom Tromey <tom@tromey.com>
6885
6886 * cli/cli-cmds.c (show_version): Update.
6887 * top.c (print_gdb_version): Add "interactive" parameter.
6888 Update.
6889 * main.c (captured_main_1): Update.
6890 * top.h (print_gdb_version): Add "interactive" parameter and a
6891 comment.
6892
6893 2018-06-05 David Malcolm <dmalcolm@redhat.com>
6894
6895 * common/enum-flags.h: Add trailing semicolon to example in
6896 comment.
6897
6898 2018-06-05 Tom Tromey <tom@tromey.com>
6899
6900 PR cli/12326:
6901 * NEWS: Add entry about pager.
6902 * utils.c (pagination_disabled_for_command): New global.
6903 (prompt_for_continue): Allow "c" response to prompt.
6904 (reinitialize_more_filter): Clear
6905 pagination_disabled_for_command.
6906 (fputs_maybe_filtered): Check pagination_disabled_for_command.
6907
6908 2018-06-04 Tom Tromey <tom@tromey.com>
6909
6910 * ada-lang.h (ada_lookup_symbol_list): Update.
6911 * ada-lang.c (resolve_subexp): Update.
6912 (symbols_are_identical_enums): Change type of syms. Remove nsyms
6913 parameter.
6914 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
6915 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
6916 results parameter to std::vector.
6917 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
6918 Update.
6919 * ada-exp.y (block_lookup): Update.
6920 (select_possible_type_sym): Change type of syms. Remove nsyms
6921 parameter.
6922 (write_var_or_type, write_name_assoc): Update.
6923
6924 2018-06-04 Joel Brobecker <brobecker@adacore.com>
6925
6926 * windows-nat.c (windows_nat_target::xfer_partial): Return
6927 TARGET_XFER_E_IO if we need to delegate to the target beneath
6928 but BENEATH is NULL.
6929
6930 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
6931
6932 * Makefile.in (config.status): Add configure.nat as a
6933 dependency.
6934
6935 2018-06-04 Tom Tromey <tom@tromey.com>
6936
6937 * cp-name-parser.y (cpname_state): Add method declarations.
6938 (HANDLE_QUAL): Update.
6939 (cpname_state::d_grab, cpname_state::fill_comp)
6940 (cpname_state::make_operator, cpname_state::make_dtor)
6941 (cpname_state::make_builtin_type, cpname_state::make_name)
6942 (cpname_state::d_qualify, cpname_state::d_int_type)
6943 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
6944 (%union): Move earlier.
6945
6946 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6947
6948 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
6949
6950 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6951
6952 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
6953 (aarch64_pseudo_write_1): Likewise.
6954 (aarch64_pseudo_read_value): Use helper.
6955 (aarch64_pseudo_write): Likewise.
6956
6957 2018-06-04 Pedro Alves <palves@redhat.com>
6958
6959 * darwin-nat.c (darwin_ops): Delete.
6960 (darwin_attach_pid): Use get_native_target.
6961
6962 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6963
6964 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
6965 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
6966
6967 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6968
6969 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
6970 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
6971 (aarch64_gdbarch_init): Check for SVE.
6972 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
6973
6974 2018-06-04 Alan Hayward <alan.hayward@arm.com>
6975
6976 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
6977 * aarch64-tdep.h (aarch64_read_description): Likewise.
6978 * arch/aarch64.c (aarch64_create_target_description): Likewise.
6979 * arch/aarch64.h (aarch64_create_target_description): Likewise.
6980 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
6981 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
6982 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
6983
6984 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
6985
6986 * value.c (value_fetch_lazy_bitfield): New.
6987 (value_fetch_lazy_memory): New.
6988 (value_fetch_lazy_register): New.
6989 (value_fetch_lazy): Factor out to smaller functions.
6990
6991 2018-06-01 Tom Tromey <tom@tromey.com>
6992
6993 * cp-name-parser.y (backslashable, represented): Now const.
6994
6995 2018-06-01 Tom Tromey <tom@tromey.com>
6996
6997 * cp-name-parser.y: Include parser-defs.h.
6998 (parser_fprintf): Remove declaration.
6999
7000 2018-06-01 Tom Tromey <tom@tromey.com>
7001
7002 * cp-name-parser.y: Use %pure-parser, %lex-param, and
7003 %parse-param.
7004 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
7005 (global_result): Remove globals.
7006 (struct cpname_state): New.
7007 (yyparse): Don't declare.
7008 (yylex, yyerror): Move declarations after %union.
7009 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
7010 (make_name): Add state parameter.
7011 Update all callers.
7012 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
7013 parameter.
7014 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
7015 Update.
7016 (yylex): Add lvalp, state parameters.
7017 (yyerror): Add state parameter.
7018 (cp_demangled_name_to_comp): Update.
7019
7020 2018-06-01 Tom Tromey <tom@tromey.com>
7021
7022 * cp-name-parser.y (parser_fprintf): Declare.
7023 (GDB_YY_REMAP_PREFIX): Define.
7024 Include yy-remap.h. Don't redefine yy* identifiers.
7025
7026 2018-06-01 Tom Tromey <tom@tromey.com>
7027
7028 * python/py-type.c (typy_legacy_template_argument): Update.
7029 * cp-support.h (cp_demangled_name_to_comp): Update.
7030 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
7031 parameter to be a "std::string *".
7032 (main): Update.
7033
7034 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
7035
7036 * ada-lex.l: Include "diagnostics.h" instead of
7037 "common/diagnostics.h".
7038 * unittests/environ-selftests.c: Likewise.
7039 * common/diagnostics.h: Moved to ../include.
7040
7041 2018-06-01 Joel Brobecker <brobecker@adacore.com>
7042
7043 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
7044 to language_mode_manual while calling breakpoint_re_set_one.
7045
7046 2018-06-01 Tom Tromey <tom@tromey.com>
7047
7048 * valops.c (value_cast_structs, destructor_name_p): Update.
7049 * symtab.c (gdb_mangle_name): Update.
7050 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
7051 Update.
7052 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
7053 (pascal_object_print_value_fields, pascal_object_print_value):
7054 Update.
7055 * p-typeprint.c (pascal_type_print_derivation_info): Update.
7056 * linespec.c (find_methods): Update.
7057 * gdbtypes.h (type_name_no_tag): Remove.
7058 (type_name_or_error): Rename from type_name_no_tag_or_error.
7059 * gdbtypes.c (type_name_no_tag): Remove.
7060 (type_name_or_error): Rename from type_name_no_tag_or_error.
7061 (lookup_struct_elt_type, check_typedef): Update.
7062 * expprint.c (print_subexp_standard): Update.
7063 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
7064 * d-namespace.c (d_lookup_nested_symbol): Update.
7065 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
7066 (cp_print_class_member): Update.
7067 * cp-namespace.c (cp_lookup_nested_symbol): Update.
7068 * completer.c (add_struct_fields): Update.
7069 * c-typeprint.c (cp_type_print_derivation_info)
7070 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
7071 Update.
7072 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
7073 (ada_prefer_type, ada_is_exception_sym): Update.
7074
7075 2018-06-01 Tom Tromey <tom@tromey.com>
7076
7077 * valops.c (enum_constant_from_type, value_namespace_elt)
7078 (value_maybe_namespace_elt): Update.
7079 * valarith.c (find_size_for_pointer_math): Update.
7080 * target-descriptions.c (make_gdb_type): Update.
7081 * symmisc.c (print_symbol): Update.
7082 * stabsread.c (define_symbol, read_type)
7083 (complain_about_struct_wipeout, add_undefined_type)
7084 (cleanup_undefined_types_1): Update.
7085 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
7086 (rust_range_type_p, val_print_struct, rust_print_struct_def)
7087 (rust_internal_print_type, rust_composite_type)
7088 (rust_evaluate_funcall, rust_evaluate_subexp)
7089 (rust_inclusive_range_type_p): Update.
7090 * python/py-type.c (typy_get_tag): Update.
7091 * p-typeprint.c (pascal_type_print_base): Update.
7092 * mdebugread.c (parse_symbol, parse_type): Update.
7093 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
7094 Update.
7095 * guile/scm-type.c (gdbscm_type_tag): Update.
7096 * go-lang.c (sixg_string_p): Update.
7097 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
7098 Update.
7099 * gdbtypes.h (struct main_type) <tag_name>: Remove.
7100 (TYPE_TAG_NAME): Remove.
7101 * gdbtypes.c (type_name_no_tag): Simplify.
7102 (check_typedef, check_types_equal, recursive_dump_type)
7103 (copy_type_recursive, arch_composite_type): Update.
7104 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
7105 in summary mode when needed.
7106 * eval.c (evaluate_funcall): Update.
7107 * dwarf2read.c (fixup_go_packaging, read_structure_type)
7108 (process_structure_scope, read_enumeration_type)
7109 (read_namespace_type, read_module_type, determine_prefix): Update.
7110 * cp-support.c (inspect_type): Update.
7111 * coffread.c (process_coff_symbol, decode_base_type): Update.
7112 * c-varobj.c (c_is_path_expr_parent): Update.
7113 * c-typeprint.c (c_type_print_base_struct_union): Update.
7114 (c_type_print_base_1): Update. Print struct/class/union/enum in
7115 summary when using C language.
7116 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
7117 (gen_maybe_namespace_elt): Update.
7118 * ada-lang.c (ada_type_name): Simplify.
7119 (empty_record, ada_template_to_fixed_record_type_1)
7120 (template_to_static_fixed_type)
7121 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
7122
7123 2018-06-01 Tom Tromey <tom@tromey.com>
7124
7125 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
7126 c_print_type.
7127 * c-typeprint.c (c_print_type_1): Add "language" parameter.
7128 (c_print_type): Update.
7129 (c_print_type): New overload.
7130 (c_type_print_varspec_prefix, c_type_print_args)
7131 (c_type_print_varspec_suffix, c_print_type_no_offsets)
7132 (c_type_print_base_struct_union, c_type_print_base_1)
7133 (cp_type_print_method_args): Add "language" parameter.
7134 (c_type_print_base): Update.
7135 * c-lang.h (c_print_type): Add new overload.
7136
7137 2018-06-01 Tom Tromey <tom@tromey.com>
7138
7139 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
7140 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
7141
7142 2018-06-01 Alan Hayward <alan.hayward@arm.com>
7143
7144 * aarch64-tdep.c (aarch64_sve_register_names): New const
7145 var.
7146 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
7147 (AARCH64_SVE_Z_REGS_NUM): New define.
7148 (AARCH64_SVE_P_REGS_NUM): Likewise.
7149 (AARCH64_SVE_NUM_REGS): Likewise.
7150
7151 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
7152
7153 * nat/linux-ptrace.h [__alpha__]
7154 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
7155 definitions.
7156
7157 2018-05-31 Maciej W. Rozycki <macro@mips.com>
7158
7159 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
7160 the endianness selected.
7161 * NEWS: Document `set endian auto' mode operation update.
7162
7163 2018-05-31 Alan Hayward <alan.hayward@arm.com>
7164
7165 * Makefile.in: Add new header.
7166 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
7167 (sve_vl_from_vg): Likewise.
7168 (sve_vq_from_vl): Likewise.
7169 (sve_vl_from_vq): Likewise.
7170 (sve_vq_from_vg): Likewise.
7171 (sve_vg_from_vq): Likewise.
7172 * configure.nat: Add new c file.
7173 * nat/aarch64-sve-linux-ptrace.c: New file.
7174 * nat/aarch64-sve-linux-ptrace.h: New file.
7175
7176 2018-05-31 Alan Hayward <alan.hayward@arm.com>
7177
7178 * aarch64-linux-nat.c (aarch64_linux_read_description):
7179 Add parmeter zero.
7180 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
7181 Likewise.
7182 * aarch64-tdep.c (tdesc_aarch64_list): Add.
7183 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
7184 (aarch64_gdbarch_init): Add parmeter zero.
7185 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
7186 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
7187 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
7188 parmeter.
7189 * doc/gdb.texinfo: Describe SVE feature
7190 * features/aarch64-sve.c: New file.
7191
7192 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
7193
7194 PR gdb/23210
7195 * gdbarch.sh (significant_addr_bit): Default to zero when
7196 not set by target architecture.
7197 * gdbarch.c: Re-generated.
7198 * utils.c (address_significant): Update.
7199
7200 2018-05-30 Joel Brobecker <brobecker@adacore.com>
7201
7202 * stack.c (func_command): Remove trailing newline in call to error.
7203
7204 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7205
7206 * regcache.h (regcache_raw_collect): Remove, update callers to
7207 use regcache::raw_collect.
7208 * regcache.c (regcache_raw_collect): Remove.
7209
7210 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7211
7212 * regcache.h (regcache_raw_supply): Remove, update callers to
7213 use detached_regcache::raw_supply.
7214 * regcache.c (regcache_raw_supply): Remove.
7215
7216 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7217
7218 * regcache.h (regcache_cooked_write_part): Remove, update
7219 callers to use regcache::cooked_write_part.
7220 * regcache.c (regcache_cooked_write_part): Remove.
7221
7222 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7223
7224 * regcache.h (regcache_cooked_read_part): Remove, update callers
7225 to use readable_regcache::cooked_read_part.
7226 * regcache.c (regcache_cooked_read_part): Remove.
7227
7228 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7229
7230 * regcache.h (regcache_cooked_read_value): Remove, update
7231 callers to use readable_regcache::cooked_read_value.
7232 * regcache.c (regcache_cooked_read_value): Remove.
7233
7234 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7235
7236 * regcache.h (regcache_cooked_write): Remove, update callers to
7237 use regcache::cooked_write.
7238 * regcache.c (regcache_cooked_write): Remove.
7239
7240 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7241
7242 * regcache.h (regcache_invalidate): Remove, update callers to
7243 use detached_regcache::invalidate instead.
7244 * regcache.c (regcache_invalidate): Remove.
7245
7246 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7247
7248 * regcache.h (regcache_raw_write_part): Remove, update callers
7249 to use regcache::raw_write_part instead.
7250 * regcache.c (regcache_raw_write_part): Remove.
7251
7252 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7253
7254 * regcache.h (regcache_raw_read_part): Remove, update callers to
7255 use readable_regcache::raw_read_part instead.
7256 * regcache.c (regcache_raw_read_part): Remove.
7257
7258 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7259
7260 * regcache.h (regcache_cooked_read): Remove, update callers to
7261 use readable_regcache::cooked_read instead.
7262 * regcache.c (regcache_cooked_read): Remove.
7263
7264 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7265
7266 * regcache.h (regcache_raw_write): Remove, update callers to use
7267 regcache::raw_write instead.
7268 * regcache.c (regcache_raw_write): Remove.
7269
7270 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7271
7272 * regcache.h (regcache_raw_read): Remove, update callers to use
7273 readable_regcache::raw_read instead.
7274 * regcache.c (regcache_raw_read): Remove.
7275
7276 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7277
7278 * regcache.h (regcache_raw_update): Remove, update callers to
7279 use readable_regcache::raw_update instead.
7280 * regcache.c (regcache_raw_update): Remove.
7281
7282 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7283
7284 * regcache.h (regcache_register_status): Remove, update callers
7285 to use reg_buffer::get_register_status directly instead.
7286 * regcache.c (regcache_register_status): Remove.
7287
7288 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7289
7290 * regcache.h (regcache_get_ptid): Remove, update all callers to
7291 call regcache::ptid instead.
7292 * regcache.c (regcache_get_ptid): Remove.
7293
7294 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
7295
7296 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
7297
7298 2018-05-30 Pedro Alves <palves@redhat.com>
7299
7300 * common/common-exceptions.h (exception_rethrow): Use
7301 ATTRIBUTE_NORETURN.
7302
7303 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
7304
7305 * breakpoint.c (print_solib_event, check_status_catch_solib):
7306 Remove struct keyword in range-based for loops.
7307 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
7308 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
7309 Likewise.
7310 * linespec.c (find_superclass_methods, search_minsyms_for_name):
7311 Likewise.
7312 * symfile.c (addr_info_make_relative): Likewise.
7313 * thread.c (value_in_thread_stack_temporaries): Likewise.
7314
7315 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
7316
7317 PR gdb/16841
7318 * valops.c (value_struct_elt_for_reference): Call check_typedef on
7319 aggregate type to get its real type before accessing it.
7320
7321 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
7322
7323 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
7324 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
7325 * coff-pe-read.c (add_pe_forwarded_sym): Replace
7326 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
7327 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
7328 * jit.c (jit_breakpoint_re_set_internal): Likewise.
7329 * printcmd.c (info_address_command): Likewise.
7330
7331 2018-05-29 Tom Tromey <tom@tromey.com>
7332
7333 * windows-nat.c (handle_exception): Update fall-through comment.
7334
7335 2018-05-29 Tom Tromey <tom@tromey.com>
7336
7337 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
7338 (struct program_space) <added_solibs>: Now a std::vector.
7339 * breakpoint.c (print_solib_event): Update.
7340 (check_status_catch_solib): Update.
7341 * progspace.c (clear_program_space_solib_cache): Update.
7342 * solib.c (update_solib_list): Update.
7343
7344 2018-05-29 Tom Tromey <tom@tromey.com>
7345
7346 * python/py-type.c (typy_richcompare): Update.
7347 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
7348 * gdbtypes.h (types_deeply_equal): Return bool.
7349 (types_equal): Likewise.
7350 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
7351 declare VEC.
7352 (check_types_equal): Change worklist to std::vector. Return
7353 bool.
7354 (struct type_equality_entry): Add constructor.
7355 (compare_maybe_null_strings): Return bool.
7356 (check_types_worklist): Return bool. Change worklist to
7357 std::vector.
7358 (types_deeply_equal): Use std::vector.
7359 (types_equal): Return bool.
7360 (compare_maybe_null_strings): Simplify.
7361
7362 2018-05-29 Tom Tromey <tom@tromey.com>
7363
7364 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
7365
7366 2018-05-29 Tom Tromey <tom@tromey.com>
7367
7368 * objc-lang.h: Don't include cp-support.h.
7369 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
7370 declare VEC.
7371
7372 2018-05-27 Tom Tromey <tom@tromey.com>
7373
7374 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
7375
7376 2018-05-25 Tom Tromey <tom@tromey.com>
7377
7378 * value.c (value::location): Initialize.
7379
7380 2018-05-25 Tom Tromey <tom@tromey.com>
7381
7382 * dbxread.c (init_bincl_list): Remove.
7383 (bincl_list): Now a std::vector.
7384 (bincls_allocated, next_bincl): Remove.
7385 (free_bincl_list, do_free_bincl_list_cleanup)
7386 (make_cleanup_free_bincl_list): Remove.
7387 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
7388 unique_xmalloc_ptr.
7389 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
7390 (struct header_file_location): Add constructor.
7391 (add_bincl_to_list): Remove.
7392
7393 2018-05-25 Tom Tromey <tom@tromey.com>
7394
7395 * tui/tui.c (tui_enable): Update.
7396 * mi/mi-interp.c (mi_interp::init): Update.
7397 * interps.h (class interp) <name>: New method.
7398 <m_name>: Rename from name.
7399 (~scoped_restore_interp): Update.
7400 * interps.c (interp::interp): Update.
7401 (interp_add, interp_set, interp_lookup_existing)
7402 (current_interp_named_p): Update.
7403
7404 2018-05-25 Tom Tromey <tom@tromey.com>
7405
7406 * interps.c (interp_name): Remove.
7407 * mi/mi-interp.c (mi_interp::init): Update.
7408 * interps.h (interp_name): Remove.
7409 (~scoped_restore_interp): Update.
7410 * tui/tui.c (tui_enable): Update.
7411
7412 2018-05-25 Tom Tromey <tom@tromey.com>
7413
7414 * utils.c (fputs_maybe_filtered): Update.
7415 * linespec.c (decode_line_full): Update.
7416 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
7417 (mi_print_breakpoint_for_event, mi_solib_loaded)
7418 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7419 (mi_user_selected_context_changed): Update.
7420 * mi/mi-main.c (mi_execute_command): Update.
7421 * cli/cli-script.c (execute_control_command): Update.
7422 * python/python.c (execute_gdb_command): Update.
7423 * solib.c (info_sharedlibrary_command): Update.
7424 * interps.c (interp_ui_out): Remove.
7425 * interps.h (interp_ui_out): Remove.
7426
7427 2018-05-25 Tom Tromey <tom@tromey.com>
7428
7429 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
7430 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
7431 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
7432
7433 2018-05-25 Tom Tromey <tom@tromey.com>
7434
7435 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
7436 * interps.c (interp_exec): Use scoped_restore.
7437
7438 2018-05-25 Tom Tromey <tom@tromey.com>
7439
7440 * remote.c (remote_target::remote_file_get): Use
7441 gdb::byte_vector.
7442 (remote_target::remote_file_put): Likewise.
7443
7444 2018-05-25 Tom Tromey <tom@tromey.com>
7445
7446 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
7447 a std::string.
7448 (get_pe_section_index, add_pe_exported_sym): Update.
7449 (read_pe_exported_syms): Use gdb::def_vector.
7450
7451 2018-05-25 Tom Tromey <tom@tromey.com>
7452
7453 * frame.c (remove_prev_frame): Remove.
7454 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
7455
7456 2018-05-25 Maciej W. Rozycki <macro@mips.com>
7457
7458 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
7459 Remove prototypes.
7460 * mips-linux-nat.c (supply_fpregset): Always call
7461 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
7462 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
7463 `mips_fill_fpregset'.
7464 * mips-linux-tdep.c (mips_supply_fpregset)
7465 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
7466 (mips_fill_fpregset_wrapper): Remove functions.
7467 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
7468 (mips_linux_fpregset): Remove variable.
7469 (mips_linux_iterate_over_regset_sections): Use
7470 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
7471 (mips_linux_o32_sigframe_init): Remove comment.
7472
7473 2018-05-25 Pedro Alves <palves@redhat.com>
7474
7475 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
7476 (struct readahead_cache, struct packet_reg, struct
7477 remote_arch_state, class remote_state): Move higher up in the
7478 file.
7479 (remote_target::m_remote_state): Now an object instead of a pointer.
7480 (remote_target::get_remote_state): Adjust.
7481
7482 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7483
7484 * stack.c (select_and_print_frame): Delete.
7485 (struct function_bounds): Move struct within function.
7486 (func_command): Most content moved into new function
7487 find_frame_for_function, use new function, print result, add
7488 function comment.
7489 (find_frame_for_function): New function, now returns a result.
7490
7491 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7492
7493 * stack.c (iterate_over_block_arg_vars): Fix comment.
7494 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
7495
7496 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
7497
7498 PR gdb/23203
7499 * frame.c
7500 (scoped_restore_selected_frame::scoped_restore_selected_frame):
7501 Define.
7502 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
7503 Define.
7504 * frame.h (class scoped_restore_selected_frame): New class.
7505 * stack.c (print_frame_local_vars): Remove catching and rethrowing
7506 of any exception, use scoped_restore_selected_frame to restore the
7507 frame instead.
7508
7509 2018-05-24 Pedro Alves <palves@redhat.com>
7510
7511 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
7512 override.
7513
7514 2018-05-23 Tom Tromey <tom@tromey.com>
7515
7516 * complaints.c (struct complaints): Remove.
7517 (symfile_complaint_book): Remove.
7518 (series): New global.
7519 (complaint_internal): Update.
7520 (clear_complaints): Update.
7521
7522 2018-05-23 Tom Tromey <tom@tromey.com>
7523
7524 * complaints.c (counters): New global.
7525 (struct complain): Remove.
7526 (struct complaints) <root>: Remove.
7527 (complaint_sentinel): Remove.
7528 (symfile_complaint_book): Update.
7529 (find_complaint) Remove.
7530 (complaint_internal, clear_complaints): Update.
7531
7532 2018-05-23 Tom Tromey <tom@tromey.com>
7533
7534 * complaints.c (struct complain) <file, line>: Remove.
7535 (find_complaint): Remove file, line parameters.
7536 (complaint_internal): Update.
7537
7538 2018-05-23 Tom Tromey <tom@tromey.com>
7539
7540 * complaints.c (vcomplaint): Remove.
7541 (complaint_internal) Merge in contents of vcomplaint.
7542
7543 2018-05-23 Tom Tromey <tom@tromey.com>
7544
7545 * complaints.c (struct complaints) <explanation>: Remove.
7546 (symfile_explanations): Remove.
7547 (symfile_complaint_book): Update.
7548 (vcomplaint): Update.
7549 (struct explanation): Remove.
7550
7551 2018-05-23 Tom Tromey <tom@tromey.com>
7552
7553 * complaints.c (symfile_complaints): Remove.
7554 (complaint_internal): Remove "complaints" parameter.
7555 (clear_complaints, vcomplaint): Remove "c" parameter.
7556 (get_complaints): Remove.
7557 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
7558 (dwarf2_debug_line_missing_file_complaint)
7559 (dwarf2_debug_line_missing_end_sequence_complaint)
7560 (dwarf2_complex_location_expr_complaint)
7561 (dwarf2_const_value_length_mismatch_complaint)
7562 (dwarf2_section_buffer_overflow_complaint)
7563 (dwarf2_macro_malformed_definition_complaint)
7564 (dwarf2_invalid_attrib_class_complaint)
7565 (create_addrmap_from_index, dw2_symtab_iter_next)
7566 (dw2_expand_marked_cus)
7567 (dw2_debug_names_iterator::find_vec_in_debug_names)
7568 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
7569 (create_debug_type_hash_table, init_cutu_and_read_dies)
7570 (partial_die_parent_scope, add_partial_enumeration)
7571 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
7572 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
7573 (read_import_statement, read_file_scope, create_dwo_cu_reader)
7574 (create_cus_hash_table, create_dwp_hash_table)
7575 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
7576 (dwarf2_rnglists_process, dwarf2_ranges_process)
7577 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
7578 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
7579 (handle_struct_member_die, process_structure_scope)
7580 (read_array_type, read_common_block, read_module_type)
7581 (read_tag_pointer_type, read_typedef, read_base_type)
7582 (read_subrange_type, load_partial_dies, partial_die_info::read)
7583 (partial_die_info::read, partial_die_info::read)
7584 (partial_die_info::read, read_checked_initial_length_and_offset)
7585 (dwarf2_string_attr, read_formatted_entries)
7586 (dwarf_decode_line_header)
7587 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
7588 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
7589 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
7590 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7591 (get_signatured_type, get_DW_AT_signature_type)
7592 (decode_locdesc, file_file_name, consume_improper_spaces)
7593 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
7594 (dwarf_decode_macro_bytes, dwarf_decode_macros)
7595 (dwarf2_symbol_mark_computed, set_die_type)
7596 (read_attribute_value): Update.
7597 * stap-probe.c (handle_stap_probe, get_stap_base_address):
7598 Update.
7599 * dbxread.c (unknown_symtype_complaint)
7600 (lbrac_mismatch_complaint, repeated_header_complaint)
7601 (set_namestring, function_outside_compilation_unit_complaint)
7602 (read_dbx_symtab, process_one_symbol): Update.
7603 * gdbtypes.c (stub_noname_complaint): Update.
7604 * windows-nat.c (handle_unload_dll): Update.
7605 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
7606 (decode_base_type): Update.
7607 * xcoffread.c (bf_notfound_complaint, ef_complaint)
7608 (eb_complaint, record_include_begin, record_include_end)
7609 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
7610 (process_xcoff_symbol, read_symbol)
7611 (function_outside_compilation_unit_complaint)
7612 (scan_xcoff_symtab): Update.
7613 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
7614 * buildsym.c (finish_block_internal, make_blockvector)
7615 (end_symtab_get_static_block, augment_type_symtab): Update.
7616 * dtrace-probe.c (dtrace_process_dof)
7617 (dtrace_static_probe_ops::get_probes): Update.
7618 * complaints.h (struct complaint): Don't declare.
7619 (symfile_complaints): Remove.
7620 (complaint_internal): Remove "complaints" parameter.
7621 (complaint): Likewise.
7622 (clear_complaints): Likewise.
7623 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7624 (reread_symbols): Update.
7625 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
7626 (dwarf2_frame_cache, decode_frame_entry): Update.
7627 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
7628 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7629 (info_selectors_command): Update.
7630 * macrotab.c (macro_include, check_for_redefinition)
7631 (macro_undef): Update.
7632 * objfiles.c (filter_overlapping_sections): Update.
7633 * stabsread.c (invalid_cpp_abbrev_complaint)
7634 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
7635 (define_symbol, error_type, read_type, rs6000_builtin_type)
7636 (stabs_method_name_from_physname, read_member_functions)
7637 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
7638 (attach_fields_to_type, complain_about_struct_wipeout)
7639 (read_range_type, read_args, common_block_start)
7640 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
7641 Update.
7642 * mdebugread.c (index_complaint, unknown_ext_complaint)
7643 (basic_type_complaint, bad_tag_guess_complaint)
7644 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
7645 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
7646 (parse_procedure, parse_lines)
7647 (function_outside_compilation_unit_complaint)
7648 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
7649 (bad_tag_guess_complaint, reg_value_complaint): Update.
7650 * cp-support.c (demangled_name_complaint): Update.
7651 * macroscope.c (sal_macro_scope): Update.
7652 * dwarf-index-write.c (class debug_names): Update.
7653
7654 2018-05-23 Tom Tromey <tom@tromey.com>
7655
7656 * complaints.c (clear_complaints): Remove "noisy" parameter.
7657 * complaints.h (clear_complaints): Update.
7658 * symfile.c (syms_from_objfile_1, finish_new_objfile)
7659 (reread_symbols): Update.
7660
7661 2018-05-23 Tom Tromey <tom@tromey.com>
7662
7663 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
7664 SUBSEQUENT_MESSAGE.
7665 (vcomplaint, clear_complaints): Update.
7666 (symfile_explanations): Remove some messages.
7667
7668 2018-05-23 Tom Tromey <tom@tromey.com>
7669
7670 * complaints.c (internal_complaint): Remove.
7671 * complaints.h (internal_complaint): Remove.
7672
7673 2018-05-22 Maciej W. Rozycki <macro@mips.com>
7674
7675 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
7676
7677 2018-05-22 Pedro Alves <palves@redhat.com>
7678
7679 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
7680 (remote_fileio_badfd, remote_fileio_return_errno)
7681 (remote_fileio_return_success, remote_fileio_func_open)
7682 (remote_fileio_func_open, remote_fileio_func_close)
7683 (remote_fileio_func_read, remote_fileio_func_write)
7684 (remote_fileio_func_lseek, remote_fileio_func_rename)
7685 (remote_fileio_func_unlink, remote_fileio_func_stat)
7686 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
7687 (remote_fileio_func_isatty, remote_fileio_func_system): Add
7688 remote_target parameter.
7689 (remote_fio_func_map) <func>: Add remote_target parameter.
7690 (do_remote_fileio_request, remote_fileio_request):
7691 * remote-fileio.h (remote_fileio_request):
7692 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
7693 remote_target parameter.
7694 (remote_notif_process, handle_notification): Adjust to pass down
7695 the remote.
7696 (remote_notif_state_allocate): Add remote_target parameter. Save
7697 it.
7698 * remote-notif.h (struct remote_target): Forward declare.
7699 (struct notif_client) <parse, ack, can_get_pending_events>: Add
7700 remote_target parameter.
7701 (struct remote_notif_state) <remote>: New field.
7702 (remote_notif_ack, remote_notif_parse): Add remote_target
7703 parameter.
7704 (remote_notif_state_allocate, remote_notif_state_allocate): Add
7705 remote_target parameter.
7706 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
7707 (threads_listing_context, rmt_thread_action, protocol_feature)
7708 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
7709 (packet_result, struct threads_listing_context, remote_state):
7710 Move definitions and declarations higher up.
7711 (remote_target) <~remote_target>: Declare.
7712 (remote_download_command_source, remote_file_put, remote_file_get)
7713 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
7714 (remote_hostio_pread_vFile, remote_hostio_send_command)
7715 (remote_hostio_set_filesystem, remote_hostio_open)
7716 (remote_hostio_close, remote_hostio_unlink, remote_state)
7717 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
7718 (get_memory_write_packet_size, get_memory_read_packet_size)
7719 (append_pending_thread_resumptions, remote_detach_1)
7720 (append_resumption, remote_resume_with_vcont)
7721 (add_current_inferior_and_thread, wait_ns, wait_as)
7722 (process_stop_reply, remote_notice_new_inferior)
7723 (process_initial_stop_replies, remote_add_thread)
7724 (btrace_sync_conf, remote_btrace_maybe_reopen)
7725 (remove_new_fork_children, kill_new_fork_children)
7726 (discard_pending_stop_replies, stop_reply_queue_length)
7727 (check_pending_events_prevent_wildcard_vcont)
7728 (discard_pending_stop_replies_in_queue, stop_reply)
7729 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
7730 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
7731 (remote_interrupt_as, remote_interrupt_ns)
7732 (remote_get_noisy_reply, remote_query_attached)
7733 (remote_add_inferior, remote_current_thread, get_current_thread)
7734 (set_thread, set_general_thread, set_continue_thread)
7735 (set_general_process, write_ptid)
7736 (remote_unpack_thread_info_response, remote_get_threadinfo)
7737 (parse_threadlist_response, remote_get_threadlist)
7738 (remote_threadlist_iterator, remote_get_threads_with_ql)
7739 (remote_get_threads_with_qxfer)
7740 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
7741 (get_offsets, remote_check_symbols, remote_supported_packet)
7742 (remote_query_supported, remote_packet_size)
7743 (remote_serial_quit_handler, remote_detach_pid)
7744 (remote_vcont_probe, remote_resume_with_hc)
7745 (send_interrupt_sequence, interrupt_query)
7746 (remote_notif_get_pending_events, fetch_register_using_p)
7747 (send_g_packet, process_g_packet, fetch_registers_using_g)
7748 (store_register_using_P, store_registers_using_G)
7749 (set_remote_traceframe, check_binary_download)
7750 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
7751 (remote_xfer_live_readonly_partial, remote_read_bytes)
7752 (remote_send_printf, remote_flash_write, readchar)
7753 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
7754 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
7755 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
7756 (extended_remote_disable_randomization, extended_remote_run)
7757 (send_environment_packet, extended_remote_environment_support)
7758 (extended_remote_set_inferior_cwd, remote_write_qxfer)
7759 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
7760 (packet_command): Now methods of ...
7761 (remote_target): ... this class.
7762 (m_remote_state) <remote_target>: New field.
7763 (struct remote_state) <stop_reply_queue,
7764 remote_async_inferior_event_token, wait_forever_enabled_p>: New
7765 fields.
7766 (remote_state::remote_state): Allocate stop_reply_queue.
7767 (remote_state): Delete global.
7768 (get_remote_state_raw): Delete.
7769 (remote_target::get_remote_state): Allocate m_remote_state on
7770 demand.
7771 (get_current_remote_target): New.
7772 (remote_ops, extended_remote_ops): Delete.
7773 (wait_forever_enabled_p, remote_async_inferior_event_token):
7774 Delete, moved to struct remote_state.
7775 (remote_target::close): Delete self. Destruction bits split to
7776 ...
7777 (remote_target::~remote_target): ... this.
7778 (show_memory_packet_size): Adjust to use
7779 get_current_remote_target.
7780 (struct protocol_feature) <func>: Add remote_target parameter.
7781 All callers adjusted.
7782 (curr_quit_handler_target): New.
7783 (remote_serial_quit_handler): Reimplement.
7784 (remote_target::open_1): Adjust to use get_current_remote_target.
7785 Heap-allocate remote_target/extended_remote_target instances.
7786 (vcont_builder::vcont_builder): Add remote_target parameter, and
7787 save it in m_remote. All callers adjusted.
7788 (vcont_builder::m_remote): New field.
7789 (vcont_builder::restart, vcont_builder::flush)
7790 (vcont_builder::push_action): Use it.
7791 (remote_target::commit_resume): Use it.
7792 (struct queue_iter_param) <remote>: New field.
7793 (remote_target::remove_new_fork_children): Fill in 'remote' field.
7794 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
7795 (check_pending_event_prevents_wildcard_vcont_callback)
7796 (remote_target::check_pending_events_prevent_wildcard_vcont)
7797 (remote_target::discard_pending_stop_replies)
7798 (remote_target::discard_pending_stop_replies_in_queue)
7799 (remote_target::remote_notif_remove_queued_reply): Fill in
7800 'remote' field.
7801 (remote_notif_get_pending_events): New.
7802 (remote_target::readchar, remote_target::remote_serial_write):
7803 Save/restore curr_quit_handler_target.
7804 (putpkt): New.
7805 (kill_new_fork_children): Fill in 'remote' field.
7806 (packet_command): Use get_current_remote_target, defer to
7807 remote_target method of same name.
7808 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
7809 parameter, and save it in m_remote. All callers adjusted.
7810 (scoped_remote_fd::release): Use m_remote.
7811 (scoped_remote_fd::m_remote): New field.
7812 (remote_file_put, remote_file_get, remote_file_delete): Use
7813 get_current_remote_target, defer to remote_target method of same
7814 name.
7815 (remote_btrace_reset): Add remote_state paremeter. Update all
7816 callers.
7817 (remote_async_inferior_event_handler). Pass down 'data'.
7818 (remote_new_objfile): Use get_current_remote_target.
7819 (remote_target::vcont_r_supported): New.
7820 (set_range_stepping): Use get_current_remote_target and
7821 remote_target::vcont_r_supported.
7822 (_initialize_remote): Don't allocate 'remote_state' and
7823 'stop_reply_queue' globals.
7824 * remote.h (struct remote_target): Forward declare.
7825 (getpkt, putpkt, remote_notif_get_pending_events): Add
7826 'remote_target' parameter.
7827
7828 2018-05-22 Pedro Alves <palves@redhat.com>
7829
7830 * remote.c (vcont_builder): Now a class. Make all data members
7831 private.
7832 (vcont_builder) <vcont_builder, restart, flush, push_action>:
7833 Declare methods.
7834 (vcont_builder_restart): Rename to ...
7835 (vcont_builder::restart): ... this.
7836 (vcont_builder_flush): Rename to ...
7837 (vcont_builder::flush): ... this.
7838 (vcont_builder_push_action): Rename to ...
7839 (vcont_builder::push_action): ... this.
7840 (remote_target::commit_resume): Adjust.
7841
7842 2018-05-22 Pedro Alves <palves@redhat.com>
7843
7844 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
7845 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
7846 (get_fixed_memory_packet_size): New.
7847 (get_memory_packet_size): Use it.
7848 (set_memory_packet_size): Don't override the config size with
7849 DEFAULT_MAX_MEMORY_PACKET_SIZE.
7850 (show_memory_packet_size): Use get_fixed_memory_packet_size.
7851 Don't refer to get_memory_packet_size if not connected to a remote
7852 target. Show "(default)" if configured size is 0.
7853
7854 2018-05-22 Pedro Alves <palves@redhat.com>
7855
7856 * remote.c (remote_target::mourn_inferior): Move
7857 discard_pending_stop_replies call here from ...
7858 (_initialize_remote): ... here.
7859
7860 2018-05-22 Pedro Alves <palves@redhat.com>
7861
7862 * remote.c (compare_section_command): Remove set_general_process
7863 call.
7864
7865 2018-05-22 Pedro Alves <palves@redhat.com>
7866
7867 * remote.c (struct packet_reg, struct remote_arch_state):
7868 Move higher up in the file.
7869 (remote_state) <m_arch_states>: Store remote_arch_state values
7870 instead of remote_arch_state pointers.
7871 (remote_state::get_remote_arch_state): Adjust.
7872
7873 2018-05-22 Pedro Alves <palves@redhat.com>
7874
7875 * remote.c: Include <unordered_map>.
7876 (remote_state): Now a class.
7877 (remote_state) <get_remote_arch_state>: Declare method.
7878 <get_remote_arch_state>: New field.
7879 (remote_arch_state) <remote_arch_state>: Declare ctor.
7880 <regs>: Now a unique_ptr.
7881 (remote_gdbarch_data_handle): Delete.
7882 (get_remote_arch_state): Delete.
7883 (remote_state::get_remote_arch_state): New.
7884 (get_remote_state): Adjust to call remote_state's
7885 get_remote_arch_state method.
7886 (init_remote_state): Delete, bits factored out to ...
7887 (remote_arch_state::remote_arch_state): ... this new method.
7888 (get_remote_packet_size, get_memory_packet_size)
7889 (process_g_packet, remote_target::fetch_registers)
7890 (remote_target::prepare_to_store, store_registers_using_G)
7891 (remote_target::store_registers, remote_target::get_trace_status):
7892 Adjust to call remote_state's method.
7893 (_initialize_remote): Remove reference to
7894 remote_gdbarch_data_handle.
7895
7896 2018-05-22 Pedro Alves <palves@redhat.com>
7897
7898 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
7899 pread>: New method declarations.
7900 (remote_target::open_1): Adjust.
7901 (readahead_cache_invalidate): Rename to ...
7902 (readahead_cache::invalidate): ... this, and adjust to be a class
7903 method.
7904 (readahead_cache_invalidate_fd): Rename to ...
7905 (readahead_cache::invalidate_fd): ... this, and adjust to be a
7906 class method.
7907 (remote_hostio_pwrite): Adjust.
7908 (remote_hostio_pread_from_cache): Rename to ...
7909 (readahead_cache::pread): ... this, and adjust to be a class
7910 method.
7911 (remote_hostio_close): Adjust.
7912
7913 2018-05-22 Pedro Alves <palves@redhat.com>
7914
7915 * remote.c (remote_hostio_close_cleanup): Delete.
7916 (class scoped_remote_fd): New.
7917 (remote_file_put, remote_file_get): Use it.
7918
7919 2018-05-22 Pedro Alves <palves@redhat.com>
7920
7921 (struct vCont_action_support): Use bool and initialize all fields.
7922 (struct readahead_cache): Initialize all fields.
7923 (remote_state): Use bool and initialize all fields.
7924 (remote_state::remote_state, remote_state::~remote_state): New.
7925 (new_remote_state): Delete.
7926 (_initialize_remote): Use new to allocate remote_state.
7927
7928 2018-05-22 Pedro Alves <palves@redhat.com>
7929 張俊芝 <zjz@zjz.name>
7930
7931 PR gdb/22973
7932 * c-exp.y: Include "c-support.h".
7933 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
7934 of tolower. Use c_ident_is_alpha to scan names.
7935 * c-lang.c: Include "c-support.h".
7936 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
7937 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
7938 * c-support.h: New file, with bits factored out from ...
7939 * cp-name-parser.y: ... this file.
7940 Include "c-support.h".
7941 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
7942 c-support.h and renamed.
7943 (symbol_end, yylex): Adjust.
7944
7945 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7946
7947 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
7948 parameter type to CORE_ADDR.
7949 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
7950 parameter type in declaration to CORE_ADDR.
7951 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
7952 target_auxv_search to get AT_HWCAP and use the result to get the
7953 target description.
7954 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
7955 to CORE_ADDR. Remove the cast of the return value to unsigned
7956 long. Fix error predicate of target_auxv_search.
7957 (ppc_linux_nat_target::read_description): Change the type of the
7958 hwcap variable to CORE_ADDR.
7959
7960 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7961
7962 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
7963 if the size of fpscr is larger than 32 bits.
7964
7965 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7966
7967 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
7968 (ppc32_linux_vsxregmap): New global.
7969 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
7970 regcache_supply_regset, and regcache_collect_regset.
7971 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
7972 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
7973 (fetch_vsx_register, store_vsx_register): Remove.
7974 (fetch_vsx_registers): Add regno parameter. Get regset using
7975 ppc_linux_vsxregset. Use regset to supply registers.
7976 (store_vsx_registers): Add regno parameter. Get regset using
7977 ppc_linux_vsxregset. Use regset to collect registers.
7978 (fetch_register): Call fetch_vsx_registers instead of
7979 fetch_vsx_register.
7980 (store_register): Call store_vsx_registers instead of
7981 store_vsx_register.
7982 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
7983 new regno parameter.
7984 (store_ppc_registers): Call store_vsx_registers with -1 for the
7985 new regno parameter.
7986 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
7987 (ppc_collect_vsxregset): Remove.
7988
7989 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
7990
7991 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
7992 offset fields.
7993 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
7994 for vector register offset fields.
7995 (ppc64_fbsd_reg_offsets): Likewise.
7996 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7997 to vector register offset fields.
7998 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
7999 to vector register offset fields.
8000 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
8001 vector register offset fields.
8002 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
8003 initializers for vector register offset fields.
8004 (rs6000_aix64_reg_offsets): Likewise.
8005 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
8006 (ppc_supply_vrregset): Remove.
8007 (ppc_collect_vrregset): Remove.
8008 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
8009 (ppc_linux_vrregset) : New function.
8010 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
8011 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
8012 (ppc32_linux_vrregset): Remove.
8013 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
8014 and use result instead of ppc32_linux_vrregset.
8015 (ppc32_linux_reg_offsets): Remove initializers for vector register
8016 offset fields.
8017 (ppc64_linux_reg_offsets): Likewise.
8018 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
8019 * ppc-linux-nat.c: Include regset.h.
8020 (gdb_vrregset_t): Adjust comment to account for little-endian
8021 mode.
8022 (supply_vrregset, fill_vrregset): Remove.
8023 (fetch_altivec_register, store_altivec_register): Remove.
8024 (fetch_altivec_registers): Add regno parameter. Get regset using
8025 ppc_linux_vrregset. Use regset to supply registers.
8026 (store_altivec_registers): Add regno parameter. Get regset using
8027 ppc_linux_vrregset. Use regset to collect registers.
8028 (fetch_register): Call fetch_altivec_registers instead of
8029 fetch_altivec_register.
8030 (store_register): Call store_altivec_registers instead of
8031 store_altivec_register.
8032 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
8033 the new regno parameter.
8034 (store_ppc_registers): Call store_altivec_registers with -1 for
8035 the new regno parameter.
8036
8037 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8038
8039 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
8040 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
8041 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
8042 (gdb_vrregset_t): Change array type size to
8043 PPC_LINUX_SIZEOF_VRREGSET.
8044 (gdb_vsxregset_t): Change array type size to
8045 PPC_LINUX_SIZEOF_VSXREGSET.
8046 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
8047 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
8048 PPC_LINUX_SIZEOF_VSXREGSET.
8049
8050 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8051
8052 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
8053 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
8054 nat/ppc-linux.c.
8055 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
8056 ppc_linux_target_wordsize with tid.
8057 (ppc_linux_nat_target::read_description): Call ppc_linux_target
8058 wordsize with tid.
8059 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
8060 (ppc64_64bit_inferior_p): Add static and inline specifiers.
8061 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
8062 tid parameter. Remove static specifier.
8063 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
8064 (ppc_linux_target_wordsize): New declaration.
8065
8066 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8067
8068 * arch/ppc-linux-common.c: New file.
8069 * arch/ppc-linux-common.h: New file.
8070 * arch/ppc-linux-tdesc.h: New file.
8071 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
8072 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
8073 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
8074 arch/ppc-linux-tdesc.h.
8075 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
8076 arch/ppc-linux-tdesc.h.
8077 (ppc_linux_nat_target::read_description): Remove target
8078 description matching code. Fill a ppc_linux_features struct and
8079 call ppc_linux_match_description with it. Move comment about ISA
8080 2.05 to ppc-linux-common.c.
8081 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
8082 arch/ppc-linux-tdesc.h.
8083 (ppc_linux_core_read_description): Remove target description
8084 matching code. Fill a ppc_linux_features struct and call
8085 ppc_linux_match_description with it.
8086 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
8087 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
8088 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
8089 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
8090 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
8091 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
8092 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
8093 (tdesc_powerpc_e500l): Remove.
8094
8095 2018-05-22 Joel Brobecker <brobecker@adacore.com>
8096
8097 * ada-lang.c (catch_assert_command): Pass empty string instead
8098 of NULL for excep_string argument.
8099
8100 2018-05-22 Maciej W. Rozycki <macro@mips.com>
8101
8102 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
8103 the width of the requested register exceeds the width of the
8104 `ptrace' data type.
8105
8106 2018-05-21 Tom Tromey <tom@tromey.com>
8107
8108 * printcmd.c (output_command): Remove.
8109 (output_command_const): Rename to output_command.
8110 * valprint.h (output_command): Rename from output_command_const.
8111 * tracepoint.c (trace_dump_actions): Call output_command.
8112
8113 2018-05-21 Tom Tromey <tom@tromey.com>
8114
8115 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
8116 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
8117 * ada-lang.h (create_ada_exception_catchpoint): Update.
8118 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
8119 std::string.
8120 (create_excep_cond_exprs, ~ada_catchpoint)
8121 (should_stop_exception, print_one_exception)
8122 (print_mention_exception, print_recreate_exception): Update.
8123 (ada_get_next_arg): Remove.
8124 (catch_ada_exception_command_split): Use std::string. Change type
8125 of "excep_string", "cond_string".
8126 (catch_ada_exception_command): Update.
8127 (create_ada_exception_catchpoint): Change type of excep_string.
8128 (ada_exception_sal): Remove excep_string parameter.
8129 (~ada_catchpoint): Remove.
8130
8131 2018-05-21 Tom Tromey <tom@tromey.com>
8132
8133 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
8134 cleanup.
8135
8136 2018-05-21 Tom Tromey <tom@tromey.com>
8137
8138 * ada-lang.c (ada_exception_message_1, ada_exception_message):
8139 Return unique_xmalloc_ptr.
8140 (print_it_exception): Update.
8141
8142 2018-05-21 Tom Tromey <tom@tromey.com>
8143
8144 * tracepoint.c (trace_dump_actions): Use std::string.
8145
8146 2018-05-21 Tom Tromey <tom@tromey.com>
8147
8148 * symfile.c (reread_symbols): Use std::string for original_name.
8149
8150 2018-05-21 Tom Tromey <tom@tromey.com>
8151
8152 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
8153 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
8154 constructor.
8155
8156 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
8157
8158 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
8159 instance to...
8160 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
8161 * objfiles.c (get_objfile_bfd_data): Allocate
8162 objfile_per_bfd_storage with obstack_new when allocating on
8163 obstack.
8164
8165 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
8166
8167 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
8168 OBSTACK_ZALLOC.
8169 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
8170 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
8171 * mdebugread.c (mdebug_build_psymtabs): Likewise.
8172 (add_pending): Likewise.
8173 (parse_symbol): Likewise.
8174 (parse_partial_symbols): Likewise.
8175 (psymtab_to_symtab_1): Likewise.
8176 (new_psymtab): Likewise.
8177 (elfmdebug_build_psymtabs): Likewise.
8178 * minsyms.c (terminate_minimal_symbol_table): Likewise.
8179 * objfiles.c (get_objfile_bfd_data): Likewise.
8180 (objfile_register_static_link): Likewise.
8181 * psymtab.c (allocate_psymtab): Likewise.
8182 * stabsread.c (read_member_functions): Likewise.
8183 * xcoffread.c (xcoff_end_psymtab): Likewise.
8184
8185 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
8186
8187 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
8188 compiler supports std::is_trivially_constructible.
8189 * common/poison.h: Include obstack.h.
8190 (IsMallocable): Define to is_trivially_constructible if the
8191 compiler supports it, define to true_type otherwise.
8192 (xobnew): New.
8193 (XOBNEW): Redefine.
8194 (xobnewvec): New.
8195 (XOBNEWVEC): Redefine.
8196 * gdb_obstack.h (obstack_zalloc): New.
8197 (OBSTACK_ZALLOC): Redefine.
8198 (obstack_calloc): New.
8199 (OBSTACK_CALLOC): Redefine.
8200 (obstack_new): New.
8201 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
8202 (gdbarch_obstack): New declaration in gdbarch.h, definition in
8203 gdbarch.c.
8204 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
8205 obstack_calloc/obstack_zalloc.
8206 (gdbarch_obstack_zalloc): Remove.
8207 * target-descriptions.c (tdesc_data_init): Use obstack_new.
8208
8209 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8210
8211 * stack.c (backtrace_command_1): Remove useless variable int i.
8212
8213 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8214
8215 * stack.c (print_frame_info): Fix comment.
8216
8217 2018-05-18 Tom Tromey <tom@tromey.com>
8218
8219 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
8220 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
8221 (~dwarf2_per_objfile): Update
8222 (dwarf2_get_dwz_file): Use new.
8223 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
8224 unique_ptr.
8225
8226 2018-05-18 Tom Tromey <tom@tromey.com>
8227
8228 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
8229 unique_ptr.
8230 * dwarf2read.c (struct dwp_file): Add constructor and
8231 initializers.
8232 (open_and_init_dwp_file): Return a unique_ptr.
8233 (dwarf2_per_objfile, create_dwp_hash_table)
8234 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
8235 (lookup_dwo_unit_in_dwp): Update.
8236 (open_and_init_dwp_file, get_dwp_file): Update.
8237
8238 2018-05-18 Tom Tromey <tom@tromey.com>
8239
8240 * dwarf2read.c (dwarf2_per_objfile): Update.
8241 (struct mapped_index): Add initializers.
8242 (dwarf2_read_index): Use new.
8243 (dw2_symtab_iter_init): Update.
8244 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
8245 unique_ptr.
8246
8247 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
8248
8249 * dwarf2read.c (mapped_index) <total_size>: Remove.
8250
8251 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
8252
8253 * unittests/format_pieces-selftests.c (test_format_specifier):
8254 Add ARI comments.
8255
8256 2018-05-18 Tom Tromey <tom@tromey.com>
8257
8258 * c-typeprint.c (maybe_print_hole): New function.
8259 (c_print_type_struct_field_offset): Update.
8260 (c_type_print_base_struct_union): Call maybe_print_hole.
8261
8262 2018-05-17 Keith Seitz <keiths@redhat.com>
8263
8264 * breakpoint.c (build_bpstat_chain): New function, moved from
8265 bpstat_stop_status.
8266 (bpstat_stop_status): Add optional parameter, `stop_chain'.
8267 If no stop chain is passed, call build_bpstat_chain to build it.
8268 * breakpoint.h (build_bpstat_chain): Declare.
8269 (bpstat_stop_status): Move documentation here from breakpoint.c.
8270 * infrun.c (handle_signal_stop): Before eliding inlined frames,
8271 build the stop chain and pass it to skip_inline_frames.
8272 Pass this stop chain to bpstat_stop_status.
8273 * inline-frame.c: Include breakpoint.h.
8274 (stopped_by_user_bp_inline_frame): New function.
8275 (skip_inline_frames): Add parameter `stop_chain'.
8276 Move documention to inline-frame.h.
8277 If non-NULL, use stopped_by_user_bp_inline_frame to determine
8278 whether the frame should be elided.
8279 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
8280 Add moved documentation and update for new parameter.
8281
8282 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
8283
8284 PR cli/14975
8285 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8286 unittests/format_pieces-selftests.c.
8287 * common/format.h (format_piece) <operator==>: New.
8288 (format_pieces) <operator[]>: Remove.
8289 * common/format.c (format_pieces::format_pieces): Handle \e.
8290 * unittests/format_pieces-selftests.c: New.
8291
8292 2018-05-17 Tom Tromey <tom@tromey.com>
8293
8294 PR symtab/23010:
8295 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
8296 (dw2_instantiate_symtab): Add skip_partial parameter.
8297 (dw2_find_last_source_symtab, dw2_map_expand_apply)
8298 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
8299 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
8300 (dw2_expand_symtabs_matching_one)
8301 (dw2_find_pc_sect_compunit_symtab)
8302 (dw2_debug_names_lookup_symbol)
8303 (dw2_debug_names_expand_symtabs_for_function): Update.
8304 (init_cutu_and_read_dies): Add skip_partial parameter.
8305 (process_psymtab_comp_unit, build_type_psymtabs_1)
8306 (process_skeletonless_type_unit, load_partial_comp_unit)
8307 (psymtab_to_symtab_1): Update.
8308 (load_full_comp_unit): Add skip_partial parameter.
8309 (process_imported_unit_die, dwarf2_read_addr_index)
8310 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
8311 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
8312 (read_signatured_type): Update.
8313
8314 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
8315
8316 * value.c (release_value): Remove unused variable.
8317 (record_latest_value): Likewise.
8318 (access_value_history): Likewise.
8319 (preserve_values): Likewise.
8320
8321 2018-05-17 Tom Tromey <tom@tromey.com>
8322
8323 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
8324 Initialize.
8325
8326 2018-05-16 Maciej W. Rozycki <macro@mips.com>
8327
8328 PR gdb/22286
8329 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
8330 Also handle registers whose width is not a multiple of
8331 PTRACE_TYPE_RET.
8332 (linux_nat_trad_target::store_register): Likewise.
8333
8334 2018-05-16 Tom Tromey <tom@tromey.com>
8335
8336 * gdbcore.h (core_bfd): Redefine.
8337 * corelow.c (core_target::close): Update.
8338 (core_target_open): Update.
8339 * progspace.h (struct program_space) <cbfd>: Now a
8340 gdb_bfd_ref_ptr.
8341
8342 2018-05-16 Tom Tromey <tom@tromey.com>
8343
8344 PR cli/19551:
8345 * symfile-add-flags.h (enum symfile_add_flags)
8346 <SYMFILE_NOT_FILENAME>: New constant.
8347 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
8348 objfile name from BFD.
8349 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
8350 * minidebug.c (find_separate_debug_file_in_section): Put
8351 ".gnu_debugdata" into BFD's file name.
8352
8353 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
8354
8355 * regcache.c (regcache_read_ftype, regcache_write_ftype):
8356 Remove.
8357
8358 2018-05-15 Tamar Christina <tamar.christina@arm.com>
8359
8360 PR binutils/21446
8361 * aarch64-tdep.c (aarch64_analyze_prologue,
8362 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
8363 Indicate not interested in errors.
8364
8365 2018-05-15 Maciej W. Rozycki <macro@mips.com>
8366
8367 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
8368 Supply the MIPS_ZERO_REGNUM register.
8369
8370 2018-05-15 Maciej W. Rozycki <macro@mips.com>
8371
8372 * mips-tdep.c (mask_address_var): Make variable static.
8373
8374 2018-05-14 Tom Tromey <tom@tromey.com>
8375
8376 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
8377
8378 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
8379
8380 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
8381 FXSAVE_ADDR for the mxcsr register.
8382
8383 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
8384
8385 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
8386
8387 2018-05-11 Pedro Alves <palves@redhat.com>
8388
8389 * corelow.c (core_target) <core_target>: No longer inline.
8390 Initialize m_core_gdbarch, m_core_vec and build the section table
8391 here.
8392 <~core_target>: New.
8393 <core_gdbarch, get_core_register_section>: New methods.
8394 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
8395 factored out from ...
8396 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
8397 (core_ops): Delete.
8398 (sniff_core_bfd): Add gdbarch parameter.
8399 (core_close): Delete, merged into ...
8400 (core_target::close): ... here. Delete self.
8401 (core_close_cleanup): Delete.
8402 (core_target_open): Allocate a core_target on the heap. Use a
8403 unique_ptr instead of a cleanup. Bits moved into the core_target
8404 ctor. Adjust to use core_target methods instead of globals.
8405 (get_core_register_section): Rename to ...
8406 (core_target::get_core_register_section): ... this and adjust.
8407 (struct get_core_registers_cb_data): New.
8408 (get_core_registers_cb): Use it. Use bool.
8409 (core_target::fetch_registers, core_target::files_info)
8410 (core_target::xfer_partial, core_target::read_description)
8411 (core_target::pid_to, core_target::thread_name): Adjust to
8412 reference class fields instead of globals.
8413 * target.h (struct target_ops_deleter, target_ops_up): New.
8414
8415 2018-05-11 Pedro Alves <palves@redhat.com>
8416
8417 * corefile.c (core_file_command): Move to corelow.c.
8418 * corelow.c (the_core_target): Delete.
8419 (core_file_command): Moved from corefile.c. Check exec_bfd
8420 instead of the_core_target. Use target_detach instead of calling
8421 into the_core_target directly.
8422 (maybe_say_no_core_file_now): New.
8423 (core_target::detach): Use it.
8424 (_initialize_corelow): Remove references to the_core_target.
8425 * gdbcore.h (the_core_target): Delete.
8426
8427 2018-05-11 Tom Tromey <tromey@redhat.com>
8428 Pedro Alves <palves@redhat.com>
8429
8430 * corefile.c (core_bfd): Remove.
8431 * gdbcore.h (core_bfd): Now a macro.
8432 * progspace.h (struct program_space) <cbfd>: New field.
8433
8434 2018-05-11 Tom Tromey <tom@tromey.com>
8435
8436 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
8437 gdb::def_vector.
8438
8439 2018-05-10 Tom Tromey <tom@tromey.com>
8440
8441 * configure: Rebuild.
8442 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
8443
8444 2018-05-10 Joel Brobecker <brobecker@adacore.com>
8445
8446 PR server/23158:
8447 * regformats/regdat.sh: Adjust script, following the addition
8448 of the new expedite_regs parameter to init_target_desc.
8449
8450 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
8451
8452 PR gdb/23127
8453 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
8454 set_gdbarch_significant_addr_bit.
8455 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
8456 set_gdbarch_significant_addr_bit.
8457 * utils.c (address_significant): Update to sign extend addr.
8458
8459 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
8460
8461 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
8462 (xtensa_linux_init_abi): Limit tdep->num_regs by
8463 tdep->num_nopriv_regs.
8464 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
8465 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
8466 not initialized.
8467
8468 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
8469
8470 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
8471
8472 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
8473
8474 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
8475 (I387_MXCSR_INIT_VAL): New constant.
8476 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
8477 buffer if it was supplied by the inferior.
8478 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
8479 (i387_xsave_get_clear_bv): New function.
8480 (i387_supply_xsave): Only read x87 control registers from the
8481 xsave buffer if the feature is enabled, and the state will have
8482 been written, otherwise, provide a suitable default.
8483 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
8484 including x87 control registers. Update control registers if they
8485 have changed from the default value, and mark features as enabled
8486 as required.
8487 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
8488
8489 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
8490
8491 * spu-tdep.c (info_spu_event_command): Fix output formatting.
8492
8493 2018-05-07 Tom Tromey <tom@tromey.com>
8494
8495 * configure: Rebuild.
8496 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
8497
8498 2018-05-07 Tom Tromey <tom@tromey.com>
8499
8500 PR tdep/20362:
8501 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
8502 bit. Use correct value for VDIV.
8503
8504 2018-05-04 Tom Tromey <tom@tromey.com>
8505
8506 * configure: Rebuild.
8507 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
8508
8509 2018-05-04 Tom Tromey <tom@tromey.com>
8510
8511 * linux-record.c (record_linux_system_call) <case
8512 RECORD_SYS_RECVFROM>: Add "break".
8513
8514 2018-05-04 Tom Tromey <tom@tromey.com>
8515
8516 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
8517 Add missing "break".
8518 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
8519 Add missing "break".
8520
8521 2018-05-04 Tom Tromey <tom@tromey.com>
8522
8523 * rs6000-tdep.c (ppc_process_record_op4)
8524 (ppc_process_record_op63): Add fall-through comment.
8525
8526 2018-05-04 Tom Tromey <tom@tromey.com>
8527
8528 * i386-tdep.c (i386_process_record): Add fall-through comment.
8529
8530 2018-05-04 Tom Tromey <tom@tromey.com>
8531
8532 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
8533 comment.
8534
8535 2018-05-04 Tom Tromey <tom@tromey.com>
8536
8537 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
8538 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
8539 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
8540 comment.
8541 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
8542 comment.
8543 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
8544 comment.
8545
8546 2018-05-04 Tom Tromey <tom@tromey.com>
8547
8548 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
8549
8550 2018-05-04 Tom Tromey <tom@tromey.com>
8551
8552 * s390-tdep.c (s390_process_record): Fix fall-through comments.
8553 * xcoffread.c (scan_xcoff_symtab): Move comment later.
8554 * symfile.c (section_is_mapped): Fix fall-through comment.
8555 * stabsread.c (define_symbol, read_member_functions): Fix
8556 fall-through comment.
8557 * s390-linux-tdep.c (s390_process_record): Fix fall-through
8558 comment.
8559 * remote.c (remote_wait_as): Fix fall-through comment.
8560 * p-exp.y (yylex): Fix fall-through comment.
8561 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
8562 comment.
8563 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
8564 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
8565 * jv-exp.y (yylex): Fix fall-through comment.
8566 * go-exp.y (lex_one_token): Fix fall-through comment.
8567 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
8568 fall-through comment.
8569 * f-exp.y (yylex): Fix fall-through comment.
8570 * dwarf2read.c (process_die): Fix fall-through comments.
8571 * dbxread.c (process_one_symbol): Fix fall-through comment.
8572 * d-exp.y (lex_one_token): Fix fall-through comment.
8573 * cp-name-parser.y (yylex): Fix fall-through comment.
8574 * coffread.c (coff_symtab_read): Fix fall-through comment.
8575 * c-exp.y (lex_one_token): Fix fall-through comment.
8576 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
8577 comment.
8578 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
8579 comment.
8580
8581 2018-05-04 Tom Tromey <tom@tromey.com>
8582
8583 PR python/22730:
8584 * NEWS: Mention gdb.execute change.
8585 * gdbcmd.h (execute_control_command): Don't declare.
8586 * python/python.c (execute_gdb_command): Use read_command_lines_1,
8587 execute_control_commands, execute_control_commands_to_string.
8588 * cli/cli-script.h (execute_control_commands)
8589 (execute_control_commands_to_string): Declare.
8590 (execute_control_command): Add from_tty parameter.
8591 * cli/cli-script.c (execute_control_commands)
8592 (execute_control_commands_to_string): New functions.
8593 (execute_user_command): Use execute_control_commands.
8594 (execute_control_command_1): Add "from_tty" parameter. Update.
8595 (execute_control_command): Likewise.
8596
8597 2018-05-04 Tom Tromey <tom@tromey.com>
8598
8599 PR python/22731:
8600 * NEWS: Mention that breakpoint commands are writable.
8601 * python/py-breakpoint.c (bppy_set_commands): New function.
8602 (breakpoint_object_getset) <"commands">: Use it.
8603
8604 2018-05-04 Tom Tromey <tom@tromey.com>
8605
8606 * tracepoint.c (actions_command): Update.
8607 * mi/mi-cmd-break.c (mi_command_line_array)
8608 (mi_command_line_array_cnt, mi_command_line_array_ptr)
8609 (mi_read_next_line): Remove.
8610 (mi_cmd_break_commands): Update.
8611 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
8612 function_view.
8613 * cli/cli-script.c (get_command_line): Update.
8614 (process_next_line): Use function_view. Constify.
8615 (recurse_read_control_structure, read_command_lines)
8616 (read_command_lines_1): Change argument types to function_view.
8617 (do_define_command, document_command): Update.
8618 * breakpoint.h (check_tracepoint_command): Don't declare.
8619 * breakpoint.c (check_tracepoint_command): Remove.
8620 (commands_command_1, create_tracepoint_from_upload): Update.
8621
8622 2018-05-04 Tom Tromey <tom@tromey.com>
8623
8624 PR gdb/11750:
8625 * cli/cli-script.h (enum command_control_type) <define_control>:
8626 New constant.
8627 * cli/cli-script.c (multi_line_command_p): Handle define_control.
8628 (build_command_line, execute_control_command_1)
8629 (process_next_line): Likewise.
8630 (do_define_command): New function, extracted from define_command.
8631 (define_command): Use it.
8632
8633 2018-05-04 Tom Tromey <tom@tromey.com>
8634
8635 * tracepoint.c (actions_command): Update.
8636 * cli/cli-script.h (read_command_lines): Update.
8637 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
8638 (MAX_TMPBUF): Remove define.
8639 (define_command): Use string_printf.
8640 (document_command): Likewise.
8641 * breakpoint.c (commands_command_1): Update.
8642
8643 2018-05-04 Tom Tromey <tom@tromey.com>
8644
8645 * top.c (execute_command): Update.
8646 * cli/cli-script.h (print_command_lines): Now varargs.
8647 * cli/cli-script.c (print_command_lines): Now varargs.
8648 (execute_control_command_1) <case while_control, case if_control>:
8649 Update.
8650
8651 2018-05-04 Tom Tromey <tom@tromey.com>
8652
8653 * tracepoint.c (all_tracepoint_actions): Rename from
8654 all_tracepoint_actions_and_cleanup. Change return type.
8655 (actions_command, encode_actions_1, encode_actions)
8656 (trace_dump_actions, tdump_command): Update.
8657 * remote.c (remote_download_command_source): Update.
8658 * python/python.c (gdbpy_eval_from_control_command)
8659 (python_command, python_interactive_command): Update.
8660 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8661 * guile/guile.c (guile_command)
8662 (gdbscm_eval_from_control_command, guile_command): Update.
8663 * compile/compile.c (compile_code_command)
8664 (compile_print_command, compile_to_object): Update.
8665 * cli/cli-script.h (struct command_lines_deleter): New.
8666 (counted_command_line): New typedef.
8667 (struct command_line): Add constructor, destructor.
8668 <body_list>: Remove.
8669 <body_list_0, body_list_1>: New members.
8670 (command_line_up): Remove typedef.
8671 (read_command_lines, read_command_lines_1, get_command_line):
8672 Update.
8673 (copy_command_lines): Don't declare.
8674 * cli/cli-script.c (build_command_line): Use "new".
8675 (get_command_line): Return counted_command_line.
8676 (print_command_lines, execute_user_command)
8677 (execute_control_command_1, while_command, if_command): Update.
8678 (realloc_body_list): Remove.
8679 (process_next_line, recurse_read_control_structure): Update.
8680 (read_command_lines, read_command_lines_1): Return counted_command_line.
8681 (free_command_lines): Use "delete".
8682 (copy_command_lines): Remove.
8683 (define_command, document_command, show_user_1): Update.
8684 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
8685 a counted_command_line.
8686 * breakpoint.h (counted_command_line): Remove typedef.
8687 (breakpoint_set_commands): Update.
8688 * breakpoint.c (check_no_tracepoint_commands)
8689 (validate_commands_for_breakpoint): Update.
8690 (breakpoint_set_commands): Change commands to be a
8691 counted_command_line.
8692 (commands_command_1, update_dprintf_command_list)
8693 (create_tracepoint_from_upload): Update.
8694
8695 2018-05-04 Tom Tromey <tom@tromey.com>
8696
8697 * cli/cli-decode.h (cmd_list_element): New constructor.
8698 (~cmd_list_element): New destructor.
8699 (struct cmd_list_element): Add initializers.
8700 * cli/cli-decode.c (do_add_cmd): Use "new".
8701 (delete_cmd): Use "delete".
8702
8703 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
8704 Pedro Alves <palves@redhat.com>
8705
8706 PR breakpoints/19806 and support for PR external/20207.
8707 * NEWS: Mention Aarch64 watchpoint improvements.
8708 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
8709 watchpoints and PR external/20207 watchpoints.
8710 * nat/aarch64-linux-hw-point.c
8711 (kernel_supports_any_contiguous_range): New.
8712 (aarch64_watchpoint_offset): New.
8713 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
8714 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
8715 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
8716 (aarch64_align_watchpoint): New parameters aligned_offset_p and
8717 next_addr_orig_p. Support PR external/20207 watchpoints.
8718 (aarch64_downgrade_regs): New.
8719 (aarch64_dr_state_insert_one_point): New parameters offset and
8720 addr_orig.
8721 (aarch64_dr_state_remove_one_point): Likewise.
8722 (aarch64_handle_breakpoint): Update caller.
8723 (aarch64_handle_aligned_watchpoint): Likewise.
8724 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
8725 aligned_offset.
8726 (aarch64_linux_set_debug_regs): Remove const from state. Call
8727 aarch64_downgrade_regs.
8728 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
8729 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
8730 (DR_CONTROL_MASK): ... this.
8731 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
8732 (unsigned int aarch64_watchpoint_offset): New prototype.
8733 (aarch64_linux_set_debug_regs): Remove const from state.
8734 * utils.c (align_up, align_down): Move to ...
8735 * common/common-utils.c (align_up, align_down): ... here.
8736 * utils.h (align_up, align_down): Move to ...
8737 * common/common-utils.h (align_up, align_down): ... here.
8738
8739 2018-05-04 Joel Brobecker <brobecker@adacore.com>
8740
8741 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
8742 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
8743 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
8744 Re-implement to match the ABI as summarized in GCC's
8745 gcc/config/sparc/sparc.c. All callers updated.
8746 (sparc32_store_arguments): Remove assertion.
8747
8748 2018-05-04 Tom Tromey <tom@tromey.com>
8749
8750 * printcmd.c: Don't include tui.h.
8751 (decode_format): Use skip_spaces.
8752
8753 2018-05-04 Tom Tromey <tom@tromey.com>
8754
8755 PR gdb/22619:
8756 * printcmd.c (last_count): New global.
8757 (x_command): Use saved count when repeating.
8758
8759 2018-05-04 Tom Tromey <tom@tromey.com>
8760
8761 * nto-procfs.c (do_closedir_cleanup): Remove.
8762 (procfs_pidlist): Use gdb_dir_up.
8763 * procfs.c (do_closedir_cleanup): Remove.
8764 (proc_update_threads): Use gdb_dir_up.
8765 * common/filestuff.h (struct gdb_dir_deleter): New.
8766 (gdb_dir_up): New typedef.
8767
8768 2018-05-04 Tom Tromey <tom@tromey.com>
8769
8770 * ada-lang.c (print_mention_exception): Use std::string.
8771
8772 2018-05-04 Tom Tromey <tom@tromey.com>
8773
8774 * ada-lang.c (create_excep_cond_exprs): Update.
8775 (ada_exception_catchpoint_cond_string): Use std::string.
8776
8777 2018-05-04 Tom Tromey <tom@tromey.com>
8778
8779 * ada-lang.c (xget_renaming_scope): Return std::string.
8780 (old_renaming_is_invisible): Update.
8781
8782 2018-05-04 Tom Tromey <tom@tromey.com>
8783
8784 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
8785 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
8786
8787 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
8788
8789 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
8790
8791 2018-05-04 Tom Tromey <tom@tromey.com>
8792
8793 * remote.c (remote_query_supported_append): Change type.
8794 (remote_check_symbols): Update.
8795
8796 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
8797
8798 PR gdb/11420
8799 * configure.ac: Prepend libpython.
8800 * python/python-config.py: Likewise.
8801 * configure: Regenerate.
8802
8803 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
8804
8805 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
8806
8807 2018-05-03 Pedro Alves <palves@redhat.com>
8808
8809 * s390-linux-nat.c
8810 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
8811 override. Write 'true' instead of '1'.
8812 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
8813 declaration.
8814
8815 2018-05-02 Pedro Alves <palves@redhat.com>
8816
8817 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
8818 add_inf_child_target.
8819 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
8820 add_inf_child_target.
8821 * aix-thread.c (aix_thread_target_info): New.
8822 (aix_thread_target) <shortname, longname, doc>: Delete.
8823 <info>: New.
8824 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
8825 add_inf_child_target.
8826 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
8827 add_inf_child_target.
8828 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
8829 add_inf_child_target.
8830 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
8831 add_inf_child_target.
8832 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
8833 add_inf_child_target.
8834 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
8835 add_inf_child_target.
8836 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
8837 add_inf_child_target.
8838 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
8839 add_inf_child_target.
8840 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
8841 add_inf_child_target.
8842 * bfd-target.c (target_bfd_target_info): New.
8843 (target_bfd) <shortname, longname, doc>: Delete.
8844 <info>: New.
8845 * bsd-kvm.c (bsd_kvm_target_info): New.
8846 (bsd_kvm_target) <shortname, longname, doc>: Delete.
8847 <info>: New.
8848 (bsd_kvm_target::open): Rename to ...
8849 (bsd_kvm_target_open): ... this. Adjust.
8850 * bsd-uthread.c (bsd_uthread_target_info): New.
8851 (bsd_uthread_target) <shortname, longname, doc>: Delete.
8852 <info>: New.
8853 * corefile.c (core_file_command): Adjust.
8854 * corelow.c (core_target_info): New.
8855 (core_target) <shortname, longname, doc>: Delete.
8856 <info>: New.
8857 (core_target::open): Rename to ...
8858 (core_target_open): ... this. Adjust.
8859 * ctf.c (ctf_target_info): New.
8860 (ctf_target) <shortname, longname, doc>: Delete.
8861 <info>: New.
8862 (ctf_target::open): Rename to ...
8863 (ctf_target_open): ... this.
8864 (_initialize_ctf): Adjust.
8865 * exec.c (exec_target_info): New.
8866 (exec_target) <shortname, longname, doc>: Delete.
8867 <info>: New.
8868 (exec_target::open): Rename to ...
8869 (exec_target_open): ... this.
8870 * gdbcore.h (core_target_open): Declare.
8871 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
8872 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
8873 add_inf_child_target.
8874 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
8875 add_inf_child_target.
8876 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
8877 add_inf_child_target.
8878 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
8879 add_inf_child_target.
8880 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
8881 add_inf_child_target.
8882 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
8883 add_inf_child_target.
8884 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
8885 add_inf_child_target.
8886 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
8887 add_inf_child_target.
8888 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
8889 add_inf_child_target.
8890 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
8891 add_inf_child_target.
8892 * inf-child.c (inf_child_target_info): New.
8893 (inf_child_target::info): New.
8894 (inf_child_open_target): Remove 'target' parameter. Use
8895 get_native_target instead.
8896 (inf_child_target::open): Delete.
8897 (add_inf_child_target): New.
8898 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
8899 Delete.
8900 <info>: New.
8901 (add_inf_child_target): Declare.
8902 (inf_child_open_target): Declare.
8903 * linux-thread-db.c (thread_db_target_info): New.
8904 (thread_db_target) <shortname, longname, doc>: Delete.
8905 <info>: New.
8906 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
8907 add_inf_child_target.
8908 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
8909 add_inf_child_target.
8910 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
8911 add_inf_child_target.
8912 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
8913 add_inf_child_target.
8914 * make-target-delegates (print_class): Adjust.
8915 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
8916 add_inf_child_target.
8917 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
8918 add_inf_child_target.
8919 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
8920 add_inf_child_target.
8921 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
8922 add_inf_child_target.
8923 * nto-procfs.c (nto_native_target_info): New.
8924 (nto_procfs_target_native) <shortname, longname, doc>:
8925 Delete.
8926 <info>: New.
8927 (nto_procfs_target_info): New.
8928 (nto_procfs_target_procfs) <shortname, longname, doc>:
8929 Delete.
8930 <info>: New.
8931 (init_procfs_targets): Adjust.
8932 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
8933 add_inf_child_target.
8934 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
8935 add_inf_child_target.
8936 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
8937 add_inf_child_target.
8938 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
8939 add_inf_child_target.
8940 * ravenscar-thread.c (ravenscar_target_info): New.
8941 (ravenscar_thread_target) <shortname, longname, doc>:
8942 Delete.
8943 <info>: New.
8944 * record-btrace.c (record_btrace_target_info):
8945 (record_btrace_target) <shortname, longname, doc>: Delete.
8946 <info>: New.
8947 (record_btrace_target::open): Rename to ...
8948 (record_btrace_target_open): ... this. Adjust.
8949 * record-full.c (record_longname, record_doc): New.
8950 (record_full_base_target) <shortname, longname, doc>: Delete.
8951 <info>: New.
8952 (record_full_target_info): New.
8953 (record_full_target): <shortname>: Delete.
8954 <info>: New.
8955 (record_full_core_open_1, record_full_open_1): Update comments.
8956 (record_full_base_target::open): Rename to ...
8957 (record_full_open): ... this.
8958 (cmd_record_full_restore): Update.
8959 (_initialize_record_full): Update.
8960 * remote-sim.c (remote_sim_target_info): New.
8961 (gdbsim_target) <shortname, longname, doc>: Delete.
8962 <info>: New.
8963 (gdbsim_target::open): Rename to ...
8964 (gdbsim_target_open): ... this.
8965 (_initialize_remote_sim): Adjust.
8966 * remote.c (remote_doc): New.
8967 (remote_target_info): New.
8968 (remote_target) <shortname, longname, doc>: Delete.
8969 <info>: New.
8970 (extended_remote_target_info): New.
8971 (extended_remote_target) <shortname, longname, doc>: Delete.
8972 <info>: New.
8973 (remote_target::open_1): Make static. Adjust.
8974 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
8975 * s390-linux-nat.c (_initialize_s390_nat): Use
8976 add_inf_child_target.
8977 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
8978 add_inf_child_target.
8979 * sol-thread.c (thread_db_target_info): New.
8980 (sol_thread_target) <shortname, longname, doc>: Delete.
8981 <info>: New.
8982 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
8983 add_inf_child_target.
8984 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
8985 add_inf_child_target.
8986 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
8987 add_inf_child_target.
8988 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
8989 add_inf_child_target.
8990 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
8991 add_inf_child_target.
8992 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
8993 add_inf_child_target.
8994 * spu-linux-nat.c (_initialize_spu_nat): Use
8995 add_inf_child_target.
8996 * spu-multiarch.c (spu_multiarch_target_info): New.
8997 (spu_multiarch_target) <shortname, longname, doc>: Delete.
8998 <info>: New.
8999 * target-delegates.c: Regenerate.
9000 * target.c: Include <unordered_map>.
9001 (target_ops_p): Delete.
9002 (DEF_VEC_P(target_ops_p)): Delete.
9003 (target_factories): New.
9004 (test_target_info): New.
9005 (test_target_ops::info): New.
9006 (open_target): Adjust to use target_factories.
9007 (add_target_with_completer): Rename to ...
9008 (add_target): ... this. Change prototype. Register target_info
9009 and open callback in target_factories. Register target_info in
9010 command context instead of target_ops.
9011 (add_target): Delete old implementation.
9012 (add_deprecated_target_alias): Change prototype. Adjust.
9013 (the_native_target): New.
9014 (set_native_target, get_native_target): New.
9015 (find_default_run_target): Use the_native_target.
9016 (find_attach_target, find_run_target): Simplify.
9017 (target_ops::open): Delete.
9018 (dummy_target_info): New.
9019 (dummy_target::shortname, dummy_target::longname)
9020 (dummy_target::doc): Delete.
9021 (dummy_target::info): New.
9022 (debug_target::shortname, debug_target::longname)
9023 (debug_target::doc): Delete.
9024 (debug_target::info): New.
9025 * target.h (struct target_info): New.
9026 (target_ops::~target_ops): Add comment.
9027 (target_ops::info): New.
9028 (target_ops::shortname, target_ops::longname, target_ops::doc): No
9029 longer virtual. Implement in terms of target_info.
9030 (set_native_target, get_native_target): Declare.
9031 (target_open_ftype): New.
9032 (add_target, add_target_with_completer)
9033 (add_deprecated_target_alias): Change prototype.
9034 (test_target) <shortname, longname, doc>: Delete.
9035 <info>: New.
9036 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
9037 add_inf_child_target.
9038 * tracefile-tfile.c (tfile_target_info): New.
9039 (tfile_target) <shortname, longname, doc>: Delete.
9040 <info>: New.
9041 (tfile_target::open): Rename to ...
9042 (tfile_target_open): ... this.
9043 (_initialize_tracefile_tfile): Adjust.
9044 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
9045 add_inf_child_target.
9046 * windows-nat.c (_initialize_windows_nat): Use
9047 add_inf_child_target.
9048 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
9049 add_inf_child_target.
9050
9051 2018-05-02 Pedro Alves <palves@redhat.com>
9052
9053 * linux-nat.h (linux_nat_target) <low_new_thread,
9054 low_delete_thread, low_new_fork, low_forget_process,
9055 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
9056 New virtual methods.
9057 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
9058 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
9059 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
9060 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
9061 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
9062 Delete.
9063 * linux-fork.c (delete_fork): Adjust to call low method.
9064 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
9065 (linux_nat_new_fork, linux_nat_forget_process_hook)
9066 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
9067 (linux_nat_status_is_event):
9068 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
9069 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
9070 to call low method.
9071 (sigtrap_is_event): Rename to ...
9072 (linux_nat_target::low_status_is_event): ... this.
9073 (linux_nat_set_status_is_event): Delete.
9074 (save_stop_reason, linux_nat_wait_1)
9075 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
9076 low methods.
9077 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
9078 (linux_nat_set_new_fork, linux_nat_set_forget_process)
9079 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
9080 (linux_nat_set_prepare_to_resume): Delete.
9081 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
9082 low virtual methods.
9083 * amd64-linux-nat.c: Likewise.
9084 * arm-linux-nat.c: Likewise.
9085 * i386-linux-nat.c: Likewise.
9086 * ia64-linux-nat.c: Likewise.
9087 * mips-linux-nat.c: Likewise.
9088 * ppc-linux-nat.c: Likewise.
9089 * s390-linux-nat.c: Likewise.
9090 * sparc64-linux-nat.c: Likewise.
9091 * x86-linux-nat.c: Likewise.
9092 * x86-linux-nat.h: Include "nat/x86-linux.h".
9093 (x86_linux_nat_target) <low_new_fork, low_forget_process,
9094 low_prepare_to_resume, low_new_thread, low_delete_thread>:
9095 Override methods.
9096
9097 2018-05-02 Pedro Alves <palves@redhat.com>
9098
9099 * target.h (target_ops)
9100 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
9101 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
9102 stopped_by_watchpoint, have_continuable_watchpoint,
9103 stopped_data_address, watchpoint_addr_within_range,
9104 can_accel_watchpoint_condition, can_run, thread_alive,
9105 has_all_memory, has_memory, has_stack, has_registers,
9106 has_execution, can_async_p, is_async_p, supports_non_stop,
9107 always_non_stop_p, can_execute_reverse, supports_multi_process,
9108 supports_enable_disable_tracepoint,
9109 supports_disable_randomization, supports_string_tracing,
9110 supports_evaluation_of_breakpoint_conditions,
9111 can_run_breakpoint_commands, filesystem_is_local,
9112 can_download_tracepoint, get_trace_state_variable_value,
9113 set_trace_notes, get_tib_address, use_agent, can_use_agent,
9114 record_is_replaying, record_will_replay,
9115 augmented_libraries_svr4_read>: Adjust to return bool.
9116 * aarch64-linux-nat.c: All implementations adjusted.
9117 * aix-thread.c: All implementations adjusted.
9118 * arm-linux-nat.c: All implementations adjusted.
9119 * breakpoint.c: All implementations adjusted.
9120 * bsd-kvm.c: All implementations adjusted.
9121 * bsd-uthread.c: All implementations adjusted.
9122 * corelow.c: All implementations adjusted.
9123 * ctf.c: All implementations adjusted.
9124 * darwin-nat.c: All implementations adjusted.
9125 * darwin-nat.h: All implementations adjusted.
9126 * exec.c: All implementations adjusted.
9127 * fbsd-nat.c: All implementations adjusted.
9128 * fbsd-nat.h: All implementations adjusted.
9129 * gnu-nat.c: All implementations adjusted.
9130 * gnu-nat.h: All implementations adjusted.
9131 * go32-nat.c: All implementations adjusted.
9132 * ia64-linux-nat.c: All implementations adjusted.
9133 * inf-child.c: All implementations adjusted.
9134 * inf-child.h: All implementations adjusted.
9135 * inf-ptrace.c: All implementations adjusted.
9136 * inf-ptrace.h: All implementations adjusted.
9137 * linux-nat.c: All implementations adjusted.
9138 * linux-nat.h: All implementations adjusted.
9139 * mips-linux-nat.c: All implementations adjusted.
9140 * nto-procfs.c: All implementations adjusted.
9141 * ppc-linux-nat.c: All implementations adjusted.
9142 * procfs.c: All implementations adjusted.
9143 * ravenscar-thread.c: All implementations adjusted.
9144 * record-btrace.c: All implementations adjusted.
9145 * record-full.c: All implementations adjusted.
9146 * remote-sim.c: All implementations adjusted.
9147 * remote.c: All implementations adjusted.
9148 * s390-linux-nat.c: All implementations adjusted.
9149 * sol-thread.c: All implementations adjusted.
9150 * spu-multiarch.c: All implementations adjusted.
9151 * target-delegates.c: All implementations adjusted.
9152 * target.c: All implementations adjusted.
9153 * target.h: All implementations adjusted.
9154 * tracefile-tfile.c: All implementations adjusted.
9155 * tracefile.c: All implementations adjusted.
9156 * tracefile.h: All implementations adjusted.
9157 * windows-nat.c: All implementations adjusted.
9158 * x86-linux-nat.h: All implementations adjusted.
9159 * x86-nat.h: All implementations adjusted.
9160
9161 2018-05-02 Pedro Alves <palves@redhat.com>
9162
9163 * make-target-delegates (scan_target_h): Don't trim lines here.
9164 Replace sequences of tabs and/or whitespace with a single
9165 whitespace.
9166 (top level, parsing methods): Trim each line before processing it
9167 here.
9168
9169 2018-05-02 Pedro Alves <palves@redhat.com>
9170 John Baldwin <jhb@freebsd.org>
9171
9172 * target.h (enum strata) <debug_stratum>: New.
9173 (struct target_ops) <all delegation methods>: Replace by C++
9174 virtual methods, and drop "to_" prefix. All references updated
9175 throughout.
9176 <to_shortname, to_longname, to_doc, to_data,
9177 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
9178 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
9179 virtual methods. All references updated throughout.
9180 <can_attach, supports_terminal_ours, can_create_inferior,
9181 get_thread_control_capabilities, attach_no_wait>: New
9182 virtual methods.
9183 <insert_breakpoint, remove_breakpoint>: Now
9184 TARGET_DEFAULT_NORETURN methods.
9185 <info_proc>: Now returns bool.
9186 <to_magic>: Delete.
9187 (OPS_MAGIC): Delete.
9188 (current_target): Delete. All references replaced by references
9189 to ...
9190 (target_stack): ... this. New.
9191 (target_shortname, target_longname): Adjust.
9192 (target_can_run): Now a function declaration.
9193 (default_child_has_all_memory, default_child_has_memory)
9194 (default_child_has_stack, default_child_has_registers)
9195 (default_child_has_execution): Remove target_ops parameter.
9196 (complete_target_initialization): Delete.
9197 (memory_breakpoint_target): New template class.
9198 (test_target_ops): Refactor as a C++ class with virtual methods.
9199 * make-target-delegates (NAME_PART): Tighten.
9200 (POINTER_PART, CP_SYMBOL): New.
9201 (SIMPLE_RETURN_PART): Reimplement.
9202 (VEC_RETURN_PART): Expect less.
9203 (RETURN_PART, VIRTUAL_PART): New.
9204 (METHOD): Adjust to C++ virtual methods.
9205 (scan_target_h): Remove reference to C99.
9206 (dname): Output "target_ops::" prefix.
9207 (write_function_header): Adjust to output a C++ class method.
9208 (write_declaration): New.
9209 (write_delegator): Adjust to output a C++ class method.
9210 (tdname): Output "dummy_target::" prefix.
9211 (write_tdefault, write_debugmethod): Adjust to output a C++ class
9212 method.
9213 (tdefault_names, debug_names): Delete.
9214 (return_types, tdefaults, styles, argtypes_array): New.
9215 (top level): All methods are delegators.
9216 (print_class): New.
9217 (top level): Print dummy_target and debug_target classes.
9218 * target-delegates.c: Regenerate.
9219 * target-debug.h (target_debug_print_enum_info_proc_what)
9220 (target_debug_print_thread_control_capabilities)
9221 (target_debug_print_thread_info_p): New.
9222 * target.c (dummy_target): Delete.
9223 (the_dummy_target, the_debug_target): New.
9224 (target_stack): Now extern.
9225 (set_targetdebug): Push/unpush debug target.
9226 (default_child_has_all_memory, default_child_has_memory)
9227 (default_child_has_stack, default_child_has_registers)
9228 (default_child_has_execution): Remove target_ops parameter.
9229 (complete_target_initialization): Delete.
9230 (add_target_with_completer): No longer call
9231 complete_target_initialization.
9232 (target_supports_terminal_ours): Use regular delegation.
9233 (update_current_target): Delete.
9234 (push_target): No longer check magic number. Don't call
9235 update_current_target.
9236 (unpush_target): Don't call update_current_target.
9237 (target_is_pushed): No longer check magic number.
9238 (target_require_runnable): Skip for all stratums over
9239 process_stratum.
9240 (target_ops::info_proc): New.
9241 (target_info_proc): Use find_target_at and
9242 find_default_run_target.
9243 (target_supports_disable_randomization): Use regular delegation.
9244 (target_get_osdata): Use find_target_at.
9245 (target_ops::open, target_ops::close, target_ops::can_attach)
9246 (target_ops::attach, target_ops::can_create_inferior)
9247 (target_ops::create_inferior, target_ops::can_run)
9248 (target_can_run): New.
9249 (default_fileio_target): Use regular delegation.
9250 (target_ops::fileio_open, target_ops::fileio_pwrite)
9251 (target_ops::fileio_pread, target_ops::fileio_fstat)
9252 (target_ops::fileio_close, target_ops::fileio_unlink)
9253 (target_ops::fileio_readlink): New.
9254 (target_fileio_open_1, target_fileio_unlink)
9255 (target_fileio_readlink): Always call the target method. Handle
9256 FILEIO_ENOSYS.
9257 (return_zero, return_zero_has_execution): Delete.
9258 (init_dummy_target): Delete.
9259 (dummy_target::dummy_target, dummy_target::shortname)
9260 (dummy_target::longname, dummy_target::doc)
9261 (debug_target::debug_target, debug_target::shortname)
9262 (debug_target::longname, debug_target::doc): New.
9263 (target_supports_delete_record): Use regular delegation.
9264 (setup_target_debug): Delete.
9265 (maintenance_print_target_stack): Skip debug_stratum.
9266 (initialize_targets): Instantiate the_dummy_target and
9267 the_debug_target.
9268 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
9269 use target_stack.
9270 (target_auxv_search, fprint_target_auxv): Adjust.
9271 (info_auxv_command): Adjust to use target_stack.
9272 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
9273 * exceptions.c (print_flush): Handle a NULL target_stack.
9274 * regcache.c (target_ops_no_register): Refactor as class with
9275 virtual methods.
9276
9277 * exec.c (exec_target): New class.
9278 (exec_ops): Now an exec_target.
9279 (exec_open, exec_close_1, exec_get_section_table)
9280 (exec_xfer_partial, exec_files_info, exec_has_memory)
9281 (exec_make_note_section): Refactor as exec_target methods.
9282 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
9283 Delete.
9284 (exec_target::find_memory_regions): New.
9285 (_initialize_exec): Don't call init_exec_ops.
9286 * gdbcore.h (exec_file_clear): Delete.
9287
9288 * corefile.c (core_target): Delete.
9289 (core_file_command): Adjust.
9290 * corelow.c (core_target): New class.
9291 (the_core_target): New.
9292 (core_close): Remove target_ops parameter.
9293 (core_close_cleanup): Adjust.
9294 (core_target::close): New.
9295 (core_open, core_detach, get_core_registers, core_files_info)
9296 (core_xfer_partial, core_thread_alive, core_read_description)
9297 (core_pid_to_str, core_thread_name, core_has_memory)
9298 (core_has_stack, core_has_registers, core_info_proc): Rework as
9299 core_target methods.
9300 (ignore, core_remove_breakpoint, init_core_ops): Delete.
9301 (_initialize_corelow): Initialize the_core_target.
9302 * gdbcore.h (core_target): Delete.
9303 (the_core_target): New.
9304
9305 * ctf.c: (ctf_target): New class.
9306 (ctf_ops): Now a ctf_target.
9307 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
9308 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
9309 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
9310 methods.
9311 (init_ctf_ops): Delete.
9312 (_initialize_ctf): Don't call it.
9313 * tracefile-tfile.c (tfile_target): New class.
9314 (tfile_ops): Now a tfile_target.
9315 (tfile_open, tfile_close, tfile_files_info)
9316 (tfile_get_tracepoint_status, tfile_trace_find)
9317 (tfile_fetch_registers, tfile_xfer_partial)
9318 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
9319 Refactor as tfile_target methods.
9320 (tfile_xfer_partial_features): Remove target_ops parameter.
9321 (init_tfile_ops): Delete.
9322 (_initialize_tracefile_tfile): Don't call it.
9323 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
9324 (tracefile_has_stack, tracefile_has_registers)
9325 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
9326 tracefile_target methods.
9327 (init_tracefile_ops): Delete.
9328 (tracefile_target::tracefile_target): New.
9329 * tracefile.h: Include "target.h".
9330 (tracefile_target): New class.
9331 (init_tracefile_ops): Delete.
9332
9333 * spu-multiarch.c (spu_multiarch_target): New class.
9334 (spu_ops): Now a spu_multiarch_target.
9335 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
9336 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
9337 (spu_search_memory, spu_mourn_inferior): Refactor as
9338 spu_multiarch_target methods.
9339 (init_spu_ops): Delete.
9340 (_initialize_spu_multiarch): Remove references to init_spu_ops,
9341 complete_target_initialization.
9342
9343 * ravenscar-thread.c (ravenscar_thread_target): New class.
9344 (ravenscar_ops): Now a ravenscar_thread_target.
9345 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
9346 (ravenscar_thread_alive, ravenscar_pid_to_str)
9347 (ravenscar_fetch_registers, ravenscar_store_registers)
9348 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
9349 (ravenscar_stopped_by_hw_breakpoint)
9350 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
9351 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
9352 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
9353 methods.
9354 (init_ravenscar_thread_ops): Delete.
9355 (_initialize_ravenscar): Remove references to
9356 init_ravenscar_thread_ops and complete_target_initialization.
9357
9358 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
9359 (bsd_uthread_target): New class.
9360 (bsd_uthread_ops): Now a bsd_uthread_target.
9361 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
9362 (bsd_uthread_close, bsd_uthread_mourn_inferior)
9363 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
9364 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
9365 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
9366 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
9367 (bsd_uthread_target): Delete function.
9368 (_initialize_bsd_uthread): Remove reference to
9369 complete_target_initialization.
9370
9371 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
9372 (target_bfd): ... this new class.
9373 (target_bfd_xfer_partial, target_bfd_get_section_table)
9374 (target_bfd_close): Refactor as target_bfd methods.
9375 (target_bfd::~target_bfd): New.
9376 (target_bfd_reopen): Adjust.
9377 (target_bfd::close): New.
9378
9379 * record-btrace.c (record_btrace_target): New class.
9380 (record_btrace_ops): Now a record_btrace_target.
9381 (record_btrace_open, record_btrace_stop_recording)
9382 (record_btrace_disconnect, record_btrace_close)
9383 (record_btrace_async, record_btrace_info)
9384 (record_btrace_insn_history, record_btrace_insn_history_range)
9385 (record_btrace_insn_history_from, record_btrace_call_history)
9386 (record_btrace_call_history_range)
9387 (record_btrace_call_history_from, record_btrace_record_method)
9388 (record_btrace_is_replaying, record_btrace_will_replay)
9389 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
9390 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
9391 (record_btrace_store_registers, record_btrace_prepare_to_store)
9392 (record_btrace_to_get_unwinder)
9393 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
9394 (record_btrace_commit_resume, record_btrace_wait)
9395 (record_btrace_stop, record_btrace_can_execute_reverse)
9396 (record_btrace_stopped_by_sw_breakpoint)
9397 (record_btrace_supports_stopped_by_sw_breakpoint)
9398 (record_btrace_stopped_by_hw_breakpoint)
9399 (record_btrace_supports_stopped_by_hw_breakpoint)
9400 (record_btrace_update_thread_list, record_btrace_thread_alive)
9401 (record_btrace_goto_begin, record_btrace_goto_end)
9402 (record_btrace_goto, record_btrace_stop_replaying_all)
9403 (record_btrace_execution_direction)
9404 (record_btrace_prepare_to_generate_core)
9405 (record_btrace_done_generating_core): Refactor as
9406 record_btrace_target methods.
9407 (init_record_btrace_ops): Delete.
9408 (_initialize_record_btrace): Remove reference to
9409 init_record_btrace_ops.
9410 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
9411 the execution_direction global.
9412 (record_full_base_target, record_full_target)
9413 (record_full_core_target): New classes.
9414 (record_full_ops): Now a record_full_target.
9415 (record_full_core_ops): Now a record_full_core_target.
9416 (record_full_target::detach, record_full_target::disconnect)
9417 (record_full_core_target::disconnect)
9418 (record_full_target::mourn_inferior, record_full_target::kill):
9419 New.
9420 (record_full_open, record_full_close, record_full_async): Refactor
9421 as methods of the record_full_base_target class.
9422 (record_full_resume, record_full_commit_resume): Refactor
9423 as methods of the record_full_target class.
9424 (record_full_wait, record_full_stopped_by_watchpoint)
9425 (record_full_stopped_data_address)
9426 (record_full_stopped_by_sw_breakpoint)
9427 (record_full_supports_stopped_by_sw_breakpoint)
9428 (record_full_stopped_by_hw_breakpoint)
9429 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
9430 methods of the record_full_base_target class.
9431 (record_full_store_registers, record_full_xfer_partial)
9432 (record_full_insert_breakpoint, record_full_remove_breakpoint):
9433 Refactor as methods of the record_full_target class.
9434 (record_full_can_execute_reverse, record_full_get_bookmark)
9435 (record_full_goto_bookmark, record_full_execution_direction)
9436 (record_full_record_method, record_full_info, record_full_delete)
9437 (record_full_is_replaying, record_full_will_replay)
9438 (record_full_goto_begin, record_full_goto_end, record_full_goto)
9439 (record_full_stop_replaying): Refactor as methods of the
9440 record_full_base_target class.
9441 (record_full_core_resume, record_full_core_kill)
9442 (record_full_core_fetch_registers)
9443 (record_full_core_prepare_to_store)
9444 (record_full_core_store_registers, record_full_core_xfer_partial)
9445 (record_full_core_insert_breakpoint)
9446 (record_full_core_remove_breakpoint)
9447 (record_full_core_has_execution): Refactor
9448 as methods of the record_full_core_target class.
9449 (record_full_base_target::supports_delete_record): New.
9450 (init_record_full_ops): Delete.
9451 (init_record_full_core_ops): Delete.
9452 (record_full_save): Refactor as method of the
9453 record_full_base_target class.
9454 (_initialize_record_full): Remove references to
9455 init_record_full_ops and init_record_full_core_ops.
9456
9457 * remote.c (remote_target, extended_remote_target): New classes.
9458 (remote_ops): Now a remote_target.
9459 (extended_remote_ops): Now an extended_remote_target.
9460 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
9461 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
9462 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
9463 (remote_pass_signals, remote_set_syscall_catchpoint)
9464 (remote_program_signals, )
9465 (remote_thread_always_alive): Remove target_ops parameter.
9466 (remote_thread_alive, remote_thread_name)
9467 (remote_update_thread_list, remote_threads_extra_info)
9468 (remote_static_tracepoint_marker_at)
9469 (remote_static_tracepoint_markers_by_strid)
9470 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
9471 (remote_open): Refactor as methods of remote_target.
9472 (extended_remote_open, extended_remote_detach)
9473 (extended_remote_attach, extended_remote_post_attach):
9474 (extended_remote_supports_disable_randomization)
9475 (extended_remote_create_inferior): : Refactor as method of
9476 extended_remote_target.
9477 (remote_set_permissions, remote_open_1, remote_detach)
9478 (remote_follow_fork, remote_follow_exec, remote_disconnect)
9479 (remote_resume, remote_commit_resume, remote_stop)
9480 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
9481 (remote_terminal_ours, remote_wait, remote_fetch_registers)
9482 (remote_prepare_to_store, remote_store_registers)
9483 (remote_flash_erase, remote_flash_done, remote_files_info)
9484 (remote_kill, remote_mourn, remote_insert_breakpoint)
9485 (remote_remove_breakpoint, remote_insert_watchpoint)
9486 (remote_watchpoint_addr_within_range)
9487 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
9488 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
9489 (remote_supports_stopped_by_sw_breakpoint)
9490 (remote_stopped_by_hw_breakpoint)
9491 (remote_supports_stopped_by_hw_breakpoint)
9492 (remote_stopped_by_watchpoint, remote_stopped_data_address)
9493 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
9494 (remote_verify_memory): Refactor as methods of remote_target.
9495 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
9496 parameter.
9497 (remote_xfer_partial, remote_get_memory_xfer_limit)
9498 (remote_search_memory, remote_rcmd, remote_memory_map)
9499 (remote_pid_to_str, remote_get_thread_local_address)
9500 (remote_get_tib_address, remote_read_description): Refactor as
9501 methods of remote_target.
9502 (remote_target::fileio_open, remote_target::fileio_pwrite)
9503 (remote_target::fileio_pread, remote_target::fileio_close): New.
9504 (remote_hostio_readlink, remote_hostio_fstat)
9505 (remote_filesystem_is_local, remote_can_execute_reverse)
9506 (remote_supports_non_stop, remote_supports_disable_randomization)
9507 (remote_supports_multi_process, remote_supports_cond_breakpoints)
9508 (remote_supports_enable_disable_tracepoint)
9509 (remote_supports_string_tracing)
9510 (remote_can_run_breakpoint_commands, remote_trace_init)
9511 (remote_download_tracepoint, remote_can_download_tracepoint)
9512 (remote_download_trace_state_variable, remote_enable_tracepoint)
9513 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
9514 (remote_trace_start, remote_get_trace_status)
9515 (remote_get_tracepoint_status, remote_trace_stop)
9516 (remote_trace_find, remote_get_trace_state_variable_value)
9517 (remote_save_trace_data, remote_get_raw_trace_data)
9518 (remote_set_disconnected_tracing, remote_core_of_thread)
9519 (remote_set_circular_trace_buffer, remote_traceframe_info)
9520 (remote_get_min_fast_tracepoint_insn_len)
9521 (remote_set_trace_buffer_size, remote_set_trace_notes)
9522 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
9523 (remote_disable_btrace, remote_teardown_btrace)
9524 (remote_read_btrace, remote_btrace_conf)
9525 (remote_augmented_libraries_svr4_read, remote_load)
9526 (remote_pid_to_exec_file, remote_can_do_single_step)
9527 (remote_execution_direction, remote_thread_handle_to_thread_info):
9528 Refactor as methods of remote_target.
9529 (init_remote_ops, init_extended_remote_ops): Delete.
9530 (remote_can_async_p, remote_is_async_p, remote_async)
9531 (remote_thread_events, remote_upload_tracepoints)
9532 (remote_upload_trace_state_variables): Refactor as methods of
9533 remote_target.
9534 (_initialize_remote): Remove references to init_remote_ops and
9535 init_extended_remote_ops.
9536
9537 * remote-sim.c (gdbsim_target): New class.
9538 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
9539 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
9540 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
9541 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
9542 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
9543 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
9544 Refactor as methods of gdbsim_target.
9545 (gdbsim_ops): Now a gdbsim_target.
9546 (init_gdbsim_ops): Delete.
9547 (gdbsim_cntrl_c): Adjust.
9548 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
9549
9550 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
9551 (the_amd64_linux_nat_target): New.
9552 (amd64_linux_fetch_inferior_registers)
9553 (amd64_linux_store_inferior_registers): Refactor as methods of
9554 amd64_linux_nat_target.
9555 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
9556 * i386-linux-nat.c: Don't include "linux-nat.h".
9557 (i386_linux_nat_target): New class.
9558 (the_i386_linux_nat_target): New.
9559 (i386_linux_fetch_inferior_registers)
9560 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
9561 as methods of i386_linux_nat_target.
9562 (_initialize_i386_linux_nat): Adjust. Set linux_target.
9563 * inf-child.c (inf_child_ops): Delete.
9564 (inf_child_fetch_inferior_registers)
9565 (inf_child_store_inferior_registers): Delete.
9566 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
9567 methods of inf_child_target.
9568 (inf_child_target::supports_terminal_ours)
9569 (inf_child_target::terminal_init)
9570 (inf_child_target::terminal_inferior)
9571 (inf_child_target::terminal_ours_for_output)
9572 (inf_child_target::terminal_ours, inf_child_target::interrupt)
9573 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
9574 New.
9575 (inf_child_open, inf_child_disconnect, inf_child_close)
9576 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
9577 (inf_child_post_startup_inferior, inf_child_can_run)
9578 (inf_child_pid_to_exec_file): Refactor as methods of
9579 inf_child_target.
9580 (inf_child_follow_fork): Delete.
9581 (inf_child_target::can_create_inferior)
9582 (inf_child_target::can_attach): New.
9583 (inf_child_target::has_all_memory, inf_child_target::has_memory)
9584 (inf_child_target::has_stack, inf_child_target::has_registers)
9585 (inf_child_target::has_execution): New.
9586 (inf_child_fileio_open, inf_child_fileio_pwrite)
9587 (inf_child_fileio_pread, inf_child_fileio_fstat)
9588 (inf_child_fileio_close, inf_child_fileio_unlink)
9589 (inf_child_fileio_readlink, inf_child_use_agent)
9590 (inf_child_can_use_agent): Refactor as methods of
9591 inf_child_target.
9592 (return_zero, inf_child_target): Delete.
9593 (inf_child_target::inf_child_target): New.
9594 * inf-child.h: Include "target.h".
9595 (inf_child_target): Delete function prototype.
9596 (inf_child_target): New class.
9597 (inf_child_open_target, inf_child_mourn_inferior)
9598 (inf_child_maybe_unpush_target): Delete.
9599 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
9600 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
9601 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
9602 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
9603 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
9604 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
9605 (inf_ptrace_wait, inf_ptrace_xfer_partial)
9606 (inf_ptrace_thread_alive, inf_ptrace_files_info)
9607 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
9608 methods of inf_ptrace_target.
9609 (inf_ptrace_target): Delete function.
9610 * inf-ptrace.h: Include "inf-child.h".
9611 (inf_ptrace_target): Delete function declaration.
9612 (inf_ptrace_target): New class.
9613 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
9614 * linux-nat.c (linux_target): New.
9615 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
9616 (linux_nat_target::~linux_nat_target): New.
9617 (linux_child_post_attach, linux_child_post_startup_inferior)
9618 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
9619 (linux_child_remove_fork_catchpoint)
9620 (linux_child_insert_vfork_catchpoint)
9621 (linux_child_remove_vfork_catchpoint)
9622 (linux_child_insert_exec_catchpoint)
9623 (linux_child_remove_exec_catchpoint)
9624 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
9625 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
9626 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
9627 (linux_nat_stopped_data_address)
9628 (linux_nat_stopped_by_sw_breakpoint)
9629 (linux_nat_supports_stopped_by_sw_breakpoint)
9630 (linux_nat_stopped_by_hw_breakpoint)
9631 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
9632 (linux_nat_kill, linux_nat_mourn_inferior)
9633 (linux_nat_xfer_partial, linux_nat_thread_alive)
9634 (linux_nat_update_thread_list, linux_nat_pid_to_str)
9635 (linux_nat_thread_name, linux_child_pid_to_exec_file)
9636 (linux_child_static_tracepoint_markers_by_strid)
9637 (linux_nat_is_async_p, linux_nat_can_async_p)
9638 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
9639 (linux_nat_supports_multi_process)
9640 (linux_nat_supports_disable_randomization, linux_nat_async)
9641 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
9642 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
9643 (linux_nat_fileio_open, linux_nat_fileio_readlink)
9644 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
9645 methods of linux_nat_target.
9646 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
9647 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
9648 parameter.
9649 (check_stopped_by_watchpoint): Adjust.
9650 (linux_xfer_partial): Delete.
9651 (linux_target_install_ops, linux_target, linux_nat_add_target):
9652 Delete.
9653 (linux_nat_target::linux_nat_target): New.
9654 * linux-nat.h: Include "inf-ptrace.h".
9655 (linux_nat_target): New.
9656 (linux_target, linux_target_install_ops, linux_nat_add_target):
9657 Delete function declarations.
9658 (linux_target): Declare global.
9659 * linux-thread-db.c (thread_db_target): New.
9660 (thread_db_target::thread_db_target): New.
9661 (thread_db_ops): Delete.
9662 (the_thread_db_target): New.
9663 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
9664 (thread_db_update_thread_list, thread_db_pid_to_str)
9665 (thread_db_extra_thread_info)
9666 (thread_db_thread_handle_to_thread_info)
9667 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
9668 (thread_db_resume): Refactor as methods of thread_db_target.
9669 (init_thread_db_ops): Delete.
9670 (_initialize_thread_db): Remove reference to init_thread_db_ops.
9671 * x86-linux-nat.c: Don't include "linux-nat.h".
9672 (super_post_startup_inferior): Delete.
9673 (x86_linux_nat_target::~x86_linux_nat_target): New.
9674 (x86_linux_child_post_startup_inferior)
9675 (x86_linux_read_description, x86_linux_enable_btrace)
9676 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
9677 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
9678 methods of x86_linux_nat_target.
9679 (x86_linux_create_target): Delete. Bits folded ...
9680 (x86_linux_add_target): ... here. Now takes a linux_nat_target
9681 pointer.
9682 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
9683 (x86_linux_nat_target): New class.
9684 (x86_linux_create_target): Delete.
9685 (x86_linux_add_target): Now takes a linux_nat_target pointer.
9686 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
9687 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
9688 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
9689 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
9690 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
9691 make extern.
9692 (x86_use_watchpoints): Delete.
9693 * x86-nat.h: Include "breakpoint.h" and "target.h".
9694 (x86_use_watchpoints): Delete.
9695 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
9696 (x86_stopped_by_watchpoint, x86_stopped_data_address)
9697 (x86_insert_watchpoint, x86_remove_watchpoint)
9698 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
9699 (x86_stopped_by_hw_breakpoint): New declarations.
9700 (x86_nat_target): New template class.
9701
9702 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
9703 (the_ppc_linux_nat_target): New.
9704 (ppc_linux_fetch_inferior_registers)
9705 (ppc_linux_can_use_hw_breakpoint)
9706 (ppc_linux_region_ok_for_hw_watchpoint)
9707 (ppc_linux_ranged_break_num_registers)
9708 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
9709 (ppc_linux_insert_mask_watchpoint)
9710 (ppc_linux_remove_mask_watchpoint)
9711 (ppc_linux_can_accel_watchpoint_condition)
9712 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
9713 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
9714 (ppc_linux_watchpoint_addr_within_range)
9715 (ppc_linux_masked_watch_num_registers)
9716 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
9717 (ppc_linux_read_description): Refactor as methods of
9718 ppc_linux_nat_target.
9719 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
9720
9721 * procfs.c (procfs_xfer_partial): Delete forward declaration.
9722 (procfs_target): New class.
9723 (the_procfs_target): New.
9724 (procfs_target): Delete function.
9725 (procfs_auxv_parse, procfs_attach, procfs_detach)
9726 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
9727 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
9728 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
9729 (procfs_create_inferior, procfs_update_thread_list)
9730 (procfs_thread_alive, procfs_pid_to_str)
9731 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
9732 (procfs_stopped_data_address, procfs_insert_watchpoint)
9733 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
9734 (proc_find_memory_regions, procfs_info_proc)
9735 (procfs_make_note_section): Refactor as methods of procfs_target.
9736 (_initialize_procfs): Adjust.
9737 * sol-thread.c (sol_thread_target): New class.
9738 (sol_thread_ops): Now a sol_thread_target.
9739 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
9740 (sol_thread_fetch_registers, sol_thread_store_registers)
9741 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
9742 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
9743 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
9744 (init_sol_thread_ops): Delete.
9745 (_initialize_sol_thread): Adjust. Remove references to
9746 init_sol_thread_ops and complete_target_initialization.
9747
9748 * windows-nat.c (windows_nat_target): New class.
9749 (windows_fetch_inferior_registers)
9750 (windows_store_inferior_registers, windows_resume, windows_wait)
9751 (windows_attach, windows_detach, windows_pid_to_exec_file)
9752 (windows_files_info, windows_create_inferior)
9753 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
9754 (windows_close, windows_pid_to_str, windows_xfer_partial)
9755 (windows_get_tib_address, windows_get_ada_task_ptid)
9756 (windows_thread_name, windows_thread_alive): Refactor as
9757 windows_nat_target methods.
9758 (do_initial_windows_stuff): Adjust.
9759 (windows_target): Delete function.
9760 (_initialize_windows_nat): Adjust.
9761
9762 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
9763 (darwin_mourn_inferior, darwin_kill_inferior)
9764 (darwin_create_inferior, darwin_attach, darwin_detach)
9765 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
9766 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
9767 (darwin_supports_multi_process): Refactor as darwin_nat_target
9768 methods.
9769 (darwin_resume_to, darwin_files_info): Delete.
9770 (_initialize_darwin_inferior): Rename to ...
9771 (_initialize_darwin_nat): ... this. Adjust to C++ification.
9772 * darwin-nat.h: Include "inf-child.h".
9773 (darwin_nat_target): New class.
9774 (darwin_complete_target): Delete.
9775 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
9776 (darwin_target): New.
9777 (i386_darwin_fetch_inferior_registers)
9778 (i386_darwin_store_inferior_registers): Refactor as methods of
9779 darwin_nat_target.
9780 (darwin_complete_target): Delete, with ...
9781 (_initialize_i386_darwin_nat): ... bits factored out here.
9782
9783 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
9784 (the_alpha_linux_nat_target): New.
9785 (alpha_linux_register_u_offset): Refactor as
9786 alpha_linux_nat_target method.
9787 (_initialize_alpha_linux_nat): Adjust.
9788 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
9789 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
9790 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
9791 methods of linux_nat_trad_target.
9792 (linux_trad_target): Delete.
9793 * linux-nat-trad.h (linux_trad_target): Delete function.
9794 (linux_nat_trad_target): New class.
9795 * mips-linux-nat.c (mips_linux_nat_target): New class.
9796 (super_fetch_registers, super_store_registers, super_close):
9797 Delete.
9798 (the_mips_linux_nat_target): New.
9799 (mips64_linux_regsets_fetch_registers)
9800 (mips64_linux_regsets_store_registers)
9801 (mips64_linux_fetch_registers, mips64_linux_store_registers)
9802 (mips_linux_register_u_offset, mips_linux_read_description)
9803 (mips_linux_can_use_hw_breakpoint)
9804 (mips_linux_stopped_by_watchpoint)
9805 (mips_linux_stopped_data_address)
9806 (mips_linux_region_ok_for_hw_watchpoint)
9807 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
9808 (mips_linux_close): Refactor as methods of mips_linux_nat.
9809 (_initialize_mips_linux_nat): Adjust to C++ification.
9810
9811 * aix-thread.c (aix_thread_target): New class.
9812 (aix_thread_ops): Now an aix_thread_target.
9813 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
9814 (aix_thread_fetch_registers, aix_thread_store_registers)
9815 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
9816 (aix_thread_thread_alive, aix_thread_pid_to_str)
9817 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
9818 Refactor as methods of aix_thread_target.
9819 (init_aix_thread_ops): Delete.
9820 (_initialize_aix_thread): Remove references to init_aix_thread_ops
9821 and complete_target_initialization.
9822 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
9823 (rs6000_nat_target): New class.
9824 (the_rs6000_nat_target): New.
9825 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
9826 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
9827 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
9828 (super_create_inferior): Delete.
9829 (_initialize_rs6000_nat): Adjust to C++ification.
9830
9831 * arm-linux-nat.c (arm_linux_nat_target): New class.
9832 (the_arm_linux_nat_target): New.
9833 (arm_linux_fetch_inferior_registers)
9834 (arm_linux_store_inferior_registers, arm_linux_read_description)
9835 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
9836 (arm_linux_remove_hw_breakpoint)
9837 (arm_linux_region_ok_for_hw_watchpoint)
9838 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
9839 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
9840 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
9841 arm_linux_nat_target.
9842 (_initialize_arm_linux_nat): Adjust to C++ification.
9843
9844 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
9845 (the_aarch64_linux_nat_target): New.
9846 (aarch64_linux_fetch_inferior_registers)
9847 (aarch64_linux_store_inferior_registers)
9848 (aarch64_linux_child_post_startup_inferior)
9849 (aarch64_linux_read_description)
9850 (aarch64_linux_can_use_hw_breakpoint)
9851 (aarch64_linux_insert_hw_breakpoint)
9852 (aarch64_linux_remove_hw_breakpoint)
9853 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
9854 (aarch64_linux_region_ok_for_hw_watchpoint)
9855 (aarch64_linux_stopped_data_address)
9856 (aarch64_linux_stopped_by_watchpoint)
9857 (aarch64_linux_watchpoint_addr_within_range)
9858 (aarch64_linux_can_do_single_step): Refactor as methods of
9859 aarch64_linux_nat_target.
9860 (super_post_startup_inferior): Delete.
9861 (_initialize_aarch64_linux_nat): Adjust to C++ification.
9862
9863 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
9864 (the_hppa_linux_nat_target): New.
9865 (hppa_linux_fetch_inferior_registers)
9866 (hppa_linux_store_inferior_registers): Refactor as methods of
9867 hppa_linux_nat_target.
9868 (_initialize_hppa_linux_nat): Adjust to C++ification.
9869
9870 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
9871 (the_ia64_linux_nat_target): New.
9872 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
9873 (ia64_linux_stopped_data_address)
9874 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
9875 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
9876 ia64_linux_nat_target methods.
9877 (super_xfer_partial): Delete.
9878 (_initialize_ia64_linux_nat): Adjust to C++ification.
9879
9880 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
9881 (the_m32r_linux_nat_target): New.
9882 (m32r_linux_fetch_inferior_registers)
9883 (m32r_linux_store_inferior_registers): Refactor as
9884 m32r_linux_nat_target methods.
9885 (_initialize_m32r_linux_nat): Adjust to C++ification.
9886
9887 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
9888 (the_m68k_linux_nat_target): New.
9889 (m68k_linux_fetch_inferior_registers)
9890 (m68k_linux_store_inferior_registers): Refactor as
9891 m68k_linux_nat_target methods.
9892 (_initialize_m68k_linux_nat): Adjust to C++ification.
9893
9894 * s390-linux-nat.c (s390_linux_nat_target): New class.
9895 (the_s390_linux_nat_target): New.
9896 (s390_linux_fetch_inferior_registers)
9897 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
9898 (s390_insert_watchpoint, s390_remove_watchpoint)
9899 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
9900 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
9901 (s390_auxv_parse, s390_read_description): Refactor as methods of
9902 s390_linux_nat_target.
9903 (_initialize_s390_nat): Adjust to C++ification.
9904
9905 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
9906 (the_sparc_linux_nat_target): New.
9907 (_initialize_sparc_linux_nat): Adjust to C++ification.
9908 * sparc-nat.c (sparc_fetch_inferior_registers)
9909 (sparc_store_inferior_registers): Remove target_ops parameter.
9910 * sparc-nat.h (sparc_fetch_inferior_registers)
9911 (sparc_store_inferior_registers): Remove target_ops parameter.
9912 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
9913 (the_sparc64_linux_nat_target): New.
9914 (_initialize_sparc64_linux_nat): Adjust to C++ification.
9915
9916 * spu-linux-nat.c (spu_linux_nat_target): New class.
9917 (the_spu_linux_nat_target): New.
9918 (spu_child_post_startup_inferior, spu_child_post_attach)
9919 (spu_child_wait, spu_fetch_inferior_registers)
9920 (spu_store_inferior_registers, spu_xfer_partial)
9921 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
9922 methods.
9923 (_initialize_spu_nat): Adjust to C++ification.
9924
9925 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
9926 (the_tilegx_linux_nat_target): New.
9927 (fetch_inferior_registers, store_inferior_registers):
9928 Refactor as methods.
9929 (_initialize_tile_linux_nat): Adjust to C++ification.
9930
9931 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
9932 (the_xtensa_linux_nat_target): New.
9933 (xtensa_linux_fetch_inferior_registers)
9934 (xtensa_linux_store_inferior_registers): Refactor as
9935 xtensa_linux_nat_target methods.
9936 (_initialize_xtensa_linux_nat): Adjust to C++ification.
9937
9938 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
9939 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
9940 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
9941 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
9942 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
9943 (fbsd_stopped_by_sw_breakpoint)
9944 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
9945 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
9946 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
9947 (fbsd_post_startup_inferior, fbsd_post_attach)
9948 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
9949 (fbsd_set_syscall_catchpoint)
9950 (super_xfer_partial, super_resume, super_wait)
9951 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
9952 (fbsd_handle_debug_trap): Remove target_ops parameter.
9953 (fbsd_nat_add_target): Delete.
9954 * fbsd-nat.h: Include "inf-ptrace.h".
9955 (fbsd_nat_add_target): Delete.
9956 (USE_SIGTRAP_SIGINFO): Define.
9957 (fbsd_nat_target): New class.
9958
9959 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
9960 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
9961 (amd64bsd_target): Delete.
9962 * amd64-bsd-nat.h: New file.
9963 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
9964 "x86-bsd-nat.h".
9965 (amd64_fbsd_nat_target): New class.
9966 (the_amd64_fbsd_nat_target): New.
9967 (amd64fbsd_read_description): Refactor as method of
9968 amd64_fbsd_nat_target.
9969 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9970 (_initialize_amd64fbsd_nat): Adjust to C++ification.
9971 * amd64-nat.h (amd64bsd_target): Delete function declaration.
9972 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
9973 (i386bsd_store_inferior_registers): Remove target_ops parameter.
9974 (i386bsd_target): Delete.
9975 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
9976 (i386bsd_fetch_inferior_registers)
9977 (i386bsd_store_inferior_registers): Declare.
9978 (i386_bsd_nat_target): New class.
9979 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
9980 (the_i386_fbsd_nat_target): New.
9981 (i386fbsd_resume, i386fbsd_read_description): Refactor as
9982 i386_fbsd_nat_target methods.
9983 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
9984 (_initialize_i386fbsd_nat): Adjust to C++ification.
9985 * x86-bsd-nat.c (super_mourn_inferior): Delete.
9986 (x86bsd_mourn_inferior, x86bsd_target): Delete.
9987 (_initialize_x86_bsd_nat): Adjust to C++ification.
9988 * x86-bsd-nat.h: Include "x86-nat.h".
9989 (x86bsd_target): Delete declaration.
9990 (x86bsd_nat_target): New class.
9991
9992 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
9993 (the_aarch64_fbsd_nat_target): New.
9994 (aarch64_fbsd_fetch_inferior_registers)
9995 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
9996 aarch64_fbsd_nat_target.
9997 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
9998 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
9999 (the_alpha_bsd_nat_target): New.
10000 (alphabsd_fetch_inferior_registers)
10001 (alphabsd_store_inferior_registers): Refactor as
10002 alpha_bsd_nat_target methods.
10003 (_initialize_alphabsd_nat): Refactor as methods of
10004 alpha_bsd_nat_target.
10005 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
10006 (the_amd64_nbsd_nat_target): New.
10007 (_initialize_amd64nbsd_nat): Adjust to C++ification.
10008 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
10009 (the_amd64_obsd_nat_target): New.
10010 (_initialize_amd64obsd_nat): Adjust to C++ification.
10011 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
10012 (the_arm_fbsd_nat_target): New.
10013 (arm_fbsd_fetch_inferior_registers)
10014 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
10015 (_initialize_arm_fbsd_nat): Refactor as methods of
10016 arm_fbsd_nat_target.
10017 (_initialize_arm_fbsd_nat): Adjust to C++ification.
10018 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
10019 (the_arm_netbsd_nat_target): New.
10020 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
10021 arm_netbsd_nat_target.
10022 (_initialize_arm_netbsd_nat): Adjust to C++ification.
10023 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
10024 (the_hppa_nbsd_nat_target): New.
10025 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
10026 hppa_nbsd_nat_target methods.
10027 (_initialize_hppanbsd_nat): Adjust to C++ification.
10028 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
10029 (the_hppa_obsd_nat_target): New.
10030 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
10031 methods of hppa_obsd_nat_target.
10032 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
10033 add_target.
10034 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
10035 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
10036 add_target.
10037 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
10038 (_initialize_i386obsd_nat): Use add_target.
10039 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
10040 (the_m68k_bsd_nat_target): New.
10041 (m68kbsd_fetch_inferior_registers)
10042 (m68kbsd_store_inferior_registers): Refactor as methods of
10043 m68k_bsd_nat_target.
10044 (_initialize_m68kbsd_nat): Adjust to C++ification.
10045 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
10046 (the_mips_fbsd_nat_target): New.
10047 (mips_fbsd_fetch_inferior_registers)
10048 (mips_fbsd_store_inferior_registers): Refactor as methods of
10049 mips_fbsd_nat_target.
10050 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
10051 add_target.
10052 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
10053 (the_mips_nbsd_nat_target): New.
10054 (mipsnbsd_fetch_inferior_registers)
10055 (mipsnbsd_store_inferior_registers): Refactor as methods of
10056 mips_nbsd_nat_target.
10057 (_initialize_mipsnbsd_nat): Adjust to C++ification.
10058 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
10059 (the_mips64_obsd_nat_target): New.
10060 (mips64obsd_fetch_inferior_registers)
10061 (mips64obsd_store_inferior_registers): Refactor as methods of
10062 mips64_obsd_nat_target.
10063 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
10064 add_target.
10065 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
10066 nbsd_nat_target.
10067 * nbsd-nat.h: Include "inf-ptrace.h".
10068 (nbsd_nat_target): New class.
10069 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
10070 (obsd_wait): Refactor as methods of obsd_nat_target.
10071 (obsd_add_target): Delete.
10072 * obsd-nat.h: Include "inf-ptrace.h".
10073 (obsd_nat_target): New class.
10074 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
10075 (the_ppc_fbsd_nat_target): New.
10076 (ppcfbsd_fetch_inferior_registers)
10077 (ppcfbsd_store_inferior_registers): Refactor as methods of
10078 ppc_fbsd_nat_target.
10079 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
10080 add_target.
10081 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
10082 (the_ppc_nbsd_nat_target): New.
10083 (ppcnbsd_fetch_inferior_registers)
10084 (ppcnbsd_store_inferior_registers): Refactor as methods of
10085 ppc_nbsd_nat_target.
10086 (_initialize_ppcnbsd_nat): Adjust to C++ification.
10087 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
10088 (the_ppc_obsd_nat_target): New.
10089 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
10090 methods of ppc_obsd_nat_target.
10091 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
10092 add_target.
10093 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
10094 (the_sh_nbsd_nat_target): New.
10095 (shnbsd_fetch_inferior_registers)
10096 (shnbsd_store_inferior_registers): Refactor as methods of
10097 sh_nbsd_nat_target.
10098 (_initialize_shnbsd_nat): Adjust to C++ification.
10099 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
10100 (inf_ptrace_xfer_partial): Delete.
10101 (sparc_xfer_partial, sparc_target): Delete.
10102 * sparc-nat.h (sparc_fetch_inferior_registers)
10103 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
10104 (sparc_target): Delete function declaration.
10105 (sparc_target): New template class.
10106 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
10107 (_initialize_sparcnbsd_nat): Adjust to C++ification.
10108 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
10109 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
10110 add_target.
10111 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
10112 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
10113 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
10114 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
10115 add_target.
10116 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
10117 (the_vax_bsd_nat_target): New.
10118 (vaxbsd_fetch_inferior_registers)
10119 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
10120 methods.
10121 (_initialize_vaxbsd_nat): Adjust to C++ification.
10122
10123 * bsd-kvm.c (bsd_kvm_target): New class.
10124 (bsd_kvm_ops): Now a bsd_kvm_target.
10125 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
10126 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
10127 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
10128 bsd_kvm_target.
10129 (bsd_kvm_return_one): Delete.
10130 (bsd_kvm_add_target): Adjust to C++ification.
10131
10132 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
10133 (nto_procfs_target_procfs): New classes.
10134 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
10135 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
10136 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
10137 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
10138 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
10139 (procfs_remove_hw_breakpoint, procfs_resume)
10140 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
10141 (procfs_kill_inferior, procfs_store_registers)
10142 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
10143 as methods of nto_procfs_target.
10144 (nto_procfs_ops): Now an nto_procfs_target_procfs.
10145 (nto_native_ops): Delete.
10146 (procfs_open, procfs_native_open): Delete.
10147 (nto_native_ops): Now an nto_procfs_target_native.
10148 (init_procfs_targets): Adjust to C++ification.
10149 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
10150 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
10151 Refactor as methods of nto_procfs_target.
10152
10153 * go32-nat.c (go32_nat_target): New class.
10154 (the_go32_nat_target): New.
10155 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
10156 (go32_store_registers, go32_xfer_partial, go32_files_info)
10157 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
10158 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
10159 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
10160 (go32_pid_to_str): Refactor as methods of go32_nat_target.
10161 (go32_target): Delete.
10162 (_initialize_go32_nat): Adjust to C++ification.
10163
10164 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
10165 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
10166 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
10167 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
10168 gnu_nat_target.
10169 (gnu_target): Delete.
10170 * gnu-nat.h (gnu_target): Delete.
10171 (gnu_nat_target): New class.
10172 * i386-gnu-nat.c (gnu_base_target): New.
10173 (i386_gnu_nat_target): New class.
10174 (the_i386_gnu_nat_target): New.
10175 (_initialize_i386gnu_nat): Adjust to C++ification.
10176
10177 2018-05-02 Pedro Alves <palves@redhat.com>
10178
10179 * bfd-target.c (target_bfd_xclose): Rename to ...
10180 (target_bfd_close): ... this.
10181 (target_bfd_reopen): Adjust.
10182 * target.c (target_close): Remove references to to_xclose.
10183 * target.h (target_ops::to_xclose): Delete.
10184 (target_ops::to_close): Update comments.
10185
10186 2018-05-02 Pedro Alves <palves@redhat.com>
10187
10188 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
10189 "linux-nat.h".
10190 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
10191 * inf-ptrace.c (inf_ptrace_register_u_offset)
10192 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
10193 (inf_ptrace_store_register, inf_ptrace_store_registers)
10194 (inf_ptrace_trad_target): Move to ...
10195 * linux-nat-trad.c: ... this new file.
10196 * linux-nat-trad.h: New file.
10197 * linux-nat.c (linux_target_install_ops): Make extern.
10198 (linux_trad_target): Delete.
10199 * linux-nat.h (linux_trad_target): Delete declaration.
10200 (linux_target_install_ops): Declare.
10201 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
10202 "linux-nat.h".
10203
10204 2018-05-02 Pedro Alves <palves@redhat.com>
10205
10206 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
10207 procfs_target/add_target here.
10208 * procfs.c (procfs_target): Make static.
10209 (_initialize_procfs): Call add_target here.
10210 * procfs.h (struct target_ops): Remove forward declaration.
10211 (procfs_target): Remove declaration.
10212 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
10213
10214 2018-05-02 Pedro Alves <palves@redhat.com>
10215
10216 * procfs.c (procfs_stopped_by_watchpoint)
10217 (procfs_insert_watchpoint, procfs_remove_watchpoint)
10218 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
10219 Forward declare.
10220 (procfs_use_watchpoints): Delete, move contents...
10221 (procfs_target): ... here.
10222 * procfs.h (procfs_use_watchpoints): Delete declaration.
10223 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
10224 procfs_use_watchpoints.
10225 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
10226 procfs_use_watchpoints.
10227
10228 2018-05-02 Tom Tromey <tom@tromey.com>
10229
10230 PR python/20084:
10231 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
10232 and var_zuinteger_unlimited.
10233 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
10234 and PARAM_ZUINTEGER_UNLIMITED.
10235 (set_parameter_value): Handle var_zuinteger and
10236 var_zuinteger_unlimited.
10237 (add_setshow_generic): Likewise.
10238 (parmpy_init): Likewise.
10239
10240 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
10241
10242 PR rust/23124
10243 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
10244 pointer is not null before dereferencing it.
10245
10246 2018-04-30 Tom Tromey <tom@tromey.com>
10247
10248 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
10249 is_mi_like_p.
10250
10251 2018-04-30 Tom Tromey <tom@tromey.com>
10252
10253 * breakpoint.c (mention): Remove use of is_mi_like_p.
10254 (print_mention_ranged_breakpoint): Likewise.
10255 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
10256 of is_mi_like_p.
10257
10258 2018-04-30 Tom Tromey <tom@tromey.com>
10259
10260 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
10261
10262 2018-04-30 Tom Tromey <tom@tromey.com>
10263
10264 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
10265 (info_spu_event_command): Remove some uses of is_mi_like_p.
10266
10267 2018-04-30 Tom Tromey <tom@tromey.com>
10268
10269 * python/py-framefilter.c (py_print_single_arg)
10270 (enumerate_locals, py_print_args, py_print_frame): Remove some
10271 uses of is_mi_like_p.
10272
10273 2018-04-30 Tom Tromey <tom@tromey.com>
10274
10275 * ui-out.c: Update.
10276 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
10277 * ui-out.h (ui_out::is_mi_like_p): Now const.
10278 (ui_out::do_is_mi_like_p): Now const.
10279 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
10280
10281 2018-04-30 Tom Tromey <tom@tromey.com>
10282
10283 * varobj.c (varobj_set_visualizer): Use new_reference.
10284 * python/python.c (gdbpy_decode_line): Use new_reference.
10285 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
10286 new_reference.
10287
10288 2018-04-30 Tom Tromey <tom@tromey.com>
10289
10290 * varobj.c (install_new_value): Use new_reference.
10291 * value.h (value_incref): Return void. Swap intro comment with
10292 value_decref.
10293 * value.c (set_value_parent): Use new_reference.
10294 (value_incref): Return void. Update intro comment.
10295 (release_value): Use new_reference.
10296 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
10297
10298 2018-04-30 Tom Tromey <tom@tromey.com>
10299
10300 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
10301 * gdb_bfd.h (new_bfd_ref): Remove.
10302 (gdb_bfd_open): Update comment.
10303 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
10304 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
10305 (gdb_bfd_fdopenr): Use new_reference.
10306 * exec.c (exec_file_attach): Use new_reference.
10307
10308 2018-04-30 Tom Tromey <tom@tromey.com>
10309
10310 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
10311 method.
10312
10313 2018-04-30 Tom Tromey <tom@tromey.com>
10314
10315 * jit.c (jit_read_code_entry): Use type_align.
10316 * i386-tdep.c (i386_gdbarch_init): Don't call
10317 set_gdbarch_long_long_align_bit.
10318 * gdbarch.sh: Remove long_long_align_bit.
10319 * gdbarch.c, gdbarch.h: Rebuild.
10320 * arc-tdep.c (arc_type_align): New function.
10321 (arc_gdbarch_init): Use arc_type_align. Don't call
10322 set_gdbarch_long_long_align_bit.
10323
10324 2018-04-30 Tom Tromey <tom@tromey.com>
10325
10326 * rust-lang.c (rust_type_alignment): Remove.
10327 (rust_composite_type): Use type_align.
10328
10329 2018-04-30 Tom Tromey <tom@tromey.com>
10330
10331 * NEWS: Mention Type.align.
10332 * python/py-type.c (typy_get_alignof): New function.
10333 (type_object_getset): Add "alignof".
10334
10335 2018-04-30 Tom Tromey <tom@tromey.com>
10336
10337 PR exp/17095:
10338 * NEWS: Update.
10339 * std-operator.def (UNOP_ALIGNOF): New operator.
10340 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
10341 New.
10342 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
10343 * c-lang.c (c_op_print_tab): Add alignof.
10344 * c-exp.y (ALIGNOF): New token.
10345 (exp): Add "ALIGNOF" production.
10346 (ident_tokens): Add _Alignof and alignof.
10347
10348 2018-04-30 Tom Tromey <tom@tromey.com>
10349
10350 * i386-tdep.c (i386_type_align): New function.
10351 (i386_gdbarch_init): Update.
10352 * gdbarch.sh (type_align): New method.
10353 * gdbarch.c, gdbarch.h: Rebuild.
10354 * arch-utils.h (default_type_align): Declare.
10355 * arch-utils.c (default_type_align): New function.
10356 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
10357 (struct type) <align_log2>: New field.
10358 <instance_flags>: Now a bitfield.
10359 (TYPE_RAW_ALIGN): New macro.
10360 (type_align, type_raw_align, set_type_align): Declare.
10361 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
10362 functions.
10363 * dwarf2read.c (quirk_rust_enum): Set type alignment.
10364 (get_alignment, maybe_set_alignment): New functions.
10365 (read_structure_type, read_enumeration_type, read_array_type)
10366 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
10367 (read_subrange_type, read_base_type): Set type alignment.
10368
10369 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
10370
10371 * dwarf2read.c (read_index_from_section): Use bool.
10372
10373 2018-04-29 Fabian Groffen <grobian@gentoo.org>
10374
10375 PR gdb/22950
10376 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
10377 with #ifdef.
10378
10379 2018-04-29 John Reiser <jreiser@BitWagon.com>
10380
10381 PR build/22873
10382 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
10383 last step, and do it atomically.
10384
10385 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
10386
10387 * compile/compile-c-types.c (convert_int, convert_float):
10388 Update for C FE v1.
10389
10390 2018-04-27 Tom Tromey <tom@tromey.com>
10391
10392 PR rust/22545:
10393 * rust-lang.c (rust_inclusive_range_type_p): New function.
10394 (rust_range): Handle inclusive ranges.
10395 (rust_compute_range): Likewise.
10396 * rust-exp.y (struct rust_op) <inclusive>: New field.
10397 (DOTDOTEQ): New constant.
10398 (range_expr): Add "..=" productions.
10399 (operator_tokens): Add "..=" token.
10400 (ast_range): Add "inclusive" parameter.
10401 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
10402 ranges.
10403 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
10404 bounds values.
10405 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
10406 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
10407 Update comments.
10408 * expprint.c (print_subexp_standard): Handle new bounds values.
10409 (dump_subexp_body_standard): Likewise.
10410
10411 2018-04-27 Tom Tromey <tom@tromey.com>
10412
10413 * configure: Rebuild.
10414 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
10415 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
10416 "OVERRIDE".
10417 (class symbol_needs_eval_context): Likewise.
10418 * dwarf2read.c (mock_mapped_index::symbol_name_count)
10419 (mock_mapped_index::symbol_name_at): Use "override". Remove
10420 "virtual".
10421 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
10422 "override".
10423 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
10424 * aarch64-tdep.c (instruction_reader::read): Use "override".
10425 (instruction_reader_test::read): Likewise.
10426 * arm-tdep.c (instruction_reader::read): Use "override".
10427 (instruction_reader_thumb::read): Likewise.
10428
10429 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
10430
10431 PR remote/9665
10432 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
10433 instead of remote_send.
10434 (remote_send): Remove.
10435
10436 2018-04-26 Pedro Alves <palves@redhat.com>
10437
10438 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
10439 find_function_start_sal instead of find_pc_line.
10440
10441 2018-04-26 Pedro Alves <palves@redhat.com>
10442
10443 * breakpoint.c (set_breakpoint_location_function): Handle
10444 mst_data_gnu_ifunc.
10445 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
10446 * elfread.c (elf_symtab_read): Give data symbols with
10447 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
10448 (elf_rel_plt_read): Update comment.
10449 * linespec.c (convert_linespec_to_sals): Handle
10450 mst_data_gnu_ifunc.
10451 (minsym_found): Handle mst_data_gnu_ifunc.
10452 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
10453 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
10454 * parse.c (find_minsym_type_and_address): Handle
10455 mst_data_gnu_ifunc.
10456 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
10457 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
10458 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
10459 comment.
10460 <mst_data_gnu_ifunc>: New enumerator.
10461
10462 2018-04-26 Pedro Alves <palves@redhat.com>
10463
10464 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
10465 (lookup_minimal_symbol_by_pc_section): ... this. Replace
10466 'want_trampoline' parameter by a lookup_msym_prefer parameter.
10467 Handle it.
10468 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
10469 (lookup_minimal_symbol_by_pc): Adjust.
10470 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
10471 (lookup_solib_trampoline_symbol_by_pc): Adjust.
10472 * minsyms.h (lookup_msym_prefer): New enum.
10473 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10474 parameter by a lookup_msym_prefer parameter.
10475
10476 2018-04-26 Pedro Alves <palves@redhat.com>
10477
10478 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
10479 ends in "@plt" instead of looking at the symbol's section.
10480
10481 2018-04-26 Pedro Alves <palves@redhat.com>
10482
10483 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
10484 all references.
10485 (find_pc_partial_function_gnu_ifunc): Rename to ...
10486 (find_pc_partial_function): ... this, and remove references to
10487 'is_gnu_ifunc_p'.
10488 (find_pc_partial_function): Delete old implementation.
10489 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
10490
10491 2018-04-26 Pedro Alves <palves@redhat.com>
10492
10493 * linespec.c (struct bound_minimal_symbol_search_key): New.
10494 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
10495 skip first line if we found a GNU ifunc minimal symbol by name.
10496 (compare_msymbols): Change parameters to work with a destructured
10497 lhs minsym.
10498 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
10499 functions.
10500
10501 2018-04-26 Pedro Alves <palves@redhat.com>
10502
10503 * breakpoint.c (set_breakpoint_location_function): Don't resolve
10504 ifunc targets here. Instead, if we have an ifunc minsym, use its
10505 address/name.
10506 (add_location_to_breakpoint): Store the minsym and the objfile in
10507 the breakpoint location.
10508 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
10509 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
10510 Record the minsym in the sal.
10511 * symtab.h (symtab_and_line) <msymbol>: New field.
10512
10513 2018-04-26 Pedro Alves <palves@redhat.com>
10514
10515 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
10516 unless we actually resolved the ifunc.
10517
10518 2018-04-26 Pedro Alves <palves@redhat.com>
10519
10520 * c-exp.y (variable production): Prefer ifunc minsyms over
10521 regular function symbols.
10522 * symtab.c (find_gnu_ifunc): New function.
10523 * minsyms.h (lookup_msym_prefer): New enum.
10524 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
10525 parameter by a lookup_msym_prefer parameter.
10526 * symtab.h (find_gnu_ifunc): New declaration.
10527
10528 2018-04-26 Pedro Alves <palves@redhat.com>
10529
10530 * blockframe.c (find_gnu_ifunc_target_type): New function.
10531 (find_function_type): New.
10532 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
10533 return a value with a memory address.
10534 (eval_call): For calls to GNU ifunc functions, try to find the
10535 type of the target function from the type that the resolver
10536 returns.
10537 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
10538 symbols.
10539 * infcall.c (find_function_return_type): Delete.
10540 (find_function_addr): Add 'function_type' parameter. For calls to
10541 GNU ifunc functions, try to find the type of the target function
10542 from the type that the resolver returns, and return it via
10543 FUNCTION_TYPE.
10544 (call_function_by_hand_dummy): Adjust to use the function type
10545 returned by find_function_addr.
10546 (find_function_addr): Add 'function_type' parameter and move
10547 description here.
10548 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
10549 declarations.
10550
10551 2018-04-26 Pedro Alves <palves@redhat.com>
10552
10553 * c-exp.y (variable production): Skip finding an alias for ifunc
10554 symbols.
10555
10556 2018-04-26 Pedro Alves <palves@redhat.com>
10557
10558 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
10559
10560 2018-04-25 Pedro Alves <palves@redhat.com>
10561
10562 * infcmd.c (kill_command): Print the pid as string, not the whole
10563 thread's ptid. Add comment. s/has been killed/killed/ in output
10564 message.
10565 * remote.c (remote_detach_1): Print the pid as string, not the
10566 whole thread's ptid.
10567
10568 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
10569 Sergio Durigan Junior <sergiodj@redhat.com>
10570 Pedro Alves <palves@redhat.com>
10571
10572 * infcmd.c (kill_command): Print message when inferior has
10573 been killed.
10574 * inferior.c (print_inferior_events): Remove 'static'. Set as
10575 '1'.
10576 (add_inferior): Improve message printed when
10577 'print_inferior_events' is on.
10578 (exit_inferior): Remove message printed when
10579 'print_inferior_events' is on.
10580 (detach_inferior): Improve message printed when
10581 'print_inferior_events' is on.
10582 (initialize_inferiors): Use 'add_inferior_silent' to set
10583 'current_inferior_'.
10584 * inferior.h (print_inferior_events): Declare here as
10585 'extern'.
10586 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
10587 '[Detaching...]' messages when 'print_inferior_events' is on.
10588 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
10589 as prefix/suffix for messages. Remove periods. Fix erroneous
10590 'Detaching after fork from child...', replace it by '... from
10591 parent...'.
10592 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
10593 prefix/suffix when printing 'Detaching...' messages. Print
10594 them when 'print_inferior_events' is on.
10595 * remote.c (remote_detach_1): Print message when detaching
10596 from inferior and '!is_fork_parent'.
10597
10598 2018-04-24 Tom Tromey <tom@tromey.com>
10599
10600 * cli-out.h: Reindent.
10601
10602 2018-04-24 Tom Tromey <tom@tromey.com>
10603
10604 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
10605 (cli_ui_out::do_field_string): Use fputs_filtered.
10606 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
10607
10608 2018-04-23 Tom Tromey <tom@tromey.com>
10609
10610 * guile/scm-frame.c (gdbscm_frame_read_var): Use
10611 gdb::unique_xmalloc_ptr.
10612
10613 2018-04-23 Tom Tromey <tom@tromey.com>
10614
10615 * configure: Rebuild.
10616
10617 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
10618
10619 PR gdb/23095
10620 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
10621 prepare_for_testing. Set normal_bp to r_debug_state if target
10622 is bsd.
10623
10624 2018-04-21 Pedro Alves <palves@redhat.com>
10625 Rajendra SY <rajendra.sy@gmail.com>
10626
10627 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
10628 * remote.c (extended_remote_attach): In all-stop mode, mark the
10629 thread as executing.
10630
10631 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
10632
10633 * thread.c (thread_apply_all_command): Fix comment.
10634 (thread_command): Fix comment.
10635
10636 2018-04-10 Alan Hayward <alan.hayward@arm.com>
10637
10638 * common/tdesc.h (tdesc_create_feature): Remove xml filename
10639 parameter.
10640 * features/aarch64-core.c (create_feature_aarch64_core):
10641 Regenerate.
10642 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
10643 Likewise.
10644 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
10645 Likewise.
10646 * features/i386/32bit-avx512.c
10647 (create_feature_i386_32bit_avx512): Likewise.
10648 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
10649 Likewise.
10650 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
10651 Likewise.
10652 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
10653 Likewise.
10654 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
10655 Likewise.
10656 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
10657 Likewise.
10658 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
10659 Likewise.
10660 * features/i386/64bit-avx512.c
10661 (create_feature_i386_64bit_avx512): Likewise.
10662 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
10663 Likewise.
10664 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
10665 Likewise.
10666 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
10667 Likewise.
10668 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
10669 Likewise.
10670 * features/i386/64bit-segments.c
10671 (create_feature_i386_64bit_segments): Likewise.
10672 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
10673 Likewise.
10674 * features/i386/x32-core.c
10675 (create_feature_i386_x32_core): Likewise.
10676 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
10677 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
10678 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
10679 * target-descriptions.c: In generated code, don't pass xml
10680 filename.
10681
10682 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10683
10684 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
10685 (print_xml_feature::visit_post): Likewise.
10686 (print_xml_feature::visit): Likewise.
10687 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
10688 (print_xml_feature): Add new class.
10689 * regformats/regdat.sh: Null xmltarget on feature targets.
10690 * target-descriptions.c (struct target_desc): Add xmltarget.
10691 (maintenance_check_tdesc_xml_convert): Add unittest function.
10692 (tdesc_get_features_xml): Add function to get xml.
10693 (maintenance_check_xml_descriptions): Test xml generation.
10694 * xml-tdesc.c (string_read_description_xml): Add function.
10695 * xml-tdesc.h (string_read_description_xml): Add declaration.
10696
10697 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10698
10699 * features/Makefile: Add feature marker to targets with new style
10700 target descriptions.
10701 * regformats/aarch64.dat: Regenerate.
10702 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
10703 * regformats/i386/amd64-avx-linux.dat: Likewise.
10704 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
10705 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
10706 * regformats/i386/amd64-linux.dat: Likewise.
10707 * regformats/i386/amd64-mpx-linux.dat: Likewise.
10708 * regformats/i386/amd64.dat: Likewise.
10709 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
10710 * regformats/i386/i386-avx-linux.dat: Likewise.
10711 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
10712 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
10713 * regformats/i386/i386-linux.dat: Likewise.
10714 * regformats/i386/i386-mmx-linux.dat: Likewise.
10715 * regformats/i386/i386-mpx-linux.dat: Likewise.
10716 * regformats/i386/i386.dat: Likewise.
10717 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
10718 * regformats/i386/x32-avx-linux.dat: Likewise.
10719 * regformats/i386/x32-linux.dat: Likewise.
10720 * regformats/tic6x-c62x-linux.dat: Likewise.
10721 * regformats/tic6x-c64x-linux.dat: Likewise.
10722 * regformats/tic6x-c64xp-linux.dat: Likewise.
10723 * regformats/regdat.sh: Parse feature marker.
10724
10725 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10726
10727 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
10728 (tdesc_osabi_name): Likewise.
10729 * target-descriptions.c (tdesc_architecture_name): Add new
10730 function.
10731 (tdesc_osabi_name): Likewise.
10732
10733 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10734
10735 * common/tdesc.c (tdesc_predefined_type): Move to here.
10736 (tdesc_named_type): Likewise.
10737 (tdesc_create_vector): Likewise.
10738 (tdesc_create_struct): Likewise.
10739 (tdesc_set_struct_size): Likewise.
10740 (tdesc_create_union): Likewise.
10741 (tdesc_create_flags): Likewise.
10742 (tdesc_create_enum): Likewise.
10743 (tdesc_add_field): Likewise.
10744 (tdesc_add_typed_bitfield): Likewise.
10745 (tdesc_add_bitfield): Likewise.
10746 (tdesc_add_flag): Likewise.
10747 (tdesc_add_enum_value): Likewise.
10748 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
10749 (struct tdesc_type_vector): Likewise.
10750 (struct tdesc_type_field): Likewise.
10751 (struct tdesc_type_with_fields): Likewise.
10752 (tdesc_create_enum): Add declaration.
10753 (tdesc_add_typed_bitfield): Likewise.
10754 (tdesc_add_enum_value): Likewise.
10755 * target-descriptions.c (tdesc_type_field): Move from here.
10756 (tdesc_type_builtin): Likewise.
10757 (tdesc_type_vector): Likewise.
10758 (tdesc_type_with_fields): Likewise.
10759 (tdesc_predefined_types): Likewise.
10760 (tdesc_named_type): Likewise.
10761 (tdesc_create_vector): Likewise.
10762 (tdesc_create_struct): Likewise.
10763 (tdesc_set_struct_size): Likewise.
10764 (tdesc_create_union): Likewise.
10765 (tdesc_create_flags): Likewise.
10766 (tdesc_create_enum): Likewise.
10767 (tdesc_add_field): Likewise.
10768 (tdesc_add_typed_bitfield): Likewise.
10769 (tdesc_add_bitfield): Likewise.
10770 (tdesc_add_flag): Likewise.
10771 (tdesc_add_enum_value): Likewise.
10772 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
10773 (tdesc_add_typed_bitfield): Likewise.
10774 (tdesc_add_enum_value): Likewise.
10775
10776 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10777
10778 * common/tdesc.c (tdesc_feature::accept): Move to here.
10779 (tdesc_feature::operator==): Likewise.
10780 (tdesc_create_reg): Likewise.
10781 * common/tdesc.h (tdesc_type_kind): Likewise.
10782 (struct tdesc_type): Likewise.
10783 (struct tdesc_feature): Likewise.
10784 * regformats/regdat.sh: Create a feature.
10785 * target-descriptions.c (tdesc_type_kind): Move from here.
10786 (tdesc_type): Likewise.
10787 (tdesc_type_up): Likewise.
10788 (tdesc_feature): Likewise.
10789 (tdesc_create_reg): Likewise.
10790
10791 2018-04-18 Alan Hayward <alan.hayward@arm.com>
10792
10793 * Makefile.in: Add arch/tdesc.c
10794 * common/tdesc.c: New file.
10795 * common/tdesc.h (tdesc_element_visitor): Move to here.
10796 (tdesc_element): Likewise.
10797 (tdesc_reg): Likewise.
10798 (tdesc_reg_up): Likewise.
10799 * regformats/regdef.h (reg): Add offset to constructors.
10800 * target-descriptions.c (tdesc_element_visitor): Move from here.
10801 (tdesc_element): Likewise.
10802 (tdesc_reg): Likewise.
10803 (tdesc_reg_up): Likewise.
10804
10805 2018-04-17 Tom Tromey <tom@tromey.com>
10806
10807 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
10808 discriminant field.
10809
10810 2018-04-17 Tom Tromey <tom@tromey.com>
10811
10812 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
10813
10814 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
10815
10816 * symtab.c (print_symbol_info): Skip printing filename and line
10817 number when `last' is NULL.
10818 (symtab_symbol_info): Use empty string instead of NULL for first
10819 invocation of print_symbol_info.
10820 (rbreak_command): Pass NULL to `last' parameter of
10821 print_symbol_info.
10822
10823 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
10824
10825 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
10826 instead of nullptr.
10827
10828 2018-04-16 Pedro Alves <palves@redhat.com>
10829
10830 * MAINTAINERS (sh): Remove.
10831 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
10832 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
10833 (ALLDEPFILES): Remove sh64-tdep.c.
10834 * NEWS: Mentions that support for SH-5/SH64 is removed.
10835 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
10836 (sh*-*-openbsd*): Ditto.
10837 (sh64-*-elf*): Remove.
10838 (sh*): Remove.
10839 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
10840 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
10841 * sh-tdep.c: No longer include "sh64-tdep.h".
10842 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
10843 * sh64-tdep.c, sh64-tdep.h: Remove files.
10844
10845 2018-04-16 Pedro Alves <palves@redhat.com>
10846
10847 * MAINTAINERS: Remove m88k.
10848 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
10849 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
10850 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
10851 * NEWS: Mention that support for m88k was removed.
10852 * configure.host (m88*-*-*): Remove support.
10853 * configure.nat (m88k-*-*): Remove support.
10854 * configure.tgt (m88*-*-openbsd*): Remove.
10855 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
10856
10857 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
10858
10859 * configure.tgt (x86_tobjs): New variable.
10860 (amd64_tobjs, i386_tobjs): Use it.
10861
10862 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10863
10864 * symtab.c (print_symbol_info): Precede the symbol definition by
10865 the line number when available.
10866 * NEWS: Advertise this enhancement.
10867
10868 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10869
10870 * NEWS (New options): announce set/show record btrace cpu.
10871 * btrace.c: Include record-btrace.h.
10872 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
10873 the vendor is unknown.
10874 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
10875 Maybe overwrite the btrace configuration's cpu.
10876 (btrace_compute_ftrace): Add cpu parameter. Update callers.
10877 (btrace_fetch): Add cpu parameter. Update callers.
10878 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
10879 Maybe overwrite the btrace configuration's cpu. Skip enabling
10880 errata workarounds if the vendor is unknown.
10881 * python/py-record-btrace.c: Include record-btrace.h.
10882 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
10883 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
10884 * record-btrace.c (record_btrace_cpu_state_kind): New.
10885 (record_btrace_cpu): New.
10886 (set_record_btrace_cpu_cmdlist): New.
10887 (record_btrace_get_cpu): New.
10888 (require_btrace_thread, record_btrace_info)
10889 (record_btrace_resume_thread): Call record_btrace_get_cpu.
10890 (cmd_set_record_btrace_cpu_none): New.
10891 (cmd_set_record_btrace_cpu_auto): New.
10892 (cmd_set_record_btrace_cpu): New.
10893 (cmd_show_record_btrace_cpu): New.
10894 (_initialize_record_btrace): Initialize set/show record btrace cpu
10895 commands.
10896 * record-btrace.h (record_btrace_get_cpu): New.
10897
10898 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10899
10900 * record.c (set_record_command): Fix typo in message.
10901
10902 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10903
10904 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
10905
10906 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
10907
10908 * infrun.c (process_event_stop_test): Call
10909 gdbarch_in_indirect_branch_thunk.
10910 * gdbarch.sh (in_indirect_branch_thunk): New.
10911 * gdbarch.c: Regenerated.
10912 * gdbarch.h: Regenerated.
10913 * x86-tdep.h: New.
10914 * x86-tdep.c: New.
10915 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
10916 (HFILES_NO_SRCDIR): Add x86-tdep.h.
10917 (ALLDEPFILES): Add x86-tdep.c.
10918 * arch-utils.h (default_in_indirect_branch_thunk): New.
10919 * arch-utils.c (default_in_indirect_branch_thunk): New.
10920 * i386-tdep: Include x86-tdep.h.
10921 (i386_in_indirect_branch_thunk): New.
10922 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
10923 function.
10924 * amd64-tdep: Include x86-tdep.h.
10925 (amd64_in_indirect_branch_thunk): New.
10926 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
10927
10928 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
10929
10930 PR gdb/23053
10931 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
10932 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
10933 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
10934 regression.
10935
10936 2018-04-12 Tom Tromey <tom@tromey.com>
10937
10938 * rust-lang.c (rust_print_struct_def): Remove univariant code.
10939 (rust_evaluate_subexp): Likewise.
10940
10941 2018-04-12 Pedro Alves <palves@redhat.com>
10942
10943 * procfs.c (procfs_detach): Make forward declaration's prototype
10944 match definition's protototype.
10945 (proc_get_LDT_entry): Remove stale do_cleanups call.
10946
10947 2018-04-12 Pedro Alves <palves@redhat.com>
10948
10949 * target.h (target_ops::to_has_exited): Delete.
10950 (target_has_exited): Delete.
10951 * target-delegates.c: Regenerate.
10952
10953 2018-04-11 Pedro Alves <palves@redhat.com>
10954
10955 * target.c (fileio_fh_t::t): Add comment.
10956 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10957 (target_fileio_close): Handle a NULL target.
10958 (invalidate_fileio_fh): New.
10959 (target_close): Call it.
10960 * remote.c (remote_hostio_send_command): No longer check whether
10961 remote_desc is open.
10962
10963 2018-04-11 Pedro Alves <palves@redhat.com>
10964
10965 * target.c (fileio_fh_t): Make it a named struct instead of a
10966 typedef.
10967 (fileio_fh_t::is_closed): New method.
10968 (DEF_VEC_O (fileio_fh_t)): Remove.
10969 (fileio_fhandles): Now a std::vector.
10970 (is_closed_fileio_fh): Delete.
10971 (acquire_fileio_fd): Adjust. Rename parameters.
10972 (release_fileio_fd): Adjust.
10973 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
10974 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
10975 (target_fileio_close): Adjust.
10976
10977 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
10978
10979 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
10980 index.
10981
10982 2018-04-10 Pedro Alves <palves@redhat.com>
10983
10984 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
10985 (scoped_finish_thread_state): New class.
10986 * infcmd.c (run_command_1): Use it instead of finish_thread_state
10987 cleanup.
10988 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
10989 (fetch_inferior_event, normal_stop): Likewise.
10990 * thread.c (finish_thread_state_cleanup): Delete.
10991
10992 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
10993 Pedro Alves <palves@redhat.com>
10994
10995 * value.c: Include "selftest.h" and "common/array-view.h".
10996 (struct range) <operator ==>: New.
10997 (test_ranges_contain): New.
10998 (check_ranges_vector): New.
10999 (test_insert_into_bit_range_vector): New.
11000 (_initialize_values): Register selftests.
11001 * common/array-view.h (operator==, operator!=): New.
11002
11003 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11004
11005 * common/gdb_vecs.h (unordered_remove): Add overload that takes
11006 an iterator.
11007 * inline-frame.c: Include <algorithm>.
11008 (struct inline_state): Add constructor.
11009 (inline_state_s): Remove.
11010 (DEF_VEC_O(inline_state_s)): Remove.
11011 (inline_states): Change type to std::vector.
11012 (find_inline_frame_state): Adjust to std::vector.
11013 (allocate_inline_frame_state): Remove.
11014 (clear_inline_frame_state): Adjust to std::vector.
11015 (skip_inline_frames): Adjust to std::vector.
11016
11017 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11018
11019 * tracepoint.h (struct trace_state_variable): Add constructor.
11020 <name>: Change type to std::string.
11021 * tracepoint.c (tsv_s): Remove.
11022 (DEF_VEC_O(tsv_s)): Remove.
11023 (tvariables): Change to std::vector.
11024 (create_trace_state_variable): Adjust to std::vector.
11025 (find_trace_state_variable): Likewise.
11026 (find_trace_state_variable_by_number): Likewise.
11027 (delete_trace_state_variable): Likewise.
11028 (trace_variable_command): Adjust to std::string.
11029 (delete_trace_variable_command): Likewise.
11030 (tvariables_info_1): Adjust to std::vector.
11031 (save_trace_state_variables): Likewise.
11032 (start_tracing): Likewise.
11033 (merge_uploaded_trace_state_variables): Adjust to std::vector
11034 and std::string.
11035 * target.h (struct target_ops)
11036 <to_download_trace_state_variable>: Pass reference to
11037 trace_state_variable.
11038 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
11039 * target-delegates.c: Re-generate.
11040 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
11041 (mi_tsv_deleted): Likewise.
11042 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
11043 * remote.c (remote_download_trace_state_variable): Change
11044 pointer to reference and adjust.
11045 * make-target-delegates (parse_argtypes): Handle references.
11046 (write_function_header): Likewise.
11047 (munge_type): Likewise.
11048
11049 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11050
11051 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11052 string_view-selftests.c.
11053 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
11054 testsuite.
11055 * unittests/basic_string_view/cons/char/1.cc: Likewise.
11056 * unittests/basic_string_view/cons/char/2.cc: Likewise.
11057 * unittests/basic_string_view/cons/char/3.cc: Likewise.
11058 * unittests/basic_string_view/element_access/char/1.cc:
11059 Likewise.
11060 * unittests/basic_string_view/element_access/char/empty.cc:
11061 Likewise.
11062 * unittests/basic_string_view/element_access/char/front_back.cc:
11063 Likewise.
11064 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
11065 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
11066 Likewise.
11067 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
11068 Likewise.
11069 * unittests/basic_string_view/modifiers/swap/char/1.cc:
11070 Likewise.
11071 * unittests/basic_string_view/operations/compare/char/1.cc:
11072 Likewise.
11073 * unittests/basic_string_view/operations/compare/char/13650.cc:
11074 Likewise.
11075 * unittests/basic_string_view/operations/copy/char/1.cc:
11076 Likewise.
11077 * unittests/basic_string_view/operations/data/char/1.cc:
11078 Likewise.
11079 * unittests/basic_string_view/operations/find/char/1.cc:
11080 Likewise.
11081 * unittests/basic_string_view/operations/find/char/2.cc:
11082 Likewise.
11083 * unittests/basic_string_view/operations/find/char/3.cc:
11084 Likewise.
11085 * unittests/basic_string_view/operations/find/char/4.cc:
11086 Likewise.
11087 * unittests/basic_string_view/operations/rfind/char/1.cc:
11088 Likewise.
11089 * unittests/basic_string_view/operations/rfind/char/2.cc:
11090 Likewise.
11091 * unittests/basic_string_view/operations/rfind/char/3.cc:
11092 Likewise.
11093 * unittests/basic_string_view/operations/substr/char/1.cc:
11094 Likewise.
11095 * unittests/basic_string_view/operators/char/2.cc: Likewise.
11096 * unittests/string_view-selftests.c: New file.
11097
11098 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11099
11100 * unittests/basic_string_view/capacity/1.cc: New file.
11101 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
11102 * unittests/basic_string_view/cons/char/1.cc: New file.
11103 * unittests/basic_string_view/cons/char/2.cc: New file.
11104 * unittests/basic_string_view/cons/char/3.cc: New file.
11105 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
11106 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
11107 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
11108 * unittests/basic_string_view/element_access/char/1.cc: New file.
11109 * unittests/basic_string_view/element_access/char/2.cc: New file.
11110 * unittests/basic_string_view/element_access/char/empty.cc: New file.
11111 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
11112 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
11113 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
11114 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
11115 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
11116 * unittests/basic_string_view/include.cc: New file.
11117 * unittests/basic_string_view/inserters/char/1.cc: New file.
11118 * unittests/basic_string_view/inserters/char/2.cc: New file.
11119 * unittests/basic_string_view/inserters/char/3.cc: New file.
11120 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
11121 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
11122 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
11123 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
11124 * unittests/basic_string_view/literals/types.cc: New file.
11125 * unittests/basic_string_view/literals/values.cc: New file.
11126 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
11127 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
11128 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
11129 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
11130 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
11131 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
11132 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
11133 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
11134 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
11135 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
11136 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
11137 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
11138 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
11139 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
11140 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
11141 * unittests/basic_string_view/operations/data/char/1.cc: New file.
11142 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
11143 * unittests/basic_string_view/operations/find/char/1.cc: New file.
11144 * unittests/basic_string_view/operations/find/char/2.cc: New file.
11145 * unittests/basic_string_view/operations/find/char/3.cc: New file.
11146 * unittests/basic_string_view/operations/find/char/4.cc: New file.
11147 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
11148 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
11149 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
11150 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
11151 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
11152 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
11153 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
11154 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
11155 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
11156 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
11157 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
11158 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
11159 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
11160 * unittests/basic_string_view/operators/char/2.cc: New file.
11161 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
11162 * unittests/basic_string_view/range_access/char/1.cc: New file.
11163 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
11164 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
11165 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
11166 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
11167 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
11168 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
11169 * unittests/basic_string_view/requirements/typedefs.cc: New file.
11170 * unittests/basic_string_view/typedefs.cc: New file.
11171 * unittests/basic_string_view/types/1.cc: New file.
11172
11173 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11174
11175 * common/gdb_string_view.h: Remove libstdc++ implementation
11176 details, adjust to gdb reality.
11177 * common/gdb_string_view.tcc: Likewise.
11178 * cli/cli-script.c (struct string_view): Remove.
11179 (user_args) <m_args>: Change element type to gdb::string_view.
11180 (user_args::insert_args): Adjust.
11181
11182 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11183
11184 * common/gdb_string_view.h: New file.
11185 * common/gdb_string_view.tcc: New file.
11186
11187 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11188
11189 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
11190 * configure: Re-generate.
11191
11192 2018-04-09 Pedro Alves <palves@redhat.com>
11193
11194 * gdbarch.sh: Include "observable.h" instead of "observer.h".
11195 (set_target_gdbarch): Call
11196 gdb::observers::architecture_changed.notify instead of
11197 observer_notify_architecture_changed.
11198
11199 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11200
11201 * tracepoint.c (struct current_traceframe_cleanup): Remove.
11202 (do_restore_current_traceframe_cleanup): Remove.
11203 (restore_current_traceframe_cleanup_dtor): Remove.
11204 (make_cleanup_restore_current_traceframe): Remove.
11205 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
11206 New.
11207 * tracepoint.h (struct scoped_restore_current_traceframe): New.
11208 * infrun.c (fetch_inferior_event): Use
11209 scoped_restore_current_traceframe.
11210
11211 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11212
11213 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
11214 Remove.
11215 <n_allocated_type_units>: Remove.
11216 <all_type_units>: Change to std::vector.
11217 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
11218 to std::vector change.
11219 (dwarf2_per_objfile::get_cutu): Likewise.
11220 (dwarf2_per_objfile::get_tu): Likewise.
11221 (create_signatured_type_table_from_index): Likewise.
11222 (create_signatured_type_table_from_debug_names): Likewise.
11223 (dw2_symtab_iter_next): Likewise.
11224 (dw2_print_stats): Likewise.
11225 (dw2_expand_all_symtabs): Likewise.
11226 (dw2_expand_marked_cus): Likewise.
11227 (dw2_debug_names_iterator::next): Likewise.
11228 (dwarf2_initialize_objfile): Likewise.
11229 (add_signatured_type_cu_to_table): Likewise.
11230 (create_all_type_units): Likewise.
11231 (add_type_unit): Likewise.
11232 (struct tu_abbrev_offset): Add constructor.
11233 (build_type_psymtabs_1): Adjust to std::vector change.
11234 (print_tu_stats): Likewise.
11235 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
11236 (write_debug_names): Likewise.
11237
11238 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11239
11240 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
11241 Make an std::vector.
11242 <n_comp_units>: Remove.
11243 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
11244 to std::vector change.
11245 (dwarf2_per_objfile::get_cutu): Likewise.
11246 (dwarf2_per_objfile::get_cu): Likewise.
11247 (create_cus_from_index): Likewise.
11248 (create_addrmap_from_index): Likewise.
11249 (create_addrmap_from_aranges): Likewise.
11250 (dwarf2_read_index): Likewise.
11251 (dw2_find_last_source_symtab): Likewise.
11252 (dw2_map_symtabs_matching_filename): Likewise.
11253 (dw2_symtab_iter_next): Likewise.
11254 (dw2_print_stats): Likewise.
11255 (dw2_expand_all_symtabs): Likewise.
11256 (dw2_expand_symtabs_with_fullname): Likewise.
11257 (dw2_expand_marked_cus): Likewise.
11258 (dw2_map_symbol_filenames): Likewise.
11259 (create_cus_from_debug_names): Likewise.
11260 (dwarf2_read_debug_names): Likewise.
11261 (dw2_debug_names_iterator::next): Likewise.
11262 (dwarf2_initialize_objfile): Likewise.
11263 (set_partial_user): Likewise.
11264 (dwarf2_build_psymtabs_hard): Likewise.
11265 (read_comp_units_from_section): Remove arguments, adjust to
11266 std::vector change.
11267 (create_all_comp_units): Adjust to std::vector and
11268 read_comp_units_from_section changes.
11269 (dwarf2_find_containing_comp_unit): Adjust to std::vector
11270 change.
11271 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
11272 (psyms_seen_size): Likewise.
11273 (write_gdbindex): Likewise.
11274 (write_debug_names): Likewise.
11275
11276 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11277
11278 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
11279 with dwarf2_per_objfile.
11280 (create_cus_from_index): Likewise.
11281 (create_signatured_type_table_from_index): Likewise.
11282 (dwarf2_read_index): Likewise.
11283 (dwarf2_initialize_objfile): Likewise.
11284 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
11285 per_cu rather than get_dwarf2_per_objfile.
11286
11287 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11288
11289 * dwarf2read.h (struct signatured_type): Forward declare.
11290 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
11291 New methods.
11292 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
11293 (dw2_get_cutu): ...this.
11294 (dwarf2_per_objfile::get_cu): Rename from...
11295 (dw2_get_cu): ...this.
11296 (dwarf2_per_objfile::get_tu): New.
11297 (create_addrmap_from_index): Adjust.
11298 (create_addrmap_from_aranges): Adjust.
11299 (dw2_find_last_source_symtab): Adjust.
11300 (dw2_map_symtabs_matching_filename): Adjust.
11301 (dw2_symtab_iter_next): Adjust.
11302 (dw2_print_stats): Adjust.
11303 (dw2_expand_all_symtabs): Adjust.
11304 (dw2_expand_symtabs_with_fullname): Adjust.
11305 (dw2_expand_marked_cus): Adjust.
11306 (dw_expand_symtabs_matching_file_matcher): Adjust.
11307 (dw2_map_symbol_filenames): Adjust.
11308 (dw2_debug_names_iterator::next): Adjust.
11309 (dwarf2_initialize_objfile): Adjust.
11310 (set_partial_user): Adjust.
11311 (dwarf2_build_psymtabs_hard): Adjust.
11312
11313 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11314
11315 * dwarf2read.c (create_signatured_type_table_from_debug_names):
11316 Remove unused variables.
11317 (dw2_map_symtabs_matching_filename): Likewise.
11318 (dwarf2_record_block_ranges): Likewise.
11319 (dwarf2_read_addr_index): Likewise.
11320 (follow_die_offset): Likewise.
11321
11322 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11323
11324 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
11325 to symbol_file_add_main.
11326
11327 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11328
11329 PR mi/22299
11330 * mi/mi-console.c (do_fputc_async_safe): New.
11331 (mi_console_file::write_async_safe): New.
11332 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
11333 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
11334 New.
11335 * ui-file.c (ui_file::putstrn): Adjust call to
11336 fputstrn_unfiltered.
11337 * utils.c (printchar): Replace do_fputs and do_fprintf
11338 parameters by do_fputc.
11339 (fputstr_filtered): Adjust call to printchar.
11340 (fputstr_unfiltered): Likewise.
11341 (fputstrn_filtered): Likewise.
11342 (fputstrn_unfiltered): Add do_fputc parameter, pass to
11343 printchar.
11344 * utils.h (do_fputc_ftype): New typedef.
11345 (fputstrn_unfiltered): Add do_fputc parameter.
11346
11347 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
11348
11349 * regformats/i386/i386-avx.dat: Remove.
11350
11351 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11352
11353 PR gdb/22979
11354 * amd64-tdep.c (amd64_none_init_abi): New function.
11355 (amd64_x32_none_init_abi): New function.
11356 (_initialize_amd64_tdep): Register handlers for x86-64 and
11357 x64_32 with GDB_OSABI_NONE.
11358 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
11359 GDB_OSABI_NONE osabi.
11360
11361 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11362
11363 PR gdb/22980
11364 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
11365 GDB_OSABI_NONE.
11366 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
11367 * osabi.c (gdb_osabi_names): Add "unknown" entry.
11368
11369 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
11370
11371 * common/byte-vector.h (char_vector): New type.
11372 * target.h (target_read_alloc): Return
11373 gdb::optional<byte_vector>.
11374 (target_read_stralloc): Return gdb::optional<char_vector>.
11375 (target_get_osdata): Return gdb::optional<char_vector>.
11376 * target.c (target_read_alloc_1): Templatize. Replacement
11377 manual memory management with vector.
11378 (target_read_alloc): Change return type, adjust.
11379 (target_read_stralloc): Change return type, adjust.
11380 (target_get_osdata): Change return type, adjust.
11381 * auxv.c (struct auxv_info) <length>: Remove.
11382 <data>: Change type to gdb::optional<byte_vector>.
11383 (auxv_inferior_data_cleanup): Free auxv_info with delete.
11384 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
11385 (target_auxv_search): Adjust.
11386 (fprint_target_auxv): Adjust.
11387 * avr-tdep.c (avr_io_reg_read_command): Adjust.
11388 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
11389 (linux_make_corefile_notes): Adjust.
11390 * osdata.c (get_osdata): Adjust.
11391 * remote.c (remote_get_threads_with_qxfer): Adjust.
11392 (remote_memory_map): Adjust.
11393 (remote_traceframe_info): Adjust.
11394 (btrace_read_config): Adjust.
11395 (remote_read_btrace): Adjust.
11396 (remote_pid_to_exec_file): Adjust.
11397 * solib-aix.c (solib_aix_get_library_list): Adjust.
11398 * solib-dsbt.c (decode_loadmap): Don't free buf.
11399 (dsbt_get_initial_loadmaps): Adjust.
11400 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
11401 * solib-target.c (solib_target_current_sos): Adjust.
11402 * tracepoint.c (sdata_make_value): Adjust.
11403 * xml-support.c (xinclude_start_include): Adjust.
11404 (xml_fetch_content_from_file): Adjust.
11405 * xml-support.h (xml_fetch_another): Change return type.
11406 (xml_fetch_content_from_file): Change return type.
11407 * xml-syscall.c (xml_init_syscalls_info): Adjust.
11408 * xml-tdesc.c (file_read_description_xml): Adjust.
11409 (fetch_available_features_from_target): Change return type.
11410 (target_fetch_description_xml): Adjust.
11411 (target_read_description_xml): Adjust.
11412
11413 2018-04-06 Tom Tromey <tom@tromey.com>
11414
11415 * value.c (~value): Update.
11416 (struct value) <contents>: Now unique_xmalloc_ptr.
11417 (value_contents_bits_eq, allocate_value_contents)
11418 (value_contents_raw, value_contents_all_raw)
11419 (value_contents_for_printing, value_contents_for_printing_const)
11420 (set_value_enclosing_type): Update.
11421
11422 2018-04-06 Tom Tromey <tom@tromey.com>
11423
11424 * value.c (range_s): Remove typedef, VEC.
11425 (struct range): Add operator<.
11426 (range_lessthan): Remove.
11427 (ranges_contain): Change type.
11428 (~value): Update.
11429 (struct value) <unavailable, optimized_out>: Now std::vector.
11430 (value_entirely_available)
11431 (value_entirely_covered_by_range_vector)
11432 (value_entirely_unavailable, value_entirely_optimized_out):
11433 Update.
11434 (insert_into_bit_range_vector): Change argument type.
11435 (find_first_range_overlap): Likewise.
11436 (struct ranges_and_idx, value_contents_bits_eq)
11437 (require_not_optimized_out, require_available): Update.
11438 (ranges_copy_adjusted): Change argument types.
11439 (value_optimized_out, value_copy, value_fetch_lazy): Update.
11440
11441 2018-04-06 Tom Tromey <tom@tromey.com>
11442
11443 * value.c (~value): Update.
11444 (struct value) <parent>: Now a value_ref_ptr.
11445 (value_parent, set_value_parent, value_address, value_copy):
11446 Update.
11447
11448 2018-04-06 Tom Tromey <tom@tromey.com>
11449
11450 * value.c (struct value): Add constructor, destructor, and member
11451 initializers.
11452 (allocate_value_lazy, value_decref): Update.
11453
11454 2018-04-06 Tom Tromey <tom@tromey.com>
11455
11456 * value.c (struct value) <released, next>: Remove.
11457 (all_values): Now a std::vector.
11458 (allocate_value_lazy): Update.
11459 (value_next): Remove.
11460 (value_mark, value_free_to_mark, release_value)
11461 (value_release_to_mark): Update.
11462
11463 2018-04-06 Tom Tromey <tom@tromey.com>
11464
11465 * value.h (fetch_subexp_value, value_release_to_mark): Update.
11466 (free_value_chain): Remove.
11467 * value.c (free_value_chain): Remove.
11468 (value_release_to_mark): Return a std::vector.
11469 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
11470 std::vector.
11471 (check_condition): Update.
11472 * eval.c (fetch_subexp_value): Change "val_chain" to a
11473 std::vector.
11474 * breakpoint.c (update_watchpoint): Update.
11475 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
11476
11477 2018-04-06 Tom Tromey <tom@tromey.com>
11478
11479 * value.h (free_all_values): Remove.
11480 * value.c (free_all_values): Remove.
11481
11482 2018-04-06 Tom Tromey <tom@tromey.com>
11483
11484 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
11485 (value_history_chain, value_history_count): Remove.
11486 (value_history): New global.
11487 (record_latest_value, access_value_history, show_values)
11488 (preserve_values): Update.
11489
11490 2018-04-06 Tom Tromey <tom@tromey.com>
11491
11492 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
11493 * varobj.c (varobj_set_display_format, varobj_set_value)
11494 (install_default_visualizer, construct_visualizer)
11495 (install_new_value, ~varobj, varobj_get_value_type)
11496 (my_value_of_variable, varobj_editable_p): Update.
11497 * c-varobj.c (c_describe_child, c_value_of_variable)
11498 (cplus_number_of_children, cplus_describe_child): Update.
11499 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
11500 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
11501 (ada_value_of_variable, ada_value_is_changeable_p): Update.
11502
11503 2018-04-06 Tom Tromey <tom@tromey.com>
11504
11505 * printcmd.c (last_examine_address): Change type to
11506 value_ref_ptr.
11507 (do_examine, x_command): Update.
11508
11509 2018-04-06 Tom Tromey <tom@tromey.com>
11510
11511 * value.c (release_value): Update.
11512 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
11513 (struct bpstats) <val>: Now a value_ref_ptr.
11514 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11515 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11516 (~watchpoint, print_it_watchpoint, watch_command_1)
11517 (invalidate_bp_value_on_memory_change): Update.
11518
11519 2018-04-06 Tom Tromey <tom@tromey.com>
11520
11521 * varobj.c (varobj_clear_saved_item)
11522 (update_dynamic_varobj_children, install_new_value, ~varobj):
11523 Update.
11524 * value.h (value_incref): Move declaration earlier.
11525 (value_decref): Rename from value_free.
11526 (struct value_ref_policy): New.
11527 (value_ref_ptr): New typedef.
11528 (struct value_deleter): Remove.
11529 (gdb_value_up): Remove typedef.
11530 (release_value): Change return type.
11531 (release_value_or_incref): Remove.
11532 * value.c (set_value_parent): Update.
11533 (value_incref): Change return type.
11534 (value_decref): Rename from value_free.
11535 (value_free_to_mark, free_all_values, free_value_chain): Update.
11536 (release_value): Return value_ref_ptr.
11537 (release_value_or_incref): Remove.
11538 (record_latest_value, set_internalvar, clear_internalvar):
11539 Update.
11540 * stack.c (info_frame_command): Don't call value_free.
11541 * python/py-value.c (valpy_dealloc, valpy_new)
11542 (value_to_value_object): Update.
11543 * printcmd.c (do_examine): Update.
11544 * opencl-lang.c (lval_func_free_closure): Update.
11545 * mi/mi-main.c (register_changed_p): Don't call value_free.
11546 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
11547 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
11548 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
11549 value_free.
11550 * guile/scm-value.c (vlscm_free_value_smob)
11551 (vlscm_scm_from_value): Update.
11552 * frame.c (frame_register_unwind, frame_unwind_register_signed)
11553 (frame_unwind_register_unsigned, get_frame_register_bytes)
11554 (put_frame_register_bytes): Don't call value_free.
11555 * findvar.c (address_from_register): Don't call value_free.
11556 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
11557 * dwarf2loc.c (entry_data_value_free_closure)
11558 (value_of_dwarf_reg_entry, free_pieced_value_closure)
11559 (dwarf2_evaluate_loc_desc_full): Update.
11560 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
11561 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
11562 (~watchpoint, watch_command_1)
11563 (invalidate_bp_value_on_memory_change): Update.
11564 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
11565
11566 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
11567
11568 PR gdb/23022
11569 * warning.m4: Add -Wno-error=deprecated-register.
11570 * configure: Re-generate.
11571
11572 2018-04-05 Tom Tromey <tom@tromey.com>
11573
11574 * linespec.h: Remove include of "vec.h".
11575
11576 2018-04-05 Tom Tromey <tom@tromey.com>
11577
11578 * linespec.c (typep): Remove typedef.
11579 (find_methods, find_superclass_methods): Take a std::vector.
11580 (find_method): Use std::vector.
11581
11582 2018-04-05 Tom Tromey <tom@tromey.com>
11583
11584 * utils.c (compare_strings): Remove.
11585 * utils.h (compare_strings): Remove.
11586 * objc-lang.h (find_imps): Update.
11587 * objc-lang.c (find_methods): Take a std::vector.
11588 (uniquify_strings, find_imps): Likewise.
11589 * linespec.c (find_methods): Take a std::vector.
11590 (decode_objc): Use std::vector.
11591 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
11592 a std::vector.
11593 (find_method, find_function_symbols): Use std::vector.
11594
11595 2018-04-05 Tom Tromey <tom@tromey.com>
11596
11597 * completer.c (completion_tracker::completion_tracker): Remove
11598 cast.
11599 (completion_tracker::discard_completions): Likewise.
11600 * breakpoint.c (ambiguous_names_p): Remove cast.
11601 * ada-lang.c (_initialize_ada_language): Remove cast.
11602 * utils.h (streq): Update.
11603 (streq_hash): Add new declaration.
11604 * utils.c (streq): Return bool.
11605 (streq_hash): New function.
11606
11607 2018-04-05 Tom Tromey <tom@tromey.com>
11608
11609 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
11610 Remove a string copy.
11611
11612 2018-04-05 Tom Tromey <tom@tromey.com>
11613
11614 * linespec.c (filter_results): Use std::vector.
11615 (decode_line_2, decode_line_full): Update.
11616
11617 2018-04-05 Tom Tromey <tom@tromey.com>
11618
11619 * linespec.c (canonical_to_fullform): Return std::string.
11620 (filter_results): Update.
11621 (struct decode_line_2_item): Add constructor.
11622 <fullform, displayform>: Now std::string.
11623 (decode_line_2_compare_items): Now a std::sort comparator.
11624 (decode_line_2): Update.
11625
11626 2018-04-05 Tom Tromey <tom@tromey.com>
11627
11628 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
11629 (unexpected_linespec_error): Update.
11630 (linespec_parse_basic, parse_linespec): Update.
11631
11632 2018-04-05 Tom Tromey <tom@tromey.com>
11633
11634 * linespec.c (linespec_parse_basic): Reindent.
11635
11636 2018-04-05 Tom Tromey <tom@tromey.com>
11637
11638 * minsyms.h (iterate_over_minimal_symbols): Update.
11639 * minsyms.c (iterate_over_minimal_symbols): Take a
11640 gdb::function_view.
11641 * linespec.c (struct collect_minsyms): Remove.
11642 (compare_msyms): Now a std::sort comparator.
11643 (add_minsym): Add parameters.
11644 (search_minsyms_for_name): Update. Use std::vector.
11645
11646 2018-04-03 Tom Tromey <tom@tromey.com>
11647
11648 * mipsread.c (read_alphacoff_dynamic_symtab): Use
11649 gdb::byte_vector.
11650
11651 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11652
11653 * MAINTAINERS (Write After Approval): Add Weimin Pan.
11654
11655 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
11656
11657 PR gdb/16959
11658 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
11659 printing static type.
11660
11661 2018-04-01 Tom Tromey <tom@tromey.com>
11662
11663 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
11664 (rs6000_xfer_shared_libraries): Update.
11665
11666 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
11667
11668 * common/gdb_vecs.h (char_ptr): Remove.
11669 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
11670
11671 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11672
11673 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
11674 with std::vector.
11675 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
11676
11677 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
11678
11679 * tracepoint.h (struct uploaded_tp): Initialize fields.
11680 <actions, step_actions, cmd_strings>: Change type to
11681 std::vector<char *>.
11682 * tracepoint.c (get_uploaded_tp): Allocate with new.
11683 (free_uploaded_tps): Free with delete.
11684 (parse_tracepoint_definition): Adjust to std::vector change.
11685 * breakpoint.c (read_uploaded_action): Likewise.
11686 (create_tracepoint_from_upload): Likewise.
11687 * ctf.c (ctf_write_uploaded_tp): Likewise.
11688 (SET_ARRAY_FIELD): Likewise.
11689 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
11690
11691 2018-03-30 Tom Tromey <tom@tromey.com>
11692
11693 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
11694 std::unique_ptr.
11695 (svr4_keep_data_in_core): Update.
11696 (svr4_read_so_list): Update.
11697
11698 2018-03-30 Tom Tromey <tom@tromey.com>
11699
11700 * windows-nat.c (handle_output_debug_string, handle_exception):
11701 Update.
11702 * target.h (target_read_string): Update.
11703 * target.c (target_read_string): Change "string" to
11704 unique_xmalloc_ptr.
11705 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
11706 Update.
11707 * solib-frv.c (frv_current_sos): Update.
11708 * solib-dsbt.c (dsbt_current_sos): Update.
11709 * solib-darwin.c (darwin_current_sos): Update.
11710 * linux-thread-db.c (inferior_has_bug): Update.
11711 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
11712 Update. Remove alloca.
11713 * ada-lang.c (ada_main_name): Update.
11714
11715 2018-03-30 Tom Tromey <tom@tromey.com>
11716
11717 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
11718 (struct dwo_file_deleter): New.
11719 (dwo_file_up): New typedef.
11720 (open_and_init_dwo_file): Use dwo_file_up.
11721 (free_dwo_file_cleanup): Remove.
11722
11723 2018-03-30 Tom Tromey <tom@tromey.com>
11724
11725 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
11726 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
11727
11728 2018-03-30 Tom Tromey <tom@tromey.com>
11729
11730 * dwarf2read.c (class free_cached_comp_units): New class.
11731 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
11732 (free_cached_comp_units): Remove function.
11733
11734 2018-03-30 Tom Tromey <tom@tromey.com>
11735
11736 * utils.h (make_cleanup_unpush_target): Remove.
11737 * inf-ptrace.c (struct target_unpusher): New.
11738 (target_unpush_up) New typedef.
11739 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
11740 target_unpush_up.
11741 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
11742
11743 2018-03-27 Tom Tromey <tom@tromey.com>
11744
11745 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
11746
11747 2018-03-27 Pedro Alves <palves@redhat.com>
11748 Tom Tromey <tom@tromey.com>
11749
11750 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
11751 destructor. Now a class.
11752 (gdb_readline_wrapper_cleanup): Remove function.
11753 (gdb_readline_wrapper): Remove cleanups.
11754
11755 2018-03-27 Tom Tromey <tom@tromey.com>
11756
11757 * typeprint.h (struct type_print_options) <local_typedefs,
11758 global_typedefs>: Remove "struct" keyword.
11759 (class typedef_hash_table): New class.
11760 (recursively_update_typedef_hash, add_template_parameters)
11761 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
11762 (find_typedef_in_hash): Don't declare.
11763 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
11764 (typedef_hash_table::recursively_update): Rename from
11765 recursively_update_typedef_hash. Now a member.
11766 (typedef_hash_table::add_template_parameters): Rename from
11767 add_template_parameters. Now a member.
11768 (typedef_hash_table::typedef_hash_table): Now a constructor;
11769 rename from create_typedef_hash.
11770 (typedef_hash_table::~typedef_hash_table): Now a destructor;
11771 rename from free_typedef_hash.
11772 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
11773 (do_free_global_table): Remove.
11774 (typedef_hash_table::typedef_hash_table): New constructor; renamed
11775 from copy_type_recursive.
11776 (create_global_typedef_table): Remove.
11777 (typedef_hash_table::find_global_typedef): Now a member of
11778 typedef_hash_table.
11779 (typedef_hash_table::find_typedef): Rename from
11780 find_typedef_in_hash; now a member.
11781 (whatis_exp): Update.
11782 * extension.h (struct ext_lang_type_printers): Add constructor and
11783 destructor.
11784 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
11785 declare.
11786 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
11787 Now a constructor; rename from start_ext_lang_type_printers.
11788 (ext_lang_type_printers): Now a destructor; rename from
11789 free_ext_lang_type_printers.
11790 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
11791 Update.
11792 (c_type_print_base_struct_union): Update. Remove cleanups.
11793
11794 2018-03-27 Tom Tromey <tom@tromey.com>
11795
11796 * dwarf-index-write.c: Include <cmath>.
11797
11798 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11799
11800 * NEWS: Add entry describing new "set|show varsize-limit" command.
11801 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
11802 command.
11803 * printcmd.c (_initialize_printcmd): Add "set var" alias of
11804 "set variable".
11805
11806 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
11807
11808 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
11809 dwarf-index-write.c
11810 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
11811 * dwarf-index-common.c: New file.
11812 * dwarf-index-common.h: New file.
11813 * dwarf-index-write.c: New file.
11814 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
11815 (struct dwarf2_section_info): Move from here.
11816 (dwarf2_section_info_def): Likewise.
11817 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
11818 (offset_type): Likewise.
11819 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
11820 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
11821 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
11822 (byte_swap): Likewise.
11823 (MAYBE_SWAP): Likewise.
11824 (dwarf2_per_cu_ptr): Likewise.
11825 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
11826 (struct tu_stats): Likewise.
11827 (struct dwarf2_per_objfile): Likewise.
11828 (struct dwarf2_per_cu_data): Likewise.
11829 (struct signatured_type): Likewise.
11830 (sig_type_ptr): Likewise.
11831 (DEF_VEC_P (sig_type_ptr)): Likewise.
11832 (INDEX4_SUFFIX): Likewise.
11833 (INDEX5_SUFFIX): Likewise.
11834 (DEBUG_STR_SUFFIX): Likewise.
11835 (dwarf2_read_section): Make non-static.
11836 (mapped_index_string_hash): Move from here.
11837 (dwarf5_djb_hash): Likewise.
11838 (file_write): Likewise.
11839 (class data_buf): Likewise.
11840 (struct symtab_index_entry): Likewise.
11841 (struct mapped_symtab): Likewise.
11842 (find_slot): Likewise.
11843 (hash_expand): Likewise.
11844 (add_index_entry): Likewise.
11845 (uniquify_cu_indices): Likewise.
11846 (class c_str_view): Likewise.
11847 (class c_str_view_hasher): Likewise.
11848 (class vector_hasher): Likewise.
11849 (write_hash_table): Likewise.
11850 (psym_index_map): Likewise.
11851 (struct addrmap_index_data): Likewise.
11852 (add_address_entry): Likewise.
11853 (add_address_entry_worker): Likewise.
11854 (write_address_map): Likewise.
11855 (symbol_kind): Likewise.
11856 (write_psymbols): Likewise.
11857 (struct signatured_type_index_data): Likewise.
11858 (write_one_signatured_type): Likewise.
11859 (recursively_count_psymbols): Likewise.
11860 (recursively_write_psymbols): Likewise.
11861 (class debug_names): Likewise.
11862 (check_dwarf64_offsets): Likewise.
11863 (psyms_seen_size): Likewise.
11864 (write_gdbindex): Likewise.
11865 (write_debug_names): Likewise.
11866 (assert_file_size): Likewise.
11867 (write_psymtabs_to_index): Likewise.
11868 (save_gdb_index_command): Likewise.
11869 (_initialize_dwarf2_read): Don't register the "save gdb-index"
11870 command.
11871 * dwarf2read.h: New file.
11872
11873 2018-03-27 Joel Brobecker <brobecker@adacore.com>
11874
11875 PR gdb/22670
11876 * dwarf2read.c (dwarf2_physname): Do not return the demangled
11877 symbol name if the CU's language stores symbol names in linkage
11878 format.
11879 * language.h (struct language_defn)
11880 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
11881 all instances of this struct.
11882
11883 2018-03-26 Tom Tromey <tom@tromey.com>
11884
11885 * stack.c (backtrace_command_1): Remove verbose code.
11886
11887 2018-03-26 Tom Tromey <tom@tromey.com>
11888
11889 * python/py-framefilter.c (py_print_type): Don't catch
11890 exceptions. Return void.
11891 (py_print_value): Likewise.
11892 (py_print_single_arg): Likewise.
11893 (enumerate_args): Don't catch exceptions.
11894 (py_print_args): Likewise.
11895 (py_print_frame): Likewise.
11896 (gdbpy_apply_frame_filter): Catch exceptions here.
11897
11898 2018-03-26 Tom Tromey <tom@tromey.com>
11899
11900 * stack.c (_initialize_stack): Remove trailing newlines from help
11901 text. Add "Usage" line to "backtrace" help.
11902
11903 2018-03-26 Tom Tromey <tom@tromey.com>
11904
11905 PR python/16486:
11906 * python/py-framefilter.c (py_print_args): Call wrap_hint.
11907
11908 2018-03-26 Tom Tromey <tom@tromey.com>
11909
11910 * python/py-framefilter.c (py_print_single_arg): Return
11911 EXT_LANG_BT_ERROR from catch.
11912
11913 2018-03-26 Tom Tromey <tom@tromey.com>
11914
11915 PR backtrace/15584:
11916 * stack.c (backtrace_command_1): Move some code into no-filters
11917 "if".
11918
11919 2018-03-26 Tom Tromey <tom@tromey.com>
11920
11921 * python/py-framefilter.c (throw_quit_or_print_exception): New
11922 function.
11923 (gdbpy_apply_frame_filter): Use it.
11924
11925 2018-03-26 Tom Tromey <tom@tromey.com>
11926
11927 PR cli/17716:
11928 * python/py-framefilter.c (py_print_type, py_print_value)
11929 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
11930 RETURN_MASK_ERROR.
11931
11932 2018-03-26 Tom Tromey <tom@tromey.com>
11933
11934 * python/py-framefilter.c (enumerate_args): Use
11935 gdb::unique_xmalloc_ptr.
11936
11937 2018-03-26 Tom Tromey <tom@tromey.com>
11938
11939 * python/py-framefilter.c (py_print_frame): Return
11940 EXT_LANG_BT_OK.
11941 (gdbpy_apply_frame_filter): Update comment.
11942 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
11943 Remove.
11944 <EXT_LANG_BT_NO_FILTERS>: Change value.
11945
11946 2018-03-26 Tom Tromey <tom@tromey.com>
11947
11948 PR backtrace/15582:
11949 * stack.c (backtrace_command): Parse "hide" argument.
11950 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
11951 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
11952 constant.
11953
11954 2018-03-26 Tom Tromey <tom@tromey.com>
11955
11956 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
11957 add "flags".
11958 (backtrace_command): Remove "fulltrace", add "flags".
11959
11960 2018-03-26 Tom Tromey <tom@tromey.com>
11961
11962 * stack.c (backtrace_command): Rewrite command line parsing.
11963
11964 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11965
11966 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
11967
11968 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
11969
11970 * filename-seen-cache.h: Add include guard.
11971
11972 2018-03-26 Keith Seitz <keiths@redhat.com>
11973
11974 * symfile.c (place_section): Remove "struct" from section_addr_info
11975 in comment.
11976 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
11977 "struct" keyword from section_addr_info.
11978
11979 2018-03-26 Alan Hayward <alan.hayward@arm.com>
11980
11981 * regformats/regdef.h (reg): Add constructors.
11982
11983 2018-03-25 Pedro Alves <palves@redhat.com>
11984
11985 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
11986 if then/else bodies in var_func_name extraction.
11987
11988 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
11989
11990 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
11991 lookup_minimal_symbol() to find symbol entry.
11992 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
11993
11994 2018-03-23 Keith Seitz <keiths@redhat.com>
11995
11996 PR c++/22968
11997 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
11998 nested type definitions for C++, too.
11999
12000 2018-03-23 Tom Tromey <tom@tromey.com>
12001
12002 * machoread.c (struct oso_el): Add a constructor. Don't define as
12003 a typedef.
12004 (macho_register_oso): Remove.
12005 (macho_symtab_read): Take a std::vector.
12006 (oso_el_compare_name): Now a std::sort comparator.
12007 (macho_symfile_read_all_oso): Take a std::vector.
12008 (macho_symfile_read): Use std::vector. Remove cleanups.
12009
12010 2018-03-22 Tom Tromey <tom@tromey.com>
12011
12012 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
12013 (record_full_goto_bookmark): Use std::string.
12014
12015 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12016
12017 PR tdep/18295
12018 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
12019 a single mask.
12020
12021 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12022
12023 * rs6000-tdep.c (store_insn_p): New function.
12024 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
12025 and cr_reg to their unshifted values. Use store_insn_p to
12026 match LR saves using either R1 or fdata->alloca_reg. Use
12027 store_insn_p to match CR saves. Set alloca_reg_offset
12028 when alloca_reg and framep are set. Remove lr_reg shift
12029 when assigning to fdata->lr_register.
12030
12031 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
12032
12033 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
12034 command line args instead of emitting a warning.
12035
12036 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12037
12038 * tracepoint.h (struct static_tracepoint_marker): Initialize
12039 fields, define default constructor, move constructor and move
12040 assignment, disable the rest.
12041 <str_id, extra>: Make std::string.
12042 (release_static_tracepoint_marker): Remove.
12043 (free_current_marker): Remove.
12044 * tracepoint.c (free_current_marker): Remove.
12045 (parse_static_tracepoint_marker_definition): Adjust to
12046 std::string, use new hex2str overload.
12047 (release_static_tracepoint_marker): Remove.
12048 (print_one_static_tracepoint_marker): Get marker by reference
12049 and adjust to std::string.
12050 (info_static_tracepoint_markers_command): Adjust to std::vector
12051 changes
12052 * target.h (static_tracepoint_marker_p): Remove typedef.
12053 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
12054 (struct target_ops) <to_static_tracepoint_marker_at>: Return
12055 bool.
12056 <to_static_tracepoint_markers_by_strid>: Return std::vector.
12057 * target-debug.h
12058 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
12059 (target_debug_print_std_vector_static_tracepoint_marker): New.
12060 (target_debug_print_struct_static_tracepoint_marker_p): Rename
12061 to...
12062 (target_debug_print_static_tracepoint_marker_p): ... this.
12063 * target-delegates.c: Re-generate.
12064 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
12065 Make std::string.
12066 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
12067 (decode_static_tracepoint_spec): Adjust to std::vector.
12068 (tracepoint_print_one_detail): Adjust to std::string.
12069 (strace_marker_decode_location): Adjust to std::string.
12070 (update_static_tracepoint): Adjust to std::string, remove call
12071 to release_static_tracepoint_marker.
12072 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
12073 Adjust to std::vector.
12074 * remote.c (remote_static_tracepoint_marker_at): Return bool.
12075 (remote_static_tracepoint_markers_by_strid): Adjust to
12076 std::vector.
12077 * common/rsp-low.h (hex2str): New overload with explicit count
12078 of bytes.
12079 * common/rsp-low.c (hex2str): New overload with explicit count
12080 of bytes.
12081 * unittests/rsp-low-selftests.c (test_hex2str): New function.
12082 (_initialize_rsp_low_selftests): Add test_hex2str test.
12083 * unittests/tracepoint-selftests.c
12084 (test_parse_static_tracepoint_marker_definition): Adjust to
12085 std::string.
12086
12087 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12088
12089 * tracepoint.c (parse_static_tracepoint_marker_definition):
12090 Consider case where the definition is followed by more
12091 definitions.
12092 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12093 tracepoint-selftests.c.
12094 * unittests/tracepoint-selftests.c: New.
12095
12096 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
12097
12098 * MAINTAINERS (Write After Approval): Add Pedro Franco de
12099 Carvalho.
12100
12101 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
12102
12103 * symtab.c (find_pc_sect_line): fixed indentation.
12104
12105 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
12106
12107 * symtab.c (find_pc_sect_line): now uses binary search.
12108
12109 2018-03-19 Tom Tromey <tom@tromey.com>
12110
12111 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
12112 "IDENT" production.
12113
12114 2018-03-19 Pedro Alves <palves@redhat.com>
12115 Tom Tromey <tom@tromey.com>
12116
12117 * unittests/observable-selftests.c: New file.
12118 * common/observable.h: New file.
12119 * observable.h: New file.
12120 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
12121 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
12122 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
12123 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
12124 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
12125 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
12126 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
12127 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
12128 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
12129 python/py-breakpoint.c, python/py-finishbreakpoint.c,
12130 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
12131 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
12132 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
12133 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
12134 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
12135 tui/tui-interp.c, valops.c: Update all users.
12136 * tui/tui-hooks.c (tui_bp_created_observer)
12137 (tui_bp_deleted_observer, tui_bp_modified_observer)
12138 (tui_inferior_exit_observer, tui_before_prompt_observer)
12139 (tui_normal_stop_observer, tui_register_changed_observer):
12140 Remove.
12141 (tui_observers_token): New global.
12142 (attach_or_detach, tui_attach_detach_observers): New functions.
12143 (tui_install_hooks, tui_remove_hooks): Use
12144 tui_attach_detach_observers.
12145 * record-btrace.c (record_btrace_thread_observer): Remove.
12146 (record_btrace_thread_observer_token): New global.
12147 * observer.sh: Remove.
12148 * observer.c: Rename to observable.c.
12149 * observable.c (namespace gdb_observers): Define new objects.
12150 (observer_debug): Move into gdb_observers namespace.
12151 (struct observer, struct observer_list, xalloc_observer_list_node)
12152 (xfree_observer_list_node, generic_observer_attach)
12153 (generic_observer_detach, generic_observer_notify): Remove.
12154 (_initialize_observer): Update.
12155 Don't include observer.inc.
12156 * Makefile.in (generated_files): Remove observer.h, observer.inc.
12157 (clean mostlyclean): Likewise.
12158 (observer.h, observer.inc): Remove targets.
12159 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
12160 (COMMON_SFILES): Use observable.c, not observer.c.
12161 * .gitignore: Remove observer.h.
12162
12163 2018-03-18 Tom Tromey <tom@tromey.com>
12164
12165 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
12166 gdb::def_vector.
12167 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
12168
12169 2018-03-17 Tom Tromey <tom@tromey.com>
12170
12171 * auto-load.c (auto_load_objfile_script_1): Use std::string.
12172
12173 2018-03-17 Tom Tromey <tom@tromey.com>
12174
12175 * target.c (class scoped_target_fd): New.
12176 (target_fileio_close_cleanup): Remove.
12177 (target_fileio_read_alloc_1): Use scoped_target_fd.
12178
12179 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
12180
12181 * silent-rules.mk: New.
12182 * Makefile.in: Include silent-rules.mk
12183 (srcdir, VPATH, top_srcdir): Move up.
12184 (COMPILE): Add ECHO_CXX.
12185 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
12186 (init.c): Add ECHO_INIT_C.
12187 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
12188 (version.c): Add ECHO_GEN.
12189 (printcmd.o): Add ECHO_CXX.
12190 (target-float.o): Add ECHO_CXX.
12191 (ada-exp.o): Add ECHO_CXX.
12192 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
12193 (insight$(EXEEXT)): Add ECHO_CXXLD.
12194 * gnulib/configure.ac: Add AM_SILENT_RULES.
12195 * gnulib/aclocal.m4: Re-generate.
12196 * gnulib/configure: Re-generate.
12197 * gnulib/import/Makefile.in: Re-generate.
12198
12199 2018-03-16 Tom Tromey <tom@tromey.com>
12200
12201 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
12202 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
12203 * utils.c (do_free_section_addr_info)
12204 (make_cleanup_free_section_addr_info): Remove.
12205 * symfile.h (struct other_sections): Add constructor.
12206 (struct section_addr_info): Remove.
12207 (section_addr_info): New typedef.
12208 (struct sym_fns) <sym_offsets>: Change type of parameter.
12209 (build_section_addr_info_from_objfile)
12210 (relative_addr_info_to_section_offsets, addr_info_make_relative)
12211 (default_symfile_offsets, symbol_file_add)
12212 (symbol_file_add_from_bfd)
12213 (build_section_addr_info_from_section_table): Update.
12214 (alloc_section_addr_info, free_section_addr_info): Don't declare.
12215 * symfile.c (alloc_section_addr_info): Remove.
12216 (build_section_addr_info_from_section_table): Change return type.
12217 Update.
12218 (build_section_addr_info_from_bfd)
12219 (build_section_addr_info_from_objfile): Likewise.
12220 (free_section_addr_info): Remove.
12221 (relative_addr_info_to_section_offsets): Change type of "addrs".
12222 (addrs_section_compar): Now a std::sort comparator.
12223 (addrs_section_sort): Change return type.
12224 (addr_info_make_relative): Change type of "addrs". Update.
12225 (default_symfile_offsets, syms_from_objfile_1)
12226 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
12227 (symbol_file_add_separate): Update.
12228 (symbol_file_add): Change type of "addrs". Update.
12229 (add_symbol_file_command): Update. Remove cleanups.
12230 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
12231 cleanups.
12232 * symfile-debug.c (debug_sym_offsets): Change type of "info".
12233 * solib.c (solib_read_symbols): Update.
12234 * objfiles.c (objfile_relocate): Update. Remove cleanups.
12235 * machoread.c (macho_symfile_offsets): Update.
12236 * jit.c (jit_bfd_try_read_symtab): Update.
12237
12238 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
12239
12240 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12241 unittests/utils-selftests.c.
12242 * unittests/utils-selftests.c: New file.
12243
12244 2018-03-14 Tom Tromey <tom@tromey.com>
12245
12246 PR cli/14977:
12247 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
12248 for NULL.
12249
12250 2018-03-14 Tom Tromey <tom@tromey.com>
12251
12252 PR cli/19918:
12253 * printcmd.c (printf_pointer): Allow "-" in format.
12254
12255 2018-03-14 Tom Tromey <tom@tromey.com>
12256
12257 * printcmd.c (_initialize_printcmd): Add usage to printf.
12258
12259 2018-03-14 Yao Qi <qiyao@sourceware.org>
12260
12261 * MAINTAINERS: Update my email address.
12262
12263 2018-03-13 Tom Tromey <tom@tromey.com>
12264
12265 * machoread.c (macho_check_dsym): Change filenamep to a
12266 std::string*.
12267 (macho_symfile_read): Update.
12268 * symfile.c (load_command): Use std::string.
12269
12270 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
12271
12272 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
12273 to error message string.
12274 (riscv_register_name): Use xsnprintf instead of sprintf.
12275 (riscv_insn::fetch_instruction): Use gdb_assert instead of
12276 internal_error.
12277 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
12278 error.
12279 (riscv_push_dummy_call): Likewise.
12280
12281 2018-03-12 Tom Tromey <tom@tromey.com>
12282
12283 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
12284 Use gdb::byte_vector.
12285 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
12286
12287 2018-03-12 Yao Qi <yao.qi@linaro.org>
12288
12289 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
12290 parameter type to readable_regcache.
12291 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
12292 the declaration.
12293
12294 2018-03-11 Tom Tromey <tom@tromey.com>
12295
12296 * dwarf2read.c (struct nextfield): Add initializers.
12297 (struct nextfnfield): Remove.
12298 (struct fnfieldlist): Add initializers. Remove "length" and
12299 "head", use std::vector.
12300 (struct decl_field_list): Remove.
12301 (struct field_info): Add initializers.
12302 <fields, baseclasses>: Now std::vector.
12303 <nbaseclasses, nfnfields, typedef_field_list_count,
12304 nested_types_list_count>: Remove.
12305 (dwarf2_add_field, dwarf2_add_type_defn)
12306 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
12307 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
12308 (process_structure_scope): Update.
12309
12310 2018-03-11 Tom Tromey <tom@tromey.com>
12311
12312 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
12313 for use by std::sort.
12314 (build_type_psymtabs_1): Use std::vector.
12315
12316 2018-03-09 Eli Zaretskii <eliz@gnu.org>
12317
12318 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
12319 and LIBMPFR in the printed configuration.
12320
12321 2018-03-08 Tom Tromey <tom@tromey.com>
12322
12323 * source.c (get_filename_and_charpos): Use scoped_fd.
12324 * nto-procfs.c (procfs_open_1): Use scoped_fd.
12325 (procfs_pidlist): Likewise.
12326 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
12327 (iterate_over_mappings): Likewise.
12328
12329 2018-03-08 Tom Tromey <tom@tromey.com>
12330
12331 * infcall.c (struct call_return_meta_info)
12332 <stack_temporaries_enabled>: Remove.
12333 (get_call_return_value, call_function_by_hand_dummy): Update.
12334 * thread.c (disable_thread_stack_temporaries): Remove.
12335 (enable_thread_stack_temporaries): Remove.
12336 (thread_stack_temporaries_enabled_p): Return bool.
12337 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
12338 (get_last_thread_stack_temporary): Update.
12339 * eval.c (evaluate_subexp): Update.
12340 * gdbthread.h (class enable_thread_stack_temporaries): Now a
12341 class, not a function.
12342 (value_ptr, value_vec): Remove typedefs.
12343 (class thread_info) <stack_temporaries_enabled>: Now bool.
12344 <stack_temporaries>: Now a std::vector.
12345 (thread_stack_temporaries_enabled_p)
12346 (value_in_thread_stack_temporaries): Return bool.
12347
12348 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
12349
12350 * remote.c (putpkt_binary): Fix omitted bytes reporting.
12351 (getpkt_or_notif_sane_1): Likewise.
12352
12353 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12354
12355 * build-id.c (build_id_to_debug_bfd): Use std::string.
12356
12357 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12358
12359 * build-id.c (find_separate_debug_file_by_buildid): Return
12360 std::string.
12361 * build-id.h (find_separate_debug_file_by_buildid): Return
12362 std::string.
12363 * coffread.c (coff_symfile_read): Adjust to std::string.
12364 * elfread.c (elf_symfile_read): Adjust to std::string.
12365 * symfile.c (separate_debug_file_exists): Change parameter to
12366 std::string.
12367 (find_separate_debug_file): Return std::string.
12368 (find_separate_debug_file_by_debuglink): Return std::string.
12369 * symfile.h (find_separate_debug_file_by_debuglink): Return
12370 std::string.
12371
12372 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
12373
12374 * common/xml-utils.c (xml_escape_text): Move code to...
12375 (xml_escape_text_append): ... this new function.
12376 * common/xml-utils.h (xml_escape_text_append): New declaration.
12377 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
12378 New function.
12379 (_initialize_xml_utils): register test_xml_escape_text_append as
12380 a selftest.
12381
12382 2018-03-07 Alan Hayward <alan.hayward@arm.com>
12383
12384 * defs.h: Remove MAX_REGISTER_SIZE.
12385 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
12386 asserts.
12387 * python/py-unwind.c (pyuw_sniffer): Likewise.
12388
12389 2018-03-07 Tom Tromey <tom@tromey.com>
12390
12391 * linux-tdep.c (linux_info_proc): Update.
12392 * target.h (struct target_ops) <to_fileio_readlink>: Return
12393 optional<string>.
12394 (target_fileio_readlink): Return optional<string>.
12395 * remote.c (remote_hostio_readlink): Return optional<string>.
12396 * inf-child.c (inf_child_fileio_readlink): Return
12397 optional<string>.
12398 * target.c (target_fileio_readlink): Return optional<string>.
12399
12400 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
12401
12402 * regcache.c (cooked_read_test): Add riscv to the list of
12403 architectures that have a save_reggroup.
12404
12405 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
12406
12407 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
12408 value is not a dynamic class object.
12409
12410 2018-03-06 Tom Tromey <tom@tromey.com>
12411
12412 * rust-exp.y: Formatting fixes.
12413
12414 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12415
12416 * riscv-tdep.c (riscv_register_name): Remove target description
12417 support.
12418 (riscv_gdbarch_init): Remove target description check.
12419
12420 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12421
12422 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
12423 comment.
12424 * riscv-tdep.h: Likewise.
12425
12426 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12427
12428 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
12429 (riscv_pseudo_register_write): Delete.
12430 (riscv_gdbarch_init): Remove all use of pseudo registers.
12431
12432 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12433
12434 * record-btrace.c (btrace_print_lines): Replace cleanup
12435 parameter with RAII equivalents.
12436 (btrace_insn_history): Replace cleanup with RAII equivalents.
12437 * ui-out.h (make_cleanup_ui_out_list_begin_end,
12438 make_cleanup_ui_out_tuple_begin_end): Remove.
12439 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
12440 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
12441 make_cleanup_ui_out_list_begin_end): Remove.
12442
12443 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12444
12445 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
12446 parameter types to std::vector. Use bool.
12447 (record_btrace_wait): Replace VEC(tp_t) with
12448 std::vector<thread_info *>.
12449 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
12450
12451 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
12452
12453 * record-btrace.c (record_btrace_disable_callback): Remove.
12454 (struct scoped_btrace_disable): New.
12455 (record_btrace_open): Use scoped_btrace_disable.
12456
12457 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12458
12459 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
12460 reading values from registers.
12461
12462 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12463
12464 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
12465 where appropriate.
12466
12467 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12468
12469 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
12470 change parameter type. Use GDB's print functions, and use
12471 core_addr_to_string where appropriate.
12472 (riscv_push_dummy_call): Use core_addr_to_string where
12473 appropriate, update call to riscv_print_arg_location, and reindent
12474 a few lines.
12475 (riscv_return_value): Update call to riscv_print_arg_location.
12476
12477 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12478 Tim Newsome <tim@sifive.com>
12479 Albert Ou <a0u@eecs.berkeley.edu>
12480 Darius Rad <darius@bluespec.com>
12481
12482 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
12483 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
12484 (ALLDEPFILES): Add riscv-tdep.c
12485 * configure.tgt: Add riscv support.
12486 * riscv-tdep.c: New file.
12487 * riscv-tdep.h: New file.
12488 * NEWS: Mention new target.
12489 * MAINTAINERS: Add entry for riscv.
12490
12491 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
12492
12493 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
12494 fields within aggregates.
12495
12496 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
12497
12498 * record-btrace.c (btrace_print_lines): Change type of flags to
12499 gdb_disassembly_flags.
12500
12501 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12502
12503 * fbsd-nat.c: Include "inf-ptrace.h".
12504 (USE_SIGTRAP_SIGINFO): Conditionally define.
12505 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
12506 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
12507 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
12508 function.
12509 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
12510 Likewise.
12511 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
12512 Likewise.
12513 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
12514 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
12515 "supports_stopped_by_hw_breakpoint" target methods.
12516
12517 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12518
12519 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
12520 * fbsd-nat.c (debug_fbsd_nat): New variable.
12521 (show_fbsd_nat_debug): New function.
12522 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
12523 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
12524
12525 2018-03-04 John Baldwin <jhb@FreeBSD.org>
12526
12527 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
12528 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
12529 prototype.
12530 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
12531 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
12532 method.
12533
12534 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12535
12536 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
12537 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
12538
12539 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12540
12541 * charset.c (struct charset_vector): New.
12542 (charsets): Change type to charset_vector.
12543 (find_charset_names): Adjust.
12544 (add_one): Adjust.
12545 (_initialize_charset): Adjust.
12546
12547 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12548
12549 * progspace.h (struct program_space) <deleted_solibs>: Change
12550 type to std::vector<std::string>.
12551 * progspace.c (clear_program_space_solib_cache): Adjust.
12552 * breakpoint.c (print_solib_event): Adjust.
12553 (check_status_catch_solib): Adjust.
12554 * solib.c (update_solib_list): Adjust.
12555 * ui-out.h (class ui_out) <field_string>: New overload.
12556 * ui-out.c (ui_out::field_string): New overload.
12557
12558 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12559
12560 * progspace.h (struct program_space): Add constructor and
12561 destructor, initialize fields.
12562 (add_program_space): Remove.
12563 * progspace.c (add_program_space): Rename to...
12564 (program_space::program_space): ... this.
12565 (release_program_space): Rename to...
12566 (program_space::~program_space): ... this.
12567 (delete_program_space): Use delete to delete program_space.
12568 (initialize_progspace): Use new to allocate program_space.
12569 * inferior.c (add_inferior_with_spaces): Likewise.
12570 (clone_inferior_command): Likewise.
12571 * infrun.c (follow_fork_inferior): Likewise.
12572 (handle_vfork_child_exec_or_exit): Likewise.
12573
12574 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
12575
12576 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
12577 (delim_string_to_char_ptr_vec): Return std::vector of
12578 gdb::unique_xmalloc_ptr.
12579 (dirnames_to_char_ptr_vec_append): Take std::vector of
12580 gdb::unique_xmalloc_ptr.
12581 (dirnames_to_char_ptr_vec): Return std::vector of
12582 gdb::unique_xmalloc_ptr.
12583 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
12584 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
12585 (delim_string_to_char_ptr_vec): Return an std::vector of
12586 gdb::unique_xmalloc_ptr, adjust the code.
12587 (dirnames_to_char_ptr_vec_append): Take an std::vector of
12588 gdb::unique_xmalloc_ptr, adjust the code.
12589 (dirnames_to_char_ptr_vec): Return an std::vector of
12590 gdb::unique_xmalloc_ptr, adjust the code.
12591 * auto-load.c (auto_load_safe_path_vec): Change type to
12592 std::vector of gdb::unique_xmalloc_ptr.
12593 (auto_load_expand_dir_vars): Return an std::vector of
12594 gdb::unique_xmalloc_ptr, adjust the code.
12595 (auto_load_safe_path_vec_update): Adjust.
12596 (filename_is_in_auto_load_safe_path_vec): Adjust.
12597 (auto_load_objfile_script_1): Adjust.
12598 * build-id.c (build_id_to_debug_bfd): Adjust.
12599 * linux-thread-db.c (thread_db_load_search): Adjust.
12600 * source.c (add_path): Adjust.
12601 (openp): Adjust.
12602 * symfile.c (find_separate_debug_file): Adjust.
12603 * utils.c (do_free_char_ptr_vec): Remove.
12604 (make_cleanup_free_char_ptr_vec): Remove.
12605
12606 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
12607
12608 PR gdb/22907
12609 * common/pathstuff.c: Conditionally include "<windows.h>".
12610
12611 2018-03-01 Georg Sauthoff <mail@georg.so>
12612
12613 PR gdb/22888
12614 * gcore.in: Quote variables and switch interpreter to bash.
12615
12616 2018-03-01 Tom Tromey <tom@tromey.com>
12617
12618 * dwarf2read.c (alloc_discriminant_info): Fix default_index
12619 assertion. Add assertion for discriminant_index.
12620 (quirk_rust_enum): Use correct base type name in univariant case.
12621
12622 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
12623
12624 * record.c (get_call_history_modifiers): Return a
12625 record_print_flags.
12626 (cmd_record_call_history): Adjust.
12627 * record-btrace.c (record_btrace_call_history): Adjust.
12628 (record_btrace_call_history_range): Adjust.
12629 (record_btrace_call_history_from): Adjust.
12630 * target-debug.h (target_debug_print_record_print_flags): New.
12631 * target-delegates.c: Re-generate.
12632 * target.c (target_call_history): Change flags type.
12633 (target_call_history_from): Likewise.
12634 (target_call_history_range): Likewise.
12635 * target.h (struct target_ops) <target_call_history>: Likewise.
12636 (target_call_history_from): Likewise.
12637 (target_call_history_range): Likewise.
12638
12639 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12640 Simon Marchi <simon.marchi@polymtl.ca>
12641
12642 * common/common-utils.c: Include "sys/stat.h".
12643 (is_regular_file): Move here from "source.c"; change return
12644 type to "bool".
12645 * common/common-utils.h (is_regular_file): New prototype.
12646 * common/pathstuff.c (contains_dir_separator): New function.
12647 * common/pathstuff.h (contains_dir_separator): New prototype.
12648 * source.c: Don't include "sys/stat.h".
12649 (is_regular_file): Move to "common/common-utils.c".
12650
12651 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
12652
12653 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
12654 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
12655 * auto-load.c: Include "common/pathstuff.h".
12656 * common/common-def.h (current_directory): Move here.
12657 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
12658 function.
12659 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
12660 prototype.
12661 * common/pathstuff.c: New file.
12662 * common/pathstuff.h: New file.
12663 * compile/compile.c: Include "common/pathstuff.h".
12664 * defs.h (current_directory): Move to "common/common-defs.h".
12665 * dwarf2read.c: Include "common/pathstuff.h".
12666 * exec.c: Likewise.
12667 * guile/scm-safe-call.c: Likewise.
12668 * linux-thread-db.c: Likewise.
12669 * main.c: Likewise.
12670 * nto-tdep.c: Likewise.
12671 * objfiles.c: Likewise.
12672 * source.c: Likewise.
12673 * symtab.c: Likewise.
12674 * utils.c: Include "common/pathstuff.h".
12675 (gdb_realpath): Move to "common/pathstuff.c".
12676 (gdb_realpath_keepfile): Likewise.
12677 (gdb_abspath): Likewise.
12678 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
12679 (gdb_realpath_keepfile): Likewise.
12680 (gdb_abspath): Likewise.
12681
12682 2018-02-28 John Baldwin <jhb@FreeBSD.org>
12683
12684 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
12685 wildcard process pid for super_resume for kernels with a
12686 specific bug.
12687
12688 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
12689
12690 * compile/compile.c (get_args): Add additional comments
12691 explaining function.
12692
12693 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
12694 Tom Tromey <tom@tromey.com>
12695
12696 * target.h (memory_write_request_s): Remove typedef. Don't define
12697 VEC.
12698 (target_write_memory_blocks): Change argument to std::vector.
12699 (struct memory_write_request): Add constructor.
12700 * target-memory.c (compare_block_starting_address): Return bool.
12701 Change argument types.
12702 (claim_memory): Change arguments to use std::vector.
12703 (split_regular_and_flash_blocks, blocks_to_erase)
12704 (compute_garbled_blocks): Likewise.
12705 (cleanup_request_data, cleanup_write_requests_vector): Remove.
12706 (target_write_memory_blocks): Change argument to std::vector.
12707 * symfile.c (struct load_section_data): Add constructor and
12708 destructor. Use std::vector for "requests".
12709 (struct load_progress_data): Add initializers.
12710 (load_section_callback): Update. Use "new".
12711 (clear_memory_write_data): Remove.
12712 (generic_load): Update.
12713
12714 2018-02-27 Alan Hayward <alan.hayward@arm.com>
12715
12716 * arch/aarch64.h: Use common/tdesc.h.
12717
12718 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12719
12720 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
12721 architecture with a 64-bit ABI.
12722
12723 2018-02-26 Maciej W. Rozycki <macro@mips.com>
12724
12725 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
12726 ahead of target description loading.
12727
12728 2018-02-26 Tom Tromey <tom@tromey.com>
12729
12730 * stack.c (backtrace_command_1): Update.
12731 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
12732 of "flags".
12733 * python/py-framefilter.c (py_print_frame)
12734 (gdbpy_apply_frame_filter): Change type of "flags".
12735 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
12736 of "flags".
12737 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
12738 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
12739 * extension.h (enum frame_filter_flag): Rename from
12740 frame_filter_flags.
12741 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
12742 (apply_ext_lang_frame_filter): Change type of "flags".
12743 * extension.c (apply_ext_lang_frame_filter): Change type of
12744 "flags".
12745 * extension-priv.h (struct extension_language_ops)
12746 <apply_frame_filter>: Change type of "flags".
12747
12748 2018-02-26 Tom Tromey <tom@tromey.com>
12749
12750 PR python/16497:
12751 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
12752 off-by-one in py_end computation.
12753 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
12754 PRINT_MORE_FRAMES.
12755 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
12756 constant.
12757
12758 2018-02-26 Tom Tromey <tom@tromey.com>
12759
12760 * dwarf2read.c (struct variant_field): New.
12761 (struct nextfield) <variant>: New field.
12762 (dwarf2_add_field): Handle DW_TAG_variant_part.
12763 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
12764 discriminated union.
12765 (read_structure_type): Handle DW_TAG_variant_part.
12766 (handle_struct_member_die): New function, extracted from
12767 process_structure_scope. Handle DW_TAG_variant.
12768 (process_structure_scope): Handle discriminated unions. Call
12769 handle_struct_member_die.
12770
12771 2018-02-26 Tom Tromey <tom@tromey.com>
12772
12773 * rust-lang.h (rust_last_path_segment): Declare.
12774 * rust-lang.c (rust_last_path_segment): Now public. Change
12775 contract.
12776 (struct disr_info): Remove.
12777 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
12778 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
12779 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
12780 (rust_enum_p, rust_enum_variant): New function.
12781 (rust_underscore_fields): Remove "offset" parameter.
12782 (rust_print_enum): New function.
12783 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
12784 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
12785 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
12786 enums.
12787 (rust_internal_print_type): New function, from rust_print_type.
12788 Remove enum code.
12789 (rust_print_type): Call rust_internal_print_type.
12790 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
12791 Update enum handling.
12792 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
12793 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
12794 (rust_union_quirks): New functions.
12795 (process_full_comp_unit, process_full_type_unit): Call
12796 rust_union_quirks.
12797 (process_structure_scope): Update rust_unions if necessary.
12798
12799 2018-02-26 Tom Tromey <tom@tromey.com>
12800
12801 * value.h (value_union_variant): Declare.
12802 * valops.c (value_union_variant): New function.
12803 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
12804 (struct discriminant_info): New.
12805 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
12806 enumerator.
12807 (struct main_type) <flag_discriminated_union>: New field.
12808
12809 2018-02-26 Tom Tromey <tom@tromey.com>
12810
12811 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12812 unittests/unpack-selftests.c.
12813 * unittests/unpack-selftests.c: New file.
12814 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
12815
12816 2018-02-26 Yao Qi <yao.qi@linaro.org>
12817
12818 * dwarf2read.c (struct partial_die_info) <read>: New method.
12819 (read_partial_die): Remove the declaration.
12820 (load_partial_dies): Update.
12821 (partial_die_info::partial_die_info):
12822 (read_partial_die): Change it to partial_die_info::read.
12823
12824 2018-02-26 Yao Qi <yao.qi@linaro.org>
12825
12826 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
12827 (fixup_partial_die): Remove declaration.
12828 (scan_partial_symbols): Update.
12829 (partial_die_parent_scope): Likewise.
12830 (partial_die_full_name): Likewise.
12831 (fixup_partial_die): Change it to partial_die_info::fixup.
12832
12833 2018-02-26 Yao Qi <yao.qi@linaro.org>
12834
12835 * dwarf2read.c (read_partial_die): Update the declaration.
12836 (load_partial_dies): Caller update.
12837 (read_partial_die): Remove one argument abbrev_len.
12838
12839 2018-02-26 Yao Qi <yao.qi@linaro.org>
12840
12841 * dwarf2read.c (struct partial_die_info): Add ctor, delete
12842 assignment operator.
12843 (load_partial_dies): Use ctor and copy ctor.
12844 (read_partial_die): Update.
12845 (dwarf2_cu::find_partial_die): Use ctor.
12846
12847 2018-02-26 Yao Qi <yao.qi@linaro.org>
12848
12849 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
12850 (find_partial_die_in_comp_unit): Change it to
12851 dwarf2_cu::find_partial_die.
12852 (find_partial_die): Update.
12853
12854 2018-02-26 Yao Qi <yao.qi@linaro.org>
12855
12856 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
12857 is NULL.
12858
12859 2018-02-26 Yao Qi <yao.qi@linaro.org>
12860
12861 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
12862
12863 2018-02-26 Alan Hayward <alan.hayward@arm.com>
12864
12865 * arch/amd64.h: Use common/tdesc.h.
12866 * arch/i386.c: Likewise.
12867 * arch/i386.h: Likewise.
12868 * arch/tic6x.c: Likewise.
12869 * arch/tdesc.h: Move file from here...
12870 * common/tdesc.h: ...to here.
12871 * features/aarch64-core.c: Regenerate.
12872 * features/aarch64-fpu.c: Regenerate.
12873 * features/i386/32bit-avx.c: Regenerate.
12874 * features/i386/32bit-avx512.c: Regenerate.
12875 * features/i386/32bit-core.c: Regenerate.
12876 * features/i386/32bit-linux.c: Regenerate.
12877 * features/i386/32bit-mpx.c: Regenerate.
12878 * features/i386/32bit-pkeys.c: Regenerate.
12879 * features/i386/32bit-sse.c: Regenerate.
12880 * features/i386/64bit-avx.c: Regenerate.
12881 * features/i386/64bit-avx512.c: Regenerate.
12882 * features/i386/64bit-core.c: Regenerate.
12883 * features/i386/64bit-linux.c: Regenerate.
12884 * features/i386/64bit-mpx.c: Regenerate.
12885 * features/i386/64bit-pkeys.c: Regenerate.
12886 * features/i386/64bit-segments.c: Regenerate.
12887 * features/i386/64bit-sse.c: Regenerate.
12888 * features/i386/x32-core.c: Regenerate.
12889 * features/tic6x-c6xp.c: Regenerate.
12890 * features/tic6x-core.c: Regenerate.
12891 * features/tic6x-gp.c: Regenerate.
12892 * target-descriptions.c: Use common/tdesc.h.
12893 * target-descriptions.h: Likewise.
12894
12895 2018-02-24 Tom Tromey <tom@tromey.com>
12896
12897 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
12898 (try_thread_db_load_from_dir, thread_db_load_search): Use
12899 std::string.
12900 (info_auto_load_libthread_db_compare): Return bool. Change
12901 argument types.
12902 (info_auto_load_libthread_db): Use std::vector, std::string.
12903 Remove cleanups.
12904
12905 2018-02-24 Tom Tromey <tom@tromey.com>
12906
12907 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
12908 std::string.
12909 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
12910 std::string*.
12911 * gdbarch.c: Rebuild.
12912 * gdbarch.h: Rebuild.
12913 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
12914 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
12915 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
12916 std::string*.
12917
12918 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
12919
12920 * gdbtypes.h (sect_offset): Change type to uint64_t.
12921 (sect_offset_str): New function.
12922 * dwarf2read.c (create_addrmap_from_aranges): Use
12923 sect_offset_str.
12924 (error_check_comp_unit_head): Likewise.
12925 (create_debug_type_hash_table): Likewise.
12926 (read_cutu_die_from_dwo): Likewise.
12927 (init_cutu_and_read_dies): Likewise.
12928 (init_cutu_and_read_dies_no_follow): Likewise.
12929 (process_psymtab_comp_unit_reader): Likewise.
12930 (partial_die_parent_scope): Likewise.
12931 (peek_die_abbrev): Likewise.
12932 (process_queue): Likewise.
12933 (dwarf2_physname): Likewise.
12934 (read_namespace_alias): Likewise.
12935 (read_import_statement): Likewise.
12936 (create_dwo_cu_reader): Likewise.
12937 (create_cus_hash_table): Likewise.
12938 (lookup_dwo_cutu): Likewise.
12939 (inherit_abstract_dies): Likewise.
12940 (read_func_scope): Likewise.
12941 (read_call_site_scope): Likewise.
12942 (dwarf2_add_member_fn): Likewise.
12943 (read_common_block): Likewise.
12944 (read_module_type): Likewise.
12945 (read_typedef): Likewise.
12946 (read_subrange_type): Likewise.
12947 (load_partial_dies): Likewise.
12948 (read_partial_die): Likewise.
12949 (find_partial_die): Likewise.
12950 (read_str_index): Likewise.
12951 (dwarf2_string_attr): Likewise.
12952 (build_error_marker_type): Likewise.
12953 (lookup_die_type): Likewise.
12954 (dump_die_shallow): Likewise.
12955 (follow_die_ref): Likewise.
12956 (dwarf2_fetch_die_loc_sect_off): Likewise.
12957 (dwarf2_fetch_constant_bytes): Likewise.
12958 (follow_die_sig): Likewise.
12959 (get_signatured_type): Likewise.
12960 (get_DW_AT_signature_type): Likewise.
12961 (dwarf2_find_containing_comp_unit): Likewise.
12962 (set_die_type): Likewise.
12963
12964 2018-02-21 John Baldwin <jhb@FreeBSD.org>
12965
12966 * arch/aarch64.c: Include "common-defs.h".
12967 * arch/amd64.c: Likewise.
12968 * arch/i386.c: Likewise.
12969
12970 2018-02-21 Tom Tromey <tom@tromey.com>
12971
12972 * value.h: (extract_field_op): Update.
12973 * eval.c (extract_field_op): Return a const char *.
12974 * expression.h (parse_expression_for_completion): Update.
12975 * completer.c (complete_expression): Update.
12976 (add_struct_fields): Make fieldname const.
12977 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
12978 (mark_completion_tag, parse_exp_in_context_1): Update.
12979 (parse_expression_for_completion): Change "name" to
12980 unique_xmalloc_ptr*.
12981
12982 2018-02-21 Tom Tromey <tom@tromey.com>
12983
12984 * infcall.c (call_function_by_hand_dummy): Use std::vector.
12985
12986 2018-02-21 Yao Qi <yao.qi@linaro.org>
12987
12988 * avr-tdep.c (avr_read_pc): Change parameter type to
12989 readable_regcache.
12990 * gdbarch.sh (read_pc): Likewise.
12991 * gdbarch.c: Re-generated.
12992 * gdbarch.h: Re-generated.
12993 * hppa-tdep.c (hppa_read_pc): Change parameter type to
12994 readable_regcache.
12995 * ia64-tdep.c (ia64_read_pc): Likewise.
12996 * mips-tdep.c (mips_read_pc): Likewise.
12997 * spu-tdep.c (spu_read_pc): Likewise.
12998
12999 2018-02-21 Yao Qi <yao.qi@linaro.org>
13000
13001 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
13002 * regcache-dump.c: New file.
13003 * regcache.c: Move register_dump to regcache-dump.c.
13004 (maintenance_print_registers): Likewise.
13005 (maintenance_print_raw_registers): Likewise.
13006 (maintenance_print_cooked_registers): Likewise.
13007 (maintenance_print_register_groups): Likewise.
13008 (maintenance_print_remote_registers): Likewise.
13009 (_initialize_regcache): Likewise.
13010 * regcache.h (register_dump): Moved from regcache.c.
13011
13012 2018-02-21 Yao Qi <yao.qi@linaro.org>
13013
13014 * regcache.c (regcache::regcache): Update.
13015 (regcache::invalidate): Move it to detached_regcache::invalidate.
13016 (get_thread_arch_aspace_regcache): Update.
13017 (regcache::raw_update): Update.
13018 (regcache::cooked_read): Remove some code.
13019 (regcache::cooked_read_value): Likewise.
13020 (regcache::raw_write): Remove assert on m_readonly_p.
13021 (regcache::raw_supply_integer): Move it to
13022 detached_regcache::raw_supply_integer.
13023 (regcache::raw_supply_zeroed): Likewise.
13024 * regcache.h (detached_regcache) <raw_supply_integer>: New
13025 declaration.
13026 <raw_supply_zeroed, invalidate>: Likewise.
13027 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
13028 <invalidate>: Likewise.
13029 <m_readonly_p>: Removed.
13030
13031 2018-02-21 Yao Qi <yao.qi@linaro.org>
13032
13033 * infcmd.c (get_return_value): Let stop_regs point to
13034 get_current_regcache.
13035 * regcache.c (regcache::regcache): Remove.
13036 (register_dump_reg_buffer): New class.
13037 (regcache_print): Adjust.
13038 * regcache.h (regcache): Remove constructors.
13039
13040 2018-02-21 Yao Qi <yao.qi@linaro.org>
13041
13042 * regcache.c (class register_dump): New class.
13043 (register_dump_regcache, register_dump_none): New class.
13044 (register_dump_remote, register_dump_groups): New class.
13045 (regcache_print): Update.
13046 * regcache.h (regcache_dump_what): Move it to regcache.c.
13047 (regcache) <dump>: Remove.
13048
13049 2018-02-21 Yao Qi <yao.qi@linaro.org>
13050
13051 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
13052 reg_buffer_rw *.
13053 (jit_unwind_reg_set_impl): Call raw_supply.
13054 (jit_frame_sniffer): Use reg_buffer_rw.
13055 * record-full.c (record_full_core_regbuf): Change its type.
13056 (record_full_core_open_1): Use reg_buffer_rw.
13057 (record_full_close): Likewise.
13058 (record_full_core_fetch_registers): Use regcache->raw_supply.
13059 (record_full_core_store_registers): Likewise.
13060 * regcache.c (regcache::get_register_status): Move it to
13061 reg_buffer.
13062 (regcache_raw_set_cached_value): Remove.
13063 (regcache::raw_set_cached_value): Remove.
13064 (regcache::raw_write): Call raw_supply.
13065 (regcache::raw_supply): Move it to reg_buffer_rw.
13066 * regcache.h (regcache_raw_set_cached_value): Remove.
13067 (reg_buffer_rw): New class.
13068
13069 2018-02-21 Yao Qi <yao.qi@linaro.org>
13070
13071 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
13072 readonly_detached_regcache.
13073 (dummy_frame_prev_register): Use regcache->cooked_read.
13074 * frame.c (frame_save_as_regcache): Change return type.
13075 (frame_pop): Update.
13076 * frame.h (frame_save_as_regcache): Update declaration.
13077 * inferior.h (get_infcall_suspend_state_regcache): Update
13078 declaration.
13079 * infrun.c (infcall_suspend_state) <registers>: use
13080 readonly_detached_regcache.
13081 (save_infcall_suspend_state): Don't use regcache_dup.
13082 (get_infcall_suspend_state_regcache): Change return type.
13083 * linux-fork.c (struct fork_info) <savedregs>: Change to
13084 readonly_detached_regcache.
13085 <pc>: New field.
13086 (fork_save_infrun_state): Don't use regcache_dup.
13087 (info_checkpoints_command): Adjust.
13088 * mi/mi-main.c (register_changed_p): Update declaration.
13089 (mi_cmd_data_list_changed_registers): Use
13090 readonly_detached_regcache.
13091 (register_changed_p): Change parameter type to
13092 readonly_detached_regcache.
13093 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
13094 readonly_detached_regcache.
13095 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
13096 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
13097 New.
13098 (regcache::save): Move it to reg_buffer.
13099 (regcache::restore): Change parameter type.
13100 (regcache_dup): Remove.
13101 * regcache.h (reg_buffer) <save>: New method.
13102 (readonly_detached_regcache): New class.
13103 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
13104 readonly_detached_regcache.
13105 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
13106
13107 2018-02-21 Yao Qi <yao.qi@linaro.org>
13108
13109 * frame.c (frame_save_as_regcache): Use regcache method save.
13110 (frame_pop): Use regcache method restore.
13111 * infrun.c (restore_infcall_suspend_state): Likewise.
13112 * linux-fork.c (fork_load_infrun_state): Likewise.
13113 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
13114 save.
13115 * regcache.c (regcache_save): Remove.
13116 (regcache::restore): More asserts.
13117 (regcache_cpy): Remove.
13118 * regcache.h (regcache_save): Remove the declaration.
13119 (regcache::restore): Move from private to public.
13120 Remove the friend declaration of regcache_cpy.
13121 (regcache_cpy): Remove declaration.
13122
13123 2018-02-21 Yao Qi <yao.qi@linaro.org>
13124
13125 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
13126 parameter type to 'readable_regcache *'.
13127 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13128 * arm-tdep.c (arm_neon_quad_read): Likewise.
13129 (arm_pseudo_read): Likewise.
13130 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13131 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13132 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13133 * gdbarch.c: Re-generated.
13134 * gdbarch.h: Re-generated.
13135 * gdbarch.sh (pseudo_register_read): Change parameter type to
13136 'readable_regcache *'.
13137 (pseudo_register_read_value): Likewise.
13138 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
13139 (h8300_pseudo_register_read): Likewise.
13140 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
13141 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13142 (i386_pseudo_register_read_into_value): Likewise.
13143 (i386_pseudo_register_read_value): Likewise.
13144 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
13145 declaration.
13146 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
13147 * m32c-tdep.c (m32c_raw_read): Likewise.
13148 (m32c_read_flg): Likewise.
13149 (m32c_banked_register): Likewise.
13150 (m32c_banked_read): Likewise.
13151 (m32c_sb_read): Likewise.
13152 (m32c_part_read): Likewise.
13153 (m32c_cat_read): Likewise.
13154 (m32c_r3r2r1r0_read): Likewise.
13155 (m32c_pseudo_register_read): Likewise.
13156 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13157 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13158 (mep_pseudo_cr64_read): Likewise.
13159 (mep_pseudo_register_read): Likewise.
13160 * mips-tdep.c (mips_pseudo_register_read): Likewise.
13161 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13162 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13163 * regcache.c (regcache::raw_read): Move it to readable_regcache.
13164 (regcache::cooked_read): Likewise.
13165 (regcache::cooked_read_value): Likewise.
13166 (regcache_cooked_read_signed):
13167 (regcache::cooked_read): Likewise.
13168 * regcache.h (readable_regcache): New class.
13169 (regcache): Inherit readable_regcache. Move some methods to
13170 readable_regcache.
13171 * rl78-tdep.c (rl78_pseudo_register_read): Change
13172 parameter type to 'readable_regcache *'.
13173 * rs6000-tdep.c (do_regcache_raw_read): Remove.
13174 (e500_pseudo_register_read): Change parameter type to
13175 'readable_regcache *'.
13176 (dfp_pseudo_register_read): Likewise.
13177 (vsx_pseudo_register_read): Likewise.
13178 (efpr_pseudo_register_read): Likewise.
13179 * s390-tdep.c (s390_pseudo_register_read): Likewise.
13180 * sh-tdep.c (sh_pseudo_register_read): Likewise.
13181 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
13182 (sh64_pseudo_register_read): Likewise.
13183 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13184 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13185 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13186 (spu_pseudo_register_read): Likewise.
13187 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13188 (xtensa_pseudo_register_read): Likewise.
13189
13190 2018-02-21 Yao Qi <yao.qi@linaro.org>
13191
13192 * regcache.c (regcache::regcache): Call reg_buffer ctor.
13193 (regcache::arch): Move it to reg_buffer::arch.
13194 (regcache::register_buffer): Likewise.
13195 (regcache::assert_regnum): Likewise.
13196 (regcache::num_raw_registers): Likewise.
13197 * regcache.h (reg_buffer): New class.
13198 (regcache): Inherit reg_buffer.
13199
13200 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
13201
13202 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
13203 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
13204
13205 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
13206
13207 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
13208
13209 2018-02-19 Alan Hayward <alan.hayward@arm.com>
13210
13211 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
13212 (SFILES): Remove common/*.c files.
13213 (COMMON_OBS): Remove some *.o files built from common/*.c files.
13214 * common/common.host: Add common reference.
13215 * configure.ac: Likewise.
13216 * configure: Regenerate.
13217
13218 2018-02-16 Yao Qi <yao.qi@linaro.org>
13219
13220 * block.c (block_namespace_info): Inherit allocate_on_obstack.
13221 (block_initialize_namespace): Use new.
13222 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
13223 (dwarf2_free_objfile): Use delete.
13224 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
13225 (copy_type_recursive): Use new.
13226 * gdb_obstack.h (allocate_on_obstack): New.
13227
13228 2018-02-15 Yao Qi <yao.qi@linaro.org>
13229
13230 PR gdb/22849
13231 * inferior.c (exit_inferior_1): Reset inf->control.
13232
13233 2018-02-15 Joel Brobecker <brobecker@adacore.com>
13234
13235 * ada-lang.c (ada_to_fixed_value_create): Delete advance
13236 declaration.
13237
13238 2018-02-14 Pedro Alves <palves@redhat.com>
13239
13240 * frame-unwind.c (frame_unwind_try_unwinder): Always call
13241 frame_cleanup_after_sniffer on exception.
13242
13243 2018-02-14 Tom Tromey <tom@tromey.com>
13244
13245 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
13246 const.
13247 (solib_bfd_open): Make pathname const.
13248 * solib.c (solib_bfd_open): Make pathname const.
13249 * solib-spu.c (spu_bfd_fopen): Make name const.
13250 (spu_bfd_open): Make pathname const.
13251 * solib-darwin.c (darwin_bfd_open): Make pathname const.
13252 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
13253
13254 2018-02-14 Tom Tromey <tom@tromey.com>
13255
13256 * symfile.c (symfile_bfd_open): Update.
13257 * source.h (openp, source_full_path_of, find_and_open_source):
13258 Change argument type to unique_xmalloc_ptr.
13259 * source.c (openp): Take a unique_xmalloc_ptr.
13260 (source_full_path_of, find_and_open_source): Likewise.
13261 (open_source_file, symtab_to_fullname): Update.
13262 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
13263 unique_xmalloc_ptr.
13264 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
13265 (exec_file_find): Update.
13266 * psymtab.c (psymtab_to_fullname): Update.
13267 * nto-tdep.h (nto_find_and_open_solib): Update.
13268 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
13269 unique_xmalloc_ptr.
13270 * exec.c (exec_file_attach): Update.
13271 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
13272 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
13273
13274 2018-02-14 Tom Tromey <tom@tromey.com>
13275
13276 * solib.c: Include source.h.
13277 * nto-tdep.c: Include source.h.
13278 * mi/mi-cmd-env.c: Include source.h.
13279 * infcmd.c: Include source.h.
13280 * exec.c: Include source.h.
13281 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
13282 (add_path, directory_switch, source_path, init_source_path): Move
13283 declarations...
13284 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
13285 (add_path, directory_switch, source_path, init_source_path):
13286 ...here.
13287
13288 2018-02-14 Tom Tromey <tom@tromey.com>
13289
13290 * solist.h (exec_file_find, solib_find): Return
13291 unique_xmalloc_ptr.
13292 (solib_bfd_fopen): Take a const char *.
13293 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
13294 (exec_file_find, solib_find): Likewise.
13295 (solib_bfd_fopen): Do not take ownership of "pathname".
13296 (solib_bfd_open): Use unique_xmalloc_ptr.
13297 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
13298 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
13299 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
13300 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
13301
13302 2018-02-14 Joel Brobecker <brobecker@adacore.com>
13303
13304 * ada-lang.c (name_match_type_from_name): Remove reference to
13305 ada_name_for_lookup in function's documentation.
13306 * ada-lang.h (ada_name_for_lookup): Delete declaration.
13307
13308 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
13309
13310 * defs.h (enum openp_flags): New enum.
13311 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
13312 Move to enum openp_flags.
13313 (openp_flags): New enum flags.
13314 (openp): Change parameter type to openp_flags.
13315 * source.c (openp): Change parameter type to openp_flags.
13316 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
13317 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
13318
13319 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
13320
13321 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
13322 per-command.
13323
13324 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
13325
13326 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
13327 into...
13328 (class dwarf2_queue_guard): ...the destructor of this new class.
13329 (dw2_do_instantiate_symtab): Create instance of the new class
13330 dwarf2_queue_guard, remove cleanup.
13331
13332 2018-02-09 Tom Tromey <tom@tromey.com>
13333
13334 * source.c (find_source_lines): Don't reference past the end of
13335 the vector.
13336
13337 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13338
13339 * remote.c (remote_btrace_maybe_reopen): Change error message.
13340 * btrace.c (btrace_enable): Likewise.
13341 (parse_xml_btrace): Likewise.
13342 (parse_xml_btrace_conf): Likewise.
13343
13344 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13345
13346 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
13347 (linux_enable_pt, linux_enable_bts): Call
13348 diagnose_perf_event_open_fail.
13349
13350 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13351
13352 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
13353 Remove parameter and change return type. Update callers. Move it.
13354 (linux_enable_bts, linux_enable_pt): Improve error message.
13355 (linux_enable_pt): Remove zero buffer size check.
13356 (linux_enable_btrace): Improve error messages. Remove NULL return
13357 check.
13358
13359 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13360
13361 * btrace.c (btrace_enable): Remove target_supports_btrace call.
13362 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
13363 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
13364 (linux_supports_pt, linux_supports_btrace): Remove.
13365 (linux_enable_bts): Call cpu_supports_bts.
13366 * nat/linux-btrace.h (linux_supports_btrace): Remove.
13367 * remote.c (remote_supports_btrace): Remove.
13368 (init_remote_ops): Remove remote_supports_btrace.
13369 * target-delegates.c: Regenerated.
13370 * target.c (target_supports_btrace): Remove.
13371 * target.h (target_ops) <to_supports_btrace>: Remove
13372 (target_supports_btrace): Remove.
13373 * x86-linux-nat.c (x86_linux_create_target): Remove
13374 linux_supports_btrace.
13375
13376 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13377
13378 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
13379 btrace failed.
13380 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
13381 exception and use message in own exception.
13382
13383 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13384
13385 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
13386 (perf_event_pt_event_type): Use gdb_file_up.
13387 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
13388 scoped_fd, and scoped_mmap.
13389
13390 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13391
13392 * common/scoped_mmap.h: New.
13393 * unittests/scoped_mmap-selftest.c: New.
13394 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13395 unittests/scoped_mmap-selftest.c.
13396
13397 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
13398
13399 * common/scoped_fd.h: New.
13400 * unittests/scoped_fd-selftest.c: New.
13401 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13402 unittests/scoped_fd-selftest.c.
13403
13404 2018-02-09 Tom Tromey <tom@tromey.com>
13405
13406 * auto-load.c (auto_load_section_scripts): Use
13407 gdb::unique_xmalloc_ptr.
13408
13409 2018-02-09 Tom Tromey <tom@tromey.com>
13410
13411 * auto-load.c (execute_script_contents): Use std::string.
13412
13413 2018-02-09 Joel Brobecker <brobecker@adacore.com>
13414
13415 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
13416 Python function, rather than a new command.
13417
13418 2018-02-08 Tom Tromey <tom@tromey.com>
13419
13420 * solib.c (solib_find_1): Use std::string.
13421 (solib_bfd_fopen): Use unique_xmalloc_ptr.
13422
13423 2018-02-08 Tom Tromey <tom@tromey.com>
13424
13425 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
13426
13427 2018-02-08 Tom Tromey <tom@tromey.com>
13428
13429 * source.c (find_source_lines): Use gdb::def_vector.
13430
13431 2018-02-08 Tom Tromey <tom@tromey.com>
13432
13433 * macrocmd.c (struct temporary_macro_definition): New.
13434 (macro_define_command): Use temporary_macro_definition. Remove
13435 cleanups.
13436 (free_macro_definition_ptr): Remove.
13437
13438 2018-02-08 Tom Tromey <tom@tromey.com>
13439
13440 * macroexp.c (maybe_expand): Use std::string.
13441
13442 2018-02-08 Tom Tromey <tom@tromey.com>
13443
13444 * macroexp.c (struct macro_buffer): Add initializers for some
13445 members.
13446 (init_buffer, init_shared_buffer, free_buffer)
13447 (free_buffer_return_text): Remove.
13448 (macro_buffer): New constructors.
13449 (~macro_buffer): New destructor.
13450 (macro_buffer::set_shared): New method.
13451 (macro_buffer::resize_buffer, macro_buffer::appendc)
13452 (macro_buffer::appendmem): Now methods, not free functions.
13453 (set_token, append_tokens_without_splicing, stringify)
13454 (macro_stringify): Update.
13455 (gather_arguments): Change return type. Remove argc_p argument,
13456 add args_ptr argument. Use std::vector.
13457 (substitute_args): Remove argc argument. Accept std::vector.
13458 (expand): Update. Use std::vector.
13459 (scan, macro_expand, macro_expand_next): Update.
13460
13461 2018-02-08 Tom Tromey <tom@tromey.com>
13462
13463 * symtab.c (default_collect_symbol_completion_matches_break_on):
13464 Use unique_xmalloc_ptr.
13465 * macroscope.h: (sal_macro_scope, user_macro_scope)
13466 (default_macro_scope): Return unique_xmalloc_ptr.
13467 * macroscope.c (sal_macro_scope, user_macro_scope)
13468 (default_macro_scope): Return unique_xmalloc_ptr.
13469 * macroexp.h (macro_expand, macro_expand_once): Return
13470 unique_xmalloc_ptr.
13471 * macroexp.c (macro_expand, macro_expand_once): Return
13472 unique_xmalloc_ptr.
13473 * macrocmd.c (macro_expand_command, macro_expand_once_command)
13474 (info_macro_command, info_macros_command): Use
13475 unique_xmalloc_ptr.
13476 * compile/compile-c-support.c (write_macro_definitions): Use
13477 unique_xmalloc_ptr.
13478 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
13479
13480 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
13481
13482 * value.c (value_static_field): Assign field type instead of
13483 containing type when returning an optimized out value.
13484
13485 2018-02-06 Yao Qi <yao.qi@linaro.org>
13486
13487 * ft32-tdep.c (ft32_read_pc): Remove.
13488 (ft32_write_pc): Remove.
13489 (ft32_gdbarch_init): Update.
13490 * m32r-tdep.c (m32r_read_pc): Remove.
13491 (m32r_gdbarch_init): Update.
13492 * mep-tdep.c (mep_read_pc): Remove.
13493 (mep_gdbarch_init): Update.
13494 * microblaze-tdep.c (microblaze_write_pc): Remove.
13495 (microblaze_gdbarch_init): Update.
13496 * mn10300-tdep.c (mn10300_read_pc): Remove.
13497 (mn10300_write_pc): Remove.
13498 (mn10300_gdbarch_init): Update.
13499 * moxie-tdep.c (moxie_read_pc): Remove.
13500 (moxie_write_pc): Remove.
13501 (moxie_gdbarch_init): Update.
13502
13503 2018-02-06 Yao Qi <yao.qi@linaro.org>
13504
13505 * expprint.c (print_subexp_standard): Handle
13506 OP_F77_UNDETERMINED_ARGLIST.
13507 (dump_subexp_body_standard): Likewise.
13508
13509 2018-02-05 Alan Hayward <alan.hayward@arm.com>
13510
13511 * target-descriptions.c (tdesc_element_visitor) Add empty
13512 implementations.
13513 (tdesc_type): Move make_gdb_type from here.
13514 (tdesc_type_builtin): Likewise.
13515 (tdesc_type_vector): Likewise.
13516 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
13517 (make_gdb_type_struct): Move from tdesc_type_with_fields.
13518 (make_gdb_type_union): Likewise.
13519 (make_gdb_type_flags): Likewise.
13520 (make_gdb_type_enum): Likewise.
13521 (make_gdb_type): New function.
13522 (tdesc_register_type): Use static make_gdb_type.
13523
13524 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
13525
13526 * infcmd.c (default_print_one_register_info): Align natural-format
13527 column values consistently one under another.
13528 (pad_to_column): New function.
13529
13530 2018-02-05 Joel Brobecker <brobecker@adacore.com>
13531
13532 * dwarf2read.c (dwarf2_physname): Move commment.
13533
13534 2018-02-01 Leszek Swirski <leszeks@google.com>
13535
13536 * varobj.c (varobj_formatted_print_options): Allow recursive
13537 pretty printing if pretty printing is enabled.
13538
13539 2018-02-01 Leszek Swirski <leszeks@google.com>
13540
13541 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
13542 names after a structop as a filename.
13543
13544 2018-02-01 Yao Qi <yao.qi@linaro.org>
13545
13546 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
13547 (arm_record_coproc_data_proc): Likewise.
13548
13549 2018-02-01 Yao Qi <yao.qi@linaro.org>
13550
13551 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
13552
13553 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
13554
13555 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
13556 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
13557
13558 2018-01-31 Pedro Alves <palves@redhat.com>
13559
13560 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
13561 * inflow.c (child_terminal_save_inferior): Wrap reference to
13562 tcgetpgrp in HAVE_TERMIOS_H.
13563 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
13564 _WIN32.
13565 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
13566 always iterate over all inferiors.
13567 (gdbsim_cntrl_c): Adjust.
13568 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
13569
13570 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13571
13572 * gdbtypes.c (lookup_array_range_type): Make sure the array's
13573 index type is objfile-owned if the element type is as well.
13574
13575 2018-01-31 Joel Brobecker <brobecker@adacore.com>
13576
13577 GDB 8.1 released.
13578
13579 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
13580
13581 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
13582 "features/s390x-linux64.c".
13583 (_initialize_s390_linux_tdep): Remove initialization of tdescs
13584 s390_linux32 and s390x_linux64.
13585 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
13586 default tdesc.
13587 * s390-tdep.c: Include "features/s390-linux32.c" and
13588 "features/s390x-linux64.c".
13589 (s390_tdesc_valid): Add check for tdesc_has_registers.
13590 (s390_gdbarch_init): Make sure there is always a valid tdesc.
13591 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
13592 tdesc_s390x_linux64.
13593 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
13594 tdesc_s390x_linux64 to...
13595 * s390-tdep.h: ...here.
13596
13597 2018-01-30 Pedro Alves <palves@redhat.com>
13598
13599 PR gdb/13211
13600 * config.in, configure: Regenerate.
13601 * configure.ac: Check for getpgid.
13602 * go32-nat.c (go32_pass_ctrlc): New.
13603 (go32_target): Install it.
13604 * inf-child.c (inf_child_target): Install
13605 child_terminal_save_inferior, child_pass_ctrlc and
13606 child_interrupt.
13607 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
13608 (inf_ptrace_target): No longer install it.
13609 * infcmd.c (interrupt_target_1): Adjust.
13610 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
13611 (child_interrupt): Declare.
13612 (inferior::terminal_state): New.
13613 * inflow.c (struct terminal_info): Update comments.
13614 (inferior_process_group): Delete.
13615 (terminal_is_ours): Delete.
13616 (gdb_tty_state): New.
13617 (child_terminal_init): Adjust.
13618 (is_gdb_terminal, sharing_input_terminal_1)
13619 (sharing_input_terminal): New functions.
13620 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
13621 Set the process's actual process group in the foreground if
13622 possible. Handle is_ours_for_output/is_ours distinction. Don't
13623 mark terminal as the inferior's if not sharing GDB's terminal.
13624 Don't check attach_flag.
13625 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
13626 pass down a target_terminal_state.
13627 (child_terminal_save_inferior): New, factored out from ...
13628 (child_terminal_ours_1): ... this. Handle
13629 target_terminal_state::is_ours_for_output.
13630 (child_interrupt, child_pass_ctrlc): New.
13631 (inflow_inferior_exit): Clear the inferior's terminal_state.
13632 (copy_terminal_info): Copy the inferior's terminal state.
13633 (_initialize_inflow): Remove reference to terminal_is_ours.
13634 * inflow.h (inferior_process_group): Delete.
13635 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
13636 * procfs.c (procfs_target): Don't install procfs_interrupt.
13637 (procfs_interrupt): Delete.
13638 * remote.c (remote_serial_quit_handler): Adjust.
13639 (remote_interrupt): Remove ptid parameter. Adjust.
13640 * target-delegates.c: Regenerate.
13641 * target.c: Include "terminal.h".
13642 (target_terminal::terminal_state): Rename to ...
13643 (target_terminal::m_terminal_state): ... this.
13644 (target_terminal::init): Adjust.
13645 (target_terminal::inferior): Adjust to per-inferior
13646 terminal_state.
13647 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
13648 (target_terminal::ours, target_terminal::ours_for_output): Use
13649 target_terminal_is_ours_kind.
13650 (target_interrupt): Remove ptid parameter. Adjust.
13651 (default_target_pass_ctrlc): Adjust.
13652 * target.h (target_ops::to_terminal_save_inferior): New field.
13653 (target_ops::to_interrupt): Remove ptid_t parameter.
13654 (target_interrupt): Remove ptid_t parameter. Update comment.
13655 (target_pass_ctrlc): Update comment.
13656 * target/target.h (target_terminal_state): New scoped enum,
13657 factored out of ...
13658 (target_terminal::terminal_state): ... here.
13659 (target_terminal::inferior): Update comments.
13660 (target_terminal::restore_inferior): New.
13661 (target_terminal::is_inferior, target_terminal::is_ours)
13662 (target_terminal::is_ours_for_output): Adjust.
13663 (target_terminal::scoped_restore_terminal_state): Adjust to
13664 rename, and call restore_inferior() instead of inferior().
13665 (target_terminal::scoped_restore_terminal_state::m_state): Change
13666 type.
13667 (target_terminal::terminal_state): Rename to ...
13668 (target_terminal::m_terminal_state): ... this and change type.
13669
13670 2018-01-30 Pedro Alves <palves@redhat.com>
13671
13672 * linux-nat.c (wait_for_signal): New function.
13673 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
13674 directly.
13675 (async_terminal_is_ours)
13676 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
13677 (linux_nat_add_target): Don't override
13678 to_terminal_inferior/to_terminal_ours.
13679
13680 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
13681
13682 * remote.c (remote_follow_fork): Don't call "detach_inferior".
13683
13684 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
13685
13686 * dwarf2read.c (free_dwo_files): Add forward-declaration.
13687 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
13688 dwarf2_per_objfile_free here.
13689 (dwarf2_per_objfile_free): Remove.
13690 (_initialize_dwarf2_read): Don't register
13691 dwarf2_per_objfile_free as a registry cleanup.
13692
13693 2018-01-27 Eli Zaretskii <eliz@gnu.org>
13694
13695 Avoid compilation errors in MinGW native builds
13696
13697 The error is triggered by including python-internal.h, and the
13698 error message is:
13699
13700 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
13701 from build-gnulib/import/math.h:27,
13702 from d:/usr/Python26/include/pyport.h:235,
13703 from d:/usr/Python26/include/Python.h:58,
13704 from python/python-internal.h:94,
13705 from python/py-arch.c:24:
13706 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
13707 using ::hypot;
13708 ^~~~~
13709
13710 This happens because Python headers define 'hypot' to expand t
13711 '_hypot' in the Windows builds.
13712 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
13713 'hypoth'. This avoids a compilation error.
13714
13715 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13716
13717 * MAINTAINERS (Write After Approval): Fix ordering.
13718
13719 2018-01-26 Alan Hayward <alan.hayward@arm.com>
13720
13721 * MAINTAINERS (Write After Approval): Add Alan Hayward.
13722
13723 2018-01-26 Alan Modra <amodra@gmail.com>
13724
13725 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
13726 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
13727 Remove nop. Make const. Comment.
13728 (powerpc32_plt_stub_so_2): New.
13729 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
13730 Correct count. Update uses.
13731 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
13732 Move common code reading PLT entry word. Correct
13733 powerpc32_plt_stub PLT address calculation.
13734 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
13735 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
13736 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
13737 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
13738 (ppc64_standard_linkage8): Likewise.
13739 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
13740 Correct insns description.
13741 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
13742
13743 2018-01-24 Pedro Alves <palves@redhat.com>
13744
13745 GCC PR libstdc++/83906
13746 * gdbtypes.c (operator==(const dynamic_prop &,
13747 const dynamic_prop &)): New.
13748 (operator==(const range_bounds &, const range_bounds &)): New.
13749 (check_types_equal): Use them instead of memcmp.
13750 * gdbtypes.h (operator==(const dynamic_prop &,
13751 const dynamic_prop &)): Declare.
13752 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
13753 (operator==(const range_bounds &, const range_bounds &)): Declare.
13754 (operator!=(const range_bounds &, const range_bounds &)): Declare.
13755
13756 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13757
13758 * s390-linux-tdep.c (s390_record_address_mask)
13759 (s390_record_calc_disp_common, s390_record_calc_disp)
13760 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13761 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13762 (s390_process_record): Move to s390-tdep.c.
13763 (s390_linux_init_abi_any): Adjust.
13764 * s390-tdep.c (s390_record_address_mask)
13765 (s390_record_calc_disp_common, s390_record_calc_disp)
13766 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
13767 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
13768 (s390_process_record): Moved from s390-linux-tdep.c
13769 (s390_gdbarch_init): Adjust.
13770
13771 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13772
13773 * s390-linux-nat.c (s390-tdep.h): New include.
13774 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
13775 (HFILES_NO_SRCDIR): Add s390-tdep.h.
13776 (ALLDEPFILES): Add s390-tdep.c.
13777 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
13778 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
13779 * s390-tdep.h: ...this. New file.
13780 * s390-linux-tdep.c (s390-tdep.h): New include.
13781 (_initialize_s390_tdep): Rename to...
13782 (_initialize_s390_linux_tdep): ...this and adjust.
13783 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
13784 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
13785 s390-tdep.h.
13786 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
13787 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
13788 (s390_is_partial_instruction, s390_software_single_step)
13789 (is_non_branch_ril, s390_displaced_step_copy_insn)
13790 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
13791 (s390_prologue_data, s390_addr, s390_store, s390_load)
13792 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
13793 (s390_register_call_saved, s390_guess_tracepoint_registers)
13794 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
13795 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
13796 (s390_pseudo_register_name, s390_pseudo_register_type)
13797 (s390_pseudo_register_read, s390_pseudo_register_write)
13798 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
13799 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
13800 (s390_addr_bits_remove, s390_address_class_type_flags)
13801 (s390_address_class_type_flags_to_name)
13802 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
13803 (s390_function_arg_float, s390_function_arg_vector)
13804 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
13805 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
13806 (s390_frame_align, s390_register_return_value, s390_return_value)
13807 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
13808 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
13809 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
13810 (s390_trad_frame_prev_register, s390_unwind_cache)
13811 (s390_prologue_frame_unwind_cache)
13812 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
13813 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
13814 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
13815 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
13816 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
13817 (s390_frame_base_address, s390_local_base_address)
13818 (s390_frame_base, s390_gcc_target_options)
13819 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
13820 (s390_validate_reg_range, s390_tdesc_valid)
13821 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
13822 * s390-tdep.c: ...this. New file.
13823
13824 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13825
13826 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
13827 (s390_process_record, s390_gdbarch_tdep_alloc)
13828 (s390_linux_init_abi_any): Use/set new hook.
13829
13830 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13831
13832 * s390-linux-tdep.c (osabi.h): New include.
13833 (s390_linux_init_abi_31, s390_linux_init_abi_64)
13834 (s390_linux_init_abi_any): New functions.
13835 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
13836
13837 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13838
13839 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
13840 tdesc_has_registers check
13841
13842 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13843
13844 * s390-linux-tdep.c (s390_tdesc_valid): New function.
13845 (s390_validate_reg_range): New macro.
13846 (s390_gdbarch_init): Adjust.
13847
13848 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13849
13850 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
13851 (s390_gdbarch_tdep_alloc): Adjust.
13852 (s390_gdbarch_init): Adjust.
13853
13854 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13855
13856 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
13857 <have_tdb>: Change type to bool.
13858 (s390_gdbarch_tdep_alloc): Adjust.
13859 (s390_gdbarch_init): Adjust.
13860
13861 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13862
13863 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
13864 (gdbarch_tdep) <have_upper, have_vx>: New fields.
13865 (s390_gdbarch_tdep_alloc): New function.
13866 (s390_gdbarch_init): Allocate tdep at start and use its fields
13867 instead of separate variables.
13868
13869 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13870
13871 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
13872 when looking for cached gdbarch and add comment for remaining.
13873
13874 2018-01-22 Pedro Alves <palves@redhat.com>
13875 Sergio Durigan Junior <sergiodj@redhat.com>
13876
13877 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
13878 case.
13879
13880 2018-01-22 Maciej W. Rozycki <macro@mips.com>
13881
13882 * MAINTAINERS: Update my company e-mail address.
13883
13884 2018-01-22 Yao Qi <yao.qi@linaro.org>
13885
13886 * regcache.c (cooked_write_test): New function.
13887 (_initialize_regcache): Register the test.
13888
13889 2018-01-22 Yao Qi <yao.qi@linaro.org>
13890
13891 * ia64-tdep.c (ia64_pseudo_register_read): Call
13892 regcache->cooked_read instead of regcache_cooked_read_unsigned.
13893 * m32c-tdep.c (m32c_cat_read): Likewise.
13894 (m32c_r3r2r1r0_read): Likewise.
13895 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
13896 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
13897
13898 2018-01-22 Yao Qi <yao.qi@linaro.org>
13899
13900 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
13901 method raw_read instead of regcache_raw_read.
13902 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
13903 * arm-tdep.c (arm_neon_quad_read): Likewise.
13904 * avr-tdep.c (avr_pseudo_register_read): Likewise.
13905 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
13906 * frv-tdep.c (frv_pseudo_register_read): Likewise.
13907 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
13908 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
13909 (i386_pseudo_register_read_into_value): Likewise.
13910 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
13911 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
13912 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
13913 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
13914 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
13915 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
13916 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
13917 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
13918 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
13919
13920 2018-01-22 Yao Qi <yao.qi@linaro.org>
13921
13922 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
13923 * configure.tgt: Remove target mt.
13924 * mt-tdep.c: Remove.
13925 * regcache.c (cooked_read_test): Remove the check for mt.
13926
13927 2018-01-22 Yao Qi <yao.qi@linaro.org>
13928
13929 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
13930 instead of gdbarch_pseudo_register_read_value.
13931
13932 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13933
13934 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
13935 language is Ada.
13936
13937 2018-01-22 Joel Brobecker <brobecker@adacore.com>
13938
13939 * linespec.c (create_sals_line_offset): Remove code that preserved
13940 the symtab_and_line's line number.
13941
13942 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13943
13944 * varobj.c (varobj_create): Don't set valid_block when creating a
13945 floating varobj.
13946
13947 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13948
13949 * varobj.c (varobj_create): Remove out of date comment.
13950
13951 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13952
13953 PR mi/20395
13954 * ada-exp.y (write_var_from_sym): Pass extra parameter when
13955 updating innermost block.
13956 * parse.c (innermost_block_tracker::update): Take extra type
13957 parameter, and check types match before updating innermost block.
13958 (write_dollar_variable): Update innermost block for registers.
13959 * parser-defs.h (enum innermost_block_tracker_type): New enum.
13960 (innermost_block_tracker::innermost_block_tracker): Initialise
13961 m_types member.
13962 (innermost_block_tracker::reset): Take type parameter.
13963 (innermost_block_tracker::update): Take type parameter, and pass
13964 type through as needed.
13965 (innermost_block_tracker::m_types): New member.
13966 * varobj.c (varobj_create): Pass type when reseting innermost
13967 block.
13968
13969 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13970
13971 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
13972 * ada-lang.c (resolve_subexp): Likewise.
13973 * breakpoint.c (set_breakpoint_condition) Likewise.
13974 (watch_command_1) Likewise.
13975 * c-exp.y (variable): Likewise.
13976 * d-exp.y (PrimaryExpression): Likewise.
13977 * f-exp.y (variable): Likewise.
13978 * go-exp.y (variable): Likewise.
13979 * m2-exp.y (variable): Likewise.
13980 * objfiles.c (objfile::~objfile): Likewise.
13981 * p-exp.y (variable): Likewise.
13982 * parse.c (innermost_block): Change type.
13983 * parser-defs.h (class innermost_block_tracker): New.
13984 (innermost_block): Change to innermost_block_tracker.
13985 * printcmd.c (display_command): Switch to innermost_block API.
13986 (do_one_display): Likewise.
13987 * rust-exp.y (do_one_display): Likewise.
13988 * symfile.c (clear_symtab_users): Likewise.
13989 * varobj.c (varobj_create): Switch to innermost_block API, replace
13990 use of innermost_block with block stored on varobj object.
13991
13992 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
13993
13994 * expression.h (innermost_block): Remove declaration.
13995 * varobj.c: Add 'parser-defs.h' include.
13996
13997 2018-01-19 Tom Tromey <tom@tromey.com>
13998
13999 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
14000 symbols in the static and global blocks.
14001
14002 2018-01-19 James Clarke <jrtc27@jrtc27.com>
14003
14004 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
14005 gdb_ptrace.h, and move including gdb_wait.h ...
14006 * nat/linux-ptrace.h: ... to here.
14007
14008 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14009
14010 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
14011 inf_ptrace_detach_success.
14012 (inf_ptrace_detach_success): Add inferior parameter, use it
14013 instead of inferior_ptid, pass it to detach_inferior.
14014 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
14015 parameter.
14016 * inferior.c (detach_inferior): Add overload that takes an
14017 inferior object.
14018 * inferior.h (detach_inferior): Likewise.
14019 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
14020 use inferior_ptid, adjust call to inf_ptrace_detach_success.
14021 * linux-thread-db.c (thread_db_detach): Use inf parameter.
14022
14023 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14024
14025 * target.h (struct target_ops) <to_detach>: Add inferior
14026 parameter.
14027 (target_detach): Likewise.
14028 * target.c (dispose_inferior): Pass inferior down.
14029 (target_detach): Pass inferior down. Assert that it is equal to
14030 the current inferior.
14031 * aix-thread.c (aix_thread_detach): Pass inferior down.
14032 * corefile.c (core_file_command): Pass current_inferior() down.
14033 * corelow.c (core_detach): Add inferior parameter.
14034 * darwin-nat.c (darwin_detach): Likewise.
14035 * gnu-nat.c (gnu_detach): Likewise.
14036 * inf-ptrace.c (inf_ptrace_detach): Likewise.
14037 * infcmd.c (detach_command): Pass current_inferior() down to
14038 target_detach.
14039 * infrun.c (follow_fork_inferior): Pass parent_inf to
14040 target_detach.
14041 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
14042 target_detach.
14043 * linux-nat.c (linux_nat_detach): Add inferior parameter.
14044 * linux-thread-db.c (thread_db_detach): Likewise.
14045 * nto-procfs.c (procfs_detach): Likewise.
14046 * procfs.c (procfs_detach): Likewise.
14047 * record.c (record_detach): Likewise.
14048 * record.h (struct inferior): Forward-declare.
14049 (record_detach): Add inferior parameter.
14050 * remote-sim.c (gdbsim_detach): Likewise.
14051 * remote.c (remote_detach_1): Likewise.
14052 (remote_detach): Likewise.
14053 (extended_remote_detach): Likewise.
14054 * sol-thread.c (sol_thread_detach): Likewise.
14055 * target-debug.h (target_debug_print_inferior_p): New macro.
14056 * target-delegates.c: Re-generate.
14057 * top.c (kill_or_detach): Pass inferior down to target_detach.
14058 * windows-nat.c (windows_detach): Add inferior parameter.
14059
14060 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
14061
14062 * target.h (struct target_ops) <to_detach>: Remove args
14063 parameter.
14064 (target_detach): Likewise.
14065 * target.c (dispose_inferior): Adjust.
14066 (target_detach): Remove args parameter, adjust.
14067 * aix-thread.c (aix_thread_detach): Adjust.
14068 * corefile.c (core_file_command): Adjust.
14069 * corelow.c (core_detach): Adjust.
14070 * darwin-nat.c (darwin_detach): Adjust.
14071 * gnu-nat.c (gnu_detach): Adjust.
14072 * inf-ptrace.c (inf_ptrace_detach): Adjust.
14073 * infcmd.c (detach_command): Adjust
14074 * infrun.c (follow_fork_inferior): Adjust.
14075 (handle_vfork_child_exec_or_exit): Adjust.
14076 * linux-fork.c (linux_fork_detach): Remove args parameter.
14077 * linux-fork.h (linux_fork_detach): Likewise.
14078 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
14079 * linux-thread-db.c (thread_db_detach): Likewise.
14080 * nto-procfs.c (procfs_detach): Likewise.
14081 * procfs.c (procfs_detach): Likewise.
14082 (do_detach): Remove signo parameter.
14083 * record.c (record_detach): Remove args parameter.
14084 * record.h (record_detach): Likewise.
14085 * remote-sim.c (gdbsim_detach): Likewise.
14086 * remote.c (remote_detach_1): Likewise.
14087 (remote_detach): Likewise.
14088 (extended_remote_detach): Likewise.
14089 * sol-thread.c (sol_thread_detach): Likewise.
14090 * target-delegates.c: Re-generate.
14091 * top.c (struct qt_args) <args>: Remove field.
14092 (kill_or_detach): Don't pass args.
14093 (quit_force): Don't set args.
14094 * windows-nat.c (windows_detach): Remove args parameter.
14095
14096 2018-01-19 Yao Qi <yao.qi@linaro.org>
14097
14098 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
14099 (arm_linux_init_abi): Install it.
14100
14101 2018-01-19 Yao Qi <yao.qi@linaro.org>
14102
14103 * osabi.c (gdb_osabi_names): Extend the regexp for
14104 arm-linux-gnueabihf.
14105
14106 2018-01-18 Yao Qi <yao.qi@linaro.org>
14107
14108 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
14109 m_abbrevs.
14110 (abbrev_table::add_abbrev): Update.
14111 (abbrev_table::lookup_abbrev): Update.
14112
14113 2018-01-18 Yao Qi <yao.qi@linaro.org>
14114
14115 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
14116
14117 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
14118
14119 * compile/compile.c (compile_to_object): Convert "triplet_rx"
14120 to "std::string".
14121
14122 2018-01-17 Tom Tromey <tom@tromey.com>
14123
14124 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
14125
14126 2018-01-17 Tom Tromey <tom@tromey.com>
14127
14128 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
14129 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
14130 (create_array_type_with_stride): Update.
14131 * dwarf2read.c (set_die_type): Update.
14132
14133 2018-01-17 Tom Tromey <tom@tromey.com>
14134
14135 * dwarf2read.c (delayed_method_info): Remove typedef.
14136 (dwarf2_cu::method_info): Now a std::vector.
14137 (add_to_method_list): Update.
14138 (free_delayed_list): Remove.
14139 (compute_delayed_physnames): Update.
14140 (process_full_comp_unit, process_full_type_unit): Clear the method
14141 list. Remove cleanups.
14142 (psymtab_include_file_name): Add name_holder parameter. Use
14143 unique_xmalloc_ptr.
14144 (dwarf_decode_lines): Update.
14145
14146 2018-01-17 Tom Tromey <tom@tromey.com>
14147 Simon Marchi <simon.marchi@ericsson.com>
14148
14149 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
14150 (dwarf2_per_objfile::free_cached_comp_units)
14151 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
14152 (init_cutu_and_read_dies_no_follow): Update.
14153 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
14154 (dwarf2_cu::~dwarf2_cu): New.
14155 (free_heap_comp_unit, free_stack_comp_unit): Remove.
14156 (age_cached_comp_units, free_one_cached_comp_unit): Update.
14157
14158 2018-01-17 Tom Tromey <tom@tromey.com>
14159 Simon Marchi <simon.marchi@ericsson.com>
14160
14161 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
14162 (struct die_reader_specs) <abbrev_table>: New member.
14163 (struct abbrev_table): Add constructor.
14164 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
14165 <abbrev_obstack>: Now an auto_obstack.
14166 (abbrev_table_up): New typedef.
14167 (init_cu_die_reader): Add abbrev_table parameter.
14168 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
14169 Add result_dwo_abbrev_table.
14170 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
14171 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
14172 Update.
14173 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
14174 parameter.
14175 (skip_children): Update.
14176 (abbrev_table::alloc_abbrev): Rename from
14177 abbrev_table_alloc_abbrev.
14178 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
14179 (abbrev_table::lookup_abbrev): Rename from
14180 abbrev_table_lookup_abbrev.
14181 (abbrev_table_read_table): Return abbrev_table_up.
14182 (abbrev_table_free, abbrev_table_free_cleanup)
14183 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
14184 (load_partial_dies): Update.
14185
14186 2018-01-17 Tom Tromey <tom@tromey.com>
14187
14188 * dwarf2read.c (dwarf2_compute_name): Update comment.
14189 (read_func_scope, read_variable): Update.
14190 (new_symbol): Remove.
14191 (new_symbol_full): Rename to new_symbol.
14192
14193 2018-01-17 Mike Gulick <mgulick@mathworks.com>
14194
14195 PR gdb/16577
14196 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
14197 a warning instead of throwing an error, set section size to 0 and return
14198 NULL.
14199 * gdb_bfd.h (gdb_bfd_map_section): Update description.
14200
14201 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
14202
14203 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
14204 std::string.
14205 (linux_ptrace_attach_fail_reason_string): Likewise.
14206 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
14207 Likewise.
14208 (linux_ptrace_attach_fail_reason_string): Likewise.
14209 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
14210
14211 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
14212
14213 * linux-nat.c (linux_nat_attach): Remove xstrdup.
14214
14215 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
14216
14217 PR gdb/21559
14218 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
14219 checking for fs_base/gs_base fields in struct user_regs_struct.
14220 * configure: Regenerate.
14221
14222 2018-01-17 Yao Qi <yao.qi@linaro.org>
14223
14224 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
14225 function.
14226 (aarch64_linux_init_abi): Install it to gdbarch hook
14227 gcc_target_options.
14228
14229 2018-01-15 Pedro Alves <palves@redhat.com>
14230
14231 * common/signals-state-save-restore.c
14232 (save_original_signals_state): Fix typos.
14233
14234 2017-01-12 Tom Tromey <tom@tromey.com>
14235 Sergio Durigan Junior <sergiodj@redhat.com>
14236
14237 * Makefile.in (install-only): Install gdb-add-index.
14238
14239 2018-01-12 John Baldwin <jhb@FreeBSD.org>
14240
14241 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
14242
14243 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
14244
14245 * infrun.c (keep_going_pass_signal): Clear step-over info when
14246 insert_breakpoints fails.
14247
14248 2018-01-11 Pedro Alves <palves@redhat.com>
14249
14250 PR gdb/22583
14251 * infrun.c (resume): Rename to ...
14252 (resume_1): ... this.
14253 (resume): Reimplement as wrapper around resume_1.
14254
14255 2018-01-11 Pedro Alves <palves@redhat.com>
14256
14257 PR remote/22597
14258 * remote.c (remote_parse_stop_reply): Default to the last-set
14259 general thread instead of to 'magic_null_ptid'.
14260
14261 2018-01-10 Pedro Alves <palves@redhat.com>
14262
14263 * language.h (language_get_symbol_name_matcher): Rename ...
14264 (get_symbol_name_matcher): ... this.
14265 * language.c (language_get_symbol_name_matcher): Ditto.
14266 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
14267 callers adjusted.
14268
14269 2018-01-10 Pedro Alves <palves@redhat.com>
14270
14271 PR gdb/22670
14272 * dwarf2read.c
14273 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
14274 Adjust to use language_get_symbol_name_matcher instead of
14275 language_defn::la_get_symbol_name_matcher.
14276 * language.c (language_get_symbol_name_matcher): If in Ada mode
14277 and the lookup name is a verbatim match, return Ada's matcher.
14278 * language.h (language_get_symbol_name_matcher): Adjust comment.
14279 (ada_lookup_name_info::verbatim_p):: New method.
14280
14281 2018-01-10 Pedro Alves <palves@redhat.com>
14282
14283 PR gdb/22670
14284 * ada-lang.c (ada_collect_symbol_completion_matches): If the
14285 minsym's language is language_auto or language_cplus, pass down
14286 language_ada instead.
14287 * symtab.c (compare_symbol_name): Don't frob symbol language here.
14288
14289 2018-01-10 Pedro Alves <palves@redhat.com>
14290
14291 PR gdb/22670
14292 * minsyms.c (linkage_name_str): New function.
14293 (iterate_over_minimal_symbols): Use it.
14294
14295 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14296
14297 * NEWS: Document that 'info proc' now works on FreeBSD.
14298
14299 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14300
14301 * configure.ac: Check for kinfo_getfile in libutil.
14302 * configure: Regenerate.
14303 * config.in: Regenerate.
14304 * fbsd-nat.c: Include "fbsd-tdep.h".
14305 (fbsd_fetch_cmdline): New.
14306 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
14307 rather than calling error.
14308 (fbsd_info_proc): New.
14309 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
14310 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
14311 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
14312
14313 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14314
14315 * fbsd-nat.c (struct free_deleter): Remove.
14316 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
14317
14318 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14319
14320 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
14321 NULL for an empty pathname.
14322
14323 2018-01-09 John Baldwin <jhb@FreeBSD.org>
14324
14325 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
14326 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
14327 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
14328 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
14329 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
14330 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
14331 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
14332 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
14333 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
14334 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
14335 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
14336 (fbsd_core_fetch_timeval, fbsd_print_sigset)
14337 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
14338 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
14339 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
14340
14341 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
14342
14343 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
14344 (gnu_xfer_auxv): New function.
14345 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
14346 TARGET_OBJECT_AUXV.
14347
14348 2018-01-08 Yao Qi <yao.qi@linaro.org>
14349 Simon Marchi <simon.marchi@ericsson.com>
14350
14351 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
14352 common/selftest.c.
14353 (COMMON_OBS): Remove selftest.o.
14354 * configure.ac: Append selftest-arch.c and common/selftest.c to
14355 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
14356 * configure: Re-generated.
14357 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
14358 GDB_SELF_TEST.
14359 (maintenance_info_selftests): Likewise.
14360
14361 2018-01-08 Xavier Roirand <roirand@adacore.com>
14362
14363 * ada-valprint.c (val_print_packed_array_elements): Use
14364 proper number of elements when printing an array indexed
14365 by an enumeration type.
14366
14367 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14368
14369 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
14370 (dw2_get_file_names_reader): Adjust.
14371 (lookup_dwo_signatured_type): Adjust.
14372 (lookup_dwp_signatured_type): Adjust.
14373 (lookup_signatured_type): Adjust.
14374 (create_type_unit_group): Adjust.
14375 (get_type_unit_group): Adjust.
14376 (process_psymtab_comp_unit_reader): Adjust.
14377 (build_type_psymtabs_reader): Adjust.
14378 (scan_partial_symbols): Adjust.
14379 (add_partial_symbol): Adjust.
14380 (add_partial_subprogram): Adjust.
14381 (peek_die_abbrev): Adjust.
14382 (fixup_go_packaging): Adjust.
14383 (process_imported_unit_die): Adjust.
14384 (dwarf2_compute_name): Adjust.
14385 (dwarf2_physname): Adjust.
14386 (read_import_statement): Adjust.
14387 (handle_DW_AT_stmt_list): Adjust.
14388 (read_file_scope): Adjust.
14389 (read_func_scope): Adjust.
14390 (read_lexical_block_scope): Adjust.
14391 (read_call_site_scope): Adjust.
14392 (read_variable): Adjust.
14393 (dwarf2_rnglists_process): Adjust.
14394 (dwarf2_ranges_process): Adjust.
14395 (dwarf2_ranges_read): Adjust.
14396 (dwarf2_get_pc_bounds): Adjust.
14397 (dwarf2_record_block_ranges): Adjust.
14398 (dwarf2_add_field): Adjust.
14399 (dwarf2_add_member_fn): Adjust.
14400 (read_structure_type): Adjust.
14401 (process_structure_scope): Adjust.
14402 (read_enumeration_type): Adjust.
14403 (read_array_type): Adjust.
14404 (mark_common_block_symbol_computed): Adjust.
14405 (read_common_block): Adjust.
14406 (read_namespace_type): Adjust.
14407 (read_namespace): Adjust.
14408 (read_module_type): Adjust.
14409 (read_tag_pointer_type): Adjust.
14410 (read_tag_ptr_to_member_type): Adjust.
14411 (read_tag_string_type): Adjust.
14412 (read_subroutine_type): Adjust.
14413 (read_typedef): Adjust.
14414 (read_base_type): Adjust.
14415 (attr_to_dynamic_prop): Adjust.
14416 (read_subrange_type): Adjust.
14417 (read_unspecified_type): Adjust.
14418 (dwarf2_read_abbrevs): Adjust.
14419 (load_partial_dies): Adjust.
14420 (read_partial_die): Adjust.
14421 (find_partial_die): Adjust.
14422 (guess_partial_die_structure_name): Adjust.
14423 (fixup_partial_die): Adjust.
14424 (read_attribute_value): Adjust.
14425 (read_addr_index): Adjust.
14426 (read_addr_index_from_leb128): Adjust.
14427 (read_str_index): Adjust.
14428 (dwarf2_string_attr): Adjust.
14429 (get_debug_line_section): Adjust.
14430 (dwarf_decode_line_header): Adjust.
14431 (lnp_state_machine::check_line_address): Adjust.
14432 (dwarf_decode_lines_1): Adjust.
14433 (dwarf_decode_lines): Adjust.
14434 (dwarf2_start_symtab): Adjust.
14435 (var_decode_location): Adjust.
14436 (new_symbol_full): Adjust.
14437 (dwarf2_const_value_data): Adjust.
14438 (dwarf2_const_value_attr): Adjust.
14439 (dwarf2_const_value): Adjust.
14440 (die_type): Adjust.
14441 (die_containing_type): Adjust.
14442 (build_error_marker_type): Adjust.
14443 (lookup_die_type): Adjust.
14444 (guess_full_die_structure_name): Adjust.
14445 (anonymous_struct_prefix): Adjust.
14446 (determine_prefix): Adjust.
14447 (dwarf2_name): Adjust.
14448 (follow_die_ref_or_sig): Adjust.
14449 (follow_die_offset): Adjust.
14450 (follow_die_ref): Adjust.
14451 (follow_die_sig_1): Adjust.
14452 (follow_die_sig): Adjust.
14453 (get_signatured_type): Adjust.
14454 (get_DW_AT_signature_type): Adjust.
14455 (decode_locdesc): Adjust.
14456 (dwarf_decode_macros): Adjust.
14457 (cu_debug_loc_section): Adjust.
14458 (fill_in_loclist_baton): Adjust.
14459 (dwarf2_symbol_mark_computed): Adjust.
14460 (init_one_comp_unit): Don't assign
14461 dwarf2_cu::dwarf2_per_objfile.
14462 (set_die_type): Adjust.
14463
14464 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14465
14466 * dwarf2read.c (struct mapped_debug_names): Add constructor.
14467 <dwarf2_per_objfile>: New field.
14468 (dwarf2_per_objfile): Remove global.
14469 (get_dwarf2_per_objfile): New function.
14470 (set_dwarf2_per_objfile): New function.
14471 (dwarf2_build_psymtabs_hard): Change objfile parameter to
14472 dwarf2_per_objfile.
14473 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14474 (read_abbrev_offset): Likewise.
14475 (read_indirect_string): Likewise.
14476 (read_indirect_line_string): Likewise.
14477 (read_indirect_string_at_offset): Likewise.
14478 (read_indirect_string_from_dwz): Likewise.
14479 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14480 dwarf2_per_objfile.
14481 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14482 (create_all_comp_units): Change objfile parameter to
14483 dwarf2_per_objfile.
14484 (create_all_type_units): Likewise.
14485 (process_queue): Add dwarf2_per_objfile parameter.
14486 (read_and_check_comp_unit_head): Likewise.
14487 (lookup_dwo_unit_in_dwp): Likewise.
14488 (get_dwp_file): Likewise.
14489 (process_cu_includes): Likewise.
14490 (struct free_dwo_file_cleanup_data): New struct.
14491 (dwarf2_has_info): Use get_dwarf2_per_objfile and
14492 set_dwarf2_per_objfile.
14493 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
14494 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
14495 context, adjust calls.
14496 (dw2_instantiate_symtab): Likewise.
14497 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
14498 (dw2_get_cu): Likewise.
14499 (create_cu_from_index_list): Change objfile parameter to
14500 dwarf2_per_objfile.
14501 (create_cus_from_index_list): Get dwarf2_per_objfile from
14502 context, adjust calls.
14503 (create_cus_from_index): Likewise.
14504 (create_signatured_type_table_from_index): Change objfile
14505 parameter to dwarf2_per_objfile.
14506 (create_signatured_type_table_from_debug_names): Change objfile
14507 parameter to dwarf2_per_objfile.
14508 (create_addrmap_from_index): Likewise.
14509 (create_addrmap_from_aranges): Likewise.
14510 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
14511 (dw2_setup): Remove.
14512 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
14513 context.
14514 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
14515 get_dwarf2_per_objfile.
14516 (dw2_forget_cached_source_info): Likewise.
14517 (dw2_map_symtabs_matching_filename): Likewise.
14518 (struct dw2_symtab_iterator) <index>: Remove.
14519 <dwarf2_per_objfile>: New field.
14520 (dw2_symtab_iter_init): Replace index parameter with
14521 dwarf2_per_objfile.
14522 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
14523 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
14524 (dw2_print_stats): Likewise.
14525 (dw2_dump): Likewise.
14526 (dw2_expand_symtabs_for_function): Likewise.
14527 (dw2_expand_all_symtabs): Likewise.
14528 (dw2_expand_symtabs_with_fullname): Likewise.
14529 (dw2_expand_marked_cus): Replace index and objfile parameters
14530 with dwarf2_per_objfile.
14531 (dw_expand_symtabs_matching_file_matcher): Add
14532 dwarf2_per_objfile parameter and adjust calls.
14533 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
14534 adjust calls.
14535 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
14536 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
14537 adjust calls.
14538 (create_cus_from_debug_names_list): Replace objfile parameter
14539 with dwarf2_per_objfile and adjust calls.
14540 (create_cus_from_debug_names): Likewise.
14541 (dwarf2_read_debug_names): Likewise.
14542 (mapped_debug_names::namei_to_name): Adjust call.
14543 (dw2_debug_names_iterator::next): Likewise.
14544 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
14545 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
14546 (dw2_debug_names_dump): Likewise.
14547 (dw2_debug_names_expand_symtabs_for_function): Likewise.
14548 (dw2_debug_names_expand_symtabs_matching): Likewise.
14549 (dwarf2_initialize_objfile): Likewise.
14550 (dwarf2_build_psymtabs): Likewise.
14551 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
14552 this_cu.
14553 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
14554 (read_and_check_comp_unit_head): Likewise.
14555 (read_abbrev_offset): Likewise.
14556 (create_debug_type_hash_table): Likewise.
14557 (create_debug_types_hash_table): Likewise.
14558 (create_all_type_units): Replace objfile parameter with
14559 dwarf2_per_objfile.
14560 (add_type_unit): Add dwarf2_per_objfile parameter.
14561 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
14562 with dwarf2_per_objfile.
14563 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
14564 (lookup_dwp_signatured_type): Likewise.
14565 (lookup_signatured_type): Likewise.
14566 (read_cutu_die_from_dwo): Likewise.
14567 (init_tu_and_read_dwo_dies): Likewise.
14568 (init_cutu_and_read_dies): Likewise.
14569 (init_cutu_and_read_dies_no_follow): Likewise.
14570 (allocate_type_unit_groups_table): Add objfile parameter.
14571 (create_type_unit_group): Use dwarf2_per_objfile from cu.
14572 (get_type_unit_group): Likewise.
14573 (process_psymtab_comp_unit): Update call.
14574 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
14575 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
14576 (print_tu_stats): Likewise.
14577 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
14578 in void* parameter.
14579 (build_type_psymtabs): Change objfile parameter to
14580 dwarf2_per_objfile.
14581 (process_skeletonless_type_unit): Use dwarf2_per_objfile
14582 passed in void* parameter.
14583 (process_skeletonless_type_units): Change objfile parameter to
14584 dwarf2_per_objfile.
14585 (set_partial_user): Likewise.
14586 (dwarf2_build_psymtabs_hard): Likewise.
14587 (read_comp_units_from_section): Likewise.
14588 (create_all_comp_units): Likewise.
14589 (scan_partial_symbols): Update calls.
14590 (add_partial_symbol): Likewise.
14591 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
14592 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
14593 (process_queue): Add dwarf2_per_objfile parameter.
14594 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
14595 (compute_compunit_symtab_includes): Likewise.
14596 (process_cu_includes): Add dwarf2_per_objfile parameter.
14597 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
14598 (process_full_type_unit): Likewise.
14599 (process_imported_unit_die): Update call.
14600 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
14601 (read_file_scope): Likewise.
14602 (allocate_dwo_file_hash_table): Add objfile parameter.
14603 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
14604 (create_cus_hash_table): Likewise.
14605 (create_dwp_hash_table): Likewise.
14606 (create_dwo_unit_in_dwp_v1): Likewise.
14607 (create_dwp_v2_section): Likewise.
14608 (create_dwo_unit_in_dwp_v2): Likewise.
14609 (lookup_dwo_unit_in_dwp): Likewise.
14610 (try_open_dwop_file): Likewise.
14611 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
14612 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
14613 cleanup to include a reference to dwarf2_per_objfile.
14614 (open_dwp_file): Add dwarf2_per_objfile parameter.
14615 (open_and_init_dwp_file): Likewise.
14616 (get_dwp_file): Likewise.
14617 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
14618 (queue_and_load_all_dwo_tus): Update call.
14619 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
14620 data.
14621 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
14622 (dwarf2_ranges_process): Likewise.
14623 (dwarf2_get_pc_bounds): Likewise.
14624 (mark_common_block_symbol_computed): Likewise.
14625 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
14626 (dwarf2_read_abbrevs): Update call.
14627 (read_partial_die): Use dwarf2_per_objfile from cu.
14628 (find_partial_die): Likewise.
14629 (fixup_partial_die): Likewise.
14630 (read_attribute_value): Likewise.
14631 (read_indirect_string_at_offset_from): Add objfile parameter.
14632 (read_indirect_string_at_offset): Add dwarf2_per_objfile
14633 parameter.
14634 (read_indirect_string_from_dwz): Add objfile parameter.
14635 (read_indirect_string): Add objfile parameter.
14636 (read_addr_index_1): Add dwarf2_per_objfile parameter.
14637 (read_addr_index): Use dwarf2_per_objfile from cu.
14638 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
14639 call dw2_setup.
14640 (read_str_index): Use dwarf2_per_objfile from cu.
14641 (get_debug_line_section): Likewise.
14642 (read_formatted_entries): Add dwarf2_per_objfile parameter.
14643 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
14644 (new_symbol_full): Use dwarf2_per_objfile from cu.
14645 (build_error_marker_type): Likewise.
14646 (lookup_die_type): Likewise.
14647 (determine_prefix): Likewise.
14648 (follow_die_offset): Likewise.
14649 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
14650 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
14651 (dwarf2_fetch_die_type_sect_off): Likewise.
14652 (dwarf2_get_die_type): Likewise.
14653 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
14654 (get_signatured_type): Likewise.
14655 (get_DW_AT_signature_type): Likewise.
14656 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
14657 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
14658 (cu_debug_loc_section): Likewise.
14659 (fill_in_loclist_baton): Likewise.
14660 (dwarf2_symbol_mark_computed): Likewise.
14661 (dwarf2_find_containing_comp_unit): Change objfile parameter to
14662 dwarf2_per_objfile.
14663 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
14664 parameter.
14665 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
14666 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
14667 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
14668 (set_die_type): Use dwarf2_free_objfile from cu.
14669 (get_die_type_at_offset): Likewise.
14670 (dwarf2_per_objfile_free): Don't assign global variable.
14671 (debug_names) <constructor>: Add dwarf2_per_objfile
14672 parameter, update m_debugstrlookup construction.
14673 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
14674 parameter.
14675 <m_dwarf2_per_objfile>: New field.
14676 <lookup>: Use m_dwarf2_per_objfile.
14677 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
14678 (psyms_seen_size): Likewise.
14679 (write_gdbindex): Replace objfile parameter with
14680 dwarf2_per_objfile.
14681 (write_debug_names): Likewise.
14682 (write_psymtabs_to_index): Likewise.
14683 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
14684 calls.
14685
14686 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14687
14688 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
14689 <dwarf2_per_objfile>: New field.
14690 (struct dwarf2_per_cu_data) <objfile>: Remove.
14691 <dwarf2_per_objfile>: New field.
14692 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
14693 of objfile.
14694 (create_signatured_type_table_from_index): Likewise.
14695 (create_debug_type_hash_table): Likewise.
14696 (fill_in_sig_entry_from_dwo_entry): Likewise.
14697 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
14698 (create_type_unit_group): Assign dwarf2_per_objfile instead of
14699 objfile.
14700 (create_partial_symtab): Access objfile through
14701 dwarf2_per_objfile.
14702 (process_psymtab_comp_unit_reader): Likewise.
14703 (read_comp_units_from_section): Likewise.
14704 (scan_partial_symbols): Likewise.
14705 (add_partial_symbol): Likewise.
14706 (add_partial_subprogram): Likewise.
14707 (peek_die_abbrev): Likewise.
14708 (fixup_go_packaging): Likewise.
14709 (process_full_comp_unit): Likewise.
14710 (process_full_type_unit): Likewise.
14711 (process_imported_unit_die): Likewise.
14712 (dwarf2_compute_name): Likewise.
14713 (dwarf2_physname): Likewise.
14714 (read_import_statement): Likewise.
14715 (create_cus_hash_table): Assign dwarf2_physname instead of
14716 objfile.
14717 (read_func_scope): Access objfile through dwarf2_per_objfile.
14718 (read_lexical_block_scope): Likewise.
14719 (read_call_site_scope): Likewise.
14720 (read_variable): Likewise.
14721 (dwarf2_rnglists_process): Likewise.
14722 (dwarf2_ranges_process): Likewise.
14723 (dwarf2_ranges_read): Likewise.
14724 (dwarf2_record_block_ranges): Likewise.
14725 (dwarf2_add_field): Likewise.
14726 (dwarf2_add_member_fn): Likewise.
14727 (read_structure_type): Likewise.
14728 (process_structure_scope): Likewise.
14729 (read_enumeration_type): Likewise.
14730 (read_array_type): Likewise.
14731 (read_common_block): Likewise.
14732 (read_namespace_type): Likewise.
14733 (read_namespace): Likewise.
14734 (read_module_type): Likewise.
14735 (read_tag_pointer_type): Likewise.
14736 (read_tag_ptr_to_member_type): Likewise.
14737 (read_tag_string_type): Likewise.
14738 (read_subroutine_type): Likewise.
14739 (read_typedef): Likewise.
14740 (read_base_type): Likewise.
14741 (attr_to_dynamic_prop): Likewise.
14742 (read_subrange_type): Likewise.
14743 (read_unspecified_type): Likewise.
14744 (load_partial_dies): Likewise.
14745 (read_partial_die): Likewise.
14746 (find_partial_die): Likewise.
14747 (guess_partial_die_structure_name): Likewise.
14748 (fixup_partial_die): Likewise.
14749 (read_attribute_value): Likewise.
14750 (read_addr_index_from_leb128): Likewise.
14751 (dwarf2_read_addr_index): Likewise.
14752 (dwarf2_string_attr): Likewise.
14753 (lnp_state_machine::check_line_address): Likewise.
14754 (dwarf_decode_lines_1): Likewise.
14755 (dwarf_decode_lines): Likewise.
14756 (dwarf2_start_symtab): Likewise.
14757 (var_decode_location): Likewise.
14758 (new_symbol_full): Likewise.
14759 (dwarf2_const_value_data): Likewise.
14760 (dwarf2_const_value_attr): Likewise.
14761 (dwarf2_const_value): Likewise.
14762 (die_type): Likewise.
14763 (die_containing_type): Likewise.
14764 (lookup_die_type): Likewise.
14765 (guess_full_die_structure_name): Likewise.
14766 (anonymous_struct_prefix): Likewise.
14767 (dwarf2_name): Likewise.
14768 (follow_die_ref_or_sig): Likewise.
14769 (follow_die_offset): Likewise.
14770 (follow_die_ref): Likewise.
14771 (dwarf2_fetch_die_loc_sect_off): Likewise.
14772 (dwarf2_fetch_constant_bytes): Likewise.
14773 (dwarf2_fetch_die_type_sect_off): Likewise.
14774 (dwarf2_get_die_type): Likewise.
14775 (follow_die_sig): Likewise.
14776 (decode_locdesc): Likewise.
14777 (dwarf2_per_cu_objfile): Likewise.
14778 (dwarf2_per_cu_text_offset): Likewise.
14779 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
14780 objfile.
14781 (set_die_type): Access objfile through
14782 dwarf2_per_objfile.
14783
14784 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
14785
14786 * valprint.c (converted_character_d): Remove typedef.
14787 (DEF_VEC_O (converted_character_d)): Remove.
14788 (count_next_character): Use std::vector.
14789 (print_converted_chars_to_obstack): Likewise.
14790 (generic_printstr): Likewise.
14791
14792 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14793
14794 * xml-support.h (struct gdb_xml_value): Add constructor.
14795 <value>: Change type to unique_xmalloc_ptr.
14796 (gdb_xml_value_s): Remove typedef.
14797 (DEF_VEC_O (gdb_xml_value_s)): Remove.
14798 (gdb_xml_element_start_handler): Change parameter type to
14799 std::vector.
14800 (xml_find_attribute): Likewise.
14801 * xml-support.c (xml_find_attribute): Change parameter type to
14802 std::vector and adjust.
14803 (gdb_xml_values_cleanup): Remove.
14804 (gdb_xml_parser::start_element): Adjust to std::vector.
14805 (xinclude_start_include): Change paraeter type to std::vector
14806 and adjust.
14807 * btrace.c (check_xml_btrace_version): Likewise.
14808 (parse_xml_btrace_block): Likewise.
14809 (parse_xml_btrace_pt_config_cpu): Likewise.
14810 (parse_xml_btrace_pt): Likewise.
14811 (parse_xml_btrace_conf_bts): Likewise.
14812 (parse_xml_btrace_conf_pt): Likewise.
14813 * memory-map.c (memory_map_start_memory): Likewise.
14814 (memory_map_start_property): Likewise.
14815 * osdata.c (osdata_start_osdata): Likewise.
14816 (osdata_start_item): Likewise.
14817 (osdata_start_column): Likewise.
14818 * remote.c (start_thread): Likewise.
14819 * solib-aix.c (library_list_start_library): Likewise.
14820 (library_list_start_list): Likewise.
14821 * solib-svr4.c (library_list_start_library): Likewise.
14822 (svr4_library_list_start_list): Likewise.
14823 * solib-target.c (library_list_start_segment): Likewise.
14824 (library_list_start_section): Likewise.
14825 (library_list_start_library): Likewise.
14826 (library_list_start_list): Likewise.
14827 * tracepoint.c (traceframe_info_start_memory): Likewise.
14828 (traceframe_info_start_tvar): Likewise.
14829 * xml-syscall.c (syscall_start_syscall): Likewise.
14830 * xml-tdesc.c (tdesc_start_target): Likewise.
14831 (tdesc_start_feature): Likewise.
14832 (tdesc_start_reg): Likewise.
14833 (tdesc_start_union): Likewise.
14834 (tdesc_start_struct): Likewise.
14835 (tdesc_start_flags): Likewise.
14836 (tdesc_start_enum): Likewise.
14837 (tdesc_start_field): Likewise.
14838 (tdesc_start_enum_value): Likewise.
14839 (tdesc_start_vector): Likewise.
14840
14841 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14842
14843 * extension.h (struct xmethod_worker) <clone>: Remove.
14844 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
14845 Remove.
14846 (python_xmethod_worker::clone): Remove.
14847 * valops.c (find_overload_match): Use std::move instead of
14848 clone.
14849
14850 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
14851
14852 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
14853 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
14854 <free_xmethod_worker_data>: Remove.
14855 <get_matching_xmethod_workers>: Chance VEC to std::vector.
14856 <get_xmethod_arg_types>: Remove.
14857 <get_xmethod_result_type>: Remove.
14858 <invoke_xmethod>: Remove.
14859 * extension.c (new_xmethod_worker): Remove.
14860 (clone_xmethod_worker): Remove.
14861 (get_matching_xmethod_workers): Return void, pass std::vector by
14862 pointer.
14863 (get_xmethod_arg_types): Rename to...
14864 (xmethod_worker::get_arg_types): ... this, and adjust.
14865 (get_xmethod_result_type): Rename to...
14866 (xmethod_worker::get_result_type): ... this, and adjust.
14867 (invoke_xmethod): Remove.
14868 (free_xmethod_worker): Remove.
14869 (free_xmethod_worker_vec): Remove.
14870 * extension.h (enum ext_lang_rc): Move here from
14871 extension-priv.h.
14872 (struct xmethod_worker): Add constructor and destructor.
14873 <data>: Remove.
14874 <value>: Remove.
14875 <invoke, clone, do_get_result_type, do_get_arg_types>: New
14876 virtual pure methods.
14877 <get_arg_types, get_result_type>: New methods.
14878 (xmethod_worker_ptr): Remove typedef.
14879 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
14880 (xmethod_worker_vec): Remove typedef.
14881 (xmethod_worker_up): New typedef.
14882 (invoke_xmethod): Remove.
14883 (clone_xmethod_worker): Remove.
14884 (free_xmethod_worker): Remove.
14885 (free_xmethod_worker_vec): Remove.
14886 (get_xmethod_arg_types): Remove.
14887 (get_xmethod_result_type): Remove.
14888 * valops.c (find_method_list): Use std::vector, don't use
14889 intermediate vector.
14890 (value_find_oload_method_list): Use std::vector.
14891 (find_overload_match): Use std::vector.
14892 (find_oload_champ): Use std::vector.
14893 * value.c (value_free): Use operator delete.
14894 (value_of_xmethod): Rename to...
14895 (value_from_xmethod): ... this. Don't assign
14896 xmethod_worker::value, take rvalue-reference.
14897 (result_type_of_xmethod): Adjust.
14898 (call_xmethod): Adjust.
14899 * value.h: Include extension.h.
14900 (struct xmethod_worker): Don't forward-declare.
14901 (value_of_xmethod): Rename to...
14902 (value_from_xmethod): ... this, take rvalue-reference.
14903 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
14904 (struct python_xmethod_worker): ... this, add constructor and
14905 destructor.
14906 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
14907 (gdbpy_free_xmethod_worker_data): Rename to...
14908 (python_xmethod_worker::~python_xmethod_worker): ... this and
14909 adjust.
14910 (gdbpy_clone_xmethod_worker_data): Rename to...
14911 (python_xmethod_worker::clone): ... this and adjust.
14912 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
14913 temporary vector.
14914 (gdbpy_get_xmethod_arg_types): Rename to...
14915 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
14916 (gdbpy_get_xmethod_result_type): Rename to...
14917 (python_xmethod_worker::do_get_result_type): ... this and
14918 adjust.
14919 (gdbpy_invoke_xmethod): Rename to...
14920 (python_xmethod_worker::invoke): ... this and adjust.
14921 (new_python_xmethod_worker): Rename to...
14922 (python_xmethod_worker::python_xmethod_worker): ... this and
14923 adjust.
14924 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
14925 Remove.
14926 (gdbpy_free_xmethod_worker_data): Remove.
14927 (gdbpy_get_matching_xmethod_workers): Use std::vector.
14928 (gdbpy_get_xmethod_arg_types): Remove.
14929 (gdbpy_get_xmethod_result_type): Remove.
14930 (gdbpy_invoke_xmethod): Remove.
14931 * python/python.c (python_extension_ops): Remove obsolete
14932 callbacks.
14933
14934 2018-01-05 Pedro Alves <palves@redhat.com>
14935
14936 PR gdb/18653
14937 * common/signals-state-save-restore.c
14938 (save_original_signals_state): New parameter 'quiet'. Warn if we
14939 find a custom handler preinstalled, instead of internal erroring.
14940 But only warn if !quiet.
14941 * common/signals-state-save-restore.h
14942 (save_original_signals_state): New parameter 'quiet'.
14943 * main.c (captured_main_1): Move save_original_signals_state call
14944 after option handling, and pass QUIET.
14945
14946 2018-01-05 Pedro Alves <palves@redhat.com>
14947
14948 * spu-tdep.c (spu_catch_start): Pass
14949 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
14950
14951 2018-01-05 Pedro Alves <palves@redhat.com>
14952
14953 PR gdb/22670
14954 * ada-lang.c (literal_symbol_name_matcher): New function.
14955 (ada_get_symbol_name_matcher): Use it for
14956 symbol_name_match_type::SEARCH_NAME.
14957 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
14958 it down instead of assuming symbol_name_match_type::FULL.
14959 * block.h (block_lookup_symbol): New parameter 'match_type'.
14960 * c-valprint.c (print_unpacked_pointer): Use
14961 lookup_symbol_search_name instead of lookup_symbol.
14962 * compile/compile-object-load.c (get_out_value_type): Pass down
14963 symbol_name_match_type::SEARCH_NAME.
14964 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
14965 symbol_name_match_type::FULL.
14966 * cp-support.c (cp_get_symbol_name_matcher): Handle
14967 symbol_name_match_type::SEARCH_NAME.
14968 * infrun.c (insert_exception_resume_breakpoint): Use
14969 lookup_symbol_search_name.
14970 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
14971 * psymtab.c (maintenance_check_psymtabs): Use
14972 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
14973 * stack.c (print_frame_args): Use lookup_symbol_search_name and
14974 SYMBOL_SEARCH_NAME.
14975 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
14976 if symbol_name_match_type::SEARCH_NAME.
14977 (lookup_symbol_in_language): Pass down
14978 symbol_name_match_type::FULL.
14979 (lookup_symbol_search_name): New.
14980 (lookup_language_this): Pass down
14981 symbol_name_match_type::SEARCH_NAME.
14982 (lookup_symbol_aux, lookup_local_symbol): New parameter
14983 'match_type'. Pass it down.
14984 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
14985 (lookup_symbol_search_name): New declaration.
14986 (lookup_symbol_in_block): New 'match_type' parameter.
14987
14988 2018-01-05 Pedro Alves <palves@redhat.com>
14989
14990 PR gdb/22670
14991 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
14992 ada_lookup_symbol.
14993 (ada_lookup_symbol): Reimplement in terms of
14994 ada_lookup_symbol_list, bits factored out from
14995 ada_lookup_encoded_symbol.
14996
14997 2018-01-05 Joel Brobecker <brobecker@adacore.com>
14998
14999 * ada-exp.y (write_object_renaming): When subscripting an array
15000 using a symbol as the index, pass the block in call to
15001 ada_lookup_encoded_symbol when looking that symbol up.
15002
15003 2018-01-05 Jerome Guitton <guitton@adacore.com>
15004
15005 * ada-lang.c (ada_array_length): Use ada_index_type instead of
15006 TYPE_INDEX_TYPE.
15007
15008 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15009
15010 * ada-lang.c (ada_to_fixed_value_create): Add handling of
15011 the case where VALUE_LVAL (val0) is not lval_memory.
15012
15013 2018-01-05 Xavier Roirand <roirand@adacore.com>
15014
15015 * ada-valprint.c (print_optional_low_bound): Handle
15016 character-indexed array printing like boolean-indexed array
15017 printing.
15018
15019 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15020
15021 * NEWS: Create a new section for the next release branch.
15022 Rename the section of the current branch, now that it has
15023 been cut.
15024
15025 2018-01-05 Joel Brobecker <brobecker@adacore.com>
15026
15027 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
15028 * version.in: Bump version to 8.1.50.DATE-git.
15029
15030 2018-01-03 Xavier Roirand <roirand@adacore.com>
15031
15032 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
15033 Add field.
15034 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
15035 Add field.
15036 (default_exception_support_info) <catch_handlers_sym>: Add field.
15037 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
15038 (ada_exception_name_addr_1): Add "catch handlers" handling.
15039 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
15040 Update all callers.
15041 (create_excep_cond_exprs) <ex>: Add parameter.
15042 (re_set_exception): Update create_excep_cond_exprs call.
15043 (print_it_exception, print_one_exception, print_mention_exception)
15044 (print_recreate_exception): Add "catch handler" handling.
15045 (allocate_location_catch_handlers, re_set_catch_handlers)
15046 (check_status_catch_handlers, print_it_catch_handlers)
15047 (print_one_catch_handlers, print_mention_catch_handlers)
15048 (print_recreate_catch_handlers): New function.
15049 (catch_handlers_breakpoint_ops): New variable.
15050 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
15051 Add parameter. Add "catch handler" handling.
15052 (ada_exception_sym_name, ada_exception_breakpoint_ops):
15053 Add "catch handler" handling.
15054 (ada_exception_catchpoint_cond_string): Add "catch handler"
15055 handling.
15056 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
15057 call.
15058 (catch_ada_handlers_command): New function.
15059 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
15060 operations structure.
15061 (_initialize_ada_language): Add "catch handlers" command entry.
15062 * NEWS: Document "catch handlers" feature.
15063
15064 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15065
15066 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
15067 account when creating the array type of the slice.
15068 (ada_value_slice): Likewise.
15069
15070 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15071
15072 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
15073 New enum value.
15074 (create_array_type_with_stride): Add byte_stride_prop parameter.
15075 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
15076 New parameter. Update all callers in this file.
15077 (array_type_has_dynamic_stride): New function.
15078 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
15079 of arrays with dynamic byte strides.
15080 * dwarf2read.c (read_array_type): Add support for dynamic
15081 DW_AT_byte_stride attributes.
15082
15083 2018-01-02 Joel Brobecker <brobecker@adacore.com>
15084
15085 * dwarf2read.c (read_unspecified_type): Treat
15086 DW_TAG_enumeration_type DIEs from Ada units as stubs.
15087
15088 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15089
15090 Update copyright year range in all GDB files.
15091
15092 2018-01-01, 18 Joel Brobecker <brobecker@adacore.com>
15093
15094 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
15095 and gdb/testsuite/gdb.base/step-line.c.
15096
15097 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15098
15099 * copyright.py (main): Dump the contents of
15100 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
15101 even if BY_HAND is empty.
15102
15103 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15104
15105 * top.c (print_gdb_version): Update Copyright year in version
15106 message.
15107
15108 2018-01-01 Joel Brobecker <brobecker@adacore.com>
15109
15110 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
15111
15112 For older changes see ChangeLog-2017.
15113 \f
15114 Local Variables:
15115 mode: change-log
15116 left-margin: 8
15117 fill-column: 74
15118 version-control: never
15119 coding: utf-8
15120 End:
This page took 0.368698 seconds and 4 git commands to generate.