Move fixup_partial_die to partial_die_info::fixup
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2018-02-26 Yao Qi <yao.qi@linaro.org>
2
3 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
4 (fixup_partial_die): Remove declaration.
5 (scan_partial_symbols): Update.
6 (partial_die_parent_scope): Likewise.
7 (partial_die_full_name): Likewise.
8 (fixup_partial_die): Change it to partial_die_info::fixup.
9
10 2018-02-26 Yao Qi <yao.qi@linaro.org>
11
12 * dwarf2read.c (read_partial_die): Update the declaration.
13 (load_partial_dies): Caller update.
14 (read_partial_die): Remove one argument abbrev_len.
15
16 2018-02-26 Yao Qi <yao.qi@linaro.org>
17
18 * dwarf2read.c (struct partial_die_info): Add ctor, delete
19 assignment operator.
20 (load_partial_dies): Use ctor and copy ctor.
21 (read_partial_die): Update.
22 (dwarf2_cu::find_partial_die): Use ctor.
23
24 2018-02-26 Yao Qi <yao.qi@linaro.org>
25
26 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
27 (find_partial_die_in_comp_unit): Change it to
28 dwarf2_cu::find_partial_die.
29 (find_partial_die): Update.
30
31 2018-02-26 Yao Qi <yao.qi@linaro.org>
32
33 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
34 is NULL.
35
36 2018-02-26 Yao Qi <yao.qi@linaro.org>
37
38 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
39
40 2018-02-26 Alan Hayward <alan.hayward@arm.com>
41
42 * arch/amd64.h: Use common/tdesc.h.
43 * arch/i386.c: Likewise.
44 * arch/i386.h: Likewise.
45 * arch/tic6x.c: Likewise.
46 * arch/tdesc.h: Move file from here...
47 * common/tdesc.h: ...to here.
48 * features/aarch64-core.c: Regenerate.
49 * features/aarch64-fpu.c: Regenerate.
50 * features/i386/32bit-avx.c: Regenerate.
51 * features/i386/32bit-avx512.c: Regenerate.
52 * features/i386/32bit-core.c: Regenerate.
53 * features/i386/32bit-linux.c: Regenerate.
54 * features/i386/32bit-mpx.c: Regenerate.
55 * features/i386/32bit-pkeys.c: Regenerate.
56 * features/i386/32bit-sse.c: Regenerate.
57 * features/i386/64bit-avx.c: Regenerate.
58 * features/i386/64bit-avx512.c: Regenerate.
59 * features/i386/64bit-core.c: Regenerate.
60 * features/i386/64bit-linux.c: Regenerate.
61 * features/i386/64bit-mpx.c: Regenerate.
62 * features/i386/64bit-pkeys.c: Regenerate.
63 * features/i386/64bit-segments.c: Regenerate.
64 * features/i386/64bit-sse.c: Regenerate.
65 * features/i386/x32-core.c: Regenerate.
66 * features/tic6x-c6xp.c: Regenerate.
67 * features/tic6x-core.c: Regenerate.
68 * features/tic6x-gp.c: Regenerate.
69 * target-descriptions.c: Use common/tdesc.h.
70 * target-descriptions.h: Likewise.
71
72 2018-02-24 Tom Tromey <tom@tromey.com>
73
74 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
75 (try_thread_db_load_from_dir, thread_db_load_search): Use
76 std::string.
77 (info_auto_load_libthread_db_compare): Return bool. Change
78 argument types.
79 (info_auto_load_libthread_db): Use std::vector, std::string.
80 Remove cleanups.
81
82 2018-02-24 Tom Tromey <tom@tromey.com>
83
84 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
85 std::string.
86 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
87 std::string*.
88 * gdbarch.c: Rebuild.
89 * gdbarch.h: Rebuild.
90 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
91 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
92 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
93 std::string*.
94
95 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
96
97 * gdbtypes.h (sect_offset): Change type to uint64_t.
98 (sect_offset_str): New function.
99 * dwarf2read.c (create_addrmap_from_aranges): Use
100 sect_offset_str.
101 (error_check_comp_unit_head): Likewise.
102 (create_debug_type_hash_table): Likewise.
103 (read_cutu_die_from_dwo): Likewise.
104 (init_cutu_and_read_dies): Likewise.
105 (init_cutu_and_read_dies_no_follow): Likewise.
106 (process_psymtab_comp_unit_reader): Likewise.
107 (partial_die_parent_scope): Likewise.
108 (peek_die_abbrev): Likewise.
109 (process_queue): Likewise.
110 (dwarf2_physname): Likewise.
111 (read_namespace_alias): Likewise.
112 (read_import_statement): Likewise.
113 (create_dwo_cu_reader): Likewise.
114 (create_cus_hash_table): Likewise.
115 (lookup_dwo_cutu): Likewise.
116 (inherit_abstract_dies): Likewise.
117 (read_func_scope): Likewise.
118 (read_call_site_scope): Likewise.
119 (dwarf2_add_member_fn): Likewise.
120 (read_common_block): Likewise.
121 (read_module_type): Likewise.
122 (read_typedef): Likewise.
123 (read_subrange_type): Likewise.
124 (load_partial_dies): Likewise.
125 (read_partial_die): Likewise.
126 (find_partial_die): Likewise.
127 (read_str_index): Likewise.
128 (dwarf2_string_attr): Likewise.
129 (build_error_marker_type): Likewise.
130 (lookup_die_type): Likewise.
131 (dump_die_shallow): Likewise.
132 (follow_die_ref): Likewise.
133 (dwarf2_fetch_die_loc_sect_off): Likewise.
134 (dwarf2_fetch_constant_bytes): Likewise.
135 (follow_die_sig): Likewise.
136 (get_signatured_type): Likewise.
137 (get_DW_AT_signature_type): Likewise.
138 (dwarf2_find_containing_comp_unit): Likewise.
139 (set_die_type): Likewise.
140
141 2018-02-21 John Baldwin <jhb@FreeBSD.org>
142
143 * arch/aarch64.c: Include "common-defs.h".
144 * arch/amd64.c: Likewise.
145 * arch/i386.c: Likewise.
146
147 2018-02-21 Tom Tromey <tom@tromey.com>
148
149 * value.h: (extract_field_op): Update.
150 * eval.c (extract_field_op): Return a const char *.
151 * expression.h (parse_expression_for_completion): Update.
152 * completer.c (complete_expression): Update.
153 (add_struct_fields): Make fieldname const.
154 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
155 (mark_completion_tag, parse_exp_in_context_1): Update.
156 (parse_expression_for_completion): Change "name" to
157 unique_xmalloc_ptr*.
158
159 2018-02-21 Tom Tromey <tom@tromey.com>
160
161 * infcall.c (call_function_by_hand_dummy): Use std::vector.
162
163 2018-02-21 Yao Qi <yao.qi@linaro.org>
164
165 * avr-tdep.c (avr_read_pc): Change parameter type to
166 readable_regcache.
167 * gdbarch.sh (read_pc): Likewise.
168 * gdbarch.c: Re-generated.
169 * gdbarch.h: Re-generated.
170 * hppa-tdep.c (hppa_read_pc): Change parameter type to
171 readable_regcache.
172 * ia64-tdep.c (ia64_read_pc): Likewise.
173 * mips-tdep.c (mips_read_pc): Likewise.
174 * spu-tdep.c (spu_read_pc): Likewise.
175
176 2018-02-21 Yao Qi <yao.qi@linaro.org>
177
178 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
179 * regcache-dump.c: New file.
180 * regcache.c: Move register_dump to regcache-dump.c.
181 (maintenance_print_registers): Likewise.
182 (maintenance_print_raw_registers): Likewise.
183 (maintenance_print_cooked_registers): Likewise.
184 (maintenance_print_register_groups): Likewise.
185 (maintenance_print_remote_registers): Likewise.
186 (_initialize_regcache): Likewise.
187 * regcache.h (register_dump): Moved from regcache.c.
188
189 2018-02-21 Yao Qi <yao.qi@linaro.org>
190
191 * regcache.c (regcache::regcache): Update.
192 (regcache::invalidate): Move it to detached_regcache::invalidate.
193 (get_thread_arch_aspace_regcache): Update.
194 (regcache::raw_update): Update.
195 (regcache::cooked_read): Remove some code.
196 (regcache::cooked_read_value): Likewise.
197 (regcache::raw_write): Remove assert on m_readonly_p.
198 (regcache::raw_supply_integer): Move it to
199 detached_regcache::raw_supply_integer.
200 (regcache::raw_supply_zeroed): Likewise.
201 * regcache.h (detached_regcache) <raw_supply_integer>: New
202 declaration.
203 <raw_supply_zeroed, invalidate>: Likewise.
204 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
205 <invalidate>: Likewise.
206 <m_readonly_p>: Removed.
207
208 2018-02-21 Yao Qi <yao.qi@linaro.org>
209
210 * infcmd.c (get_return_value): Let stop_regs point to
211 get_current_regcache.
212 * regcache.c (regcache::regcache): Remove.
213 (register_dump_reg_buffer): New class.
214 (regcache_print): Adjust.
215 * regcache.h (regcache): Remove constructors.
216
217 2018-02-21 Yao Qi <yao.qi@linaro.org>
218
219 * regcache.c (class register_dump): New class.
220 (register_dump_regcache, register_dump_none): New class.
221 (register_dump_remote, register_dump_groups): New class.
222 (regcache_print): Update.
223 * regcache.h (regcache_dump_what): Move it to regcache.c.
224 (regcache) <dump>: Remove.
225
226 2018-02-21 Yao Qi <yao.qi@linaro.org>
227
228 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
229 reg_buffer_rw *.
230 (jit_unwind_reg_set_impl): Call raw_supply.
231 (jit_frame_sniffer): Use reg_buffer_rw.
232 * record-full.c (record_full_core_regbuf): Change its type.
233 (record_full_core_open_1): Use reg_buffer_rw.
234 (record_full_close): Likewise.
235 (record_full_core_fetch_registers): Use regcache->raw_supply.
236 (record_full_core_store_registers): Likewise.
237 * regcache.c (regcache::get_register_status): Move it to
238 reg_buffer.
239 (regcache_raw_set_cached_value): Remove.
240 (regcache::raw_set_cached_value): Remove.
241 (regcache::raw_write): Call raw_supply.
242 (regcache::raw_supply): Move it to reg_buffer_rw.
243 * regcache.h (regcache_raw_set_cached_value): Remove.
244 (reg_buffer_rw): New class.
245
246 2018-02-21 Yao Qi <yao.qi@linaro.org>
247
248 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
249 readonly_detached_regcache.
250 (dummy_frame_prev_register): Use regcache->cooked_read.
251 * frame.c (frame_save_as_regcache): Change return type.
252 (frame_pop): Update.
253 * frame.h (frame_save_as_regcache): Update declaration.
254 * inferior.h (get_infcall_suspend_state_regcache): Update
255 declaration.
256 * infrun.c (infcall_suspend_state) <registers>: use
257 readonly_detached_regcache.
258 (save_infcall_suspend_state): Don't use regcache_dup.
259 (get_infcall_suspend_state_regcache): Change return type.
260 * linux-fork.c (struct fork_info) <savedregs>: Change to
261 readonly_detached_regcache.
262 <pc>: New field.
263 (fork_save_infrun_state): Don't use regcache_dup.
264 (info_checkpoints_command): Adjust.
265 * mi/mi-main.c (register_changed_p): Update declaration.
266 (mi_cmd_data_list_changed_registers): Use
267 readonly_detached_regcache.
268 (register_changed_p): Change parameter type to
269 readonly_detached_regcache.
270 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
271 readonly_detached_regcache.
272 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
273 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
274 New.
275 (regcache::save): Move it to reg_buffer.
276 (regcache::restore): Change parameter type.
277 (regcache_dup): Remove.
278 * regcache.h (reg_buffer) <save>: New method.
279 (readonly_detached_regcache): New class.
280 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
281 readonly_detached_regcache.
282 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
283
284 2018-02-21 Yao Qi <yao.qi@linaro.org>
285
286 * frame.c (frame_save_as_regcache): Use regcache method save.
287 (frame_pop): Use regcache method restore.
288 * infrun.c (restore_infcall_suspend_state): Likewise.
289 * linux-fork.c (fork_load_infrun_state): Likewise.
290 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
291 save.
292 * regcache.c (regcache_save): Remove.
293 (regcache::restore): More asserts.
294 (regcache_cpy): Remove.
295 * regcache.h (regcache_save): Remove the declaration.
296 (regcache::restore): Move from private to public.
297 Remove the friend declaration of regcache_cpy.
298 (regcache_cpy): Remove declaration.
299
300 2018-02-21 Yao Qi <yao.qi@linaro.org>
301
302 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
303 parameter type to 'readable_regcache *'.
304 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
305 * arm-tdep.c (arm_neon_quad_read): Likewise.
306 (arm_pseudo_read): Likewise.
307 * avr-tdep.c (avr_pseudo_register_read): Likewise.
308 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
309 * frv-tdep.c (frv_pseudo_register_read): Likewise.
310 * gdbarch.c: Re-generated.
311 * gdbarch.h: Re-generated.
312 * gdbarch.sh (pseudo_register_read): Change parameter type to
313 'readable_regcache *'.
314 (pseudo_register_read_value): Likewise.
315 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
316 (h8300_pseudo_register_read): Likewise.
317 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
318 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
319 (i386_pseudo_register_read_into_value): Likewise.
320 (i386_pseudo_register_read_value): Likewise.
321 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
322 declaration.
323 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
324 * m32c-tdep.c (m32c_raw_read): Likewise.
325 (m32c_read_flg): Likewise.
326 (m32c_banked_register): Likewise.
327 (m32c_banked_read): Likewise.
328 (m32c_sb_read): Likewise.
329 (m32c_part_read): Likewise.
330 (m32c_cat_read): Likewise.
331 (m32c_r3r2r1r0_read): Likewise.
332 (m32c_pseudo_register_read): Likewise.
333 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
334 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
335 (mep_pseudo_cr64_read): Likewise.
336 (mep_pseudo_register_read): Likewise.
337 * mips-tdep.c (mips_pseudo_register_read): Likewise.
338 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
339 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
340 * regcache.c (regcache::raw_read): Move it to readable_regcache.
341 (regcache::cooked_read): Likewise.
342 (regcache::cooked_read_value): Likewise.
343 (regcache_cooked_read_signed):
344 (regcache::cooked_read): Likewise.
345 * regcache.h (readable_regcache): New class.
346 (regcache): Inherit readable_regcache. Move some methods to
347 readable_regcache.
348 * rl78-tdep.c (rl78_pseudo_register_read): Change
349 parameter type to 'readable_regcache *'.
350 * rs6000-tdep.c (do_regcache_raw_read): Remove.
351 (e500_pseudo_register_read): Change parameter type to
352 'readable_regcache *'.
353 (dfp_pseudo_register_read): Likewise.
354 (vsx_pseudo_register_read): Likewise.
355 (efpr_pseudo_register_read): Likewise.
356 * s390-tdep.c (s390_pseudo_register_read): Likewise.
357 * sh-tdep.c (sh_pseudo_register_read): Likewise.
358 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
359 (sh64_pseudo_register_read): Likewise.
360 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
361 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
362 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
363 (spu_pseudo_register_read): Likewise.
364 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
365 (xtensa_pseudo_register_read): Likewise.
366
367 2018-02-21 Yao Qi <yao.qi@linaro.org>
368
369 * regcache.c (regcache::regcache): Call reg_buffer ctor.
370 (regcache::arch): Move it to reg_buffer::arch.
371 (regcache::register_buffer): Likewise.
372 (regcache::assert_regnum): Likewise.
373 (regcache::num_raw_registers): Likewise.
374 * regcache.h (reg_buffer): New class.
375 (regcache): Inherit reg_buffer.
376
377 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
378
379 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
380 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
381
382 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
383
384 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
385
386 2018-02-19 Alan Hayward <alan.hayward@arm.com>
387
388 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
389 (SFILES): Remove common/*.c files.
390 (COMMON_OBS): Remove some *.o files built from common/*.c files.
391 * common/common.host: Add common reference.
392 * configure.ac: Likewise.
393 * configure: Regenerate.
394
395 2018-02-16 Yao Qi <yao.qi@linaro.org>
396
397 * block.c (block_namespace_info): Inherit allocate_on_obstack.
398 (block_initialize_namespace): Use new.
399 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
400 (dwarf2_free_objfile): Use delete.
401 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
402 (copy_type_recursive): Use new.
403 * gdb_obstack.h (allocate_on_obstack): New.
404
405 2018-02-15 Yao Qi <yao.qi@linaro.org>
406
407 PR gdb/22849
408 * inferior.c (exit_inferior_1): Reset inf->control.
409
410 2018-02-15 Joel Brobecker <brobecker@adacore.com>
411
412 * ada-lang.c (ada_to_fixed_value_create): Delete advance
413 declaration.
414
415 2018-02-14 Pedro Alves <palves@redhat.com>
416
417 * frame-unwind.c (frame_unwind_try_unwinder): Always call
418 frame_cleanup_after_sniffer on exception.
419
420 2018-02-14 Tom Tromey <tom@tromey.com>
421
422 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
423 const.
424 (solib_bfd_open): Make pathname const.
425 * solib.c (solib_bfd_open): Make pathname const.
426 * solib-spu.c (spu_bfd_fopen): Make name const.
427 (spu_bfd_open): Make pathname const.
428 * solib-darwin.c (darwin_bfd_open): Make pathname const.
429 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
430
431 2018-02-14 Tom Tromey <tom@tromey.com>
432
433 * symfile.c (symfile_bfd_open): Update.
434 * source.h (openp, source_full_path_of, find_and_open_source):
435 Change argument type to unique_xmalloc_ptr.
436 * source.c (openp): Take a unique_xmalloc_ptr.
437 (source_full_path_of, find_and_open_source): Likewise.
438 (open_source_file, symtab_to_fullname): Update.
439 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
440 unique_xmalloc_ptr.
441 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
442 (exec_file_find): Update.
443 * psymtab.c (psymtab_to_fullname): Update.
444 * nto-tdep.h (nto_find_and_open_solib): Update.
445 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
446 unique_xmalloc_ptr.
447 * exec.c (exec_file_attach): Update.
448 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
449 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
450
451 2018-02-14 Tom Tromey <tom@tromey.com>
452
453 * solib.c: Include source.h.
454 * nto-tdep.c: Include source.h.
455 * mi/mi-cmd-env.c: Include source.h.
456 * infcmd.c: Include source.h.
457 * exec.c: Include source.h.
458 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
459 (add_path, directory_switch, source_path, init_source_path): Move
460 declarations...
461 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
462 (add_path, directory_switch, source_path, init_source_path):
463 ...here.
464
465 2018-02-14 Tom Tromey <tom@tromey.com>
466
467 * solist.h (exec_file_find, solib_find): Return
468 unique_xmalloc_ptr.
469 (solib_bfd_fopen): Take a const char *.
470 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
471 (exec_file_find, solib_find): Likewise.
472 (solib_bfd_fopen): Do not take ownership of "pathname".
473 (solib_bfd_open): Use unique_xmalloc_ptr.
474 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
475 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
476 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
477 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
478
479 2018-02-14 Joel Brobecker <brobecker@adacore.com>
480
481 * ada-lang.c (name_match_type_from_name): Remove reference to
482 ada_name_for_lookup in function's documentation.
483 * ada-lang.h (ada_name_for_lookup): Delete declaration.
484
485 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
486
487 * defs.h (enum openp_flags): New enum.
488 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
489 Move to enum openp_flags.
490 (openp_flags): New enum flags.
491 (openp): Change parameter type to openp_flags.
492 * source.c (openp): Change parameter type to openp_flags.
493 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
494 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
495
496 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
497
498 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
499 per-command.
500
501 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
502
503 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
504 into...
505 (class dwarf2_queue_guard): ...the destructor of this new class.
506 (dw2_do_instantiate_symtab): Create instance of the new class
507 dwarf2_queue_guard, remove cleanup.
508
509 2018-02-09 Tom Tromey <tom@tromey.com>
510
511 * source.c (find_source_lines): Don't reference past the end of
512 the vector.
513
514 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
515
516 * remote.c (remote_btrace_maybe_reopen): Change error message.
517 * btrace.c (btrace_enable): Likewise.
518 (parse_xml_btrace): Likewise.
519 (parse_xml_btrace_conf): Likewise.
520
521 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
522
523 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
524 (linux_enable_pt, linux_enable_bts): Call
525 diagnose_perf_event_open_fail.
526
527 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
528
529 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
530 Remove parameter and change return type. Update callers. Move it.
531 (linux_enable_bts, linux_enable_pt): Improve error message.
532 (linux_enable_pt): Remove zero buffer size check.
533 (linux_enable_btrace): Improve error messages. Remove NULL return
534 check.
535
536 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
537
538 * btrace.c (btrace_enable): Remove target_supports_btrace call.
539 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
540 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
541 (linux_supports_pt, linux_supports_btrace): Remove.
542 (linux_enable_bts): Call cpu_supports_bts.
543 * nat/linux-btrace.h (linux_supports_btrace): Remove.
544 * remote.c (remote_supports_btrace): Remove.
545 (init_remote_ops): Remove remote_supports_btrace.
546 * target-delegates.c: Regenerated.
547 * target.c (target_supports_btrace): Remove.
548 * target.h (target_ops) <to_supports_btrace>: Remove
549 (target_supports_btrace): Remove.
550 * x86-linux-nat.c (x86_linux_create_target): Remove
551 linux_supports_btrace.
552
553 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
554
555 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
556 btrace failed.
557 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
558 exception and use message in own exception.
559
560 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
561
562 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
563 (perf_event_pt_event_type): Use gdb_file_up.
564 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
565 scoped_fd, and scoped_mmap.
566
567 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
568
569 * common/scoped_mmap.h: New.
570 * unittests/scoped_mmap-selftest.c: New.
571 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
572 unittests/scoped_mmap-selftest.c.
573
574 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
575
576 * common/scoped_fd.h: New.
577 * unittests/scoped_fd-selftest.c: New.
578 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
579 unittests/scoped_fd-selftest.c.
580
581 2018-02-09 Tom Tromey <tom@tromey.com>
582
583 * auto-load.c (auto_load_section_scripts): Use
584 gdb::unique_xmalloc_ptr.
585
586 2018-02-09 Tom Tromey <tom@tromey.com>
587
588 * auto-load.c (execute_script_contents): Use std::string.
589
590 2018-02-09 Joel Brobecker <brobecker@adacore.com>
591
592 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
593 Python function, rather than a new command.
594
595 2018-02-08 Tom Tromey <tom@tromey.com>
596
597 * solib.c (solib_find_1): Use std::string.
598 (solib_bfd_fopen): Use unique_xmalloc_ptr.
599
600 2018-02-08 Tom Tromey <tom@tromey.com>
601
602 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
603
604 2018-02-08 Tom Tromey <tom@tromey.com>
605
606 * source.c (find_source_lines): Use gdb::def_vector.
607
608 2018-02-08 Tom Tromey <tom@tromey.com>
609
610 * macrocmd.c (struct temporary_macro_definition): New.
611 (macro_define_command): Use temporary_macro_definition. Remove
612 cleanups.
613 (free_macro_definition_ptr): Remove.
614
615 2018-02-08 Tom Tromey <tom@tromey.com>
616
617 * macroexp.c (maybe_expand): Use std::string.
618
619 2018-02-08 Tom Tromey <tom@tromey.com>
620
621 * macroexp.c (struct macro_buffer): Add initializers for some
622 members.
623 (init_buffer, init_shared_buffer, free_buffer)
624 (free_buffer_return_text): Remove.
625 (macro_buffer): New constructors.
626 (~macro_buffer): New destructor.
627 (macro_buffer::set_shared): New method.
628 (macro_buffer::resize_buffer, macro_buffer::appendc)
629 (macro_buffer::appendmem): Now methods, not free functions.
630 (set_token, append_tokens_without_splicing, stringify)
631 (macro_stringify): Update.
632 (gather_arguments): Change return type. Remove argc_p argument,
633 add args_ptr argument. Use std::vector.
634 (substitute_args): Remove argc argument. Accept std::vector.
635 (expand): Update. Use std::vector.
636 (scan, macro_expand, macro_expand_next): Update.
637
638 2018-02-08 Tom Tromey <tom@tromey.com>
639
640 * symtab.c (default_collect_symbol_completion_matches_break_on):
641 Use unique_xmalloc_ptr.
642 * macroscope.h: (sal_macro_scope, user_macro_scope)
643 (default_macro_scope): Return unique_xmalloc_ptr.
644 * macroscope.c (sal_macro_scope, user_macro_scope)
645 (default_macro_scope): Return unique_xmalloc_ptr.
646 * macroexp.h (macro_expand, macro_expand_once): Return
647 unique_xmalloc_ptr.
648 * macroexp.c (macro_expand, macro_expand_once): Return
649 unique_xmalloc_ptr.
650 * macrocmd.c (macro_expand_command, macro_expand_once_command)
651 (info_macro_command, info_macros_command): Use
652 unique_xmalloc_ptr.
653 * compile/compile-c-support.c (write_macro_definitions): Use
654 unique_xmalloc_ptr.
655 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
656
657 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
658
659 * value.c (value_static_field): Assign field type instead of
660 containing type when returning an optimized out value.
661
662 2018-02-06 Yao Qi <yao.qi@linaro.org>
663
664 * ft32-tdep.c (ft32_read_pc): Remove.
665 (ft32_write_pc): Remove.
666 (ft32_gdbarch_init): Update.
667 * m32r-tdep.c (m32r_read_pc): Remove.
668 (m32r_gdbarch_init): Update.
669 * mep-tdep.c (mep_read_pc): Remove.
670 (mep_gdbarch_init): Update.
671 * microblaze-tdep.c (microblaze_write_pc): Remove.
672 (microblaze_gdbarch_init): Update.
673 * mn10300-tdep.c (mn10300_read_pc): Remove.
674 (mn10300_write_pc): Remove.
675 (mn10300_gdbarch_init): Update.
676 * moxie-tdep.c (moxie_read_pc): Remove.
677 (moxie_write_pc): Remove.
678 (moxie_gdbarch_init): Update.
679
680 2018-02-06 Yao Qi <yao.qi@linaro.org>
681
682 * expprint.c (print_subexp_standard): Handle
683 OP_F77_UNDETERMINED_ARGLIST.
684 (dump_subexp_body_standard): Likewise.
685
686 2018-02-05 Alan Hayward <alan.hayward@arm.com>
687
688 * target-descriptions.c (tdesc_element_visitor) Add empty
689 implementations.
690 (tdesc_type): Move make_gdb_type from here.
691 (tdesc_type_builtin): Likewise.
692 (tdesc_type_vector): Likewise.
693 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
694 (make_gdb_type_struct): Move from tdesc_type_with_fields.
695 (make_gdb_type_union): Likewise.
696 (make_gdb_type_flags): Likewise.
697 (make_gdb_type_enum): Likewise.
698 (make_gdb_type): New function.
699 (tdesc_register_type): Use static make_gdb_type.
700
701 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
702
703 * infcmd.c (default_print_one_register_info): Align natural-format
704 column values consistently one under another.
705 (pad_to_column): New function.
706
707 2018-02-05 Joel Brobecker <brobecker@adacore.com>
708
709 * dwarf2read.c (dwarf2_physname): Move commment.
710
711 2018-02-01 Leszek Swirski <leszeks@google.com>
712
713 * varobj.c (varobj_formatted_print_options): Allow recursive
714 pretty printing if pretty printing is enabled.
715
716 2018-02-01 Leszek Swirski <leszeks@google.com>
717
718 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
719 names after a structop as a filename.
720
721 2018-02-01 Yao Qi <yao.qi@linaro.org>
722
723 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
724 (arm_record_coproc_data_proc): Likewise.
725
726 2018-02-01 Yao Qi <yao.qi@linaro.org>
727
728 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
729
730 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
731
732 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
733 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
734
735 2018-01-31 Pedro Alves <palves@redhat.com>
736
737 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
738 * inflow.c (child_terminal_save_inferior): Wrap reference to
739 tcgetpgrp in HAVE_TERMIOS_H.
740 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
741 _WIN32.
742 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
743 always iterate over all inferiors.
744 (gdbsim_cntrl_c): Adjust.
745 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
746
747 2018-01-31 Joel Brobecker <brobecker@adacore.com>
748
749 * gdbtypes.c (lookup_array_range_type): Make sure the array's
750 index type is objfile-owned if the element type is as well.
751
752 2018-01-31 Joel Brobecker <brobecker@adacore.com>
753
754 GDB 8.1 released.
755
756 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
757
758 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
759 "features/s390x-linux64.c".
760 (_initialize_s390_linux_tdep): Remove initialization of tdescs
761 s390_linux32 and s390x_linux64.
762 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
763 default tdesc.
764 * s390-tdep.c: Include "features/s390-linux32.c" and
765 "features/s390x-linux64.c".
766 (s390_tdesc_valid): Add check for tdesc_has_registers.
767 (s390_gdbarch_init): Make sure there is always a valid tdesc.
768 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
769 tdesc_s390x_linux64.
770 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
771 tdesc_s390x_linux64 to...
772 * s390-tdep.h: ...here.
773
774 2018-01-30 Pedro Alves <palves@redhat.com>
775
776 PR gdb/13211
777 * config.in, configure: Regenerate.
778 * configure.ac: Check for getpgid.
779 * go32-nat.c (go32_pass_ctrlc): New.
780 (go32_target): Install it.
781 * inf-child.c (inf_child_target): Install
782 child_terminal_save_inferior, child_pass_ctrlc and
783 child_interrupt.
784 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
785 (inf_ptrace_target): No longer install it.
786 * infcmd.c (interrupt_target_1): Adjust.
787 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
788 (child_interrupt): Declare.
789 (inferior::terminal_state): New.
790 * inflow.c (struct terminal_info): Update comments.
791 (inferior_process_group): Delete.
792 (terminal_is_ours): Delete.
793 (gdb_tty_state): New.
794 (child_terminal_init): Adjust.
795 (is_gdb_terminal, sharing_input_terminal_1)
796 (sharing_input_terminal): New functions.
797 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
798 Set the process's actual process group in the foreground if
799 possible. Handle is_ours_for_output/is_ours distinction. Don't
800 mark terminal as the inferior's if not sharing GDB's terminal.
801 Don't check attach_flag.
802 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
803 pass down a target_terminal_state.
804 (child_terminal_save_inferior): New, factored out from ...
805 (child_terminal_ours_1): ... this. Handle
806 target_terminal_state::is_ours_for_output.
807 (child_interrupt, child_pass_ctrlc): New.
808 (inflow_inferior_exit): Clear the inferior's terminal_state.
809 (copy_terminal_info): Copy the inferior's terminal state.
810 (_initialize_inflow): Remove reference to terminal_is_ours.
811 * inflow.h (inferior_process_group): Delete.
812 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
813 * procfs.c (procfs_target): Don't install procfs_interrupt.
814 (procfs_interrupt): Delete.
815 * remote.c (remote_serial_quit_handler): Adjust.
816 (remote_interrupt): Remove ptid parameter. Adjust.
817 * target-delegates.c: Regenerate.
818 * target.c: Include "terminal.h".
819 (target_terminal::terminal_state): Rename to ...
820 (target_terminal::m_terminal_state): ... this.
821 (target_terminal::init): Adjust.
822 (target_terminal::inferior): Adjust to per-inferior
823 terminal_state.
824 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
825 (target_terminal::ours, target_terminal::ours_for_output): Use
826 target_terminal_is_ours_kind.
827 (target_interrupt): Remove ptid parameter. Adjust.
828 (default_target_pass_ctrlc): Adjust.
829 * target.h (target_ops::to_terminal_save_inferior): New field.
830 (target_ops::to_interrupt): Remove ptid_t parameter.
831 (target_interrupt): Remove ptid_t parameter. Update comment.
832 (target_pass_ctrlc): Update comment.
833 * target/target.h (target_terminal_state): New scoped enum,
834 factored out of ...
835 (target_terminal::terminal_state): ... here.
836 (target_terminal::inferior): Update comments.
837 (target_terminal::restore_inferior): New.
838 (target_terminal::is_inferior, target_terminal::is_ours)
839 (target_terminal::is_ours_for_output): Adjust.
840 (target_terminal::scoped_restore_terminal_state): Adjust to
841 rename, and call restore_inferior() instead of inferior().
842 (target_terminal::scoped_restore_terminal_state::m_state): Change
843 type.
844 (target_terminal::terminal_state): Rename to ...
845 (target_terminal::m_terminal_state): ... this and change type.
846
847 2018-01-30 Pedro Alves <palves@redhat.com>
848
849 * linux-nat.c (wait_for_signal): New function.
850 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
851 directly.
852 (async_terminal_is_ours)
853 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
854 (linux_nat_add_target): Don't override
855 to_terminal_inferior/to_terminal_ours.
856
857 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
858
859 * remote.c (remote_follow_fork): Don't call "detach_inferior".
860
861 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
862
863 * dwarf2read.c (free_dwo_files): Add forward-declaration.
864 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
865 dwarf2_per_objfile_free here.
866 (dwarf2_per_objfile_free): Remove.
867 (_initialize_dwarf2_read): Don't register
868 dwarf2_per_objfile_free as a registry cleanup.
869
870 2018-01-27 Eli Zaretskii <eliz@gnu.org>
871
872 Avoid compilation errors in MinGW native builds
873
874 The error is triggered by including python-internal.h, and the
875 error message is:
876
877 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
878 from build-gnulib/import/math.h:27,
879 from d:/usr/Python26/include/pyport.h:235,
880 from d:/usr/Python26/include/Python.h:58,
881 from python/python-internal.h:94,
882 from python/py-arch.c:24:
883 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
884 using ::hypot;
885 ^~~~~
886
887 This happens because Python headers define 'hypot' to expand t
888 '_hypot' in the Windows builds.
889 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
890 'hypoth'. This avoids a compilation error.
891
892 2018-01-26 Alan Hayward <alan.hayward@arm.com>
893
894 * MAINTAINERS (Write After Approval): Fix ordering.
895
896 2018-01-26 Alan Hayward <alan.hayward@arm.com>
897
898 * MAINTAINERS (Write After Approval): Add Alan Hayward.
899
900 2018-01-26 Alan Modra <amodra@gmail.com>
901
902 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
903 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
904 Remove nop. Make const. Comment.
905 (powerpc32_plt_stub_so_2): New.
906 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
907 Correct count. Update uses.
908 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
909 Move common code reading PLT entry word. Correct
910 powerpc32_plt_stub PLT address calculation.
911 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
912 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
913 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
914 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
915 (ppc64_standard_linkage8): Likewise.
916 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
917 Correct insns description.
918 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
919
920 2018-01-24 Pedro Alves <palves@redhat.com>
921
922 GCC PR libstdc++/83906
923 * gdbtypes.c (operator==(const dynamic_prop &,
924 const dynamic_prop &)): New.
925 (operator==(const range_bounds &, const range_bounds &)): New.
926 (check_types_equal): Use them instead of memcmp.
927 * gdbtypes.h (operator==(const dynamic_prop &,
928 const dynamic_prop &)): Declare.
929 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
930 (operator==(const range_bounds &, const range_bounds &)): Declare.
931 (operator!=(const range_bounds &, const range_bounds &)): Declare.
932
933 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
934
935 * s390-linux-tdep.c (s390_record_address_mask)
936 (s390_record_calc_disp_common, s390_record_calc_disp)
937 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
938 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
939 (s390_process_record): Move to s390-tdep.c.
940 (s390_linux_init_abi_any): Adjust.
941 * s390-tdep.c (s390_record_address_mask)
942 (s390_record_calc_disp_common, s390_record_calc_disp)
943 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
944 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
945 (s390_process_record): Moved from s390-linux-tdep.c
946 (s390_gdbarch_init): Adjust.
947
948 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
949
950 * s390-linux-nat.c (s390-tdep.h): New include.
951 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
952 (HFILES_NO_SRCDIR): Add s390-tdep.h.
953 (ALLDEPFILES): Add s390-tdep.c.
954 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
955 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
956 * s390-tdep.h: ...this. New file.
957 * s390-linux-tdep.c (s390-tdep.h): New include.
958 (_initialize_s390_tdep): Rename to...
959 (_initialize_s390_linux_tdep): ...this and adjust.
960 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
961 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
962 s390-tdep.h.
963 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
964 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
965 (s390_is_partial_instruction, s390_software_single_step)
966 (is_non_branch_ril, s390_displaced_step_copy_insn)
967 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
968 (s390_prologue_data, s390_addr, s390_store, s390_load)
969 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
970 (s390_register_call_saved, s390_guess_tracepoint_registers)
971 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
972 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
973 (s390_pseudo_register_name, s390_pseudo_register_type)
974 (s390_pseudo_register_read, s390_pseudo_register_write)
975 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
976 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
977 (s390_addr_bits_remove, s390_address_class_type_flags)
978 (s390_address_class_type_flags_to_name)
979 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
980 (s390_function_arg_float, s390_function_arg_vector)
981 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
982 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
983 (s390_frame_align, s390_register_return_value, s390_return_value)
984 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
985 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
986 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
987 (s390_trad_frame_prev_register, s390_unwind_cache)
988 (s390_prologue_frame_unwind_cache)
989 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
990 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
991 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
992 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
993 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
994 (s390_frame_base_address, s390_local_base_address)
995 (s390_frame_base, s390_gcc_target_options)
996 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
997 (s390_validate_reg_range, s390_tdesc_valid)
998 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
999 * s390-tdep.c: ...this. New file.
1000
1001 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1002
1003 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
1004 (s390_process_record, s390_gdbarch_tdep_alloc)
1005 (s390_linux_init_abi_any): Use/set new hook.
1006
1007 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1008
1009 * s390-linux-tdep.c (osabi.h): New include.
1010 (s390_linux_init_abi_31, s390_linux_init_abi_64)
1011 (s390_linux_init_abi_any): New functions.
1012 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
1013
1014 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1015
1016 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
1017 tdesc_has_registers check
1018
1019 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1020
1021 * s390-linux-tdep.c (s390_tdesc_valid): New function.
1022 (s390_validate_reg_range): New macro.
1023 (s390_gdbarch_init): Adjust.
1024
1025 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1026
1027 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
1028 (s390_gdbarch_tdep_alloc): Adjust.
1029 (s390_gdbarch_init): Adjust.
1030
1031 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1032
1033 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
1034 <have_tdb>: Change type to bool.
1035 (s390_gdbarch_tdep_alloc): Adjust.
1036 (s390_gdbarch_init): Adjust.
1037
1038 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1039
1040 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
1041 (gdbarch_tdep) <have_upper, have_vx>: New fields.
1042 (s390_gdbarch_tdep_alloc): New function.
1043 (s390_gdbarch_init): Allocate tdep at start and use its fields
1044 instead of separate variables.
1045
1046 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
1047
1048 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
1049 when looking for cached gdbarch and add comment for remaining.
1050
1051 2018-01-22 Pedro Alves <palves@redhat.com>
1052 Sergio Durigan Junior <sergiodj@redhat.com>
1053
1054 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
1055 case.
1056
1057 2018-01-22 Maciej W. Rozycki <macro@mips.com>
1058
1059 * MAINTAINERS: Update my company e-mail address.
1060
1061 2018-01-22 Yao Qi <yao.qi@linaro.org>
1062
1063 * regcache.c (cooked_write_test): New function.
1064 (_initialize_regcache): Register the test.
1065
1066 2018-01-22 Yao Qi <yao.qi@linaro.org>
1067
1068 * ia64-tdep.c (ia64_pseudo_register_read): Call
1069 regcache->cooked_read instead of regcache_cooked_read_unsigned.
1070 * m32c-tdep.c (m32c_cat_read): Likewise.
1071 (m32c_r3r2r1r0_read): Likewise.
1072 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
1073 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
1074
1075 2018-01-22 Yao Qi <yao.qi@linaro.org>
1076
1077 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
1078 method raw_read instead of regcache_raw_read.
1079 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
1080 * arm-tdep.c (arm_neon_quad_read): Likewise.
1081 * avr-tdep.c (avr_pseudo_register_read): Likewise.
1082 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
1083 * frv-tdep.c (frv_pseudo_register_read): Likewise.
1084 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
1085 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1086 (i386_pseudo_register_read_into_value): Likewise.
1087 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
1088 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
1089 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
1090 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
1091 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
1092 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
1093 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
1094 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
1095 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
1096
1097 2018-01-22 Yao Qi <yao.qi@linaro.org>
1098
1099 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
1100 * configure.tgt: Remove target mt.
1101 * mt-tdep.c: Remove.
1102 * regcache.c (cooked_read_test): Remove the check for mt.
1103
1104 2018-01-22 Yao Qi <yao.qi@linaro.org>
1105
1106 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
1107 instead of gdbarch_pseudo_register_read_value.
1108
1109 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1110
1111 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
1112 language is Ada.
1113
1114 2018-01-22 Joel Brobecker <brobecker@adacore.com>
1115
1116 * linespec.c (create_sals_line_offset): Remove code that preserved
1117 the symtab_and_line's line number.
1118
1119 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1120
1121 * varobj.c (varobj_create): Don't set valid_block when creating a
1122 floating varobj.
1123
1124 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1125
1126 * varobj.c (varobj_create): Remove out of date comment.
1127
1128 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1129
1130 PR mi/20395
1131 * ada-exp.y (write_var_from_sym): Pass extra parameter when
1132 updating innermost block.
1133 * parse.c (innermost_block_tracker::update): Take extra type
1134 parameter, and check types match before updating innermost block.
1135 (write_dollar_variable): Update innermost block for registers.
1136 * parser-defs.h (enum innermost_block_tracker_type): New enum.
1137 (innermost_block_tracker::innermost_block_tracker): Initialise
1138 m_types member.
1139 (innermost_block_tracker::reset): Take type parameter.
1140 (innermost_block_tracker::update): Take type parameter, and pass
1141 type through as needed.
1142 (innermost_block_tracker::m_types): New member.
1143 * varobj.c (varobj_create): Pass type when reseting innermost
1144 block.
1145
1146 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1147
1148 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
1149 * ada-lang.c (resolve_subexp): Likewise.
1150 * breakpoint.c (set_breakpoint_condition) Likewise.
1151 (watch_command_1) Likewise.
1152 * c-exp.y (variable): Likewise.
1153 * d-exp.y (PrimaryExpression): Likewise.
1154 * f-exp.y (variable): Likewise.
1155 * go-exp.y (variable): Likewise.
1156 * m2-exp.y (variable): Likewise.
1157 * objfiles.c (objfile::~objfile): Likewise.
1158 * p-exp.y (variable): Likewise.
1159 * parse.c (innermost_block): Change type.
1160 * parser-defs.h (class innermost_block_tracker): New.
1161 (innermost_block): Change to innermost_block_tracker.
1162 * printcmd.c (display_command): Switch to innermost_block API.
1163 (do_one_display): Likewise.
1164 * rust-exp.y (do_one_display): Likewise.
1165 * symfile.c (clear_symtab_users): Likewise.
1166 * varobj.c (varobj_create): Switch to innermost_block API, replace
1167 use of innermost_block with block stored on varobj object.
1168
1169 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
1170
1171 * expression.h (innermost_block): Remove declaration.
1172 * varobj.c: Add 'parser-defs.h' include.
1173
1174 2018-01-19 Tom Tromey <tom@tromey.com>
1175
1176 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
1177 symbols in the static and global blocks.
1178
1179 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1180
1181 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
1182 gdb_ptrace.h, and move including gdb_wait.h ...
1183 * nat/linux-ptrace.h: ... to here.
1184
1185 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1186
1187 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
1188 inf_ptrace_detach_success.
1189 (inf_ptrace_detach_success): Add inferior parameter, use it
1190 instead of inferior_ptid, pass it to detach_inferior.
1191 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
1192 parameter.
1193 * inferior.c (detach_inferior): Add overload that takes an
1194 inferior object.
1195 * inferior.h (detach_inferior): Likewise.
1196 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
1197 use inferior_ptid, adjust call to inf_ptrace_detach_success.
1198 * linux-thread-db.c (thread_db_detach): Use inf parameter.
1199
1200 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1201
1202 * target.h (struct target_ops) <to_detach>: Add inferior
1203 parameter.
1204 (target_detach): Likewise.
1205 * target.c (dispose_inferior): Pass inferior down.
1206 (target_detach): Pass inferior down. Assert that it is equal to
1207 the current inferior.
1208 * aix-thread.c (aix_thread_detach): Pass inferior down.
1209 * corefile.c (core_file_command): Pass current_inferior() down.
1210 * corelow.c (core_detach): Add inferior parameter.
1211 * darwin-nat.c (darwin_detach): Likewise.
1212 * gnu-nat.c (gnu_detach): Likewise.
1213 * inf-ptrace.c (inf_ptrace_detach): Likewise.
1214 * infcmd.c (detach_command): Pass current_inferior() down to
1215 target_detach.
1216 * infrun.c (follow_fork_inferior): Pass parent_inf to
1217 target_detach.
1218 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
1219 target_detach.
1220 * linux-nat.c (linux_nat_detach): Add inferior parameter.
1221 * linux-thread-db.c (thread_db_detach): Likewise.
1222 * nto-procfs.c (procfs_detach): Likewise.
1223 * procfs.c (procfs_detach): Likewise.
1224 * record.c (record_detach): Likewise.
1225 * record.h (struct inferior): Forward-declare.
1226 (record_detach): Add inferior parameter.
1227 * remote-sim.c (gdbsim_detach): Likewise.
1228 * remote.c (remote_detach_1): Likewise.
1229 (remote_detach): Likewise.
1230 (extended_remote_detach): Likewise.
1231 * sol-thread.c (sol_thread_detach): Likewise.
1232 * target-debug.h (target_debug_print_inferior_p): New macro.
1233 * target-delegates.c: Re-generate.
1234 * top.c (kill_or_detach): Pass inferior down to target_detach.
1235 * windows-nat.c (windows_detach): Add inferior parameter.
1236
1237 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
1238
1239 * target.h (struct target_ops) <to_detach>: Remove args
1240 parameter.
1241 (target_detach): Likewise.
1242 * target.c (dispose_inferior): Adjust.
1243 (target_detach): Remove args parameter, adjust.
1244 * aix-thread.c (aix_thread_detach): Adjust.
1245 * corefile.c (core_file_command): Adjust.
1246 * corelow.c (core_detach): Adjust.
1247 * darwin-nat.c (darwin_detach): Adjust.
1248 * gnu-nat.c (gnu_detach): Adjust.
1249 * inf-ptrace.c (inf_ptrace_detach): Adjust.
1250 * infcmd.c (detach_command): Adjust
1251 * infrun.c (follow_fork_inferior): Adjust.
1252 (handle_vfork_child_exec_or_exit): Adjust.
1253 * linux-fork.c (linux_fork_detach): Remove args parameter.
1254 * linux-fork.h (linux_fork_detach): Likewise.
1255 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
1256 * linux-thread-db.c (thread_db_detach): Likewise.
1257 * nto-procfs.c (procfs_detach): Likewise.
1258 * procfs.c (procfs_detach): Likewise.
1259 (do_detach): Remove signo parameter.
1260 * record.c (record_detach): Remove args parameter.
1261 * record.h (record_detach): Likewise.
1262 * remote-sim.c (gdbsim_detach): Likewise.
1263 * remote.c (remote_detach_1): Likewise.
1264 (remote_detach): Likewise.
1265 (extended_remote_detach): Likewise.
1266 * sol-thread.c (sol_thread_detach): Likewise.
1267 * target-delegates.c: Re-generate.
1268 * top.c (struct qt_args) <args>: Remove field.
1269 (kill_or_detach): Don't pass args.
1270 (quit_force): Don't set args.
1271 * windows-nat.c (windows_detach): Remove args parameter.
1272
1273 2018-01-19 Yao Qi <yao.qi@linaro.org>
1274
1275 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
1276 (arm_linux_init_abi): Install it.
1277
1278 2018-01-19 Yao Qi <yao.qi@linaro.org>
1279
1280 * osabi.c (gdb_osabi_names): Extend the regexp for
1281 arm-linux-gnueabihf.
1282
1283 2018-01-18 Yao Qi <yao.qi@linaro.org>
1284
1285 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
1286 m_abbrevs.
1287 (abbrev_table::add_abbrev): Update.
1288 (abbrev_table::lookup_abbrev): Update.
1289
1290 2018-01-18 Yao Qi <yao.qi@linaro.org>
1291
1292 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
1293
1294 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
1295
1296 * compile/compile.c (compile_to_object): Convert "triplet_rx"
1297 to "std::string".
1298
1299 2018-01-17 Tom Tromey <tom@tromey.com>
1300
1301 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
1302
1303 2018-01-17 Tom Tromey <tom@tromey.com>
1304
1305 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
1306 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
1307 (create_array_type_with_stride): Update.
1308 * dwarf2read.c (set_die_type): Update.
1309
1310 2018-01-17 Tom Tromey <tom@tromey.com>
1311
1312 * dwarf2read.c (delayed_method_info): Remove typedef.
1313 (dwarf2_cu::method_info): Now a std::vector.
1314 (add_to_method_list): Update.
1315 (free_delayed_list): Remove.
1316 (compute_delayed_physnames): Update.
1317 (process_full_comp_unit, process_full_type_unit): Clear the method
1318 list. Remove cleanups.
1319 (psymtab_include_file_name): Add name_holder parameter. Use
1320 unique_xmalloc_ptr.
1321 (dwarf_decode_lines): Update.
1322
1323 2018-01-17 Tom Tromey <tom@tromey.com>
1324 Simon Marchi <simon.marchi@ericsson.com>
1325
1326 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
1327 (dwarf2_per_objfile::free_cached_comp_units)
1328 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1329 (init_cutu_and_read_dies_no_follow): Update.
1330 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
1331 (dwarf2_cu::~dwarf2_cu): New.
1332 (free_heap_comp_unit, free_stack_comp_unit): Remove.
1333 (age_cached_comp_units, free_one_cached_comp_unit): Update.
1334
1335 2018-01-17 Tom Tromey <tom@tromey.com>
1336 Simon Marchi <simon.marchi@ericsson.com>
1337
1338 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
1339 (struct die_reader_specs) <abbrev_table>: New member.
1340 (struct abbrev_table): Add constructor.
1341 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
1342 <abbrev_obstack>: Now an auto_obstack.
1343 (abbrev_table_up): New typedef.
1344 (init_cu_die_reader): Add abbrev_table parameter.
1345 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
1346 Add result_dwo_abbrev_table.
1347 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
1348 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
1349 Update.
1350 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
1351 parameter.
1352 (skip_children): Update.
1353 (abbrev_table::alloc_abbrev): Rename from
1354 abbrev_table_alloc_abbrev.
1355 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
1356 (abbrev_table::lookup_abbrev): Rename from
1357 abbrev_table_lookup_abbrev.
1358 (abbrev_table_read_table): Return abbrev_table_up.
1359 (abbrev_table_free, abbrev_table_free_cleanup)
1360 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
1361 (load_partial_dies): Update.
1362
1363 2018-01-17 Tom Tromey <tom@tromey.com>
1364
1365 * dwarf2read.c (dwarf2_compute_name): Update comment.
1366 (read_func_scope, read_variable): Update.
1367 (new_symbol): Remove.
1368 (new_symbol_full): Rename to new_symbol.
1369
1370 2018-01-17 Mike Gulick <mgulick@mathworks.com>
1371
1372 PR gdb/16577
1373 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
1374 a warning instead of throwing an error, set section size to 0 and return
1375 NULL.
1376 * gdb_bfd.h (gdb_bfd_map_section): Update description.
1377
1378 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1379
1380 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
1381 std::string.
1382 (linux_ptrace_attach_fail_reason_string): Likewise.
1383 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
1384 Likewise.
1385 (linux_ptrace_attach_fail_reason_string): Likewise.
1386 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
1387
1388 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1389
1390 * linux-nat.c (linux_nat_attach): Remove xstrdup.
1391
1392 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1393
1394 PR gdb/21559
1395 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1396 checking for fs_base/gs_base fields in struct user_regs_struct.
1397 * configure: Regenerate.
1398
1399 2018-01-17 Yao Qi <yao.qi@linaro.org>
1400
1401 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
1402 function.
1403 (aarch64_linux_init_abi): Install it to gdbarch hook
1404 gcc_target_options.
1405
1406 2018-01-15 Pedro Alves <palves@redhat.com>
1407
1408 * common/signals-state-save-restore.c
1409 (save_original_signals_state): Fix typos.
1410
1411 2017-01-12 Tom Tromey <tom@tromey.com>
1412 Sergio Durigan Junior <sergiodj@redhat.com>
1413
1414 * Makefile.in (install-only): Install gdb-add-index.
1415
1416 2018-01-12 John Baldwin <jhb@FreeBSD.org>
1417
1418 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
1419
1420 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
1421
1422 * infrun.c (keep_going_pass_signal): Clear step-over info when
1423 insert_breakpoints fails.
1424
1425 2018-01-11 Pedro Alves <palves@redhat.com>
1426
1427 PR gdb/22583
1428 * infrun.c (resume): Rename to ...
1429 (resume_1): ... this.
1430 (resume): Reimplement as wrapper around resume_1.
1431
1432 2018-01-11 Pedro Alves <palves@redhat.com>
1433
1434 PR remote/22597
1435 * remote.c (remote_parse_stop_reply): Default to the last-set
1436 general thread instead of to 'magic_null_ptid'.
1437
1438 2018-01-10 Pedro Alves <palves@redhat.com>
1439
1440 * language.h (language_get_symbol_name_matcher): Rename ...
1441 (get_symbol_name_matcher): ... this.
1442 * language.c (language_get_symbol_name_matcher): Ditto.
1443 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
1444 callers adjusted.
1445
1446 2018-01-10 Pedro Alves <palves@redhat.com>
1447
1448 PR gdb/22670
1449 * dwarf2read.c
1450 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
1451 Adjust to use language_get_symbol_name_matcher instead of
1452 language_defn::la_get_symbol_name_matcher.
1453 * language.c (language_get_symbol_name_matcher): If in Ada mode
1454 and the lookup name is a verbatim match, return Ada's matcher.
1455 * language.h (language_get_symbol_name_matcher): Adjust comment.
1456 (ada_lookup_name_info::verbatim_p):: New method.
1457
1458 2018-01-10 Pedro Alves <palves@redhat.com>
1459
1460 PR gdb/22670
1461 * ada-lang.c (ada_collect_symbol_completion_matches): If the
1462 minsym's language is language_auto or language_cplus, pass down
1463 language_ada instead.
1464 * symtab.c (compare_symbol_name): Don't frob symbol language here.
1465
1466 2018-01-10 Pedro Alves <palves@redhat.com>
1467
1468 PR gdb/22670
1469 * minsyms.c (linkage_name_str): New function.
1470 (iterate_over_minimal_symbols): Use it.
1471
1472 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1473
1474 * NEWS: Document that 'info proc' now works on FreeBSD.
1475
1476 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1477
1478 * configure.ac: Check for kinfo_getfile in libutil.
1479 * configure: Regenerate.
1480 * config.in: Regenerate.
1481 * fbsd-nat.c: Include "fbsd-tdep.h".
1482 (fbsd_fetch_cmdline): New.
1483 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
1484 rather than calling error.
1485 (fbsd_info_proc): New.
1486 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
1487 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
1488 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
1489
1490 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1491
1492 * fbsd-nat.c (struct free_deleter): Remove.
1493 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
1494
1495 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1496
1497 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
1498 NULL for an empty pathname.
1499
1500 2018-01-09 John Baldwin <jhb@FreeBSD.org>
1501
1502 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
1503 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
1504 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
1505 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
1506 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
1507 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
1508 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
1509 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
1510 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
1511 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
1512 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
1513 (fbsd_core_fetch_timeval, fbsd_print_sigset)
1514 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
1515 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
1516 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
1517
1518 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
1519
1520 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
1521 (gnu_xfer_auxv): New function.
1522 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
1523 TARGET_OBJECT_AUXV.
1524
1525 2018-01-08 Yao Qi <yao.qi@linaro.org>
1526 Simon Marchi <simon.marchi@ericsson.com>
1527
1528 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
1529 common/selftest.c.
1530 (COMMON_OBS): Remove selftest.o.
1531 * configure.ac: Append selftest-arch.c and common/selftest.c to
1532 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
1533 * configure: Re-generated.
1534 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
1535 GDB_SELF_TEST.
1536 (maintenance_info_selftests): Likewise.
1537
1538 2018-01-08 Xavier Roirand <roirand@adacore.com>
1539
1540 * ada-valprint.c (val_print_packed_array_elements): Use
1541 proper number of elements when printing an array indexed
1542 by an enumeration type.
1543
1544 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1545
1546 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
1547 (dw2_get_file_names_reader): Adjust.
1548 (lookup_dwo_signatured_type): Adjust.
1549 (lookup_dwp_signatured_type): Adjust.
1550 (lookup_signatured_type): Adjust.
1551 (create_type_unit_group): Adjust.
1552 (get_type_unit_group): Adjust.
1553 (process_psymtab_comp_unit_reader): Adjust.
1554 (build_type_psymtabs_reader): Adjust.
1555 (scan_partial_symbols): Adjust.
1556 (add_partial_symbol): Adjust.
1557 (add_partial_subprogram): Adjust.
1558 (peek_die_abbrev): Adjust.
1559 (fixup_go_packaging): Adjust.
1560 (process_imported_unit_die): Adjust.
1561 (dwarf2_compute_name): Adjust.
1562 (dwarf2_physname): Adjust.
1563 (read_import_statement): Adjust.
1564 (handle_DW_AT_stmt_list): Adjust.
1565 (read_file_scope): Adjust.
1566 (read_func_scope): Adjust.
1567 (read_lexical_block_scope): Adjust.
1568 (read_call_site_scope): Adjust.
1569 (read_variable): Adjust.
1570 (dwarf2_rnglists_process): Adjust.
1571 (dwarf2_ranges_process): Adjust.
1572 (dwarf2_ranges_read): Adjust.
1573 (dwarf2_get_pc_bounds): Adjust.
1574 (dwarf2_record_block_ranges): Adjust.
1575 (dwarf2_add_field): Adjust.
1576 (dwarf2_add_member_fn): Adjust.
1577 (read_structure_type): Adjust.
1578 (process_structure_scope): Adjust.
1579 (read_enumeration_type): Adjust.
1580 (read_array_type): Adjust.
1581 (mark_common_block_symbol_computed): Adjust.
1582 (read_common_block): Adjust.
1583 (read_namespace_type): Adjust.
1584 (read_namespace): Adjust.
1585 (read_module_type): Adjust.
1586 (read_tag_pointer_type): Adjust.
1587 (read_tag_ptr_to_member_type): Adjust.
1588 (read_tag_string_type): Adjust.
1589 (read_subroutine_type): Adjust.
1590 (read_typedef): Adjust.
1591 (read_base_type): Adjust.
1592 (attr_to_dynamic_prop): Adjust.
1593 (read_subrange_type): Adjust.
1594 (read_unspecified_type): Adjust.
1595 (dwarf2_read_abbrevs): Adjust.
1596 (load_partial_dies): Adjust.
1597 (read_partial_die): Adjust.
1598 (find_partial_die): Adjust.
1599 (guess_partial_die_structure_name): Adjust.
1600 (fixup_partial_die): Adjust.
1601 (read_attribute_value): Adjust.
1602 (read_addr_index): Adjust.
1603 (read_addr_index_from_leb128): Adjust.
1604 (read_str_index): Adjust.
1605 (dwarf2_string_attr): Adjust.
1606 (get_debug_line_section): Adjust.
1607 (dwarf_decode_line_header): Adjust.
1608 (lnp_state_machine::check_line_address): Adjust.
1609 (dwarf_decode_lines_1): Adjust.
1610 (dwarf_decode_lines): Adjust.
1611 (dwarf2_start_symtab): Adjust.
1612 (var_decode_location): Adjust.
1613 (new_symbol_full): Adjust.
1614 (dwarf2_const_value_data): Adjust.
1615 (dwarf2_const_value_attr): Adjust.
1616 (dwarf2_const_value): Adjust.
1617 (die_type): Adjust.
1618 (die_containing_type): Adjust.
1619 (build_error_marker_type): Adjust.
1620 (lookup_die_type): Adjust.
1621 (guess_full_die_structure_name): Adjust.
1622 (anonymous_struct_prefix): Adjust.
1623 (determine_prefix): Adjust.
1624 (dwarf2_name): Adjust.
1625 (follow_die_ref_or_sig): Adjust.
1626 (follow_die_offset): Adjust.
1627 (follow_die_ref): Adjust.
1628 (follow_die_sig_1): Adjust.
1629 (follow_die_sig): Adjust.
1630 (get_signatured_type): Adjust.
1631 (get_DW_AT_signature_type): Adjust.
1632 (decode_locdesc): Adjust.
1633 (dwarf_decode_macros): Adjust.
1634 (cu_debug_loc_section): Adjust.
1635 (fill_in_loclist_baton): Adjust.
1636 (dwarf2_symbol_mark_computed): Adjust.
1637 (init_one_comp_unit): Don't assign
1638 dwarf2_cu::dwarf2_per_objfile.
1639 (set_die_type): Adjust.
1640
1641 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
1642
1643 * dwarf2read.c (struct mapped_debug_names): Add constructor.
1644 <dwarf2_per_objfile>: New field.
1645 (dwarf2_per_objfile): Remove global.
1646 (get_dwarf2_per_objfile): New function.
1647 (set_dwarf2_per_objfile): New function.
1648 (dwarf2_build_psymtabs_hard): Change objfile parameter to
1649 dwarf2_per_objfile.
1650 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
1651 (read_abbrev_offset): Likewise.
1652 (read_indirect_string): Likewise.
1653 (read_indirect_line_string): Likewise.
1654 (read_indirect_string_at_offset): Likewise.
1655 (read_indirect_string_from_dwz): Likewise.
1656 (dwarf2_find_containing_comp_unit): Change objfile parameter to
1657 dwarf2_per_objfile.
1658 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
1659 (create_all_comp_units): Change objfile parameter to
1660 dwarf2_per_objfile.
1661 (create_all_type_units): Likewise.
1662 (process_queue): Add dwarf2_per_objfile parameter.
1663 (read_and_check_comp_unit_head): Likewise.
1664 (lookup_dwo_unit_in_dwp): Likewise.
1665 (get_dwp_file): Likewise.
1666 (process_cu_includes): Likewise.
1667 (struct free_dwo_file_cleanup_data): New struct.
1668 (dwarf2_has_info): Use get_dwarf2_per_objfile and
1669 set_dwarf2_per_objfile.
1670 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
1671 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
1672 context, adjust calls.
1673 (dw2_instantiate_symtab): Likewise.
1674 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
1675 (dw2_get_cu): Likewise.
1676 (create_cu_from_index_list): Change objfile parameter to
1677 dwarf2_per_objfile.
1678 (create_cus_from_index_list): Get dwarf2_per_objfile from
1679 context, adjust calls.
1680 (create_cus_from_index): Likewise.
1681 (create_signatured_type_table_from_index): Change objfile
1682 parameter to dwarf2_per_objfile.
1683 (create_signatured_type_table_from_debug_names): Change objfile
1684 parameter to dwarf2_per_objfile.
1685 (create_addrmap_from_index): Likewise.
1686 (create_addrmap_from_aranges): Likewise.
1687 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
1688 (dw2_setup): Remove.
1689 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
1690 context.
1691 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
1692 get_dwarf2_per_objfile.
1693 (dw2_forget_cached_source_info): Likewise.
1694 (dw2_map_symtabs_matching_filename): Likewise.
1695 (struct dw2_symtab_iterator) <index>: Remove.
1696 <dwarf2_per_objfile>: New field.
1697 (dw2_symtab_iter_init): Replace index parameter with
1698 dwarf2_per_objfile.
1699 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
1700 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
1701 (dw2_print_stats): Likewise.
1702 (dw2_dump): Likewise.
1703 (dw2_expand_symtabs_for_function): Likewise.
1704 (dw2_expand_all_symtabs): Likewise.
1705 (dw2_expand_symtabs_with_fullname): Likewise.
1706 (dw2_expand_marked_cus): Replace index and objfile parameters
1707 with dwarf2_per_objfile.
1708 (dw_expand_symtabs_matching_file_matcher): Add
1709 dwarf2_per_objfile parameter and adjust calls.
1710 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
1711 adjust calls.
1712 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
1713 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
1714 adjust calls.
1715 (create_cus_from_debug_names_list): Replace objfile parameter
1716 with dwarf2_per_objfile and adjust calls.
1717 (create_cus_from_debug_names): Likewise.
1718 (dwarf2_read_debug_names): Likewise.
1719 (mapped_debug_names::namei_to_name): Adjust call.
1720 (dw2_debug_names_iterator::next): Likewise.
1721 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
1722 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
1723 (dw2_debug_names_dump): Likewise.
1724 (dw2_debug_names_expand_symtabs_for_function): Likewise.
1725 (dw2_debug_names_expand_symtabs_matching): Likewise.
1726 (dwarf2_initialize_objfile): Likewise.
1727 (dwarf2_build_psymtabs): Likewise.
1728 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
1729 this_cu.
1730 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
1731 (read_and_check_comp_unit_head): Likewise.
1732 (read_abbrev_offset): Likewise.
1733 (create_debug_type_hash_table): Likewise.
1734 (create_debug_types_hash_table): Likewise.
1735 (create_all_type_units): Replace objfile parameter with
1736 dwarf2_per_objfile.
1737 (add_type_unit): Add dwarf2_per_objfile parameter.
1738 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
1739 with dwarf2_per_objfile.
1740 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
1741 (lookup_dwp_signatured_type): Likewise.
1742 (lookup_signatured_type): Likewise.
1743 (read_cutu_die_from_dwo): Likewise.
1744 (init_tu_and_read_dwo_dies): Likewise.
1745 (init_cutu_and_read_dies): Likewise.
1746 (init_cutu_and_read_dies_no_follow): Likewise.
1747 (allocate_type_unit_groups_table): Add objfile parameter.
1748 (create_type_unit_group): Use dwarf2_per_objfile from cu.
1749 (get_type_unit_group): Likewise.
1750 (process_psymtab_comp_unit): Update call.
1751 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
1752 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
1753 (print_tu_stats): Likewise.
1754 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
1755 in void* parameter.
1756 (build_type_psymtabs): Change objfile parameter to
1757 dwarf2_per_objfile.
1758 (process_skeletonless_type_unit): Use dwarf2_per_objfile
1759 passed in void* parameter.
1760 (process_skeletonless_type_units): Change objfile parameter to
1761 dwarf2_per_objfile.
1762 (set_partial_user): Likewise.
1763 (dwarf2_build_psymtabs_hard): Likewise.
1764 (read_comp_units_from_section): Likewise.
1765 (create_all_comp_units): Likewise.
1766 (scan_partial_symbols): Update calls.
1767 (add_partial_symbol): Likewise.
1768 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
1769 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
1770 (process_queue): Add dwarf2_per_objfile parameter.
1771 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
1772 (compute_compunit_symtab_includes): Likewise.
1773 (process_cu_includes): Add dwarf2_per_objfile parameter.
1774 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
1775 (process_full_type_unit): Likewise.
1776 (process_imported_unit_die): Update call.
1777 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
1778 (read_file_scope): Likewise.
1779 (allocate_dwo_file_hash_table): Add objfile parameter.
1780 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
1781 (create_cus_hash_table): Likewise.
1782 (create_dwp_hash_table): Likewise.
1783 (create_dwo_unit_in_dwp_v1): Likewise.
1784 (create_dwp_v2_section): Likewise.
1785 (create_dwo_unit_in_dwp_v2): Likewise.
1786 (lookup_dwo_unit_in_dwp): Likewise.
1787 (try_open_dwop_file): Likewise.
1788 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
1789 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
1790 cleanup to include a reference to dwarf2_per_objfile.
1791 (open_dwp_file): Add dwarf2_per_objfile parameter.
1792 (open_and_init_dwp_file): Likewise.
1793 (get_dwp_file): Likewise.
1794 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
1795 (queue_and_load_all_dwo_tus): Update call.
1796 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
1797 data.
1798 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
1799 (dwarf2_ranges_process): Likewise.
1800 (dwarf2_get_pc_bounds): Likewise.
1801 (mark_common_block_symbol_computed): Likewise.
1802 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
1803 (dwarf2_read_abbrevs): Update call.
1804 (read_partial_die): Use dwarf2_per_objfile from cu.
1805 (find_partial_die): Likewise.
1806 (fixup_partial_die): Likewise.
1807 (read_attribute_value): Likewise.
1808 (read_indirect_string_at_offset_from): Add objfile parameter.
1809 (read_indirect_string_at_offset): Add dwarf2_per_objfile
1810 parameter.
1811 (read_indirect_string_from_dwz): Add objfile parameter.
1812 (read_indirect_string): Add objfile parameter.
1813 (read_addr_index_1): Add dwarf2_per_objfile parameter.
1814 (read_addr_index): Use dwarf2_per_objfile from cu.
1815 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
1816 call dw2_setup.
1817 (read_str_index): Use dwarf2_per_objfile from cu.
1818 (get_debug_line_section): Likewise.
1819 (read_formatted_entries): Add dwarf2_per_objfile parameter.
1820 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
1821 (new_symbol_full): Use dwarf2_per_objfile from cu.
1822 (build_error_marker_type): Likewise.
1823 (lookup_die_type): Likewise.
1824 (determine_prefix): Likewise.
1825 (follow_die_offset): Likewise.
1826 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
1827 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
1828 (dwarf2_fetch_die_type_sect_off): Likewise.
1829 (dwarf2_get_die_type): Likewise.
1830 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
1831 (get_signatured_type): Likewise.
1832 (get_DW_AT_signature_type): Likewise.
1833 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
1834 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
1835 (cu_debug_loc_section): Likewise.
1836 (fill_in_loclist_baton): Likewise.
1837 (dwarf2_symbol_mark_computed): Likewise.
1838 (dwarf2_find_containing_comp_unit): Change objfile parameter to
1839 dwarf2_per_objfile.
1840 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
1841 parameter.
1842 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
1843 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
1844 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
1845 (set_die_type): Use dwarf2_free_objfile from cu.
1846 (get_die_type_at_offset): Likewise.
1847 (dwarf2_per_objfile_free): Don't assign global variable.
1848 (debug_names) <constructor>: Add dwarf2_per_objfile
1849 parameter, update m_debugstrlookup construction.
1850 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
1851 parameter.
1852 <m_dwarf2_per_objfile>: New field.
1853 <lookup>: Use m_dwarf2_per_objfile.
1854 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
1855 (psyms_seen_size): Likewise.
1856 (write_gdbindex): Replace objfile parameter with
1857 dwarf2_per_objfile.
1858 (write_debug_names): Likewise.
1859 (write_psymtabs_to_index): Likewise.
1860 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
1861 calls.
1862
1863 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
1864
1865 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
1866 <dwarf2_per_objfile>: New field.
1867 (struct dwarf2_per_cu_data) <objfile>: Remove.
1868 <dwarf2_per_objfile>: New field.
1869 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
1870 of objfile.
1871 (create_signatured_type_table_from_index): Likewise.
1872 (create_debug_type_hash_table): Likewise.
1873 (fill_in_sig_entry_from_dwo_entry): Likewise.
1874 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
1875 (create_type_unit_group): Assign dwarf2_per_objfile instead of
1876 objfile.
1877 (create_partial_symtab): Access objfile through
1878 dwarf2_per_objfile.
1879 (process_psymtab_comp_unit_reader): Likewise.
1880 (read_comp_units_from_section): Likewise.
1881 (scan_partial_symbols): Likewise.
1882 (add_partial_symbol): Likewise.
1883 (add_partial_subprogram): Likewise.
1884 (peek_die_abbrev): Likewise.
1885 (fixup_go_packaging): Likewise.
1886 (process_full_comp_unit): Likewise.
1887 (process_full_type_unit): Likewise.
1888 (process_imported_unit_die): Likewise.
1889 (dwarf2_compute_name): Likewise.
1890 (dwarf2_physname): Likewise.
1891 (read_import_statement): Likewise.
1892 (create_cus_hash_table): Assign dwarf2_physname instead of
1893 objfile.
1894 (read_func_scope): Access objfile through dwarf2_per_objfile.
1895 (read_lexical_block_scope): Likewise.
1896 (read_call_site_scope): Likewise.
1897 (read_variable): Likewise.
1898 (dwarf2_rnglists_process): Likewise.
1899 (dwarf2_ranges_process): Likewise.
1900 (dwarf2_ranges_read): Likewise.
1901 (dwarf2_record_block_ranges): Likewise.
1902 (dwarf2_add_field): Likewise.
1903 (dwarf2_add_member_fn): Likewise.
1904 (read_structure_type): Likewise.
1905 (process_structure_scope): Likewise.
1906 (read_enumeration_type): Likewise.
1907 (read_array_type): Likewise.
1908 (read_common_block): Likewise.
1909 (read_namespace_type): Likewise.
1910 (read_namespace): Likewise.
1911 (read_module_type): Likewise.
1912 (read_tag_pointer_type): Likewise.
1913 (read_tag_ptr_to_member_type): Likewise.
1914 (read_tag_string_type): Likewise.
1915 (read_subroutine_type): Likewise.
1916 (read_typedef): Likewise.
1917 (read_base_type): Likewise.
1918 (attr_to_dynamic_prop): Likewise.
1919 (read_subrange_type): Likewise.
1920 (read_unspecified_type): Likewise.
1921 (load_partial_dies): Likewise.
1922 (read_partial_die): Likewise.
1923 (find_partial_die): Likewise.
1924 (guess_partial_die_structure_name): Likewise.
1925 (fixup_partial_die): Likewise.
1926 (read_attribute_value): Likewise.
1927 (read_addr_index_from_leb128): Likewise.
1928 (dwarf2_read_addr_index): Likewise.
1929 (dwarf2_string_attr): Likewise.
1930 (lnp_state_machine::check_line_address): Likewise.
1931 (dwarf_decode_lines_1): Likewise.
1932 (dwarf_decode_lines): Likewise.
1933 (dwarf2_start_symtab): Likewise.
1934 (var_decode_location): Likewise.
1935 (new_symbol_full): Likewise.
1936 (dwarf2_const_value_data): Likewise.
1937 (dwarf2_const_value_attr): Likewise.
1938 (dwarf2_const_value): Likewise.
1939 (die_type): Likewise.
1940 (die_containing_type): Likewise.
1941 (lookup_die_type): Likewise.
1942 (guess_full_die_structure_name): Likewise.
1943 (anonymous_struct_prefix): Likewise.
1944 (dwarf2_name): Likewise.
1945 (follow_die_ref_or_sig): Likewise.
1946 (follow_die_offset): Likewise.
1947 (follow_die_ref): Likewise.
1948 (dwarf2_fetch_die_loc_sect_off): Likewise.
1949 (dwarf2_fetch_constant_bytes): Likewise.
1950 (dwarf2_fetch_die_type_sect_off): Likewise.
1951 (dwarf2_get_die_type): Likewise.
1952 (follow_die_sig): Likewise.
1953 (decode_locdesc): Likewise.
1954 (dwarf2_per_cu_objfile): Likewise.
1955 (dwarf2_per_cu_text_offset): Likewise.
1956 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
1957 objfile.
1958 (set_die_type): Access objfile through
1959 dwarf2_per_objfile.
1960
1961 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
1962
1963 * valprint.c (converted_character_d): Remove typedef.
1964 (DEF_VEC_O (converted_character_d)): Remove.
1965 (count_next_character): Use std::vector.
1966 (print_converted_chars_to_obstack): Likewise.
1967 (generic_printstr): Likewise.
1968
1969 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1970
1971 * xml-support.h (struct gdb_xml_value): Add constructor.
1972 <value>: Change type to unique_xmalloc_ptr.
1973 (gdb_xml_value_s): Remove typedef.
1974 (DEF_VEC_O (gdb_xml_value_s)): Remove.
1975 (gdb_xml_element_start_handler): Change parameter type to
1976 std::vector.
1977 (xml_find_attribute): Likewise.
1978 * xml-support.c (xml_find_attribute): Change parameter type to
1979 std::vector and adjust.
1980 (gdb_xml_values_cleanup): Remove.
1981 (gdb_xml_parser::start_element): Adjust to std::vector.
1982 (xinclude_start_include): Change paraeter type to std::vector
1983 and adjust.
1984 * btrace.c (check_xml_btrace_version): Likewise.
1985 (parse_xml_btrace_block): Likewise.
1986 (parse_xml_btrace_pt_config_cpu): Likewise.
1987 (parse_xml_btrace_pt): Likewise.
1988 (parse_xml_btrace_conf_bts): Likewise.
1989 (parse_xml_btrace_conf_pt): Likewise.
1990 * memory-map.c (memory_map_start_memory): Likewise.
1991 (memory_map_start_property): Likewise.
1992 * osdata.c (osdata_start_osdata): Likewise.
1993 (osdata_start_item): Likewise.
1994 (osdata_start_column): Likewise.
1995 * remote.c (start_thread): Likewise.
1996 * solib-aix.c (library_list_start_library): Likewise.
1997 (library_list_start_list): Likewise.
1998 * solib-svr4.c (library_list_start_library): Likewise.
1999 (svr4_library_list_start_list): Likewise.
2000 * solib-target.c (library_list_start_segment): Likewise.
2001 (library_list_start_section): Likewise.
2002 (library_list_start_library): Likewise.
2003 (library_list_start_list): Likewise.
2004 * tracepoint.c (traceframe_info_start_memory): Likewise.
2005 (traceframe_info_start_tvar): Likewise.
2006 * xml-syscall.c (syscall_start_syscall): Likewise.
2007 * xml-tdesc.c (tdesc_start_target): Likewise.
2008 (tdesc_start_feature): Likewise.
2009 (tdesc_start_reg): Likewise.
2010 (tdesc_start_union): Likewise.
2011 (tdesc_start_struct): Likewise.
2012 (tdesc_start_flags): Likewise.
2013 (tdesc_start_enum): Likewise.
2014 (tdesc_start_field): Likewise.
2015 (tdesc_start_enum_value): Likewise.
2016 (tdesc_start_vector): Likewise.
2017
2018 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2019
2020 * extension.h (struct xmethod_worker) <clone>: Remove.
2021 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
2022 Remove.
2023 (python_xmethod_worker::clone): Remove.
2024 * valops.c (find_overload_match): Use std::move instead of
2025 clone.
2026
2027 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2028
2029 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
2030 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
2031 <free_xmethod_worker_data>: Remove.
2032 <get_matching_xmethod_workers>: Chance VEC to std::vector.
2033 <get_xmethod_arg_types>: Remove.
2034 <get_xmethod_result_type>: Remove.
2035 <invoke_xmethod>: Remove.
2036 * extension.c (new_xmethod_worker): Remove.
2037 (clone_xmethod_worker): Remove.
2038 (get_matching_xmethod_workers): Return void, pass std::vector by
2039 pointer.
2040 (get_xmethod_arg_types): Rename to...
2041 (xmethod_worker::get_arg_types): ... this, and adjust.
2042 (get_xmethod_result_type): Rename to...
2043 (xmethod_worker::get_result_type): ... this, and adjust.
2044 (invoke_xmethod): Remove.
2045 (free_xmethod_worker): Remove.
2046 (free_xmethod_worker_vec): Remove.
2047 * extension.h (enum ext_lang_rc): Move here from
2048 extension-priv.h.
2049 (struct xmethod_worker): Add constructor and destructor.
2050 <data>: Remove.
2051 <value>: Remove.
2052 <invoke, clone, do_get_result_type, do_get_arg_types>: New
2053 virtual pure methods.
2054 <get_arg_types, get_result_type>: New methods.
2055 (xmethod_worker_ptr): Remove typedef.
2056 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
2057 (xmethod_worker_vec): Remove typedef.
2058 (xmethod_worker_up): New typedef.
2059 (invoke_xmethod): Remove.
2060 (clone_xmethod_worker): Remove.
2061 (free_xmethod_worker): Remove.
2062 (free_xmethod_worker_vec): Remove.
2063 (get_xmethod_arg_types): Remove.
2064 (get_xmethod_result_type): Remove.
2065 * valops.c (find_method_list): Use std::vector, don't use
2066 intermediate vector.
2067 (value_find_oload_method_list): Use std::vector.
2068 (find_overload_match): Use std::vector.
2069 (find_oload_champ): Use std::vector.
2070 * value.c (value_free): Use operator delete.
2071 (value_of_xmethod): Rename to...
2072 (value_from_xmethod): ... this. Don't assign
2073 xmethod_worker::value, take rvalue-reference.
2074 (result_type_of_xmethod): Adjust.
2075 (call_xmethod): Adjust.
2076 * value.h: Include extension.h.
2077 (struct xmethod_worker): Don't forward-declare.
2078 (value_of_xmethod): Rename to...
2079 (value_from_xmethod): ... this, take rvalue-reference.
2080 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
2081 (struct python_xmethod_worker): ... this, add constructor and
2082 destructor.
2083 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
2084 (gdbpy_free_xmethod_worker_data): Rename to...
2085 (python_xmethod_worker::~python_xmethod_worker): ... this and
2086 adjust.
2087 (gdbpy_clone_xmethod_worker_data): Rename to...
2088 (python_xmethod_worker::clone): ... this and adjust.
2089 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
2090 temporary vector.
2091 (gdbpy_get_xmethod_arg_types): Rename to...
2092 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
2093 (gdbpy_get_xmethod_result_type): Rename to...
2094 (python_xmethod_worker::do_get_result_type): ... this and
2095 adjust.
2096 (gdbpy_invoke_xmethod): Rename to...
2097 (python_xmethod_worker::invoke): ... this and adjust.
2098 (new_python_xmethod_worker): Rename to...
2099 (python_xmethod_worker::python_xmethod_worker): ... this and
2100 adjust.
2101 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
2102 Remove.
2103 (gdbpy_free_xmethod_worker_data): Remove.
2104 (gdbpy_get_matching_xmethod_workers): Use std::vector.
2105 (gdbpy_get_xmethod_arg_types): Remove.
2106 (gdbpy_get_xmethod_result_type): Remove.
2107 (gdbpy_invoke_xmethod): Remove.
2108 * python/python.c (python_extension_ops): Remove obsolete
2109 callbacks.
2110
2111 2018-01-05 Pedro Alves <palves@redhat.com>
2112
2113 PR gdb/18653
2114 * common/signals-state-save-restore.c
2115 (save_original_signals_state): New parameter 'quiet'. Warn if we
2116 find a custom handler preinstalled, instead of internal erroring.
2117 But only warn if !quiet.
2118 * common/signals-state-save-restore.h
2119 (save_original_signals_state): New parameter 'quiet'.
2120 * main.c (captured_main_1): Move save_original_signals_state call
2121 after option handling, and pass QUIET.
2122
2123 2018-01-05 Pedro Alves <palves@redhat.com>
2124
2125 * spu-tdep.c (spu_catch_start): Pass
2126 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
2127
2128 2018-01-05 Pedro Alves <palves@redhat.com>
2129
2130 PR gdb/22670
2131 * ada-lang.c (literal_symbol_name_matcher): New function.
2132 (ada_get_symbol_name_matcher): Use it for
2133 symbol_name_match_type::SEARCH_NAME.
2134 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
2135 it down instead of assuming symbol_name_match_type::FULL.
2136 * block.h (block_lookup_symbol): New parameter 'match_type'.
2137 * c-valprint.c (print_unpacked_pointer): Use
2138 lookup_symbol_search_name instead of lookup_symbol.
2139 * compile/compile-object-load.c (get_out_value_type): Pass down
2140 symbol_name_match_type::SEARCH_NAME.
2141 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
2142 symbol_name_match_type::FULL.
2143 * cp-support.c (cp_get_symbol_name_matcher): Handle
2144 symbol_name_match_type::SEARCH_NAME.
2145 * infrun.c (insert_exception_resume_breakpoint): Use
2146 lookup_symbol_search_name.
2147 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
2148 * psymtab.c (maintenance_check_psymtabs): Use
2149 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
2150 * stack.c (print_frame_args): Use lookup_symbol_search_name and
2151 SYMBOL_SEARCH_NAME.
2152 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
2153 if symbol_name_match_type::SEARCH_NAME.
2154 (lookup_symbol_in_language): Pass down
2155 symbol_name_match_type::FULL.
2156 (lookup_symbol_search_name): New.
2157 (lookup_language_this): Pass down
2158 symbol_name_match_type::SEARCH_NAME.
2159 (lookup_symbol_aux, lookup_local_symbol): New parameter
2160 'match_type'. Pass it down.
2161 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
2162 (lookup_symbol_search_name): New declaration.
2163 (lookup_symbol_in_block): New 'match_type' parameter.
2164
2165 2018-01-05 Pedro Alves <palves@redhat.com>
2166
2167 PR gdb/22670
2168 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
2169 ada_lookup_symbol.
2170 (ada_lookup_symbol): Reimplement in terms of
2171 ada_lookup_symbol_list, bits factored out from
2172 ada_lookup_encoded_symbol.
2173
2174 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2175
2176 * ada-exp.y (write_object_renaming): When subscripting an array
2177 using a symbol as the index, pass the block in call to
2178 ada_lookup_encoded_symbol when looking that symbol up.
2179
2180 2018-01-05 Jerome Guitton <guitton@adacore.com>
2181
2182 * ada-lang.c (ada_array_length): Use ada_index_type instead of
2183 TYPE_INDEX_TYPE.
2184
2185 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2186
2187 * ada-lang.c (ada_to_fixed_value_create): Add handling of
2188 the case where VALUE_LVAL (val0) is not lval_memory.
2189
2190 2018-01-05 Xavier Roirand <roirand@adacore.com>
2191
2192 * ada-valprint.c (print_optional_low_bound): Handle
2193 character-indexed array printing like boolean-indexed array
2194 printing.
2195
2196 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2197
2198 * NEWS: Create a new section for the next release branch.
2199 Rename the section of the current branch, now that it has
2200 been cut.
2201
2202 2018-01-05 Joel Brobecker <brobecker@adacore.com>
2203
2204 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
2205 * version.in: Bump version to 8.1.50.DATE-git.
2206
2207 2018-01-03 Xavier Roirand <roirand@adacore.com>
2208
2209 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
2210 Add field.
2211 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
2212 Add field.
2213 (default_exception_support_info) <catch_handlers_sym>: Add field.
2214 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
2215 (ada_exception_name_addr_1): Add "catch handlers" handling.
2216 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
2217 Update all callers.
2218 (create_excep_cond_exprs) <ex>: Add parameter.
2219 (re_set_exception): Update create_excep_cond_exprs call.
2220 (print_it_exception, print_one_exception, print_mention_exception)
2221 (print_recreate_exception): Add "catch handler" handling.
2222 (allocate_location_catch_handlers, re_set_catch_handlers)
2223 (check_status_catch_handlers, print_it_catch_handlers)
2224 (print_one_catch_handlers, print_mention_catch_handlers)
2225 (print_recreate_catch_handlers): New function.
2226 (catch_handlers_breakpoint_ops): New variable.
2227 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
2228 Add parameter. Add "catch handler" handling.
2229 (ada_exception_sym_name, ada_exception_breakpoint_ops):
2230 Add "catch handler" handling.
2231 (ada_exception_catchpoint_cond_string): Add "catch handler"
2232 handling.
2233 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
2234 call.
2235 (catch_ada_handlers_command): New function.
2236 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
2237 operations structure.
2238 (_initialize_ada_language): Add "catch handlers" command entry.
2239 * NEWS: Document "catch handlers" feature.
2240
2241 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2242
2243 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
2244 account when creating the array type of the slice.
2245 (ada_value_slice): Likewise.
2246
2247 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2248
2249 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
2250 New enum value.
2251 (create_array_type_with_stride): Add byte_stride_prop parameter.
2252 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
2253 New parameter. Update all callers in this file.
2254 (array_type_has_dynamic_stride): New function.
2255 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
2256 of arrays with dynamic byte strides.
2257 * dwarf2read.c (read_array_type): Add support for dynamic
2258 DW_AT_byte_stride attributes.
2259
2260 2018-01-02 Joel Brobecker <brobecker@adacore.com>
2261
2262 * dwarf2read.c (read_unspecified_type): Treat
2263 DW_TAG_enumeration_type DIEs from Ada units as stubs.
2264
2265 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2266
2267 Update copyright year range in all GDB files.
2268
2269 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2270
2271 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
2272 and gdb/testsuite/gdb.base/step-line.c.
2273
2274 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2275
2276 * copyright.py (main): Dump the contents of
2277 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
2278 even if BY_HAND is empty.
2279
2280 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2281
2282 * top.c (print_gdb_version): Update Copyright year in version
2283 message.
2284
2285 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2286
2287 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
2288
2289 For older changes see ChangeLog-2017.
2290 \f
2291 Local Variables:
2292 mode: change-log
2293 left-margin: 8
2294 fill-column: 74
2295 version-control: never
2296 coding: utf-8
2297 End:
This page took 0.120418 seconds and 4 git commands to generate.