Constify commands maint.c, plus maintenance_print_type
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
58971144
TT
12017-09-27 Tom Tromey <tom@tromey.com>
2
3 * typeprint.c (maintenance_print_type): Constify.
4 * maint.c (maintenance_dump_me, maintenance_demangle)
5 (maintenance_time_display, maintenance_info_sections)
6 (maintenance_print_statistics, maintenance_deprecate)
7 (maintenance_undeprecate): Constify.
8 (maintenance_do_deprecate): Constify. Use std::string.
9 (maintenance_selftest): Constify.
10 * gdbtypes.h (maintenance_print_type): Constify.
11
c482f52c
TT
122017-09-27 Tom Tromey <tom@tromey.com>
13
14 * hppa-tdep.c (unwind_command): Constify.
15
e100df1a
TT
162017-09-27 Tom Tromey <tom@tromey.com>
17
18 * target-descriptions.c (unset_tdesc_filename_cmd)
19 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
20 Constify.
21
31d56ade
TT
222017-09-27 Tom Tromey <tom@tromey.com>
23
24 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
25
b961da0b
TT
262017-09-27 Tom Tromey <tom@tromey.com>
27
28 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
29
e2d8ae16
TT
302017-09-27 Tom Tromey <tom@tromey.com>
31
32 * tui/tui-regs.c (tui_reg_command): Constify.
33
863779b0
TT
342017-09-27 Tom Tromey <tom@tromey.com>
35
36 * skip.c (skip_file_command, skip_function_command)
37 (skip_enable_command, skip_disable_command, skip_delete_command):
38 Constify.
39
cdb34d4a
TT
402017-09-27 Tom Tromey <tom@tromey.com>
41
42 * record-btrace.c (cmd_record_btrace_bts_start)
43 (cmd_record_btrace_pt_start): Constify.
44
e99c83e7
TT
452017-09-27 Tom Tromey <tom@tromey.com>
46
47 * symmisc.c (maintenance_print_symbols)
48 (maintenance_print_msymbols, maintenance_print_objfiles)
49 (maintenance_info_symtabs, maintenance_check_symtabs)
50 (maintenance_expand_symtabs, maintenance_info_line_tables):
51 Constify.
52
32faf971
TT
532017-09-27 Tom Tromey <tom@tromey.com>
54
55 * top.c (new_ui_command): Constify.
56
2cf311eb
TT
572017-09-27 Tom Tromey <tom@tromey.com>
58
59 * symfile.c (add_symbol_file_command)
60 (remove_symbol_file_command, list_overlays_command)
61 (map_overlay_command, unmap_overlay_command)
62 (overlay_auto_command, overlay_manual_command)
63 (overlay_off_command, overlay_load_command): Constify.
64
e6738699
TT
652017-09-27 Tom Tromey <tom@tromey.com>
66
67 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
68 (info_spu_mailbox_command, info_spu_dma_command)
69 (info_spu_proxydma_command): Constify.
70
aa360cd5
TT
712017-09-27 Tom Tromey <tom@tromey.com>
72
73 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
74
898241a5
TT
752017-09-27 Tom Tromey <tom@tromey.com>
76
77 * cli/cli-script.c (user_defined_command): Constify.
78
2d0ac106
TT
792017-09-27 Tom Tromey <tom@tromey.com>
80
81 * cli/cli-dump.c (dump_memory_command, dump_value_command)
82 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
83 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
84 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
85 (dump_binary_value, append_binary_memory, append_binary_value):
86 Constify.
87 (struct dump_context) <func>: Constify.
88 (add_dump_command): Update.
89
dede02ce
TT
902017-09-27 Tom Tromey <tom@tromey.com>
91
92 * cli/cli-cmds.c (show_version, show_configuration)
93 (source_command, show_user): Constify.
94
d3cb6b99
TT
952017-09-27 Tom Tromey <tom@tromey.com>
96
97 * target.c (maintenance_print_target_stack): Constify.
98
1970a12f
TT
992017-09-27 Tom Tromey <tom@tromey.com>
100
101 * interps.c (interpreter_exec_cmd): Constify.
102
41243651
TT
1032017-09-27 Tom Tromey <tom@tromey.com>
104
105 * record-full.c (cmd_record_full_restore): Constify.
106
4465d9db
TT
1072017-09-27 Tom Tromey <tom@tromey.com>
108
109 * memattr.c (enable_mem_command, disable_mem_command)
110 (delete_mem_command): Constify.
111
ad25e423
TT
1122017-09-27 Tom Tromey <tom@tromey.com>
113
114 * value.c (show_convenience): Constify.
115
d64097b1
TT
1162017-09-27 Tom Tromey <tom@tromey.com>
117
118 * gdbcore.h (core_file_command): Update.
119 * corefile.c (core_file_command): Constify.
120
4d4589ef
TT
1212017-09-27 Tom Tromey <tom@tromey.com>
122
123 * user-regs.c (maintenance_print_user_registers): Constify.
124
32a7bf17
TT
1252017-09-27 Tom Tromey <tom@tromey.com>
126
127 * cp-namespace.c (maintenance_cplus_namespace): Constify.
128
4a475551
TT
1292017-09-27 Tom Tromey <tom@tromey.com>
130
131 * cp-support.c (first_component_command): Constify.
132
990b9f9f
TT
1332017-09-27 Tom Tromey <tom@tromey.com>
134
135 * psymtab.c (maintenance_print_psymbols)
136 (maintenance_info_psymtabs, maintenance_check_psymtabs):
137 Constify.
138
c281872e
TT
1392017-09-27 Tom Tromey <tom@tromey.com>
140
141 * windows-tdep.c (display_tib): Constify.
142
5b64bf74
TT
1432017-09-27 Tom Tromey <tom@tromey.com>
144
145 * linux-fork.c (delete_checkpoint_command)
146 (detach_checkpoint_command): Constify.
147
4ada038f
TT
1482017-09-27 Tom Tromey <tom@tromey.com>
149
150 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
151
57f5a81b
TT
1522017-09-27 Tom Tromey <tom@tromey.com>
153
154 * arc-tdep.c (dump_arc_instruction_command): Constify.
155
b0a8e6c4
TT
1562017-09-27 Tom Tromey <tom@tromey.com>
157
158 * valprint.c (set_radix, show_radix): Constify.
159
8d97dc1c
TT
1602017-09-27 Tom Tromey <tom@tromey.com>
161
162 * dtrace-probe.c (info_probes_dtrace_command): Constify.
163
eb7c454d
TT
1642017-09-27 Tom Tromey <tom@tromey.com>
165
166 * command.h (not_just_help_class_command): Update.
167 * cli/cli-decode.h (not_just_help_class_command): Update.
168 * cli/cli-decode.c (not_just_help_class_command): Constify.
169
e4e33335
TT
1702017-09-27 Tom Tromey <tom@tromey.com>
171
172 * gdb_bfd.c (maintenance_info_bfds): Constify.
173
0450cc4c
TT
1742017-09-27 Tom Tromey <tom@tromey.com>
175
176 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
177 overloads.
178 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
179 (do_const_cfunc): New function.
180 (cmd_cfunc_eq): New overload.
181 (cli_user_command_p): Check do_const_cfunc.
182 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
183 const_cfunc.
184 * command.h (add_cmd): Add const overload and no-function
185 overload.
186 (set_cmd_cfunc): Add const overload.
187 (cmd_const_cfunc_ftype): Declare.
188 (cmd_cfunc_eq): Add const overload.
189 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
190 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
191 overload.
192
a9bbfbd8
TT
1932017-09-27 Tom Tromey <tom@tromey.com>
194
195 * macroexp.c (get_next_token_for_substitution): New function.
196 (substitute_args): Call it. Check for __VA_OPT__.
197
5230b05a
WT
1982017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
199 Pedro Alves <palves@redhat.com>
200
201 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
202 producer_is_icc_lt_14.
203 (producer_is_icc_lt_14): New function.
204 (check_producer): Add code for checking version of ICC.
205 (producer_is_icc): Move to producer.c.
206 (read_structure_type): Restrict ICC workaround to ICC<14.
207 * producer.c: Include selftest.h.
208 (producer_is_icc, producer_parsing_tests, _initialize_producer):
209 New functions.
210 * producer.h (producer_is_icc): New declaration.
211
b32b108a
WT
2122017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
213
214 * Makefile.in (SFILES): Add producer.c.
215 (COMMON_OBS): Add producer.o
216 * amd64-tdep.c (producer.h): Add new include.
217 * dwarf2read.c (producer.h): Add new include.
218 * producer.c: New file.
219 * producer.h: New file.
220 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
221 producer.c.
222 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
223 producer.h.
224
5007d765
MK
2252017-09-26 Matthias Klose <doko@ubuntu.com>
226
227 * configure.ac: Search ncursesw before ncurses.
228 Check ncursesw/ncurses.h before ncurses/ncurses.h.
229 * gdb_curses.h: Include <ncursesw/ncurses.h>
230 * config.in, configure: Regenerate.
231
281c4447
RO
2322017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
233
234 PR gdb/22185
235 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
236 obsolete.
237 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
238 Remove i386sol2 support.
239 * configure.nat <i386sol2>: Remove.
240 <sol2-64>: Fold into ...
241 <sol2>: ... this.
242 Move common settings to default section.
243 Add sol-thread.o.
244 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
245 x86_64-*-solaris2.1[0-9]*>: Rename to ...
246 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
247 <i[34567]86-*-solaris*>: Remove.
248 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
249
250 * configure.ac: Remove wctype in libw check.
251 (_MSE_INT_H): Don't define on Solaris 7-9.
252 <solaris*>: Remove libthread_db.so.1 check.
253 * configure: Regenerate.
254 * config.in: Regenerate.
255
256 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
257 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
258 (gdb_ps_size_t): Remove.
259 Use base types in users.
260 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
261
262 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
263
39b06c20
RO
2642017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
265
266 PR build/22206
267 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
268 (adi_is_addr_mapped): Likewise.
269 (PSR_ICC): Don't redefine.
270 (PSR_IMPL): Likewise.
271
6c3e20f1
TT
2722017-09-25 Tom Tromey <tom@tromey.com>
273
274 * regcache.c (regcache::dump): Use string_printf.
275
b292235f
TT
2762017-09-25 Tom Tromey <tom@tromey.com>
277
278 * regcache.c (class regcache_invalidator): New.
279 (struct register_to_invalidate): Remove.
280 (make_cleanup_regcache_invalidate): Remove.
281 (regcache::raw_write): Use regcache_invalidator.
282
9ac86b52
TT
2832017-09-25 Tom Tromey <tom@tromey.com>
284
285 * spu-tdep.c (spu2ppu_sniffer): Update.
286 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
287 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
288 Remove.
289 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
290 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
291 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
292 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
293 (frame_pop): Update.
294
c0e383c6
TT
2952017-09-25 Tom Tromey <tom@tromey.com>
296
297 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
298 * regcache.h (regcache_xfree): Don't declare.
299 * regcache.c (regcache_xfree): Remove.
300 (do_regcache_xfree): Use delete.
301 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
302 * linux-fork.c (free_fork): Use delete.
303 (fork_save_infrun_state): Likewise.
304 * jit.c (jit_dealloc_cache): Use delete.
305 * infrun.c (discard_infcall_suspend_state): Use delete.
306
791199cc
TT
3072017-09-25 Tom Tromey <tom@tromey.com>
308
309 * regcache.h (regcache_xmalloc): Don't declare.
310 (regcache_raw_set_cached_value): Update comment.
311 * regcache.c (regcache_xmalloc): Remove.
312 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
313 * jit.c (jit_frame_sniffer): Use new.
314 * frame.c (frame_save_as_regcache): Use new.
315
289e23aa
AA
3162017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
317
318 * NEWS: Advertise support for guarded-storage registers on IBM z.
319
1b63490c
AA
3202017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
321
322 * s390-linux-nat.c (have_regset_gs): New static variable.
323 (s390_linux_fetch_inferior_registers): Handle guarded-storage
324 control block and guarded-storage broadcast control regsets.
325 (s390_read_description): Detect whether the target has
326 guarded-storage support, return appropriate tdesc.
327 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
328 (features/s390x-gs-linux64.c): Likewise.
329 (struct gdbarch_tdep) <have_gs>: New field.
330 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
331 (s390_gsbc_regset): New variables.
332 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
333 and s390_gsbc_regset, if applicable.
334 (s390_core_read_description): Check whether core file was from a
335 target with guarded-storage support; include appropriate regsets.
336 (s390_gdbarch_init): Add registers for guarded-storage support.
337 (_initialize_s390_tdep): Initialize new target descriptions that
338 include registers for guarded-storage support.
339 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
340 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
341 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
342 (S390_NUM_REGS): Adjust macro definition.
343 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
344 (tdesc_s390x_gs_linux64): New declarations.
345
96235dc1
AA
3462017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
347
348 * features/s390-gs-linux64.xml: New file.
349 * features/s390-gs.xml: New file.
350 * features/s390-gsbc.xml: New file.
351 * features/s390x-gs-linux64.xml: New file.
352 * features/Makefile (WHICH): Add s390-gs-linux64 and
353 s390x-gs-linux64.
354 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
355 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
356 * features/s390-gs-linux64.c: New generated file.
357 * features/s390x-gs-linux64.c: New file.
358 * regformats/s390-gs-linux64.dat: New file.
359 * regformats/s390x-gs-linux64.dat: New file.
360
b4a7c699
TT
3612017-09-23 Tom Tromey <tom@tromey.com>
362
363 * defs.h (make_cleanup_override_quit_handler): Don't declare.
364
c2f97536
TT
3652017-09-22 Tom Tromey <tom@tromey.com>
366
367 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
368 type to scoped_restore_tmpl.
369 <scoped_input_handler>: Initialize m_quit_handler directly.
370
43573013
SDJ
3712017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
372
373 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
374 (cd_command): Likewise. Free "current_directory" before
375 assigning to it.
376 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
377 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
378 * top.c (gdb_dirbuf): Remove global declaration.
379 * top.h (gdb_dirbuf): Likewise.
380
6ec2e0f5
SDJ
3812017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
382
383 * gnulib/aclocal.m4: Regenerate.
384 * gnulib/config.in: Regenerate.
385 * gnulib/configure: Regenerate.
386 * gnulib/import/Makefile.am: Regenerate.
387 * gnulib/import/Makefile.in: Regenerate.
388 * gnulib/import/assure.h: New file.
389 * gnulib/import/at-func.c: Likewise
390 * gnulib/import/chdir-long.c: New file.
391 * gnulib/import/chdir-long.h: New file.
392 * gnulib/import/cloexec.c: New file.
393 * gnulib/import/cloexec.h: New file.
394 * gnulib/import/close.c: New file.
395 * gnulib/import/closedir.c: New file.
396 * gnulib/import/dirent-private.h: New file.
397 * gnulib/import/dup-safer.c: New file.
398 * gnulib/import/dup.c: New file.
399 * gnulib/import/dup2.c: New file.
400 * gnulib/import/error.c: New file.
401 * gnulib/import/error.h: New file.
402 * gnulib/import/exitfail.c: New file.
403 * gnulib/import/exitfail.h: New file.
404 * gnulib/import/fchdir.c: New file.
405 * gnulib/import/fcntl.c: New file.
406 * gnulib/import/fcntl.in.h: New file.
407 * gnulib/import/fd-hook.c: New file.
408 * gnulib/import/fd-hook.h: New file.
409 * gnulib/import/fd-safer.c: New file.
410 * gnulib/import/fdopendir.c: New file.
411 * gnulib/import/filename.h: New file.
412 * gnulib/import/filenamecat-lgpl.c: New file.
413 * gnulib/import/filenamecat.h: New file.
414 * gnulib/import/fstat.c: New file.
415 * gnulib/import/fstatat.c: New file.
416 * gnulib/import/getcwd-lgpl.c: New file.
417 * gnulib/import/getcwd.c: New file.
418 * gnulib/import/getdtablesize.c: New file.
419 * gnulib/import/getlogin_r.c: New file.
420 * gnulib/import/getprogname.c: New file.
421 * gnulib/import/getprogname.h: New file.
422 * gnulib/import/gettext.h: New file.
423 * gnulib/import/glob-libc.h: New file.
424 * gnulib/import/glob.c: New file.
425 * gnulib/import/glob.in.h: New file.
426 * gnulib/import/intprops.h: New file.
427 * gnulib/import/m4/chdir-long.m4: New file.
428 * gnulib/import/m4/close.m4: New file.
429 * gnulib/import/m4/closedir.m4: New file.
430 * gnulib/import/m4/d-ino.m4: New file.
431 * gnulib/import/m4/d-type.m4: New file.
432 * gnulib/import/m4/dup.m4: New file.
433 * gnulib/import/m4/dup2.m4: New file.
434 * gnulib/import/m4/error.m4: New file.
435 * gnulib/import/m4/fchdir.m4: New file.
436 * gnulib/import/m4/fcntl.m4: New file.
437 * gnulib/import/m4/fcntl_h.m4: New file.
438 * gnulib/import/m4/fdopendir.m4: New file.
439 * gnulib/import/m4/filenamecat.m4: New file.
440 * gnulib/import/m4/fstat.m4: New file.
441 * gnulib/import/m4/fstatat.m4: New file.
442 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
443 * gnulib/import/m4/getcwd-path-max.m4: New file.
444 * gnulib/import/m4/getcwd.m4: New file.
445 * gnulib/import/m4/getdtablesize.m4: New file.
446 * gnulib/import/m4/getlogin_r.m4: New file.
447 * gnulib/import/m4/getprogname.m4: New file.
448 * gnulib/import/m4/glob.m4: New file.
449 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
450 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
451 * gnulib/import/m4/mempcpy.m4: New file.
452 * gnulib/import/m4/memrchr.m4: New file.
453 * gnulib/import/m4/mode_t.m4: New file.
454 * gnulib/import/m4/msvc-inval.m4: New file.
455 * gnulib/import/m4/msvc-nothrow.m4: New file.
456 * gnulib/import/m4/open.m4: New file.
457 * gnulib/import/m4/openat.m4: New file.
458 * gnulib/import/m4/opendir.m4: New file.
459 * gnulib/import/m4/readdir.m4: New file.
460 * gnulib/import/m4/realloc.m4: New file.
461 * gnulib/import/m4/rewinddir.m4: New file.
462 * gnulib/import/m4/save-cwd.m4: New file.
463 * gnulib/import/m4/strdup.m4: New file.
464 * gnulib/import/m4/strerror.m4: New file.
465 * gnulib/import/m4/unistd-safer.m4: New file.
466 * gnulib/import/mempcpy.c: New file.
467 * gnulib/import/memrchr.c: New file.
468 * gnulib/import/msvc-inval.c: New file.
469 * gnulib/import/msvc-inval.h: New file.
470 * gnulib/import/msvc-nothrow.c: New file.
471 * gnulib/import/msvc-nothrow.h: New file.
472 * gnulib/import/open.c: New file.
473 * gnulib/import/openat-die.c: New file.
474 * gnulib/import/openat-priv.h: New file.
475 * gnulib/import/openat-proc.c: New file.
476 * gnulib/import/openat.c: New file.
477 * gnulib/import/openat.h: New file.
478 * gnulib/import/opendir.c: New file.
479 * gnulib/import/pipe-safer.c: New file.
480 * gnulib/import/readdir.c: New file.
481 * gnulib/import/realloc.c: New file.
482 * gnulib/import/rewinddir.c: New file.
483 * gnulib/import/save-cwd.c: New file.
484 * gnulib/import/save-cwd.h: New file.
485 * gnulib/import/strdup.c: New file.
486 * gnulib/import/strerror-override.c: New file.
487 * gnulib/import/strerror-override.h: New file.
488 * gnulib/import/strerror.c: New file.
489 * gnulib/import/unistd--.h: New file.
490 * gnulib/import/unistd-safer.h: New file.
491 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
492 "getcwd" and "glob".
493 * ser-tcp.c: Undefine "close" before redefining it.
494
432ae719
SM
4952017-09-21 Simon Marchi <simon.marchi@ericsson.com>
496
497 * guile/scm-value.c (gdbscm_value_address): Initialize address,
498 get rid of res_val.
499
4fa7574e
RO
5002017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
501
502 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
503 <sol2,sparc>: Likewise.
504 <sol2-64,i386>: Likewise.
505
506 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
507 -Wdeprecated-declarations on *-*-solaris*.
508 * configure: Regenerate.
509
510 * procfs.c: Include "nat/inferior.h".
511 (procfs_info_proc): Fix typo.
512
f6327dcb
KB
5132017-09-21 Kevin Buettner <kevinb@redhat.com>
514
515 * remote.c (vector): Include.
516 (struct private_thread_info): Add field, thread_handle.
517 (free_private_thread_info): Deallocate storage associated with
518 thread handle.
519 (get_private_info_thread): Initialize `thread_handle' field.
520 (struct thread_item): Add field, thread_handle.
521 (clear_threads_listing_context): Deallocate storage associated
522 with thread handle.
523 (start_thread): Add support for "handle" attribute.
524 (thread_attributes): Add "handle".
525 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
526 field.
527 (remote_update_thread_list): Update thread_handle.
528 (remote_thread_handle_to_thread_info): New function.
529 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
530
fbbe5337
KB
5312017-09-21 Kevin Buettner <kevinb@redhat.com>
532
533 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
534 function.
535 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
536 * python/python-internal.h (thread_object_type): Declare.
537
e04ee09e
KB
5382017-09-21 Kevin Buettner <kevinb@redhat.com>
539
540 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
541 (target_thread_handle_to_thread_info): Declare.
542 * target.c (target_thread_handle_to_thread_info): New function.
543 * target-delegates.c: Regenerate.
544 * gdbthread.h (find_thread_by_handle): Declare.
545 * thread.c (find_thread_by_handle): New function.
546 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
547 function.
548 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
549
1e5b66ed
SM
5502017-09-21 Simon Marchi <simon.marchi@ericsson.com>
551
552 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
553
ebe48ba0
SM
5542017-09-21 Simon Marchi <simon.marchi@ericsson.com>
555
556 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
557
0a0bf5dc
YQ
5582017-09-21 Yao Qi <yao.qi@linaro.org>
559
560 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
561 to gdb_target_obs.
562
d1b0a7bf
TT
5632017-09-20 Tom Tromey <tom@tromey.com>
564
565 * breakpoint.c (struct counted_command_line): Remove.
566 (breakpoint_commands): Update.
567 (alloc_counted_command_line, incref_counted_command_line)
568 (decref_counted_command_line, do_cleanup_counted_command_line)
569 (make_cleanup_decref_counted_command_line): Remove.
570 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
571 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
572 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
573 (save_breakpoints): Update.
574 * breakpoint.h (counted_command_line): Now a typedef to
575 shared_ptr.
576 (struct breakpoint) <commands>: Now a counted_command_line.
577 (struct bpstats) <command>: Likewise.
578
48649e1b
TT
5792017-09-20 Tom Tromey <tom@tromey.com>
580
581 * breakpoint.c (struct commands_info, do_map_commands_command):
582 Remove.
583 (commands_command_1): Update.
584 (iterate_over_related_breakpoints): Take a function_view.
585 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
586 (delete_command): Update.
587 (map_breakpoint_numbers): Take a function_view.
588 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
589 (disable_command): Update.
590 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
591 (enable_command): Update.
592 (struct disp_data, do_enable_breakpoint_disp)
593 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
594 (do_map_enable_delete_breakpoint): Remove.
595 (enable_once_command, enable_count_command, enable_delete_command)
596 (delete_trace_variable_command): Update.
597
04afa70c
TT
5982017-09-20 Tom Tromey <tom@tromey.com>
599
600 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
601 (bpstat_clear): Use delete.
602 (bpstats): New constructors.
603 (bpstat_copy, bpstat_stop_status): Use new.
604 (dprintf_after_condition_true): Update.
605 * breakpoint.h (bpstats::bpstats): Add constructors.
606 (bpstats::~bpstats): Add destructor.
607
c83833f4
PA
6082017-09-20 Pedro Alves <palves@redhat.com>
609
610 * eval.c (make_params): Delete, refactored as ...
611 (class fake_method): ... this new type's ctor.
612 (fake_method::~fake_method): New.
613 (evaluate_subexp_standard): Use 'fake_method'.
614
223ffa71
TT
6152017-09-20 Tom Tromey <tom@tromey.com>
616
617 * windows-nat.c (get_windows_debug_event, windows_wait)
618 (do_initial_windows_stuff, windows_attach): Update.
619 * utils.c (vwarning, internal_vproblem): Update.
620 (ui_unregister_input_event_handler_cleanup)
621 (prepare_to_handle_input): Remove.
622 (class scoped_input_handler): New.
623 (defaulted_query, prompt_for_continue): Update.
624 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
625 Update.
626 * top.c (undo_terminal_modifications_before_exit): Update.
627 * target/target.h (target_terminal_init, target_terminal_inferior)
628 (target_terminal_ours): Don't declare.
629 (class target_terminal): New.
630 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
631 (target_terminal_ours_for_output)
632 (make_cleanup_restore_target_terminal): Don't declare.
633 (target_terminal_info): Remove.
634 * target.c (enum terminal_state, terminal_state): Remove.
635 (target_terminal::terminal_state): Define.
636 (target_terminal::init): Rename from target_terminal_init.
637 (target_terminal::inferior): Rename from
638 target_terminal_inferior.
639 (target_terminal::ours): Rename from target_terminal_ours.
640 (target_terminal::ours_for_output): Rename from
641 target_terminal_ours_for_output.
642 (target_terminal::info): New method.
643 (cleanup_restore_target_terminal)
644 (make_cleanup_restore_target_terminal): Remove.
645 * solib.c (handle_solib_event): Update.
646 * remote.c (remote_serial_quit_handler): Update.
647 (remote_terminal_inferior, remote_wait_as): Update.
648 * record-full.c (record_full_wait_1): Update.
649 * nto-procfs.c (procfs_create_inferior): Update.
650 * nat/fork-inferior.c (startup_inferior): Update.
651 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
652 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
653 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
654 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
655 (mi_breakpoint_created, mi_breakpoint_deleted)
656 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
657 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
658 (mi_user_selected_context_changed, report_initial_inferior):
659 Update.
660 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
661 (linux_nat_terminal_inferior): Update.
662 * infrun.c (follow_fork_inferior)
663 (handle_vfork_child_exec_or_exit, do_target_resume)
664 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
665 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
666 Update.
667 * inflow.c (child_terminal_init, info_terminal_command): Update.
668 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
669 (attach_command): Update.
670 * infcall.c (call_thread_fsm_should_stop): Update.
671 * gnu-nat.c (gnu_attach): Update.
672 * extension.c (struct active_ext_lang_state)
673 (restore_active_ext_lang): Update.
674 * exceptions.c (print_flush): Update.
675 * event-top.c (async_enable_stdin, default_quit_handler): Update.
676 (struct quit_handler_cleanup_data, restore_quit_handler)
677 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
678 Remove.
679 * cp-support.c (gdb_demangle): Update.
680 * breakpoint.c (update_inserted_breakpoint_locations)
681 (insert_breakpoint_locations, handle_jit_event)
682 (disable_breakpoints_in_unloaded_shlib): Update.
683 * annotate.c (annotate_breakpoints_invalid)
684 (annotate_frames_invalid): Update.
685
013af3fc
TT
6862017-09-20 Tom Tromey <tom@tromey.com>
687
688 * main.c (catch_command_errors): Rename from
689 catch_command_errors_const.
690 (captured_main_1): Update.
691
06871ae8
PA
6922017-09-20 Pedro Alves <palves@redhat.com>
693
694 * cli/cli-cmds.c (list_command): Use print_sal_location.
695 (print_sal_location): New function.
696 (ambiguous_line_spec): Use print_sal_location.
697 * linespec.c (symbol_to_sal): Record the symbol in the sal.
698 * symtab.c (find_function_start_sal): Likewise.
699 * symtab.h (symtab_and_line::symbol): New field.
700
e5f25bc5
PA
7012017-09-20 Pedro Alves <palves@redhat.com>
702
703 * linespec.c (minsym_found): Handle non-text minsyms.
704 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
705
1b7fa39e
WT
7062017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
707
708 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
709 backslash.
710
37dd0825
WT
7112017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
712
713 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
714 vmovups instead vmovaps.
715 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
716
4e5a4f58
JB
7172017-09-19 John Baldwin <jhb@FreeBSD.org>
718
719 * NEWS (Changes since GDB 8.0): Add starti.
720 * infcmd.c (enum run_break): New.
721 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
722 case.
723 (run_command): Use enum run_how.
724 (start_command): Likewise.
725 (starti_command): New function.
726 (RUN_ARGS_HELP): New macro.
727 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
728 commands. Add starti command.
729
aa70c9f1
YQ
7302017-09-19 Yao Qi <yao.qi@linaro.org>
731
732 * Makefile.in (monitor.o): Remove the rule.
733
d6541620
YQ
7342017-09-19 Yao Qi <yao.qi@linaro.org>
735
736 * annotate.h (struct annotate_arg_emitter): Use
737 DISABLE_COPY_AND_ASSIGN.
738 * common/refcounted-object.h (refcounted_object): Likewise.
739 * completer.h (struct completion_result): Likewise.
740 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
741 * filename-seen-cache.h (filename_seen_cache): Likewise.
742 * gdbcore.h (thread_section_name): Likewise.
743 * gdb_regex.h (compiled_regex): Likewise.
744 * gdbthread.h (scoped_restore_current_thread): Likewise.
745 * inferior.h (scoped_restore_current_inferior): Likewise.
746 * jit.c (jit_reader): Likewise.
747 * linespec.h (struct linespec_result): Likewise.
748 * mi/mi-parse.h (struct mi_parse): Likewise.
749 * nat/fork-inferior.c (execv_argv): Likewise.
750 * progspace.h (scoped_restore_current_program_space): Likewise.
751 * python/python-internal.h (class gdbpy_enter): Likewise.
752 * regcache.h (regcache): Likewise.
753 * target-descriptions.c (struct tdesc_reg): Likewise.
754 (struct tdesc_type): Likewise.
755 (struct tdesc_feature): Likewise.
756 * ui-out.h (ui_out_emit_type): Likewise.
757
0615127c
SM
7582017-09-18 Simon Marchi <simon.marchi@ericsson.com>
759
760 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
761 label abort_expression.
762
5e187554
SM
7632017-09-16 Simon Marchi <simon.marchi@ericsson.com>
764
765 * common/buffer.c (buffer_xml_printf): Adjust.
766 * common/xml-utils.c (xml_escape_text): Change return type to
767 std::string, update code accordingly.
768 * common/xml-utils.h (xml_escape_text): Change return type to
769 std::string.
770 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
771 * windows-tdep.c (windows_xfer_shared_library): Adjust.
772 * unittests/xml-utils-selftests.c (test_xml_escape_text):
773 Adjust.
774
c3d7b541
SM
7752017-09-16 Simon Marchi <simon.marchi@ericsson.com>
776
777 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
778 (SUBDIR_UNITTESTS_OBS): Add new object file.
779 * unittests/xml-utils-selftests.c: New file.
780
1526853e
SM
7812017-09-16 Simon Marchi <simon.marchi@ericsson.com>
782
783 * common/selftest.h (selftest): New struct/interface.
784 (register_test): Add name parameter, add new overload.
785 (run_tests): Add filter parameter.
786 (for_each_selftest_ftype): New typedef.
787 (for_each_selftest): New declaration.
788 * common/selftest.c (tests): Change type to
789 map<string, unique_ptr<selftest>>.
790 (simple_selftest): New struct.
791 (register_test): New function.
792 (register_test): Add name parameter and use it.
793 (run_tests): Add filter parameter and use it. Add prints.
794 Adjust to vector -> map change.
795 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
796 registering selftests.
797 * arm-tdep.c (_initialize_arm_tdep): Likewise.
798 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
799 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
800 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
801 * findvar.c (_initialize_findvar): Likewise.
802 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
803 * maint.c (maintenance_selftest): Update call to run_tests.
804 (maintenance_info_selftests): New function.
805 (_initialize_maint_cmds): Register "maintenance info selftests"
806 command. Update "maintenance selftest" doc.
807 * regcache.c (_initialize_regcache): Add names when registering
808 selftests.
809 * rust-exp.y (_initialize_rust_exp): Likewise.
810 * selftest-arch.c (gdbarch_selftest): New struct.
811 (gdbarch_tests): Remove.
812 (register_test_foreach_arch): Add name parameter. Call
813 register_test.
814 (tests_with_arch): Remove, move most content to
815 gdbarch_selftest::operator().
816 (_initialize_selftests_foreach_arch): Remove.
817 * selftest-arch.h (register_test_foreach_arch): Add name
818 parameter.
819 (run_tests_with_arch): New declaration.
820 * utils-selftests.c (_initialize_utils_selftests): Add names
821 when registering selftests.
822 * utils.c (_initialize_utils): Likewise.
823 * unittests/array-view-selftests.c
824 (_initialize_array_view_selftests): Likewise.
825 * unittests/environ-selftests.c (_initialize_environ_selftests):
826 Likewise.
827 * unittests/function-view-selftests.c
828 (_initialize_function_view_selftests): Likewise.
829 * unittests/offset-type-selftests.c
830 (_initialize_offset_type_selftests): Likewise.
831 * unittests/optional-selftests.c
832 (_initialize_optional_selftests): Likewise.
833 * unittests/scoped_restore-selftests.c
834 (_initialize_scoped_restore_selftests): Likewise.
835 * NEWS: Document "maintenance selftest" and "maint info
836 selftests".
837
5846367a
SM
8382017-09-16 Simon Marchi <simon.marchi@ericsson.com>
839
840 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
841 scoped_restore.
842
bd77e8ff
SM
8432017-09-16 Simon Marchi <simon.marchi@ericsson.com>
844
845 * mi/mi-main.c (mi_load_progress): Make uiout variable
846 a unique_ptr.
847
26a67918
PA
8482017-09-15 Pedro Alves <palves@redhat.com>
849
850 * compile/compile-c-types.c (convert_enum, convert_int)
851 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
852
3f8a7804
SM
8532017-09-15 Simon Marchi <simon.marchi@ericsson.com>
854
855 * dwarf2read.c (copy_string): Remove.
856 (parse_macro_definition): Replace copy_string with savestring.
857
8d200706
YQ
8582017-09-15 Yao Qi <yao.qi@linaro.org>
859
860 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
861 gdb_target_obs.
862 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
863 Likewise.
864 (i[34567]86-*-linux*): Likewise.
865
d185219d
SM
8662017-09-14 Simon Marchi <simon.marchi@ericsson.com>
867
868 * dwarf2expr.h (dwarf_stack_value): Add constructor.
869 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
870 <stack>: Change type to std::vector.
871 <stack_len, stack_allocated>: Remove.
872 <grow_stack>: Remove.
873 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
874 (dwarf_expr_context::~dwarf_expr_context): Remove.
875 (dwarf_expr_context::grow_stack): Remove.
876 (dwarf_expr_context::push): Adjust.
877 (dwarf_expr_context::pop): Adjust.
878 (dwarf_expr_context::fetch): Adjust.
879 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
880 (dwarf_expr_context::stack_empty_p): Adjust.
881 (dwarf_expr_context::execute_stack_op): Adjust.
882
eccd80d6
SM
8832017-09-14 Simon Marchi <simon.marchi@ericsson.com>
884
885 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
886 return type to bool.
887 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
888
69009882
SM
8892017-09-14 Simon Marchi <simon.marchi@ericsson.com>
890
891 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
892 Change type to bool.
893 (dwarf_stack_value) <in_stack_memory>: Likewise.
894 (dwarf_expr_context) <push_address>: Change parameter type to
895 bool.
896 <fetch_in_stack_memory>: Change return type to bool.
897 <push>: Change parameter type to bool.
898 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
899 to bool.
900 (dwarf_expr_context::push_address): Likewise.
901 (dwarf_expr_context::fetch_in_stack_memory): Change return type
902 to bool.
903 (dwarf_expr_context::execute_stack_op): Adjust.
904 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
905
1e467161
SM
9062017-09-14 Simon Marchi <simon.marchi@ericsson.com>
907
908 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
909 (struct dwarf_expr_context) <n_pieces>: Remove.
910 <pieces>: Change type to std::vector.
911 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
912 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
913 pieces.
914 (dwarf_expr_context::add_piece): Adjust.
915 * dwarf2loc.c (struct piece_closure): Initialize fields.
916 <n_pieces>: Remove.
917 <pieces>: Change type to std::vector.
918 (allocate_piece_closure): Adjust, change parameter to
919 std::vector rvalue and std::move it to piece_closure.
920 (rw_pieced_value): Adjust.
921 (check_pieced_synthetic_pointer): Adjust.
922 (indirect_synthetic_pointer): Adjust.
923 (coerce_pieced_ref): Adjust.
924 (free_pieced_value_closure): Adjust. Use delete to free
925 piece_closure.
926 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
927 to allocate_piece_closure.
928 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
929
0782db84
SM
9302017-09-12 Simon Marchi <simon.marchi@ericsson.com>
931
932 * probe.h (probe_ops_cp): Remove typedef.
933 (DEF_VEC_P (probe_ops_cp)): Remove.
934 (all_probe_ops): Change type to std::vector.
935 * probe.c (info_probes_for_ops): Adjust to vector change.
936 (probe_linespec_to_ops): Likewise.
937 (all_probe_ops): Change type to std::vector.
938 (_initialize_probe): Adjust to vector change.
939 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
940 * elfread.c (elf_get_probes): Likewise.
941 * stap-probe.c (_initialize_stap_probe): Likewise.
942
1eac6bea
SM
9432017-09-12 Simon Marchi <simon.marchi@ericsson.com>
944
945 * probe.h (struct bound_probe): Define constructors.
946 * probe.c (bound_probe_s): Remove typedef.
947 (DEF_VEC_O (bound_probe_s)): Remove VEC.
948 (collect_probes): Change return type to std::vector, remove
949 cleanup.
950 (compare_probes): Return bool, change parameter type. Change
951 semantic to "less than".
952 (gen_ui_out_table_header_info): Change parameter to std::vector
953 and update.
954 (exists_probe_with_pops): Likewise.
955 (info_probes_for_ops): Update to std::vector change.
956 (enable_probes_command): Likewise.
957 (disable_probes_command): Likewise.
958
aaa63a31
SM
9592017-09-12 Simon Marchi <simon.marchi@ericsson.com>
960
961 * probe.h (struct probe_ops) <get_probes>: Change parameter from
962 vec to std::vector.
963 * probe.c (parse_probes_in_pspace): Update.
964 (find_probes_in_objfile): Update.
965 (find_probe_by_pc): Update.
966 (collect_probes): Update.
967 (probe_any_get_probes): Update.
968 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
969 return type to reference to std::vector.
970 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
971 std::vector and update.
972 (dtrace_process_dof): Likewise.
973 (dtrace_get_probes): Likewise.
974 * elfread.c (elf_get_probes): Change return type to std::vector,
975 store an std::vector in bfd_data.
976 (probe_key_free): Update to std::vector.
977 * stap-probe.c (handle_stap_probe): Change parameter to
978 std::vector and update.
979 (stap_get_probes): Likewise.
980 * symfile-debug.c (debug_sym_get_probes): Change return type to
981 std::vector and update.
982
cb85b21b
TT
9832017-09-11 Tom Tromey <tom@tromey.com>
984
985 * breakpoint.c (program_breakpoint_here_p): Update.
986 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
987 from make_show_memory_breakpoints_cleanup. Return a
988 scoped_restore_tmpl<int>.
989 (restore_show_memory_breakpoints): Remove.
990 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
991 * mem-break.c (memory_validate_breakpoint): Update.
992 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
993 (ia64_memory_remove_breakpoint): Update.
994 (ia64_breakpoint_from_pc): Update.
995 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
996 from make_show_memory_breakpoints_cleanup.
997
8fbc99ef
TT
9982017-09-11 Tom Tromey <tom@tromey.com>
999
1000 * d-namespace.c (d_lookup_symbol): Use std::string.
1001 (find_symbol_in_baseclass): Likewise.
1002
50feb4bd
TT
10032017-09-11 Tom Tromey <tom@tromey.com>
1004
1005 * ctf.c (ctf_start): Use std::string.
1006
c6dc63a1
TT
10072017-09-11 Tom Tromey <tom@tromey.com>
1008
1009 * ada-lang.c (is_known_support_routine): Update.
1010 (ada_unhandled_exception_name_addr_from_raise): Update.
1011 * guile/scm-frame.c (gdbscm_frame_name): Update.
1012 * python/py-frame.c (frapy_name): Update.
1013 (frapy_function): Update.
1014 * stack.h (find_frame_funname): Update.
1015 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1016 (print_frame): Update.
1017
d6b9b80f
TT
10182017-09-11 Tom Tromey <tom@tromey.com>
1019
1020 * findcmd.c (put_bits): Take a gdb::byte_vector.
1021 (parse_find_args): Return gdb::byte_vector. "args" now const.
1022 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1023 cleanups.
1024 (find_command): Update.
1025
a9921622
TT
10262017-09-11 Tom Tromey <tom@tromey.com>
1027
1028 * cli/cli-script.c (class scoped_restore_hook_in): New.
1029 (clear_hook_in_cleanup): Remove.
1030 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1031 scoped_restore_hook_in.
1032
be0d7abb
TT
10332017-09-11 Tom Tromey <tom@tromey.com>
1034
1035 * cli/cli-script.c (restore_interp): Remove.
1036 (read_command_lines): Use scoped_restore_interp.
1037 * interps.c (scoped_restore_interp::set_temp): Rename from
1038 interp_set_temp.
1039 * interps.h (class scoped_restore_interp): New.
1040 (interp_set_temp): Remove.
1041
00f675ff
TT
10422017-09-11 Tom Tromey <tom@tromey.com>
1043
1044 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1045 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1046 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1047 scoped_restore.
1048 (mi_cmd_break_insert_1): Update.
1049 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1050 scoped_restore.
1051
cb791d59
TT
10522017-09-11 Tom Tromey <tom@tromey.com>
1053
1054 * demangle.c (demangle_command): Update.
1055 * breakpoint.c (disable_command): Update.
1056 (enable_command): Update.
1057 (find_location_by_number): Make "number" const. Use
1058 get_number_trailer.
1059 * cli/cli-utils.c (extract_arg): Return std::string.
1060 * probe.c (parse_probe_linespec): Update. Change types.
1061 (collect_probes): Take string arguments.
1062 (parse_probe_linespec): Likewise.
1063 (info_probes_for_ops): Update.
1064 (enable_probes_command): Update.
1065 (disable_probes_command): Update.
1066 * break-catch-sig.c (catch_signal_split_args): Update.
1067 * mi/mi-parse.c (mi_parse): Update.
1068
2039bd9f
TT
10692017-09-11 Tom Tromey <tom@tromey.com>
1070
1071 * language.h (language_enum): Make argument const.
1072 * language.c (language_enum): Make argument const.
1073
f1735a53
TT
10742017-09-11 Tom Tromey <tom@tromey.com>
1075
1076 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1077 as function.
1078 (skip_to_space): Rename from skip_to_space_const.
1079 * common/common-utils.c (skip_to_space): New function.
1080 (skip_to_space): Rename from skip_to_space_const.
1081 * cli/cli-utils.h (get_number): Rename from get_number_const.
1082 (extract_arg): Rename from extract_arg_const.
1083 * cli/cli-utils.c (get_number): Rename from get_number_const.
1084 (extract_arg): Rename from extract_arg_const.
1085 (number_or_range_parser::get_number): Use ::get_number.
1086 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1087 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1088 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1089 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1090 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1091 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1092 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1093 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1094
7d221d74
TT
10952017-09-11 Tom Tromey <tom@tromey.com>
1096
1097 * python/python.c (do_start_initialization): Use
1098 py-event-types.def to initialize types.
1099 Define all object type structures.
1100 * python/python-internal.h: Don't declare event initialization
1101 functions.
1102 * python/py-threadevent.c (thread_event_object_type): Don't
1103 define.
1104 * python/py-stopevent.c (stop_event_object_type): Don't define.
1105 * python/py-signalevent.c (signal_event_object_type): Don't
1106 declare or define.
1107 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1108 (clear_objfiles_event_object_type): Don't declare or define.
1109 * python/py-infevents.c (inferior_call_pre_event_object_type)
1110 (inferior_call_post_event_object_type)
1111 (register_changed_event_object_type)
1112 (memory_changed_event_object_type): Don't declare or define.
1113 * python/py-inferior.c (new_thread_event_object_type)
1114 (new_inferior_event_object_type)
1115 (inferior_deleted_event_object_type): Don't declare or define.
1116 * python/py-exitedevent.c (exited_event_object_type): Don't
1117 declare or define.
1118 * python/py-evts.c (gdbpy_initialize_py_events): Use
1119 py-all-events.def.
1120 * python/py-events.h (thread_event_object_type): Don't declare.
1121 (events_object): Use py-all-events.def.
1122 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1123 py-event-types.def.
1124 * python/py-event-types.def: New file.
1125 * python/py-continueevent.c (create_continue_event_object): Don't
1126 declare or define.
1127 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1128 declare or define.
1129 * python/py-all-events.def: New file.
1130
35c61a1d
TT
11312017-09-11 Tom Tromey <tom@tromey.com>
1132
1133 * python/py-threadevent.c (create_thread_event_object): Return
1134 gdbpy_ref.
1135 * python/py-stopevent.h (create_stop_event_object)
1136 (create_breakpoint_event_object, create_signal_event_object):
1137 Update.
1138 * python/py-stopevent.c (create_stop_event_object): Return
1139 gdbpy_ref.
1140 (emit_stop_event): Update.
1141 * python/py-signalevent.c (create_signal_event_object): Return
1142 gdbpy_ref.
1143 * python/py-infevents.c (create_inferior_call_event_object):
1144 Update.
1145 * python/py-event.h (create_event_object)
1146 (create_thread_event_object): Update.
1147 * python/py-event.c (create_event_object): Return gdbpy_ref.
1148 * python/py-continueevent.c: Return gdbpy_ref.
1149 * python/py-bpevent.c (create_breakpoint_event_object): Return
1150 gdbpy_ref.
1151
7c96f8c1
TT
11522017-09-11 Tom Tromey <tom@tromey.com>
1153
1154 PR python/15622:
1155 * NEWS: Add entry.
1156 * python/python.c (do_start_initialization): Initialize new event
1157 types.
1158 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1159 (gdbpy_initialize_inferior_deleted_event)
1160 (gdbpy_initialize_new_thread_event): Declare.
1161 * python/py-threadevent.c (create_thread_event_object): Add option
1162 "thread" parameter.
1163 * python/py-inferior.c (new_thread_event_object_type)
1164 (new_inferior_event_object_type)
1165 (inferior_deleted_event_object_type): Declare.
1166 (python_new_inferior, python_inferior_deleted): New functions.
1167 (add_thread_object): Emit new_thread event.
1168 (gdbpy_initialize_inferior): Attach new functions to corresponding
1169 observers.
1170 (new_thread, new_inferior, inferior_deleted): Define new event
1171 types.
1172 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1173 registries.
1174 * python/py-events.h (events_object) <new_inferior,
1175 inferior_deleted, new_thread>: New fields.
1176 * python/py-event.h (create_thread_event_breakpoint): Add optional
1177 "thread" parameter.
1178
72542b8e
AB
11792017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1180
1181 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1182 check current_ui instead.
1183 (internal_vproblem): Likewise.
1184
0d64823e
SM
11852017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1186
1187 * thread.c (print_thread_info_1): Remove unnecessary calls to
1188 uiout->is_mi_like_p.
1189
eb1e02fd
TT
11902017-09-09 Tom Tromey <tom@tromey.com>
1191
1192 * namespace.h (add_using_directive): Update.
1193 * namespace.c (add_using_directive): Change type of excludes to
1194 std::vector.
1195 * dwarf2read.c (read_import_statement): Use std::vector.
1196 (read_namespace): Update.
1197 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1198
0fc21fd8
TT
11992017-09-09 Tom Tromey <tom@tromey.com>
1200
1201 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1202
49663d05
TT
12032017-09-09 Tom Tromey <tom@tromey.com>
1204
1205 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1206
0b868b60
TT
12072017-09-09 Tom Tromey <tom@tromey.com>
1208
1209 * stack.c (func_command): Use gdb::def_vector.
1210
c0470d48
TT
12112017-09-09 Tom Tromey <tom@tromey.com>
1212
1213 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1214 ui_out_emit_list, ui_out_emit_tuple.
1215 (mi_cmd_var_update): Likewise.
1216
ca5909c7
TT
12172017-09-09 Tom Tromey <tom@tromey.com>
1218
1219 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1220 ui_out_redirect_pop.
1221 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1222 ui_out_redirect_pop.
1223 * utils.c (do_ui_out_redirect_pop)
1224 (make_cleanup_ui_out_redirect_pop): Remove.
1225 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1226 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1227 * ui-out.h (ui_out_redirect_pop): New class.
1228
e6a2252a
TT
12292017-09-09 Tom Tromey <tom@tromey.com>
1230
1231 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1232 (list_available_thread_groups, mi_cmd_list_thread_groups)
1233 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1234 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1235 Likewise.
1236
393702cd
TT
12372017-09-09 Tom Tromey <tom@tromey.com>
1238
1239 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1240 ui_out_emit_tuple.
1241
76f9c9cf
TT
12422017-09-09 Tom Tromey <tom@tromey.com>
1243
1244 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1245 * stack.c (print_frame): Use ui_out_emit_tuple.
1246 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1247 (info_spu_mailbox_command, info_spu_dma_command)
1248 (info_spu_proxydma_command): Likewise.
1249 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1250 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1251 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1252 ui_out_emit_tuple.
1253 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1254
dc9fe180
TT
12552017-09-09 Tom Tromey <tom@tromey.com>
1256
1257 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1258 (class ui_out_emit_table): Update comment.
1259 * ui-out.c (do_cleanup_table_end)
1260 (make_cleanup_ui_out_table_begin_end): Remove.
1261 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1262 (info_spu_dma_cmdlist): Likewise.
1263 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1264 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1265 ui_out_emit_table.
1266
f8cc3da6
TT
12672017-09-09 Tom Tromey <tom@tromey.com>
1268
1269 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1270 ui_out_emit_list, gdb::optional.
1271
481695ed
JB
12722017-09-09 John Baldwin <jhb@FreeBSD.org>
1273
1274 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1275 prototype.
1276 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1277 prototype.
1278 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1279 prototype.
1280 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1281 * ada-exp.y: Remove _initialize_ada_exp prototype.
1282 * ada-lang.c: Remove _initialize_ada_language prototype.
1283 * ada-tasks.c: Remove _initialize_tasks prototype.
1284 * addrmap.c: Remove _initialize_addrmap prototype.
1285 * agent.c: Remove _initialize_agent prototype.
1286 * aix-thread.c: Remove _initialize_aix_thread prototype.
1287 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1288 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1289 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1290 prototype.
1291 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1292 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1293 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1294 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1295 prototype.
1296 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1297 prototype.
1298 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1299 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1300 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1301 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1302 prototype.
1303 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1304 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1305 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1306 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1307 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1308 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1309 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1310 prototype.
1311 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1312 prototype.
1313 * annotate.c: Remove _initialize_annotate prototype.
1314 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1315 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1316 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1317 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1318 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1319 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1320 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1321 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1322 prototype.
1323 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1324 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1325 * auto-load.c: Remove _initialize_auto_load prototype.
1326 * auxv.c: Remove _initialize_auxv prototype.
1327 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1328 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1329 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1330 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1331 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1332 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1333 prototype.
1334 * break-catch-throw.c: Remove _initialize_break_catch_throw
1335 prototype.
1336 * breakpoint.c: Remove _initialize_breakpoint prototype.
1337 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1338 * btrace.c: Remove _initialize_btrace prototype.
1339 * charset.c: Remove _initialize_charset prototype.
1340 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1341 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1342 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1343 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1344 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1345 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1346 * coffread.c: Remove _initialize_coffread prototype.
1347 * compile/compile.c: Remove _initialize_compile prototype.
1348 * complaints.c: Remove _initialize_complaints prototype.
1349 * completer.c: Remove _initialize_completer prototype.
1350 * copying.awk: Remove _initialize_copying prototype.
1351 * copying.c: Regenerate.
1352 * core-regset.c: Remove _initialize_core_regset prototype.
1353 * corefile.c: Remove _initialize_core prototype.
1354 * corelow.c: Remove _initialize_corelow prototype.
1355 * cp-abi.c: Remove _initialize_cp_abi prototype.
1356 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1357 * cp-support.c: Remove _initialize_cp_support prototype.
1358 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1359 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1360 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1361 * ctf.c: Remove _initialize_ctf prototype.
1362 * d-lang.c: Remove _initialize_d_language prototype.
1363 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1364 prototype.
1365 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1366 * dbxread.c: Remove _initialize_dbxread prototype.
1367 * dcache.c: Remove _initialize_dcache prototype.
1368 * demangle.c: Remove _initialize_demangler prototype.
1369 * disasm-selftests.c: Remove _initialize_disasm_selftests
1370 prototype.
1371 * disasm.c: Remove _initialize_disasm prototype.
1372 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1373 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1374 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1375 prototype.
1376 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1377 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1378 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1379 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1380 * elfread.c: Remove _initialize_elfread prototype.
1381 * exec.c: Remove _initialize_exec prototype.
1382 * extension.c: Remove _initialize_extension prototype.
1383 * f-lang.c: Remove _initialize_f_language prototype.
1384 * f-valprint.c: Remove _initialize_f_valprint prototype.
1385 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1386 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1387 * filesystem.c: Remove _initialize_filesystem prototype.
1388 * findcmd.c: Remove _initialize_mem_search prototype.
1389 * fork-child.c: Remove _initialize_fork_child prototype.
1390 * frame-base.c: Remove _initialize_frame_base prototype.
1391 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1392 * frame.c: Remove _initialize_frame prototype.
1393 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1394 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1395 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1396 * gcore.c: Remove _initialize_gcore prototype.
1397 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1398 * gdbarch.c: Regenerate.
1399 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1400 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1401 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1402 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1403 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1404 * go-lang.c: Remove _initialize_go_language prototype.
1405 * go32-nat.c: Remove _initialize_go32_nat prototype.
1406 * guile/guile.c: Remove _initialize_guile prototype.
1407 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1408 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1409 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1410 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1411 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1412 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1413 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1414 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1415 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1416 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1417 prototype.
1418 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1419 prototype.
1420 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1421 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
1422 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
1423 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
1424 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
1425 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
1426 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
1427 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
1428 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
1429 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
1430 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
1431 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
1432 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
1433 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1434 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
1435 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
1436 prototype.
1437 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
1438 prototype.
1439 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
1440 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
1441 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
1442 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
1443 * infcall.c: Remove _initialize_infcall prototype.
1444 * infcmd.c: Remove _initialize_infcmd prototype.
1445 * inferior.c: Remove _initialize_inferiors prototype.
1446 * inflow.c: Remove _initialize_inflow prototype.
1447 * infrun.c: Remove _initialize_infrun prototype.
1448 * interps.c: Remove _initialize_interpreter prototype.
1449 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
1450 * jit.c: Remove _initialize_jit prototype.
1451 * language.c: Remove _initialize_language prototype.
1452 * linux-fork.c: Remove _initialize_linux_fork prototype.
1453 * linux-nat.c: Remove _initialize_linux_nat prototype.
1454 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
1455 * linux-thread-db.c: Remove _initialize_thread_db prototype.
1456 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
1457 * m2-lang.c: Remove _initialize_m2_language prototype.
1458 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
1459 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
1460 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
1461 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
1462 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
1463 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1464 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1465 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
1466 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
1467 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
1468 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1469 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1470 * machoread.c: Remove _initialize_machoread prototype.
1471 * macrocmd.c: Remove _initialize_macrocmd prototype.
1472 * macroscope.c: Remove _initialize_macroscope prototype.
1473 * maint.c: Remove _initialize_maint_cmds prototype.
1474 * mdebugread.c: Remove _initialize_mdebugread prototype.
1475 * memattr.c: Remove _initialize_mem prototype.
1476 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
1477 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
1478 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
1479 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
1480 * mi/mi-main.c: Remove _initialize_mi_main prototype.
1481 * microblaze-linux-tdep.c: Remove
1482 _initialize_microblaze_linux_tdep prototype.
1483 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
1484 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
1485 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
1486 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
1487 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
1488 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
1489 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
1490 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
1491 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
1492 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
1493 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
1494 prototype.
1495 * mipsread.c: Remove _initialize_mipsread prototype.
1496 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
1497 prototype.
1498 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
1499 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
1500 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
1501 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
1502 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
1503 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
1504 prototype.
1505 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
1506 * nto-procfs.c: Remove _initialize_procfs prototype.
1507 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
1508 * objc-lang.c: Remove _initialize_objc_language prototype.
1509 * objfiles.c: Remove _initialize_objfiles prototype.
1510 * observer.c: Remove observer_test_first_notification_function,
1511 observer_test_second_notification_function,
1512 observer_test_third_notification_function, and
1513 _initialize_observer prototypes.
1514 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
1515 * osabi.c: Remove _initialize_gdb_osabi prototype.
1516 * osdata.c: Remove _initialize_osdata prototype.
1517 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
1518 * parse.c: Remove _initialize_parse prototype.
1519 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
1520 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
1521 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
1522 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
1523 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
1524 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
1525 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
1526 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
1527 * printcmd.c: Remove _initialize_printcmd prototype.
1528 * probe.c: Remove _initialize_probe prototype.
1529 * proc-api.c: Remove _initialize_proc_api prototype.
1530 * proc-events.c: Remove _initialize_proc_events prototype.
1531 * proc-service.c: Remove _initialize_proc_service prototype.
1532 * procfs.c: Remove _initialize_procfs prototype.
1533 * psymtab.c: Remove _initialize_psymtab prototype.
1534 * python/python.c: Remove _initialize_python prototype.
1535 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
1536 * record-btrace.c: Remove _initialize_record_btrace prototype.
1537 * record-full.c: Remove _initialize_record_full prototype.
1538 * record.c: Remove _initialize_record prototype.
1539 * regcache.c: Remove _initialize_regcache prototype.
1540 * reggroups.c: Remove _initialize_reggroup prototype.
1541 * remote-notif.c: Remove _initialize_notif prototype.
1542 * remote-sim.c: Remove _initialize_remote_sim prototype.
1543 * remote.c: Remove _initialize_remote prototype.
1544 * reverse.c: Remove _initialize_reverse prototype.
1545 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
1546 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
1547 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
1548 prototype.
1549 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
1550 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
1551 * rust-exp.y: Remove _initialize_rust_exp prototype.
1552 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
1553 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
1554 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
1555 * score-tdep.c: Remove _initialize_score_tdep prototype.
1556 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
1557 prototype.
1558 * ser-go32.c: Remove _initialize_ser_dos prototype.
1559 * ser-mingw.c: Remove _initialize_ser_windows prototype.
1560 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
1561 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
1562 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
1563 * serial.c: Remove _initialize_serial prototype.
1564 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
1565 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
1566 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
1567 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
1568 * skip.c: Remove _initialize_step_skip prototype.
1569 * sol-thread.c: Remove _initialize_sol_thread prototype.
1570 * solib-aix.c: Remove _initialize_solib_aix prototype.
1571 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
1572 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
1573 * solib-frv.c: Remove _initialize_frv_solib prototype.
1574 * solib-spu.c: Remove _initialize_spu_solib prototype.
1575 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
1576 * solib-target.c: Remove _initialize_solib_target prototype.
1577 * solib.c: Remove _initialize_solib prototype.
1578 * source.c: Remove _initialize_source prototype.
1579 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
1580 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
1581 prototype.
1582 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
1583 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
1584 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
1585 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
1586 prototype.
1587 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
1588 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
1589 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
1590 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
1591 prototype.
1592 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
1593 prototype.
1594 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
1595 prototype.
1596 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
1597 prototype.
1598 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
1599 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
1600 prototype.
1601 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
1602 prototype.
1603 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
1604 prototype.
1605 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
1606 prototype.
1607 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
1608 prototype.
1609 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
1610 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
1611 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
1612 * stabsread.c: Remove _initialize_stabsread prototype.
1613 * stack.c: Remove _initialize_stack prototype.
1614 * stap-probe.c: Remove _initialize_stap_probe prototype.
1615 * std-regs.c: Remove _initialize_frame_reg prototype.
1616 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
1617 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
1618 * symfile.c: Remove _initialize_symfile prototype.
1619 * symmisc.c: Remove _initialize_symmisc prototype.
1620 * symtab.c: Remove _initialize_symtab prototype.
1621 * target-dcache.c: Remove _initialize_target_dcache prototype.
1622 * target-descriptions.c: Remove _initialize_target_descriptions
1623 prototype.
1624 * thread.c: Remove _initialize_thread prototype.
1625 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
1626 prototype.
1627 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
1628 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
1629 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
1630 prototype.
1631 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
1632 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
1633 * tracefile.c: Remove _initialize_tracefile prototype.
1634 * tracepoint.c: Remove _initialize_tracepoint prototype.
1635 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
1636 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
1637 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
1638 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
1639 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
1640 * tui/tui-win.c: Remove _initialize_tui_win prototype.
1641 * tui/tui.c: Remove _initialize_tui prototype.
1642 * typeprint.c: Remove _initialize_typeprint prototype.
1643 * user-regs.c: Remove _initialize_user_regs prototype.
1644 * utils.c: Remove _initialize_utils prototype.
1645 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
1646 * valarith.c: Remove _initialize_valarith prototype.
1647 * valops.c: Remove _initialize_valops prototype.
1648 * valprint.c: Remove _initialize_valprint prototype.
1649 * value.c: Remove _initialize_values prototype.
1650 * varobj.c: Remove _initialize_varobj prototype.
1651 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
1652 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
1653 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
1654 * windows-nat.c: Remove _initialize_windows_nat,
1655 _initialize_check_for_gdb_ini, and _initialize_loadable
1656 prototypes.
1657 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
1658 * xcoffread.c: Remove _initialize_xcoffread prototype.
1659 * xml-support.c: Remove _initialize_xml_support prototype.
1660 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
1661 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
1662 prototype.
1663 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
1664 prototype.
1665 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
1666
a611b5cb
KS
16672017-09-08 Keith Seitz <keiths@redhat.com>
1668
1669 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
1670 field.
1671
469412dd
CW
16722017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
1673
1674 * f-valprint.c (f_val_print): Remove check for one byte
1675 sized integers. Remove printing of character type.
1676
a5ad232b
FP
16772017-09-08 Frank Penczek <frank.penczek@intel.com>
1678 Christoph Weinmann <christoph.t.weinmann@intel.com>
1679 Bernhard Heckel <bernhard.heckel@intel.com>
1680
1681 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
1682 to maintain proper indentation when printing pointers/refs.
1683
e5014227
JB
16842017-09-07 Joel Brobecker <brobecker@adacore.com>
1685
1686 GDB 8.0.1 released.
1687
63c99141
JB
16882017-09-07 Joel Brobecker <brobecker@adacore.com>
1689
1690 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
1691
69c1e056
TT
16922017-09-05 Tom Tromey <tom@tromey.com>
1693
1694 * parse.c (funcall_chain): Now a std::vector.
1695 (start_arglist, end_arglist): Simplify.
1696 (free_funcalls): Remove.
1697 (parse_exp_in_context_1): Remove cleanup.
1698
fef704bf
TT
16992017-09-05 Tom Tromey <tom@tromey.com>
1700
1701 * go-exp.y (go_parse): Don't create a cleanup.
1702
5613c585
TT
17032017-09-05 Tom Tromey <tom@tromey.com>
1704
1705 * d-exp.y (PrimaryExpression): Use std::string.
1706 (d_parse): Don't create a cleanup.
1707
eae49211
TT
17082017-09-05 Tom Tromey <tom@tromey.com>
1709
1710 * utils.c (do_clear_parser_state): Remove.
1711 (make_cleanup_clear_parser_state): Remove.
1712 * p-exp.y (pascal_parse): Use scoped_restore.
1713 * m2-exp.y (m2_parse): Use scoped_restore.
1714 * f-exp.y (f_parse): Use scoped_restore.
1715 * d-exp.y (d_parse): Use scoped_restore.
1716 * c-exp.y (c_parse): Use scoped_restore.
1717 * ada-exp.y (ada_parse): Use scoped_restore.
1718 * utils.h (make_cleanup_clear_parser_state): Remove.
1719
73b9be8b
KS
17202017-09-06 Keith Seitz <keiths@redhat.com>
1721
1722 * dwarf2read.c (dw2_linkage_name_attr): New function.
1723 (dw2_linkage_name): New function.
1724 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
1725 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
1726 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
1727
a102602b
KR
17282017-09-06 Kamil Rytarowski <n54@gmx.com>
1729
1730 * config/djgpp/djconfig.sh: Correct shell portability issue.
1731
28ad437d
KR
17322017-09-06 Kamil Rytarowski <n54@gmx.com>
1733
1734 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
1735
351787dd
JB
17362017-09-06 John Baldwin <jhb@FreeBSD.org>
1737
1738 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
1739 * NEWS: Mention new FreeBSD/mips native configuration.
1740 * configure.host: Add aarch64*-*-freebsd*.
1741 * configure.nat: Likewise.
1742 * aarch64-fbsd-nat.c: New file.
1743
c0f84956
JB
17442017-09-06 John Baldwin <jhb@FreeBSD.org>
1745
1746 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
1747 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
1748 * NEWS: Mention new FreeBSD/aarch64 target.
1749 * configure.tgt: Add aarch64*-*-freebsd*.
1750 * aarch64-fbsd-tdep.c: New file.
1751 * aarch64-fbsd-tdep.h: New file.
1752
7610297a
KR
17532017-09-06 Kamil Rytarowski <n54@gmx.com>
1754
1755 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
1756
fbd1b771
JK
17572017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
1758
1759 * parse.c (find_minsym_type_and_address): Don't relocate addresses
1760 of TLS symbols.
1761
5ca79eae
PW
17622017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1763
1764 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
1765 call.
1766
bf93d7ba
SM
17672017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1768
1769 * infrun.c (follow_exec): Call add_thread after
1770 target_find_description.
1771
1bb7c059
SM
17722017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1773
1774 * infrun.c (handle_inferior_event_1): When exec'ing, read
1775 stop_pc after follow_exec.
1776
fc809827
SM
17772017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1778
1779 * remote.c (process_g_packet): Update error message.
1780
d2fcdd85
YQ
17812017-09-05 Yao Qi <yao.qi@linaro.org>
1782
1783 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
1784 targets.
1785
e69570ee
PA
17862017-09-05 Pedro Alves <palves@redhat.com>
1787
1788 * eval.c (eval_call, evaluate_funcall): New functions, factored
1789 out from ...
1790 (evaluate_subexp_standard): ... this.
1791
22916b07
YQ
17922017-09-05 Yao Qi <yao.qi@linaro.org>
1793
1794 * amd64-tdep.c (amd64_target_description): Create target
1795 descriptions.
1796 (_initialize_amd64_tdep): Don't call functions
1797 initialize_tdesc_amd64_*. Add self tests.
1798 * arch/amd64.c (amd64_create_target_description): Add parameter
1799 is_linux. Call set_tdesc_osabi if is_linux is true.
1800 * arch/amd64.h (amd64_create_target_description): Update the
1801 declaration.
1802 * arch/i386.c (i386_create_target_description): Add parameter
1803 is_linux. Call set_tdesc_osabi if is_linux is true.
1804 * arch/i386.h (i386_create_target_description): Update
1805 declaration.
1806 * configure.tgt: Add i386.o to gdb_target_obs.
1807 * features/Makefile (XMLTOC): Remove i386/*.xml.
1808 * features/i386/amd64-avx-avx512.c: Remove.
1809 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
1810 * features/i386/amd64-avx-mpx.c: Remove.
1811 * features/i386/amd64-avx.c: Remove.
1812 * features/i386/amd64-mpx.c: Remove.
1813 * features/i386/amd64.c: Remove.
1814 * features/i386/i386-avx-avx512.c: Remove.
1815 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
1816 * features/i386/i386-avx-mpx.c: Remove.
1817 * features/i386/i386-avx.c: Remove.
1818 * features/i386/i386-mmx.c: Remove.
1819 * features/i386/i386-mpx.c: Remove.
1820 * features/i386/i386.c: Remove.
1821 * i386-tdep.c: Don't include features/i386/i386*.c., include
1822 target-descriptions.h and arch/i386.h.
1823 (i386_target_description): Create target descriptions.
1824 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
1825 functions. Do self tests.
1826
0854b7b1
YQ
18272017-09-05 Yao Qi <yao.qi@linaro.org>
1828
1829 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
1830 * features/i386/amd64-avx-avx512-linux.c: Removed.
1831 * features/i386/amd64-avx-linux.c: Removed.
1832 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
1833 * features/i386/amd64-avx-mpx-linux.c: Removed.
1834 * features/i386/amd64-linux.c: Removed.
1835 * features/i386/amd64-mpx-linux.c: Removed.
1836 * features/i386/x32-avx-avx512-linux.c: Removed.
1837 * features/i386/x32-avx-linux.c: Removed.
1838 * features/i386/x32-linux.c: Removed.
1839
b4570e4b
YQ
18402017-09-05 Yao Qi <yao.qi@linaro.org>
1841
1842 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
1843 features/i386/*.c.
1844 (amd64_linux_read_description): Call
1845 amd64_create_target_description.
1846 * arch/amd64.c: New file.
1847 * arch/amd64.h: New file.
1848 * configure.tgt (x86_64-*-linux*): Append amd64.o.
1849 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
1850
6c73f67f
YQ
18512017-09-05 Yao Qi <yao.qi@linaro.org>
1852
1853 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
1854 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
1855 (amd64_linux_read_description): Create target descriptions.
1856 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
1857 functions. Add unit tests.
1858 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
1859 x32-core.xml.
1860 * features/i386/64bit-avx.c: Generated.
1861 * features/i386/64bit-avx512.c: Generated.
1862 * features/i386/64bit-core.c: Generated.
1863 * features/i386/64bit-linux.c: Generated.
1864 * features/i386/64bit-mpx.c: Generated.
1865 * features/i386/64bit-pkeys.c: Generated.
1866 * features/i386/64bit-segments.c: Generated.
1867 * features/i386/64bit-sse.c: Generated.
1868 * features/i386/x32-core.c: Generated.
1869 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
1870 c files for amd64-linux and x32-linux.
1871
9d3d478b
YQ
18722017-09-05 Yao Qi <yao.qi@linaro.org>
1873
1874 * amd64-linux-tdep.c (amd64_linux_read_description): New
1875 function.
1876 (amd64_linux_core_read_description): Call
1877 amd64_linux_read_description.
1878 (amd64_linux_init_abi): Likewise.
1879 (amd64_x32_linux_init_abi): Likewise.
1880 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
1881 * x86-linux-nat.c (x86_linux_read_description): Call
1882 amd64_linux_read_description.
1883
b9f1d50f
YQ
18842017-09-05 Yao Qi <yao.qi@linaro.org>
1885
1886 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
1887 comments.
1888
188c9e6d
YQ
18892017-09-05 Yao Qi <yao.qi@linaro.org>
1890
1891 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
1892 * features/i386/i386-avx-avx512-linux.c: Remove.
1893 * features/i386/i386-avx-linux.c: Remove.
1894 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
1895 * features/i386/i386-avx-mpx-linux.c: Remove.
1896 * features/i386/i386-linux.c: Remove.
1897 * features/i386/i386-mmx-linux.c: Remove.
1898 * features/i386/i386-mpx-linux.c: Remove.
1899
5f035c07
YQ
19002017-09-05 Yao Qi <yao.qi@linaro.org>
1901
1902 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
1903 (SFILES): Add arch/i386.c.
1904 (HFILES_NO_SRCDIR): Add arch/i386.h.
1905 * arch/i386.c: New file.
1906 * arch/i386.h: New file.
1907 * arch/tdesc.h (allocate_target_description): Declare.
1908 (set_tdesc_architecture): Declare.
1909 (set_tdesc_osabi): Declare.
1910 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
1911 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
1912 include arch/i386.h.
1913 (i386_linux_read_description): Remove code and call
1914 i386_create_target_description.
1915 (set_tdesc_architecture): New function.
1916 (set_tdesc_osabi): New function.
1917 * target-descriptions.h (allocate_target_description): Remove.
1918
0abe8a89
YQ
19192017-09-05 Yao Qi <yao.qi@linaro.org>
1920
1921 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
1922 * target-descriptions.c (tdesc_create_feature): Likewise, and
1923 adjust code.
1924 * features/i386/32bit-avx.c: Re-generated.
1925 * features/i386/32bit-avx512.c: Re-generated.
1926 * features/i386/32bit-core.c: Re-generated.
1927 * features/i386/32bit-linux.c: Re-generated.
1928 * features/i386/32bit-mpx.c: Re-generated.
1929 * features/i386/32bit-pkeys.c: Re-generated.
1930 * features/i386/32bit-sse.c: Re-generated.
1931
0a188386
YQ
19322017-09-05 Yao Qi <yao.qi@linaro.org>
1933
1934 * regformats/regdef.h (struct reg): Override operator == and !=.
1935
f49ff000
YQ
19362017-09-05 Yao Qi <yao.qi@linaro.org>
1937
1938 * arch/tdesc.h: New file.
1939 * regformats/regdat.sh: Generate code using tdesc_create_reg.
1940 * target-descriptions.c: Update comments.
1941 * target-descriptions.h: Include "arch/tdesc.h". Remove the
1942 declarations.
1943 * features/i386/32bit-avx.c: Re-generated.
1944 * features/i386/32bit-avx512.c: Re-generated.
1945 * features/i386/32bit-core.c: Re-generated.
1946 * features/i386/32bit-linux.c: Re-generated.
1947 * features/i386/32bit-mpx.c: Re-generated.
1948 * features/i386/32bit-pkeys.c: Re-generated.
1949 * features/i386/32bit-sse.c: Re-generated.
1950
f7000548
YQ
19512017-09-05 Yao Qi <yao.qi@linaro.org>
1952
1953 * regformats/regdat.sh: Update generated code.
1954
c9a5e2a5
YQ
19552017-09-05 Yao Qi <yao.qi@linaro.org>
1956
1957 * regformats/regdat.sh: Adjust code order.
1958
d6b687ac
SM
19592017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1960
1961 * expprint.c (dump_subexp_body_standard): Use constant format
1962 string in fprintf_filtered call.
1963
a379bfd0
JB
19642017-09-04 John Baldwin <jhb@FreeBSD.org>
1965
1966 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
1967 NetBSD/i386.
1968 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
1969
f7efc967
JB
19702017-09-04 John Baldwin <jhb@FreeBSD.org>
1971
1972 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
1973
c49fbc6c
JB
19742017-09-04 John Baldwin <jhb@FreeBSD.org>
1975
1976 * bsd-kvm.o: Define _KMEMUSER.
1977 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
1978 * configure: Regenerate.
1979
26562e73
JB
19802017-09-04 John Baldwin <jhb@FreeBSD.org>
1981
1982 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
1983 * i386-fbsd-nat.c: Likewise.
1984
31cf1487
JB
19852017-09-04 John Baldwin <jhb@FreeBSD.org>
1986
1987 * unittests/array-view-selftests.c: Add include of <array>.
1988
5b9f8a7c
JB
19892017-09-04 John Baldwin <jhb@FreeBSD.org>
1990
1991 * spu-tdep.c (flush_ea_cache): Add missing argument to
1992 call_function_by_hand.
1993
d69cf9b2
PA
19942017-09-04 Pedro Alves <palves@redhat.com>
1995
1996 * NEWS (Safer support for debugging with no debug info): New.
1997
3693fdb3
PA
19982017-09-04 Pedro Alves <palves@redhat.com>
1999
2000 * c-exp.y (function_method, function_method_void): Add current
2001 instance flags to TYPE_INSTANCE.
2002 * dwarf2read.c (check_modifier): New.
2003 (compute_delayed_physnames): Assert that only C++ adds delayed
2004 physnames. Mark fn_fields as const/volatile depending on
2005 physname.
2006 * eval.c (make_params): New type_instance_flags parameter. Use
2007 it as the new type's instance flags.
2008 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2009 flags element and pass it to make_params.
2010 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2011 instance flags element.
2012 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2013 * gdbtypes.h: Include "enum-flags.h".
2014 (type_instance_flags): New enum-flags type.
2015 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2016 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2017 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2018 (follow_type_instance_flags): New function.
2019 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2020 * parser-defs.h (follow_type_instance_flags): Declare.
2021 * valops.c (value_struct_elt_for_reference): const/volatile must
2022 match too.
2023
e68cb8e0
PA
20242017-09-04 Pedro Alves <palves@redhat.com>
2025
2026 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2027 function/method scopes; lookup the nested name as a function local
2028 static variable.
2029
858be34c
PA
20302017-09-04 Pedro Alves <palves@redhat.com>
2031
2032 (%type <voidval>): Add function_method.
2033 * c-exp.y (exp): New production for calls with no arguments.
2034 (function_method, function_method_void_or_typelist): New
2035 productions.
2036 (exp): New production for "method()::static_var".
2037 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2038 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2039 Handle OP_FUNC_STATIC_VAR.
2040 * parse.c (operator_length_standard):
2041 Handle OP_FUNC_STATIC_VAR.
2042
dd5901a6
PA
20432017-09-04 Pedro Alves <palves@redhat.com>
2044
2045 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2046 handling.
2047 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2048 Ditto.
2049 * parse.c (operator_length_standard, operator_check_standard):
2050 Ditto.
2051 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2052
46a4882b
PA
20532017-09-04 Pedro Alves <palves@redhat.com>
2054
2055 * ax-gdb.c: Include "typeprint.h".
2056 (gen_expr_for_cast): New function.
2057 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2058 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2059 type is unknown.
2060 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2061 nodebug_data_symbol.
2062 * eval.c: Include "typeprint.h".
2063 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2064 Error out if symbol has unknown type.
2065 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2066 evaluate_subexp_for_cast.
2067 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2068 OP_VAR_MSYM_VALUE.
2069 (evaluate_subexp_for_cast): New function.
2070 * gdbtypes.c (init_nodebug_var_type): New function.
2071 (objfile_type): Use it to initialize types of variables with no
2072 debug info.
2073 * typeprint.c (error_unknown_type): New.
2074 * typeprint.h (error_unknown_type): New declaration.
2075 * compile/compile-c-types.c (convert_type_basic): Handle
2076 TYPE_CODE_ERROR; warn and fallback to int for variables with
2077 unknown type.
2078
fe13dfec
PA
20792017-09-04 Pedro Alves <palves@redhat.com>
2080
2081 * eval.c (evaluate_var_value): New function, factored out from ...
2082 (evaluate_subexp_standard): ... here.
2083
d008ee21
PA
20842017-09-04 Pedro Alves <palves@redhat.com>
2085
2086 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2087 Remove useless assignments to 'op'.
2088
827d0c51
PA
20892017-09-04 Pedro Alves <palves@redhat.com>
2090
2091 * eval.c (eval_skip_value): New function.
2092 (evaluate_subexp_standard): Use it.
2093
2c5a2be1
PA
20942017-09-04 Pedro Alves <palves@redhat.com>
2095
2096 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2097 function name from symbol/minsym and pass it to
2098 error_call_unknown_return_type.
2099
74ea4be4
PA
21002017-09-04 Pedro Alves <palves@redhat.com>
2101
2102 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2103 * ax-gdb.c (gen_msym_var_ref): New function.
2104 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2105 * eval.c (evaluate_var_msym_value): New function.
2106 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2107 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2108 to call_function_by_hand.
2109 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2110 Handle OP_VAR_MSYM_VALUE.
2111 (union exp_element) <msymbol>: New field.
2112 * minsyms.h (struct type): Forward declare.
2113 (find_minsym_type_and_address): Declare.
2114 * parse.c (write_exp_elt_msym): New function.
2115 (write_exp_msymbol): Delete, refactored as ...
2116 (find_minsym_type_and_address): ... this new function.
2117 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2118 (operator_length_standard, operator_check_standard): Handle
2119 OP_VAR_MSYM_VALUE.
2120 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2121
7022349d
PA
21222017-09-04 Pedro Alves <palves@redhat.com>
2123
2124 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2125 TYPE_GNU_IFUNC specially here. Throw error if return type is
2126 unknown.
2127 * ada-typeprint.c (print_func_type): Handle functions with unknown
2128 return type.
2129 * c-typeprint.c (c_type_print_base): Handle functions and methods
2130 with unknown return type.
2131 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2132 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2133 * compile/compile-c-types.c: Include "objfiles.h".
2134 (convert_func): For functions with unknown return type, warn and
2135 default to int.
2136 * compile/compile-object-run.c (compile_object_run): Adjust call
2137 to call_function_by_hand_dummy.
2138 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2139 call_function_by_hand.
2140 * eval.c (evaluate_subexp_standard): Adjust calls to
2141 call_function_by_hand. Handle functions and methods with unknown
2142 return type. Pass expect_type to call_function_by_hand.
2143 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2144 return type.
2145 * gcore.c (call_target_sbrk): Adjust call to
2146 call_function_by_hand.
2147 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2148 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2149 an integer address type instead of nodebug.
2150 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2151 call_function_by_hand.
2152 * infcall.c (error_call_unknown_return_type): New function.
2153 (call_function_by_hand): New "default_return_type" parameter.
2154 Pass it down.
2155 (call_function_by_hand_dummy): New "default_return_type"
2156 parameter. Use it instead of defaulting to int. If there's no
2157 default and the return type is unknown, throw an error. If
2158 there's a default return type, and the called function has no
2159 debug info, then assume the function is prototyped.
2160 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2161 New "default_return_type" parameter.
2162 (error_call_unknown_return_type): New declaration.
2163 * linux-fork.c (call_lseek): Cast return type of lseek.
2164 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2165 call_function_by_hand.
2166 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2167 calls to call_function_by_hand.
2168 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2169 return type.
2170 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2171 (value_nsstring, print_object_command): Adjust calls to
2172 call_function_by_hand.
2173 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2174 functions with unknown return type.
2175 (pascal_type_print_func_varspec_suffix): New function.
2176 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2177 TYPE_CODE_METHOD>: Use it.
2178 * python/py-value.c (valpy_call): Adjust call to
2179 call_function_by_hand.
2180 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2181 call_function_by_hand.
2182 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2183 call_function_by_hand.
2184 * valops.c (value_allocate_space_in_inferior): Adjust call to
2185 call_function_by_hand.
2186 * typeprint.c (type_print_unknown_return_type): New function.
2187 * typeprint.h (type_print_unknown_return_type): New declaration.
2188
54990598
PA
21892017-09-04 Pedro Alves <palves@redhat.com>
2190
2191 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2192 types with more than one parameter as prototyped.
2193
9a24775b
PA
21942017-09-04 Pedro Alves <palves@redhat.com>
2195
2196 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2197 (disassemble_command): Use gdb_disassembly_flags instead of bare
2198 int.
2199 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2200 (dump_insns, do_mixed_source_and_assembly_deprecated)
2201 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2202 Use gdb_disassembly_flags instead of bare int.
2203 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2204 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2205 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2206 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2207 (enum gdb_disassembly_flag): ... values of this new enumeration.
2208 (gdb_disassembly_flags): Define.
2209 (gdb_disassembly)
2210 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2211 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2212 gdb_disassembly_flags instead of bare int.
2213 * record-btrace.c (btrace_insn_history)
2214 (record_btrace_insn_history, record_btrace_insn_history_range)
2215 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2216 instead of bare int.
2217 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2218 Use gdb_disassembly_flags instead of bare int.
2219 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2220 Define.
2221 * target-delegates.c: Regenerate.
2222 * target.c (target_insn_history, target_insn_history_from)
2223 (target_insn_history_range): Use gdb_disassembly_flags instead of
2224 bare int.
2225 * target.h: Include "disasm.h".
2226 (struct target_ops) <to_insn_history, to_insn_history_from,
2227 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2228 int.
2229 (target_insn_history, target_insn_history_from)
2230 (target_insn_history_range): Use gdb_disassembly_flags instead of
2231 bare int.
2232
80a65e9b
SM
22332017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2234
2235 * cli/cli-script.c (build_command_line): For if/while commands,
2236 check whether args is empty.
2237
6b66338c
SM
22382017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2239
2240 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2241 (enum command_control_type): Likewise.
2242 (struct command_line): Likewise.
2243 (free_command_lines): Likewise.
2244 (struct command_lines_deleter): Likewise.
2245 (command_line_up): Likewise.
2246 (read_command_lines): Likewise.
2247 (read_command_lines_1): Likewise.
2248 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2249 (enum command_control_type): Likewise.
2250 (struct command_line): Likewise.
2251 (free_command_lines): Likewise.
2252 (struct command_lines_deleter): Likewise.
2253 (command_line_up): Likewise.
2254 (read_command_lines): Likewise.
2255 (read_command_lines_1): Likewise.
2256 * breakpoint.h: Include cli/cli-script.h.
2257 * extension-priv.h: Likewise.
2258 * gdbcmd.h: Likewise.
2259
51abb421
PA
22602017-09-04 Pedro Alves <palves@redhat.com>
2261
2262 * ada-lang.c (is_known_support_routine): Move sal declaration to
2263 where it is initialized.
2264 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2265 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2266 (clear_command, update_static_tracepoint): Remove init_sal
2267 references. Move declarations closer to initializations.
2268 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2269 initializations.
2270 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2271 references. Move sal declarations closer to initializations.
2272 * frame.c (find_frame_sal): Return a symtab_and_line via function
2273 return instead of output parameter. Remove init_sal references.
2274 * frame.h (find_frame_sal): Return a symtab_and_line via function
2275 return instead of output parameter.
2276 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2277 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2278 instead of memset.
2279 (gdbscm_find_pc_line): Remove init_sal reference.
2280 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2281 references. Move declarations closer to initializations.
2282 * infcmd.c (set_step_frame): Update. Move declarations closer to
2283 initializations.
2284 (finish_backward): Remove init_sal references. Move declarations
2285 closer to initializations.
2286 * infrun.c (process_event_stop_test, handle_step_into_function)
2287 (insert_hp_step_resume_breakpoint_at_frame)
2288 (insert_step_resume_breakpoint_at_caller): Likewise.
2289 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2290 (symbol_to_sal): Likewise.
2291 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2292 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2293 to its initialization.
2294 * reverse.c (save_bookmark_command): Use new/delete. Remove
2295 init_sal references. Move declarations closer to initializations.
2296 * source.c (get_current_source_symtab_and_line): Remove brace
2297 initialization.
2298 (set_current_source_symtab_and_line): Now takes the sal by const
2299 reference. Remove brace initialization.
2300 (line_info): Remove init_sal reference.
2301 * source.h (set_current_source_symtab_and_line): Now takes a
2302 symtab_and_line via const reference.
2303 * stack.c (set_current_sal_from_frame): Adjust.
2304 (print_frame_info): Adjust.
2305 (get_last_displayed_sal): Return the sal via function return
2306 instead of via output parameter. Simplify.
2307 (frame_info): Adjust.
2308 * stack.h (get_last_displayed_sal): Return the sal via function
2309 return instead of via output parameter.
2310 * symtab.c (init_sal): Delete.
2311 (find_pc_sect_line): Remove init_sal references. Move
2312 declarations closer to initializations.
2313 (find_function_start_sal): Remove init_sal references. Move
2314 declarations closer to initializations.
2315 * symtab.h (struct symtab_and_line): In-class initialize all
2316 fields.
2317 * tracepoint.c (set_traceframe_context)
2318 (print_one_static_tracepoint_marker): Remove init_sal references.
2319 Move declarations closer to initializations.
2320 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2321 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2322 declarations closer to initializations.
2323 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2324 init_sal references. Adjust.
2325
6c5b2ebe
PA
23262017-09-04 Pedro Alves <palves@redhat.com>
2327
2328 * ax-gdb.c (agent_command_1): Use range-for.
2329 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2330 * breakpoint.c: Include "common/array-view.h".
2331 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2332 parameter from struct symtabs_and_lines to
2333 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2334 (breakpoint_sals_to_pc): Change sals parameter from struct
2335 symtabs_and_lines to std::vector reference.
2336 (check_fast_tracepoint_sals): Change sals parameter from struct
2337 symtabs_and_lines to std::array_view. Use range-for.
2338 (decode_static_tracepoint_spec): Return a std::vector instead of
2339 symtabs_and_lines. Update.
2340 (create_breakpoint): Update.
2341 (break_range_command, until_break_command, clear_command): Update.
2342 (base_breakpoint_decode_location, bkpt_decode_location)
2343 (bkpt_probe_create_sals_from_location)
2344 (bkpt_probe_decode_location, tracepoint_decode_location)
2345 (tracepoint_probe_decode_location)
2346 (strace_marker_create_sals_from_location): Return a std::vector
2347 instead of symtabs_and_lines.
2348 (strace_marker_create_breakpoints_sal): Update.
2349 (strace_marker_decode_location): Return a std::vector instead of
2350 symtabs_and_lines. Update.
2351 (update_breakpoint_locations): Change struct symtabs_and_lines
2352 parameters to gdb::array_view. Adjust.
2353 (location_to_sals): Return a std::vector instead of
2354 symtabs_and_lines. Update.
2355 (breakpoint_re_set_default): Use std::vector instead of struct
2356 symtabs_and_lines.
2357 (decode_location_default): Return a std::vector instead of
2358 symtabs_and_lines. Update.
2359 * breakpoint.h: Include "common/array-view.h".
2360 (struct breakpoint_ops) <decode_location>: Now returns a
2361 std::vector instead of returning a symtabs_and_lines via output
2362 parameter.
2363 (update_breakpoint_locations): Change sals parameters to use
2364 gdb::array_view.
2365 * cli/cli-cmds.c (edit_command, list_command): Update to use
2366 std::vector and gdb::array_view.
2367 (ambiguous_line_spec): Adjust to use gdb::array_view and
2368 range-for.
2369 (compare_symtabs): Rename to ...
2370 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2371 const reference and adjust.
2372 (filter_sals): Rewrite using std::vector and standard algorithms.
2373 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2374 (jump_command): Update to use std::vector.
2375 * linespec.c (struct linespec_state) <canonical_names>: Update
2376 comment.
2377 (add_sal_to_sals_basic): Delete.
2378 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2379 (decode_line_2, create_sals_line_offset)
2380 (convert_address_location_to_sals, convert_linespec_to_sals)
2381 (convert_explicit_location_to_sals, parse_linespec)
2382 (event_location_to_sals, decode_line_full, decode_line_1)
2383 (decode_line_with_current_source)
2384 (decode_line_with_last_displayed, decode_objc)
2385 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2386 (linespec_result::~linespec_result): Adjust to use std::vector
2387 instead of symtabs_and_lines.
2388 * linespec.h (linespec_sals::sals): Now a std::vector.
2389 (struct linespec_result): Use std::vector, bool, and in-class
2390 initialization.
2391 (decode_line_1, decode_line_with_current_source)
2392 (decode_line_with_last_displayed): Return std::vector.
2393 * macrocmd.c (info_macros_command): Use std::vector.
2394 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2395 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2396 std::vector.
2397 * probe.h (parse_probes): Return a std::vector.
2398 * python/python.c (gdbpy_decode_line): Use std::vector and
2399 gdb::array_view.
2400 * source.c (select_source_symtab, line_info): Use std::vector.
2401 * stack.c (func_command): Use std::vector.
2402 * symtab.h (struct symtabs_and_lines): Delete.
2403 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2404
7c44b49c
PA
24052017-09-04 Pedro Alves <palves@redhat.com>
2406
2407 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2408 unittests/array-view-selftests.c.
2409 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2410 * common/array-view.h: New file.
2411 * unittests/array-view-selftests.c: New file.
2412
e439fa14
PA
24132017-09-04 Pedro Alves <palves@redhat.com>
2414
2415 * cli/cli-cmds.c (edit_command): Pass message to
2416 ambiguous_line_spec.
2417 (list_command): Pass message to ambiguous_line_spec. Say
2418 "first"/"last" instead of "start" and "end" to be consistent with
2419 the manual.
2420 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2421 them to print formatted message.
2422
7525b645
PA
24232017-09-04 Pedro Alves <palves@redhat.com>
2424
2425 * btrace.c (ftrace_add_pt): Pass btrace_insn to
2426 ftrace_update_insns by reference instead of pointer.
2427
badc0020
YQ
24282017-09-04 Yao Qi <yao.qi@linaro.org>
2429
2430 * i386-go32-tdep.c: Include x86-xstate.h.
2431 (i386_go32_init_abi): Call i386_target_description.
2432 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
2433 if xcr0 is X86_XSTATE_X87_MASK.
2434 * i386-tdep.h (tdesc_i386): Remove the declaration.
2435 (tdesc_i386_mmx): Likewise.
2436
d78bdb54
YQ
24372017-09-04 Yao Qi <yao.qi@linaro.org>
2438
2439 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
2440 X86_XSTATE_SSE_MASK instead of 0.
2441
ca1fa5ee
YQ
24422017-09-04 Yao Qi <yao.qi@linaro.org>
2443
2444 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
2445 i386_target_description.
2446 * i386-fbsd-nat.c (i386fbsd_read_description): Call
2447 i386_target_description.
2448 * i386-tdep.c (i386_gdbarch_init): Likewise.
2449
2434b019
YQ
24502017-09-04 Yao Qi <yao.qi@linaro.org>
2451
2452 * amd64-darwin-tdep.c: Include "x86-xstate.h".
2453 (x86_darwin_init_abi_64): Call amd64_target_description.
2454 * amd64-dicos-tdep.c: Likewise.
2455 * amd64-fbsd-nat.c: Likewise.
2456 * amd64-fbsd-tdep.c: Likewise.
2457 * amd64-nbsd-tdep.c: Likewise.
2458 * amd64-obsd-tdep.c: Likewise.
2459 * amd64-sol2-tdep.c: Likewise.
2460 * amd64-windows-tdep.c: Likewise.
2461 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
2462
0860c437
SM
24632017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2464
2465 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
2466 (btrace_function) <insn>: Change type to use std::vector.
2467 * btrace.c (ftrace_debug, ftrace_call_num_insn,
2468 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
2469 ftrace_update_insns, ftrace_compute_global_level_offset,
2470 btrace_stitch_bts, btrace_clear, btrace_insn_get,
2471 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
2472 change to std::vector.
2473 (ftrace_update_insns): Adjust to change to std::vector, change
2474 type of INSN parameter.
2475 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
2476 * record-btrace.c (btrace_call_history_insn_range,
2477 btrace_compute_src_line_range,
2478 record_btrace_frame_prev_register): Adjust to change to
2479 std::vector.
2480 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
2481 to change to std::vector.
2482
0638b7f9
TT
24832017-09-03 Tom Tromey <tom@tromey.com>
2484
2485 * corefile.c (reopen_exec_file): Use std::string.
2486
8f84fb0e
TT
24872017-09-03 Tom Tromey <tom@tromey.com>
2488
2489 * compile/compile.c (compile_register_name_mangled): Return
2490 std::string.
2491 * compile/compile-loc2c.c (pushf_register_address): Update.
2492 (pushf_register): Update.
2493 * compile/compile-c-types.c (convert_array): Update.
2494 * compile/compile-c-symbols.c (generate_vla_size): Update.
2495 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
2496 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
2497 (convert_one_symbol): Update.
2498 (generate_c_for_for_one_variable): Update.
2499 * compile/compile-c-support.c (c_get_range_decl_name): Return a
2500 std::string.
2501 (generate_register_struct): Update.
2502 * compile/compile-internal.h (c_get_range_decl_name): Return a
2503 std::string.
2504 (compile_register_name_mangled): Return std::string.
2505
18e9961f
TT
25062017-09-03 Tom Tromey <tom@tromey.com>
2507
2508 * utils.c (perror_string): Return a std::string.
2509 (throw_perror_with_name, perror_warning_with_name): Update.
2510
45343786
TT
25112017-09-03 Tom Tromey <tom@tromey.com>
2512
2513 * demangle.c (demangle_command): Use std::string,
2514 unique_xmalloc_ptr.
2515
b57af503
TT
25162017-09-03 Tom Tromey <tom@tromey.com>
2517
2518 * cli/cli-setshow.c (do_set_command): Use std::string.
2519
6eecf35f
TT
25202017-09-03 Tom Tromey <tom@tromey.com>
2521
2522 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
2523
56496dd4
TT
25242017-09-03 Tom Tromey <tom@tromey.com>
2525
2526 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
2527
e91a1fa7
TT
25282017-09-03 Tom Tromey <tom@tromey.com>
2529
2530 * mi/mi-cmd-env.c (env_execute_cli_command): Use
2531 gdb::unique_xmalloc_ptr.
2532
7ffd83d7
TT
25332017-09-03 Tom Tromey <tom@tromey.com>
2534
2535 * thread.c (print_thread_info_1): Use string_printf.
2536 (thread_apply_command, thread_apply_all_command): Use
2537 std::string.
2538
1ccbe998
TT
25392017-09-03 Tom Tromey <tom@tromey.com>
2540
2541 * valprint.c (val_print_string): Update.
2542 * gdbcore.h (memory_error_message): Return std::string.
2543 * corefile.c (memory_error_message): Return std::string.
2544 (memory_error): Update.
2545 * breakpoint.c (insert_bp_location): Update.
2546
23fdd69e
SM
25472017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2548
2549 * target/waitstatus.h (target_waitstatus_to_string): Change
2550 return type to std::string.
2551 * target/waitstatus.c (target_waitstatus_to_string): Return
2552 std::string.
2553 * target.h (target_waitstatus_to_string): Remove declaration.
2554 * infrun.c (resume, clear_proceed_status_thread,
2555 print_target_wait_results, do_target_wait, save_waitstatus,
2556 stop_all_threads): Adjust.
2557 * record-btrace.c (record_btrace_wait): Adjust.
2558 * target-debug.h
2559 (target_debug_print_struct_target_waitstatus_p): Adjust.
2560
5c811d30
JK
25612017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2562
2563 PR gdb/22046
2564 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
2565 detection.
2566
0a2dde4a
SDJ
25672017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2568
2569 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
2570 for setting/unsetting environment variables on the remote target.
2571 (New remote packets): Add entries for QEnvironmentHexEncoded,
2572 QEnvironmentUnset and QEnvironmentReset.
2573 * common/environ.c (gdb_environ::operator=): Extend method to
2574 handle m_user_set_env_list and m_user_unset_env_list.
2575 (gdb_environ::clear): Likewise.
2576 (match_var_in_string): Change type of first parameter from 'char
2577 *' to 'const char *'.
2578 (gdb_environ::set): Extend method to handle
2579 m_user_set_env_list and m_user_unset_env_list.
2580 (gdb_environ::unset): Likewise.
2581 (gdb_environ::clear_user_set_env): New method.
2582 (gdb_environ::user_set_envp): Likewise.
2583 (gdb_environ::user_unset_envp): Likewise.
2584 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
2585 m_user_unset_env_list on move constructor/assignment.
2586 (unset): Add new default parameter 'update_unset_list = true'.
2587 (clear_user_set_env): New method.
2588 (user_set_envp): Likewise.
2589 (user_unset_envp): Likewise.
2590 (m_user_set_env_list): New std::set.
2591 (m_user_unset_env_list): Likewise.
2592 * common/rsp-low.c (hex2str): New function.
2593 (bin2hex): New overload for bin2hex function.
2594 * common/rsp-low.c (hex2str): New prototype.
2595 (str2hex): New overload prototype.
2596 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
2597 QEnvironmentUnset and QEnvironmentReset.
2598 (remote_protocol_features): Add QEnvironmentHexEncoded,
2599 QEnvironmentUnset and QEnvironmentReset packets.
2600 (send_environment_packet): New function.
2601 (extended_remote_environment_support): Likewise.
2602 (extended_remote_create_inferior): Call
2603 extended_remote_environment_support.
2604 (_initialize_remote): Add QEnvironmentHexEncoded,
2605 QEnvironmentUnset and QEnvironmentReset packet configs.
2606 * unittests/environ-selftests.c (gdb_selftest_env_var):
2607 New variable.
2608 (test_vector_initialization): New function.
2609 (test_init_from_host_environ): Likewise.
2610 (test_reinit_from_host_environ): Likewise.
2611 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
2612 Likewise.
2613 (test_unset_set_empty_vector): Likewise.
2614 (test_vector_clear): Likewise.
2615 (test_std_move): Likewise.
2616 (test_move_constructor):
2617 (test_self_move): Likewise.
2618 (test_set_unset_reset): Likewise.
2619 (run_tests): Rewrite in terms of the functions above.
2620
654670a4
WP
26212017-08-31 Weimin Pan <weimin.pan@oracle.com>
2622
2623 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
2624 (adi_available): Use a temp variable of type CORE_ADDR as argument
2625 3 when calling target_auxv_search.
2626 (adi_normalize_address): Use masks and xor operators to calculate
2627 normalized address.
2628 (adi_read_versions, adi_write_versions, adi_print_versions)
2629 (do_examine, do_assign): Use paddress.
2630
7755ddb7
JB
26312017-08-29 John Baldwin <jhb@FreeBSD.org>
2632
2633 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
2634 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
2635 out of loop and add supply of FIR.
2636 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
2637 add collect of FIR.
2638
fd437cbc
SM
26392017-08-28 Simon Marchi <simon.marchi@ericsson.com>
2640
3804a343 2641 PR gdb/21827
fd437cbc
SM
2642 * cli/cli-script.c (define_command): Don't convert command name
2643 to lower case.
2644
988f6b3d
JB
26452017-08-25 Joel Brobecker <brobecker@adacore.com>
2646
2647 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
2648 Update all callers accordingly. Remove all code blocks handling
2649 the case where DISPP is not NULL.
2650
663c44ac
JK
26512017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2652
2653 PR symtab/22003
2654 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
2655 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2656 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
2657
f1902523
JK
26582017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2659
2660 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
2661 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
2662 (read_comp_units_from_section): New parameter abbrev_section, use
2663 read_and_check_comp_unit_head, allocate signatured_type if needed.
2664 (create_all_comp_units): Update read_comp_units_from_section caller.
2665
87215ad1
SDJ
26662017-08-23 Pedro Alves <palves@redhat.com>
2667
2668 PR remote/21852
2669 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
2670 to null_ptid and switch to thread without reading the registers
2671 after adding the inferior.
2672
6e41ddec
JK
26732017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2674
2675 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
2676 compile-gcc.
2677 * compile/compile.c (compile_gcc, show_compile_gcc): New.
2678 (compile_to_object): Implement compile_gcc.
2679 (_initialize_compile): Install "set compile-gcc". Initialize
2680 compile_gcc.
2681
e68c32d5
JK
26822017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2683
2684 * compile/compile.c (compile_to_object): Conditionally call
2685 set_verbose. Conditionally call compile or compile_v0.
2686
58afddc6
WP
26872017-08-07 Weimin Pan <weimin.pan@oracle.com>
2688
2689 * sparc64-tdep.h: (adi_normalize_address): New export.
2690 * sparc-nat.h: (open_adi_tag_fd): New export.
2691 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
2692 * sparc64-linux-tdep.c:
2693 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
2694 (sparc64_linux_handle_segmentation_fault): New function.
2695 (sparc64_linux_init_abi): Register
2696 sparc64_linux_handle_segmentation_fault
2697 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
2698 (sparc64_addr_bits_remove): New function.
2699 (sparc64_init_abi): Register sparc64_addr_bits_remove.
2700 (MAX_PROC_NAME_SIZE): New macro.
2701 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
2702 (sparc64adilist): New variable.
2703 (adi_proc_list): New variable.
2704 (find_adi_info): New function.
2705 (add_adi_info): New function.
2706 (get_adi_info_proc): New function.
2707 (get_adi_info): New function.
2708 (info_adi_command): New function.
2709 (read_maps_entry): New function.
2710 (adi_available): New function.
2711 (adi_normalize_address): New function.
2712 (adi_align_address): New function.
2713 (adi_convert_byte_count): New function.
2714 (adi_tag_fd): New function.
2715 (adi_is_addr_mapped): New function.
2716 (adi_read_versions): New function.
2717 (adi_write_versions): New function.
2718 (adi_print_versions): New function.
2719 (do_examine): New function.
2720 (do_assign): New function.
2721 (adi_examine_command): New function.
2722 (adi_assign_command): New function.
2723 (_initialize_sparc64_adi_tdep): New function.
2724
11db9430
SM
27252017-08-22 Simon Marchi <simon.marchi@ericsson.com>
2726
2727 * breakpoint.c (breakpoints_info): Rename to ...
2728 (info_breakpoints_command): ... this.
2729 (watchpoints_info): Rename to ...
2730 (info_watchpoints_command): ... this.
2731 (tracepoints_info): Rename to ...
2732 (info_tracepoints_command): ... this.
2733 (_initialize_breakpoint): Adjust.
2734 * dcache.c (dcache_info): Rename to ...
2735 (info_display_command): ... this.
2736 (_initialize_dcache): Adjust.
2737 * frame.h (args_info): Rename to ...
2738 (info_args_command): ... this.
2739 (locals_info): Rename to ...
2740 (info_locals_command): ... this.
2741 * infcmd.c (nofp_registers_info): Rename to ...
2742 (info_registers_command): ... this.
2743 (float_info): Rename to ...
2744 (info_float_command): ... this.
2745 (program_info): Rename to ...
2746 (info_program_command): ... this.
2747 (all_registers_info): Rename to ...
2748 (info_all_registers_command): ... this.
2749 (vector_info): Rename to ...
2750 (info_vector_command): ... this.
2751 (float_info): Rename to ...
2752 (info_float_command): ... this.
2753 (_initialize_infcmd): Adjust.
2754 * inferior.h (term_info): Rename to ...
2755 (info_terminal_command): ... this.
2756 * inflow.c (term_info): Rename to ...
2757 (info_terminal_command): ... this.
2758 (_initialize_inflow): Adjust.
2759 * infrun.c (signals_info): Rename to ...
2760 (info_signals_command): ... this.
2761 (_initialize_infrun): Adjust.
2762 * objc-lang.c (classes_info): Rename to ...
2763 (info_classes_command): ... this.
2764 (selectors_info): Rename to ...
2765 (info_selectors_command): ... this.
2766 (_initialize_objc_language): Adjust.
2767 * printcmd.c (sym_info): Rename to ...
2768 (info_symbol_command): ... this.
2769 (address_info): Rename to ...
2770 (info_address_command): ... this.
2771 (display_info): Rename to ...
2772 (info_display_command): ... this.
2773 (_initialize_printcmd): Adjust.
2774 * reverse.c (bookmarks_info): Rename to ...
2775 (info_breakpoints_command): ... this.
2776 (_initialize_reverse): Adjust.
2777 * ser-go32.c (dos_info): Rename to ...
2778 (info_serial_command): ... this.
2779 (_initialize_ser_dos): Adjust.
2780 * skip.c (skip_info): Rename to ...
2781 (info_skip_command): ... this.
2782 (_initialize_step_skip): Adjust.
2783 * source.c (line_info): Rename to ...
2784 (info_line_command): ... this.
2785 (source_info): Rename to ...
2786 (info_source_command)
2787 * stack.c (frame_info): Rename to ...
2788 (info_frame_command): ... this.
2789 (locals_info): Rename to ...
2790 (info_locals_command): ... this.
2791 (args_info): Rename to ...
2792 (info_args_command): ... this.
2793 (_initialize_stack): Adjust.
2794 * symtab.c (sources_info): Rename to ...
2795 (info_sources_command): ... this.
2796 (variables_info): Rename to ...
2797 (info_variables_command): ... this.
2798 (functions_info): Rename to ...
2799 (info_functions_command): ... this.
2800 (types_info): Rename to ...
2801 (info_types_command): ... this.
2802 (_initialize_symtab): Adjust.
2803 * target.c (target_info): Rename to ...
2804 (info_target_command): ... this.
2805 (initialize_targets): Adjust.
2806 * tracepoint.c (tvariables_info): Rename to ...
2807 (info_tvariables_command): ... this.
2808 (scope_info): Rename to ...
2809 (info_scope_command): ... this.
2810 (trace_dump_actions): Adjust.
2811 (_initialize_tracepoint): Adjust.
2812
b270e6f9
TT
28132017-08-22 Tom Tromey <tom@tromey.com>
2814
2815 * breakpoint.h (install_breakpoint): Update.
2816 * breakpoint.c (add_solib_catchpoint): Update.
2817 (install_breakpoint): Change argument to a std::unique_ptr.
2818 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
2819 (create_breakpoint_sal, create_breakpoint): Update.
2820 (watch_command_1, catch_exec_command_1)
2821 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
2822 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
2823 Return the breakpoint.
2824 (set_raw_breakpoint_without_location, set_raw_breakpoint)
2825 (new_single_step_breakpoint): Update.
2826 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
2827 std::unique_ptr.
2828 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
2829 std::unique_ptr.
2830 * break-catch-sig.c (create_signal_catchpoint): Use
2831 std::unique_ptr.
2832 * ada-lang.c (create_ada_exception_catchpoint): Use
2833 std::unique_ptr.
2834
36bd8eaa
TT
28352017-08-22 Tom Tromey <tom@tromey.com>
2836
2837 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
2838
56f37645
TT
28392017-08-22 Tom Tromey <tom@tromey.com>
2840
2841 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
2842 (lookup_partial_symbol): Update.
2843
0b581c69
TT
28442017-08-22 Tom Tromey <tom@tromey.com>
2845
2846 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
2847 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
2848 (find_and_open_source, symtab_to_fullname): Update.
2849 * psymtab.c (psymtab_to_fullname): Update.
2850
14278e1f
TT
28512017-08-22 Tom Tromey <tom@tromey.com>
2852
2853 * exec.c (exec_file_attach): Update.
2854 * linux-thread-db.c (try_thread_db_load): Update.
2855 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
2856 * utils.c (gdb_realpath): Change return type.
2857 (gdb_realpath_keepfile): Update.
2858 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
2859 (_initialize_utils): Register the new self test.
2860 * source.c (openp): Update.
2861 (find_and_open_source): Update.
2862 * nto-tdep.c (nto_find_and_open_solib): Update.
2863 * main.c (set_gdb_data_directory): Update.
2864 (captured_main_1): Update.
2865 * dwarf2read.c (dwarf2_get_dwz_file): Update
2866 (dw2_map_symbol_filenames): Update.
2867 * auto-load.c (auto_load_safe_path_vec_update): Update.
2868 (filename_is_in_auto_load_safe_path_vec): Change type of
2869 "filename_realp".
2870 (auto_load_objfile_script): Update.
2871 (file_is_auto_load_safe): Update. Use std::string.
2872 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
2873
4971c9a7
TT
28742017-08-22 Tom Tromey <tom@tromey.com>
2875
2876 * utils.c (gdb_realpath_keepfile): Return a
2877 gdb::unique_xmalloc_ptr.
2878 * exec.c (exec_file_attach): Update.
2879 * utils.h (gdb_realpath_keepfile): Return a
2880 gdb::unique_xmalloc_ptr.
2881
e3e41d58
TT
28822017-08-22 Tom Tromey <tom@tromey.com>
2883
2884 * compile/compile.c (compile_file_command): Use
2885 gdb::unique_xmalloc_ptr, std::string.
2886 * utils.c (gdb_abspath): Change return type.
2887 * source.c (openp): Update.
2888 * objfiles.c (allocate_objfile): Update.
2889 * main.c (set_gdb_data_directory): Update.
2890 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
2891
0d999a6e
ZZ
28922017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
2893
2894 * cli-cmds.c (list_commands): List actual code around more than
2895 one location.
2896
329d5e7e
JB
28972017-08-21 John Baldwin <jhb@FreeBSD.org>
2898
2899 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
2900
bf223d3e
PA
29012017-08-21 Pedro Alves <palves@redhat.com>
2902
2903 PR gdb/19487
2904 * c-exp.y (variable production): Handle function aliases.
2905 * minsyms.c (msymbol_is_text): New function.
2906 * minsyms.h (msymbol_is_text): Declare.
2907 * symtab.c (find_function_alias_target): New function.
2908 * symtab.h (find_function_alias_target): Declare.
2909
c973d0aa
PA
29102017-08-21 Pedro Alves <palves@redhat.com>
2911
2912 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
2913 typedefs.
2914 * typeprint.c (whatis_exp): If handling "whatis", and expression
2915 is OP_TYPE, strip one typedef level. Otherwise don't strip
2916 typedefs here.
2917 * valops.c (value_cast): Save "to" type before resolving
2918 stubs/typedefs. Use that type as resulting value's type.
2919
2989a365
TT
29202017-08-18 Tom Tromey <tom@tromey.com>
2921 Pedro Alves <palves@redhat.com>
2922
2923 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
2924 * sol-thread.c (sol_thread_resume, sol_thread_wait)
2925 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
2926 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
2927 * proc-service.c (ps_xfer_memory): Use scoped_restore.
2928 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
2929 (linux_get_siginfo_data): Add "thread" argument. Use
2930 scoped_restore.
2931 * linux-nat.c (linux_child_follow_fork)
2932 (check_stopped_by_watchpoint): Use scoped_restore.
2933 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
2934 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
2935 (restore_inferior_ptid, save_inferior_ptid): Remove.
2936 * btrace.c (btrace_fetch): Use scoped_restore.
2937 * bsd-uthread.c (bsd_uthread_fetch_registers)
2938 (bsd_uthread_store_registers): Use scoped_restore.
2939 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
2940 scoped_restore.
2941 * aix-thread.c (aix_thread_resume, aix_thread_wait)
2942 (aix_thread_xfer_partial): Use scoped_restore.
2943 * inferior.h (save_inferior_ptid): Remove.
2944
e60eb288
YQ
29452017-08-18 Yao Qi <yao.qi@linaro.org>
2946
2947 PR tdep/21818
2948 * arm-tdep.c (gdb_print_insn_arm): Mark
2949 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
2950
6d580b63
YQ
29512017-08-18 Yao Qi <yao.qi@linaro.org>
2952
2953 * NEWS: Mention GDBserver's new option "--selftest".
2954 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
2955 * selftest.c: Move it to common/selftest.c.
2956 * selftest.h: Move it to common/selftest.h.
2957 * selftest-arch.c (reset): New function.
2958 (tests_with_arch): Call reset.
2959
86dcbf50
YQ
29602017-08-18 Yao Qi <yao.qi@linaro.org>
2961
2962 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
2963 instead of exception_fprintf and printf_filtered.
2964
7649770c
YQ
29652017-08-18 Yao Qi <yao.qi@linaro.org>
2966
2967 * selftest.c (register_self_test): Rename it to
2968 selftests::register_test.
2969 (run_self_tests): selftest::run_tests.
2970 * selftest.h: Update declarations.
2971 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
2972 selftests::register_test_foreach_arch.
2973 * selftest-arch.h: Update declaration.
2974 * aarch64-tdep.c: Update.
2975 * arm-tdep.c: Likewise.
2976 * disasm-selftests.c: Likewise.
2977 * dwarf2loc.c: Likewise.
2978 * dwarf2-frame.c: Likewise.
2979 * findvar.c: Likewise.
2980 * gdbarch-selftests.c: Likewise.
2981 * maint.c (maintenance_selftest): Likewise.
2982 * regcache.c: Likewise.
2983 * rust-exp.y: Likewise.
2984 * selftest-arch.c: Likewise.
2985 * unittests/environ-selftests.c: Likewise.
2986 * unittests/function-view-selftests.c: Likewise.
2987 * unittests/offset-type-selftests.c: Likewise.
2988 * unittests/optional-selftests.c: Likewise.
2989 * unittests/scoped_restore-selftests.c: Likewise.
2990 * utils-selftests.c: Likewise.
2991
b0cba12e
PA
29922017-08-17 Pedro Alves <palves@redhat.com>
2993
2994 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
2995 local.
2996
4c8aa72d
PA
29972017-08-17 Pedro Alves <palves@redhat.com>
2998
2999 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3000 field.
3001 (reset_die_in_process): Delete, replaced by ...
3002 (process_die_scope): ... this new class. Make it responsible for
3003 freeing cu->line_header too.
3004 (process_die): Use process_die_scope.
3005 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3006 cu->line_header_die_owner. Don't release the line header if it's
3007 owned by the CU.
3008 (setup_type_unit_groups): Make the CU/DIE own the line header.
3009 Don't release the line header here.
3010
ba713918
AL
30112017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3012
3013 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3014
44d0fb3a
RK
30152017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3016
3017 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3018 Single-Key mode
3019
a5afdb16
RK
30202017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3021
3022 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3023 mode command list.
3024
47613aeb
SH
30252017-08-15 Stafford Horne <shorne@gmail.com>
3026
3027 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3028
9c3cc999
SH
30292017-08-15 Stafford Horne <shorne@gmail.com>
3030
3031 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3032
206726fb
SDJ
30332017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3034
3035 PR gdb/21954
3036 * infcmd.c (unset_environment_command): Use the 'clear' method on
3037 the environment instead of resetting it.
3038
0335ac6d
JB
30392017-08-15 John Baldwin <jhb@FreeBSD.org>
3040
3041 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3042 platforms.
3043
d3abe1c8
TT
30442017-08-14 Tom Tromey <tom@tromey.com>
3045
3046 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3047 (print_binary_chars): Likewise.
3048 (BITS_IN_BYTES): Remove.
3049
d6382fff
TT
30502017-08-14 Tom Tromey <tom@tromey.com>
3051
3052 PR gdb/21675
3053 * valprint.c (LOW_ZERO): Change value to 034.
3054 (print_octal_chars): Add static_asserts for octal constants.
3055 * printcmd.c (print_scalar_formatted): Add 'd' case.
3056
f978cb06
TT
30572017-08-11 Tom Tromey <tom@tromey.com>
3058
3059 * symfile.c (add_symbol_file_command): Use std::vector.
3060
2f5404b3
TT
30612017-08-14 Tom Tromey <tom@tromey.com>
3062
3063 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3064 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3065 std::move.
3066 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3067
de7985c3
PA
30682017-08-11 Pedro Alves <palves@redhat.com>
3069
3070 * infrun.c (process_event_stop_test): Adjust
3071 function_name_is_marked_for_skip call.
3072 * skip.c: Include <list>.
3073 (skiplist_entry): Make it a class with private fields, and
3074 getters/setters.
3075 (skiplist_entry_chain): Delete.
3076 (skiplist_entries): New.
3077 (skiplist_entry_count): Delete.
3078 (highest_skiplist_entry_num): New.
3079 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3080 (add_skiplist_entry): Delete.
3081 (skiplist_entry::skiplist_entry): New.
3082 (skiplist_entry::add_entry): New.
3083 (skip_file_command, skip_function): Adjust.
3084 (compile_skip_regexp): Delete.
3085 (skip_command): Don't compile regexp here. Adjust to use
3086 skiplist_entry::add_entry.
3087 (skip_info): Adjust to use range-for and getters.
3088 (skip_enable_command, skip_disable_command): Adjust to use
3089 range-for and setters.
3090 (skip_delete_command): Adjust to use std::list.
3091 (add_skiplist_entry): Delete.
3092 (skip_file_p): Delete, refactored as ...
3093 (skiplist_entry::do_skip_file_p): ... this new method.
3094 (skip_gfile_p): Delete, refactored as ...
3095 (skiplist_entry::do_gskip_file_p): ... this new method.
3096 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3097 (skiplist_entry::skip_function_p): ... this new method.
3098 (function_name_is_marked_for_skip): Now returns bool, and takes
3099 the function sal by const reference. Adjust to use range-for and
3100 skiplist_entry methods.
3101 (_initialize_step_skip): Remove references to
3102 skiplist_entry_chain, skiplist_entry_count.
3103 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3104 takes the function sal by const reference.
3105
be7d3cd5
YQ
31062017-08-11 Yao Qi <yao.qi@linaro.org>
3107
3108 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3109 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3110 (dwarf2_frame_cache):
3111 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3112 RETURN_MASK_ALL and set *this_case to NULL.
3113 * frame-unwind.h: Update comments.
3114
1c90d9f0
YQ
31152017-08-11 Yao Qi <yao.qi@linaro.org>
3116
3117 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3118 (dwarf2_frame_state_copy_regs): Remove.
3119 (dwarf2_frame_state_free_regs): Remove.
3120 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3121 (dwarf2_restore_rule): Call method .alloc_regs instead of
3122 dwarf2_frame_state_alloc_regs.
3123 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3124 constructor. Call std::move.
3125 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3126 (dwarf2_frame_cache): Likewise.
3127
3128 [GDB_SELF_TEST]: Include selftest.h and
3129 selftest-arch.h.
3130 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3131 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3132 execute_cfa_program_test.
3133
3134 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3135 copy ctor, assignment operator, move assignment.
3136 <alloc_regs>: New method.
3137 <swap>: New method.
3138 (struct dwarf2_frame_state): Delete dtor.
3139 (dwarf2_frame_state_alloc_regs): Remove declaration.
3140 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3141 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3142
afe37d6b
YQ
31432017-08-11 Yao Qi <yao.qi@linaro.org>
3144
3145 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3146 (dwarf2_frame_state::dwarf2_frame_state): New.
3147 (dwarf2_frame_state::~dwarf2_frame_state): New.
3148 (dwarf2_fetch_cfa_info): Update.
3149 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3150 rather than a pointer. Update code.
3151 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3152 dtor.
3153 <data_align, code_align, retaddr_column>: Change them to const.
3154 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3155 to bool.
3156
b348037f
YQ
31572017-08-11 Yao Qi <yao.qi@linaro.org>
3158
3159 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3160 <loc.exp>: New field.
3161 * dwarf2-frame.c (execute_cfa_program): Update.
3162 (dwarf2_frame_prev_register): Update.
3163
e7c9de26
PA
31642017-08-10 Pedro Alves <palves@redhat.com>
3165
3166 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3167
e8c6b620
JB
31682017-08-09 John Baldwin <jhb@FreeBSD.org>
3169
3170 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3171 (fbsd_pending_children): Use std::list.
3172 (fbsd_remember_child): Likewise.
3173 (fbsd_is_child_pending): Likewise.
3174 (fbsd_pending_vfork_done): Use std::forward_list.
3175 (fbsd_add_vfork_done): Likewise.
3176 (fbsd_is_vfork_done_pending): Likewise.
3177 (fbsd_next_vfork_done): Likewise.
3178
e4a26669
JB
31792017-08-09 John Baldwin <jhb@FreeBSD.org>
3180
3181 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3182 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3183 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3184 for `mapfilename'.
3185 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 3186 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 3187
142311d3
JB
31882017-08-09 John Baldwin <jhb@FreeBSD.org>
3189
3190 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3191 "filestuff.h".
3192 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3193
42fa2e0e
TT
31942017-08-09 Tom Tromey <tom@tromey.com>
3195
3196 * skip.c (skiplist_entry): New constructor.
3197 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3198 (skiplist_entry::file_is_glob): Now bool.
3199 (skiplist_entry::file, skiplist_entry::function): Now
3200 std::string.
3201 (make_skip_entry): Return a unique_ptr. Use new.
3202 (free_skiplist_entry, free_skiplist_entry_cleanup)
3203 (make_free_skiplist_entry_cleanup): Remove.
3204 (skip_command, skip_disable_command, add_skiplist_entry)
3205 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3206 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3207 (function_name_is_marked_for_skip): Update.
3208 (skip_delete_command): Update. Use delete.
3209
cd3af38d
JW
32102017-08-09 Jiong Wang <jiong.wang@arm.com>
3211
3212 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3213 (aarch64_linux_core_read_description): New function.
3214 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3215
29592bde
PA
32162017-08-09 Pedro Alves <palves@redhat.com>
3217
3218 * cp-name-parser.y (cp_comp_to_string): Return a
3219 gdb::unique_xmalloc_ptr<char>.
3220 * cp-support.c (replace_typedefs_qualified_name)
3221 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3222 (cp_canonicalize_string_full): Use op= instead of explicit
3223 convertion.
3224 (cp_class_name_from_physname, method_name_from_physname)
3225 (cp_func_name, cp_remove_params): Adjust to use
3226 gdb::unique_xmalloc_ptr<char>.
3227 * cp-support.h (cp_comp_to_string): Return a
3228 gdb::unique_xmalloc_ptr<char>.
3229 * python/py-type.c (typy_lookup_type): Adjust to use
3230 gdb::unique_xmalloc_ptr<char>.
3231
b3340438
L
32322017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3233
3234 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3235
e88e8651
YQ
32362017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3237 Yao Qi <yao.qi@linaro.org>
3238
3239 * cp-support.c (cp_canonicalize_string_full): Use
3240 gdb::unique_xmalloc_ptr<char>.
3241 (cp_canonicalize_string): Likewise.
3242
f5a29eb0
YQ
32432017-08-09 Yao Qi <yao.qi@linaro.org>
3244
3245 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3246 * regformats/i386/amd64-avx-avx512.dat: Remove.
3247 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3248 * regformats/i386/amd64-avx-mpx.dat:Remove.
3249 * regformats/i386/amd64-avx.dat: Remove.
3250 * regformats/i386/amd64-mpx.dat: Remove.
3251 * regformats/i386/i386-avx-avx512.dat: Remove.
3252 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3253 * regformats/i386/i386-avx-mpx.dat: Remove.
3254 * regformats/i386/i386-mmx.dat: Remove.
3255 * regformats/i386/i386-mpx.dat: Remove.
3256
57757c2f
YQ
32572017-08-09 Yao Qi <yao.qi@linaro.org>
3258
3259 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3260 * amd64-tdep.c: Don't include features/i386/x32*.c.
3261 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3262 functions.
3263 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3264 and i386/x32-avx-avx512.
3265 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3266 and i386/x32.xml.
3267 * features/i386/x32-avx-avx512.c: Removed.
3268 * features/i386/x32-avx-avx512.xml: Removed.
3269 * features/i386/x32-avx.c: Removed.
3270 * features/i386/x32-avx.xml: Removed.
3271 * features/i386/x32.c: Removed.
3272 * features/i386/x32.xml: Removed.
3273 * regformats/i386/x32-avx-avx512.dat: Removed.
3274 * regformats/i386/x32-avx.dat: Removed.
3275 * regformats/i386/x32.dat: Removed.
3276
ba7b109b
MR
32772017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3278
3279 PR breakpoints/21886
3280 * mem-break.c (default_memory_insert_breakpoint): Use
3281 `->placed_address' rather than `->reqstd_address' for the
3282 breakpoint location.
3283
e347efc3
MR
32842017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3285
3286 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3287 assertions.
3288
0dba2a6c
MR
32892017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3290
3291 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3292 a union of `tdep_info', `tdesc_data' and `id'.
3293 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3294 rather than `info.tdep_info'.
3295 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3296 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3297 * i386-tdep.c (i386_gdbarch_init): Likewise.
3298 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3299 * mips-tdep.c (mips_gdbarch_init): Likewise.
3300 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3301 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3302 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3303 `info.tdep_info'.
3304 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3305 `info.tdep_info'.
3306 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3307 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3308 `info.tdep_info'.
3309 * spu-tdep.c (spu_gdbarch_init): Likewise.
3310 * gdbarch.h: Regenerate.
3311
16eb6b2d
LS
33122017-08-07 Leszek Swirski <leszeks@google.com>
3313
7b005726 3314 PR symtab/20899
16eb6b2d
LS
3315 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3316
74cbb09e
SM
33172017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3318
3319 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3320 (gdbsim_open): Rename gdb_argv args object to argv.
3321
ee0c3293
TT
33222017-08-05 Tom Tromey <tom@tromey.com>
3323
3324 * compile/compile-object-load.c (compile_object_load): Use
3325 gdb::unique_xmalloc_ptr.
3326 * cli/cli-dump.c (scan_filename): Rename from
3327 scan_filename_with_cleanup. Change return type.
3328 (scan_expression): Rename from scan_expression_with_cleanup.
3329 Change return type.
3330 (dump_memory_to_file, dump_value_to_file, restore_command):
3331 Use gdb::unique_xmalloc_ptr. Update.
3332 * cli/cli-cmds.c (find_and_open_script): Use
3333 gdb::unique_xmalloc_ptr.
3334 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3335 * symmisc.c (maintenance_print_symbols)
3336 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3337 * symfile.c (symfile_bfd_open, generic_load)
3338 (add_symbol_file_command, remove_symbol_file_command): Use
3339 gdb::unique_xmalloc_ptr.
3340 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3341 * psymtab.c (maintenance_print_psymbols): Use
3342 gdb::unique_xmalloc_ptr.
3343 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3344 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3345 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3346 (reload_shared_libraries_1): Likewise.
3347
3232fabd
TT
33482017-08-05 Tom Tromey <tom@tromey.com>
3349
3350 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3351 (rust_op_vector, rust_set_vector): New typedefs.
3352 (current_parser): New global.
3353 (work_obstack): Change to pointer type. Update all users.
3354 (rust_ast, pstate): Remove globals.
3355 (struct rust_parser): New.
3356 (%union) <params, field_inits>: Change type.
3357 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3358 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3359 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3360 (convert_params_to_types, convert_params_to_expression): Change
3361 type of "params".
3362 (ast_string): Change type of "fields".
3363 (rust_parse): Make a rust_parser. Remove cleanups.
3364 (rust_lex_tests): Make and install an auto_obstack.
3365
f02fd774
YQ
33662017-08-04 Yao Qi <yao.qi@linaro.org>
3367
3368 * configure.srv (ipa_x32_linux_regobj): New.
3369 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3370 instead of X86_TDESC_AVX512.
3371 (initialize_low_tracepoint): Call
3372 init_registers_x32_avx_avx512_linux.
3373
91975afd
YQ
33742017-08-04 Yao Qi <yao.qi@linaro.org>
3375
3376 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3377
2331fa3a
RK
33782017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3379
3380 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3381
744e4fe1
TT
33822017-08-03 Tom Tromey <tom@tromey.com>
3383
3384 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3385 Remove.
3386 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3387
1c034b67
TT
33882017-08-03 Tom Tromey <tom@tromey.com>
3389
3390 * python/py-param.c (compute_enum_values): Use gdb_argv.
3391
773a1edc
TT
33922017-08-03 Tom Tromey <tom@tromey.com>
3393
3394 * utils.h (struct gdb_argv_deleter): New.
3395 (gdb_argv): New class.
3396 * utils.c (gdb_argv::reset): New method.
3397 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3398 * tracefile.c (tsave_command): Use gdb_argv.
3399 * top.c (new_ui_command): Use gdb_argv.
3400 * symmisc.c (maintenance_print_symbols)
3401 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3402 * symfile.c (symbol_file_command, generic_load)
3403 (remove_symbol_file_command): Use gdb_argv.
3404 * stack.c (backtrace_command): Use gdb_argv.
3405 * source.c (add_path, show_substitute_path_command)
3406 (unset_substitute_path_command, set_substitute_path_command):
3407 Use gdb_argv.
3408 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3409 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3410 * remote.c (extended_remote_run, remote_put_command)
3411 (remote_get_command, remote_delete_command): Use gdb_argv.
3412 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3413 (gdbsim_open): Use gdb_argv.
3414 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3415 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3416 * procfs.c (procfs_info_proc): Use gdb_argv.
3417 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3418 * infrun.c (handle_command): Use gdb_argv.
3419 * inferior.c (add_inferior_command, clone_inferior_command):
3420 Use gdb_argv.
3421 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
3422 * exec.c (exec_file_command): Use gdb_argv.
3423 * cli/cli-cmds.c (alias_command): Use gdb_argv.
3424 * compile/compile.c (build_argc_argv): Use gdb_argv.
3425
0d50bde3
TT
34262017-08-03 Tom Tromey <tom@tromey.com>
3427
3428 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
3429
7f968c89
TT
34302017-08-03 Tom Tromey <tom@tromey.com>
3431
3432 * python/python.c (compute_python_string): Return std::string.
3433 (gdbpy_eval_from_control_command): Update.
3434 (do_start_initialization): Use std::string.
3435 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
3436 xstrprintf.
3437 * python/py-breakpoint.c (local_setattro): Use string_printf, not
3438 xstrprintf.
3439
3c9ebddd
TT
34402017-08-03 Tom Tromey <tom@tromey.com>
3441
3442 * top.h (do_restore_instream_cleanup): Remove.
3443 * top.c (do_restore_instream_cleanup): Remove.
3444 (read_command_file): Use scoped_restore.
3445 * cli/cli-script.c (execute_user_command): Use scoped_restore.
3446
b51b225e
TT
34472017-08-03 Tom Tromey <tom@tromey.com>
3448
3449 * cli/cli-script.c (execute_user_command)
3450 (execute_control_command): Use scoped_restore.
3451
ac991630
TT
34522017-08-03 Tom Tromey <tom@tromey.com>
3453
3454 * cli/cli-script.c (do_restore_user_call_depth): Remove.
3455 (execute_user_command): Remove user_call_depth; use
3456 user_args_stack's size instead.
3457
898e0c8e
TT
34582017-08-03 Tom Tromey <tom@tromey.com>
3459
3460 * top.h (in_user_command): Remove.
3461 * top.c (in_user_command): Remove.
3462 * cli/cli-script.c (do_restore_user_call_depth)
3463 (execute_user_command): Update.
3464
26fcd5d7
TT
34652017-08-03 Tom Tromey <tom@tromey.com>
3466
3467 * valops.c (search_struct_method): Use gdb::byte_vector.
3468 * valarith.c (value_concat): Use std::vector.
3469 * target.c (memory_xfer_partial): Use gdb::byte_vector.
3470 (simple_search_memory): Likewise.
3471 * printcmd.c (find_string_backward): Use gdb::byte_vector.
3472 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
3473 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
3474 * elfread.c (elf_rel_plt_read): Use std::string.
3475 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
3476 * cli/cli-dump.c (restore_section_callback): Use
3477 gdb::byte_vector.
3478
7c218e6c
TT
34792017-08-03 Tom Tromey <tom@tromey.com>
3480
3481 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
3482
31b68d4a
TT
34832017-08-03 Tom Tromey <tom@tromey.com>
3484
3485 * tui/tui-regs.c (tui_restore_gdbout): Remove.
3486 (tui_register_format): Use scoped_restore.
3487
2ec845e7
TT
34882017-08-03 Tom Tromey <tom@tromey.com>
3489
3490 * reverse.c (exec_direction_default): Remove.
3491 (exec_reverse_once): Use scoped_restore.
3492 * remote.c (restore_remote_timeout): Remove.
3493 (remote_flash_erase, remote_flash_write, remote_flash_done)
3494 (readchar, remote_serial_write): Use scoped_restore.
3495 * cli/cli-script.c (struct source_cleanup_lines_args)
3496 (source_cleanup_lines): Remove.
3497 (script_from_file): Use scoped_restore.
3498 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
3499 (source_command): Use scoped_restore.
3500
b3bc8453
TT
35012017-08-03 Tom Tromey <tom@tromey.com>
3502
3503 * utils.h (make_cleanup_free_so): Remove.
3504 * utils.c (do_free_so, make_cleanup_free_so): Remove.
3505 * solist.h (struct so_deleter): New.
3506 (so_list_up): New typedef.
3507 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
3508
e3ad2841
TT
35092017-08-03 Tom Tromey <tom@tromey.com>
3510
3511 * utils.h (make_cleanup_restore_current_language): Remove.
3512 * utils.c (do_restore_current_language)
3513 (make_cleanup_restore_current_language): Remove.
3514 * parse.c (parse_exp_in_context_1)
3515 (parse_expression_with_language): Use
3516 scoped_restore_current_language.
3517 * mi/mi-main.c (mi_cmd_execute): Use
3518 scoped_restore_current_language.
3519 * language.h (scoped_restore_current_language): New class.
3520
b80cf838
TT
35212017-08-03 Tom Tromey <tom@tromey.com>
3522
3523 * compile/compile.c (cleanup_unlink_file): Remove.
3524 (compile_to_object): Use gdb::unlinker.
3525 (eval_compile_command): Likewise.
3526
fad0444a
TT
35272017-08-03 Tom Tromey <tom@tromey.com>
3528
3529 * utils.h (make_cleanup_fclose): Remove.
3530 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
3531
6e7bc05c
TT
35322017-08-03 Tom Tromey <tom@tromey.com>
3533
3534 * top.c (open_terminal_stream): Return gdb_file_up.
3535 (new_ui_command): Update.
3536
4a45905b
TT
35372017-08-03 Tom Tromey <tom@tromey.com>
3538
3539 * source.c (print_source_lines_base, forward_search_command)
3540 (reverse_search_command): Use gdb_file_up.
3541
7cd06d6e
TT
35422017-08-03 Tom Tromey <tom@tromey.com>
3543
3544 * fbsd-nat.c (fbsd_find_memory_regions): Update.
3545
ed166945
TT
35462017-08-03 Tom Tromey <tom@tromey.com>
3547
3548 * cli/cli-cmds.c (find_and_open_script): Change return type.
3549 Remove "streamp" and "full_path" parameters.
3550 (source_script_with_search): Update.
3551 * auto-load.c (source_script_file): Update.
3552 * cli/cli-cmds.h (find_and_open_script): Change type.
3553 (open_script): New struct.
3554
d419f42d
TT
35552017-08-03 Tom Tromey <tom@tromey.com>
3556
3557 * xml-support.c (xml_fetch_content_from_file): Update.
3558 * ui-file.c (stdio_file::open): Update.
3559 * tracefile-tfile.c (tfile_start): Update.
3560 * remote.c (remote_file_put, remote_file_get): Update.
3561 * nat/linux-procfs.c (linux_proc_get_int)
3562 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
3563 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
3564 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
3565 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
3566 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
3567 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
3568 * linux-nat.c (linux_proc_pending_signals): Update.
3569 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
3570 (file_closer): Remove.
3571 * compile/compile.c (compile_to_object): Update.
3572 * common/filestuff.h (struct gdb_file_deleter): New.
3573 (gdb_file_up): New typedef.
3574 (gdb_fopen_cloexec): Change return type.
3575 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
3576 * cli/cli-dump.c (fopen_with_cleanup): Remove.
3577 (dump_binary_file, restore_binary_file): Update.
3578 * auto-load.c (auto_load_objfile_script_1): Update.
3579
4a2b031d
TT
35802017-08-03 Tom Tromey <tom@tromey.com>
3581
3582 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
3583 (info_static_tracepoint_markers_command): Likewise.
3584 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
3585 * skip.c (skip_info): Use ui_out_emit_table.
3586 * progspace.c (print_program_space): Use ui_out_emit_table.
3587 * osdata.c (info_osdata): Use ui_out_emit_table.
3588 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
3589 ui_out_emit_table.
3590 * linux-thread-db.c (info_auto_load_libthread_db): Use
3591 ui_out_emit_table.
3592 * inferior.c (print_inferior): Use ui_out_emit_table.
3593 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
3594 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
3595 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
3596 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
3597 * ui-out.h (class ui_out_emit_table): New.
3598
a4f320fd
MR
35992017-08-02 Maciej W. Rozycki <macro@imgtec.com>
3600
3601 * mips-tdep.c (mips_fpu_type_str): New function.
3602 (mips_dump_tdep): Call it.
3603
a2f1f308
MR
36042017-08-01 Maciej W. Rozycki <macro@imgtec.com>
3605
3606 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
3607 `->mips_fpu_type'.
3608
7e5ed83b
XR
36092017-07-31 Xavier Roirand <roirand@adacore.com>
3610
3611 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
3612
4c9dc811
XR
36132017-07-27 Xavier Roirand <roirand@adacore.com>
3614
3615 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
3616
27d41eac
YQ
36172017-07-26 Yao Qi <yao.qi@linaro.org>
3618
3619 * cli/cli-cmds.c (maintenancechecklist): New variable.
3620 * gdbcmd.h (maintenancechecklist): Declare it.
3621 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
3622 Call i386_linux_read_description with different masks.
3623 * maint.c (maintenance_check_command): New function.
3624 (_initialize_maint_cmds): Call add_prefix_cmd.
3625 * target-descriptions.c (tdesc_reg): override operator != and ==.
3626 (tdesc_type): Likewise.
3627 (tdesc_feature): Likewise.
3628 (target_desc): Likewise.
3629 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
3630 (maintenance_check_xml_descriptions): New function.
3631 (_initialize_target_descriptions) Add command "xml-descriptions".
3632 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
3633
ea03d0d3
YQ
36342017-07-26 Yao Qi <yao.qi@linaro.org>
3635
3636 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
3637 Include features/i386/32bit-*.c.
3638 (i386_linux_read_description): Generate target description if it
3639 doesn't exist.
3640 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
3641 functions.
3642 * features/i386/32bit-linux.c: Re-generated.
3643 * features/i386/32bit-sse.c: Likewise.
3644 * target-descriptions.c (print_c_feature::visit): Print code to
3645 set register number if needed.
3646 (print_c_feature) <m_next_regnum>: New field.
3647
25aa13e5
YQ
36482017-07-26 Yao Qi <yao.qi@linaro.org>
3649
3650 * features/Makefile (CFILES): Rename with TDESC_CFILES.
3651 (FEATURE_XMLFILES): New.
3652 (FEATURE_CFILES): New.
3653 New rules.
3654 (clean-cfiles): Remove generated c files.
3655 * features/i386/32bit-avx.c: Generated.
3656 * features/i386/32bit-avx512.c: Generated.
3657 * features/i386/32bit-core.c: Generated.
3658 * features/i386/32bit-linux.c: Generated.
3659 * features/i386/32bit-mpx.c: Generated.
3660 * features/i386/32bit-pkeys.c: Generated.
3661 * features/i386/32bit-sse.c: Generated.
3662 * target-descriptions.c: Include algorithm.
3663 (tdesc_element_visitor): Add method visit_end.
3664 (print_c_tdesc): Implement visit_end.
3665 (print_c_tdesc:: m_filename_after_features): Move it to
3666 protected.
3667 (print_c_feature): New class.
3668 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
3669 name starts with "i386/32bit-".
3670
6eb1e6a8
YQ
36712017-07-26 Yao Qi <yao.qi@linaro.org>
3672
3673 * target-descriptions.c (tdesc_element_visitor): New class.
3674 (tdesc_element): New class.
3675 (tdesc_reg): Inherit from tdesc_element.
3676 (tdesc_reg::accept): New function.
3677 (tdesc_type): Inherit from tdesc_element.
3678 (tdesc_type::accept): New function.
3679 (tdesc_feature): Inherit from tdesc_element.
3680 (tdesc_feature::accept): New function.
3681 (target_desc): Inherit from tdesc_element.
3682 (target_desc::target_desc): New.
3683 (target_desc::~target_desc): New.
3684 (target_desc::accept): New.
3685 (allocate_target_description): Use new.
3686 (free_target_description): Use delete.
3687 (print_c_tdesc): New class.
3688 (maint_print_c_tdesc_cmd): Adjust.
3689
3690 * features/aarch64.c: Re-generated.
3691 * features/arc-arcompact.c: Re-generated.
3692 * features/arc-v2.c: Re-generated.
3693 * features/arm/arm-with-iwmmxt.c: Re-generated.
3694 * features/arm/arm-with-m.c: Re-generated.
3695 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
3696 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
3697 * features/arm/arm-with-neon.c: Re-generated.
3698 * features/arm/arm-with-vfpv2.c: Re-generated.
3699 * features/arm/arm-with-vfpv3.c: Re-generated.
3700 * features/i386/amd64-avx-avx512.c: Re-generated.
3701 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
3702 * features/i386/amd64-avx.c: Re-generated.
3703 * features/i386/amd64-avx-linux.c: Re-generated.
3704 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
3705 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
3706 * features/i386/amd64-avx-mpx.c: Re-generated.
3707 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
3708 * features/i386/amd64.c: Re-generated.
3709 * features/i386/amd64-linux.c: Re-generated.
3710 * features/i386/amd64-mpx.c: Re-generated.
3711 * features/i386/amd64-mpx-linux.c: Re-generated.
3712 * features/i386/i386-avx-avx512.c: Re-generated.
3713 * features/i386/i386-avx-avx512-linux.c: Re-generated.
3714 * features/i386/i386-avx.c: Re-generated.
3715 * features/i386/i386-avx-linux.c: Re-generated.
3716 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
3717 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
3718 * features/i386/i386-avx-mpx.c: Re-generated.
3719 * features/i386/i386-avx-mpx-linux.c: Re-generated.
3720 * features/i386/i386.c: Re-generated.
3721 * features/i386/i386-linux.c: Re-generated.
3722 * features/i386/i386-mmx.c: Re-generated.
3723 * features/i386/i386-mmx-linux.c: Re-generated.
3724 * features/i386/i386-mpx.c: Re-generated.
3725 * features/i386/i386-mpx-linux.c: Re-generated.
3726 * features/i386/x32-avx-avx512.c: Re-generated.
3727 * features/i386/x32-avx-avx512-linux.c: Re-generated.
3728 * features/i386/x32-avx.c: Re-generated.
3729 * features/i386/x32-avx-linux.c: Re-generated.
3730 * features/i386/x32.c: Re-generated.
3731 * features/i386/x32-linux.c: Re-generated.
3732 * features/microblaze.c: Re-generated.
3733 * features/microblaze-with-stack-protect.c: Re-generated.
3734 * features/mips64-dsp-linux.c: Re-generated.
3735 * features/mips64-linux.c: Re-generated.
3736 * features/mips-dsp-linux.c: Re-generated.
3737 * features/mips-linux.c: Re-generated.
3738 * features/nds32.c: Re-generated.
3739 * features/nios2.c: Re-generated.
3740 * features/nios2-linux.c: Re-generated.
3741 * features/rs6000/powerpc-32.c: Re-generated.
3742 * features/rs6000/powerpc-32l.c: Re-generated.
3743 * features/rs6000/powerpc-403.c: Re-generated.
3744 * features/rs6000/powerpc-403gc.c : Re-generated.
3745 * features/rs6000/powerpc-405.c: Re-generated.
3746 * features/rs6000/powerpc-505.c: Re-generated.
3747 * features/rs6000/powerpc-601.c: Re-generated.
3748 * features/rs6000/powerpc-602.c: Re-generated.
3749 * features/rs6000/powerpc-603.c: Re-generated.
3750 * features/rs6000/powerpc-604.c: Re-generated.
3751 * features/rs6000/powerpc-64.c: Re-generated.
3752 * features/rs6000/powerpc-64l.c: Re-generated.
3753 * features/rs6000/powerpc-7400.c: Re-generated.
3754 * features/rs6000/powerpc-750.c: Re-generated.
3755 * features/rs6000/powerpc-860.c: Re-generated.
3756 * features/rs6000/powerpc-altivec32.c: Re-generated.
3757 * features/rs6000/powerpc-altivec32l.c: Re-generated.
3758 * features/rs6000/powerpc-altivec64.c: Re-generated.
3759 * features/rs6000/powerpc-altivec64l.c: Re-generated.
3760 * features/rs6000/powerpc-cell32l.c: Re-generated.
3761 * features/rs6000/powerpc-cell64l.c: Re-generated.
3762 * features/rs6000/powerpc-e500.c: Re-generated.
3763 * features/rs6000/powerpc-e500l.c: Re-generated.
3764 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
3765 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
3766 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
3767 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
3768 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
3769 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
3770 * features/rs6000/powerpc-vsx32.c: Re-generated.
3771 * features/rs6000/powerpc-vsx32l.c: Re-generated.
3772 * features/rs6000/powerpc-vsx64.c: Re-generated.
3773 * features/rs6000/powerpc-vsx64l.c: Re-generated.
3774 * features/rs6000/rs6000.c: Re-generated.
3775 * features/s390-linux32.c: Re-generated.
3776 * features/s390-linux32v1.c: Re-generated.
3777 * features/s390-linux32v2.c: Re-generated.
3778 * features/s390-linux64.c: Re-generated.
3779 * features/s390-linux64v1.c: Re-generated.
3780 * features/s390-linux64v2.c: Re-generated.
3781 * features/s390-te-linux64.c: Re-generated.
3782 * features/s390-tevx-linux64.c: Re-generated.
3783 * features/s390-vx-linux64.c: Re-generated.
3784 * features/s390x-linux64.c: Re-generated.
3785 * features/s390x-linux64v1.c: Re-generated.
3786 * features/s390x-linux64v2.c: Re-generated.
3787 * features/s390x-te-linux64.c: Re-generated.
3788 * features/s390x-tevx-linux64.c: Re-generated.
3789 * features/s390x-vx-linux64.c: Re-generated.
3790 * features/sparc/sparc32-solaris.c: Re-generated.
3791 * features/sparc/sparc64-solaris.c: Re-generated.
3792 * features/tic6x-c62x.c: Re-generated.
3793 * features/tic6x-c62x-linux.c: Re-generated.
3794 * features/tic6x-c64x.c: Re-generated.
3795 * features/tic6x-c64x-linux.c: Re-generated.
3796 * features/tic6x-c64xp.c: Re-generated.
3797 * features/tic6x-c64xp-linux.c: Re-generated.
3798
35b4818d
YQ
37992017-07-26 Yao Qi <yao.qi@linaro.org>
3800
3801 * i386-linux-tdep.c (i386_linux_read_description): New function.
3802 (i386_linux_core_read_description): Call
3803 i386_linux_read_description.
3804 * i386-linux-tdep.h (i386_linux_read_description): Declare.
3805 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
3806 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
3807 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
3808 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
3809 * x86-linux-nat.c (x86_linux_read_description): Call
3810 i386_linux_read_description.
3811
8e2141c6
YQ
38122017-07-26 Yao Qi <yao.qi@linaro.org>
3813
3814 * NEWS: Mention it.
3815 * features/Makefile (%.c: %.xml): Pass the xml file name to
3816 command "maint print c-tdesc".
3817 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
3818 name from 'arg'.
3819
b468ff4c
YQ
38202017-07-26 Yao Qi <yao.qi@linaro.org>
3821
3822 * target-descriptions.c (target_desc): Add ctor and dtor. Do
3823 in-class initialization.
3824 (tdesc_create_feature): Call new instead of XCNEW.
3825 (free_target_description): Ue delete.
3826
b9c0e1b4
JB
38272017-07-25 John Baldwin <jhb@FreeBSD.org>
3828
3829 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
3830
a04b5337
YQ
38312017-07-25 Yao Qi <yao.qi@linaro.org>
3832
3833 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
3834 constant.
3835 (amd64_x32_init_abi): Likewise.
3836 * amd64-tdep.h (amd64_init_abi): Update declaration.
3837 (amd64_x32_init_abi): Likewise.
3838
02ad7fc2
YQ
38392017-07-25 Yao Qi <yao.qi@linaro.org>
3840
3841 PR tdep/21717
3842 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
3843 condition for FPSCR.
3844 (arm_linux_store_inferior_registers): Likewise.
3845
b6f48cb0
TT
38462017-07-22 Tom Tromey <tom@tromey.com>
3847
3848 * break-catch-syscall.c (struct catch_syscall_inferior_data)
3849 <syscalls_counts>: Now a std::vector.
3850 (get_catch_syscall_inferior_data): Use "new".
3851 (catch_syscall_inferior_data_cleanup): Use "delete".
3852 (insert_catch_syscall, remove_catch_syscall)
3853 (clear_syscall_counts): Update.
3854
e12c9b7a
TT
38552017-07-22 Tom Tromey <tom@tromey.com>
3856
3857 * break-catch-syscall.c (syscall_catchpoint)
3858 <syscalls_to_be_caught>: Now a std::vector<int>
3859 (~syscall_catchpoint): Remove.
3860 (insert_catch_syscall, remove_catch_syscall)
3861 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
3862 (print_mention_catch_syscall, print_recreate_catch_syscall):
3863 Update.
3864 (create_syscall_event_catchpoint): Change type of "filter"
3865 parameter.
3866 (catch_syscall_split_args): Return a std::vector.
3867 (catch_syscall_command_1, catching_syscall_number_1): Update.
3868
4fa8aeac
TT
38692017-07-22 Tom Tromey <tom@tromey.com>
3870
3871 * break-catch-throw.c (struct exception_catchpoint)
3872 <exception_rx>: Now a std::string.
3873 (~exception_catchpoint): Remove.
3874 (print_one_detail_exception_catchpoint): Update.
3875 (handle_gnu_v3_exceptions): Change type of except_rx.
3876 (extract_exception_regexp): Return a std::string.
3877 (catch_exception_command_1): Update.
3878
f746a154
TT
38792017-07-22 Tom Tromey <tom@tromey.com>
3880
3881 * break-catch-sig.c (gdb_signal_type): Remove typedef.
3882 (struct signal_catchpoint) <signals_to_be_caught>: Now a
3883 std::vector.
3884 <catch_all>: Now a bool.
3885 (~signal_catchpoint): Remove.
3886 (signal_catchpoint_insert_location)
3887 (signal_catchpoint_remove_location)
3888 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
3889 (signal_catchpoint_print_mention)
3890 (signal_catchpoint_print_recreate)
3891 (signal_catchpoint_explains_signal): Update.
3892 (create_signal_catchpoint): Change type of "filter" and
3893 "catch_all".
3894 (catch_signal_split_args): Return a std::vector. Change type of
3895 "catch_all".
3896 (catch_signal_command): Update.
3897
47e77640
PA
38982017-07-20 Pedro Alves <palves@redhat.com>
3899
3900 * ada-lang.c (ada_language_defn): Make extern.
3901 (_initialize_ada_language): Remove add_language call.
3902 * c-lang.c (c_language_defn, cplus_language_defn)
3903 (asm_language_defn, minimal_language_defn): Make extern.
3904 (_initialize_c_language): Delete.
3905 * completer.c (compare_cstrings): Delete, moved to utils.h.
3906 * d-lang.c (d_language_defn): Make extern.
3907 (_initialize_d_language): Remove add_language calls.
3908 * defs.h (enum language): Add comment.
3909 * f-lang.c (f_language_defn): Make extern.
3910 (_initialize_f_language): Remove add_language call.
3911 * go-lang.c (go_language_defn): Make extern.
3912 (_initialize_go_language): Remove add_language call.
3913 * language.c: Include <algorithm>.
3914 (languages): Redefine as const array.
3915 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
3916 (set_language_command): Handle "local". Use for-range loop.
3917 (set_language): Remove loop.
3918 (language_enum): Rewrite.
3919 (language_def, language_str): Remove loops.
3920 (add_language): Delete.
3921 (add_set_language_command): New, based on add_languages.
3922 (skip_language_trampoline): Adjust.
3923 (local_language_defn): Delete.
3924 (language_gdbarch_post_init): Adjust.
3925 (_initialize_language): Remove add_language calls. Call
3926 add_set_language_command.
3927 * language.h (add_language): Delete.
3928 (auto_language_defn)
3929 (unknown_language_defn, minimal_language_defn, ada_language_defn)
3930 (asm_language_defn, c_language_defn, cplus_language_defn)
3931 (d_language_defn, f_language_defn, go_language_defn)
3932 (m2_language_defn, objc_language_defn, opencl_language_defn)
3933 (pascal_language_defn, rust_language_defn): Declare.
3934 * m2-lang.c (m2_language_defn): Make extern.
3935 (_initialize_m2_language): Remove add_language call.
3936 * objc-lang.c (objc_language_defn): Make extern.
3937 (_initialize_objc_language): Remove add_language call.
3938 * opencl-lang.c (opencl_language_defn): Make extern.
3939 (_initialize_opencl_language): Remove add_language call.
3940 * p-lang.c (pascal_language_defn): Make extern.
3941 (_initialize_pascal_language): Delete.
3942 * rust-lang.c (rust_language_defn): Make extern.
3943 (_initialize_rust_language): Delete.
3944 * utils.h (compare_cstrings): New static inline function.
3945
edb0c9cb
PA
39462017-07-20 Pedro Alves <palves@redhat.com>
3947
3948 * ada-lang.c (ada_to_fixed_type_1): Adjust.
3949 (get_var_value): Constify parameters.
3950 (get_int_var_value): Change prototype.
3951 (to_fixed_range_type): Adjust.
3952 * ada-lang.h (get_int_var_value): Change prototype.
3953
a778f165
PA
39542017-07-20 Pedro Alves <palves@redhat.com>
3955
3956 * dwarf2read.c (dw2_lookup_symbol): Use
3957 SYMBOL_MATCHES_SEARCH_NAME.
3958 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
3959
42edd901
PA
39602017-07-20 Pedro Alves <palves@redhat.com>
3961
3962 * block.c (block_iter_name_step, block_iter_name_first)
3963 (block_iter_name_next): Delete.
3964 (block_lookup_symbol_primary): Adjust to use
3965 dict_iter_match_first/dict_iter_match_next.
3966 * block.h (block_iter_name_first, block_iter_name_next): Delete
3967 declarations.
3968 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
3969 dict_iter_match_first/dict_iter_match_next.
3970
cf325299
PA
39712017-07-20 Pedro Alves <palves@redhat.com>
3972
3973 * cp-support.c (cp_find_first_component_aux): Add missing case for
3974 end of string.
3975
c5ed0576
DB
39762017-07-18 David Blaikie <dblaikie@gmail.com>
3977
3978 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
3979 of dwo_cu's dwo_file.
3980
27841e76
YQ
39812017-07-18 Yao Qi <yao.qi@linaro.org>
3982
3983 * remote.c (store_registers_using_G): Remove one line comment.
3984
cfb7e58b
YQ
39852017-07-18 Yao Qi <yao.qi@linaro.org>
3986
3987 * regcache.c (regcache_cpy): Simplify it.
3988 (regcache::cpy_no_passthrough): Remove it.
3989 * regcache.h (cpy_no_passthrough): Remove it.
3990 (regcache_dup, regcache_cpy): Update comments.
3991
386535dd
PA
39922017-07-18 Pedro Alves <palves@redhat.com>
3993
3994 * remote-sim.c (sim_command_completer): Adjust to work with a
3995 completion_tracker instead of a VEC.
3996
c45ec17c
PA
39972017-07-17 Pedro Alves <palves@redhat.com>
3998
3999 * completer.c (complete_source_filenames): New function.
4000 (complete_address_and_linespec_locations): New function.
4001 (location_completer): Use complete_address_and_linespec_locations.
4002 (completion_tracker::build_completion_result): Honor the tracker's
4003 request to suppress append.
4004 * completer.h (completion_tracker::suppress_append_ws)
4005 (completion_tracker::set_suppress_append_ws): New methods.
4006 (completion_tracker::m_suppress_append_ws): New field.
4007 (complete_source_filenames): New declaration.
4008 * linespec.c (linespec_complete_what): New.
4009 (struct ls_parser) <complete_what, completion_word,
4010 completion_quote_char, completion_quote_end, completion_tracker>:
4011 New fields.
4012 (string_find_incomplete_keyword_at_end): New.
4013 (linespec_lexer_lex_string): Record quote char. If in completion
4014 mode, don't throw.
4015 (linespec_lexer_consume_token): Advance the completion word point.
4016 (linespec_lexer_peek_token): Save/restore completion info.
4017 (save_stream_and_consume_token): New.
4018 (set_completion_after_number): New.
4019 (linespec_parse_basic): Set what to complete next depending on
4020 token. Handle function and label completions specially.
4021 (parse_linespec): Disable objc shortcut in completion mode. Set
4022 what to complete next depending on token type. Skip keyword if in
4023 completion mode.
4024 (complete_linespec_component, linespec_complete): New.
4025 * linespec.h (linespec_complete): Declare.
4026
be966d42
PA
40272017-07-17 Pedro Alves <palves@redhat.com>
4028
4029 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4030 Handle 'operator<' / 'operator<<'.
4031
a2459270
PA
40322017-07-17 Pedro Alves <palves@redhat.com>
4033
4034 * completer.c (collect_explicit_location_matches): Handle
4035 MATCH_LABEL.
4036 (convert_explicit_location_to_linespec): New, factored out from
4037 ...
4038 (convert_explicit_location_to_sals): ... this.
4039 (complete_label): New.
4040 (linespec_complete_label, find_label_symbols_in_block): New.
4041 (find_label_symbols): Add completion_mode parameter and adjust to
4042 call find_label_symbols_in_block.
4043 * linespec.h (linespec_complete_label): Declare.
4044
c6756f62
PA
40452017-07-17 Pedro Alves <palves@redhat.com>
4046
4047 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4048 complete_symbol_mode parameter.
4049 * cli/cli-cmds.c (complete_command): Get the completion result out
4050 of the handle_brkchars tracker if used a custom word point.
4051 * completer.c: Include "linespec.h".
4052 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4053 (advance_to_expression_complete_word_point): New.
4054 (completion_tracker::completes_to_completion_word): New.
4055 (complete_files_symbols): Pass down
4056 complete_symbol_mode::EXPRESSION.
4057 (explicit_options, probe_options): New.
4058 (collect_explicit_location_matches): Complete on the
4059 explictit_loc->foo instead of word. Use
4060 linespec_complete_function. Handle MATCH_LINE. Handle offering
4061 keyword and options completions.
4062 (backup_text_ptr): Delete.
4063 (skip_keyword): New.
4064 (complete_explicit_location): Remove 'word' parameter. Add
4065 language, quoted_arg_start and quoted_arg_end parameters.
4066 Rewrite, parsing left to right.
4067 (location_completer): Rewrite.
4068 (location_completer_handle_brkchars): New function.
4069 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4070 (enum complete_line_internal_reason): Adjust comments.
4071 (completion_tracker::discard_completions): New.
4072 (completer_handle_brkchars_func_for_completer): Handle
4073 location_completer.
4074 (gdb_custom_word_point_brkchars)
4075 (gdb_org_rl_basic_quote_characters): New.
4076 (gdb_completion_word_break_characters_throw)
4077 (completion_find_completion_word): Handle trackers that use a
4078 custom word point.
4079 (completion_tracker::advance_custom_word_point_by): New.
4080 (completion_tracker::build_completion_result): Don't rely on
4081 readline appending the quote char.
4082 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4083 use a custom word point.
4084 (gdb_rl_attempted_completion_function): Restore
4085 rl_basic_quote_characters.
4086 * completer.h (class completion_tracker): Extend intro comment.
4087 (completion_tracker::set_quote_char)
4088 (completion_tracker::quote_char)
4089 (completion_tracker::set_use_custom_word_point)
4090 (completion_tracker::use_custom_word_point)
4091 (completion_tracker::custom_word_point)
4092 (completion_tracker::set_custom_word_point)
4093 (completion_tracker::advance_custom_word_point_by)
4094 (completion_tracker::completes_to_completion_word)
4095 (completion_tracker::discard_completions): New methods.
4096 (completion_tracker::m_quote_char)
4097 (completion_tracker::m_use_custom_word_point)
4098 (completion_tracker::m_custom_word_point): New fields.
4099 (advance_to_expression_complete_word_point): Declare.
4100 * f-lang.c (f_collect_symbol_completion_matches): Add
4101 complete_symbol_mode parameter.
4102 * language.h (struct language_defn)
4103 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4104 parameter.
4105 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4106 (linespec_complete_function): New function.
4107 (linespec_lexer_lex_keyword): Adjust.
4108 * linespec.h (linespec_keywords, linespec_complete_function): New
4109 declarations.
4110 * location.c (find_end_quote): New function.
4111 (explicit_location_lex_one): Add explicit_completion_info
4112 parameter. Save quoting info. Don't throw if being called for
4113 completion. Don't handle Ada operators here.
4114 (is_cp_operator, skip_op_false_positives, first_of)
4115 (explicit_location_lex_one_function): New function.
4116 (string_to_explicit_location): Replace 'dont_throw' parameter with
4117 an explicit_completion_info pointer parameter. Handle it. Don't
4118 use explicit_location_lex_one to lex function names. Use
4119 explicit_location_lex_one_function instead.
4120 * location.h (struct explicit_completion_info): New.
4121 (string_to_explicit_location): Replace 'dont_throw' parameter with
4122 an explicit_completion_info pointer parameter.
4123 * symtab.c (default_collect_symbol_completion_matches_break_on):
4124 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4125 (default_collect_symbol_completion_matches)
4126 (collect_symbol_completion_matches): Add complete_symbol_mode
4127 parameter.
4128 (collect_symbol_completion_matches_type): Pass down
4129 complete_symbol_mode::EXPRESSION.
4130 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4131 parameter. Handle LINESPEC mode.
4132 * symtab.h (complete_symbol_mode): New.
4133 (default_collect_symbol_completion_matches_break_on)
4134 (default_collect_symbol_completion_matches)
4135 (collect_symbol_completion_matches)
4136 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4137 parameter.
4138
1d550c82
PA
41392017-07-17 Pedro Alves <palves@redhat.com>
4140
4141 * utils.c (enum class strncmp_iw_mode): New.
4142 (strcmp_iw): Rename to ...
4143 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4144 parameters. Handle them.
4145 (strncmp_iw): New.
4146 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4147 * utils.h (strncmp_iw): Declare.
4148 (strcmp_iw): Move describing comments here.
4149
8090b426
PA
41502017-07-17 Pedro Alves <palves@redhat.com>
4151
4152 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4153 CP_OPERATOR_STR.
4154 * c-typeprint.c (is_type_conversion_operator): Use
4155 CP_OPERATOR_STR.
4156 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4157 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4158 CP_OPERATOR_LEN.
4159 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4160 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4161 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4162 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4163 CP_OPERATOR_STR.
4164 * location.c: Include "cp-support.h".
4165 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4166 CP_OPERATOR_STR.
4167 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4168 CP_OPERATOR_LEN.
4169
6a2c1b87
PA
41702017-07-17 Pedro Alves <palves@redhat.com>
4171
4172 * cli/cli-cmds.c (complete_command): Use a completion tracker
4173 along with completion_find_completion_word for handle_brkchars
4174 phase.
4175 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4176 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4177 (struct gdb_rl_completion_word_info): New.
4178 (gdb_rl_find_completion_word): New.
4179 (completion_find_completion_word): New.
4180 * completer.h (completion_find_completion_word): Declare.
4181
eb3ff9a5
PA
41822017-07-17 Pedro Alves <palves@redhat.com>
4183
4184 * ada-lang.c (symbol_completion_match): Adjust comments.
4185 (symbol_completion_add): Replace vector parameter with
4186 completion_tracker parameter. Use it.
4187 (ada_make_symbol_completion_list): Rename to...
4188 (ada_collect_symbol_completion_matches): ... this. Add
4189 completion_tracker parameter and use it.
4190 (ada_language_defn): Adjust.
4191 * break-catch-syscall.c (catch_syscall_completer): Adjust
4192 prototype and work with completion_tracker instead of VEC.
4193 * breakpoint.c (condition_completer): Adjust prototype and work
4194 with completion_tracker instead of VEC.
4195 * c-lang.c (c_language_defn, cplus_language_defn)
4196 (asm_language_defn, minimal_language_defn): Adjust to renames.
4197 * cli/cli-cmds.c (complete_command): Rework using
4198 completion_tracker. Catch exceptions when completing.
4199 * cli/cli-decode.c (integer_unlimited_completer)
4200 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4201 with completion_tracker instead of VEC.
4202 * command.h (struct completion_tracker): Forward declare.
4203 (completer_ftype, completer_handle_brkchars_ftype): Change
4204 types.
4205 (complete_on_cmdlist, complete_on_enum): Adjust.
4206 * completer.c: Include <algorithm>.
4207 (struct gdb_completer_state): New.
4208 (current_completion): New global.
4209 (readline_line_completion_function): Delete.
4210 (noop_completer, filename_completer)
4211 (filename_completer_handle_brkchars, complete_files_symbols)
4212 (linespec_location_completer): Adjust to work with a
4213 completion_tracker instead of a VEC.
4214 (string_or_empty): New.
4215 (collect_explicit_location_matches): Adjust to work with a
4216 completion_tracker instead of a VEC.
4217 (explicit_location_completer): Rename to ...
4218 (complete_explicit_location): ... this and adjust to work with a
4219 completion_tracker instead of a VEC.
4220 (location_completer): Adjust to work with a completion_tracker
4221 instead of a VEC.
4222 (add_struct_fields): Adjust to work with a completion_list instead
4223 of VEC.
4224 (expression_completer): Rename to ...
4225 (complete_expression): ... this and adjust to work with a
4226 completion_tracker instead of a VEC. Use complete_files_symbols.
4227 (expression_completer): Reimplement on top of complete_expression.
4228 (symbol_completer): Adjust to work with a completion_tracker
4229 instead of a VEC.
4230 (enum complete_line_internal_reason): Add describing comments.
4231 (complete_line_internal_normal_command): Adjust to work with a
4232 completion_tracker instead of a VEC.
4233 (complete_line_internal): Rename to ...
4234 (complete_line_internal_1): ... this and adjust to work with a
4235 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4236 handle_brkchars phase.
4237 (new_completion_tracker): Delete.
4238 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4239 complete_line_internal_1.
4240 (free_completion_tracker): Delete.
4241 (INITIAL_COMPLETION_HTAB_SIZE): New.
4242 (completion_tracker::completion_tracker)
4243 (completion_tracker::~completion_tracker): New.
4244 (maybe_add_completion): Delete.
4245 (completion_tracker::maybe_add_completion)
4246 (completion_tracker::add_completion)
4247 (completion_tracker::add_completions): New.
4248 (throw_max_completions_reached_error): Delete.
4249 (complete_line): Adjust to work with a completion_tracker instead
4250 of a VEC. Don't create a completion_tracker_t or check for max
4251 completions here.
4252 (command_completer, command_completer_handle_brkchars)
4253 (signal_completer, reg_or_group_completer_1)
4254 (reg_or_group_completer, default_completer_handle_brkchars):
4255 Adjust to work with a completion_tracker.
4256 (gdb_completion_word_break_characters_throw): New.
4257 (gdb_completion_word_break_characters): Reimplement.
4258 (line_completion_function): Delete.
4259 (completion_tracker::recompute_lowest_common_denominator)
4260 (expand_preserving_ws)
4261 (completion_tracker::build_completion_result)
4262 (completion_result::completion_result)
4263 (completion_result::completion_result)
4264 (completion_result::~completion_result)
4265 (completion_result::completion_result)
4266 (completion_result::release_match_list, compare_cstrings)
4267 (completion_result::sort_match_list)
4268 (completion_result::reset_match_list)
4269 (gdb_rl_attempted_completion_function_throw)
4270 (gdb_rl_attempted_completion_function): New.
4271 * completer.h (completion_list, struct completion_result)
4272 (class completion_tracker): New.
4273 (complete_line): Add completion_tracker parameter.
4274 (readline_line_completion_function): Delete.
4275 (gdb_rl_attempted_completion_function): New.
4276 (noop_completer, filename_completer, expression_completer)
4277 (location_completer, symbol_completer, command_completer)
4278 (signal_completer, reg_or_group_completer): Update prototypes.
4279 (completion_tracker_t, new_completion_tracker)
4280 (make_cleanup_free_completion_tracker): Delete.
4281 (enum maybe_add_completion_enum): Delete.
4282 (maybe_add_completion): Delete.
4283 (throw_max_completions_reached_error): Delete.
4284 * corefile.c (complete_set_gnutarget): Adjust to work with a
4285 completion_tracker instead of a VEC.
4286 * cp-abi.c (cp_abi_completer): Adjust to work with a
4287 completion_tracker instead of a VEC.
4288 * d-lang.c (d_language_defn): Adjust.
4289 * disasm.c (disassembler_options_completer): Adjust to work with a
4290 completion_tracker instead of a VEC.
4291 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4292 (f_collect_symbol_completion_matches): ... this. Adjust to work
4293 with a completion_tracker instead of a VEC.
4294 (f_language_defn): Adjust.
4295 * go-lang.c (go_language_defn): Adjust.
4296 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4297 Adjust to work with a completion_tracker instead of a VEC.
4298 * infrun.c (handle_completer): Likewise.
4299 * interps.c (interpreter_completer): Likewise.
4300 * interps.h (interpreter_completer): Likewise.
4301 * language.c (unknown_language_defn, auto_language_defn)
4302 (local_language_defn): Adjust.
4303 * language.h (language_defn::la_make_symbol_completion_list):
4304 Rename to ...
4305 (language_defn::la_collect_symbol_completion_matches): ... this
4306 and adjust to work with a completion_tracker instead of a VEC.
4307 * m2-lang.c (m2_language_defn): Adjust.
4308 * objc-lang.c (objc_language_defn): Adjust.
4309 * opencl-lang.c (opencl_language_defn): Adjust.
4310 * p-lang.c (pascal_language_defn): Adjust.
4311 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4312 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4313 with a completion_tracker.
4314 * rust-lang.c (rust_language_defn): Adjust.
4315 * symtab.c (free_completion_list, do_free_completion_list)
4316 (return_val, completion_tracker): Delete.
4317 (completion_list_add_name, completion_list_add_symbol)
4318 (completion_list_add_msymbol, completion_list_objc_symbol)
4319 (completion_list_add_fields, add_symtab_completions): Add
4320 completion_tracker parameter and use it.
4321 (default_make_symbol_completion_list_break_on_1): Rename to...
4322 (default_collect_symbol_completion_matches_break_on): ... this.
4323 Add completion_tracker parameter and use it instead of allocating
4324 a completion tracker here.
4325 (default_make_symbol_completion_list_break_on): Delete old
4326 implementation.
4327 (default_make_symbol_completion_list): Delete.
4328 (default_collect_symbol_completion_matches): New.
4329 (make_symbol_completion_list): Delete.
4330 (collect_symbol_completion_matches): New.
4331 (make_symbol_completion_type): Rename to ...
4332 (collect_symbol_completion_matches_type): ... this. Add
4333 completion_tracker parameter and use it instead of VEC.
4334 (make_file_symbol_completion_list_1): Rename to...
4335 (collect_file_symbol_completion_matches): ... this. Add
4336 completion_tracker parameter and use it instead of VEC.
4337 (make_file_symbol_completion_list): Delete.
4338 (add_filename_to_list): Use completion_list instead of a VEC.
4339 (add_partial_filename_data::list): Now a completion_list.
4340 (make_source_files_completion_list): Work with a completion_list
4341 instead of a VEC.
4342 * symtab.h: Include "completer.h".
4343 (default_make_symbol_completion_list_break_on)
4344 (default_make_symbol_completion_list, make_symbol_completion_list)
4345 (make_symbol_completion_type, make_file_symbol_completion_list)
4346 (make_source_files_completion_list): Delete.
4347 (default_collect_symbol_completion_matches_break_on)
4348 (default_collect_symbol_completion_matches)
4349 (collect_symbol_completion_matches)
4350 (collect_symbol_completion_matches_type)
4351 (collect_file_symbol_completion_matches)
4352 (make_source_files_completion_list): New.
4353 * top.c (init_main): Don't install a rl_completion_entry_function
4354 hook. Install a rl_attempted_completion_function hook instead.
4355 * tui/tui-layout.c (layout_completer): Adjust to work with a
4356 completion_tracker.
4357 * tui/tui-regs.c (tui_reggroup_completer):
4358 * tui/tui-win.c (window_name_completer, focus_completer)
4359 (winheight_completer): Adjust to work with a completion_tracker.
4360 * value.c: Include "completer.h".
4361 (complete_internalvar): Adjust to work with a completion_tracker.
4362 * value.h (complete_internalvar): Likewise.
4363
6e1dbf8c
PA
43642017-07-17 Pedro Alves <palves@redhat.com>
4365
4366 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4367 renames.
4368 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4369 comments to completer_ftype's declaration.
4370 <completer_handle_brkchars>: Change type to
4371 completer_handle_brkchars_ftype.
4372 * command.h (completer_ftype): Add describing comment and give
4373 names to parameters.
4374 (completer_ftype_void): Rename to ...
4375 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4376 (set_cmd_completer_handle_brkchars): Adjust.
4377 * completer.c (filename_completer_handle_brkchars): New function.
4378 (complete_line_internal_normal_command): New function, factored
4379 out from ...
4380 (complete_line_internal): ... here.
4381 (command_completer_handle_brkchars)
4382 (default_completer_handle_brkchars)
4383 (completer_handle_brkchars_func_for_completer): New functions.
4384 * completer.h (set_gdb_completion_word_break_characters): Delete
4385 declaration.
4386 (completer_handle_brkchars_func_for_completer): New declaration.
4387 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4388 completer_handle_brkchars_func_for_completer.
4389
78b13106
PA
43902017-07-17 Pedro Alves <palves@redhat.com>
4391
4392 * completer.c (symbol_completer): New function, based on
4393 make_symbol_completion_list_fn.
4394 * completer.h (symbol_completer): New declaration.
4395 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4396 * python/py-cmd.c (completers): Adjust.
4397 * symtab.c (make_symbol_completion_list_fn): Delete.
4398 * symtab.h (make_symbol_completion_list_fn): Delete.
4399 * cli/cli-decode.c (add_cmd): Adjust.
4400
bbf2f4df
PA
44012017-07-17 Pedro Alves <palves@redhat.com>
4402
4403 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4404 * dwarf2read.c: Include "filename-seen-cache.h".
4405 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4406 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4407 * filename-seen-cache.c: New file.
4408 * filename-seen-cache.h: New file.
4409 * symtab.c: Include "filename-seen-cache.h".
4410 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4411 (create_filename_seen_cache, clear_filename_seen_cache)
4412 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4413 to filename-seen-cache.h/filename-seen-cache.c.
4414 (output_source_filename, sources_info)
4415 (maybe_add_partial_symtab_filename)
4416 (make_source_files_completion_list): Adjust to use
4417 filename_seen_cache.
4418
330cdd98
PA
44192017-07-17 Pedro Alves <palves@redhat.com>
4420
4421 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
4422 fields.
4423 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
4424 dwarf2_debug_sections*)): New.
4425 (dwarf2_per_objfile::dwarf2_per_objfile(const
4426 dwarf2_per_objfile&)): Declare as deleted.
4427 (dwarf2_per_objfile::operator=): Declare as deleted.
4428 (dwarf2_per_objfile::dwarf2_per_objfile)
4429 (dwarf2_per_objfile::~dwarf2_per_objfile)
4430 (dwarf2_per_objfile::free_cached_comp_units): New.
4431 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
4432 ctor. Call dwarf2_per_objfile's ctor manually.
4433 (dwarf2_locate_sections): Deleted/refactored as ...
4434 (dwarf2_per_objfile::locate_sections): ... this new method.
4435 (free_cached_comp_units): Defer to
4436 dwarf2_per_objfile::free_cached_comp_units.
4437 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
4438
8880f2a9
TT
44392017-07-14 Tom Tromey <tom@tromey.com>
4440
4441 PR rust/21764:
4442 * rust-exp.y (convert_ast_to_expression): Add "want_type"
4443 parameter.
4444 <UNOP_SIZEOF>: Split into separate case.
4445 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
4446
65547233
TT
44472017-07-14 Tom Tromey <tom@tromey.com>
4448
4449 PR rust/21763:
4450 * symtab.c (symbol_matches_domain): Add language_rust to special
4451 case.
4452 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
4453 treat LOC_TYPEDEF symbols as variables.
4454
8f14146e
PA
44552017-07-14 Pedro Alves <palves@redhat.com>
4456
4457 * symtab.c (make_file_symbol_completion_list_1): Iterate over
4458 symtabs matching all symtabs with SRCFILE as file name instead of
4459 only considering the first hit, with lookup_symtab.
4460
2347965c
SM
44612017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4462
4463 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
4464 operator_name parameters.
4465 (gen_expr): Update function call.
4466
40f4af28
SM
44672017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4468
4469 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
4470 parameter.
4471 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
4472 Likewise.
4473 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
4474 parameter, use agent_expr::gdbarch instead, update function
4475 calls.
4476 (locexpr_tracepoint_var_ref): Likewise.
4477 (loclist_tracepoint_var_ref): Likewise.
4478 * ax-gdb.c (gen_trace_static_fields): Likewise.
4479 (gen_traced_pop): Likewise.
4480 (gen_frame_args_address): Likewise.
4481 (gen_frame_locals_address): Likewise.
4482 (gen_var_ref): Likewise.
4483 (gen_struct_ref_recursive): Likewise.
4484 (gen_static_field): Likewise.
4485 (gen_maybe_namespace_elt): Likewise.
4486 (gen_expr): Likewise.
4487 (gen_trace_for_var): Likewise.
4488 (gen_trace_for_expr): Likewise.
4489 (gen_trace_for_return_address): Likewise.
4490
053f8057
SM
44912017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4492
4493 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
4494 parameter.
4495 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
4496
6661ad48
SM
44972017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4498
4499 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
4500 from ax, update calls.
4501 (gen_usual_arithmetic): Likewise.
4502 (gen_integral_promotions): Likewise.
4503 (gen_bitfield_ref): Likewise.
4504 (gen_primitive_field): Likewise.
4505 (gen_struct_ref_recursive): Likewise.
4506 (gen_struct_ref): Likewise.
4507 (gen_maybe_namespace_elt): Likewise.
4508 (gen_struct_elt_for_reference): Likewise.
4509 (gen_namespace_elt): Likewise.
4510 (gen_aggregate_elt_ref): Likewise.
4511 (gen_expr): Get gdbarch from ax, update calls.
4512 (gen_expr_binop_rest): Likewise.
4513
c55a47e7
PA
45142017-07-13 Pedro Alves <palves@redhat.com>
4515
4516 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
4517 as default tdesc.
4518 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
4519 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
4520 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
4521 tdesc_amd64_linux as default tdesc. Get final tdesc from the
4522 tdep.
4523 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
4524 Get final tdesc from the tdep.
4525 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
4526 default tdesc.
4527 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4528 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4529 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
4530 Use it as default tdesc.
4531 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
4532 down to amd_init_abi. No longer handle fallback tdesc here.
4533 * amd64-tdep.h (tdesc_x32): Declare.
4534 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
4535 parameter.
4536 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
4537 as default tdesc.
4538
55efceab
AA
45392017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4540
4541 * s390-linux-tdep.c (s390_process_record): Add support for
4542 instructions new in arch12.
4543
0aa37b65
JB
45442017-07-11 John Baldwin <jhb@FreeBSD.org>
4545
4546 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
4547 PT_GETFSBASE and PT_GETGSBASE.
4548 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
4549 PT_SETGSBASE.
4550
48aeef91
JB
45512017-07-11 John Baldwin <jhb@FreeBSD.org>
4552
4553 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
4554 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
4555 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
4556 those rules.
4557 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
4558 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
4559 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
4560 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
4561 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
4562 * features/i386/amd64.xml: Add 64bit-segments.xml.
4563 * features/i386/amd64-avx-avx512.c: Regenerated.
4564 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
4565 * features/i386/amd64-avx-mpx.c: Regenerated.
4566 * features/i386/amd64-avx.c: Regenerated.
4567 * features/i386/amd64-mpx.c: Regenerated.
4568 * features/i386/amd64.c: Regenerated.
4569 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
4570 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4571 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
4572 * regformats/i386/amd64-avx.dat: Regenerated.
4573 * regformats/i386/amd64-mpx.dat: Regenerated.
4574 * regformats/i386/amd64.dat: Regenerated.
4575
77c501bc
YQ
45762017-07-10 Yao Qi <yao.qi@linaro.org>
4577
4578 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4579 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4580
6dc8d757
AK
45812017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
4582
4583 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
4584 unsetenv.
4585 * gnulib/aclocal.m4: Regenerate.
4586 * gnulib/config.in: Regenerate.
4587 * gnulib/configure: Regenerate.
4588 * gnulib/import/Makefile.am: Regenerate.
4589 * gnulib/import/Makefile.in: Regenerate.
4590 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4591 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4592 * gnulib/import/m4/environ.m4: New file.
4593 * gnulib/import/m4/setenv.m4: New file.
4594 * gnulib/import/setenv.c: New file.
4595 * gnulib/import/unsetenv.c: New file.
4596
266934d1
SM
45972017-07-09 Simon Marchi <simon.marchi@ericsson.com>
4598
4599 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
4600 address when op is DW_OP_addr.
4601
03278692
TT
46022017-07-09 Tom Tromey <tom@tromey.com>
4603
4604 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
4605 check and apply to outer type.
4606
4b654465
JB
46072017-07-07 John Baldwin <jhb@FreeBSD.org>
4608
4609 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
4610 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
4611 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
4612 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
4613
2af9fc44
JB
46142017-07-07 John Baldwin <jhb@FreeBSD.org>
4615
4616 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
4617
382b69bb
JB
46182017-07-07 John Baldwin <jhb@FreeBSD.org>
4619
4620 * corelow.c (get_core_siginfo): Remove.
4621 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
4622 instead of get_core_siginfo.
4623 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
4624 * gdbarch.h: Re-generate.
4625 * gdbarch.c: Re-generate.
4626 * linux-tdep.c (linux_core_xfer_siginfo): New.
4627 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
4628
6e5eab33
JB
46292017-07-07 John Baldwin <jhb@FreeBSD.org>
4630
4631 * corelow.c (thread_section_name): Move to ...
4632 * gdbcore.h (thread_section_name): ... here.
4633
929edea9
JB
46342017-07-07 John Baldwin <jhb@FreeBSD.org>
4635
4636 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
4637 (struct siginfo32): New.
4638 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
4639 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
4640 via ptrace(PT_LWPINFO).
4641
762c974a
JB
46422017-07-07 John Baldwin <jhb@FreeBSD.org>
4643
4644 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
4645 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
4646 (fbsd_get_siginfo_type): New.
4647 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
4648 (_initialize_fbsd_tdep): New.
4649
33c5cd75
DB
46502017-07-06 David Blaikie <dblaikie@gmail.com>
4651
4652 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
4653 a singular dwo_unit*) to support multiple CUs in the same way that
4654 multiple TUs are supported.
4655 (create_cus_hash_table): Replace create_dwo_cu with a function for
4656 parsing multiple CUs from a DWO file.
4657 (open_and_init_dwo_file): Use create_cus_hash_table rather than
4658 create_dwo_cu.
4659 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
4660 htab_find, rather than comparing the signature to a singleton CU in
4661 the dwo_file.
4662
8455d262
PA
46632017-07-06 Pedro Alves <palves@redhat.com>
4664
4665 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
4666
4da3eb35
PA
46672017-07-04 Pedro Alves <palves@redhat.com>
4668
4669 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
4670 * gdbtypes.h (TYPE_STATIC): Delete.
4671 (struct fn_field) <is_public, is_abstract, is_static, is_final,
4672 is_synchronized, is_native>: Delete.
4673 <dummy>: Bump.
4674 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
4675 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
4676 (TYPE_FN_FIELD_ABSTRACT): Delete.
4677
5bfd255c
SM
46782017-07-03 Simon Marchi <simon.marchi@ericsson.com>
4679
4680 * buffer.h (buffer_finish): Fix spelling mistakes.
4681
25c54127
EZ
46822017-07-01 Eli Zaretskii <eliz@gnu.org>
4683
4684 * .dir-locals.el: Automatically switch to C-style comments in
4685 versions of Emacs that support the feature.
4686
dc4bde35
SDJ
46872017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4688 Pedro Alves <palves@redhat.com>
4689
4690 PR cli/21688
4691 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
4692 (process_next_line): New variable 'inline_cmd'.
4693 Adjust 'if' clauses for "python", "compile" and "guile" to use
4694 'command_name_equals' and check for '!inline_cmd'.
4695
51ed89aa
SDJ
46962017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4697
4698 PR cli/21688
4699 * cli/cli-script.c (command_name_equals_not_inline): New function.
4700 (process_next_line): Adjust 'if' clauses for "python", "compile"
4701 and "guile" to use command_name_equals_not_inline.
4702
eb17d413
PA
47032017-06-29 Pedro Alves <palves@redhat.com>
4704
4705 * completer.c (expression_completer): Call
4706 linespec_location_completer instead of location_completer.
4707
195bcdd5
PA
47082017-06-29 Pedro Alves <palves@redhat.com>
4709
4710 * completer.c (expression_completer): Remove code that recomputes
4711 'text' from 'word'.
4712
adc764e7
YQ
47132017-06-29 Yao Qi <yao.qi@linaro.org>
4714
4715 * regformats/regdat.sh: Generate code with
4716 "ifndef IN_PROCESS_AGENT".
4717
6e75794e
PA
47182017-06-28 Pedro Alves <palves@redhat.com>
4719
4720 * command.h: Include "common/scoped_restore.h".
4721
bc491f2e
YQ
47222017-06-28 Yao Qi <yao.qi@linaro.org>
4723
4724 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
4725 instead of obstack_grow.
4726
41664b45
DG
47272017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
4728
4729 PR gdb/21337
4730 * symfile.c (reread_symbols): Call objfiles_changed just before
4731 read_symbols.
4732
6da67eb1
PA
47332017-06-27 Pedro Alves <palves@redhat.com>
4734
4735 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
4736 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
4737 (completion_list_add_symbol, completion_list_add_msymbol):
4738 ... these new functions.
4739 (add_symtab_completions)
4740 (default_make_symbol_completion_list_break_on_1): Adjust.
4741
23732b1e
PA
47422017-06-27 Pedro Alves <palves@redhat.com>
4743
4744 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
4745 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
4746 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
4747 dtor.
4748 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
4749 'storage_obstack' field an auto_obstack. In-class initialize all
4750 non-bitfield fields. Make minsyms_read bool.
4751 * symfile.c (read_symbols): Adjust.
4752
a4d1e79a
AH
47532017-06-27 Alan Hayward <alan.hayward@arm.com>
4754
4755 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
4756 (gdbsim_store_register): Likewise.
4757
8268c778
PA
47582017-06-27 Pedro Alves <palves@redhat.com>
4759
4760 * c-exp.y (name_obstack): Now an auto_obstack.
4761 (yylex): Use auto_obstack::clear.
4762 (c_parse): Use auto_obstack::clear instead of reinitializing and
4763 freeing the obstack.
4764 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
4765 * d-exp.y (name_obstack): Now an auto_obstack.
4766 (yylex): Use auto_obstack::clear.
4767 (d_parse): Use auto_obstack::clear instead of reinitializing and
4768 freeing the obstack.
4769 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
4770 auto_obstack.
4771 * dwarf2read.c (create_addrmap_from_index)
4772 (dwarf2_build_psymtabs_hard)
4773 (update_enumeration_type_from_children): Likewise.
4774 * gdb_obstack.h (auto_obstack): New type.
4775 * go-exp.y (name_obstack): Now an auto_obstack.
4776 (build_packaged_name): Use auto_obstack::clear.
4777 (go_parse): Use auto_obstack::clear instead of reinitializing and
4778 freeing the obstack.
4779 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
4780 auto_obstack.
4781 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
4782 * rust-exp.y (work_obstack): Now an auto_obstack.
4783 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
4784 reinitializing and freeing the obstack.
4785 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
4786 (host_char_to_target): Use auto_obstack.
4787 * utils.h (make_cleanup_obstack_free): Delete declaration.
4788 * valprint.c (generic_emit_char, generic_printstr): Use
4789 auto_obstack.
4790
db665f42
SM
47912017-06-27 Simon Marchi <simon.marchi@ericsson.com>
4792
4793 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
4794 thread.
4795 (darwin_init_thread_list): Don't update dummy thread.
4796 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
4797
873c0814
SM
47982017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4799
4800 * record-full.c (netorder16): Remove.
4801
8b5a7a6e
SM
48022017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4803
4804 * common/diagnostics.h: Define macros for GCC.
4805 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
4806 * common/vec.h: Include diagnostics.h.
4807 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
4808 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
4809 warning.
4810
d1435379
SM
48112017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4812
4813 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
4814 New macro.
4815 * ada-lex.l: Ignore deprecated register warnings.
4816
cc75e0fd
SM
48172017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4818
4819 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
4820 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
4821
07809eaf
SM
48222017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4823
4824 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
4825 its own line.
4826
f076f034
SM
48272017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4828
4829 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
4830
0dd5cbc5
AH
48312017-06-23 Alan Hayward <alan.hayward@arm.com>
4832
4833 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
4834 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
4835 (xtensa_register_read_masked): Likewise.
4836
d4c6ce5b
SDJ
48372017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
4838
4839 * common/environ.c (gdb_environ::unset): Update comment.
4840
16892a03
AH
48412017-06-22 Alan Hayward <alan.hayward@arm.com>
4842
4843 * python/py-unwind.c (pyuw_sniffer): Allocate space for
4844 registers.
4845
d7dcbefc
AH
48462017-06-22 Alan Hayward <alan.hayward@arm.com>
4847
4848 * record-full.c (record_full_exec_insn): Use byte_vector.
4849
b30ff123
YQ
48502017-06-22 Yao Qi <yao.qi@linaro.org>
4851
4852 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
4853 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4854
4fa847d7
AH
48552017-06-22 Alan Hayward <alan.hayward@arm.com>
4856
4857 * remote.c (cached_reg): Move from here...
4858 * regcache.h (cached_reg): ...to here.
4859 * python/py-unwind.c (struct reg_info): Remove.
4860 (cached_frame_info): Use cached_reg_t.
4861 (pyuw_prev_register): Likewise.
4862 (pyuw_sniffer): Use cached_reg_t and allocate registers.
4863 (pyuw_dealloc_cache): Free all registers.
4864
f4906a9a
PA
48652017-06-22 Pedro Alves <palves@redhat.com>
4866 Simon Marchi <simon.marchi@ericsson.com>
4867
4868 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
4869 warning.
4870 * common/diagnostics.h: New file.
4871
b45a1208
PA
48722017-06-22 Pedro Alves <palves@redhat.com>
4873
4874 * common/agent.h: Add include guards.
4875
e4da2c61
SM
48762017-06-21 Simon Marchi <simon.marchi@ericsson.com>
4877
4878 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
4879 talk about addressable units instead of bytes.
4880
96160d60
SDJ
48812017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4882
4883 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
4884 of '::const_iterator'.
4885
9a6c7d9c
SDJ
48862017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
4887
4888 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4889 'unittests/environ-selftests.c'.
4890 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
4891 * charset.c (find_charset_names): Declare object 'iconv_env'.
4892 Update code to use 'iconv_env' object. Remove call to
4893 'free_environ'.
4894 * common/environ.c: Include <utility>.
4895 (make_environ): Delete function.
4896 (free_environ): Delete function.
4897 (gdb_environ::clear): New function.
4898 (gdb_environ::operator=): New function.
4899 (gdb_environ::get): Likewise.
4900 (environ_vector): Delete function.
4901 (set_in_environ): Delete function.
4902 (gdb_environ::set): New function.
4903 (unset_in_environ): Delete function.
4904 (gdb_environ::unset): New function.
4905 (gdb_environ::envp): Likewise.
4906 * common/environ.h: Include <vector>.
4907 (struct gdb_environ): Delete; transform into...
4908 (class gdb_environ): ... this class.
4909 (free_environ): Delete prototype.
4910 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
4911 environ_vector): Likewise.
4912 * infcmd.c (run_command_1): Update code to call
4913 'envp' from 'gdb_environ' class.
4914 (environment_info): Update code to call methods from 'gdb_environ'
4915 class.
4916 (unset_environment_command): Likewise.
4917 (path_info): Likewise.
4918 (path_command): Likewise.
4919 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
4920 (inferior::inferior): Initialize 'environment' using the host's
4921 information.
4922 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
4923 Include "environ.h".
4924 (class inferior) <environment>: Change type from 'struct
4925 gdb_environ' to 'gdb_environ'.
4926 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
4927 methods from 'gdb_environ' class.
4928 * solib.c (solib_find_1): Likewise
4929 * unittests/environ-selftests.c: New file.
4930
75c554cf
YQ
49312017-06-20 Yao Qi <yao.qi@linaro.org>
4932
4933 * features/i386/i386-linux.xml: Exchange the order of including
4934 32bit-linux.xml and 32bit-sse.xml.
4935 * features/i386/i386-linux.c: Regenerated.
4936
72ddacb7
YQ
49372017-06-20 Yao Qi <yao.qi@linaro.org>
4938
4939 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
4940 Delete copy ctor and assignment operator.
4941 (tdesc_type): Likewise.
4942 (tdesc_feature): Likewise.
4943 (tdesc_free_reg): Remove.
4944 (tdesc_create_reg): Use new.
4945 (tdesc_free_type): Remove.
4946 (tdesc_create_vector): Use new.
4947 (tdesc_create_union): Likewise.
4948 (tdesc_create_flags): Likewise.
4949 (tdesc_create_enum): Likewise.
4950 (tdesc_free_feature): Delete.
4951 (free_target_description): Use delete.
4952
325c9fd4
JB
49532017-06-19 John Baldwin <jhb@FreeBSD.org>
4954
4955 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
4956 registers.
4957
16b7a719
PA
49582017-06-19 Pedro Alves <palves@redhat.com>
4959
4960 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
4961 after gdb::unlinker.
4962
1c8e01c9
SDJ
49632017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
4964
4965 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
4966 gdb_environ to access an environment variable.
4967
ffce45d2
TP
49682017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
4969
4970 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
4971 gdb_byte*.
4972
1d4fbac9
SM
49732017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4974
4975 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
4976
8465943a
SM
49772017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4978
4979 * configure: Re-generate.
4980 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
4981
3e019bdc
SM
49822017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4983
4984 * configure: Re-generate.
4985 * warning.m4: Pass -Werror to compiler when checking for
4986 supported warning flags.
4987
cf0dd6f0
SM
49882017-06-17 Simon Marchi <simon.marchi@ericsson.com>
4989
4990 * Makefile.in (COMPILE.pre): Add "-x c++".
4991
6f98355c
YQ
49922017-06-16 Alan Hayward <alan.hayward@arm.com>
4993 Pedro Alves <palves@redhat.com>
4994 Yao Qi <yao.qi@linaro.org>
4995
4996 * defs.h (RequireLongest): New.
4997 (extract_integer): Declare function template.
4998 (extract_signed_integer): Remove the declaration, but define it
4999 static inline.
5000 (extract_unsigned_integer): Likewise.
5001 (store_integer): Declare function template.
5002 (store_signed_integer): Remove the declaration, but define it
5003 static inline.
5004 (store_unsigned_integer): Likewise.
5005 * findvar.c (extract_integer): New function template.
5006 (extract_signed_integer): Remove.
5007 (extract_unsigned_integer): Remove.
5008 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5009 instantiations.
5010 (store_integer): New function template.
5011 (store_signed_integer): Remove.
5012 (store_unsigned_integer): Remove.
5013 (store_integer): Explicit instantiations.
5014 * regcache.c (regcache_raw_read_signed): Update.
5015 (regcache::raw_read): New function.
5016 (regcache::raw_read_signed): Remove.
5017 (regcache::raw_read_unsigned): Remove.
5018 (regcache_raw_read_unsigned): Update.
5019 (regcache_raw_write_unsigned): Update.
5020 (regcache::raw_write_signed): Remove.
5021 (regcache::raw_write): New function.
5022 (regcache_cooked_read_signed): Update.
5023 (regcache::raw_write_unsigned): Remove.
5024 (regcache::cooked_read_signed): Remove.
5025 (regcache_cooked_read_unsigned): Update.
5026 (regcache::cooked_read_unsigned): Remove.
5027 (regcache_cooked_write_signed): Update.
5028 (regcache_cooked_write_unsigned): Update.
5029 * regcache.h (regcache) <raw_read_signed>: Remove.
5030 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5031 <raw_read, raw_write>: New.
5032 <cooked_read_signed, cooked_write_signed>: Remove.
5033 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5034 <cooked_read, cooked_write>: New.
5035 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5036 (sh64_pseudo_register_write): Update.
5037
a87dc45a
AK
50382017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5039
5040 * arc-tdep.c (arc_disassembler_options): New variable.
5041 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5042 of default_print_insn.
5043 (arc_delayed_print_insn): Set info->section when needed,
5044 use default_print_insn to retrieve a disassembler.
5045
45159d6a
SDJ
50462017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5047
5048 PR gdb/21574
5049 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5050 to mention $SHELL and startup-with-shell.
5051
b46c4cf0
MF
50522017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5053
5054 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5055
6394c606
YQ
50562017-06-14 Yao Qi <yao.qi@linaro.org>
5057
5058 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5059 default_print_insn instead of print_insn_aarch64.
5060 * arm-tdep.c (gdb_print_insn_arm): Call
5061 default_print_insn instead of print_insn_big_arm
5062 and print_insn_little_arm.
5063 * i386-tdep.c (i386_print_insn): Call default_print_insn
5064 instead of print_insn_i386.
5065 * ia64-tdep.c (ia64_print_insn): Call
5066 default_print_insn instead of print_insn_ia64.
5067 * mips-tdep.c (gdb_print_insn_mips): Call
5068 default_print_insn instead of print_insn_big_mips
5069 and print_insn_little_mips.
5070 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5071 instead of print_insn_spu.
5072
d5722aa2
PA
50732017-06-14 Pedro Alves <palves@redhat.com>
5074
5075 * ada-lang.c: Include "common/byte-vector.h".
5076 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5077 * charset.c (wchar_iterator::iterate): Resize the vector instead
5078 of reserving it.
5079 * common/byte-vector.h: Include "common/def-vector.h".
5080 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5081 * cli/cli-dump.c: Include "common/byte-vector.h".
5082 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5083 * common/byte-vector.h: New file.
5084 * common/def-vector.h: New file.
5085 * common/default-init-alloc.h: New file.
5086 * dwarf2loc.c: Include "common/byte-vector.h".
5087 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5088 instead of reserving it.
5089 * dwarf2read.c: Include "common/byte-vector.h".
5090 (data_buf::m_vec): Now a gdb::byte_vector.
5091 * gdb_regex.c: Include "common/def-vector.h".
5092 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5093 * mi/mi-main.c: Include "common/byte-vector.h".
5094 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5095 * printcmd.c: Include "common/byte-vector.h".
5096 (print_scalar_formatted): Use gdb::byte_vector.
5097 * valprint.c: Include "common/byte-vector.h".
5098 (maybe_negate_by_bytes, print_decimal_chars): Use
5099 gdb::byte_vector.
5100
01ec7a27
SM
51012017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5102
5103 * darwin-nat.c: Include "nat/fork-inferior.h".
5104
848d9074
SM
51052017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5106
5107 * configure.nat: Factor out Darwin bits that are not
5108 architecture-specific. Add fork-inferior.o.
5109
3b912944
SM
51102017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5111
5112 * configure.nat: Factor out AIX bits that are not
5113 architecture-specific. Add fork-inferior.o.
5114
55acdf22
AA
51152017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5116
5117 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5118 (read_pieced_value, write_pieced_value): ...here. Reduce to
5119 wrappers that just call rw_pieced_value.
5120
f65e2044
AA
51212017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5122
5123 * dwarf2loc.c (write_pieced_value): When writing the data for a
5124 memory piece, use write_memory_with_notification instead of
5125 write_memory.
5126
23f945bf
AA
51272017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5128
5129 * valops.c (read_value_memory): Change embedded_offset to
5130 represent a bit offset instead of a byte offset.
5131 * value.h (read_value_memory): Adjust comment.
5132
f236533e
AA
51332017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5134
5135 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5136 dest_offset_bits and source_offset_bits.
5137 (write_pieced_value): Likewise.
5138
65d84b76
AA
51392017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5140
5141 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5142 given by DW_OP_bit_piece.
5143 (write_pieced_value): Likewise.
5144
242d31ab
AA
51452017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5146
5147 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5148 some other preparations to the places where sufficient information
5149 is available.
5150 (write_pieced_value): Likewise.
5151
03c8af18
AA
51522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5153
5154 * dwarf2loc.c (bits_to_bytes): New function.
5155 (read_pieced_value): Fix offset calculations for register pieces
5156 on big-endian targets.
5157 (write_pieced_value): Likewise.
5158
840989c1
AA
51592017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5160
5161 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5162 (write_pieced_value): Likewise.
5163
359b19bb
AA
51642017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5165
5166 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5167 transfer the source value's least significant bits, instead of its
5168 lowest-addressed ones. Rename type_len to max_offset.
5169 (read_pieced_value): Mirror above changes to write_pieced_value as
5170 applicable.
5171
07c9ca3b
AA
51722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5173
5174 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5175 truncate full bytes from dest_offset_bits before using it as an
5176 offset into the buffer.
5177
f1cc9874
AA
51782017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5179
5180 * dwarf2loc.c (write_pieced_value): Include transfer size in
5181 byte-wise check.
5182
cdaac320
AA
51832017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5184
5185 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5186 calculation of this_size.
5187
af547a96
AA
51882017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5189
5190 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5191 when targeting a bit-field.
5192 (write_pieced_value): Likewise.
5193
ddd7882a
AA
51942017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5195
5196 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5197 (allocate_piece_closure): Drop addr_size parameter.
5198 (dwarf2_evaluate_loc_desc_full): Adjust call to
5199 allocate_piece_closure.
5200
e9352324
AA
52012017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5202
5203 PR gdb/21226
5204 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5205 the LSB end, independent of endianness.
5206
d5d1163e
AA
52072017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5208
5209 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5210 size capping.
5211
032bb6ea
YQ
52122017-06-13 Yao Qi <yao.qi@linaro.org>
5213
5214 * mips-linux-nat.c: Move include features/mips*-linux.c to
5215 mips-linux-tdep.c.
5216 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5217 to mips-linux-tdep.c.
5218 * mips-linux-tdep.c: Include features/mips*-linux.c
5219 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5220 functions.
5221 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5222 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5223 (tdesc_mips64_dsp_linux): Declare.
5224
f12f6bad
TT
52252017-06-12 Tom Tromey <tom@tromey.com>
5226
5227 * valprint.h (val_print_type_code_int): Remove.
5228 * valprint.c (generic_val_print_int): Always call
5229 val_print_scalar_formatted.
5230 (val_print_type_code_int): Remove.
5231 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5232 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5233 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5234 * ada-valprint.c (ada_val_print_num): Use
5235 val_print_scalar_formatted.
5236
d9109c80
TT
52372017-06-12 Tom Tromey <tom@tromey.com>
5238
5239 * printcmd.c (print_scalar_formatted): Unify the two switches.
5240 Don't convert scalars to LONGEST.
5241
4ac0cb1c
TT
52422017-06-12 Tom Tromey <tom@tromey.com>
5243
5244 PR exp/16225:
5245 * valprint.h (print_decimal_chars): Update.
5246 * valprint.c (maybe_negate_by_bytes): New function.
5247 (print_decimal_chars): Add "is_signed" argument.
5248 * printcmd.c (print_scalar_formatted): Update.
5249
30a25466
TT
52502017-06-12 Tom Tromey <tom@tromey.com>
5251
5252 PR exp/16225:
5253 * valprint.h (print_binary_chars, print_hex_chars): Update.
5254 * valprint.c (val_print_type_code_int): Update.
5255 (print_binary_chars): Add "zero_pad" argument.
5256 (emit_octal_digit): New function.
5257 (print_octal_chars): Don't zero-pad.
5258 (print_decimal_chars): Likewise.
5259 (print_hex_chars): Add "zero_pad" argument.
5260 * sh64-tdep.c (sh64_do_fp_register): Update.
5261 * regcache.c (regcache::dump): Update.
5262 * printcmd.c (print_scalar_formatted): Update.
5263 * infcmd.c (default_print_one_register_info): Update.
5264
b3464d03
PA
52652017-06-12 Pedro Alves <palves@redhat.com>
5266 Alan Hayward <alan.hayward@arm.com>
5267
5268 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5269 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5270 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5271 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5272 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5273
4b76cda9
PA
52742017-06-12 Pedro Alves <palves@redhat.com>
5275
5276 * dwarf2read.c (mapped_symtab::data): Now a vector of
5277 symtab_index_entry instead of vector of
5278 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5279 whether an element's name is NULL instead of checking whether the
5280 element itself is NULL.
5281 (find_slot): Change return type. Adjust.
5282 (hash_expand, , add_index_entry, uniquify_cu_indices)
5283 (write_hash_table): Adjust.
5284
e8f8bcb3
PA
52852017-06-12 Pedro Alves <palves@redhat.com>
5286
5287 * dwarf2read.c (recursively_count_psymbols): New function.
5288 (write_psymtabs_to_index): Call it to compute number of psyms and
5289 pass estimate size of psyms_seen to unordered_set's ctor.
5290
70a1152b
PA
52912017-06-12 Pedro Alves <palves@redhat.com>
5292
5293 * dwarf2read.c (write_hash_table): Check if key already exists
5294 before emplacing.
5295
c2f134ac
PA
52962017-06-12 Pedro Alves <palves@redhat.com>
5297
5298 * dwarf2read.c (data_buf::append_space): Rename to...
5299 (data_buf::grow): ... this, and make private. Adjust all callers.
5300 (data_buf::append_uint): New method.
5301 (add_address_entry, write_one_signatured_type)
5302 (write_psymtabs_to_index): Use it.
5303
a81e6d4d
PA
53042017-06-12 Pedro Alves <palves@redhat.com>
5305
5306 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5307 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5308 (data_buf::file_write): Call ::fwrite directly.
5309
6fd931f2
PA
53102017-06-12 Pedro Alves <palves@redhat.com>
5311
5312 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5313 std::vector::erase.
5314
bc8f2430
JK
53152017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5316
5317 Code cleanup: C++ify .gdb_index producer.
5318 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5319 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5320 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5321 (create_strtab, add_string): Remove.
5322 (file_write, data_buf): New.
5323 (struct symtab_index_entry): Use std::vector for cu_indices.
5324 (struct mapped_symtab): Use std::vector for data.
5325 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5326 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5327 Remove.
5328 (find_slot): Change return type. Update it to the new data structures.
5329 (hash_expand, add_index_entry): Update it to the new data structures.
5330 (offset_type_compare): Remove.
5331 (uniquify_cu_indices): Update it to the new data structures.
5332 (c_str_view, c_str_view_hasher, vector_hasher): New.
5333 (add_indices_to_cpool): Remove.
5334 (write_hash_table): Update it to the new data structures.
5335 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5336 (eq_psymtab_cu_index): Remove.
5337 (psym_index_map): New typedef.
5338 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5339 reference and std::unordered_map for cu_index_htab.
5340 (add_address_entry, add_address_entry_worker, write_address_map)
5341 (write_psymbols): Update it to the new data structures.
5342 (write_obstack): Remove.
5343 (struct signatured_type_index_data): Change types_list to a data_buf
5344 reference and psyms_seen to a std::unordered_set reference.
5345 (write_one_signatured_type, recursively_write_psymbols)
5346 (write_psymtabs_to_index): Update it to the new data structures.
5347
c4dcb155
SM
53482017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5349
5350 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5351 separate-debug-file commands.
5352 * symfile.h (separate_debug_file_debug): New global.
5353 * symfile.c (separate_debug_file_debug): New global.
5354 (separate_debug_file_exists, find_separate_debug_file): Add
5355 debug output.
5356 (_initialize_symfile): Add "set debug separate-debug-file"
5357 command.
5358 * build-id.c (build_id_to_debug_bfd,
5359 find_separate_debug_file_by_buildid): Add debug output.
5360
6d45d4b4
SM
53612017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5362
5363 * gdbarch.sh (displaced_step_free_closure): Remove.
5364 * gdbarch.h, gdbarch.c: Re-generate.
5365 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5366 displaced_step_free_closure.
5367 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5368 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5369 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5370 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5371 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5372 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5373 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5374 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5375 * infrun.c (displaced_step_clear): Call xfree instead of
5376 gdbarch_displaced_step_free_closure.
5377
2f91880f
SDJ
53782017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5379
5380 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5381 NULL".
5382
b8b6e72f
AH
53832017-06-08 Alan Hayward <alan.hayward@arm.com>
5384
5385 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5386 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5387 (mn10300_push_dummy_call): Likewise.
5388
5369082e
AH
53892017-06-08 Alan Hayward <alan.hayward@arm.com>
5390
5391 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5392
ff4ca5ac
AH
53932017-06-08 Alan Hayward <alan.hayward@arm.com>
5394
5395 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5396
aefd8b33
SDJ
53972017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5398
5399 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5400 able to start inferiors using a shell.
5401 (New remote packets): Announce new packet "QStartupWithShell".
5402 * remote.c: Add PACKET_QStartupWithShell.
5403 (extended_remote_create_inferior): Handle new
5404 PACKET_QStartupWithShell.
5405 (remote_protocol_features) <QStartupWithShell>: New entry for
5406 PACKET_QStartupWithShell.
5407 (_initialize_remote): Call "add_packet_config_cmd" for
5408 QStartupShell.
5409
2090129c
SDJ
54102017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5411 Pedro Alves <palves@redhat.com>
5412
5413 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5414 and "nat/fork-inferior.h".
5415 * common/common-inferior.h: New file, with contents from
5416 "gdb/inferior.h".
5417 * commom/common-utils.c: Include "common-utils.h".
5418 (stringify_argv): New function.
5419 * common/common-utils.h (stringify_argv): New prototype.
5420 * configure.nat: Add "fork-inferior.o" as a dependency for
5421 "*linux*", "fbsd*" and "nbsd*" hosts.
5422 * corefile.c (get_exec_file): Update comment.
5423 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
5424 instead of "startup_inferior".
5425 (darwin_create_inferior): Call "add_thread_silent" after
5426 "fork_inferior".
5427 * fork-child.c: Cleanup unnecessary includes.
5428 (SHELL_FILE): Move to "common/common-fork-child.c".
5429 (environ): Likewise.
5430 (exec_wrapper): Initialize.
5431 (get_exec_wrapper): New function.
5432 (breakup_args): Move to "common/common-fork-child.c"; rename to
5433 "breakup_args_for_exec".
5434 (escape_bang_in_quoted_argument): Move to
5435 "common/common-fork-child.c".
5436 (saved_ui): New variable.
5437 (prefork_hook): New function.
5438 (postfork_hook): Likewise.
5439 (postfork_child_hook): Likewise.
5440 (gdb_startup_inferior): Likewise.
5441 (fork_inferior): Move to "common/common-fork-child.c". Update
5442 function to support gdbserver.
5443 (startup_inferior): Likewise.
5444 * gdbcore.h (get_exec_file): Remove declaration.
5445 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
5446 instead of "startup_inferior". Call "add_thread_silent" after
5447 "fork_inferior".
5448 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
5449 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
5450 instead of "startup_inferior". Call "add_thread_silent" after
5451 "fork_inferior".
5452 * inferior.h: Include "common-inferior.h".
5453 (trace_start_error): Move to "common/common-utils.h".
5454 (trace_start_error_with_name): Likewise.
5455 (fork_inferior): Move prototype to "nat/fork-inferior.h".
5456 (startup_inferior): Likewise.
5457 (gdb_startup_inferior): New prototype.
5458 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
5459 * nat/fork-inferior.h: New file.
5460 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
5461 instead of "startup_inferior". Call "add_thread_silent" after
5462 "fork_inferior".
5463 * target.h (target_terminal_init): Move prototype to
5464 "target/target.h".
5465 (target_terminal_inferior): Likewise.
5466 (target_terminal_ours): Likewise.
5467 * target/target.h (target_terminal_init): New prototype, moved
5468 from "target.h".
5469 (target_terminal_inferior): Likewise.
5470 (target_terminal_ours): Likewise.
5471 * utils.c (gdb_flush_out_err): New function.
5472
043a4934
SDJ
54732017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5474
5475 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
5476 * common/common-gdbthread.h: New file, with parts from
5477 "gdb/gdbthread.h".
5478 * gdbthread.h: Include "common-gdbthread.h".
5479 (switch_to_thread): Moved to "common/common-gdbthread.h".
5480
15652511
SDJ
54812017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5482
5483 * Makefile.in (SFILES): Add "common/job-control.c".
5484 (HFILES_NO_SRCDIR): Add "common/job-control.h".
5485 (COMMON_OBS): Add "job-control.o".
5486 * common/job-control.c: New file, with contents from
5487 "gdb/inflow.c".
5488 * common/job-control.h: New file, with contents from "terminal.h".
5489 * fork-child.c: Include "job-control.h".
5490 * inflow.c: Include "job-control.h".
5491 (gdb_setpgid): Move to "common/common-inflow.c".
5492 (_initialize_inflow): Move setting of "job_control" to
5493 "handle_job_control".
5494 * terminal.h (job_control): Moved to "common/common-terminal.h".
5495 (gdb_setpgid): Likewise.
5496 * top.c: Include "job_control.h".
5497 * utils.c: Likewise.
5498 (job_control): Moved to "job-control.c".
5499
2d7cc5c7
PA
55002017-06-07 Pedro Alves <palves@redhat.com>
5501
5502 * Makefile.in (SFILES): Add gdb_regex.c.
5503 (COMMON_OBS): Add gdb_regex.o.
5504 * ada-lang.c (ada_add_standard_exceptions)
5505 (ada_add_exceptions_from_frame, name_matches_regex)
5506 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
5507 parameter type to compiled_regex. Adjust.
5508 (ada_exceptions_list): Use compiled_regex.
5509 * break-catch-throw.c (exception_catchpoint::pattern): Now a
5510 std::unique_ptr<compiled_regex>.
5511 (exception_catchpoint::~exception_catchpoint): Remove regfree
5512 call.
5513 (check_status_exception_catchpoint): Adjust to use compiled_regex.
5514 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
5515 * breakpoint.c (solib_catchpoint::compiled): Now a
5516 std::unique_ptr<compiled_regex>.
5517 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
5518 (check_status_catch_solib): Adjust to use compiled_regex.
5519 (add_solib_catchpoint): Adjust to use compiled_regex.
5520 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
5521 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
5522 compiled_regex reference. Adjust to use it.
5523 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
5524 declaration. Include "gdb_regex.h".
5525 (apropos_cmd): Change regex parameter to compiled_regex reference.
5526 * gdb_regex.c: New file.
5527 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
5528 declarations.
5529 (class compiled_regex): New.
5530 * linux-tdep.c: Include "common/gdb_optional.h".
5531 (struct mapping_regexes): New, factored out from
5532 mapping_is_anonymous_p, and adjusted to use compiled_regex.
5533 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
5534 gdb::optional and remove cleanups. Adjust to compiled_regex.
5535 * probe.c: Include "common/gdb_optional.h".
5536 (collect_probes): Use compiled_regex and gdb::optional and remove
5537 cleanups.
5538 * skip.c: Include "common/gdb_optional.h".
5539 (skiplist_entry::compiled_function_regexp): Now a
5540 gdb::optional<compiled_regex>.
5541 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
5542 (free_skiplist_entry): Remove regfree call.
5543 (compile_skip_regexp, skip_rfunction_p): Adjust to use
5544 compiled_regex and gdb::optional.
5545 * symtab.c: Include "common/gdb_optional.h".
5546 (search_symbols): Use compiled_regex and gdb::optional.
5547 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
5548 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
5549 to gdb_regex.c.
5550
50d6adef
AH
55512017-06-07 Alan Hayward <alan.hayward@arm.com>
5552
5553 * regcache.c (regcache::save): Avoid buffer use.
5554 (regcache::dump): Likewise.
5555
4a8a33c8
AH
55562017-06-07 Alan Hayward <alan.hayward@arm.com>
5557
5558 * sh-tdep.c (sh_pseudo_register_read): Remove
5559 MAX_REGISTER_SIZE.
5560 (sh_pseudo_register_write): Likewise.
5561 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
5562 (sh64_pseudo_register_write): Likewise
5563
d1be909e
AH
55642017-06-07 Alan Hayward <alan.hayward@arm.com>
5565
5566 * aarch64-tdep.c (aarch64_store_return_value): Use
5567 V_REGISTER_SIZE.
5568 (aarch64_pseudo_read_value): Likewise.
5569 (aarch64_pseudo_write): Likewise.
5570
f4a65042
YQ
55712017-06-06 Yao Qi <yao.qi@linaro.org>
5572
5573 * regformats/regdef.h (set_register_cache): Remove the
5574 declaration.
5575
9f7fb0aa
AH
55762017-06-06 Alan Hayward <alan.hayward@arm.com>
5577
5578 * frame.c (frame_unwind_register_signed): Use
5579 frame_unwind_register_value.
5580
e1e01040
PA
55812017-06-06 Pedro Alves <palves@redhat.com>
5582
5583 PR breakpoints/21553
5584 * breakpoint.c (create_breakpoints_sal_default)
5585 (init_breakpoint_sal, create_breakpoint_sal): Use
5586 gdb::unique_xmalloc_ptr for string parameters.
5587 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5588 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
5589 (base_breakpoint_create_breakpoints_sal)
5590 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
5591 (strace_marker_create_breakpoints_sal)
5592 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
5593 string parameters.
5594 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
5595 gdb::unique_xmalloc_ptr for string parameters.
5596 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5597 parameters.
5598
fbe654c8
AH
55992017-06-06 Alan Hayward <alan.hayward@arm.com>
5600
5601 * alpha-tdep.c (alpha_register_to_value): Use
5602 get_frame_register_value.
5603 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
5604
ae0d01d6
AH
56052017-06-06 Alan Hayward <alan.hayward@arm.com>
5606
5607 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
5608 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
5609 (ia64_value_to_register): Likewise.
5610 (ia64_extract_return_value): Likewise.
5611 (ia64_store_return_value): Likewise.
5612 (ia64_push_dummy_call): Likewise.
5613
49cf576c
JB
56142017-06-04 Joel Brobecker <brobecker@adacore.com>
5615
5616 GDB 8.0 released.
5617
26b6a6ab
SM
56182017-06-03 Simon Marchi <simon.marchi@ericsson.com>
5619
5620 * x86-linux-nat.c (struct arch_lwp_info): Remove.
5621
22827c51
SM
56222017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
5623
5624 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
5625 parameter.
5626 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
5627
0e05cf3a
SM
56282017-06-02 Simon Marchi <simon.marchi@ericsson.com>
5629
5630 * event-loop.c (poll_timers): Unallocate timer using delete
5631 instead of xfree.
5632
c1fc2657
SM
56332017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5634
5635 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
5636 (struct breakpoint) <~breakpoint>: New.
5637 (struct watchpoint): Inherit from breakpoint.
5638 <~watchpoint>: New.
5639 <base>: Remove.
5640 (struct tracepoint): Inherit from breakpoint.
5641 <base>: Remove.
5642 * breakpoint.c (longjmp_breakpoint_ops): Remove.
5643 (struct longjmp_breakpoint): Inherit from breakpoint.
5644 <~longjmp_breakpoint>: New.
5645 <base>: Remove.
5646 (new_breakpoint_from_type): Remove casts.
5647 (watchpoint_in_thread_scope): Remove reference to base field.
5648 (watchpoint_del_at_next_stop): Likewise.
5649 (update_watchpoint): Likewise.
5650 (watchpoint_check): Likewise.
5651 (bpstat_check_watchpoint): Likewise.
5652 (set_longjmp_breakpoint): Likewise.
5653 (struct fork_catchpoint): Inherit from breakpoint.
5654 <base>: Remove.
5655 (struct solib_catchpoint): Inherit from breakpoint.
5656 <~solib_catchpoint>: New.
5657 <base>: Remove.
5658 (dtor_catch_solib): Change to ...
5659 (solib_catchpoint::~solib_catchpoint): ... this.
5660 (breakpoint_hit_catch_solib): Remove reference to base field.
5661 (add_solib_catchpoint): Likewise.
5662 (create_fork_vfork_event_catchpoint): Likewise.
5663 (struct exec_catchpoint): Inherit from breakpoint.
5664 <~exec_catchpoint>: New.
5665 <base>: Remove.
5666 (dtor_catch_exec): Change to ...
5667 (exec_catchpoint::~exec_catchpoint): ... this.
5668 (dtor_watchpoint): Change to ...
5669 (watchpoint::~watchpoint): ... this.
5670 (watch_command_1): Remove reference to base field.
5671 (catch_exec_command_1): Likewise.
5672 (base_breakpoint_dtor): Change to ...
5673 (breakpoint::~breakpoint): ... this.
5674 (base_breakpoint_ops): Remove dtor field value.
5675 (longjmp_bkpt_dtor): Change to ...
5676 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
5677 (strace_marker_create_breakpoints_sal): Remove reference to base
5678 field.
5679 (delete_breakpoint): Don't manually call breakpoint destructor.
5680 (create_tracepoint_from_upload): Remove reference to base field.
5681 (trace_pass_set_count): Likewise.
5682 (initialize_breakpoint_ops): Don't initialize
5683 momentary_breakpoint_ops, don't set dtors.
5684 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
5685 <~ada_catchpoint>: New.
5686 <base>: Remove.
5687 (create_excep_cond_exprs): Remove reference to base field.
5688 (dtor_exception): Change to ...
5689 (ada_catchpoint::~ada_catchpoint): ... this.
5690 (dtor_catch_exception): Remove.
5691 (dtor_catch_exception_unhandled): Remove.
5692 (dtor_catch_assert): Remove.
5693 (create_ada_exception_catchpoint): Remove reference to base
5694 field.
5695 (initialize_ada_catchpoint_ops): Don't set dtors.
5696 * break-catch-sig.c (struct signal_catchpoint): Inherit from
5697 breakpoint.
5698 <~signal_catchpoint>: New.
5699 <base>: Remove.
5700 (signal_catchpoint_dtor): Change to ...
5701 (signal_catchpoint::~signal_catchpoint): ... this.
5702 (create_signal_catchpoint): Remove reference to base field.
5703 (initialize_signal_catchpoint_ops): Don't set dtor.
5704 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
5705 from breakpoint.
5706 <~syscall_catchpoint>: New.
5707 <base>: Remove.
5708 (dtor_catch_syscall): Change to ...
5709 (syscall_catchpoint::~syscall_catchpoint): ... this.
5710 (create_syscall_event_catchpoint): Remove reference to base
5711 field.
5712 (initialize_syscall_catchpoint_ops): Don't set dtor.
5713 * break-catch-throw.c (struct exception_catchpoint): Inherit
5714 from breakpoint.
5715 <~exception_catchpoint>: New.
5716 <base>: Remove.
5717 (dtor_exception_catchpoint): Change to ...
5718 (exception_catchpoint::~exception_catchpoint): ... this.
5719 (handle_gnu_v3_exceptions): Remove reference to base field.
5720 (initialize_throw_catchpoint_ops): Don't set dtor.
5721 * ctf.c (ctf_get_traceframe_address): Remove reference to base
5722 field.
5723 * remote.c (remote_get_tracepoint_status): Likewise.
5724 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
5725 * tracefile.c (tracefile_fetch_registers): Likewise.
5726 * tracepoint.c (actions_command): Likewise.
5727 (validate_actionline): Likewise.
5728 (tfind_1): Likewise.
5729 (get_traceframe_location): Likewise.
5730 (find_matching_tracepoint_location): Likewise.
5731 (parse_tracepoint_status): Likewise.
5732 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
5733
3b0871f4
SM
57342017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5735
5736 * breakpoint.c (struct longjmp_breakpoint): New struct.
5737 (is_tracepoint_type): Change return type to bool.
5738 (is_longjmp_type): New function.
5739 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
5740 (set_raw_breakpoint_without_location): Use
5741 new_breakpoint_from_type.
5742 (set_raw_breakpoint): Likewise.
5743
a5e364af
SM
57442017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5745
5746 * breakpoint.c (new_breakpoint_from_type): New function.
5747 (create_breakpoint_sal): Use new_breakpoint_from_type and
5748 unique_ptr.
5749 (create_breakpoint): Likewise.
5750
ae3b3f34
SM
57512017-05-31 Simon Marchi <simon.marchi@ericsson.com>
5752
5753 * memattr.c (mem_info_command): Rename to ...
5754 (info_mem_command): ... this.
5755 (mem_enable_command): Rename to ...
5756 (enable_mem_command): ... this.
5757 (mem_disable_command): Rename to ...
5758 (disable_mem_command): ... this.
5759 (mem_delete_command): Rename to ...
5760 (delete_mem_command): ... this.
5761 (_initialize_mem): Adjust function names.
5762
13ace077
MM
57632017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5764
5765 * btrace.c (handle_pt_insn_events): New.
5766 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
5767 STATUS. Split into this and ...
5768 (handle_pt_insn_event_flags): ... this.
5769
c56ccc05
MM
57702017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5771
5772 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
5773 and struct pt_insn.resynced.
5774 * configure: Regenerated.
5775 * config.in: Regenerated.
5776
08c3f6d2
TW
57772017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5778
5779 * btrace.c (ftrace_find_call_by_number): New function.
5780 (ftrace_new_function): Store objects, not pointers.
5781 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
5782 ftrace_new_gap, ftrace_update_function,
5783 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
5784 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
5785 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
5786 btrace_ends_with_single_insn, btrace_call_get): Account for
5787 btrace_thread_info::functions now storing objects.
5788 * btrace.h (struct btrace_thread_info): Add constructor.
5789 (struct btrace_thread_info) <functions>: Make std::vector.
5790 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
5791 Initialize with default values.
5792 * record-btrace.c (record_btrace_frame_sniffer): Account for
5793 btrace_thread_info::functions now storing objects.
5794
8ffd39f2
TW
57952017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5796
5797 * btrace.c: Remove typedef bfun_s.
5798 (ftrace_new_gap): Directly add gaps to the list of gaps.
5799 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
5800 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
5801 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
5802 instead of gdb VEC.
5803
4aeb0dfc
TW
58042017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5805
5806 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
5807 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
5808 with btrace_thread_info::next_segment and
5809 btrace_thread_info::prev_segment.
5810 * btrace.h: Remove struct btrace_func_link.
5811 (struct btrace_function): Replace pair of function segment pointers
5812 with pair of indices.
5813 * python/py-record-btrace.c (btpy_call_prev_sibling,
5814 btpy_call_next_sibling): Replace references to
5815 btrace_thread_info::segment with btrace_thread_info::next_segment and
5816 btrace_thread_info::prev_segment.
5817 * record-btrace.c (record_btrace_frame_this_id): Use
5818 btrace_find_call_by_number.
5819
eb8f2b9c
TW
58202017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5821
5822 * btrace.c (ftrace_new_function, ftrace_fixup_level,
5823 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
5824 btrace_insn_next, btrace_insn_prev): Remove references to
5825 btrace_thread_info::flow.
5826 * btrace.h (struct btrace_function): Remove FLOW.
5827
42bfe59e
TW
58282017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5829
5830 * btrace.c (ftrace_find_call_by_number): New function.
5831 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
5832 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
5833 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
5834 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
5835 index.
5836 * btrace.h (struct btrace_function): Turn UP into an index.
5837 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
5838 as an index.
5839 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
5840 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
5841 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
5842
b54b03bd
TW
58432017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5844
5845 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5846 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5847 ftrace_update_function, ftrace_compute_global_level_offset,
5848 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
5849 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
5850 btrace_insn_end, btrace_is_empty): Remove references to
5851 btrace_thread_info::begin and btrace_thread_info::end.
5852 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
5853 (struct btrace_thread_info) <functions>: Adjust comment.
5854 * record-btrace.c (record_btrace_start_replaying): Remove reference to
5855 btrace_thread_info::begin.
5856
8286623c
TW
58572017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5858
5859 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5860 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5861 ftrace_update_function): Remove arguments that implicitly were always
5862 BTINFO->END.
5863 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
5864 Don't pass BTINFO->END.
5865
a0f1b963
TW
58662017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5867
5868 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
5869 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
5870 btrace_find_insn_by_number): Replace function segment pointer with
5871 index.
5872 (btrace_insn_cmp): Simplify.
5873 * btrace.h: (struct btrace_insn_iterator) Rename index to
5874 insn_index. Replace function segment pointer with index into function
5875 segment vector.
5876 * record-btrace.c (record_btrace_call_history): Replace function
5877 segment pointer use with index.
5878 (record_btrace_frame_sniffer): Retrieve function call segment through
5879 vector.
5880 (record_btrace_set_replay): Remove defunc't safety check.
5881
f158f208
TW
58822017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5883
5884 * btrace.c (btrace_ends_with_single_insn): New function.
5885 (btrace_call_get, btrace_call_number, btrace_call_begin,
5886 btrace_call_end, btrace_call_next, btrace_call_prev,
5887 btrace_find_call_by_number): Use index into call segment vector
5888 instead of pointer.
5889 (btrace_call_cmp): Simplify.
5890 * btrace.h (struct btrace_call_iterator): Replace function call segment
5891 pointer with index into vector.
5892 * record-btrace.c (record_btrace_call_history): Use index instead of
5893 pointer.
5894
521103fd
TW
58952017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5896
5897 * btrace.c (btrace_insn_begin, btrace_insn_end,
5898 btrace_find_insn_by_number): Add btinfo to iterator.
5899 * btrace.h (struct btrace_insn_iterator): Add btinfo.
5900
17b89b34
TW
59012017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5902
5903 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
5904 and save pointers directly.
5905 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
5906 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
5907 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
5908 changed signature of functions.
5909 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
5910 (btrace_fetch): Remove code that adds btrace_function pointers to
5911 vector of btrace_functions.
5912 (btrace_clear): Simplify freeing vector of btrace_functions.
5913
2b51eddc
TW
59142017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5915
5916 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
5917 Replace VEC_* with std::vector functions.
5918 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
5919 (struct btrace_thread_info)<functions>: Change type to std::vector.
5920
db6be0d5
SM
59212017-05-30 Simon Marchi <simon.marchi@ericsson.com>
5922
5923 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
5924 "Removed targets and native configurations" up. Merge duplicate
5925 "New commands" sub-sections. Add "New options" sub-sections.
5926
b057297a
AH
59272017-05-26 Alan Hayward <alan.hayward@arm.com>
5928
5929 * defs.h (copy_integer_to_size): New declaration.
5930 * findvar.c (copy_integer_to_size): New function.
5931 (do_cint_test): New selftest function.
5932 (copy_integer_to_size_test): Likewise.
5933 (_initialize_findvar): Likewise.
5934 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
5935 (mips_fbsd_collect_reg): Use raw_collect_integer.
5936 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
5937 (mips64_fill_gregset): Use raw_collect_integer
5938 (mips64_fill_fpregset): Use raw_supply_integer.
5939 * regcache.c (regcache::raw_supply_integer): New function.
5940 (regcache::raw_collect_integer): Likewise.
5941 * regcache.h: (regcache::raw_supply_integer): New declaration.
5942 (regcache::raw_collect_integer): Likewise.
5943
b77b02a5
YQ
59442017-05-24 Yao Qi <yao.qi@linaro.org>
5945
5946 * Makefile.in (SFILES): Add gdbarch-selftests.c.
5947 (COMMON_OBS): Add gdbarch-selftests.o.
5948 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
5949 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
5950 * gdbarch-selftests.c: New file.
5951 * regcache.h (regcache) <~regcache>: Mark it virtual if
5952 GDB_SELF_TEST.
5953 <raw_write>: Likewise.
5954
e521e87e
YQ
59552017-05-24 Yao Qi <yao.qi@linaro.org>
5956
5957 * regcache.c (current_regcache): Change it to
5958 regcache::current_regcache.
5959 (regcache_observer_target_changed): Update.
5960 (regcache_thread_ptid_changed): Make it a regcache static
5961 method.
5962 (regcache_thread_ptid_changed): Update.
5963 (class regcache_access): New.
5964 (current_regcache_test): Update.
5965 (_initialize_regcache): Update.
5966 * regcache.h: Include forward_list.
5967 (regcache): Declare regcache_thread_ptid_changed and declare
5968 registers_changed_ptid as friend.
5969
d8e07dda
YQ
59702017-05-24 Yao Qi <yao.qi@linaro.org>
5971
5972 * i387-tdep.c (i387_register_to_value): Use register_size
5973 instead of TYPE_LENGTH.
5974 * m68k-tdep.c (m68k_register_to_value): Likewise.
5975
8c8f9122
YQ
59762017-05-24 Yao Qi <yao.qi@linaro.org>
5977
5978 * i387-tdep.c (i387_convert_register_p): Return false if type
5979 code isn't TYPE_CODE_FLT.
5980
68fce50f
YQ
59812017-05-24 Yao Qi <yao.qi@linaro.org>
5982
5983 * alpha-tdep.c (alpha_convert_register_p): Return true if type
5984 length is 4.
5985 (alpha_register_to_value): Remove type length check.
5986 (alpha_value_to_register): Likewise.
5987
88954b49
YQ
59882017-05-24 Yao Qi <yao.qi@linaro.org>
5989
5990 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
5991 TYPE_CODE_FLT.
5992
e3ec9b69
YQ
59932017-05-24 Yao Qi <yao.qi@linaro.org>
5994
5995 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
5996 TYPE_CODE_FLT or not.
5997
cdd238da
YQ
59982017-05-24 Yao Qi <yao.qi@linaro.org>
5999
6000 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6001 * avr-tdep.c (avr_gdbarch_init): Likewise.
6002 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6003 * cris-tdep.c (cris_gdbarch_init): Likewise.
6004 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6005 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6006 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6007 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6008 * mep-tdep.c (mep_gdbarch_init): Likewise.
6009 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6010 * mips-tdep.c (mips_gdbarch_init): Likewise.
6011 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6012 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6013 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6014 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6015 * v850-tdep.c (v850_gdbarch_init): Likewise.
6016
7a3929c4
YQ
60172017-05-24 Yao Qi <yao.qi@linaro.org>
6018
6019 * selftest-arch.c (tests_with_arch): Call registers_changed
6020 and reinit_frame_cache.
6021 * selftest.c (run_self_tests): Likewise.
6022
f4985dba
YQ
60232017-05-24 Yao Qi <yao.qi@linaro.org>
6024
6025 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6026 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6027
ab20fa4a
YQ
60282017-05-24 Yao Qi <yao.qi@linaro.org>
6029
6030 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6031 set_gdbarch_print_insn.
6032
f532ab94
YQ
60332017-05-24 Yao Qi <yao.qi@linaro.org>
6034
6035 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6036 set_gdbarch_print_insn.
6037
39503f82
YQ
60382017-05-24 Yao Qi <yao.qi@linaro.org>
6039
6040 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6041 set_gdbarch_print_insn.
6042 * arc-tdep.c (arc_gdbarch_init): Likewise.
6043 * arch-utils.c: include dis-asm.h.
6044 (default_print_insn): New function.
6045 * arch-utils.h (default_print_insn): Declare.
6046 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6047 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6048 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6049 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6050 * frv-tdep.c (frv_gdbarch_init): Likewise.
6051 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6052 * gdbarch.sh (print_insn): Use default_print_insn.
6053 * gdbarch.c: Regenerated.
6054 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6055 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6056 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6057 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6058 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6059 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6060 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6061 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6062 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6063 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6064 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6065 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6066 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6067 * mt-tdep.c (mt_gdbarch_init): Likewise.
6068 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6069 * nios2-tdep.c (nios2_print_insn): Remove.
6070 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6071 * rx-tdep.c (rx_gdbarch_init): Likewise.
6072 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6073 * score-tdep.c (score_print_insn): Remove.
6074 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6075 * sh-tdep.c (sh_gdbarch_init): Likewise.
6076 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6077 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6078 * tic6x-tdep.c (tic6x_print_insn): Remove.
6079 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6080 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6081 * v850-tdep.c (v850_gdbarch_init): Likewise.
6082 * vax-tdep.c (vax_gdbarch_init): Likewise.
6083 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6084 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6085
f7241d4f
JB
60862017-05-23 John Baldwin <jhb@FreeBSD.org>
6087
6088 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6089 (MIPS_FP0_REGNUM): Remove.
6090 (MIPS_FSR_REGNUM): Remove.
6091 (mips_fbsd_supply_fpregs): Use mips_regnum.
6092 (mips_fbsd_supply_gregs): Likewise.
6093 (mips_fbsd_collect_fpregs): Likewise.
6094 (mips_fbsd_collect_gregs): Likewise.
6095
d489d81d
JB
60962017-05-23 John Baldwin <jhb@FreeBSD.org>
6097
6098 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6099 (getpfpregs_supplies): New function.
6100 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6101 getfpregs_supplies.
6102 (mips_fbsd_store_inferior_registers): Likewise.
6103
e11b3cdc
PA
61042017-05-22 Pedro Alves <palves@redhat.com>
6105
6106 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6107 maintainer.
6108
0f068fb5
AH
61092017-05-22 Alan Hayward <alan.hayward@arm.com>
6110
6111 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6112 (store_register): Likewise.
6113 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6114 (get_decimal_float_return_value): Likewise.
6115 (do_ppc_sysv_return_value): Likewise.
6116 (ppc64_sysv_abi_push_integer): Likewise.
6117 (ppc64_sysv_abi_push_freg): Likewise.
6118 (ppc64_sysv_abi_return_value_base): Likewise.
6119 (ppc64_sysv_abi_return_value): Likewise.
6120 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6121 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6122 * rs6000-nat.c: Likewise.
6123 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6124 (rs6000_value_to_register): Likewise.
6125 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6126
e6cf65f2
TT
61272017-05-21 Tom Tromey <tom@tromey.com>
6128
6129 PR rust/21466:
6130 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6131 arrays as "[T]", not "[T; ]".
6132
43cc5389
TT
61332017-05-19 Tom Tromey <tom@tromey.com>
6134
6135 PR rust/21484:
6136 * rust-lang.c (exp_descriptor_rust): New function.
6137 (rust_language_defn): Use it.
6138 * p-lang.c (pascal_language_defn): Update.
6139 * opencl-lang.c (opencl_language_defn): Update.
6140 * objc-lang.c (objc_language_defn): Update.
6141 * m2-lang.c (m2_language_defn): Update.
6142 * language.h (struct language_defn)
6143 <la_watch_location_expression>: New member.
6144 * language.c (unknown_language_defn, auto_language_defn)
6145 (local_language_defn): Update.
6146 * go-lang.c (go_language_defn): Update.
6147 * f-lang.c (f_language_defn): Update.
6148 * d-lang.c (d_language_defn): Update.
6149 * c-lang.h (c_watch_location_expression): Declare.
6150 * c-lang.c (c_watch_location_expression): New function.
6151 (c_language_defn, cplus_language_defn, asm_language_defn)
6152 (minimal_language_defn): Use it.
6153 * breakpoint.c (watch_command_1): Call
6154 la_watch_location_expression.
6155 * ada-lang.c (ada_language_defn): Update.
6156
7a6e7fcc
RO
61572017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6158
6e7e1744
RO
6159 PR tui/21482
6160 * gdb_curses.h (NOMACROS): Define.
6161 (NCURSES_NOMACROS): Define.
6162
61632017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6164
6165 PR tui/21482
7a6e7fcc
RO
6166 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6167 arg to char *.
6168 * tui/tui-wingeneral.c (box_win): Likewise.
6169 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6170 (tui_show_source_line): Likewise.
6171 (tui_show_exec_info_content): Likewise.
6172
1933fd8e
VM
61732017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6174
6175 * sparc-tdep.c (sparc_structure_return_p)
6176 (sparc_arg_on_registers_p): New functions.
6177 (sparc32_store_arguments): Use them.
6178 * sparc64-tdep.c (sparc64_16_byte_align_p)
6179 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6180 Handle TYPE_CODE_ARRAY.
6181
21873064
YQ
61822017-05-17 Yao Qi <yao.qi@linaro.org>
6183
6184 * cli/cli-decode.c (add_alias_cmd): New function.
6185 * command.h (add_alias_cmd): Declare.
6186 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6187 instead call add_alias_cmd.
6188
2b351b19
PA
61892017-05-17 Pedro Alves <palves@redhat.com>
6190
6191 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6192 (nat_makefile_frag): ... this. All references updated.
6193 * configure.ac: Likewise.
6194 * configure.nat: Likewise. Enhance comments.
6195 * configure: Regenerate.
6196
5f2ad7a3
RO
61972017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6198
6199 * procfs.c (procfs_create_inferior): Change prototype to match
6200 definition.
6201
adf3dde5
EZ
62022017-05-13 Eli Zaretskii <eliz@gnu.org>
6203
6204 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6205 C++ compiler warning.
6206
6830f270
TT
62072017-05-12 Tom Tromey <tom@tromey.com>
6208
6209 PR rust/21483:
6210 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6211 recurse, just call value_struct_elt directly.
6212
68f2f2e3
TT
62132017-05-12 Tom Tromey <tom@tromey.com>
6214
6215 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6216 OP_RUST_ARRAY>: Fix.
6217
256afbc2
TT
62182017-05-12 Tom Tromey <tom@tromey.com>
6219
6220 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6221
94bb8dfe
YQ
62222017-05-09 Yao Qi <yao.qi@linaro.org>
6223
6224 * regcache.c: Include <forward_list>.
6225 (struct regcache_list): Remove.
6226 (current_regcache): Update.
6227 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6228 (regcache_thread_ptid_changed): Likewise.
6229 (registers_changed_ptid): Likewise.
6230 (current_regcache_size): Likewise.
6231
8248946c
YQ
62322017-05-09 Yao Qi <yao.qi@linaro.org>
6233
6234 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6235 (current_regcache_size): New function.
6236 (current_regcache_test): New function.
6237 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6238
313c5961
AH
62392017-05-08 Alan Hayward <alan.hayward@arm.com>
6240
6241 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6242 (print_gp_register_row): Use get_frame_register_value.
6243
27bfc1d1
AH
62442017-05-08 Alan Hayward <alan.hayward@arm.com>
6245
6246 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6247 (mips_supply_fpregset): Likewise.
6248 (mips64_supply_gregset): Likewise.
6249
146e6c5c
AH
62502017-05-08 Alan Hayward <alan.hayward@arm.com>
6251
6252 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6253 regcache->raw_supply_zeroed.
6254
e50f25ec
SDJ
62552017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6256
6257 * configure.nat: Rearrange 'case' statements to match
6258 host before cpu.
6259
21ea5acd
SDJ
62602017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6261
6262 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6263 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6264 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6265 "@nat_extra_makefile_frag@".
6266 (Makefile): Remove dependency on "@frags@".
6267 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6268 (data-directory/Makefile): Likewise.
6269 * config/aarch64/linux.mh: Deleted; moved contents to
6270 "gdb/configure.nat".
6271 * config/alpha/alpha-linux.mh: Likewise.
6272 * config/alpha/nbsd.mh: Likewise.
6273 * config/arm/linux.mh: Likewise.
6274 * config/arm/nbsdelf.mh: Likewise.
6275 * config/i386/cygwin.mh: Likewise.
6276 * config/i386/cygwin64.mh: Likewise.
6277 * config/i386/darwin.mh: Likewise.
6278 * config/i386/fbsd.mh: Likewise.
6279 * config/i386/fbsd64.mh: Likewise.
6280 * config/i386/go32.mh: Likewise.
6281 * config/i386/i386gnu.mh: Likewise.
6282 * config/i386/i386sol2.mh: Likewise.
6283 * config/i386/linux.mh: Likewise.
6284 * config/i386/linux64.mh: Likewise.
6285 * config/i386/mingw.mh: Likewise.
6286 * config/i386/mingw64.mh: Likewise.
6287 * config/i386/nbsd64.mh: Likewise.
6288 * config/i386/nbsdelf.mh: Likewise.
6289 * config/i386/nto.mh: Likewise.
6290 * config/i386/obsd.mh: Likewise.
6291 * config/i386/obsd64.mh: Likewise.
6292 * config/i386/sol2-64.mh: Likewise.
6293 * config/ia64/linux.mh: Likewise.
6294 * config/m32r/linux.mh: Likewise.
6295 * config/m68k/linux.mh: Likewise.
6296 * config/m68k/nbsdelf.mh: Likewise.
6297 * config/m68k/obsd.mh: Likewise.
6298 * config/m88k/obsd.mh: Likewise.
6299 * config/mips/fbsd.mh: Likewise.
6300 * config/mips/linux.mh: Likewise.
6301 * config/mips/nbsd.mh: Likewise.
6302 * config/mips/obsd64.mh: Likewise.
6303 * config/pa/linux.mh: Likewise.
6304 * config/pa/nbsd.mh: Likewise.
6305 * config/pa/obsd.mh: Likewise.
6306 * config/powerpc/aix.mh: Likewise.
6307 * config/powerpc/fbsd.mh: Likewise.
6308 * config/powerpc/linux.mh: Likewise.
6309 * config/powerpc/nbsd.mh: Likewise.
6310 * config/powerpc/obsd.mh: Likewise.
6311 * config/powerpc/ppc64-linux.mh: Likewise.
6312 * config/powerpc/spu-linux.mh: Likewise.
6313 * config/s390/linux.mh: Likewise.
6314 * config/sh/nbsd.mh: Likewise.
6315 * config/sparc/fbsd.mh: Likewise.
6316 * config/sparc/linux.mh: Likewise.
6317 * config/sparc/linux64.mh: Likewise.
6318 * config/sparc/nbsd64.mh: Likewise.
6319 * config/sparc/nbsdelf.mh: Likewise.
6320 * config/sparc/obsd64.mh: Likewise.
6321 * config/sparc/sol2.mh: Likewise.
6322 * config/tilegx/linux.mh: Likewise.
6323 * config/vax/nbsdelf.mh: Likewise.
6324 * config/vax/obsd.mh: Likewise.
6325 * config/xtensa/linux.mh: Likewise.
6326 * config/i386/i386gnu.mn: New file, with excerpts from
6327 "config/i386/i386gnu.mh".
6328 * configure: Regenerate.
6329 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6330 *.mh files under "gdb/config".
6331 * configure.nat: New file, with contents from the
6332 "gdb/config/*/*.mh" files.
6333
7ed1acaf
TW
63342017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6335
6336 * btrace.c (btrace_clear): Free insn vector.
6337
e13cb306
PA
63382017-05-05 Pedro Alves <palves@redhat.com>
6339
6340 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6341 * configure: Regenerate.
6342
5ed8105e
PA
63432017-05-04 Pedro Alves <palves@redhat.com>
6344
6345 * Makefile.in (SFILES): Add progspace-and-thread.c.
6346 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6347 (COMMON_OBS): Add progspace-and-thread.o.
6348 * breakpoint.c: Include "progspace-and-thread.h".
6349 (update_inserted_breakpoint_locations)
6350 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6351 Use scoped_restore_current_pspace_and_thread.
6352 (create_std_terminate_master_breakpoint): Use
6353 scoped_restore_current_program_space.
6354 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6355 (print_breakpoint_location): Use
6356 scoped_restore_current_program_space.
6357 (bp_loc_is_permanent): Use
6358 scoped_restore_current_pspace_and_thread.
6359 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6360 (download_tracepoint_locations): Use
6361 scoped_restore_current_pspace_and_thread.
6362 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6363 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6364 (enum step_over_calls_kind): Moved from inferior.h.
6365 (class scoped_restore_current_thread): New class.
6366 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6367 declaration.
6368 (scoped_restore_current_thread): New class.
6369 * infcmd.c: Include "common/gdb_optional.h".
6370 (continue_1, proceed_after_attach): Use
6371 scoped_restore_current_thread.
6372 (notice_new_inferior): Use scoped_restore_current_thread.
6373 * inferior.c: Include "progspace-and-thread.h".
6374 (restore_inferior, save_current_inferior): Delete.
6375 (add_inferior_command, clone_inferior_command): Use
6376 scoped_restore_current_pspace_and_thread.
6377 * inferior.h (scoped_restore_current_inferior): New class.
6378 * infrun.c: Include "progspace-and-thread.h" and
6379 "common/gdb_optional.h".
6380 (follow_fork_inferior): Use
6381 scoped_restore_current_pspace_and_thread.
6382 (scoped_restore_exited_inferior): New class.
6383 (handle_vfork_child_exec_or_exit): Use
6384 scoped_restore_exited_inferior,
6385 scoped_restore_current_pspace_and_thread,
6386 scoped_restore_current_thread and scoped_restore.
6387 (fetch_inferior_event): Use scoped_restore_current_thread.
6388 * linespec.c (decode_line_full, decode_line_1): Use
6389 scoped_restore_current_program_space.
6390 * mi/mi-main.c: Include "progspace-and-thread.h".
6391 (exec_continue): Use scoped_restore_current_thread.
6392 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6393 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6394 * proc-service.c (ps_pglobal_lookup): Use
6395 scoped_restore_current_program_space.
6396 * progspace-and-thread.c: New file.
6397 * progspace-and-thread.h: New file.
6398 * progspace.c (release_program_space, clone_program_space): Use
6399 scoped_restore_current_program_space.
6400 (restore_program_space, save_current_program_space)
6401 (save_current_space_and_thread): Delete.
6402 (switch_to_program_space_and_thread): Moved to
6403 progspace-and-thread.c.
6404 * progspace.h (save_current_program_space)
6405 (save_current_space_and_thread): Delete declarations.
6406 (scoped_restore_current_program_space): New class.
6407 * remote.c (remote_btrace_maybe_reopen): Use
6408 scoped_restore_current_thread.
6409 * symtab.c: Include "progspace-and-thread.h".
6410 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6411 * thread.c (print_thread_info_1): Use
6412 scoped_restore_current_thread.
6413 (struct current_thread_cleanup): Delete.
6414 (do_restore_current_thread_cleanup)
6415 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6416 (scoped_restore_current_thread::~scoped_restore_current_thread):
6417 ... this new dtor.
6418 (make_cleanup_restore_current_thread): Rename/convert to ...
6419 (scoped_restore_current_thread::scoped_restore_current_thread):
6420 ... this new ctor.
6421 (thread_apply_all_command): Use scoped_restore_current_thread.
6422 (thread_apply_command): Use scoped_restore_current_thread.
6423 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
6424 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
6425
f6223dbb
PA
64262017-05-04 Pedro Alves <palves@redhat.com>
6427
6428 * thread.c (make_cleanup_restore_current_thread): Move
6429 find_thread_ptid call before the is_stopped call. Assert that the
6430 thread is found. Replace is_stopped call by checking the thread's
6431 state directly. Remove unnecessary NULL-thread check.
6432
3c3ae77e
PA
64332017-05-04 Pedro Alves <palves@redhat.com>
6434
6435 * corelow.c (thread_section_name): New class.
6436 (get_core_register_section, get_core_siginfo): Use it.
6437
45eba0ab
AA
64382017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
6439
6440 * corelow.c (sniff_core_bfd): Remove extra semicolon.
6441 (get_core_register_section): Remove xfree of NULL pointer.
6442
f81fdd35
AH
64432017-05-03 Alan Hayward <alan.hayward@arm.com>
6444
6445 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
6446 * regcache.c (regcache::raw_supply_zeroed): New function.
6447 * regcache.h (regcache::raw_supply_zeroed): New declaration.
6448
35837774
SM
64492017-05-03 Simon Marchi <simon.marchi@ericsson.com>
6450
6451 * gdbarch.sh: Remove commented out definition of
6452 TARGET_CHAR_BIT.
6453 * gdbarch.h: Re-generate.
6454
c94fee56
SDJ
64552017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6456
6457 * configure: Regenerate.
6458
d17f7b36
SM
64592017-05-02 Simon Marchi <simon.marchi@ericsson.com>
6460
6461 * solib-target.c (solib_target_relocate_section_addresses):
6462 Remove num_section_bases, num_bases, segment_bases variables.
6463
b560ebd6
SM
64642017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6465
6466 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
6467
f2f46dfc
SM
64682017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6469
6470 * solib-target.c: Include <vector>
6471 (struct lm_info_target) <~lm_info_target>: Remove.
6472 <segment_bases, section_bases>: Change type to
6473 std::vector<CORE_ADDR>.
6474 (library_list_start_segment, library_list_start_section,
6475 library_list_end_library,
6476 solib_target_relocate_section_addresses): Adjust.
6477
a0ff9e1a
SM
64782017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6479
6480 * gdbarch.sh (software_single_step): Change return type to
6481 std::vector<CORE_ADDR>.
6482 * gdbarch.c, gdbarch.h: Re-generate.
6483 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
6484 Adjust.
6485 (arm_deal_with_atomic_sequence_raw): Adjust.
6486 (thumb_get_next_pcs_raw): Adjust.
6487 (arm_get_next_pcs_raw): Adjust.
6488 (arm_get_next_pcs): Adjust.
6489 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
6490 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
6491 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
6492 (alpha_software_single_step): Adjust.
6493 * alpha-tdep.h (alpha_software_single_step): Adjust.
6494 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
6495 * arm-tdep.c (arm_software_single_step): Adjust.
6496 (arm_breakpoint_kind_from_current_state): Adjust.
6497 * arm-tdep.h (arm_software_single_step): Adjust.
6498 * breakpoint.c (insert_single_step_breakpoint): Adjust.
6499 * cris-tdep.c (cris_software_single_step): Adjust.
6500 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
6501 (micromips_deal_with_atomic_sequence): Adjust.
6502 (deal_with_atomic_sequence): Adjust.
6503 (mips_software_single_step): Adjust.
6504 * mips-tdep.h (mips_software_single_step): Adjust.
6505 * moxie-tdep.c (moxie_software_single_step): Adjust.
6506 * nios2-tdep.c (nios2_software_single_step): Adjust.
6507 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
6508 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
6509 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
6510 * s390-linux-tdep.c (s390_software_single_step): Adjust.
6511 * sparc-tdep.c (sparc_software_single_step): Adjust.
6512 * spu-tdep.c (spu_software_single_step): Adjust.
6513 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
6514
ea480a30
SM
65152017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6516
6517 * gdbarch.sh: Use semi-colon as field separator instead of colon.
6518 * gdbarch.h: Re-generate.
6519
d050f7d7
TW
65202017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6521
6522 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
6523 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
6524 * python/py-instruction.c, python/py-instruction.h: New file.
6525 * python/py-record.c: Add py-instruction.h include.
6526 (gdbpy_initialize_record): Make gdb.Instruction a super class of
6527 gdb.RecordInstruction.
6528 * python/python-internal.h: Add gdbpy_initialize_instruction
6529 declaration.
6530 * python/python.c (do_start_initialization): Add
6531 gdbpy_initialize_instruction.
6532
14f819c8
TW
65332017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6534
6535 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
6536 Remove.
6537 (btrace_func_from_recpy_func): New function.
6538 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
6539 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
6540 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
6541 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
6542 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
6543 Also, use new helper functions.
6544 (btpy_list_item): Use new helper functions.
6545 (recpy_bt_function_call_history): Use new type name.
6546 (btpy_call_getset): Remove.
6547 (gdbpy_initialize_btrace): Remove code to initialize
6548 gdb.BtraceFunctionCall.
6549 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
6550 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
6551 recpy_bt_func_prev, recpy_bt_func_next): New export.
6552 * python/py-record.c (recpy_func_type): New static object.
6553 (recpy_func_new, recpy_func_level, recpy_func_symbol,
6554 recpy_func_instructions, recpy_func_up, recpy_func_prev,
6555 recpy_func_next): New function.
6556 (recpy_element_hash, recpy_element_richcompare): Updated comment.
6557 (recpy_func_getset): New static object.
6558 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
6559 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
6560
0ed5da75
TW
65612017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6562
6563 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
6564 (btpy_object, btpy_insn_type, btpy_new): Remove.
6565 (btpy_list_object): Use gdb.RecordInstruction type instead of
6566 gdb.BtraceInstruction type.
6567 (btrace_insn_from_recpy_insn): New function.
6568 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
6569 btpy_new.
6570 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
6571 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
6572 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
6573 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
6574 instead of btpy_object.
6575 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6576 btpy_insn_data, btpy_insn_decode): Rename to ...
6577 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
6578 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
6579 recpy_bt_insn_decode): This. Also, use new helper functions.
6580 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
6581 recpy_insn_type.
6582 (btpy_insn_getset): Remove.
6583 (gdbpy_initialize_btrace): Remove code to initialize
6584 gdb.BtraceInstruction. Use recpy_element_object.
6585 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
6586 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
6587 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
6588 * python/py-record.c (recpy_insn_type): New static object.
6589 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
6590 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
6591 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
6592 New function.
6593 (recpy_insn_getset): New static object.
6594 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
6595 * python/py-record.h (recpy_element_object): New typedef.
6596 (recpy_insn_type, recpy_insn_new): New export.
6597
913aeadd
TW
65982017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6599
6600 * py-record-btrace.c (btpy_insn_new): Removed.
6601 (btpy_insn_or_gap_new): New function.
6602 (btpy_insn_error): Removed.
6603 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6604 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
6605 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
6606 btpy_insn_or_gap_new instead of btpy_insn_new.
6607 (btpy_insn_getset): Remove btpy_insn_error.
6608 * py-record.c (recpy_gap_type): New static object.
6609 (recpy_gap_object): New typedef.
6610 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
6611 recpy_gap_reason_string): New function.
6612 (recpy_gap_getset): New static object.
6613 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
6614 * py-record.h (recpy_gap_new): New export.
6615
a3be24ad
TW
66162017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6617
6618 * python/py-record.c (recpy_ptid): Remove.
6619 (recpy_record_getset): Remove recpy_ptid.
6620
ae20e79a
TW
66212017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6622
6623 * btrace.c (btrace_fetch): Set inferior_ptid.
6624 * python/py-record-btrace.c: Add "py-record.h" include.
6625 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
6626 recpy_bt_end, recpy_bt_instruction_history,
6627 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
6628 in gdb.Record object instead of current ptid.
6629 * python/py-record.c: Include new "py-record.h" file.
6630 (recpy_record_object): Moved to py-record.h.
6631 * python/py-record.h: New file.
6632
8d0050ea
TW
66332017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6634
6635 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
6636 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
6637 indentation.
6638
3f380b50
JB
66392017-05-01 Joel Brobecker <brobecker@adacore.com>
6640
6641 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
6642 the past maintainers section.
6643
07495424
YQ
66442017-04-28 Yao Qi <yao.qi@linaro.org>
6645
6646 * infcmd.c (get_return_value): Use regcache ctor, and remove
6647 cleanup.
6648
deb1fa3e
YQ
66492017-04-28 Yao Qi <yao.qi@linaro.org>
6650 Pedro Alves <palves@redhat.com>
6651
6652 * regcache.c (regcache::regcache): New tag dispatch ctor.
6653 (do_cooked_read): Moved above.
6654 (regcache_dup): Use the tag dispatch ctor..
6655 * regcache.h (regcache): Declare ctor, delete copy ctor and
6656 assignment operator, remove friend regcache_dup.
6657
b421c83c
YQ
66582017-04-28 Yao Qi <yao.qi@linaro.org>
6659
6660 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
6661 call method save instead of regcache_cpy.
6662 * regcache.h (struct regcache): Make regcache_dup a friend.
6663
ef79d9a3
YQ
66642017-04-28 Yao Qi <yao.qi@linaro.org>
6665
6666 * regcache.c (struct regcache): Move to regcache.h
6667 (regcache::arch): New method.
6668 (regcache_get_ptid): Update.
6669 (get_regcache_arch): Call arch method.
6670 (get_regcache_aspace): Call method aspace.
6671 (register_buffer): Change it to method.
6672 (regcache_save): Change it to regcache::save.
6673 (regcache_restore): Likewise.
6674 (regcache_cpy_no_passthrough): Remove the declaration.
6675 (regcache_cpy): Call methods restore and cpy_no_passthrough.
6676 (regcache_cpy_no_passthrough): Change it to method
6677 cpy_no_passthrough.
6678 (regcache_register_status): Change it to method
6679 get_register_status.
6680 (regcache_invalidate): Change it to method invalidate.
6681 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
6682 (regcache_raw_update): Change it to method raw_update.
6683 (regcache_raw_read): Likewise.
6684 (regcache_raw_read_signed): Likewise.
6685 (regcache_raw_read_unsigned): Likewise.
6686 (regcache_raw_write_signed): Likewise.
6687 (regcache_raw_write_unsigned): Likewise.
6688 (regcache_cooked_read): Likewise.
6689 (regcache_cooked_read_value): Likewise.
6690 (regcache_cooked_read_signed): Likewise.
6691 (regcache_cooked_read_unsigned): Likewise.
6692 (regcache_cooked_write_signed): Likewise.
6693 (regcache_cooked_write_unsigned): Likewise.
6694 (regcache_raw_set_cached_value): Likewise.
6695 (regcache_raw_write): Likewise.
6696 (regcache_cooked_write): Likewise.
6697 (regcache_xfer_part): Likewise.
6698 (regcache_raw_read_part): Likewise.
6699 (regcache_raw_write_part): Likewise.
6700 (regcache_cooked_read_part): Likewise.
6701 (regcache_cooked_write_part): Likewise.
6702 (regcache_raw_supply): Likewise.
6703 (regcache_raw_collect): Likewise.
6704 (regcache_transfer_regset): Likewise.
6705 (regcache_supply_regset): Likewise.
6706 (regcache_collect_regset): Likewise.
6707 (regcache_debug_print_register): Likewise.
6708 (enum regcache_dump_what): Move it to regcache.h.
6709 (regcache_dump): Change it to method dump.
6710 * regcache.h (enum regcache_dump_what): New.
6711 (class regcache): New.
6712 * target.c (target_fetch_registers): Call method
6713 debug_print_register.
6714 (target_store_registers): Likewise.
6715
f8fdb78e
SM
67162017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6717
6718 * windows-nat.c (struct lm_info_windows): Initialize field.
6719 (windows_make_so): Allocate lm_info_windows with new.
6720 (windows_free_so): Free lm_info_windows with delete.
6721
9ccbfd7b
SM
67222017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6723
6724 * solib-darwin.c (struct lm_info_darwin): Initialize field.
6725 (darwin_current_sos): Allocate lm_info_darwin with new, remove
6726 cleanup.
6727 (darwin_free_so): Free lm_info_darwin with delete.
6728
76e75227
SM
67292017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6730
6731 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
6732 <l_addr_p>: Change type to bool.
6733 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
6734 (svr4_free_so): Free lm_info_svr4 with delete.
6735 (svr4_copy_library_list): Replace memcpy with call to copy
6736 constructor.
6737 (library_list_start_library, svr4_default_sos): Allocate
6738 lm_info_svr4 with new.
6739
51046d9e
SM
67402017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6741
6742 * solib-target.c (struct lm_info_target): Add destructor,
6743 initialize fields.
6744 <name>: Change type to std::string.
6745 (library_list_start_library): Allocate lm_info_target with new.
6746 (solib_target_free_library_list): Free lm_info_target with
6747 delete.
6748 (solib_target_current_sos): Adapt to std::string.
6749 (solib_target_free_so): Free lm_info_target with delete.
6750
4023ae76
SM
67512017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6752
6753 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
6754 fields.
6755 (frv_current_sos): Allocate lm_info_frv with new.
6756 (frv_relocate_main_executable): Free lm_info_frv with delete,
6757 allocate with new.
6758 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
6759
af43057b
SM
67602017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6761
6762 * solib-frv.c (struct lm_info_frv): Fix indentation.
6763
b0911207
SM
67642017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6765
6766 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
6767 map field.
6768 (dsbt_current_sos): Allocate lm_info_dsbt with new.
6769 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
6770 and allocate with new.
6771 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
6772
6c401f72
SM
67732017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6774
6775 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
6776 <filename, member_name>: Change type to std::string.
6777 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
6778 (library_list_start_library): Allocate lm_info_aix with new.
6779 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
6780 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
6781 with copy constructor.
6782
d0e449a1
SM
67832017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6784
6785 * solist.h (struct lm_info): Remove.
6786 (struct lm_info_base): New class.
6787 (struct so_list) <lm_info>: Change type to lm_info_base *.
6788 * nto-tdep.c (struct lm_info): Remove.
6789 (lm_addr): Adjust.
6790 * solib-aix.c (struct lm_info): Rename to ...
6791 (struct lm_info_aix): ... this. Extend lm_info_base.
6792 (lm_info_p): Rename to ...
6793 (lm_info_aix_p): ... this, and adjust.
6794 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
6795 solib_aix_parse_libraries, library_list_start_library,
6796 solib_aix_free_library_list, solib_aix_parse_libraries,
6797 solib_aix_get_library_list,
6798 solib_aix_relocate_section_addresses, solib_aix_free_so,
6799 solib_aix_get_section_offsets,
6800 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
6801 Adjust.
6802 (struct solib_aix_inferior_data) <library_list>: Adjust.
6803 * solib-darwin.c (struct lm_info): Rename to ...
6804 (struct lm_info_darwin): ... this. Extend lm_info_base.
6805 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
6806 * solib-dsbt.c (struct lm_info): Rename to ...
6807 (struct lm_info_dsbt): ... this. Extend lm_info_base.
6808 (struct dsbt_info) <main_executable_lm_info): Adjust.
6809 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
6810 dsbt_relocate_section_addresses): Adjust.
6811 * solib-frv.c (struct lm_info): Rename to ...
6812 (struct lm_info_frv): ... this. Extend lm_info_base.
6813 (main_executable_lm_info): Adjust.
6814 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
6815 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
6816 find_canonical_descriptor_in_load_object,
6817 frv_fdpic_find_canonical_descriptor): Adjust.
6818 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
6819 to lm_info_svr4.
6820 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
6821 svr4_clear_so, svr4_copy_library_list,
6822 library_list_start_library, svr4_default_sos, svr4_read_so_list,
6823 svr4_current_sos, svr4_fetch_objfile_link_map,
6824 solist_update_incremental): Adjust.
6825 * solib-svr4.h (struct lm_info_svr4): Move here from
6826 solib-svr4.c.
6827 * solib-target.c (struct lm_info): Rename to ...
6828 (struct lm_info_target): ... this. Extend lm_info_base.
6829 (lm_info_p): Rename to ...
6830 (lm_info_target_p): ... this.
6831 (solib_target_parse_libraries, library_list_start_segment,
6832 library_list_start_section, library_list_start_library,
6833 library_list_end_library, solib_target_free_library_list,
6834 solib_target_current_sos, solib_target_free_so,
6835 solib_target_relocate_section_addresses): Adjust.
6836 * windows-nat.c (struct lm_info): Rename to ...
6837 (struct lm_info_windows): ... this. Extend lm_info_base.
6838 (windows_make_so, handle_load_dll, handle_unload_dll,
6839 windows_xfer_shared_libraries): Adjust.
6840
434a4023
SM
68412017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6842
6843 * solib-darwin.c (struct darwin_so_list): Remove.
6844 (darwin_current_sos): Allocate an so_list object instead of a
6845 darwin_so_list, separately allocate an lm_info object.
6846 (darwin_free_so): Free lm_info.
6847
428544e8
JB
68482017-04-28 John Baldwin <jhb@FreeBSD.org>
6849
6850 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
6851 with fprintf_filtered.
6852
4621115f
YQ
68532017-04-28 Yao Qi <yao.qi@linaro.org>
6854
6855 * regcache.c (regcache::regcache): New function.
6856 (regcache::~regcache): New function.
6857 (regcache_xmalloc_1): Remove.
6858 (regcache_xmalloc): Call new regcache.
6859 (regcache_xfree): Call delete regcache.
6860 (get_thread_arch_aspace_regcache): Call new regcache.
6861
339053c2
YQ
68622017-04-28 Yao Qi <yao.qi@linaro.org>
6863
6864 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
6865 lwp instead of ptid_get_lwp.
6866
7974a605
YQ
68672017-04-28 Yao Qi <yao.qi@linaro.org>
6868
6869 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
6870 lwp_info instead of getting from inferior_ptid.
6871
e15c3eb4
KS
68722017-04-27 Keith Seitz <keiths@redhat.com>
6873
6874 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
6875 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
6876 (CV_CONVERSION_BADNESS): Define.
6877 (rank_one_type): Remove overly restrictive rvalue reference
6878 rank checks.
6879 Add cv-qualifier checks and subranks for type equality.
6880 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
6881 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
6882 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
6883
72bc1d24
SM
68842017-04-27 Simon Marchi <simon.marchi@ericsson.com>
6885
6886 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
6887 count when creating the object.
6888
55bcecda
UW
68892017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
6890 Ulrich Weigand <uweigand@de.ibm.com>
6891
6892 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
6893 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
6894 is used in AIX.
6895 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
6896 (process_xcoff_symbol): Likewise.
6897 (scan_xcoff_symtab): Likewise.
6898
5c99fcf8
AH
68992017-04-26 Alan Hayward <alan.hayward@arm.com>
6900
6901 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
6902 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
6903 (ia64_access_reg): Use get_frame_register_unsigned.
6904 (ia64_access_rse_reg): Likewise.
6905 (ia64_libunwind_frame_prev_register): Likewise.
6906
b41c5a85
JW
69072017-04-26 Jiong Wang <jiong.wang@arm.com>
6908
6909 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
6910 * gdbarch.c: Regenerated.
6911 * gdbarch.h: Regenerated.
6912 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
6913 visibility external.
6914 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
6915 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
6916 (enum cfa_how_kind): Move to ...
6917 (struct dwarf2_frame_state_reg_info): Likewise.
6918 (struct dwarf2_frame_state): Likewise.
6919 * dwarf2-frame.h: ... here.
6920 (dwarf2_frame_state_alloc_regs): New declaration.
6921 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
6922 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
6923
c185f580
AH
69242017-04-26 Alan Hayward <alan.hayward@arm.com>
6925
6926 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
6927 regcache_raw_read_unsigned.
6928 (xtensa_pseudo_register_write): Likewise.
6929
19c45594
AH
69302017-04-26 Alan Hayward <alan.hayward@arm.com>
6931
6932 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
6933 (nds32_pseudo_register_write): Likewise.
6934
4658f12e
YQ
69352017-04-25 Yao Qi <yao.qi@linaro.org>
6936
6937 * regcache.c (struct regcache) <readonly_p>: Change its type
6938 to bool.
6939 (regcache_xmalloc_1): Update parameter type and callers update.
6940
d581dda8
YQ
69412017-04-25 Yao Qi <yao.qi@linaro.org>
6942
6943 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
6944 set_gdbarch_wchar_bit.
6945 * arm-tdep.c (arm_gdbarch_init): Likewise.
6946
debed3db
PA
69472017-04-25 Pedro Alves <palves@redhat.com>
6948
6949 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
6950 (BothAreRelocatable, memcopy, memmove): Don't define.
6951 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
6952 macros.
6953
b0b92aeb
PA
69542017-04-25 Pedro Alves <palves@redhat.com>
6955
6956 * common/common-defs.h: Include "common/poison.h".
6957 * common/function-view.h: (Not, Or, Requires): Move to traits.h
6958 and adjust.
6959 * common/poison.h: New file.
6960 * common/traits.h: Include <type_traits>.
6961 (Not, Or, Requires): New, moved from common/function-view.h.
6962
16c4d54a
PA
69632017-04-25 Pedro Alves <palves@redhat.com>
6964
6965 * breakpoint.h (struct breakpoint): In-class initialize all
6966 fields. Make boolean fields "bool".
6967 * breakpoint.c (init_raw_breakpoint_without_location): Remove
6968 memset call and initializations no longer necessary.
6969
b5c36682
PA
69702017-04-25 Pedro Alves <palves@redhat.com>
6971
6972 * btrace.c (pt_btrace_insn_flags): Change parameter type to
6973 reference.
6974 (pt_btrace_insn): New function.
6975 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
6976
5625a286
PA
69772017-04-25 Pedro Alves <palves@redhat.com>
6978
6979 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
6980 "base" field and inherit from "bp_location" instead. Add
6981 non-default ctor.
6982 (allocate_location_exception): Use new non-default ctor.
6983 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
6984 (init_bp_location): Convert to ...
6985 (bp_location::bp_location): ... this new ctor, and remove memset
6986 call.
6987 (base_breakpoint_allocate_location): Use the new non-default ctor.
6988 * breakpoint.h (bp_location): Now a class. Declare default and
6989 non-default ctors. In-class initialize all members.
6990 (init_bp_location): Remove declaration.
6991
23bcc18f
PA
69922017-04-25 Pedro Alves <palves@redhat.com>
6993
6994 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
6995 assignment operator.
6996
e1ba3053
YQ
69972017-04-24 Yao Qi <yao.qi@linaro.org>
6998
6999 * doublest.c (convert_doublest_to_floatformat): Call
7000 floatformat_totalsize_bytes.
7001
10f489e5
TT
70022017-04-22 Tom Tromey <tom@tromey.com>
7003
7004 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7005 ui_out_emit_list.
7006 * stack.c (print_frame): Use ui_out_emit_list.
7007 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7008 ui_out_emit_list.
7009 * mi/mi-main.c (print_one_inferior)
7010 (mi_cmd_data_list_register_names)
7011 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7012 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7013 ui_out_emit_list.
7014 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7015 (mi_output_solib_attribs): Use ui_out_emit_list,
7016 ui_out_emit_tuple.
7017 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7018 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7019 (mi_cmd_stack_list_args, list_args_or_locals): Use
7020 ui_out_emit_list.
7021 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7022 * breakpoint.c (print_solib_event, output_thread_groups): Use
7023 ui_out_emit_list.
7024
0092b74d
TT
70252017-04-22 Tom Tromey <tom@tromey.com>
7026
7027 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7028 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7029 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7030
a14a62dd
TT
70312017-04-22 Tom Tromey <tom@tromey.com>
7032
7033 * tracepoint.c (tvariables_info_1)
7034 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7035
46b9c129
TT
70362017-04-22 Tom Tromey <tom@tromey.com>
7037
7038 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7039 annotate_arg_emitter.
7040 * breakpoint.c (print_mention_watchpoint)
7041 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7042 * annotate.h (struct annotate_arg_emitter): New.
7043
2e783024
TT
70442017-04-22 Tom Tromey <tom@tromey.com>
7045
7046 * record-btrace.c (record_btrace_insn_history)
7047 (record_btrace_insn_history_range, record_btrace_call_history)
7048 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7049 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7050 ui_out_emit_tuple.
7051 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7052 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7053 * skip.c (skip_info): Use ui_out_emit_tuple.
7054 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7055 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7056 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7057 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7058 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7059 ui_out_emit_tuple.
7060 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7061 (output_register, mi_cmd_data_read_memory)
7062 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7063 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7064 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7065 Use ui_out_emit_tuple.
7066 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7067 ui_out_emit_tuple.
7068 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7069 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7070 * linux-thread-db.c (info_auto_load_libthread_db): Use
7071 ui_out_emit_tuple.
7072 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7073 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7074 * disasm.c (do_mixed_source_and_assembly_deprecated)
7075 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7076 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7077 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7078 * breakpoint.c (print_one_breakpoint_location)
7079 (print_one_breakpoint): Use ui_out_emit_tuple.
7080 * auto-load.c (print_script, info_auto_load_cmd): Use
7081 ui_out_emit_tuple.
7082 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7083
9be21bb4
SM
70842017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7085
7086 * thread.c (print_thread_info_1): Remove dead code.
7087
0d4c07af
JK
70882017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7089
7090 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7091 GDB_SELF_TEST.
7092 * arm-tdep.c (selftests::arm_record_test): Likewise.
7093
4daf993d
YQ
70942017-04-21 Yao Qi <yao.qi@linaro.org>
7095
7096 * regcache.c (regcache_restore): Remove argument 2. Replace
7097 argument 3 with regcache. Get register status from
7098 src->register_status and get register contents from
7099 register_buffer (src, regnum).
7100 (regcache_cpy): Update.
7101
a6c21d4a
PA
71022017-04-19 Pedro Alves <palves@redhat.com>
7103
7104 * gdbthread.h (thread): Add missing closing parenthesis in
7105 comment.
7106
3a3fd0fd
PA
71072017-04-19 Pedro Alves <palves@redhat.com>
7108
7109 * common/refcounted-object.h: New file.
7110 * gdbthread.h: Include "common/refcounted-object.h".
7111 (thread_info): Inherit from refcounted_object and add comments.
7112 (thread_info::incref, thread_info::decref)
7113 (thread_info::m_refcount): Delete.
7114 (thread_info::deletable): Use the refcounted_object::refcount()
7115 method.
7116 * inferior.c (current_inferior_): Add comment.
7117 (set_current_inferior): Increment/decrement refcounts.
7118 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7119 not-deletable instead of comparing with the current inferior.
7120 (initialize_inferiors): Increment the initial inferior's refcount.
7121 * inferior.h (struct inferior): Forward declare.
7122 Include "common/refcounted-object.h".
7123 (current_inferior, set_current_inferior): Move declaration to
7124 before struct inferior's definition, and fix comment.
7125 (inferior): Inherit from refcounted_object. Add comments.
7126 * thread.c (switch_to_thread_no_regs): Reference the thread's
7127 inferior pointer directly instead of doing a ptid lookup.
7128 (switch_to_no_thread): New function.
7129 (switch_to_thread(thread_info *)): New function, factored out
7130 from ...
7131 (switch_to_thread(ptid_t)): ... this.
7132 (restore_current_thread): Delete.
7133 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7134 fields, and add 'inf' field.
7135 (do_restore_current_thread_cleanup): Check whether old->inf is
7136 alive instead of looking up an inferior by ptid. Use
7137 switch_to_thread and switch_to_no_thread.
7138 (restore_current_thread_cleanup_dtor): Use old->inf directly
7139 instead of lookup up an inferior by id. Decref the inferior.
7140 Don't restore 'removable'.
7141 (make_cleanup_restore_current_thread): Same the inferior pointer
7142 in old, instead of the inferior number. Incref the inferior.
7143 Don't save/clear 'removable'.
7144
9bcb1f16
PA
71452017-04-19 Pedro Alves <palves@redhat.com>
7146
7147 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7148 unittests/scoped_restore-selftests.c.
7149 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7150 * common/scoped_restore.h (scoped_restore_base): Make "class".
7151 (scoped_restore_base::release): New public method.
7152 (scoped_restore_base::scoped_restore_base): New protected ctor.
7153 (scoped_restore_base::m_saved_var): New protected field.
7154 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7155 scoped_restore_base base class instead of m_saved_var directly.
7156 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7157 (scoped_restore_tmpl::scoped_restore_tmpl(const
7158 scoped_restore_tmpl<T>&)): Likewise.
7159 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7160 method.
7161 (scoped_restore_tmpl::saved_var): New method.
7162 (scoped_restore_tmpl::m_saved_var): Delete.
7163 * inferior.h (inferior::detaching): Now a bool.
7164 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7165 cleanup.
7166 * unittests/scoped_restore-selftests.c: New file.
7167
26fcd539
PA
71682017-04-19 Pedro Alves <palves@redhat.com>
7169
7170 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7171 Re-sort in alphabetic order.
7172
fdd243b0
PA
71732017-04-18 Pedro Alves <palves@redhat.com>
7174
7175 * xml-support.c (obstack_xml_printf): Delete.
7176 * xml-support.h (obstack_xml_printf): Delete.
7177
4895cde2
PA
71782017-04-18 Pedro Alves <palves@redhat.com>
7179
7180 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7181 vdebug, verror, body_text, start_element, end_element, name,
7182 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7183 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7184 is_xinclude>: Make private and add m_ prefix.
7185 (gdb_xml_parser::body_text): New method, based on ...
7186 (gdb_xml_body_text): ... this. Adjust.
7187 (gdb_xml_parser::vdebug): New method, based on ...
7188 (gdb_xml_debug): ... this. Adjust.
7189 (gdb_xml_parser::verror): New method, based on ...
7190 (gdb_xml_error): ... this. Adjust.
7191 (gdb_xml_parser::start_element): New method, based on ...
7192 (gdb_xml_start_element): ... this. Adjust.
7193 (gdb_xml_start_element_wrapper): Defer to
7194 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7195 (gdb_xml_parser::end_element): New method, based on ...
7196 (gdb_xml_end_element_wrapper): ... this. Adjust.
7197 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7198 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7199 (gdb_xml_parser::use_dtd): New method, based on ...
7200 (gdb_xml_use_dtd): ... this. Adjust.
7201 (gdb_xml_parser::parse): New method, based on ...
7202 (gdb_xml_parse): ... this. Adjust.
7203 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7204 (xinclude_start_include): Adjust to call the parser's name method.
7205 (xml_xinclude_default, xml_xinclude_start_doctype)
7206 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7207 method.
7208 (xml_process_xincludes): Adjust to call parser methods.
7209 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7210 declarations.
7211
bd8a901f
PA
72122017-04-18 Pedro Alves <palves@redhat.com>
7213
7214 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7215 gdb::optional<std::string>.
7216 * xml-support.c: Include <string>.
7217 (scope_level::scope_level(scope_level &&))
7218 (scope_level::~scope_level): Delete.
7219 (scope_level::body): Now a std::string.
7220 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7221 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7222 parameter.
7223 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7224 (xinclude_parsing_data::output): Now a std::string reference.
7225 (xinclude_start_include): Adjust.
7226 (xml_xinclude_default): Adjust.
7227 (xml_process_xincludes): Add 'output' parameter, and return bool.
7228 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7229 and return bool.
7230 * xml-tdesc.c: Include <unordered_map> and <string>.
7231 (tdesc_xml_cache): Delete.
7232 (tdesc_xml_cache_s): Delete.
7233 (xml_cache): Now an std::unordered_map.
7234 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7235 (target_fetch_description_xml): Change return type to
7236 gdb::optional<std::string>, and adjust.
7237 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7238 (target_fetch_description_xml): Change return type to
7239 gdb::optional<std::string>.
7240
d35d1958
PA
72412017-04-18 Pedro Alves <palves@redhat.com>
7242
7243 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7244 unittests/optional-selftests.c.
7245 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7246 * unittests/optional-selftests.c: New file.
7247 * unittests/optional/assignment/1.cc: New file.
7248 * unittests/optional/assignment/2.cc: New file.
7249 * unittests/optional/assignment/3.cc: New file.
7250 * unittests/optional/assignment/4.cc: New file.
7251 * unittests/optional/assignment/5.cc: New file.
7252 * unittests/optional/assignment/6.cc: New file.
7253 * unittests/optional/assignment/7.cc: New file.
7254 * unittests/optional/cons/copy.cc: New file.
7255 * unittests/optional/cons/default.cc: New file.
7256 * unittests/optional/cons/move.cc: New file.
7257 * unittests/optional/cons/value.cc: New file.
7258 * unittests/optional/in_place.cc: New file.
7259 * unittests/optional/observers/1.cc: New file.
7260 * unittests/optional/observers/2.cc: New file.
7261
22796e97
PA
72622017-04-18 Pedro Alves <palves@redhat.com>
7263
7264 * common/gdb_optional.h: Include common/traits.h.
7265 (in_place_t): New type.
7266 (in_place): New constexpr variable.
7267 (optional::optional): Remove member initialization of
7268 m_instantiated.
7269 (optional::optional(in_place_t...)): New constructor.
7270 (optional::~optional): Use reset.
7271 (optional::optional(const optional&)): New.
7272 (optional::optional(const optional&&)): New.
7273 (optional::optional(T &)): New.
7274 (optional::optional(T &&)): New.
7275 (operator::operator=(const optional &)): New.
7276 (operator::operator=(optional &&)): New.
7277 (operator::operator= (const T &))
7278 (operator::operator= (T &&))
7279 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7280 (operator::reset): New.
7281 (operator::m_instantiated):: Add in-class initializer.
7282 * common/traits.h: Include <type_traits>.
7283 (struct And): New types.
7284
a7fc9b61
PA
72852017-04-18 Pedro Alves <palves@redhat.com>
7286
7287 * xml-support.c: Include <vector>.
7288 (scope_level::scope_level(const gdb_xml_element *))
7289 (scope_level::scope_level(scope_level&&)): New.
7290 (scope_level::~scope_level): New.
7291 (scope_level_s): Delete.
7292 (gdb_xml_parser::scopes): Now a std::vector.
7293 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7294 Use std::vector.
7295 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7296 scope cleanup code.
7297 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7298 of the scopes member. Use std::vector::emplace_back.
7299
010151c9
PA
73002017-04-18 Pedro Alves <palves@redhat.com>
7301
7302 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7303 a bool.
7304 (gdb_xml_end_element): Change type of first parameter.
7305 (gdb_xml_cleanup): Rename to ...
7306 (gdb_xml_parser::~gdb_xml_parser): ... this.
7307 (gdb_xml_create_parser_and_cleanup): Delete with ...
7308 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7309 to this new ctor.
7310 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7311 using gdb_xml_create_parser_and_cleanup.
7312 (xinclude_parsing_data): Add ctor/dtor.
7313 (xml_xinclude_cleanup): Delete.
7314 (xml_process_xincludes): Create a local xinclude_parsing_data
7315 instead of heap-allocating one. Create a local gdb_xml_parser
7316 instead of heap-allocating one with
7317 gdb_xml_create_parser_and_cleanup.
7318
d56060f0
JB
73192017-04-18 John Baldwin <jhb@FreeBSD.org>
7320
7321 PR threads/20743
7322 * fbsd-nat.c (resume_one_thread_cb): Remove.
7323 (resume_all_threads_cb): Remove.
7324 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7325 iterate_over_threads.
7326
305d16a9
JB
73272017-04-17 Joel Brobecker <brobecker@adacore.com>
7328
7329 * NEWS: Create a new section for the next release branch.
7330 Rename the section of the current branch, now that it has
7331 been cut.
7332
8bb57231
JB
73332017-04-17 Joel Brobecker <brobecker@adacore.com>
7334
7335 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7336 * version.in: Bump version to 8.0.50.DATE-git.
7337
096c92dd
SDJ
73382017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7339
7340 PR gdb/21385
7341 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7342 independently of the host, and fix build breakage on Cygwin.
7343
0550c955
PA
73442017-04-13 Pedro Alves <palves@redhat.com>
7345
7346 * inferior.c (free_inferior): Convert to ...
7347 (inferior::~inferior): ... this dtor.
7348 (inferior::inferior): New ctor, factored out from ...
7349 (add_inferior_silent): ... here. Allocate the inferior with a new
7350 expression.
7351 (delete_inferior): Call delete instead of free_inferior.
7352 * inferior.h (gdb_environ, continuation): Forward declare.
7353 (inferior): Now a class. Add in-class initialization to all
7354 members. Make boolean fields bool, except 'detaching'.
7355 (inferior::inferior): New explicit ctor.
7356 (inferior::~inferior): New.
7357
e3d60dfc
PA
73582017-04-13 Pedro Alves <palves@redhat.com>
7359
7360 * inferior.c (init_inferior_list): Delete.
7361 * inferior.h (init_inferior_list): Delete.
7362
5fd69d0a
PA
73632017-04-13 Pedro Alves <palves@redhat.com>
7364
7365 PR threads/13217
7366 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7367 (top level): Call it twice, with different thread sets.
7368
c6609450
PA
73692017-04-13 Pedro Alves <palves@redhat.com>
7370
7371 * thread.c: Include <algorithm>.
7372 (thread_array_cleanup): Delete.
7373 (scoped_inc_dec_ref): New class.
7374 (live_threads_count): New function.
7375 (set_thread_refcount): Delete.
7376 (tp_array_compar_ascending): Now a bool.
7377 (tp_array_compar): Convert to a std::sort comparison function.
7378 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7379 and live_threads_count.
7380
2a00d7ce
PA
73812017-04-13 Pedro Alves <palves@redhat.com>
7382
7383 * infrun.c (follow_fork_inferior): Also switch the current
7384 inferior.
7385
441d7c93
PA
73862017-04-13 Pedro Alves <palves@redhat.com>
7387
7388 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7389 before calling create_internal_breakpoint.
7390
808480f6
PA
73912017-04-13 Pedro Alves <palves@redhat.com>
7392
7393 * fork-child.c (execv_argv): New class.
7394 (breakup_args): Refactored as ...
7395 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7396 Copy arguments to storage and replace separators with NULL
7397 terminators in place.
7398 (escape_bang_in_quoted_argument): Adjust to return bool.
7399 (execv_argv::execv_argv): New ctor.
7400 (execv_argv::init_for_shell): New method, factored out from
7401 fork_inferior. Don't strdup strings into the vector.
7402 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7403 Remove free_vector_argv call.
7404
ad3d022a
YQ
74052017-04-13 Yao Qi <yao.qi@linaro.org>
7406
7407 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7408 tdep->rx_psw_type.
7409
e6ddc3bf
YQ
74102017-04-13 Yao Qi <yao.qi@linaro.org>
7411
7412 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7413 * rx-tdep.c (rx_gdbarch_init): Likewise.
7414
bfb8cf90
PA
74152017-04-13 Pedro Alves <palves@redhat.com>
7416
7417 * breakpoint.h (struct breakpoint): Reindent.
7418
f5336ca5
PA
74192017-04-13 Pedro Alves <palves@redhat.com>
7420
7421 * breakpoint.c (bp_location): Rename to ...
7422 (bp_locations): ... this. All references updated.
7423 (bp_location_count): Rename to ...
7424 (bp_locations_count): ... this. All references updated.
7425 (bp_location_placed_address_before_address_max): Rename to ...
7426 (bp_locations_placed_address_before_address_max): ... this. All
7427 references updated.
7428 (bp_location_shadow_len_after_address_max): Rename to ...
7429 (bp_locations_shadow_len_after_address_max): ... this. All
7430 references updated.
7431 (bp_location_compare_addrs): Rename to ...
7432 (bp_locations_compare_addrs): ... this. All references updated.
7433 (bp_location_compare):Rename to ...
7434 (bp_locations_compare): ... this. All references updated.
7435 (bp_location_target_extensions_update): Rename to ...
7436 (bp_locations_target_extensions_update): ... this. All references
7437 updated.
7438
be628ab8
SDJ
74392017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7440
7441 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
7442 * common/common.m4: Check headers 'termios.h', 'termio.h' and
7443 'sgtty.h'.
7444 * common/gdb_termios.h: New file, with parts of "terminal.h".
7445 * inflow.c: Include "gdb_termios.h".
7446 * ser-unix.c: Include "gdb_termios.h".
7447 * terminal.h: Move terminal-related defines to
7448 "common/gdb_termios.h".
7449
8e9e35b1
TT
74502017-04-12 Tom Tromey <tom@tromey.com>
7451
7452 * probe.c (parse_probes): Update.
7453 * location.h (delete_event_location): Don't declare.
7454 (event_location_deleter::operator()): Update.
7455 * location.c (event_location_deleter::operator()): Rename from
7456 delete_event_location.
7457 * linespec.h (linespec_result) <location>: Change type to
7458 event_location_up.
7459 * linespec.c (canonicalize_linespec, event_location_to_sals)
7460 (decode_objc): Update.
7461 (linespec_result): Don't call delete_event_location.
7462 * breakpoint.c (create_breakpoints_sal)
7463 (bkpt_probe_create_sals_from_location)
7464 (strace_marker_create_sals_from_location): Update.
7465
16e802b9
TT
74662017-04-12 Tom Tromey <tom@tromey.com>
7467
7468 * linespec.h (struct linespec_result): Add constructor and
7469 destructor.
7470 (init_linespec_result, destroy_linespec_result)
7471 (make_cleanup_destroy_linespec_result): Don't declare.
7472 * linespec.c (init_linespec_result): Remove.
7473 (linespec_result::~linespec_result): Rename from
7474 destroy_linespec_result. Update.
7475 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
7476 Remove.
7477 * breakpoint.c (create_breakpoint, break_range_command)
7478 (decode_location_default): Update.
7479 * ax-gdb.c (agent_command_1): Update.
7480
d28cd78a
TT
74812017-04-12 Tom Tromey <tom@tromey.com>
7482
7483 * remote.c (remote_download_tracepoint): Update.
7484 * python/py-breakpoint.c (bppy_get_location): Update.
7485 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
7486 (gdbscm_breakpoint_location): Update.
7487 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
7488 * breakpoint.h (struct breakpoint) <location, location_range_end>:
7489 Change type to event_location_up.
7490 * breakpoint.c (create_overlay_event_breakpoint)
7491 (create_longjmp_master_breakpoint)
7492 (create_std_terminate_master_breakpoint)
7493 (create_exception_master_breakpoint)
7494 (breakpoint_event_location_empty_p, print_breakpoint_location)
7495 (print_one_breakpoint_location, create_thread_event_breakpoint)
7496 (init_breakpoint_sal, create_breakpoint)
7497 (print_recreate_ranged_breakpoint, break_range_command)
7498 (init_ada_exception_breakpoint, say_where): Update.
7499 (base_breakpoint_dtor): Don't call delete_event_location.
7500 (bkpt_print_recreate, tracepoint_print_recreate)
7501 (dprintf_print_recreate, update_static_tracepoint)
7502 (breakpoint_re_set_default): Update.
7503
711799d5
TT
75042017-04-12 Tom Tromey <tom@tromey.com>
7505
7506 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
7507 type of "to_do". Update.
7508 (compute_stack_depth): Use std::vector.
7509
52d214d3
TT
75102017-04-12 Tom Tromey <tom@tromey.com>
7511
7512 * printcmd.c (find_instruction_backward): Use std::vector.
7513
4c404b8b
TT
75142017-04-12 Tom Tromey <tom@tromey.com>
7515
7516 * symfile.c (objfilep): Remove typedef.
7517 (reread_symbols): Use a std::vector.
7518
156d9eab
TT
75192017-04-12 Tom Tromey <tom@tromey.com>
7520
7521 * mi/mi-main.c (exec_direction_forward): Remove.
7522 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
7523 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7524 scoped_restore.
7525 * guile/guile.c (guile_repl_command, guile_command)
7526 (gdbscm_execute_gdb_command): Use scoped_restore.
7527 * go-exp.y (go_parse): Use scoped_restore.
7528 * d-exp.y (d_parse): Use scoped_restore.
7529 * cli/cli-decode.c (cmd_func): Use scoped_restore.
7530 * c-exp.y (c_parse): Use scoped_restore.
7531
4d89769a
TT
75322017-04-12 Tom Tromey <tom@tromey.com>
7533
7534 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
7535 (mi_parse): Update return type.
7536 (mi_parse_free): Remove.
7537 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
7538 (mi_parse::~mi_parse): Rename from mi_parse_free.
7539 (mi_parse_cleanup): Remove.
7540 (mi_parse): Return a unique_ptr. Use new.
7541 * mi/mi-main.c (mi_execute_command): Update.
7542
4b217cc7
TT
75432017-04-12 Tom Tromey <tom@tromey.com>
7544
7545 * location.c (explicit_location_lex_one): Return a
7546 unique_xmalloc_ptr.
7547 (string_to_explicit_location): Update. Remove cleanups.
7548
59d3651b
TT
75492017-04-12 Tom Tromey <tom@tromey.com>
7550
7551 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
7552 (compare_value_and_voffset): Change type. Update.
7553 (compute_vtable_size): Change type of "offset_vec".
7554 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
7555 (gnuv3_get_typeid): Remove extraneous declaration.
7556
b24b0d6c
TT
75572017-04-12 Tom Tromey <tom@tromey.com>
7558
7559 * charset.h (wchar_iterator): Fix comment.
7560
80a3b8c5
TT
75612017-04-12 Tom Tromey <tom@tromey.com>
7562
7563 * charset.c (iconv_wrapper): New class.
7564 (cleanup_iconv): Remove.
7565 (convert_between_encodings): Use it.
7566
c83dd867
TT
75672017-04-12 Tom Tromey <tom@tromey.com>
7568
7569 * symfile.h (increment_reading_symtab): Update type.
7570 * symfile.c (decrement_reading_symtab): Remove.
7571 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
7572 * psymtab.c (psymtab_to_symtab): Update.
7573 * dwarf2read.c (dw2_instantiate_symtab): Update.
7574
0e8621a0
TT
75752017-04-12 Tom Tromey <tom@tromey.com>
7576
7577 * jit.c (struct jit_reader): Declare separately. Add constructor
7578 and destructor. Change type of "handle".
7579 (loaded_jit_reader): Define separately.
7580 (jit_reader_load): Update. New "new".
7581 (jit_reader_unload_command): Use "delete".
7582 * gdb-dlfcn.h (struct dlclose_deleter): New.
7583 (gdb_dlhandle_up): New typedef.
7584 (gdb_dlopen, gdb_dlsym): Update types.
7585 (gdb_dlclose): Remove.
7586 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
7587 (gdb_dlsym): Change type of "handle".
7588 (make_cleanup_dlclose): Remove.
7589 (dlclose_deleter::operator()): Rename from gdb_dlclose.
7590 * compile/compile-c-support.c (load_libcc): Update.
7591
67d89901
TT
75922017-04-12 Tom Tromey <tom@tromey.com>
7593
7594 * symtab.h (find_pcs_for_symtab_line): Change return type.
7595 * symtab.c (find_pcs_for_symtab_line): Change return type.
7596 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
7597 type of "vec". Update.
7598 (ltpy_get_pcs_for_line): Update.
7599 * linespec.c (decode_digits_ordinary): Update.
7600
93921405
TT
76012017-04-12 Tom Tromey <tom@tromey.com>
7602
7603 * tracepoint.c (actions_command): Update.
7604 * python/python.c (python_command, python_interactive_command):
7605 Update.
7606 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7607 * guile/guile.c (guile_command): Update.
7608 * defs.h (read_command_lines, read_command_lines_1): Return
7609 command_line_up.
7610 (command_lines_deleter): New struct.
7611 (command_line_up): New typedef.
7612 * compile/compile.c (compile_code_command)
7613 (compile_print_command): Update.
7614 * cli/cli-script.h (get_command_line, copy_command_lines): Return
7615 command_line_up.
7616 (make_cleanup_free_command_lines): Remove.
7617 * cli/cli-script.c (get_command_line, read_command_lines_1)
7618 (copy_command_lines): Return command_line_up.
7619 (while_command, if_command, read_command_lines, define_command)
7620 (document_command): Update.
7621 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
7622 Remove.
7623 * breakpoint.h (breakpoint_set_commands): Change type of
7624 "commands".
7625 * breakpoint.c (breakpoint_set_commands): Change type of
7626 "commands". Update.
7627 (do_map_commands_command, update_dprintf_command_list)
7628 (create_tracepoint_from_upload): Update.
7629
ffc2605c
TT
76302017-04-12 Tom Tromey <tom@tromey.com>
7631
7632 * tracepoint.c (scope_info): Update.
7633 * spu-tdep.c (spu_catch_start): Update.
7634 * python/python.c (gdbpy_decode_line): Update.
7635 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
7636 * python/py-breakpoint.c (bppy_init): Update.
7637 * probe.c (parse_probes): Update.
7638 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
7639 * location.h (event_location_deleter): New struct.
7640 (event_location_up): New typedef.
7641 (new_linespec_location, new_address_location, new_probe_location)
7642 (new_explicit_location, copy_event_location)
7643 (string_to_event_location, string_to_event_location_basic)
7644 (string_to_explicit_location): Update return type.
7645 (make_cleanup_delete_event_location): Remove.
7646 * location.c (new_linespec_location, new_address_location)
7647 (new_probe_location, new_explicit_location, copy_event_location):
7648 Return event_location_up.
7649 (delete_event_location_cleanup)
7650 (make_cleanup_delete_event_location): Remove.
7651 (string_to_explicit_location, string_to_event_location_basic)
7652 (string_to_event_location): Return event_location_up.
7653 * linespec.c (canonicalize_linespec, event_location_to_sals)
7654 (decode_line_with_current_source)
7655 (decode_line_with_last_displayed, decode_objc): Update.
7656 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
7657 * completer.c (location_completer): Update.
7658 * cli/cli-cmds.c (edit_command, list_command): Update.
7659 * breakpoint.c (create_overlay_event_breakpoint)
7660 (create_longjmp_master_breakpoint)
7661 (create_std_terminate_master_breakpoint)
7662 (create_exception_master_breakpoint)
7663 (create_thread_event_breakpoint): Update.
7664 (init_breakpoint_sal): Update. Remove some dead code.
7665 (create_breakpoint_sal): Change type of "location". Update.
7666 (create_breakpoints_sal, create_breakpoint, break_command_1)
7667 (dprintf_command, break_range_command, until_break_command)
7668 (init_ada_exception_breakpoint)
7669 (strace_marker_create_sals_from_location)
7670 (update_static_tracepoint, trace_command, ftrace_command)
7671 (strace_command, create_tracepoint_from_upload): Update.
7672 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7673 * ax-gdb.c (agent_command_1): Update.
7674
8f10c932
PA
76752017-04-12 Pedro Alves <palves@redhat.com>
7676
7677 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
7678 * configure.tgt: Handle i[34567]86-*-go32* and
7679 i[34567]86-*-msdosdjgpp*.
7680 * i386-tdep.c (i386_svr4_reg_to_regnum):
7681 Make extern.
7682 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
7683 i386-go32-tdep.c.
7684 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
7685 * i386-go32-tdep.c: New file.
7686 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
7687 declarations.
7688
0a31ccfb
SM
76892017-04-12 Simon Marchi <simon.marchi@ericsson.com>
7690
7691 * aix-thread.c (pd_status2str): Change return type to const char *.
7692
e9bb3fbb
PA
76932017-04-12 Pedro Alves <palves@redhat.com>
7694
7695 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
7696 calls to set_gdbarch_gnu_triplet_regexp.
7697
53375380
PA
76982017-04-12 Pedro Alves <palves@redhat.com>
7699
7700 PR gdb/21323
7701 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
7702 New enum value.
7703 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
7704 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
7705 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
7706 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
7707 * gdbarch.h, gdbarch.c: Regenerate.
7708 * aarch64-tdep.c (aarch64_gdbarch_init): Override
7709 gdbarch_wchar_bit and gdbarch_wchar_signed.
7710 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
7711 * arm-tdep.c (arm_gdbarch_init): Likewise.
7712 * avr-tdep.c (avr_gdbarch_init): Likewise.
7713 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
7714 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
7715 * i386-tdep.c (i386_go32_init_abi): Likewise.
7716 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
7717 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
7718 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7719 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
7720 * sh-tdep.c (sh_gdbarch_init): Likewise.
7721 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7722 * sparc64-tdep.c (sparc64_init_abi): Likewise.
7723 * windows-tdep.c (windows_init_abi): Likewise.
7724 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
7725
53e710ac
PA
77262017-04-12 Pedro Alves <palves@redhat.com>
7727
7728 PR c++/21323
7729 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
7730 cplus_primitive_type_char32_t>: New enum values.
7731 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
7732 and cplus_primitive_type_char32_t.
7733 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
7734 32, use the archtecture's built-in type for char16_t and char32_t,
7735 respectively. Otherwise, fallback to init_integer_type as before,
7736 but make the type unsigned, and issue a complaint.
7737 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
7738
ab0538b8
AH
77392017-04-12 Alan Hayward <alan.hayward@arm.com>
7740
5e0e0422 7741 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
7742 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
7743
5430098f
SDJ
77442017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7745
7746 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
7747 'const char *'.
7748
7c5ded6a
SDJ
77492017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7750
7751 * common/common-utils.c (free_vector_argv): New function.
7752 * common/common-utils.h: Include <vector>.
7753 (free_vector_argv): New prototype.
7754 * darwin-nat.c (darwin_create_inferior): Rewrite function
7755 prototype in order to constify "exec_file" and accept a
7756 "std::string" for "allargs".
7757 * fork-child.c: Include <vector>.
7758 (breakup_args): Rewrite function, using C++.
7759 (fork_inferior): Rewrite function header, constify "exec_file_arg"
7760 and accept "std::string" for "allargs". Update the code to
7761 calculate "argv" based on "allargs". Update calls to "exec_fun"
7762 and "execvp".
7763 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
7764 order to constify "exec_file" and accept a "std::string" for
7765 "allargs".
7766 * go32-nat.c (go32_create_inferior): Likewise.
7767 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
7768 * infcmd.c (run_command_1): Constify "exec_file". Use
7769 "std::string" for inferior arguments.
7770 * inferior.h (fork_inferior): Update prototype.
7771 * linux-nat.c (linux_nat_create_inferior): Rewrite function
7772 prototype in order to constify "exec_file" and accept a
7773 "std::string" for "allargs".
7774 * nto-procfs.c (procfs_create_inferior): Likewise.
7775 * procfs.c (procfs_create_inferior): Likewise.
7776 * remote-sim.c (gdbsim_create_inferior): Likewise.
7777 * remote.c (extended_remote_run): Update code to accept
7778 "std::string" as argument.
7779 (extended_remote_create_inferior): Rewrite function prototype in
7780 order to constify "exec_file" and accept a "std::string" for
7781 "allargs".
7782 * rs6000-nat.c (super_create_inferior): Likewise.
7783 (rs6000_create_inferior): Likewise.
7784 * target.h (struct target_ops) <to_create_inferior>: Likewise.
7785 * windows-nat.c (windows_create_inferior): Likewise.
7786
ae0eee42
PA
77872017-04-11 Pedro Alves <palves@redhat.com>
7788
7789 * thread.c: Fix whitespace throughout.
7790
a6acac06
PR
77912017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
7792
7793 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
7794
64403bd1
AH
77952017-04-11 Alan Hayward <alan.hayward@arm.com>
7796
7797 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
7798
a5bef50f
SDJ
77992017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
7800
7801 PR gdb/21364
7802 * osdata.c (info_osdata): Check if 'type' is an empty string
7803 instead of NULL.
7804
9295a5a9
PA
78052017-04-10 Pedro Alves <palves@redhat.com>
7806
7807 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
7808 (ptid_to_global_thread_id, in_thread_list)
7809 (do_captured_list_thread_ids, set_resumed, set_running)
7810 (set_executing, set_stop_requested, finish_thread_state)
7811 (validate_registers_access, can_access_registers_ptid)
7812 (print_thread_info_1, switch_to_thread)
7813 (do_restore_current_thread_cleanup)
7814 (make_cleanup_restore_current_thread, thread_command)
7815 (thread_name_command): Use operator== instead of ptid_equal.
7816
996812e3
PA
78172017-04-10 Pedro Alves <palves@redhat.com>
7818
7819 * thread.c (struct current_thread_cleanup) <next>: Delete field.
7820 (current_thread_cleanup_chain): Delete.
7821 (restore_current_thread_cleanup_dtor)
7822 (make_cleanup_restore_current_thread): Remove references to
7823 current_thread_cleanup_chain.
7824
845b344f
AH
78252017-04-10 Alan Hayward <alan.hayward@arm.com>
7826
7827 * msp430-tdep.c (msp430_pseudo_register_read): Never return
7828 REG_UNKNOWN.
7829
803bdfe4
YQ
78302017-04-10 Yao Qi <yao.qi@linaro.org>
7831
7832 PR gdb/19942
7833 * gdbthread.h (thread_info::deletable): New method.
7834 (thread_info::incref): New method.
7835 (thread_info::decref): New method.
7836 (thread_info::refcount): Move it to private.
7837 * infrun.c (save_stop_context): Call inc_refcount.
7838 (release_stop_context_cleanup): Likewise.
7839 * thread.c (set_thread_exited): New function.
7840 (init_thread_list): Delete "tp" only it is deletable, otherwise
7841 call set_thread_exited.
7842 (delete_thread_1): Call set_thread_exited.
7843 (current_thread_cleanup) <inferior_pid>: Remove.
7844 <thread>: New field.
7845 (restore_current_thread_ptid_changed): Removed.
7846 (do_restore_current_thread_cleanup): Adjust.
7847 (restore_current_thread_cleanup_dtor): Don't call
7848 find_thread_ptid.
7849 (set_thread_refcount): Use dec_refcount.
7850 (make_cleanup_restore_current_thread): Adjust.
7851 (thread_apply_all_command): Call inc_refcount.
7852 (_initialize_thread): Don't call
7853 observer_attach_thread_ptid_changed.
7854
8c25b497
YQ
78552017-04-10 Yao Qi <yao.qi@linaro.org>
7856
7857 * thread.c (delete_thread_1): Hoist code on marking thread as
7858 exited.
7859
8473b447
SM
78602017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7861
7862 * windows-nat.c (windows_detach): Initialize ptid with
7863 minus_one_ptid.
7864
6670ec13
SM
78652017-04-07 Simon Marchi <simon.marchi@ericsson.com>
7866
7867 * unittests/ptid-selftests.c: Fix erroneous assert messages.
7868
ba2f91bb
AH
78692017-04-07 Alan Hayward <alan.hayward@arm.com>
7870
7871 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
7872 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
7873 (bfin_pseudo_register_write): Likewise
7874
436252de
SM
78752017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7876
7877 * common/ptid.h (struct ptid): Change to...
7878 (class ptid_t): ... this.
7879 <ptid_t>: New constructors.
7880 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
7881 matches>: New methods.
7882 <make_null, make_minus_one>: New static methods.
7883 <pid>: Rename to...
7884 <m_pid>: ...this.
7885 <lwp>: Rename to...
7886 <m_lwp>: ...this.
7887 <tid>: Rename to...
7888 <m_tid>: ...this.
7889 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
7890 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
7891 as references, move comment to class ptid_t.
7892 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
7893 ptid_t static methods.
7894 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
7895 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
7896 Take ptid arguments as references, implement using ptid_t methods.
7897 * unittests/ptid-selftests.c: New file.
7898 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7899 unittests/ptid-selftests.c.
7900 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
7901
0dedf377
TP
79022017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
7903
7904 * python/python.c (python_run_simple_file): Cast mode literal to
7905 non-const char pointer as expected by PyFile_FromString.
7906
4e9868d4
SM
79072017-04-05 Simon Marchi <simon.marchi@ericsson.com>
7908
7909 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
7910 minus_one_ptid and null_ptid.
7911
9bf2a700
PA
79122017-04-05 Pedro Alves <palves@redhat.com>
7913
7914 * warning.m4 (build_warnings): Remove -Wno-write-strings.
7915 * configure: Regenerate.
7916
a121b7c1
PA
79172017-04-05 Pedro Alves <palves@redhat.com>
7918
7919 * ada-exp.y (yyerror): Constify.
7920 * ada-lang.c (bound_name, get_selections)
7921 (ada_variant_discrim_type)
7922 (ada_variant_discrim_name, ada_value_struct_elt)
7923 (ada_lookup_struct_elt_type, is_unchecked_variant)
7924 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
7925 (catch_ada_exception_command_split)
7926 (catch_ada_assert_command_split, catch_assert_command)
7927 (ada_op_name): Constify.
7928 * ada-lang.h (ada_yyerror, get_selections)
7929 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
7930 * arc-tdep.c (arc_print_frame_cache): Constify.
7931 * arm-tdep.c (arm_skip_stub): Constify.
7932 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
7933 (gen_aggregate_elt_ref): Constify.
7934 * bcache.c (print_bcache_statistics): Constify.
7935 * bcache.h (print_bcache_statistics): Constify.
7936 * break-catch-throw.c (catch_exception_command_1):
7937 * breakpoint.c (struct ep_type_description::description):
7938 Constify.
7939 (add_solib_catchpoint): Constify.
7940 (catch_fork_command_1): Add cast.
7941 (add_catch_command): Constify.
7942 * breakpoint.h (add_catch_command, add_solib_catchpoint):
7943 Constify.
7944 * bsd-uthread.c (bsd_uthread_state): Constify.
7945 * buildsym.c (patch_subfile_names): Constify.
7946 * buildsym.h (next_symbol_text_func, patch_subfile_names):
7947 Constify.
7948 * c-exp.y (yyerror): Constify.
7949 (token::oper): Constify.
7950 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
7951 * c-varobj.c (cplus_describe_child): Constify.
7952 * charset.c (find_charset_names): Add cast.
7953 (find_charset_names): Constify array and add const_cast.
7954 * cli/cli-cmds.c (complete_command, cd_command): Constify.
7955 (edit_command): Constify.
7956 * cli/cli-decode.c (lookup_cmd): Constify.
7957 * cli/cli-dump.c (dump_memory_command, dump_value_command):
7958 Constify.
7959 (struct dump_context): Constify.
7960 (add_dump_command, restore_command): Constify.
7961 * cli/cli-script.c (get_command_line): Constify.
7962 * cli/cli-script.h (get_command_line): Constify.
7963 * cli/cli-utils.c (check_for_argument): Constify.
7964 * cli/cli-utils.h (check_for_argument): Constify.
7965 * coff-pe-read.c (struct read_pe_section_data): Constify.
7966 * command.h (lookup_cmd): Constify.
7967 * common/print-utils.c (decimal2str): Constify.
7968 * completer.c (gdb_print_filename): Constify.
7969 * corefile.c (set_gnutarget): Constify.
7970 * cp-name-parser.y (yyerror): Constify.
7971 * cp-valprint.c (cp_print_class_member): Constify.
7972 * cris-tdep.c (cris_register_name, crisv32_register_name):
7973 Constify.
7974 * d-exp.y (yyerror): Constify.
7975 (struct token::oper): Constify.
7976 * d-lang.h (d_yyerror): Constify.
7977 * dbxread.c (struct header_file_location::name): Constify.
7978 (add_old_header_file, add_new_header_file, last_function_name)
7979 (dbx_next_symbol_text, add_bincl_to_list)
7980 (find_corresponding_bincl_psymtab, set_namestring)
7981 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
7982 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
7983 * defs.h (command_line_input, print_address_symbolic)
7984 (deprecated_readline_begin_hook): Constify.
7985 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
7986 Constify.
7987 * event-top.c (handle_line_of_input): Constify and add cast.
7988 * exceptions.c (catch_errors): Constify.
7989 * exceptions.h (catch_errors): Constify.
7990 * expprint.c (print_subexp_standard, op_string, op_name)
7991 (op_name_standard, dump_raw_expression, dump_raw_expression):
7992 * expression.h (op_name, op_string, dump_raw_expression):
7993 Constify.
7994 * f-exp.y (yyerror): Constify.
7995 (struct token::oper): Constify.
7996 (struct f77_boolean_val::name): Constify.
7997 * f-lang.c (f_word_break_characters): Constify.
7998 * f-lang.h (f_yyerror): Constify.
7999 * fork-child.c (fork_inferior): Add cast.
8000 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8001 (new_variant): Constify.
8002 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8003 * gdbarch.c: Regenerate.
8004 * gdbcore.h (set_gnutarget): Constify.
8005 * go-exp.y (yyerror): Constify.
8006 (token::oper): Constify.
8007 * go-lang.h (go_yyerror): Constify.
8008 * go32-nat.c (go32_sysinfo): Constify.
8009 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8010 * guile/scm-cmd.c (cmdscm_function): Constify.
8011 * guile/scm-param.c (pascm_param_value): Constify.
8012 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8013 (h8300sx_register_name): Constify.
8014 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8015 Constify.
8016 * ia64-tdep.c (ia64_register_names): Constify.
8017 * infcmd.c (construct_inferior_arguments): Constify.
8018 (path_command, attach_post_wait): Constify.
8019 * language.c (show_range_command, show_case_command)
8020 (unk_lang_error): Constify.
8021 * language.h (language_defn::la_error)
8022 (language_defn::la_name_of_this): Constify.
8023 * linespec.c (decode_line_2): Constify.
8024 * linux-thread-db.c (thread_db_err_str): Constify.
8025 * lm32-tdep.c (lm32_register_name): Constify.
8026 * m2-exp.y (yyerror): Constify.
8027 * m2-lang.h (m2_yyerror): Constify.
8028 * m32r-tdep.c (m32r_register_names): Constify and make static.
8029 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8030 * m88k-tdep.c (m88k_register_name): Constify.
8031 * macroexp.c (appendmem): Constify.
8032 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8033 (upgrade_type, parse_external, parse_partial_symbols)
8034 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8035 (new_symbol): Constify.
8036 * memattr.c (mem_info_command): Constify.
8037 * mep-tdep.c (register_name_from_keyword): Constify.
8038 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8039 Constify.
8040 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8041 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8042 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8043 cast.
8044 (mi_execute_async_cli_command): Constify.
8045 * mips-tdep.c (mips_register_name): Constify.
8046 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8047 (am33_register_name, am33_2_register_name)
8048 * moxie-tdep.c (moxie_register_names): Constify.
8049 * nat/linux-osdata.c (osdata_type): Constify fields.
8050 * nto-tdep.c (nto_parse_redirection): Constify.
8051 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8052 (lookup_child_selector): Constify.
8053 (objc_methcall::name): Constify.
8054 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8055 (lookup_struct_typedef): Constify.
8056 * objfiles.c (pc_in_section): Constify.
8057 * objfiles.h (pc_in_section): Constify.
8058 * p-exp.y (struct token::oper): Constify.
8059 (yyerror): Constify.
8060 * p-lang.h (pascal_yyerror): Constify.
8061 * parser-defs.h (op_name_standard): Constify.
8062 (op_print::string): Constify.
8063 (exp_descriptor::op_name): Constify.
8064 * printcmd.c (print_address_symbolic): Constify.
8065 * psymtab.c (print_partial_symbols): Constify.
8066 * python/py-breakpoint.c (stop_func): Constify.
8067 (bppy_get_expression): Constify.
8068 * python/py-cmd.c (cmdpy_completer::name): Constify.
8069 (cmdpy_function): Constify.
8070 * python/py-event.c (evpy_add_attribute)
8071 (gdbpy_initialize_event_generic): Constify.
8072 * python/py-event.h (evpy_add_attribute)
8073 (gdbpy_initialize_event_generic): Constify.
8074 * python/py-evts.c (add_new_registry): Constify.
8075 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8076 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8077 * python/py-inferior.c (get_buffer): Add cast.
8078 * python/py-param.c (parm_constant::name): Constify.
8079 * python/py-unwind.c (fprint_frame_id): Constify.
8080 * python/python.c (gdbpy_parameter_value): Constify.
8081 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8082 * remote.c (memory_packet_config::name): Constify.
8083 (show_packet_config_cmd, remote_write_bytes)
8084 (remote_buffer_add_string):
8085 * reverse.c (exec_reverse_once): Constify.
8086 * rs6000-tdep.c (variant::name, variant::description): Constify.
8087 * rust-exp.y (rustyyerror): Constify.
8088 * rust-lang.c (rust_op_name): Constify.
8089 * rust-lang.h (rustyyerror): Constify.
8090 * serial.h (serial_ops::name): Constify.
8091 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8092 (sh_sh3e_register_name, sh_sh2e_register_name)
8093 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8094 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8095 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8096 (sh_sh4al_dsp_register_name): Constify.
8097 * sh64-tdep.c (sh64_register_name): Constify.
8098 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8099 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8100 * stabsread.c (patch_block_stabs, read_type_number)
8101 (ref_map::stabs, ref_add, process_reference)
8102 (symbol_reference_defined, define_symbol, define_symbol)
8103 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8104 (read_one_struct_field, read_struct_fields, read_baseclasses)
8105 (read_tilde_fields, read_struct_type, read_array_type)
8106 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8107 (read_huge_number, read_range_type, read_args, common_block_start)
8108 (find_name_end): Constify.
8109 * stabsread.h (common_block_start, define_symbol)
8110 (process_one_symbol, symbol_reference_defined, ref_add):
8111 * symfile.c (get_section_index, add_symbol_file_command):
8112 * symfile.h (get_section_index): Constify.
8113 * target-descriptions.c (tdesc_type::name): Constify.
8114 (tdesc_free_type): Add cast.
8115 * target.c (find_default_run_target):
8116 (add_deprecated_target_alias, find_default_run_target)
8117 (target_announce_detach): Constify.
8118 (do_option): Constify.
8119 * target.h (add_deprecated_target_alias): Constify.
8120 * thread.c (print_thread_info_1): Constify.
8121 * top.c (deprecated_readline_begin_hook, command_line_input):
8122 Constify.
8123 (init_main): Add casts.
8124 * top.h (handle_line_of_input): Constify.
8125 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8126 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8127 (tfind_command): Rename to ...
8128 (tfind_command_1): ... this and constify.
8129 (tfind_command): New function.
8130 (tfind_end_command, tfind_start_command): Adjust.
8131 (encode_source_string): Constify.
8132 * tracepoint.h (encode_source_string): Constify.
8133 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8134 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8135 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8136 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8137 * tui/tui-win.c (parse_scrolling_args): Constify.
8138 * tui/tui-windata.c (tui_erase_data_content): Constify.
8139 * tui/tui-windata.h (tui_erase_data_content): Constify.
8140 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8141 * tui/tui.c (tui_enable): Add cast.
8142 * utils.c (defaulted_query): Constify.
8143 (init_page_info): Add cast.
8144 (puts_debug, subset_compare): Constify.
8145 * utils.h (subset_compare): Constify.
8146 * varobj.c (varobj_format_string): Constify.
8147 * varobj.h (varobj_format_string): Constify.
8148 * vax-tdep.c (vax_register_name): Constify.
8149 * windows-nat.c (windows_detach): Constify.
8150 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8151 * xml-support.c (gdb_xml_end_element): Constify.
8152 * xml-tdesc.c (tdesc_start_reg): Constify.
8153 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8154 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8155 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8156
995816ba
PA
81572017-04-05 Pedro Alves <palves@redhat.com>
8158
8159 * proc-api.c (struct trans): Constify.
8160 (procfs_note): Constify.
8161 * proc-events.c (struct trans, syscall_table):
8162 * proc-flags.c (struct trans): Constify.
8163 * proc-utils.h (procfs_note): Constify.
8164 * proc-why.c (struct trans): Constify.
8165 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8166 (procfs_detach): Constify.
8167 * sol-thread.c (struct string_map): Constify.
8168 (td_err_string, td_state_string): Constify.
8169
3e83a920
PA
81702017-04-05 Pedro Alves <palves@redhat.com>
8171
8172 * proc-api.c (procfs_filename): Don't initialize
8173 procfs_filename.
8174 (prepare_to_trace): Assume procfs_filename is non-NULL.
8175 (_initialize_proc_api): Give procfs_filename a default value here.
8176
63160a43
PA
81772017-04-05 Pedro Alves <palves@redhat.com>
8178
8179 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8180 'cond_string' parameter.
8181 (extract_exception_regexp): Constify 'string' parameter.
8182 (catch_exception_command_1): Constify.
8183 * breakpoint.c (init_catchpoint)
8184 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8185 parameter.
8186 (ep_parse_optional_if_clause, catch_fork_command_1)
8187 (catch_exec_command_1): Constify.
8188 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8189 parameter.
8190 (ep_parse_optional_if_clause): Constify.
8191 * cli/cli-utils.c (remove_trailing_whitespace)
8192 (check_for_argument): Constify.
8193 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8194 non-const overload.
8195 (check_for_argument): Likewise.
8196
9b2eba3d
PA
81972017-04-05 Pedro Alves <palves@redhat.com>
8198
8199 * event-top.c (command_line_handler): Add cast to execute_command
8200 call.
8201 * record-btrace.c (cmd_record_btrace_bts_start)
8202 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8203 (cmd_record_btrace_start): Add cast to execute_command call.
8204 * record-full.c (record_full_goto_insn):
8205 * record.c (record_start, record_stop): Add cast to
8206 execute_command_to_string calls.
8207 (cmd_record_start): Add cast to execute_command calls.
8208
2adadf51
PA
82092017-04-05 Pedro Alves <palves@redhat.com>
8210
8211 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8212 static inline function.
8213 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8214 array and use gdb_PyArg_ParseTupleAndKeywords.
8215 * python/py-cmd.c (cmdpy_init): Likewise.
8216 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8217 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8218 (infpy_search_memory): Likewise.
8219 * python/py-objfile.c (objfpy_add_separate_debug_file)
8220 (gdbpy_lookup_objfile): Likewise.
8221 * python/py-symbol.c (gdbpy_lookup_symbol)
8222 (gdbpy_lookup_global_symbol): Likewise.
8223 * python/py-type.c (gdbpy_lookup_type): Likewise.
8224 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8225 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8226 Likewise.
8227
0d1f4ceb
PA
82282017-04-05 Pedro Alves <palves@redhat.com>
8229
8230 * python/python-internal.h (gdb_PyGetSetDef): New type.
8231 * python/py-block.c (block_object_getset)
8232 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8233 * python/py-event.c (event_object_getset)
8234 (finish_breakpoint_object_getset): Likewise.
8235 * python/py-inferior.c (inferior_object_getset): Likewise.
8236 * python/py-infthread.c (thread_object_getset): Likewise.
8237 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8238 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8239 * python/py-objfile.c (objfile_getset): Likewise.
8240 * python/py-progspace.c (pspace_getset): Likewise.
8241 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8242 Likewise.
8243 * python/py-record.c (recpy_record_getset): Likewise.
8244 * python/py-symbol.c (symbol_object_getset): Likewise.
8245 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8246 Likewise.
8247 * python/py-type.c (type_object_getset, field_object_getset):
8248 Likewise.
8249 * python/py-value.c (value_object_getset): Likewise.
8250
4d759979
PA
82512017-04-05 Pedro Alves <palves@redhat.com>
8252
8253 * python/python-internal.h (gdb_PyObject_CallMethod)
8254 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8255 New functions.
8256 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8257 (PySys_GetObject, PySys_SetPath): New macros.
8258
fdf9e36f
PA
82592017-04-05 Pedro Alves <palves@redhat.com>
8260
8261 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8262 info_osdata_command.
8263 * osdata.c (info_osdata_command): Rename to ...
8264 (info_osdata): ... this. Constify 'type' parameter, and remove
8265 the 'from_tty' parameter. Accept NULL TYPE.
8266 (info_osdata_command): New function.
8267 * osdata.h (info_osdata_command): Remove declaration.
8268 (info_osdata): New declaration.
8269
9f33b8b7
PA
82702017-04-05 Pedro Alves <palves@redhat.com>
8271
8272 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8273 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8274 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8275 parameter.
8276 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8277 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8278 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8279 parameter.
8280 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8281 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8282 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8283 (mi_cmd_file_list_exec_source_files)
8284 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8285 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8286 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8287 parameter.
8288 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8289 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8290 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8291 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8292 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8293 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8294 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8295 'command' parameter.
8296 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8297 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8298 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8299 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8300 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8301 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8302 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8303 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8304 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8305 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8306 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8307 parameter.
8308 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8309 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8310 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8311 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8312 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8313 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8314 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8315 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8316 (mi_cmd_data_list_changed_registers)
8317 (mi_cmd_data_write_register_values)
8318 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8319 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8320 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8321 (mi_cmd_list_features, mi_cmd_list_target_features)
8322 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8323 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8324 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8325 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8326 (mi_cmd_trace_frame_collected): Constify 'command'
8327 parameter.
8328 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8329 'command' parameter.
8330
67cb5b2d
PA
83312017-04-05 Pedro Alves <palves@redhat.com>
8332
8333 * ada-lang.c (ada_completer_word_break_characters): Now a const
8334 array.
8335 (ada_get_gdb_completer_word_break_characters): Constify.
8336 * completer.c (gdb_completer_command_word_break_characters)
8337 (gdb_completer_file_name_break_characters)
8338 (gdb_completer_quote_characters): Now const arrays.
8339 (get_gdb_completer_quote_characters): Constify.
8340 (set_rl_completer_word_break_characters): New function.
8341 (set_gdb_completion_word_break_characters)
8342 (complete_line_internal): Use it.
8343 * completer.h (get_gdb_completer_quote_characters): Constify.
8344 (set_rl_completer_word_break_characters): Declare.
8345 * f-lang.c (f_word_break_characters): Constify.
8346 * language.c (default_word_break_characters): Constify.
8347 * language.h (language_defn::la_word_break_characters): Constify.
8348 (default_word_break_characters): Constify.
8349 * top.c (init_main): Use set_rl_completer_word_break_characters.
8350
7a114964
PA
83512017-04-05 Pedro Alves <palves@redhat.com>
8352
8353 * aix-thread.c (aix_thread_pid_to_str)
8354 (aix_thread_extra_thread_info): Constify.
8355 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8356 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8357 (bsd_uthread_pid_to_str): Constify.
8358 * corelow.c (core_pid_to_str): Constify.
8359 * darwin-nat.c (darwin_pid_to_str): Constify.
8360 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8361 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8362 Constify.
8363 * gnu-nat.c (gnu_pid_to_str): Constify.
8364 * go32-nat.c (go32_pid_to_str): Constify.
8365 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8366 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8367 * inferior.c (inferior_pid_to_str): Constify.
8368 * linux-nat.c (linux_nat_pid_to_str): Constify.
8369 * linux-tdep.c (linux_core_pid_to_str): Constify.
8370 * linux-thread-db.c (thread_db_pid_to_str)
8371 (thread_db_extra_thread_info): Constify.
8372 * nto-tdep.c (nto_extra_thread_info): Constify.
8373 * nto-tdep.h (nto_extra_thread_info): Constify.
8374 * obsd-nat.c (obsd_pid_to_str): Constify.
8375 * procfs.c (procfs_pid_to_str): Constify.
8376 * ravenscar-thread.c (ravenscar_extra_thread_info)
8377 (ravenscar_pid_to_str): Constify.
8378 * remote-sim.c (gdbsim_pid_to_str): Constify.
8379 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8380 Constify.
8381 * sol-thread.c (solaris_pid_to_str): Constify.
8382 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8383 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8384 * target.c (default_pid_to_str, target_pid_to_str)
8385 (normal_pid_to_str, default_pid_to_str): Constify.
8386 * target.h (target_ops::to_pid_to_str)
8387 (target_ops::to_extra_thread_info): Constify.
8388 (target_pid_to_str, normal_pid_to_str): Constify.
8389 * windows-nat.c (windows_pid_to_str): Constify.
8390 * gdbarch.sh (core_pid_to_str): Constify.
8391 * target-delegates.c: Regenerate.
8392 * gdbarch.h, gdbarch.c: Regenerate.
8393
69bbf465
PA
83942017-04-05 Pedro Alves <palves@redhat.com>
8395
8396 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8397 the memory of the temporary warning_pre_print override.
8398 * utils.c (warning_pre_print): Constify.
8399 * utils.h (warning_pre_print): Constify.
8400
be47f9e8
PA
84012017-04-05 Pedro Alves <palves@redhat.com>
8402
8403 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8404 (shell_command): New function.
8405 (make_command): Use std::string.
8406 (init_cli_cmds): Register shell_command instead of shell_escape.
8407
bde6261a
PA
84082017-04-05 Pedro Alves <palves@redhat.com>
8409
8410 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8411 * tracepoint.c (default_collect): Don't initialize.
8412
b38ef47f
PA
84132017-04-05 Pedro Alves <palves@redhat.com>
8414
8415 * macroexp.c (macro_buffer::shared): Now a bool.
8416 (init_buffer): Update.
8417 (init_shared_buffer): Constify 'addr' parameter.
8418 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8419 casts.
8420
f995bbe8
PA
84212017-04-05 Pedro Alves <palves@redhat.com>
8422
8423 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
8424 * disasm.c (set_disassembler_options): Constify local.
8425 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
8426
4a596fe2
SDJ
84272017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
8428
8429 PR gdb/21352
8430 * tracefile.c (tsave_command): Fix argument parsing for '-r'
8431 option.
8432
2cad08ea
YQ
84332017-04-05 Yao Qi <yao.qi@linaro.org>
8434
8435 * frame.c (frame_unwind_register_unsigned): Call
8436 frame_unwind_register_value.
8437
55a98976
YQ
84382017-04-05 Yao Qi <yao.qi@linaro.org>
8439
8440 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
8441 Use gdb_test_multiple, and don't match anchor.
8442
4ac40124
PA
84432017-04-05 Pedro Alves <palves@redhat.com>
8444
8445 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
8446 (Write After Approval): Remove Simon Marchi.
8447
c053b654
PA
84482017-04-05 Pedro Alves <palves@redhat.com>
8449
8450 * common/gdb_optional.h (optional::optional): Make constexpr and
8451 initialize m_dummy.
8452
4c7bf4f9
JB
84532017-04-04 John Baldwin <jhb@FreeBSD.org>
8454
8455 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8456 (amd64fbsd_jmp_buf_reg_offset): Remove.
8457 (amd64fbsd_supply_uthread): Remove function.
8458 (amd64fbsd_collect_uthread): Remove function.
8459 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
8460 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
8461 (x86_64-*-freebsd*): Remove bsd-uthread.o.
8462 (fbsd-nat.c): Update comment.
8463 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8464 (i386fbsd_jmp_buf_reg_offset): Remove.
8465 (i386fbsd_supply_uthread): Remove function.
8466 (i386fbsd_collect_uthread): Remove function.
8467 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
8468
1e1a8bef
JB
84692017-04-04 John Baldwin <jhb@FreeBSD.org>
8470
8471 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
8472 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
8473 * NEWS: Mention that support for FreeBSD/alpha was removed.
8474 * alpha-fbsd-tdep.c: Delete file.
8475 * config/alpha/fbsd.mh: Delete file.
8476 * configure.host: Delete alpha*-*-freebsd* and
8477 alpha*-*-kfreebsd*-gnu.
8478 * configure.tgt: Delete alpha*-*-freebsd* and
8479 alpha*-*-kfreebsd*-gnu.
8480
49907934
JB
84812017-04-04 John Baldwin <jhb@FreeBSD.org>
8482
8483 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
8484 amd64bsd_store_inferior_registers): Use ptid from regcache.
8485
6f77053d
PA
84862017-04-04 Pedro Alves <palves@redhat.com>
8487
8488 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
8489 data fields, make them private and add "m_" prefixes.
8490 (lnp_state_machine::lnp_state_machine): New ctor.
8491 (record_line, check_line_address, handle_set_discriminator)
8492 (handle_set_address, handle_advance_pc, handle_special_opcode)
8493 (handle_advance_line, handle_set_file, handle_negate_stmt)
8494 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
8495 (end_sequence, advance_line): New methods.
8496 (m_gdbarch, m_record_lines_p): New fields.
8497 (lnp_reader_state): Delete.
8498 (dwarf_record_line): Rename to ...
8499 (lnp_state_machine::record_line): ... adjust.
8500 (init_lnp_state_machine): Delete.
8501 (lnp_state_machine::lnp_state_machine): New.
8502 (check_line_address): Rename to ...
8503 (lnp_state_machine::check_line_address): This.
8504 (dwarf_decode_lines_1): Remove reference to "reader_state".
8505 Adjust lnp_state_machine having a non-default ctor. Use bool.
8506 State machine internal state manipulation moved to
8507 lnp_state_machine methods.
8508
9c541725
PA
85092017-04-04 Pedro Alves <palves@redhat.com>
8510
8511 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8512 unittests/offset-type-selftests.c.
8513 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
8514 * common/offset-type.h: New file.
8515 * common/preprocessor.h: New file.
8516 * common/traits.h: New file.
8517 * common/valid-expr.h: New file.
8518 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
8519 sect_offset and cu_offset strong typedefs throughout.
8520 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
8521 typedefs throughout.
8522 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
8523 sect_offset and cu_offset strong typedefs throughout.
8524 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
8525 typedefs throughout.
8526 * gdbtypes.h: Include "common/offset-type.h".
8527 (cu_offset): Now an offset type (strong typedef) instead of a
8528 struct.
8529 (sect_offset): Likewise.
8530 (union call_site_parameter_u): Rename "param_offset" field to
8531 "param_cu_off".
8532 * unittests/offset-type-selftests.c: New file.
8533
ecfb656c
PA
85342017-04-04 Pedro Alves <palves@redhat.com>
8535
8536 * common/underlying.h: New file.
8537 * dwarf2read.c: Include "common/gdb_optional.h" and
8538 "common/underlying.h".
8539 (dir_index, file_name_index): New types.
8540 (file_entry): Use them.
8541 (file_entry::include): Use to_underlying.
8542 (line_header::add_file_name): Use dir_index.
8543 (read_formatted_entries): Use gdb::optional. Read form before
8544 writting to file_entry.
8545 (dwarf_decode_line_header): Use dir_index.
8546 (lnp_state_machine::current_file): Use to_underlying.
8547 (lnp_state_machine::file): Change type to file_name_index.
8548 (dwarf_record_line): Use to_underlying.
8549 (init_lnp_state_machine): Use file_name_index.
8550 (dwarf_decode_lines_1): Use dir_index and file_name_index.
8551
d194f1fe
PA
85522017-04-04 Pedro Alves <palves@redhat.com>
8553
8554 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
8555 operator bool, has_value and get methods.
8556
fff8551c
PA
85572017-04-04 Pedro Alves <palves@redhat.com>
8558
8559 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
8560 fields.
8561 (line_header): Initialize all data fields. Change type of
8562 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
8563 Change type of include_dirs to std::vector<const char *>. Remove
8564 num_include_dirs, include_dirs_size. Change type of file_names to
8565 std::vector<file_entry>. Remove num_file_names, file_names_size.
8566 (line_header::line_header): New.
8567 (line_header::add_include_dir, line_header::add_file_name): New
8568 methods.
8569 (line_header::include_dir_at): Remove NULL check.
8570 (line_header::file_name_at): Add const overload.
8571 (line_header_up): New unique_ptr typedef.
8572 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
8573 std::vector. Remove free_line_header call.
8574 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
8575 free_line_header call.
8576 (free_cu_line_header): Delete.
8577 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
8578 (setup_type_unit_groups): Use line_header_up instead of cleanups.
8579 Adjust to use std::vector.
8580 (free_line_header): Delete.
8581 (free_line_header_voidp): Use delete.
8582 (add_include_dir): Replace with ...
8583 (line_header::add_include_dir): ... this method. Use std::vector.
8584 (add_file_name): Replace with ...
8585 (line_header::add_file_name): ... this method. Use std::vector.
8586 (add_include_dir_stub): Delete.
8587 (read_formatted_entries): Remove memset.
8588 (dwarf_decode_line_header): Return a line_header_up instead of a
8589 raw pointer. Remove cleanup handling. Pass lambdas to
8590 read_formatted_entries. Adjust to use line_header methods.
8591 (dwarf_decode_lines_1): Adjust to use line_header methods.
8592 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
8593 use std::vector.
8594
d62a8ae2
SM
85952017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
8596
8597 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
8598 instead of struct ptid.
8599
db3a1dc7
AH
86002017-05-04 Alan Hayward <alan.hayward@arm.com>
8601
8602 * frame.c (get_frame_register_bytes): Unwind using value.
8603 (put_frame_register_bytes): Likewise.
8604
b1b45502
IB
86052017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
8606
8607 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
8608 aggregate-like.
8609
ec13808e
JK
86102017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
8611
8612 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
8613
12316564
YQ
86142017-03-29 Yao Qi <yao.qi@linaro.org>
8615
8616 * gdbthread.h (struct thread_info): Declare constructor and
8617 destructor. Add some in-class member initializers.
8618 * thread.c (free_thread): Remove.
8619 (init_thread_list): Call delete instead of free_thread.
8620 (new_thread): Call thread_info constructor.
8621 (thread_info::thread_info): New function.
8622 (thread_info::~thread_info): New function.
8623 (delete_thread_1): Call delete instead of free_thread.
8624 (make_cleanup_restore_current_thread): Move tp and frame to
8625 inner block.
8626
fe5f7374
AK
86272017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8628
8629 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
8630 (arc_skip_prologue): Likewise.
8631 (arc_make_frame_cache): Likewise.
8632 (arc_pv_get_operand): New function.
8633 (arc_is_in_prologue): Likewise.
8634 (arc_analyze_prologue): Likewise.
8635 (arc_print_frame_cache): Likewise.
8636 (MAX_PROLOGUE_LENGTH): New constant.
8637
eea78757
AK
86382017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8639
8640 * configure.tgt: Add arc-insn.o.
8641 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
8642 (dump_arc_instruction_command): New function.
8643 (arc_fprintf_disasm): Likewise.
8644 (arc_disassemble_info): Likewise.
8645 (arc_insn_get_operand_value): Likewise.
8646 (arc_insn_get_operand_value_signed): Likewise.
8647 (arc_insn_get_memory_base_reg): Likewise.
8648 (arc_insn_get_memory_offset): Likewise.
8649 (arc_insn_get_branch_target): Likewise.
8650 (arc_insn_dump): Likewise.
8651 (arc_insn_get_linear_next_pc): Likewise.
8652 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
8653 (arc_disassemble_info): Likewise.
8654 (arc_insn_get_branch_target): Likewise.
8655 (arc_insn_get_linear_next_pc): Likewise.
8656 * NEWS: Mention new "maint print arc arc-instruction".
8657
3be78afd
AK
86582017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8659
8660 * arc-tdep (maintenance_print_arc_list): New variable.
8661 (maintenance_print_arc_command): New function.
8662
296ec4fa
AK
86632017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8664
8665 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
8666 Add "limm" and "reserved".
8667 (arc_cannot_fetch_register, arc_cannot_store_register): Add
8668 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
8669 * arc-tdep.h (arc_regnum): Likewise.
8670
f74f865e
MF
86712017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8672
8673 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8674 for THREADPTR register.
8675 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
8676 register.
8677 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
8678 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
8679 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
8680
0d0bf81a
MF
86812017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8682
8683 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
8684 registers above gdbarch_num_regs (gdbarch) as privileged in
8685 call0 ABI.
8686
0ce4291e
MF
86872017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8688
8689 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8690 for a single specified register or for all registers in
8691 a0_base..a0_base + C0_NREGS range.
8692 (supply_gregset_reg): Call regcache_raw_supply for a single
8693 specified register or for all registers in a0_base..a0_base +
8694 C0_NREGS range.
8695
c56054f9
MF
86962017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8697
8698 * arch/xtensa.h (C0_NREGS): Add definition.
8699 * xtensa-tdep.c (C0_NREGS): Remove definition.
8700
a4398628
MF
87012017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8702
8703 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
8704 Drop xtensa_default_isa initialization.
8705 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
8706
8c43009f
PA
87072017-03-27 Pedro Alves <palves@redhat.com>
8708
8709 * dwarf2read.c (file_entry) <dir_index>: Add comment.
8710 (file_entry::include_dir): New method.
8711 (line_header::include_dir_at, line_header::file_name_at): New
8712 methods.
8713 (setup_type_unit_groups, setup_type_unit_groups)
8714 (psymtab_include_file_name): Simplify using the new methods.
8715 (lnp_state_machine) <the_line_header>: New field.
8716 <file>: Add comment.
8717 (lnp_state_machine::current_file): New method.
8718 (dwarf_record_line): Simplify using the new methods.
8719 (init_lnp_state_machine): Initialize the "the_line_header" field.
8720 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
8721 Simplify using the new methods.
8722
a7e80b9e
PA
87232017-03-27 Pedro Alves <palves@redhat.com>
8724
8725 * cp-name-parser.y (make_empty): Delete.
8726 (demangler_special, nested_name, ptr_operator, array_indicator)
8727 (direct_declarator, declarator_1): Use fill_comp instead of
8728 make_empty.
8729
21047726
PA
87302017-03-27 Pedro Alves <palves@redhat.com>
8731
8732 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
8733 to ATTRIBUTE_PRINTF.
8734 * solib-target.c (library_list_start_list): Print "string" not
8735 "version".
8736 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
8737 gdb_xml_error call.
8738
d721ba37
PA
87392017-03-27 Pedro Alves <palves@redhat.com>
8740
8741 * dwarf2read.c (struct file_and_directory): New.
8742 (dwarf2_get_dwz_file): Adjust to use std::string.
8743 (dw2_get_file_names_reader): Adjust to use file_and_directory.
8744 (find_file_and_directory): Adjust to return a file_and_directory
8745 object.
8746 (read_file_scope): Adjust to use file_and_directory. Remove
8747 make_cleanup/do_cleanups calls.
8748 (open_and_init_dwp_file): Adjust to use std::string. Remove
8749 make_cleanup/do_cleanups calls.
8750 * python/python.c (do_start_initialization): Adjust to ldirname
8751 returning a std::string.
8752 * utils.c (ldirname): Now returns a std::string.
8753 * utils.h (ldirname): Change return type to std::string.
8754 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
8755 returning a std::string.
8756 * xml-tdesc.c (file_read_description_xml): Likewise.
8757
ed771251
AH
87582017-03-24 Alan Hayward <alan.hayward@arm.com>
8759
8760 * regcache.c (regcache_debug_print_register): New function.
8761 * regcache.h (regcache_debug_print_register): New declaration.
8762 * target.c (debug_print_register): Remove.
8763 (target_fetch_registers): Call regcache_debug_print_register.
8764 (target_store_registers): Likewise.
8765
568c1b9f
PB
87662017-03-24 Pádraig Brady <pbrady@fb.com>
8767
8768 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
8769 reference beyond the 'lh->include_dirs' array before accessing to
8770 it.
8771 (psymtab_include_file_name): Likewise.
8772 (dwarf_decode_lines_1): Likewise.
8773 (dwarf_decode_lines): Likewise.
8774 (file_file_name): Likewise.
8775
3e00d44f
SM
87762017-03-23 Simon Marchi <simon.marchi@ericsson.com>
8777
8778 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
8779 inferior_ptid.
8780 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8781 ps_lsetfpregs): Likewise.
8782 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
8783 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8784 ps_lsetfpregs): Likewise.
8785 * target.c (target_fetch_registers, target_store_registers):
8786 Remove asserts.
8787
077ae656
AH
87882017-03-23 Alan Hayward <alan.hayward@arm.com>
8789
8790 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
8791
1e2b521d
YQ
87922017-03-23 Yao Qi <yao.qi@linaro.org>
8793
8794 * aarch64-tdep.c (aarch64_process_record_test): Declare.
8795 (_initialize_aarch64_tdep): Register it.
8796 (aarch64_record_load_store): Handle PRFM instruction.
8797 (aarch64_process_record_test): New function.
8798
33877125
YQ
87992017-03-23 Yao Qi <yao.qi@linaro.org>
8800
8801 * aarch64-tdep.c (aarch64_record_load_store): Fix code
8802 indentation.
8803
a0eef940
YQ
88042017-03-23 Yao Qi <yao.qi@linaro.org>
8805
8806 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
8807
3f2a3564
PR
88082017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8809
8810 python/python.c (do_start_initialization): Fix memory leak.
8811
b67aeab0
SM
88122017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8813
8814 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
8815 using get_ptrace_pid.
8816 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
8817 inferior_ptid.
8818 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
8819 inferior_ptid instead of pid.
8820
ffdbe864
YQ
88212017-03-22 Yao Qi <yao.qi@linaro.org>
8822
8823 * aarch64-tdep.c: Wrap locally used classes in anonymous
8824 namespace.
8825 * arm-tdep.c: Likewise.
8826 * linespec.c: Likewise.
8827 * ui-out.c: Likewise.
8828
9d736fbf
JG
88292017-03-22 Jonah Graham <jonah@kichwacoders.com>
8830
8831 PR gdb/19637
8832 * python/lib/gdb/printer/bound_registers.py: Import sys.
8833
3de88e9a
SM
88342017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8835
8836 * windows-nat.c (do_windows_fetch_inferior_registers): Add
8837 windows_thread_info parameter and use it instead of
8838 current_thread.
8839 (windows_fetch_inferior_registers): Don't set current_thread,
8840 pass the thread to do_windows_fetch_inferior_registers. Use
8841 ptid from regcache instead of inferior_ptid.
8842 (do_windows_store_inferior_registers): Add windows_thread_info
8843 parameter and use it instead of current_thread.
8844 (windows_store_inferior_registers): Don't set current_thread,
8845 pass the thread to do_windows_store_inferior_registers. Use
8846 ptid from regcache instead of inferior_ptid.
8847
0e7b8f61
SM
88482017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8849
8850 * ser-mingw.c (ser_windows_raw): Remove reference to
8851 struct serial::current_timeout.
8852
5badf10a
IR
88532017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
8854
8855 PR tdep/20928
8856 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
8857 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
8858 (sparc64_fsr_type): Fix %fsr decoding.
8859
cee59b3f
TW
88602017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
8861
8862 * python/py-record-btrace.c (btpy_insn_data): Change return type
8863 for Python 2.
8864
639a9038
SM
88652017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8866
8867 * spu-linux-nat.c (spu_fetch_inferior_registers,
8868 spu_store_inferior_registers): Use ptid from regcache, set and
8869 restore inferior_ptid.
8870 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
8871 Likewise.
8872
bcc0c096
SM
88732017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8874
8875 * i386-linux-nat.c (fetch_register, store_register,
8876 i386_linux_fetch_inferior_registers,
8877 i386_linux_store_inferior_registers): Use ptid from regcache.
8878 * ia64-linux-nat.c (ia64_linux_fetch_register,
8879 ia64_linux_store_register): Likewise.
8880 * inf-ptrace.c (inf_ptrace_fetch_register,
8881 inf_ptrace_store_register): Likewise.
8882 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
8883 m32r_linux_store_inferior_registers): Likewise.
8884 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
8885 m68kbsd_store_inferior_registers): Likewise.
8886 * m68k-linux-nat.c (fetch_register, store_register,
8887 m68k_linux_fetch_inferior_registers,
8888 m68k_linux_store_inferior_registers): Likewise.
8889 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
8890 m88kbsd_store_inferior_registers): Likewise.
8891 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
8892 mips_fbsd_store_inferior_registers): Likewise.
8893 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
8894 mips64_linux_regsets_store_registers): Likewise.
8895 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
8896 mipsnbsd_store_inferior_registers): Likewise.
8897 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
8898 mips64obsd_store_inferior_registers): Likewise.
8899 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
8900 Likewise.
8901 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
8902 ppcfbsd_store_inferior_registers): Likewise.
8903 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
8904 ppc_linux_store_inferior_registers): Likewise.
8905 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
8906 ppcnbsd_store_inferior_registers): Likewise.
8907 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
8908 ppcobsd_store_registers): Likewise.
8909 * procfs.c (procfs_fetch_registers, procfs_store_registers):
8910 Likewise.
8911 * ravenscar-thread.c (ravenscar_fetch_registers,
8912 ravenscar_store_registers, ravenscar_prepare_to_store):
8913 Likewise.
8914 * record-btrace.c (record_btrace_fetch_registers,
8915 record_btrace_store_registers, record_btrace_prepare_to_store):
8916 Likewise.
8917 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
8918 Lookup inferior using ptid from regcache, instead of
8919 current_inferior.
8920 * remote.c (remote_fetch_registers, remote_store_registers): Use
8921 ptid from regcache.
8922 * rs6000-nat.c (fetch_register, store_register): Likewise.
8923 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
8924 s390_linux_store_inferior_registers): Likewise.
8925 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
8926 shnbsd_store_inferior_registers): Likewise.
8927 * sol-thread.c (sol_thread_fetch_registers,
8928 sol_thread_store_registers): Likewise.
8929 * sparc-nat.c (sparc_fetch_inferior_registers,
8930 sparc_store_inferior_registers): Likewise.
8931 * tilegx-linux-nat.c (fetch_inferior_registers,
8932 store_inferior_registers): Likewise.
8933 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
8934 vaxbsd_store_inferior_registers): Likewise.
8935 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
8936 store_xtregs): Likewise.
8937
c0f55cc6
AV
89382017-03-20 Artemiy Volkov <artemiyv@acm.org>
8939
8940 PR gdb/14441
8941 * NEWS: Mention support for rvalue references in GDB and python.
8942 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
8943 supports both lvalue and rvalue references.
8944
15c0a2a9
AV
89452017-03-20 Artemiy Volkov <artemiyv@acm.org>
8946
8947 PR gdb/14441
8948 * gdbtypes.c (rank_one_type): Implement overloading
8949 resolution rules regarding rvalue references.
8950
aa006118
AV
89512017-03-20 Artemiy Volkov <artemiyv@acm.org>
8952
8953 PR gdb/14441
8954 * aarch64-tdep.c (aarch64_type_align)
8955 (aarch64_extract_return_value, aarch64_store_return_value): Change
8956 lvalue reference type checks to general reference type checks.
8957 * amd64-tdep.c (amd64_classify): Likewise.
8958 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
8959 Likewise.
8960 * arm-tdep.c (arm_type_align, arm_extract_return_value)
8961 (arm_store_return_value): Likewise.
8962 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
8963 * c-typeprint.c (c_print_type): Likewise.
8964 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
8965 (cplus_number_of_children, cplus_describe_child): Likewise.
8966 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
8967 * completer.c (expression_completer): Likewise.
8968 * cp-support.c (make_symbol_overload_list_adl_namespace):
8969 Likewise.
8970 * darwin-nat-info.c (info_mach_region_command): Likewise.
8971 * dwarf2loc.c (entry_data_value_coerce_ref)
8972 (value_of_dwarf_reg_entry): Likewise.
8973 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
8974 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
8975 Likewise.
8976 * findvar.c (extract_typed_address, store_typed_address):
8977 Likewise.
8978 * gdbtypes.c (rank_one_type): Likewise.
8979 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
8980 * infcall.c (value_arg_coerce): Likewise.
8981 * language.c (pointer_type): Likewise.
8982 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
8983 Likewise.
8984 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
8985 * mn10300-tdep.c (mn10300_type_align): Likewise.
8986 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
8987 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
8988 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
8989 Likewise.
8990 * printcmd.c (print_formatted, x_command): Likewise.
8991 * python/py-type.c (typy_get_composite, typy_template_argument):
8992 Likewise.
8993 * python/py-value.c (valpy_referenced_value)
8994 (valpy_get_dynamic_type, value_has_field): Likewise.
8995 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
8996 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
8997 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
8998 * spu-tdep.c (spu_scalar_value_p): Likewise.
8999 * symtab.c (lookup_symbol_aux): Likewise.
9000 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9001 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9002 Likewise.
9003 * valops.c (value_cast_pointers, value_cast)
9004 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9005 (value_struct_elt, value_struct_elt_bitpos)
9006 (value_find_oload_method_list, find_overload_match)
9007 (value_rtti_indirect_type): Likewise.
9008 * valprint.c (val_print_scalar_type_p, generic_val_print):
9009 Likewise.
9010 * value.c (value_actual_type, value_as_address, unpack_long)
9011 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9012 (coerce_ref): Likewise.
9013 * varobj.c (varobj_get_value_type): Likewise.
9014
3fcf899d
AV
90152017-03-20 Artemiy Volkov <artemiyv@acm.org>
9016
9017 PR gdb/14441
9018 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9019 table of constants.
9020 * python/lib/gdb/command/explore.py: Support exploring values
9021 of rvalue reference types.
9022 * python/lib/gdb/types.py: Implement get_basic_type() for
9023 rvalue reference types.
9024 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9025 constant.
9026 * python/py-value.c (valpy_getitem): Add an rvalue reference
9027 check.
9028 (valpy_reference_value): Add new parameter "refcode".
9029 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9030 New wrappers for valpy_reference_value().
9031 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9032 (gdbpy_invoke_xmethod): Likewise.
9033
4297a3f0
AV
90342017-03-20 Artemiy Volkov <artemiyv@acm.org>
9035
9036 PR gdb/14441
9037 * dwarf2read.c (process_die, read_type_die_1): Handle the
9038 DW_TAG_rvalue_reference_type DIE.
9039 (read_tag_reference_type): Add new parameter "refcode".
9040
e1cb3213
AV
90412017-03-20 Artemiy Volkov <artemiyv@acm.org>
9042
9043 PR gdb/14441
9044 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9045 (c_type_print_modifier, c_type_print_varspec_suffix)
9046 (c_type_print_base): Support printing rvalue reference types.
9047 * c-valprint.c (c_val_print, c_value_print): Support printing
9048 rvalue reference values.
9049
e4347c89
AV
90502017-03-20 Artemiy Volkov <artemiyv@acm.org>
9051
9052 PR gdb/14441
9053 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9054 typename.
9055 * cp-support.c (replace_typedefs): Handle
9056 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9057 * python/py-type.c (typy_lookup_type): Likewise.
9058
53cc15f5
AV
90592017-03-20 Artemiy Volkov <artemiyv@acm.org>
9060
9061 PR gdb/14441
9062 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9063 * parse.c (insert_type): Change assert statement.
9064 (follow_types): Handle rvalue reference types.
9065 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9066 constant.
9067
a65cfae5
AV
90682017-03-20 Artemiy Volkov <artemiyv@acm.org>
9069
9070 PR gdb/14441
9071 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9072 value_ref() interface.
9073 * c-valprint.c (c_value_print): Likewise.
9074 * infcall.c (value_arg_coerce): Likewise.
9075 * python/py-value.c (valpy_reference_value): Likewise.
9076 * valops.c (value_cast, value_reinterpret_cast)
9077 (value_dynamic_cast, typecmp): Likewise.
9078 (value_ref): Parameterize by kind of return value reference type.
9079 * value.h (value_ref): Add new parameter "refcode".
9080
3b224330
AV
90812017-03-20 Artemiy Volkov <artemiyv@acm.org>
9082
9083 PR gdb/14441
9084 * dwarf2read.c (read_tag_reference_type): Use
9085 lookup_lvalue_reference_type() instead of lookup_reference_type().
9086 * eval.c (evaluate_subexp_standard): Likewise.
9087 * f-exp.y: Likewise.
9088 * gdbtypes.c (make_reference_type, lookup_reference_type):
9089 Generalize with rvalue reference types.
9090 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9091 convenience wrappers for lookup_reference_type().
9092 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9093 reference kind parameter.
9094 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9095 wrappers for lookup_reference_type().
9096 * guile/scm-type.c (gdbscm_type_reference): Use
9097 lookup_lvalue_reference_type() instead of lookup_reference_type().
9098 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9099 * parse.c (follow_types): Likewise.
9100 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9101 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9102 Likewise.
9103 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9104 (gdbpy_invoke_xmethod): Likewise.
9105 * stabsread.c: Provide extra argument to make_reference_type()
9106 call.
9107 * valops.c (value_ref, value_rtti_indirect_type): Use
9108 lookup_lvalue_reference_type() instead of lookup_reference_type().
9109
f9aeb8d4
AV
91102017-03-20 Artemiy Volkov <artemiyv@acm.org>
9111
9112 PR gdb/14441
9113 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9114 (TYPE_IS_REFERENCE): New macro.
9115 (struct type): Add rvalue_reference_type field.
9116 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9117
51457a05
MAL
91182017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9119
9120 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9121 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9122 New function definition.
9123 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9124 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9125 New function declaration.
9126 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9127 * mi/mi-interp.h: New file.
9128 * solib.c (info_sharedlibrary_command): Replace for loop with
9129 ALL_SO_LIBS macro
9130 * solib.h (update_solib_list): New function declaration.
9131 (so_list_head): Move macro.
9132 * solist.h (ALL_SO_LIBS): New macro.
9133
e696b3ad
MAL
91342017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9135
9136 * infcmd.c (post_create_inferior): Remove unused argument in
9137 call to solib_add.
9138 * remote.c (remote_start_remote): Likewise.
9139 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9140 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9141 (enable_break): Likewise.
9142 * solib.c (update_solib_list): Remove unused target argument
9143 and its documentation.
9144 (solib_add): Remove unused target argument. Remove unused
9145 argument in call to update_solib_list.
9146 (info_sharedlibrary_command): Remove unused argument in call
9147 to update_solib_list.
9148 (sharedlibrary_command): Remove unused argument in call to
9149 solib_add.
9150 (handle_solib_event): Likewise.
9151 (reload_shared_libraries): Likewise.
9152 * solib.h (solib_add): Remove unused target argument.
9153
dcb84eda
AA
91542017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9155
9156 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9157 (s390_displaced_step_fixup): Cover relative branches with the
9158 default fixup handling. This fixes lack of support for some
9159 relative branch instructions.
9160
d9cb6cdc
SM
91612017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9162
9163 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9164 ptid from regcache.
9165
1afaf9f4
SM
91662017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9167
9168 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9169 i386_darwin_store_inferior_registers): Use ptid from regcache.
9170
aac12e24
SM
91712017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9172
9173 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9174 i386bsd_store_inferior_registers): Use ptid from regcache.
9175
bbe1eef1
SM
91762017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9177
9178 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9179 hppaobsd_store_registers): Use ptid from regcache.
9180
10799020
SM
91812017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9182
9183 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9184 hppanbsd_store_registers): Use ptid from regcache.
9185
00204cf7
SM
91862017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9187
9188 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9189 from regcache. Use get_ptrace_pid.
9190
11a33714
SM
91912017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9192
9193 * corelow.c (get_core_register_section): Use ptid from regcache,
9194 update doc.
9195
317cd492
SM
91962017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9197
9198 * bsd-uthread.c (bsd_uthread_fetch_registers,
9199 bsd_uthread_store_registers): Use ptid from regcache, set and
9200 restore inferior_ptid.
9201
9ac8a7c2
SM
92022017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9203
9204 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9205 fetch_fp_regs, store_register, store_regs, store_fp_register,
9206 store_fp_regs): Use ptid from regcache.
9207
4ac4bb6a
SM
92082017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9209
9210 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9211 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9212 store_vfp_regs): Use ptid from regcache.
9213
9bcbdca8
PA
92142017-03-17 Pedro Alves <palves@redhat.com>
9215
9216 PR remote/21188
9217 * ser-base.c (ser_base_wait_for): Add comment.
9218 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9219 version.
9220 * ser-unix.c (hardwire_raw): Remove reference to
9221 scb->current_timeout.
9222 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9223 (hardwire_ops): Install ser_base_readchar instead of
9224 hardwire_readchar.
9225 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9226 Remove fields.
9227
7503099f
JG
92282017-03-17 Jonah Graham <jonah@kichwacoders.com>
9229
9230 PR gdb/19637
9231 * python/lib/gdb/printer/bound_registers.py: Add support for
9232 Python 3.
9233
7942e96e
AA
92342017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9235
9236 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9237 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9238 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9239 byte_offset to subobj_byte_offset. Fix the handling of
9240 DWARF_VALUE_STACK on big-endian targets when coming via an
9241 implicit pointer.
9242 (dwarf2_evaluate_loc_desc): Adjust call to
9243 dwarf2_evaluate_loc_desc_full.
9244 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9245 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9246
ba14f379
YQ
92472017-03-16 Yao Qi <yao.qi@linaro.org>
9248
9249 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9250 and REVSH instructions.
9251
b121eeb9
YQ
92522017-03-16 Yao Qi <yao.qi@linaro.org>
9253
9254 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9255 (arm_record_test): Declare.
9256 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9257 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9258 align with the manual.
9259 (thumb_record_misc): Adjust the code order to align with the
9260 manual.
9261 (thumb2_record_decode_insn_handler): Fix instruction matching.
9262 (instruction_reader_thumb): New class.
9263 (arm_record_test): New function.
9264
728a7913
YQ
92652017-03-16 Yao Qi <yao.qi@linaro.org>
9266
9267 * arm-tdep.c (abstract_memory_reader): New class.
9268 (instruction_reader): New class.
9269 (extract_arm_insn): Add argument 'reader'. Callers updated.
9270 (decode_insn): Likewise.
9271
34b43320
DE
92722017-03-16 Doug Evans <dje@google.com>
9273
a7c0469f
DE
9274 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9275 member. Change type of TYPE member to SCM. All uses updated.
9276 (lsscm_make_lazy_string_smob): Add assert.
9277 (lsscm_make_lazy_string): Flag bad length values.
9278 (lsscm_elt_type): New function.
9279 (gdbscm_lazy_string_to_value): Rewrite to use
9280 lsscm_safe_lazy_string_to_value.
9281 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9282 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9283 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9284 in incoming type.
9285 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9286 * guile/scm-type.c (tyscm_scm_to_type): New function.
9287
92882017-03-15 Doug Evans <dje@google.com>
9289
34b43320
DE
9290 PR python/17728, python/18439, python/18779
9291 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9292 member. Change type of TYPE member to PyObject *. All uses updated.
9293 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9294 (gdbpy_create_lazy_string_object): Flag bad length values.
9295 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9296 Handle typedefs in incoming type.
9297 (stpy_lazy_string_elt_type): New function.
9298 (gdbpy_extract_lazy_string): Call it.
9299 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9300 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9301 typedefs in incoming type.
9302
a3a5fecc
DE
93032017-03-16 Doug Evans <dje@google.com>
9304
9305 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9306 * guile/scm-type.c (tyscm_scm_to_type): New function.
9307
28f1c605
JW
93082017-03-16 Jiong Wang <jiong.wang@arm.com>
9309
9310 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9311 "ULONGEST" for "skip".
9312
87c336f6
AA
93132017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9314
9315 PR gdb/21220
9316 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9317 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9318 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9319 over ptrace peek/poke until end of buffer or error.
9320
cf81cf60
SM
93212017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9322
9323 * parse.c (length_of_subexp): Make static.
9324 * parser-defs.h (length_of_subexp): Remove.
9325
a379284a
AA
93262017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9327
9328 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9329 as well.
9330
8a6200ba
PA
93312017-03-14 Pedro Alves <palves@redhat.com>
9332
9333 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9334 (main): Use std::unique_ptr. Remove calls to
9335 cp_demangled_name_parse_free.
9336
f79ec206
SM
93372017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9338
9339 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9340 alphabsd_store_inferior_registers): Use regcache->ptid instead
9341 of inferior_ptid.
9342
edb5fb00
SM
93432017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9344
9345 * aix-thread.c (aix_thread_fetch_registers,
9346 aix_thread_store_registers): Use regcache->ptid instead of
9347 inferior_ptid.
9348
55119686
SM
93492017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9350
9351 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9352 store_gregs_to_thread, fetch_fpregs_from_thread,
9353 store_fpregs_to_thread): Use regcache->ptid instead of
9354 inferior_ptid.
9355
6a06fbb7
SM
93562017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9357
9358 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9359 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9360 instead of inferior_ptid.
9361
c6386875
SM
93622017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9363
9364 * target.c (target_fetch_registers, target_store_registers): Add
9365 assert.
9366
ddaaf0fb
SM
93672017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9368
9369 * regcache.h (regcache_get_ptid): New function.
9370 * regcache.c (regcache_get_ptid): New function.
9371
b9da89d1 93722017-03-13 Mark Wielaard <mark@klomp.org>
9373
9374 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9375
5f4d1085
KS
93762017-03-10 Keith Seitz <keiths@redhat.com>
9377
9378 PR c++/8218
9379 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9380
c65d6b55
PA
93812017-03-08 Pedro Alves <palves@redhat.com>
9382
9383 PR gdb/18360
9384 * infrun.c (start_step_over, do_target_resume, resume)
9385 (restart_threads): Assert we're not resuming a thread that is
9386 meant to be stopped.
9387 (infrun_thread_stop_requested_callback): Delete.
9388 (infrun_thread_stop_requested): If the thread is internally
9389 stopped, queue a pending stop event and clear the thread's
9390 inline-frame state.
9391 (handle_stop_requested): New function.
9392 (handle_syscall_event, handle_inferior_event_1): Use
9393 handle_stop_requested.
9394 (handle_stop_requested): New function.
9395 (handle_signal_stop): Set the thread's stop_signal here instead of
9396 at caller.
9397 (finish_step_over): Clear step over info unconditionally.
9398 (handle_signal_stop): If the user had interrupted the event
9399 thread, consider the stop a random signal.
9400 (handle_signal_stop) <signal arrived while stepping over
9401 breakpoint>: Don't restart threads here.
9402 (stop_waiting): Don't clear step-over info here.
9403
15c22686
PA
94042017-03-08 Pedro Alves <palves@redhat.com>
9405
9406 PR 21206
9407 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9408 goes to argument 2, not 1.
9409
6e5d74e7
PA
94102017-03-08 Pedro Alves <palves@redhat.com>
9411
9412 PR cli/21218
9413 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9414 display_gdb_prompt.
9415 (command_line_input): Add comment.
9416
9753a2f6
PA
94172017-03-08 Pedro Alves <palves@redhat.com>
9418
9419 PR tui/21216
9420 * tui/tui-file.c (tui_file::write): New.
9421 * tui/tui-file.h (tui_file): Override "write".
9422 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
9423 factored out from ...
9424 (tui_puts): ... here.
9425 (tui_putc): Use them.
9426 (tui_write): New function.
9427 * tui/tui-io.h (tui_write): Declare.
9428
1672e0d9
SDJ
94292017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
9430
9431 * Makefile.in (SFILES): Replace "environ.c" with
9432 "common/environ.c".
9433 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
9434 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
9435 to...
9436 * common/environ.c: ... here.
9437 * environ.h: Moved to...
9438 * common/environ.h: ... here.
9439
f7bb4e3a
PB
94402017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9441
9442 * gdbarch.sh (pstring_ptr): New static function.
9443 (gdbarch_disassembler_options): Use it.
9444 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
9445 not valid_disassembler_option->name.
9446 * gdbarch.c: Regenerate.
9447
e45ced6c
PB
94482017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9449
9450 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
9451
5f6fd321
PA
94522017-03-07 Pedro Alves <palves@redhat.com>
9453
9454 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
9455
6dbb839a 94562017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
9457
9458 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
9459 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
9460 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 9461 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 9462
d274ecf4
SM
94632017-03-06 Simon Marchi <simon.marchi@ericsson.com>
9464
9465 * xtensa-linux-nat.c (fetch_gregs): Remove const.
9466
df97be55
SM
94672017-03-03 Simon Marchi <simon.marchi@ericsson.com>
9468
9469 * remote.c (remote_add_target_side_commands): Use range-based
9470 for loop.
9471
7d45f3df
YQ
94722017-03-03 Yao Qi <yao.qi@linaro.org>
9473
9474 PR gdb/21165
9475 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
9476 value is lazy.
9477 * valprint.c (common_val_print): Likewise.
9478
65b48a81
PB
94792017-02-28 Peter Bergner <bergner@vnet.ibm.com>
9480
9481 * NEWS: Mention new set/show disassembler-options commands.
9482 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
9483 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
9484 (prospective_options): New static variable.
9485 (gdb_disassembler::gdb_disassembler): Initialize
9486 m_di.disassembler_options.
9487 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
9488 (get_disassembler_options): New function.
9489 (set_disassembler_options): Likewise.
9490 (set_disassembler_options_sfunc): Likewise.
9491 (show_disassembler_options_sfunc): Likewise.
9492 (disassembler_options_completer): Likewise.
9493 (_initialize_disasm): Likewise.
9494 * disasm.h (get_disassembler_options): New prototype.
9495 (set_disassembler_options): Likewise.
9496 * gdbarch.sh (gdbarch_disassembler_options): New variable.
9497 (gdbarch_verify_disassembler_options): Likewise.
9498 * gdbarch.c: Regenerate.
9499 * gdbarch.h: Likewise.
9500 * arm-tdep.c (num_disassembly_options): Delete.
9501 (set_disassembly_style): Likewise.
9502 (arm_disassembler_options): New static variable.
9503 (set_disassembly_style_sfunc): Convert short style name into long
9504 option name. Call set_disassembler_options.
9505 (show_disassembly_style_sfunc): New function.
9506 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
9507 set_gdbarch_verify_disassembler_options.
9508 (_initialize_arm_tdep): Delete regnames variable and update callers.
9509 (arm_disassembler_options): Initialize.
9510 (disasm_options): New variable.
9511 (num_disassembly_options): Rename from this...
9512 (num_disassembly_styles): ...to this. Compute by scanning through
9513 disasm_options.
9514 (valid_disassembly_styles): Initialize using disasm_options.
9515 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
9516 set_arm_regname_option.
9517 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
9518 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
9519 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
9520 set_gdbarch_verify_disassembler_options.
9521 * s390-tdep.c (s390_disassembler_options): New static variable.
9522 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
9523 set_gdbarch_verify_disassembler_options.
9524
d538e36d
SM
95252017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9526
9527 * remote.c (remote_add_target_side_condition): Remove "struct"
9528 keyword from range-based for loop.
9529
83621223
SM
95302017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9531
9532 * remote.c (remote_add_target_side_condition): Use range-based
9533 for loop. Update comment.
9534
2123df0e
YQ
95352017-02-27 Yao Qi <yao.qi@linaro.org>
9536
9537 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
9538
8e368124
AH
95392017-02-26 Alan Hayward <alan.hayward@arm.com>
9540
9541 * regcache.c (regcache_raw_update): New function.
9542 (regcache_raw_read): Move code to regcache_raw_update.
9543 * regcache.h (regcache_raw_update): New declaration.
9544 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
9545
a49dd8dd
JK
95462017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
9547
9548 * dwarf2read.c (create_debug_type_hash_table): Initialize
9549 header.signature and header.type_offset_in_tu.
9550
34e4bae9
PA
95512017-02-24 Pedro Alves <palves@redhat.com>
9552
9553 * symtab.c (make_file_symbol_completion_list_1): Use
9554 add_symtab_completions.
9555
b0e4b369
AH
95562017-02-24 Alan Hayward <alan.hayward@arm.com>
9557
9558 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
9559
975c21ab
AH
95602017-02-24 Alan Hayward <alan.hayward@arm.com>
9561
9562 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
9563 I386_MAX_REGISTER_SIZE.
9564 (i386_pseudo_register_write): Likewise.
9565 (i386_process_record): Likewise.
9566 * i387-tdep.c (i387_supply_xsave): Likewise.
9567 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
9568 (store_register): Likewise.
9569
14bc53a8
PA
95702017-02-23 Pedro Alves <palves@redhat.com>
9571
9572 * ada-lang.c: Include "common/function-view.h".
9573 (ada_iterate_over_symbols): Adjust to use function_view as
9574 callback type.
9575 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
9576 (ada_make_symbol_completion_list): Use a lambda.
9577 (ada_exc_search_name_matches): Delete.
9578 (name_matches_regex): New.
9579 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
9580 * compile/compile-c-support.c: Include "common/function-view.h".
9581 (print_one_macro): Change prototype to accept a ui_file pointer.
9582 (write_macro_definitions): Use a lambda.
9583 * dwarf2read.c: Include "common/function-view.h".
9584 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9585 (dw2_expand_symtabs_matching): Adjust to use function_view as
9586 callback type.
9587 * language.h: Include "common/function-view.h".
9588 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
9589 function_view as callback type.
9590 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
9591 * linespec.c: Include "common/function-view.h".
9592 (collect_info::add_symbol): New method.
9593 (struct symbol_and_data_callback, iterate_inline_only, struct
9594 symbol_matcher_data, iterate_name_matcher): Delete.
9595 (iterate_over_all_matching_symtabs): Adjust to use function_view
9596 as callback type and lambdas.
9597 (iterate_over_file_blocks): Adjust to use function_view as
9598 callback type.
9599 (decode_compound_collector): Now a class with private fields.
9600 (decode_compound_collector::release_symbols): New method.
9601 (collect_one_symbol): Rename to...
9602 (decode_compound_collector::operator()): ... this and adjust.
9603 (lookup_prefix_sym): decode_compound_collector construction bits
9604 move to decode_compound_collector ctor. Pass the
9605 decode_compound_collector object directly as callback. Remove
9606 cleanups and use decode_compound_collector::release_symbols
9607 instead.
9608 (symtab_collector): Now a class with private fields.
9609 (symtab_collector::release_symtabs): New method.
9610 (add_symtabs_to_list): Rename to...
9611 (symtab_collector::operator()): ... this and adjust.
9612 (collect_symtabs_from_filename): symtab_collector construction
9613 bits move to symtab_collector ctor. Pass the symtab_collector
9614 object directly as callback. Remove cleanups and use
9615 symtab_collector::release_symtabs instead.
9616 (collect_symbols): Delete.
9617 (add_matching_symbols_to_info): Use lambdas.
9618 * macrocmd.c (print_macro_callback): Delete.
9619 (info_macro_command): Use a lambda.
9620 (info_macros_command): Pass print_macro_definition as callable
9621 directly.
9622 (print_one_macro): Remove 'ignore' parameter.
9623 (macro_list_command): Adjust.
9624 * macrotab.c (macro_for_each_data::fn): Now a function_view.
9625 (macro_for_each_data::user_data): Delete field.
9626 (foreach_macro): Adjust to call the function_view.
9627 (macro_for_each): Adjust to use function_view as callback type.
9628 (foreach_macro_in_scope): Adjust to call the function_view.
9629 (macro_for_each_in_scope): Adjust to use function_view as callback
9630 type.
9631 * macrotab.h: Include "common/function-view.h".
9632 (macro_callback_fn): Declare a prototype instead of a pointer.
9633 Remove "user_data" parameter.
9634 (macro_for_each, macro_for_each_in_scope): Adjust to use
9635 function_view as callback type.
9636 * psymtab.c (partial_map_expand_apply)
9637 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
9638 Adjust to use function_view as callback type and to return bool.
9639 (psym_expand_symtabs_matching): Adjust to use function_view as
9640 callback types.
9641 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
9642 to use function_view as callback type and to return bool.
9643 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
9644 callback types.
9645 * symfile.c (expand_symtabs_matching): Adjust to use function_view
9646 as callback types.
9647 * symfile.h: Include "common/function-view.h".
9648 (expand_symtabs_file_matcher_ftype)
9649 (expand_symtabs_symbol_matcher_ftype)
9650 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
9651 return bool.
9652 (quick_symbol_functions::map_symtabs_matching_filename)
9653 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
9654 function_view as callback type and return bool.
9655 (expand_symtabs_matching): Adjust to use function_view as callback
9656 type.
9657 (maintenance_expand_name_matcher)
9658 (maintenance_expand_file_matcher): Delete.
9659 (maintenance_expand_symtabs): Use lambdas.
9660 * symtab.c (iterate_over_some_symtabs): Adjust to use
9661 function_view as callback types and return bool.
9662 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
9663 of a cleanup.
9664 (lookup_symtab_callback): Delete.
9665 (lookup_symtab): Use a lambda.
9666 (iterate_over_symbols): Adjust to use function_view as callback
9667 type.
9668 (struct search_symbols_data, search_symbols_file_matches)
9669 (search_symbols_name_matches): Delete.
9670 (search_symbols): Use a pair of lambdas.
9671 (struct add_name_data, add_macro_name, symbol_completion_matcher)
9672 (symtab_expansion_callback): Delete.
9673 (default_make_symbol_completion_list_break_on_1): Use lambdas.
9674 * symtab.h: Include "common/function-view.h".
9675 (iterate_over_some_symtabs): Adjust to use function_view as
9676 callback type and return bool.
9677 (iterate_over_symtabs): Adjust to use function_view as callback
9678 type.
9679 (symbol_found_callback_ftype): Remove 'data' parameter and return
9680 bool.
9681 (iterate_over_symbols): Adjust to use function_view as callback
9682 type.
9683
07e253aa
PA
96842017-02-23 Pedro Alves <palves@redhat.com>
9685
9686 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
9687 (%.o) <unittests/%.c>: New pattern.
9688 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
9689 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
9690 * common/function-view.h: New file.
9691 * unittests/function-view-selftests.c: New file.
9692 * configure: Regenerate.
9693
8eaf5320
SM
96942017-02-23 Simon Marchi <simon.marchi@ericsson.com>
9695
9696 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
9697 inferior_ptid.
9698 * go32-nat.c (go32_thread_alive): Likewise.
9699
38768751
YQ
97002017-02-23 Yao Qi <yao.qi@linaro.org>
9701
9702 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
9703 delete.
9704
0a8beaba
YQ
97052017-02-23 Yao Qi <yao.qi@linaro.org>
9706
9707 * varobj.c (varobj_clear_saved_item): Use delete instead of
9708 xfree.
9709 (update_dynamic_varobj_children): Likewise.
9710
58fdfd2c
JK
97112017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9712
9713 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
9714
1b90b139
SM
97152017-02-21 Simon Marchi <simon.marchi@ericsson.com>
9716
9717 * common/enum-flags.h (enum_flags::enum_flags): Initialize
9718 m_enum_value to 0 in default constructor.
9719
2039d74e
EBM
97202017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9721
9722 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
9723 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
9724 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
9725 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
9726 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
9727 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
9728 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
9729 IS_STORE_CONDITIONAL_INSN.
9730
7814882a
JK
97312017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9732
9733 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
9734
0ae60b63
JK
97352017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9736
9737 * NEWS (Changes since GDB 7.12): Add DWARF-5.
9738
0224619f
JK
97392017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9740
9741 * dwarf2read.c (skip_one_die, read_attribute_value)
9742 (dwarf2_const_value_attr, dump_die_shallow)
9743 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9744 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
9745
0af92d60
JK
97462017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9747
9748 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
9749 (dwarf_parse_macro_header): Accept DWARF version 5.
9750 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
9751
216f72a1
JK
97522017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9753
9754 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
9755 DW_AT_GNU_*.
9756 * common/common-exceptions.h (enum errors): Likewise.
9757 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
9758 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
9759 (dwarf_expr_context::execute_stack_op): Likewise.
9760 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
9761 Likewise.
9762 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
9763 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9764 (show_entry_values_debug, call_site_to_target_addr)
9765 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
9766 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
9767 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
9768 (value_of_dwarf_block_entry, indirect_pieced_value)
9769 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
9770 (disassemble_dwarf_expression): Likewise.
9771 * dwarf2read.c (process_die, inherit_abstract_dies)
9772 (read_call_site_scope): Likewise.
9773 * gdbtypes.h (struct func_type, struct call_site_parameter)
9774 (struct call_site): Likewise.
9775 * stack.c (read_frame_arg): Likewise.
9776 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
9777
43988095
JK
97782017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9779
9780 * defs.h (read_unsigned_leb128): New declaration.
9781 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
9782 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
9783 (dwarf2_find_location_expression): Call also
9784 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
9785 * dwarf2loc.h (dwarf2_version): New declaration.
9786 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
9787 rnglists.
9788 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
9789 .debug_rnglists.
9790 (struct dwop_section_names): Add loclists_dwo.
9791 (dwop_section_names): Add .debug_loclists.dwo.
9792 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
9793 (struct dwarf2_per_cu_data): Add dwarf_version.
9794 (struct dwo_sections): Add loclists.
9795 (struct attr_abbrev): Add implicit_const.
9796 (read_indirect_line_string): New declaration.
9797 (read_unsigned_leb128): Delete declaration.
9798 (rcuh_kind): New definition.
9799 (read_and_check_comp_unit_head): Change parameter
9800 is_debug_types_section to section_kind.
9801 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
9802 (read_comp_unit_head): Change parameter abfd to section, add parameter
9803 section_kind. Handle DWARF-5.
9804 (error_check_comp_unit_head): Accept also DWARF version 5.
9805 (read_and_check_comp_unit_head): Change parameter
9806 is_debug_types_section to section_kind.
9807 (read_and_check_type_unit_head): Delete function.
9808 (read_abbrev_offset): Handle DWARF-5.
9809 (create_debug_type_hash_table): Add parameter section_kind. Process
9810 only DW_UT_type. Use signature and type_offset_in_tu from struct
9811 comp_unit_head.
9812 (create_debug_types_hash_table): Update create_debug_type_hash_table
9813 caller.
9814 (create_all_type_units): Call create_debug_type_hash_table.
9815 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
9816 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
9817 caller.
9818 (skip_one_die): Handle DW_FORM_implicit_const.
9819 (dwarf2_rnglists_process): New function.
9820 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
9821 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
9822 (read_attribute_value): Handle DW_FORM_implicit_const,
9823 DW_FORM_line_strp.
9824 (read_attribute): Handle DW_FORM_implicit_const.
9825 (read_indirect_string_at_offset_from): New function from
9826 read_indirect_string_at_offset.
9827 (read_indirect_string_at_offset): Call
9828 read_indirect_string_at_offset_from.
9829 (read_indirect_line_string_at_offset): New function.
9830 (read_indirect_string): New function comment.
9831 (read_indirect_line_string): New function.
9832 (read_unsigned_leb128): Make it global.
9833 (dwarf2_string_attr): Handle DWARF-5.
9834 (add_include_dir_stub, read_formatted_entries): New functions.
9835 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
9836 Handle DWARF-5.
9837 (per_cu_header_read_in): Update read_comp_unit_head caller.
9838 (dwarf2_version): New function.
9839 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
9840 rnglists.
9841 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
9842 fields.
9843
22d2f3ab
JK
98442017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9845
9846 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
9847
5f46c5a5
JK
98482017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9849
9850 * dwarf2read.c (dwarf2_ranges_process): New function from
9851 dwarf2_ranges_read.
9852 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
9853 dwarf2_ranges_process.
9854
78d4d2c5
JK
98552017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9856
9857 * dwarf2read.c (create_debug_type_hash_table): New function from
9858 create_debug_types_hash_table.
9859 (create_debug_types_hash_table): Call create_debug_type_hash_table.
9860 (create_all_type_units, open_and_init_dwo_file): Update
9861 create_debug_types_hash_table callers.
9862
1b076f25
SDJ
98632017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9864
9865 PR gdb/16188
9866 * fork-child.c (trace_start_error): Fix thinko. va_end should
9867 refer to 'ap', not 'args'.
9868
0db8980c
SDJ
98692017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9870 Pedro Alves <palves@redhat.com>
9871
9872 PR gdb/16188
9873 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
9874 calls succeeded.
9875 * fork-child.c (trace_start_error): New function.
9876 (trace_start_error_with_name): Likewise.
9877 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
9878 * inf-ptrace.c (inf_ptrace_me): Likewise.
9879 * inferior.h (trace_start_error): New prototype.
9880 (trace_start_error_with_name): Likewise.
9881
99e8a4f9
SDJ
98822017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
9883
9884 PR gdb/21164
9885 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
9886 NULL before using it.
9887 * symmisc.c (maintenance_print_symbols): Likewise.
9888 (maintenance_print_msymbols): Likewise.
9889
4e746bb6
TW
98902017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9891
9892 * NEWS: Add record Python bindings entry.
9893
98942017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9895
9896 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
9897 py-record-full.o.
9898 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
9899 * python/py-record-btrace.c, python/py-record-btrace.h,
9900 python/py-record-full.c, python/py-record-full.h: New file.
9901 * python/py-record.c: Add include for py-record-btrace.h and
9902 py-record-full.h.
9903 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
9904 recpy_instruction_history, recpy_function_call_history, recpy_begin,
9905 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
9906 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
9907 New definition.
9908 (gdbpy_initialize_btrace): New export.
9909 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
9910
99112017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9912
9913 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
9914 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
9915 * python/py-record.c: New file.
9916 * python/python-internal.h (gdbpy_start_recording,
9917 gdbpy_current_recording, gdpy_stop_recording,
9918 gdbpy_initialize_record): New export.
9919 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
9920 (python_GdbMethods): Add gdbpy_start_recording,
9921 gdbpy_current_recording and gdbpy_stop_recording.
9922
99232017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9924
9925 * record-btrace.c (record_btrace_record_method): New function.
9926 (init_record_btrace_ops): Initialize to_record_method.
9927 * record-full.c (record_full_record_method): New function.
9928 (init_record_full_ops, init_record_full_core_ops): Add
9929 record_full_record_method.
9930 * record.h (enum record_method): New enum.
9931 * target-debug.h (target_debug_print_enum_record_method: New define.
9932 * target-delegates.c: Regenerate.
9933 * target.c (target_record_method): New function.
9934 * target.h: Include record.h.
9935 (struct target_ops) <to_record_method>: New field.
9936 (target_record_method): New export.
9937
99382017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9939
9940 * record.h (record_start, record_stop): New export.
9941 * record.c (record_start, record_stop): New function.
9942
99432017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9944
9945 * btrace.c (btrace_fetch): Copy function call segments pointer
9946 into a vector.
9947 (btrace_clear): Clear the vector.
9948 (btrace_find_insn_by_number): Use binary search to find the correct
9949 function call segment.
9950 * btrace.h (brace_fun_p): New typedef.
9951 (struct btrace_thread_info) <functions>: New field.
9952
99532017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9954
9955 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
9956 * btrace.c (btrace_decode_error): ... here. New function.
9957 * btrace.h (btrace_decode_error): New export.
9958
99592017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
9960
9961 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
9962 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
9963 btrace_find_insn_by_number): Remove special case for gaps.
9964 * btrace.h (btrace_insn_get_error): New export.
9965 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
9966 * record-btrace.c (btrace_insn_history): Print number for gaps.
9967 (record_btrace_info, record_btrace_goto): Handle gaps.
9968
3f77c769
TT
99692017-02-14 Tom Tromey <tom@tromey.com>
9970
9971 PR python/13598:
9972 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
9973 event.
9974 * python/py-evts.c (gdbpy_initialize_py_events): Add
9975 before_prompt registry.
9976 * python/py-events.h (events_object) <before_prompt>: New field.
9977
4c2c7ac6
MM
99782017-02-14 Markus Metzger <markus.t.metzger@intel.com>
9979
9980 * btrace.c (ftrace_new_switch): Preserve up link and flags.
9981
5cf30ebf
LM
99822017-02-13 Luis Machado <lgustavo@codesourcery.com>
9983
9984 * symfile (_initialize_symfile): Add usage text to the load command's
9985 help text.
9986
26a06916
SM
99872017-02-10 Simon Marchi <simon.marchi@ericsson.com>
9988
9989 * utils.c (defaulted_query): Don't query on secondary UIs.
9990
0b145e37
TT
99912017-02-10 Tom Tromey <tom@tromey.com>
9992
9993 * rust-lang.c (rust_get_disr_info): Remove unused variable.
9994
2d8365c4
TT
99952017-02-10 Tom Tromey <tom@tromey.com>
9996
9997 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
9998 "cleanup" local.
9999 * python/py-type.c (typy_legacy_template_argument): Remove
10000 unnecessary "cleanup" local.
10001
2bb8f231
TT
100022017-02-10 Tom Tromey <tom@tromey.com>
10003
10004 * python/python.c (do_start_initialization): New function, from
10005 _initialize_python.
10006 (_initialize_python): Call do_start_initialization.
10007 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10008 goto.
10009
1bdfaf42
TT
100102017-02-10 Tom Tromey <tom@tromey.com>
10011
10012 * python/py-prettyprint.c (pretty_print_one_value): Use
10013 gdbpy_ref.
10014
88b6faea
TT
100152017-02-10 Tom Tromey <tom@tromey.com>
10016
10017 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10018 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10019 gdbpy_ref.
10020 * python/py-type.c (field_new): Use gdbpy_ref.
10021 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10022 gdbpy_ref.
10023 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10024 (py_free_pspace): Likewise.
10025 (pspace_to_pspace_object): Likewise.
10026 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10027 (py_free_objfile): Likewise.
10028 (objfile_to_objfile_object): Likewise.
10029 * python/py-inferior.c (delete_thread_object): Use
10030 gdbpy_ref.
10031 (infpy_read_memory): Likewise.
10032 (py_free_inferior): Likewise.
10033 * python/py-evtregistry.c (create_eventregistry_object): Use
10034 gdbpy_ref.
10035 * python/py-event.c (create_event_object): Use gdbpy_ref.
10036
7780f186
TT
100372017-02-10 Tom Tromey <tom@tromey.com>
10038
10039 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10040 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10041 used.
10042 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10043 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10044 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10045 python/py-framefilter.c, python/py-function.c,
10046 python/py-inferior.c, python/py-infevents.c,
10047 python/py-linetable.c, python/py-newobjfileevent.c,
10048 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10049 python/py-signalevent.c, python/py-stopevent.c,
10050 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10051 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10052 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10053 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10054
d4b0bb18
TT
100552017-02-10 Tom Tromey <tom@tromey.com>
10056
10057 * ui-out.h (ui_out_emit_type): New class.
10058 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10059 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10060 and ui_out_emit_tuple.
10061 (enumerate_locals): Likewise.
10062 (py_mi_print_variables, py_print_locals, py_print_args): Use
10063 ui_out_emit_list.
10064 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10065 ui_out_emit_list.
10066 * common/gdb_optional.h: New file.
10067
f67f945c
MG
100682017-02-10 Martin Galvan <martingalvan@sourceware.org>
10069
10070 * MAINTAINERS (Write After Approval): Update my e-mail address.
10071
18da0c51
MG
100722017-02-10 Martin Galvan <martingalvan@sourceware.org>
10073
10074 PR gdb/21122
10075 * breakpoint.c (_initialize_breakpoint): Update the help description
10076 of the 'commands' command to indicate that it takes a list argument.
10077
62c14536
SM
100782017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10079
10080 * interps.c (current_interp_set_logging): Remove "return".
10081
ff6fa247
GB
100822017-02-09 Gary Benson <gbenson@redhat.com>
10083
10084 * symtab.c (add_symtab_completions): Prevent NULL pointer
10085 dereference.
10086
a474bd8e
PA
100872017-02-08 Pedro Alves <palves@redhat.com>
10088
10089 * interps.c (interp::interp): Remove reference to quiet_p.
10090 (interp_set): Make static. Remove dead "Switching to" output
10091 code.
10092 (interp_quiet_p, interp_set_quiet): Delete.
10093 (interpreter_exec_cmd): Don't set the interpreter quiet.
10094 * interps.h (interp_quiet_p): Make static.
10095 (class interp) <quiet_p>: Remove field
10096
3d7b173c
JG
100972017-02-08 Jerome Guitton <guitton@adacore.com>
10098
604c4576
JG
10099 * cli/cli-decode.c (find_command_name_length): Make it extern.
10100 * cli/cli-decode.h (find_command_name_length): Declare.
10101 * cli/cli-script.c (command_name_equals, line_first_arg):
10102 New functions.
10103 (process_next_line): Use cli-decode to parse command names.
10104 (build_command_line): Make args a constant pointer.
10105
101062017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 10107
3d7b173c
JG
10108 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10109 Remove case-insensitive search.
10110
1291063d
JM
101112017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10112
10113 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10114 at the end of the line. Avoids an ARI warning.
10115
20b477a7
LM
101162017-02-06 Luis Machado <lgustavo@codesourcery.com>
10117
10118 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10119 rdseed instructions.
10120 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10121
3f7b46f2
IR
101222017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10123
10124 PR tdep/20936
10125 Provide and use sparc32 and sparc64 target description XML files.
10126 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10127 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10128 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10129 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10130 * features/sparc/sparc32-solaris.xml: New file.
10131 * features/sparc/sparc64-solaris.xml: New file.
10132 * features/sparc/sparc32-solaris.c: Generated.
10133 * features/sparc/sparc64-solaris.c: Generated.
10134 * sparc-tdep.h: Account for differences in target descriptions.
10135 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10136 (sparc32_register_type): Use target provided registers.
10137 (validate_tdesc_registers): New function.
10138 (sparc32_gdbarch_init): Use tdesc_has_registers.
10139 Set pseudoregister functions.
10140 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10141 (sparc64_register_type): Use target provided registers.
10142 (sparc64_init_abi): Set pseudoregister functions.
10143
f0fd41c1
TT
101442017-02-03 Tom Tromey <tom@tromey.com>
10145
10146 PR rust/21097:
10147 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10148 with a single member.
10149
d6f9b0fb
PA
101502017-02-03 Pedro Alves <palves@redhat.com>
10151
10152 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10153 (cli_interp_base::~cli_interp_base): New.
10154 (cli_interp): New struct.
10155 (as_cli_interp): Cast the interp itself to cli_interp.
10156 (cli_interpreter_pre_command_loop): Rename to ...
10157 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10158 parameter.
10159 (cli_interpreter_init): Rename to ...
10160 (cli_interp::init): ... this. Remove 'self' parameter. Use
10161 boolean. Make extern.
10162 (cli_interpreter_resume): Rename to ...
10163 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10164 extern.
10165 (cli_interpreter_suspend): Rename to ...
10166 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10167 extern.
10168 (cli_interpreter_exec): Rename to ...
10169 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10170 extern.
10171 (cli_interpreter_supports_command_editing): Rename to ...
10172 (cli_interp_base::supports_command_editing): ... this. Remove
10173 'interp' parameter. Make extern.
10174 (cli_ui_out): Rename to ...
10175 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10176 Make extern.
10177 (cli_set_logging): Rename to ...
10178 (cli_interp_base::set_logging): ... this. Remove 'interp'
10179 parameter. Make extern.
10180 (cli_interp_procs): Delete.
10181 (cli_interp_factory): Adjust to use "new".
10182 * cli/cli-interp.h: Include "interps.h".
10183 (struct cli_interp_base): New struct.
10184 * interps.c (struct interp): Delete. Fields moved to interps.h.
10185 (interp_new): Delete.
10186 (interp::interp, interp::~interp): New.
10187 (interp_set): Use bool, and return void. Assume the interpreter
10188 has suspend, init and resume methods, and that the all return
10189 void.
10190 (set_top_level_interpreter): interp_set returns void.
10191 (interp_ui_out): Adapt.
10192 (current_interp_set_logging): Adapt.
10193 (interp_data): Delete.
10194 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10195 (interp_exec): Adapt.
10196 (top_level_interpreter_data): Delete.
10197 * interps.h (interp_init_ftype, interp_resume_ftype)
10198 (interp_suspend_ftype, interp_exec_ftype)
10199 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10200 (class interp): New.
10201 (interp_new): Delete.
10202 (interp_set): Now returns void. Use bool.
10203 (interp_data, top_level_interpreter_data): Delete.
10204 * mi/mi-common.h: Include interps.h.
10205 (class mi_interp): Inherit from interp. Define a ctor. Declare
10206 init, resume, suspect, exec, interp_ui_out, set_logging and
10207 pre_command_loop methods.
10208 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10209 (mi_interpreter_init): Rename to ...
10210 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10211 bool, return void and make extern. Adjust.
10212 (mi_interpreter_resume): ... Rename to ...
10213 (mi_interp::resume): ... this. Remove the 'data' parameter,
10214 return void and make extern. Adjust.
10215 (mi_interpreter_suspend): ... Rename to ...
10216 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10217 return void and make extern. Adjust.
10218 (mi_interpreter_exec): ... Rename to ...
10219 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10220 extern. Adjust.
10221 (mi_interpreter_pre_command_loop): ... Rename to ...
10222 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10223 parameter and make extern.
10224 (mi_on_normal_stop_1): Adjust.
10225 (mi_ui_out): Rename to ...
10226 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10227 parameter and make extern. Adjust.
10228 (mi_set_logging): Rename to ...
10229 (mi_interp::set_logging): ... this. Remove the 'interp'
10230 parameter and make extern. Adjust.
10231 (mi_interp_procs): Delete.
10232 (mi_interp_factory): Adjust to use 'new'.
10233 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10234 (mi_print_exception, mi_execute_command, mi_load_progress):
10235 Adjust.
10236 * tui/tui-interp.c (tui_interp): New class.
10237 (as_tui_interp): Return a tui_interp pointer.
10238 (tui_on_normal_stop, tui_on_signal_received)
10239 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10240 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10241 to use interp::interp_ui_out.
10242 (tui_init): Rename to ...
10243 (tui_interp::init): ... this. Remove the 'self' parameter, use
10244 bool, return void and make extern. Adjust.
10245 (tui_resume): Rename to ...
10246 (tui_interp::resume): ... this. Remove the 'data' parameter,
10247 return void and make extern. Adjust.
10248 (tui_suspend): Rename to ...
10249 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10250 return void and make extern. Adjust.
10251 (tui_ui_out): Rename to ...
10252 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10253 parameter, and make extern. Adjust.
10254 (tui_exec): Rename to ...
10255 (tui_interp::exec): ... this. Remove the 'data' parameter and
10256 make extern.
10257 (tui_interp_procs): Delete.
10258 (tui_interp_factory): Use "new".
10259
65c40c95
TT
102602017-02-02 Tom Tromey <tom@tromey.com>
10261
10262 * rust-exp.y (ends_raw_string, space_then_number)
10263 (rust_identifier_start_p): Return bool.
10264 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10265 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10266 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10267 (rust_chartype_p): Return bool.
10268 (val_print_struct, rust_print_struct_def, rust_print_type):
10269 Update.
10270 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10271 Return bool.
10272
b50f188d
TT
102732017-02-02 Tom Tromey <tom@tromey.com>
10274
10275 * rust-lang.c: Reindent.
10276
03c85b11
TT
102772017-02-02 Tom Tromey <tom@tromey.com>
10278
10279 * rust-lang.h (rust_crate_for_block): Update.
10280 * rust-lang.c (rust_crate_for_block): Return std::string.
10281 (rust_get_disr_info): Use std:;string, not
10282 gdb::unique_xmalloc_ptr.
10283 * rust-exp.y (crate_name): Update.
10284
9b6da501
PA
102852017-02-02 Pedro Alves <palves@redhat.com>
10286
10287 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10288 field out of gdb_disassembler_test and make it static.
10289
ec4cb20b
PA
102902017-02-02 Pedro Alves <palves@redhat.com>
10291
10292 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10293 mi1_interp and mi_interp fields.
10294
5be5dbf0
PA
102952017-02-02 Pedro Alves <palves@redhat.com>
10296
616268b6
PA
10297 * cli/cli-interp.c (struct saved_output_files, saved_output):
10298 Moved from cli/cli-logging.c.
10299 (cli_set_logging): New function.
10300 (cli_interp_procs): Install cli_set_logging.
10301 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10302 Declare.
10303 * cli/cli-logging.c (struct saved_output_files, saved_output):
10304 Moved to cli/cli-interp.c.
10305 (pop_output_files): Don't save outputs here.
10306 (make_logging_output): New function.
10307 (handle_redirections): Don't build tee nor save previous outputs
10308 here.
10309 * interps.c (current_interp_set_logging): Change prototype.
10310 Assume there's always a set_logging_proc method installed.
10311 * interps.h (interp_set_logging_ftype): Change prototype.
10312 (current_interp_set_logging): Change prototype and adjust comment.
10313 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10314 use make_logging_output.
10315 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
103162017-02-02 Pedro Alves <palves@redhat.com>
10317
5be5dbf0
PA
10318 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10319 from ...
10320 (set_logging_overwrite): ... here.
10321 (logging_no_redirect_file): Delete.
10322 (set_logging_redirect): Don't handle redirection on the fly.
10323 Instead warn that "logging off" / "logging on" is necessary.
10324 (pop_output_files): Delete references to logging_no_redirect_file.
10325 (show_logging_command): Always speak in terms of what will happen
10326 once logging is reenabled.
10327
c99cc448
PA
103282017-02-02 Pedro Alves <palves@redhat.com>
10329
10330 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10331
8b172ce7
PA
103322017-02-02 Pedro Alves <palves@redhat.com>
10333
10334 * disasm.c (gdb_pretty_print_insn): Rename to ...
10335 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10336 Remove gdbarch parameter. Adapt to clear the object's buffers
10337 instead of allocating new buffers, and to print using the object's
10338 gdb_disassembler instead of calling gdb_print_insn.
10339 (dump_insns): Use gdb_pretty_print_disassembler.
10340 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10341 (gdb_pretty_print_disassembler): New class.
10342 * record-btrace.c (btrace_insn_history): Use
10343 gdb_pretty_print_disassembler.
10344
d7e74731
PA
103452017-02-02 Pedro Alves <palves@redhat.com>
10346
10347 * ada-lang.c (type_as_string): Use string_file.
10348 * ada-valprint.c (ada_print_floating): Use string_file.
10349 * ada-varobj.c (ada_varobj_scalar_image)
10350 (ada_varobj_get_value_image): Use string_file.
10351 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10352 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10353 * breakpoint.c (update_inserted_breakpoint_locations)
10354 (insert_breakpoint_locations, reattach_breakpoints)
10355 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10356 (print_it_watchpoint): Use string_file.
10357 (save_breakpoints): Use stdio_file.
10358 * c-exp.y (oper): Use string_file.
10359 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10360 tee_file.
10361 (pop_output_files): Use delete.
10362 (handle_redirections): Use stdio_file and tee_file.
10363 * cli/cli-setshow.c (do_show_command): Use string_file.
10364 * compile/compile-c-support.c (c_compute_program): Use
10365 string_file.
10366 * compile/compile-c-symbols.c (generate_vla_size): Take a
10367 'string_file &' instead of a 'ui_file *'.
10368 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10369 of a 'ui_file *'. Use string_file.
10370 (generate_c_for_variable_locations): Take a 'string_file &'
10371 instead of a 'ui_file *'.
10372 * compile/compile-internal.h (generate_c_for_for_one_variable):
10373 Take a 'string_file &' instead of a 'ui_file *'.
10374 * compile/compile-loc2c.c (push, pushf, unary, binary)
10375 (print_label, pushf_register_address, pushf_register)
10376 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10377 'ui_file *'. Adjust.
10378 * compile/compile.c (compile_to_object): Use string_file.
10379 * compile/compile.h (compile_dwarf_expr_to_c)
10380 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10381 'ui_file *'.
10382 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10383 (replace_typedefs_qualified_name): Use string_file and
10384 obstack_copy0.
10385 * disasm.c (gdb_pretty_print_insn): Use string_file.
10386 (gdb_disassembly): Adjust reference the null_stream global.
10387 (do_ui_file_delete): Delete.
10388 (gdb_insn_length): Use null_stream.
10389 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10390 * dwarf2loc.c (dwarf2_compile_property_to_c)
10391 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10392 'string_file &' instead of a 'ui_file *'.
10393 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10394 * dwarf2read.c (do_ui_file_peek_last): Delete.
10395 (dwarf2_compute_name): Use string_file.
10396 * event-top.c (gdb_setup_readline): Use stdio_file.
10397 * gdbarch.sh (verify_gdbarch): Use string_file.
10398 * gdbtypes.c (safe_parse_type): Use null_stream.
10399 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10400 string_file.
10401 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10402 'string_file *' instead of a 'ui_file *'.
10403 (gdbscm_arch_disassemble): Use string_file.
10404 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10405 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10406 inherits from ui_file.
10407 (ioscm_file_port_delete, ioscm_file_port_rewind)
10408 (ioscm_file_port_put): Delete.
10409 (ioscm_file_port_write): Rename to ...
10410 (ioscm_file_port::write): ... this. Remove file_port_magic
10411 checks.
10412 (ioscm_file_port_new): Delete.
10413 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10414 ui_file_up.
10415 * guile/scm-type.c (tyscm_type_name): Use string_file.
10416 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10417 Use string_file.
10418 * infcmd.c (print_return_value_1): Use string_file.
10419 * infrun.c (print_target_wait_results): Use string_file.
10420 * language.c (add_language): Use string_file.
10421 * location.c (explicit_to_string_internal): Use string_file.
10422 * main.c (captured_main_1): Use null_file.
10423 * maint.c (maintenance_print_architecture): Use stdio_file.
10424 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
10425 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
10426 event_channel>: Change type to mi_console_file pointer.
10427 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
10428 (mi_console_file_delete): Delete.
10429 (struct mi_console_file): Delete.
10430 (mi_console_file_magic): Delete.
10431 (mi_console_file_new): Delete.
10432 (mi_console_file::mi_console_file): New.
10433 (mi_console_file_delete): Delete.
10434 (mi_console_file_fputs): Delete.
10435 (mi_console_file::write): New.
10436 (mi_console_raw_packet): Delete.
10437 (mi_console_file::flush): New.
10438 (mi_console_file_flush): Delete.
10439 (mi_console_set_raw): Rename to ...
10440 (mi_console_file::set_raw): ... this.
10441 * mi/mi-console.h (class mi_console_file): New class.
10442 (mi_console_file_new, mi_console_set_raw): Delete.
10443 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
10444 (mi_set_logging): Use delete and tee_file. Adjust.
10445 * mi/mi-main.c (output_register): Use string_file.
10446 (mi_cmd_data_evaluate_expression): Use string_file.
10447 (mi_cmd_data_read_memory): Use string_file.
10448 (mi_cmd_execute, print_variable_or_computed): Use string_file.
10449 * mi/mi-out.c (mi_ui_out::main_stream): New.
10450 (mi_ui_out::rewind): Use main_stream and
10451 string_file.
10452 (mi_ui_out::put): Use main_stream and string_file.
10453 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10454 Allocate a 'string_file' instead.
10455 (mi_out_new): Don't allocate a mem_fileopen stream here.
10456 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10457 (mi_ui_out::main_stream): Declare method.
10458 * printcmd.c (eval_command): Use string_file.
10459 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
10460 * python/py-arch.c (archpy_disassemble): Use string_file.
10461 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
10462 * python/py-frame.c (frapy_str): Use string_file.
10463 * python/py-framefilter.c (py_print_type, py_print_single_arg):
10464 Use string_file.
10465 * python/py-type.c (typy_str): Use string_file.
10466 * python/py-unwind.c (unwind_infopy_str): Use string_file.
10467 * python/py-value.c (valpy_str): Use string_file.
10468 * record-btrace.c (btrace_insn_history): Use string_file.
10469 * regcache.c (regcache_print): Use stdio_file.
10470 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
10471 * remote.c (escape_buffer): Use string_file.
10472 * rust-lang.c (rust_get_disr_info): Use string_file.
10473 * serial.c (serial_open_ops_1): Use stdio_file.
10474 (do_serial_close): Use delete.
10475 * stack.c (print_frame_arg): Use string_file.
10476 (print_frame_args): Remove local mem_fileopen stream, not used.
10477 (print_frame): Use string_file.
10478 * symmisc.c (maintenance_print_symbols): Use stdio_file.
10479 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
10480 Take a 'string_file *' instead of a 'ui_file *'.
10481 * top.c (new_ui): Use stdio_file and stderr_file.
10482 (free_ui): Use delete.
10483 (execute_command_to_string): Use string_file.
10484 (quit_confirm): Use string_file.
10485 * tracepoint.c (collection_list::append_exp): Use string_file.
10486 * tui/tui-disasm.c (tui_disassemble): Use string_file.
10487 * tui/tui-file.c: Don't include "ui-file.h".
10488 (enum streamtype, struct tui_stream): Delete.
10489 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
10490 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
10491 (tui_file::tui_file): New method.
10492 (tui_file_fputs): Delete.
10493 (tui_file_get_strbuf): Delete.
10494 (tui_file::puts): New method.
10495 (tui_file_adjust_strbuf): Delete.
10496 (tui_file_flush): Delete.
10497 (tui_file::flush): New method.
10498 * tui/tui-file.h: Tweak intro comment.
10499 Include ui-file.h.
10500 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
10501 (tui_file_adjust_strbuf): Delete declarations.
10502 (class tui_file): New class.
10503 * tui/tui-io.c (tui_initialize_io): Use tui_file.
10504 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
10505 (tui_register_format): Use string_stream.
10506 * tui/tui-stack.c (tui_make_status_line): Use string_file.
10507 (tui_get_function_from_frame): Use string_file.
10508 * typeprint.c (type_to_string): Use string_file.
10509 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
10510 (null_stream): New global.
10511 (ui_file_delete): Delete.
10512 (ui_file::ui_file): New.
10513 (null_file_isatty): Delete.
10514 (ui_file::~ui_file): New.
10515 (null_file_rewind): Delete.
10516 (ui_file::printf): New.
10517 (null_file_put): Delete.
10518 (null_file_flush): Delete.
10519 (ui_file::putstr): New.
10520 (null_file_write): Delete.
10521 (ui_file::putstrn): New.
10522 (null_file_read): Delete.
10523 (ui_file::putc): New.
10524 (null_file_fputs): Delete.
10525 (null_file_write_async_safe): Delete.
10526 (ui_file::vprintf): New.
10527 (null_file_delete): Delete.
10528 (null_file::write): New.
10529 (null_file_fseek): Delete.
10530 (null_file::puts): New.
10531 (ui_file_data): Delete.
10532 (null_file::write_async_safe): New.
10533 (gdb_flush, ui_file_isatty): Adjust.
10534 (ui_file_put, ui_file_rewind): Delete.
10535 (ui_file_write): Adjust.
10536 (ui_file_write_for_put): Delete.
10537 (ui_file_write_async_safe, ui_file_read): Adjust.
10538 (ui_file_fseek): Delete.
10539 (fputs_unfiltered): Adjust.
10540 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
10541 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
10542 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
10543 (set_ui_file_data): Delete.
10544 (string_file::~string_file, string_file::write)
10545 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
10546 (do_ui_file_as_string, ui_file_as_string): Delete.
10547 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
10548 (struct mem_file): Delete.
10549 (mem_file_new): Delete.
10550 (stdio_file::stdio_file): New.
10551 (mem_file_delete): Delete.
10552 (stdio_file::stdio_file): New.
10553 (mem_fileopen): Delete.
10554 (stdio_file::~stdio_file): New.
10555 (mem_file_rewind): Delete.
10556 (stdio_file::set_stream): New.
10557 (mem_file_put): Delete.
10558 (stdio_file::open): New.
10559 (mem_file_write): Delete.
10560 (stdio_file_magic, struct stdio_file): Delete.
10561 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
10562 (stdio_file::flush): New.
10563 (stdio_file_read): Rename to ...
10564 (stdio_file::read): ... this. Adjust.
10565 (stdio_file_write): Rename to ...
10566 (stdio_file::write): ... this. Adjust.
10567 (stdio_file_write_async_safe): Rename to ...
10568 (stdio_file::write_async_safe) ... this. Adjust.
10569 (stdio_file_fputs): Rename to ...
10570 (stdio_file::puts) ... this. Adjust.
10571 (stdio_file_isatty): Delete.
10572 (stdio_file_fseek): Delete.
10573 (stdio_file::isatty): New.
10574 (stderr_file_write): Rename to ...
10575 (stderr_file::write) ... this. Adjust.
10576 (stderr_file_fputs): Rename to ...
10577 (stderr_file::puts) ... this. Adjust.
10578 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
10579 (stderr_file::stderr_file): New.
10580 (tee_file_magic): Delete.
10581 (struct tee_file): Delete.
10582 (tee_file::tee_file): New.
10583 (tee_file_new): Delete.
10584 (tee_file::~tee_file): New.
10585 (tee_file_delete): Delete.
10586 (tee_file_flush): Rename to ...
10587 (tee_file::flush): ... this. Adjust.
10588 (tee_file_write): Rename to ...
10589 (tee_file::write): ... this. Adjust.
10590 (tee_file::write_async_safe): New.
10591 (tee_file_fputs): Rename to ...
10592 (tee_file::puts): ... this. Adjust.
10593 (tee_file_isatty): Rename to ...
10594 (tee_file::isatty): ... this. Adjust.
10595 * ui-file.h (struct obstack, struct ui_file): Don't
10596 forward-declare.
10597 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
10598 (ui_file_write_ftype)
10599 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
10600 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
10601 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
10602 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
10603 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
10604 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
10605 (set_ui_file_fseek): Delete.
10606 (ui_file_data, ui_file_delete, ui_file_rewind)
10607 (struct ui_file): New.
10608 (ui_file_up): New.
10609 (class null_file): New.
10610 (null_stream): Declare.
10611 (ui_file_write_for_put, ui_file_put): Delete.
10612 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
10613 Delete.
10614 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
10615 (gdb_fopen, tee_file_new): Delete.
10616 (struct string_file): New.
10617 (struct stdio_file): New.
10618 (stdio_file_up): New.
10619 (struct stderr_file): New.
10620 (class tee_file): New.
10621 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
10622 of a 'ui_file *'. Adjust.
10623 * ui-out.h (class ui_out) <field_stream>: Likewise.
10624 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
10625 (null_stream): Delete.
10626 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
10627 Adjust.
10628 * utils.h (struct ui_file): Delete forward declaration..
10629 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
10630 (error_stream): Take a 'string_file &' instead of a
10631 'ui_file *'.
10632 * varobj.c (varobj_value_get_print_value): Use string_file.
10633 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
10634 * gdbarch.c: Regenerate.
10635
187808b0
PA
106362017-02-02 Pedro Alves <palves@redhat.com>
10637
10638 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
10639 (gdb_pretty_print_insn): ... this. Now a free function. Add back
10640 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
10641 Adjust to call gdb_print_insn instead of
10642 gdb_disassembler::print_insn.
10643 (dump_insns, do_mixed_source_and_assembly_deprecated)
10644 (do_mixed_source_and_assembly, do_assembly_only): Add back a
10645 'gdbarch' parameter. Remove gdb_disassembler parameter.
10646 (gdb_disassembly): Don't allocate a gdb_disassembler here.
10647 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
10648 declaration.
10649 (gdb_pretty_print_insn): Re-add declaration.
10650 * record-btrace.c (btrace_insn_history): Don't allocate a
10651 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
10652
7a8eb317
SM
106532017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
10654
10655 * disasm.h (gdb_disassembly): Remove file_string parameter.
10656 * disasm.c (gdb_disassembly): Likewise.
10657 * cli/cli-cmds.c (print_disassembly): Adapt.
10658 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
10659 * stack.c (do_gdb_disassembly): Likewise.
10660
7346ef59
AA
106612017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
10662
10663 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
10664 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
10665 targets. And if the implicit value is longer than needed, extract
10666 the first bytes instead of the "least significant" ones.
10667
cd4007e4
MM
106682017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10669
10670 * btrace.c (btrace_enable): Do not call btrace_add_pc for
10671 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
10672 (btrace_fetch): Assert can_access_registers_ptid.
10673 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
10674 validate_registers_access.
10675
cf77c34e
MM
106762017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10677
10678 * gdbthread.h (can_access_registers_ptid): New.
10679 * thread.c (can_access_registers_ptid): New.
10680
be85ce7d
PA
106812017-02-01 Pedro Alves <palves@redhat.com>
10682
10683 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
10684
29b0b251
PA
106852017-01-31 Pedro Alves <palves@redhat.com>
10686
10687 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
10688 Fix typos.
10689
289b5b24
PA
106902017-01-31 Pedro Alves <palves@redhat.com>
10691
10692 * stack.c (print_frame_args): Remove local mem_fileopen stream,
10693 not used.
10694
b47413b4
PA
106952017-01-31 Pedro Alves <palves@redhat.com>
10696
10697 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
10698
60adb36c
PA
106992017-01-31 Pedro Alves <palves@redhat.com>
10700
10701 * common/scoped_restore.h
10702 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
10703 change the value's parameter type to T2.
10704 (make_scoped_restore): Likewise.
10705
2735833d
WT
107062017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10707 Richard Henderson <rth@redhat.com>
10708
10709 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
10710 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
10711 GS_BASE for older kernels.
10712 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
10713 GS_BASE for older kernels.
10714 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
10715 and GS_BASE to the offset table.
10716 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
10717 system register group.
10718 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
10719 for older kernels.
10720 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
10721 amd64 ABI.
10722 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
10723 AMD64_GSBASE_REGNUM.
10724 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
10725 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
10726 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
10727 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
10728 i386/64bit-segments.xml in those rules.
10729 * features/i386/64bit-segments.xml: New file.
10730 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
10731 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
10732 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
10733 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
10734 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
10735 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
10736 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
10737 * features/i386/amd64-avx-linux.c: Regenerated.
10738 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
10739 * features/i386/amd64-avx-mpx.c: Regenerated.
10740 * features/i386/amd64-avx512-linux.c: Regenerated.
10741 * features/i386/amd64-linux.c: Regenerated.
10742 * features/i386/amd64-mpx-linux.c: Regenerated.
10743 * features/i386/i386-avx-mpx-linux.c: Regenerated.
10744 * features/i386/i386-avx-mpx.c: Regenerated.
10745 * features/i386/x32-avx-linux.c: Regenerated.
10746 * features/i386/x32-avx512-linux.c: Regenerated.
10747 * regformats/i386/amd64-avx-linux.dat: Regenerated.
10748 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
10749 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
10750 * regformats/i386/amd64-linux.dat: Regenerated.
10751 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
10752 * regformats/i386/x32-avx-linux.dat: Regenerated.
10753 * regformats/i386/x32-avx512-linux.dat: Regenerated.
10754 * regformats/i386/x32-linux.dat: Regenerated.
10755
8884e97e
WT
107562017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10757
10758 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
10759 Set to AMD64_NUM_REGS.
10760
7005d26a
WT
107612017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10762
10763 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
10764 that checks validity of a register number.
10765
4bd2e1b2
KC
107662017-01-27 Kees Cook <keescook@google.com>
10767
10768 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
10769 fetch_fpregs if target has fpa registers.
10770 (arm_linux_store_inferior_registers): Call store_fpregs if target
10771 has fpa registers.
10772
7cf1de6c
AA
107732017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
10774
10775 * cris-tdep.c (cris_gdbarch_init): Remove check for
10776 info.byte_order and force it to BFD_ENDIAN_LITTLE.
10777
874a1c8c
AT
107782017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
10779
10780 * corelow.c (get_core_register_section): Check for regset
10781 existence before checking for REGSET_VARIABLE_SIZE.
10782
d8b49cf0
YQ
107832017-01-26 Yao Qi <yao.qi@linaro.org>
10784 Pedro Alves <palves@redhat.com>
10785
10786 PR gdb/20939
10787 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
10788 call memory_error, save memaddr instead.
10789 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
10790 negative, cal memory_error.
10791 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
10792
658ca58c
YQ
107932017-01-26 Yao Qi <yao.qi@linaro.org>
10794
10795 * disasm-selftests.c (memory_error_test): New function.
10796 (_initialize_disasm_selftests): Register memory_error_test.
10797
79843d45
YQ
107982017-01-26 Yao Qi <yao.qi@linaro.org>
10799
10800 * Makefile.in (SFILES): Add disasm-selftests.c and
10801 selftest-arch.c.
10802 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
10803 * disasm-selftests.c: New file.
10804 * selftest-arch.c: New file.
10805 * selftest-arch.h: New file.
10806
8cafda32
YQ
108072017-01-26 Yao Qi <yao.qi@linaro.org>
10808
10809 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
10810 to bfd_arch_mep. Don't return 0 if section is not
10811 found. Call print_insn_mep.
10812
e47ad6c0
YQ
108132017-01-26 Pedro Alves <palves@redhat.com>
10814 Yao Qi <yao.qi@linaro.org>
10815
10816 * arm-tdep.c: Include "disasm.h".
10817 (gdb_print_insn_arm): Update code to get gdbarch.
10818 * disasm.c (dis_asm_read_memory): Change it to
10819 gdb_disassembler::dis_asm_read_memory.
10820 (dis_asm_memory_error): Likewise.
10821 (dis_asm_print_address): Likewise.
10822 (gdb_pretty_print_insn): Change it to
10823 gdb_disassembler::pretty_print_insn.
10824 (dump_insns): Add one argument gdb_disassemlber. All
10825 callers updated.
10826 (do_mixed_source_and_assembly_deprecated): Likewise.
10827 (do_mixed_source_and_assembly): Likewise.
10828 (do_assembly_only): Likewise.
10829 (gdb_disassembler::gdb_disassembler): New.
10830 (gdb_disassembler::print_insn): New.
10831 * disasm.h (class gdb_disassembler): New.
10832 (gdb_pretty_print_insn): Remove declaration.
10833 (gdb_disassemble_info): Likewise.
10834 * guile/scm-disasm.c (class gdbscm_disassembler): New.
10835 (gdbscm_disasm_read_memory_worker): Update.
10836 (gdbscm_disasm_read_memory): Update.
10837 (gdbscm_disasm_memory_error): Remove.
10838 (gdbscm_disasm_print_address): Remove.
10839 (gdbscm_disassembler::gdbscm_disassembler): New.
10840 (gdbscm_print_insn_from_port): Update.
10841 * mips-tdep.c: Include disasm.h.
10842 (gdb_print_insn_mips): Update code to get gdbarch.
10843 * record-btrace.c (btrace_insn_history): Update.
10844 * spu-tdep.c: Include disasm.h.
10845 (struct spu_dis_asm_data): Remove.
10846 (struct spu_dis_asm_info): New.
10847 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
10848 SPU id.
10849 (gdb_print_insn_spu): Cast disassemble_info to
10850 spu_dis_asm_info.
10851
80d75874
YQ
108522017-01-26 Yao Qi <yao.qi@linaro.org>
10853
10854 * disasm.c (do_ui_file_delete): Delete.
10855 (gdb_insn_length): Move code creating stream to ...
10856 * utils.c (null_stream): ... here. New function.
10857 * utils.h (null_stream): Declare.
10858
60685cd0
SM
108592017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10860
10861 * python/py-inferior.c (find_thread_object): Return directly
10862 from the loop. Remove "found" variable.
10863
eb1cdb62
JB
108642017-01-21 Joel Brobecker <brobecker@adacore.com>
10865
10866 GDB 7.12.1 released.
10867
b1ce6568
SM
108682017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10869
10870 * python/py-function.c (fnpy_call): Reorder declarations to have
10871 the gdbpy_enter object declared first.
10872 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
10873
6f8b0407
SM
108742017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10875
fec93fb1 10876 PR python/21068
6f8b0407
SM
10877 * python/python-internal.h (PyMem_RawMalloc): Define for
10878 Python < 3.4.
10879 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
10880 PyMem_RawMalloc instead of PyMem_Malloc.
10881
78cbbba8
LM
108822017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
10883 Luis Machado <lgustavo@codesourcery.com>
10884
10885 * NEWS (New commands): Mention flash-erase.
10886 (New MI commands): Mention target-flash-erase.
10887 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
10888 command.
10889 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
10890 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
10891 * target.c (flash_erase_command): New function.
10892 (initialize_targets): Add new flash-erase command.
10893 * target.h (flash_erase_command): New declaration.
10894
2132fe85
JB
108952017-01-20 Joel Brobecker <brobecker@adacore.com>
10896
10897 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
10898 HAVE_SYS_PROCFS_H is defined.
10899
d1dff226
AH
109002017-01-18 Alan Hayward <alan.hayward@arm.com>
10901
10902 * remote.c (struct cached_reg): Change data into a pointer.
10903 * (stop_reply_dtr): Free data pointers before deleting vector.
10904 (process_stop_reply): Likewise.
10905 (remote_parse_stop_reply): Allocate space for data
10906
9890e433
AH
109072017-01-18 Alan Hayward <alan.hayward@arm.com>
10908
10909 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
10910 MAX_REGISTER_SIZE.
10911 (amd64_pseudo_register_read_value): Likewise.
10912 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
10913 (store_register_using_P): Likewise.
10914 * regcache.c (regcache_xfer_part): Likewise.
10915
7a36499a
IR
109162017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
10917
10918 Split real and pseudo registers.
10919 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
10920 (sparc32_pseudo_regnum): New enum.
10921 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
10922 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
10923 (SPARC32_CP0_REGISTERS): New macro.
10924 (sparc32_pseudo_register_name): New function.
10925 (sparc32_register_name): Use sparc32_pseudo_register_name.
10926 (sparc32_pseudo_register_type): New function.
10927 (sparc32_register_type): Use sparc32_pseudo_register_type.
10928 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
10929 pseudo register numbers.
10930 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
10931 (SPARC64_CP0_REGISTERS): New macro.
10932 (sparc64_pseudo_register_name): New function.
10933 (sparc64_register_name): Use sparc64_pseudo_register_name.
10934 (sparc64_pseudo_register_type): New function.
10935 (sparc64_register_type): Use sparc64_pseudo_register_type.
10936 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
10937 pseudo register numbers.
10938 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
10939 sparc64_store_arguments): Handle pseudo register numbers.
10940
6f8976bf
YQ
109412017-01-13 Yao Qi <yao.qi@linaro.org>
10942
10943 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
10944 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
10945 output.
10946 (getpkt_or_notif_sane_1): Likewise.
10947
e4241ace
YQ
109482017-01-13 Yao Qi <yao.qi@linaro.org>
10949
10950 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
10951 of CC. Pass "-x c++-header" instead of "-x c".
10952
3015c064
SM
109532017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10954
10955 * remote.c (remote_can_async_p): Update comment.
10956
fde1b17d
SM
109572017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10958
10959 * linux-nat.c (linux_nat_can_async_p): Update comment.
10960
ca1ca08b
SM
109612017-01-12 Simon Marchi <simon.marchi@ericsson.com>
10962
10963 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
10964
4ad2da73
SM
109652017-01-11 Simon Marchi <simon.marchi@ericsson.com>
10966
10967 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
10968
c8b23b3f
TT
109692017-01-10 Tom Tromey <tom@tromey.com>
10970
10971 * python/py-type.c (typy_legacy_template_argument): Update.
10972 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
10973 ~demangle_parse_info): Declare new members.
10974 (cp_demangled_name_to_comp): Return unique_ptr.
10975 (cp_demangled_name_parse_free)
10976 (make_cleanup_cp_demangled_name_parse_free)
10977 (cp_new_demangle_parse_info): Remove.
10978 * cp-support.c (do_demangled_name_parse_free_cleanup)
10979 (make_cleanup_cp_demangled_name_parse_free): Remove.
10980 (inspect_type, cp_canonicalize_string_full)
10981 (cp_canonicalize_string): Update.
10982 (mangled_name_to_comp): Change return type.
10983 (cp_class_name_from_physname, method_name_from_physname)
10984 (cp_func_name, cp_remove_params): Update.
10985 * cp-name-parser.y (demangle_parse_info): New constructor, from
10986 cp_new_demangle_parse_info.
10987 (~demangle_parse_info): New destructor, from
10988 cp_demangled_name_parse_free.
10989 (cp_merge_demangle_parse_infos): Update.
10990 (cp_demangled_name_to_comp): Change return type.
10991
1ac32117
TT
109922017-01-10 Tom Tromey <tom@tromey.com>
10993
10994 * top.c (prevent_dont_repeat): Change return type.
10995 * python/python.c (execute_gdb_command): Use std::string.
10996 Update.
10997 * guile/guile.c (gdbscm_execute_gdb_command): Update.
10998 * command.h (prevent_dont_repeat): Change return type.
10999 * breakpoint.c (bpstat_do_actions_1): Update.
11000
0cf08227
TT
110012017-01-10 Tom Tromey <tom@tromey.com>
11002
11003 * value.h (scoped_value_mark::~scoped_value_mark): Call
11004 free_to_mark.
11005 (scoped_value_mark::free_to_mark): New method.
11006 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11007 scoped_value_mark.
11008
eb115069
TT
110092017-01-10 Tom Tromey <tom@tromey.com>
11010
11011 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11012 (valpy_reference_value, valpy_const_value, valpy_get_address)
11013 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11014 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11015 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11016 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11017 scoped_value_mark.
11018 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11019 * value.h (scoped_value_mark): New class.
11020
906768f9
TT
110212017-01-10 Tom Tromey <tom@tromey.com>
11022
11023 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11024 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11025 * psymtab.c (discard_psymtabs_upto): Remove.
11026 (make_cleanup_discard_psymtabs): Remove.
11027 (struct psymtab_state): Remove.
11028
bef155c3
TT
110292017-01-10 Tom Tromey <tom@tromey.com>
11030
11031 * record-full.c (record_full_save_cleanups): Remove.
11032 (record_full_save): Use gdb::unlinker.
11033 * gcore.c (do_bfd_delete_cleanup): Remove.
11034 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11035 cleanups.
11036 * dwarf2read.c (unlink_if_set): Remove.
11037 (write_psymtabs_to_index): Use gdb::unlinker.
11038 * common/gdb_unlinker.h: New file.
11039
192b62ce
TT
110402017-01-10 Tom Tromey <tom@tromey.com>
11041
11042 * windows-tdep.c (windows_xfer_shared_library): Update.
11043 * windows-nat.c (windows_make_so): Update.
11044 * utils.h (make_cleanup_bfd_unref): Remove.
11045 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11046 * symfile.h (symfile_bfd_open)
11047 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11048 * symfile.c (read_symbols, symbol_file_add)
11049 (separate_debug_file_exists): Update.
11050 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11051 (generic_load, reread_symbols): Update.
11052 * symfile-mem.c (symbol_file_add_from_memory): Update.
11053 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11054 (spu_symbol_file_add_from_memory): Update.
11055 * solist.h (struct target_so_ops) <bfd_open>: Return
11056 gdb_bfd_ref_ptr.
11057 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11058 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11059 gdb_bfd_ref_ptr.
11060 (solib_map_sections, reload_shared_libraries_1): Update.
11061 * solib-svr4.c (enable_break): Update.
11062 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11063 * solib-frv.c (enable_break2): Update.
11064 * solib-dsbt.c (enable_break): Update.
11065 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11066 gdb_bfd_ref_ptr.
11067 (darwin_solib_get_all_image_info_addr_at_init): Update.
11068 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11069 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11070 * record-full.c (record_full_save): Update.
11071 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11072 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11073 * minidebug.c (find_separate_debug_file_in_section): Return
11074 gdb_bfd_ref_ptr.
11075 * machoread.c (macho_add_oso_symfile): Change abfd to
11076 gdb_bfd_ref_ptr.
11077 (macho_symfile_read_all_oso): Update.
11078 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11079 (macho_symfile_read): Update.
11080 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11081 (jit_bfd_try_read_symtab): Update.
11082 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11083 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11084 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11085 gdb_bfd_ref_ptr.
11086 (gdb_bfd_ref_policy): New struct.
11087 (gdb_bfd_ref_ptr): New typedef.
11088 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11089 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11090 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11091 gdb_bfd_ref_ptr.
11092 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11093 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11094 (gcore_command): Update.
11095 * exec.c (exec_file_attach): Update.
11096 * elfread.c (elf_symfile_read): Update.
11097 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11098 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11099 (open_and_init_dwo_file): Update.
11100 (open_dwp_file): Return gdb_bfd_ref_ptr.
11101 (open_and_init_dwp_file): Update.
11102 * corelow.c (core_open): Update.
11103 * compile/compile-object-load.c (compile_object_load): Update.
11104 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11105 * coffread.c (coff_symfile_read): Update.
11106 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11107 gdb_bfd_ref_ptr. Rename.
11108 (dump_bfd_file, restore_command): Update.
11109 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11110 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11111 (find_separate_debug_file_by_buildid): Update.
11112
50315b21
TT
111132017-01-10 Tom Tromey <tom@tromey.com>
11114
11115 * common/gdb_ref_ptr.h: New file.
11116 * python/py-ref.h (struct gdbpy_ref_policy): New.
11117 (gdbpy_ref): Now a typedef.
11118
fc4007c9
TT
111192017-01-10 Tom Tromey <tom@tromey.com>
11120
11121 * utils.h (make_cleanup_htab_delete): Don't declare.
11122 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11123 Remove.
11124 * linespec.c (decode_compound_collector): Add constructor,
11125 destructor.
11126 (lookup_prefix_sym): Remove cleanup.
11127 (symtab_collector): Add constructor, destructor.
11128 (collect_symtabs_from_filename): Remove cleanup.
11129 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11130 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11131 Use htab_up.
11132 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11133 * dwarf2read.c (dw2_expand_symtabs_matching)
11134 (dw2_map_symbol_filenames, dwarf_decode_macros)
11135 (write_psymtabs_to_index): Use htab_up.
11136 * dwarf2loc.c (func_verify_no_selftailcall)
11137 (call_site_find_chain_1, func_verify_no_selftailcall)
11138 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11139 std::vector, gdb::unique_xmalloc_ptr.
11140 (call_sitep): Remove typedef.
11141 (dwarf2_locexpr_baton_eval): Remove unused variable.
11142
8dbcee67
TT
111432017-01-10 Tom Tromey <tom@tromey.com>
11144
11145 * python/python-internal.h (make_cleanup_py_decref)
11146 (make_cleanup_py_xdecref): Don't declare.
11147 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11148 (py_xdecref, make_cleanup_py_xdecref): Remove.
11149
13df46cc
TT
111502017-01-10 Tom Tromey <tom@tromey.com>
11151
11152 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11153 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11154
06fc9bf7
TT
111552017-01-10 Tom Tromey <tom@tromey.com>
11156
11157 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11158
830a4934
TT
111592017-01-10 Tom Tromey <tom@tromey.com>
11160
11161 * python/py-utils.c (unicode_to_encoded_string)
11162 (python_string_to_target_string)
11163 (python_string_to_target_python_string)
11164 (python_string_to_host_string, gdbpy_obj_to_string)
11165 (get_addr_from_python): Use gdbpy_ref.
11166
4586d543
TT
111672017-01-10 Tom Tromey <tom@tromey.com>
11168
11169 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11170 gdbpy_ref.
11171
59876f8f
TT
111722017-01-10 Tom Tromey <tom@tromey.com>
11173
11174 * python/python.c (eval_python_command, gdbpy_decode_line)
11175 (gdbpy_run_events, gdbpy_start_type_printers)
11176 (gdbpy_apply_type_printers): Use gdbpy_ref.
11177
97d83487
TT
111782017-01-10 Tom Tromey <tom@tromey.com>
11179
11180 * python/py-param.c (get_doc_string, compute_enum_values): Use
11181 gdbpy_ref.
11182
9205649a
TT
111832017-01-10 Tom Tromey <tom@tromey.com>
11184
11185 * python/py-inferior.c (find_thread_object, build_inferior_list):
11186 Use gdbpy_ref.
11187
74c49d45
TT
111882017-01-10 Tom Tromey <tom@tromey.com>
11189
11190 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11191
16361ffb
TT
111922017-01-10 Tom Tromey <tom@tromey.com>
11193
11194 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11195 gdbpy_ref.
11196
905f2cca
TT
111972017-01-10 Tom Tromey <tom@tromey.com>
11198
11199 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11200 extra incref.
11201 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11202 Use gdbpy_ref.
11203
64081434
TT
112042017-01-10 Tom Tromey <tom@tromey.com>
11205
11206 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11207 gdbpy_ref.
11208
59e9e831
TT
112092017-01-10 Tom Tromey <tom@tromey.com>
11210
11211 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11212 decref results of PyArg_ParseTupleAndKeywords.
11213
9de10f6d
TT
112142017-01-10 Tom Tromey <tom@tromey.com>
11215
11216 * python/python.c (python_run_simple_file): Use
11217 unique_xmalloc_ptr, gdbpy_ref.
11218
2bd5759d
TT
112192017-01-10 Tom Tromey <tom@tromey.com>
11220
11221 * python/py-prettyprint.c (print_stack_unless_memory_error)
11222 (print_string_repr, print_children): Use gdbpy_ref.
11223 (dummy_python_frame): New class.
11224 (dummy_python_frame::dummy_python_frame): Rename from
11225 push_dummy_python_frame.
11226 (py_restore_tstate): Remove.
11227
3b4e0e01
TT
112282017-01-10 Tom Tromey <tom@tromey.com>
11229
11230 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11231
17a22718
TT
112322017-01-10 Tom Tromey <tom@tromey.com>
11233
11234 * python/python.c (ensure_python_env, restore_python_env):
11235 Remove.
11236 * python/python-internal.h (ensure_python_env): Don't declare.
11237 * varobj.h (varobj_ensure_python_env): Don't declare.
11238 * varobj.c (varobj_ensure_python_env): Remove.
11239
68cdc557
TT
112402017-01-10 Tom Tromey <tom@tromey.com>
11241
11242 * varobj.c (varobj_value_get_print_value): Use
11243 gdbpy_enter_varobj.
11244
1eba6383
TT
112452017-01-10 Tom Tromey <tom@tromey.com>
11246
11247 * python/py-prettyprint.c (print_string_repr, print_children):
11248 Update.
11249 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11250 of "encoding".
11251 * varobj.c (varobj_value_get_print_value): Update.
11252 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11253
bde7b3e3
TT
112542017-01-10 Tom Tromey <tom@tromey.com>
11255
11256 * varobj.c (varobj_get_display_hint)
11257 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11258 (varobj_set_visualizer, free_variable): Use
11259 gdbpy_enter_varobj.
11260
a7785f8c
TT
112612017-01-10 Tom Tromey <tom@tromey.com>
11262
11263 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11264 (do_finish_initialization): New function. Use gdbpy_ref.
11265 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11266 do_finish_initialization.
11267
2865bfce
TT
112682017-01-10 Tom Tromey <tom@tromey.com>
11269
11270 * python/py-param.c (get_set_value, get_show_value): Use
11271 gdbpy_enter, gdbpy_ref.
11272
0e9dcc75
TT
112732017-01-10 Tom Tromey <tom@tromey.com>
11274
11275 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11276
12a5cedd
TT
112772017-01-10 Tom Tromey <tom@tromey.com>
11278
11279 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11280
788f2586
TT
112812017-01-10 Tom Tromey <tom@tromey.com>
11282
11283 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11284 Use gdbpy_enter_varobj.
11285
6cd67bea
TT
112862017-01-10 Tom Tromey <tom@tromey.com>
11287
11288 * varobj.c (gdbpy_enter_varobj): New constructor.
11289 * python/python-internal.h (gdbpy_enter_varobj): New class.
11290 * python/py-varobj.c (py_varobj_get_iterator): Use
11291 gdbpy_enter_varobj.
11292
14b122bf
TT
112932017-01-10 Tom Tromey <tom@tromey.com>
11294
11295 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11296 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11297 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11298 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11299 unique_xmalloc_ptr.
11300 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11301
bf1ca3b9
TT
113022017-01-10 Tom Tromey <tom@tromey.com>
11303
11304 * python/py-xmethods.c (invoke_match_method): Use
11305 gdbpy_ref.
11306
572a5524
TT
113072017-01-10 Tom Tromey <tom@tromey.com>
11308
11309 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11310 gdbpy_enter, gdbpy_ref.
11311
396a78b6
TT
113122017-01-10 Tom Tromey <tom@tromey.com>
11313
11314 * python/python.c (python_interactive_command): Use gdbpy_enter.
11315
a88b13c7
TT
113162017-01-10 Tom Tromey <tom@tromey.com>
11317
11318 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11319 gdbpy_ref.
11320
e9f0c363
TT
113212017-01-10 Tom Tromey <tom@tromey.com>
11322
11323 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11324 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11325
6349f452
TT
113262017-01-10 Tom Tromey <tom@tromey.com>
11327
11328 * utils.h (htab_deleter): New struct.
11329 (htab_up): New typedef.
11330 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11331 gdbpy_enter, gdbpy_ref, htab_up.
11332
c0171de6
TT
113332017-01-10 Tom Tromey <tom@tromey.com>
11334
11335 * python/py-unwind.c (pending_frame_invalidate): Remove.
11336 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11337
f18e226f
TT
113382017-01-10 Tom Tromey <tom@tromey.com>
11339
11340 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11341 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11342
c57af3f1
TT
113432017-01-10 Tom Tromey <tom@tromey.com>
11344
11345 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11346
60e600ec
TT
113472017-01-10 Tom Tromey <tom@tromey.com>
11348
11349 * python/python.c (gdbpy_eval_from_control_command)
11350 (gdbpy_source_script, gdbpy_run_events)
11351 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11352 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11353 gdbpy_enter.
11354
bf7da5b0
TT
113552017-01-10 Tom Tromey <tom@tromey.com>
11356
11357 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11358
2d38bced
TT
113592017-01-10 Tom Tromey <tom@tromey.com>
11360
11361 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11362
07bc7329
TT
113632017-01-10 Tom Tromey <tom@tromey.com>
11364
11365 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11366 (python_on_inferior_call_pre, python_on_inferior_call_post)
11367 (python_on_memory_change, python_on_register_change)
11368 (python_inferior_exit, python_new_objfile, add_thread_object)
11369 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11370
6e7c365e
TT
113712017-01-10 Tom Tromey <tom@tromey.com>
11372
11373 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11374 (bpfinishpy_handle_exit): Use gdbpy_enter.
11375
6ba0cd40
TT
113762017-01-10 Tom Tromey <tom@tromey.com>
11377
11378 * python/py-cmd.c (cmdpy_destroyer)
11379 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11380 gdbpy_enter.
11381
de2dc875
TT
113822017-01-10 Tom Tromey <tom@tromey.com>
11383
11384 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11385 gdbpy_enter.
11386 (gdbpy_breakpoint_has_cond): Likewise.
11387
4ecee2c4
TT
113882017-01-10 Tom Tromey <tom@tromey.com>
11389
11390 * python/python.c (gdbpy_enter): New constructor.
11391 (~gdbpy_enter): New destructor.
11392 (restore_python_env, ensure_python_env): Rewrite.
11393 * python/python-internal.h (gdbpy_enter): New class.
11394
37fce74f
TT
113952017-01-10 Tom Tromey <tom@tromey.com>
11396
11397 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11398
53a0cca3
TT
113992017-01-10 Tom Tromey <tom@tromey.com>
11400
11401 * python/py-value.c (value_has_field, get_field_flag)
11402 (get_field_type, valpy_getitem, convert_value_from_python): Use
11403 gdbpy_ref.
11404
ff3724f5
TT
114052017-01-10 Tom Tromey <tom@tromey.com>
11406
11407 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11408 gdbpy_ref.
11409
0700aea5
TT
114102017-01-10 Tom Tromey <tom@tromey.com>
11411
11412 * python/py-prettyprint.c (search_pp_list)
11413 (find_pretty_printer_from_objfiles)
11414 (find_pretty_printer_from_progspace)
11415 (find_pretty_printer_from_gdb, find_pretty_printer)
11416 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11417 gdbpy_ref.
11418
1bb44c9f
TT
114192017-01-10 Tom Tromey <tom@tromey.com>
11420
11421 * python/py-param.c (call_doc_function): Use gdbpy_ref.
11422
87ce03fd
TT
114232017-01-10 Tom Tromey <tom@tromey.com>
11424
11425 * python/py-linetable.c (build_line_table_tuple_from_pcs)
11426 (ltpy_get_all_source_lines): Use gdbpy_ref.
11427
ee0a3fb8
TT
114282017-01-10 Tom Tromey <tom@tromey.com>
11429
11430 * python/py-framefilter.c (extract_sym, extract_value)
11431 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
11432 gdbpy_ref.
11433
bf2a52fa
TT
114342017-01-10 Tom Tromey <tom@tromey.com>
11435
11436 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
11437
f59fe7f8
TT
114382017-01-10 Tom Tromey <tom@tromey.com>
11439
11440 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
11441
80bd970a
TT
114422017-01-10 Tom Tromey <tom@tromey.com>
11443
11444 * python/py-function.c (convert_values_to_python, fnpy_init): Use
11445 gdbpy_ref.
11446
d1b3de2e
TT
114472017-01-10 Tom Tromey <tom@tromey.com>
11448
11449 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
11450
3bb43384
TT
114512017-01-10 Tom Tromey <tom@tromey.com>
11452
11453 * python/py-type.c (convert_field, make_fielditem, typy_fields)
11454 (typy_range): Use gdbpy_ref.
11455
abf5651e
TT
114562017-01-10 Tom Tromey <tom@tromey.com>
11457
11458 * python/py-threadevent.c (create_thread_event_object): Use
11459 gdbpy_ref.
11460 * python/py-stopevent.c (create_stop_event_object): Simplify.
11461 (emit_stop_event): Use gdbpy_ref.
11462 * python/py-signalevent.c (create_signal_event_object): Use
11463 gdbpy_ref.
11464 * python/py-newobjfileevent.c (create_new_objfile_event_object)
11465 (emit_new_objfile_event, create_clear_objfiles_event_object)
11466 (emit_clear_objfiles_event): Use gdbpy_ref.
11467 * python/py-infevents.c (create_inferior_call_event_object)
11468 (create_register_changed_event_object)
11469 (create_memory_changed_event_object, emit_inferior_call_event)
11470 (emit_memory_changed_event, emit_register_changed_event): Use
11471 gdbpy_ref.
11472 * python/py-exitedevent.c (create_exited_event_object)
11473 (emit_exited_event): Use gdbpy_ref.
11474 * python/py-event.h (evpy_emit_event): Remove
11475 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
11476 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
11477 * python/py-continueevent.c (emit_continue_event): Use
11478 gdbpy_ref.
11479 * python/py-breakpoint.c (gdbpy_breakpoint_created)
11480 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
11481 gdbpy_ref.
11482 * python/py-bpevent.c (create_breakpoint_event_object): Use
11483 gdbpy_ref.
11484
a68ff33e
TT
114852017-01-10 Tom Tromey <tom@tromey.com>
11486
11487 * python/py-ref.h: New file.
11488
7becfd03
SM
114892017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11490
11491 * cli-out.c (cli_ui_out::do_redirect): Change return type to
11492 void.
11493 * cli-out.h (cli_ui_out::do_redirect): Likewise.
11494 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
11495 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
11496 * ui-out.c (ui_out::redirect): Likewise.
11497 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
11498 * cli/cli-logging.c (set_logging_redirect): Update call site of
11499 ui_out::redirect.
11500 (handle_redirections): Likewise.
11501 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
11502 * top.c (execute_command_to_string): Likewise.
11503 * utils.c (do_ui_out_redirect_pop): Likewise.
11504
df294654
SM
115052017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11506
11507 * stack.c (_initialize_stack): Update "frame" command help message.
11508
f5e6296e
IB
115092017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
11510
11511 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
11512
0e2d6fa6
YQ
115132017-01-06 Yao Qi <yao.qi@linaro.org>
11514
11515 * x86-linux-nat.h: Include gdb_proc_service.h.
11516
44d6d3f9
YQ
115172017-01-06 Yao Qi <yao.qi@linaro.org>
11518
11519 * ser-base.h: Include serial.h.
11520
656731fe
YQ
115212017-01-06 Yao Qi <yao.qi@linaro.org>
11522
11523 * ppc-linux-tdep.h: Include ppc-tdep.h.
11524
1ca8f924
YQ
115252017-01-06 Yao Qi <yao.qi@linaro.org>
11526
11527 * nat/amd64-linux-siginfo.h: Include signal.h.
11528
bc3008c4
YQ
115292017-01-06 Yao Qi <yao.qi@linaro.org>
11530
11531 * nat/aarch64-linux-hw-point.h: Include break-common.h.
11532
66c80d03
YQ
115332017-01-06 Yao Qi <yao.qi@linaro.org>
11534
11535 * mi/mi-parse.h: Include mi-cmds.h.
11536
051d2dda
YQ
115372017-01-06 Yao Qi <yao.qi@linaro.org>
11538
11539 * inf-loop.c: Don't include "target.h".
11540 * inf-loop.h: Include it here.
11541
8018d34f
YQ
115422017-01-06 Yao Qi <yao.qi@linaro.org>
11543
11544 * dfp.h: Include "dboulest.h" and "expression.h".
11545
c0b8369c
YQ
115462017-01-06 Yao Qi <yao.qi@linaro.org>
11547
11548 * ax-gdb.h: Include "ax.h".
11549
ad5cba2a
YQ
115502017-01-06 Yao Qi <yao.qi@linaro.org>
11551
11552 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
11553 with nat/gdb_ptrace.h.
11554
1c33cd7f
YQ
115552017-01-05 Yao Qi <yao.qi@linaro.org>
11556
11557 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
11558 new line.
11559 (mips64_fbsd_sigframe_init): Likewise.
11560
c988ac1d
JB
115612017-01-04 John Baldwin <jhb@FreeBSD.org>
11562
11563 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
11564 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
11565
b268007c
JB
115662017-01-04 John Baldwin <jhb@FreeBSD.org>
11567
11568 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
11569 * NEWS: Mention new FreeBSD/mips native configuration.
11570 * config/mips/fbsd.mh: New file.
11571 * configure.host: Add mips*-*-freebsd*.
11572 * mips-fbsd-nat.c: New file.
11573
387360da
JB
115742017-01-04 John Baldwin <jhb@FreeBSD.org>
11575
11576 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
11577 (ALLDEPFILES): Add mips-fbsd-tdep.c.
11578 * NEWS: Mention new FreeBSD/mips target.
11579 * configure.tgt: Add mips*-*-freebsd*.
11580 * mips-fbsd-tdep.c: New file.
11581 * mips-fbsd-tdep.h: New file.
11582
2aaaf250
YQ
115832017-01-04 Yao Qi <yao.qi@linaro.org>
11584
11585 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
11586 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
11587
61baf725
JB
115882017-01-01 Joel Brobecker <brobecker@adacore.com>
11589
6dbb839a 11590 Update copyright year range in all GDB files.
61baf725 11591
c113e7ff 115922017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 11593
c113e7ff 11594 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 11595
c113e7ff 11596For older changes see ChangeLog-2016.
c906108c
SS
11597\f
11598Local Variables:
11599mode: change-log
11600left-margin: 8
11601fill-column: 74
11602version-control: never
57da7796 11603coding: utf-8
c906108c 11604End:
This page took 2.529794 seconds and 4 git commands to generate.