Free results of varobj_get_type and type_to_string
[external/binutils.git] / gdb / ChangeLog
1 2015-01-30  Simon Marchi  <simon.marchi@ericsson.com>
2
3         * mi/mi-cmd-var.c (mi_cmd_var_info_type): Free result of
4         varobj_get_type.
5         (varobj_update_one): Same.
6         * varobj.c (update_type_if_necessary): Free curr_type_str and
7         new_type_str.
8         (varobj_get_type): Specify in comment that the result needs to be
9         freed by the caller.
10
11 2015-01-29  Doug Evans  <dje@google.com>
12
13         PR symtab/17890
14         * dwarf2read.c (dwarf_decode_line_header): Punt if version > 4.
15
16 2015-01-25  Mark Wielaard  <mjw@redhat.com>
17
18         * dwarf2read.c (checkproducer): Call producer_is_gcc.
19         * utils.c (producer_is_gcc_ge_4): Likewise.
20         (producer_is_gcc): New function.
21         * utils.h (producer_is_gcc): New declaration.
22
23 2015-01-29  Joel Brobecker  <brobecker@adacore.com>
24
25         * gdbtypes.h (struct dynamic_prop): New PROP_ADDR_OFFSET enum
26         kind.
27         * gdbtypes.c (resolve_dynamic_type_internal): Replace "addr"
28         parameter by "addr_stack" parameter.
29         (resolve_dynamic_range): Replace "addr" parameter by
30         "stack_addr" parameter.  Update function documentation.
31         Update code accordingly.
32         (resolve_dynamic_array, resolve_dynamic_union)
33         (resolve_dynamic_struct, resolve_dynamic_type_internal): Likewise.
34         (resolve_dynamic_type): Update code, following the changes made
35         to resolve_dynamic_type_internal's interface.
36         * dwarf2loc.h (struct property_addr_info): New.
37         (dwarf2_evaluate_property): Replace "address" parameter
38         by "addr_stack" parameter.  Adjust function documentation.
39         (struct dwarf2_offset_baton): New.
40         (struct dwarf2_property_baton): Update documentation of
41         field "referenced_type" to be more general. New field
42         "offset_info" in union data field.
43         * dwarf2loc.c (dwarf2_evaluate_property): Replace "address"
44         parameter by "addr_stack" parameter.  Adjust code accordingly.
45         Add support for PROP_ADDR_OFFSET properties.
46         * dwarf2read.c (attr_to_dynamic_prop): Add support for
47         DW_AT_data_member_location attributes as well.  Use case
48         statements instead of if/else condition.
49
50 2015-01-29  Joel Brobecker  <brobecker@adacore.com>
51
52         * ada-varobj.c (ada_varobj_get_array_number_of_children):
53         Return zero if PARENT_VALUE is NULL and parent_type's
54         range type is dynamic.
55
56 2015-01-29  Joel Brobecker  <brobecker@adacore.com>
57
58         * gdbtypes.c (is_dynamic_type_internal) <TYPE_CODE_RANGE>: Return
59         nonzero if the type's subtype is dynamic.
60         (resolve_dynamic_range): Also resolve the range's subtype.
61
62 2015-01-29  Alexander Klimov  <alserkli@inbox.ru>  (tiny patch)
63
64         Pushed by Joel Brobecker  <brobecker@adacore.com>.
65         * symfile.c (unmap_overlay_command): Initialize sec to NULL.
66
67 2015-01-27  Doug Evans  <dje@google.com>
68
69         * NEWS: Mention gdb.Objfile.username.
70         * python/py-objfile.c (objfpy_get_username): New function.
71         (objfile_getset): Add "username".
72
73 2015-01-24  Mark Wielaard  <mjw@redhat.com>
74
75         * stack.c (return_command): Markup warning message with _.
76
77 2015-01-24  Doug Evans  <xdje42@gmail.com>
78
79         * gdbtypes.h (TYPE_TYPE_SPECIFIC): Delete.
80
81 2015-01-24  Jan Kratochvil  <jan.kratochvil@redhat.com>
82
83         Fix 100x slowdown regression on DWZ files.
84         * dwarf2read.c (struct dwarf2_per_objfile): Add line_header_hash.
85         (struct line_header): Add offset and offset_in_dwz.
86         (dwarf_decode_lines): Add parameter decode_mapping to the declaration.
87         (free_line_header_voidp): New declaration.
88         (line_header_hash, line_header_hash_voidp, line_header_eq_voidp): New
89         functions.
90         (dwarf2_build_include_psymtabs): Update dwarf_decode_lines caller.
91         (handle_DW_AT_stmt_list): Use line_header_hash.
92         (free_line_header_voidp): New function.
93         (dwarf_decode_line_header): Initialize offset and offset_in_dwz.
94         (dwarf_decode_lines): New parameter decode_mapping, use it.
95         (dwarf2_free_objfile): Free line_header_hash.
96
97 2015-01-23  Simon Marchi  <simon.marchi@ericsson.com>
98
99         PR gdb/17416
100         * valops.c (value_rtti_indirect_type): Catch exception thrown by
101         value_ind.
102
103 2015-01-15  Mark Wielaard  <mjw@redhat.com>
104
105         * dwarf2read.c (read_subroutine_type): Set TYPE_NO_RETURN from
106         DW_AT_noreturn.
107         * gdbtypes.h (struct func_type): Add is_noreturn field flag. Make
108         calling_convention an 8 bit bit field.
109         (TYPE_NO_RETURN): New macro.
110         * infcmd.c (finish_command): Query if function does not return
111         normally.
112         * stack.c (return_command): Likewise.
113
114 2015-01-23  Pedro Alves  <palves@redhat.com>
115
116         * linux-nat.c (linux_is_async_p): New macro.
117         (linux_nat_is_async_p):
118         (linux_nat_terminal_inferior): Check whether the target can async
119         instead of whether it is already async.
120         (linux_nat_terminal_ours): Don't check whether the target is
121         async.
122         (linux_async_pipe): Use linux_is_async_p.
123
124 2015-01-22  Jan Kratochvil  <jan.kratochvil@redhat.com>
125
126         * NEWS (Changes since GDB 7.9): Add 'thread apply all' option
127         '-ascending'.
128         * thread.c (tp_array_compar_ascending, tp_array_compar): New.
129         (thread_apply_all_command): Parse CMD for tp_array_compar_ascending.
130         Sort tp_array using tp_array_compar.
131         (_initialize_thread): Extend thread_apply_all_command help.
132
133 2015-01-22  Jan Kratochvil  <jan.kratochvil@redhat.com>
134
135         * corelow.c (core_open): Call also thread_command.
136         * gdbthread.h (thread_command): New prototype moved from ...
137         * thread.c (thread_command): ... here.
138         (thread_command): Make it global.
139
140 2015-01-22  Pedro Alves  <palves@redhat.com>
141
142         * configure.ac [*mingw32*]: Check $curses_found instead of
143         $prefer_curses.
144         * configure: Regenerate.
145         * windows-termcap.c: Remove HAVE_CURSES_H, HAVE_NCURSES_H and
146         HAVE_NCURSES_NCURSES_H checks.
147
148 2015-01-22  Eli Zaretskii  <eliz@gnu.org>
149
150         * tui/tui.c (tui_enable) [__MINGW32__]: If the call to 'newterm'
151         fails with the 1st arg NULL, try again with "unknown".  Don't test
152         the "cup" capability: it isn't supported by the Windows port of
153         ncurses, but the Windows console driver is still capable of
154         supporting TUI.
155
156 2015-01-22  Jan Kratochvil  <jan.kratochvil@redhat.com>
157
158         * compile/compile.c (_initialize_compile): Use -fPIE for compile_args.
159
160 2015-01-22  Eli Zaretskii  <eliz@gnu.org>
161
162         * Makefile.in (HFILES_NO_SRCDIR): Remove ada-varobj.h.
163         (ALLDEPFILES): Remove irix5-nat.c.  These two are part of the
164         reason that "make TAGS" is broken.
165
166 2015-01-22  Chen Gang  <gang.chen.5i5j@gmail.com>
167
168         * hppa-tdep.c (inst_saves_gr): Fix logical working flow issues
169         and check additional store instructions.
170
171 2015-01-21  Wei-cheng Wang  <cole945@gmail.com>
172
173         * MAINTAINERS (Write After Approval): Add "Wei-cheng Wang".
174
175 2015-01-21  Wei-cheng Wang  <cole945@gmail.com>
176
177         * ppc-linux-tdep.c (ppc_skip_trampoline_code,
178         ppc_canonicalize_syscall, ppc_linux_syscall_record,
179         ppc_linux_record_signal, ppc_init_linux_record_tdep): Add comments.
180         * ppc64-tdep.c (ppc64_skip_trampoline_code): Likewise.
181         * rs6000-tdep.c (rs6000_epilogue_frame_cache,
182         rs6000_epilogue_frame_this_id, rs6000_epilogue_frame_prev_register,
183         rs6000_epilogue_frame_sniffer, ppc_record_vsr, ppc_process_record_op4,
184         ppc_process_record_op19, ppc_process_record_op31,
185         ppc_process_record_op59, ppc_process_record_op60,
186         ppc_process_record_op63): Likewise.
187
188 2015-01-20  Joel Brobecker  <brobecker@adacore.com>
189
190         * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason_string)
191         (linux_ptrace_test_ret_to_nx): Use safe_strerror instead of
192         strerror.
193
194 2015-01-20  Wei-cheng Wang  <cole945@gmail.com>
195
196         * rs6000-tdep.c (ppc_process_record_op4, ppc_process_record_op19,
197         ppc_process_record_op31, ppc_process_record_op59,
198         ppc_process_record_op60, ppc_process_record_op63,
199         ppc_process_record): Fix -Wformat warning.
200         * rs6000-tdep.c (rs6000_epilogue_frame_cache, ppc_process_record_op60):
201         Remove unused variables.
202
203 2015-01-20  Chen Gang  <gang.chen.5i5j@gmail.com>
204
205         * MAINTAINERS (Write After Approval): Add "Chen Gang".
206
207 2015-01-19  Eli Zaretskii  <eliz@gnu.org>
208
209         * configure.ac [*mingw32*]: Only add windows-termcap.o to
210         CONFIG_OBS if not building with a curses library.
211         * configure: Regenerate.
212
213         * windows-termcap.c: Include defs.h.  Make the whole body empty if
214         either one of HAVE_CURSES_H or HAVE_NCURSES_H or
215         HAVE_NCURSES_NCURSES_H is defined.
216
217 2015-01-19  Joel Brobecker  <brobecker@adacore.com>
218
219         * rs6000-tdep.c (rs6000_gdbarch_init): Move divide operator
220         from end of line to start of next line.
221
222 2015-01-17  Wei-cheng Wang  <cole945@gmail.com>
223
224         * ppc-linux-tdep.c (ppc_skip_trampoline_code):
225         Scan PLT stub backward for reverse debugging.
226         * ppc64-tdep.c (ppc64_skip_trampoline_code): Likewise.
227
228 2015-01-17  Wei-cheng Wang  <cole945@gmail.com>
229             Ulrich Weigand  <uweigand@de.ibm.com>
230
231         * configure.tgt (powerpc*-*-linux): Add linux-record.o to
232         gdb_target_obs.
233         (ppc_linux_record_tdep, ppc64_linux_record_tdep): New for linux syscall
234         record.
235         (ppc_canonicalize_syscall, ppc_linux_syscall_record,
236         ppc_linux_record_signal, ppc_init_linux_record_tdep): New functions.
237         (ppc_linux_init_abi): Set process_record, process_record_signal.
238         * ppc-tdep.h (struct gdbarch_tdep): Add ppc_syscall_record and
239         ppc_linux_record_tdep to gdbarch_tdep.
240         (ppc_process_record): New declaration.
241         * rs6000-tdep.c (ppc_record_vsr, ppc_process_record_op4,
242         ppc_process_record_op19, ppc_process_record_op31,
243         ppc_process_record_op59, ppc_process_record_op60,
244         ppc_process_record_op63, ppc_process_record): New functions.
245
246 2015-01-17  Wei-cheng Wang  <cole945@gmail.com>
247
248         * rs6000-tdep.c (rs6000_in_function_epilogue_p): Rename to
249         rs6000_in_function_epilogue_frame_p and add an argument
250         for frame_info.
251         (rs6000_epilogue_frame_cache, rs6000_epilogue_frame_this_id,
252         rs6000_epilogue_frame_prev_register, rs6000_epilogue_frame_sniffer):
253         New functions.
254         (rs6000_epilogue_frame_unwind): New.
255         (rs6000_gdbarch_init): Append epilogue unwinder.
256
257 2015-01-16  Sergio Durigan Junior  <sergiodj@redhat.com>
258
259         * nat/linux-personality.c: Replace "#ifndef
260         HAVE_DECL_ADDR_NO_RANDOMIZE" by "#if
261         !HAVE_DECL_ADDR_NO_RANDOMIZE", fixing a regression in RHEL-5
262         systems.
263
264 2015-01-16  Eli Zaretskii  <eliz@gnu.org>
265
266         * tui/tui-win.c (tui_rehighlight_all, tui_set_var_cmd): New
267         functions.
268         (_initialize_tui_win) <border-kind, border-mode>:
269         <active-border-mode>: Use tui_set_var_cmd as the "set" function.
270         (tui_set_tab_width_command): Fix the commentary.
271
272         * tui/tui-win.h: Add prototype for tui_rehighlight_all.
273
274         * tui/tui-win.c (tui_scroll_left_command, tui_scroll_right_command):
275         Doc fix.
276         (tui_set_tab_width_command): Delete and recreate the source and
277         the disassembly windows, to show the effect of the changed tab
278         size immediately.
279
280         * tui/tui-data.h (LINE_PREFIX): Make shorter
281         (MAX_PID_WIDTH): Enlarge from 14 to 19, to leave enough space for
282         "Thread NNNNN.XXXX" thread ID notation on Windows.
283
284 2015-01-16  Jan Kratochvil  <jan.kratochvil@redhat.com>
285
286         Fix gcc-5 compilation.
287         * hppa-tdep.c (inst_saves_gr): Fix parentheses typo.
288
289 2015-01-15  Sergio Durigan Junior  <sergiodj@redhat.com>
290
291         * Makefile.in (HFILES_NO_SRCDIR): Add nat/linux-personality.h.
292         (linux-personality.o): New rule.
293         * common/common-defs.h: Include <stdint.h>.
294         * config/aarch64/linux.mh (NATDEPFILES): Include
295         linux-personality.o.
296         * config/alpha/alpha-linux.mh (NATDEPFILES): Likewise.
297         * config/arm/linux.mh (NATDEPFILES): Likewise.
298         * config/i386/linux64.mh (NATDEPFILES): Likewise.
299         * config/i386/linux.mh (NATDEPFILES): Likewise.
300         * config/ia64/linux.mh (NATDEPFILES): Likewise.
301         * config/m32r/linux.mh (NATDEPFILES): Likewise.
302         * config/m68k/linux.mh (NATDEPFILES): Likewise.
303         * config/mips/linux.mh (NATDEPFILES): Likewise.
304         * config/pa/linux.mh (NATDEPFILES): Likewise.
305         * config/powerpc/linux.mh (NATDEPFILES): Likewise.
306         * config/powerpc/ppc64-linux.mh (NATDEPFILES): Likewise.
307         * config/powerpc/spu-linux.mh (NATDEPFILES): Likewise.
308         * config/s390/linux.mh (NATDEPFILES): Likewise.
309         * config/sparc/linux64.mh (NATDEPFILES): Likewise.
310         * config/sparc/linux.mh (NATDEPFILES): Likewise.
311         * config/tilegx/linux.mh (NATDEPFILES): Likewise.
312         * config/xtensa/linux.mh (NATDEPFILES): Likewise.
313         * defs.h: Remove #include <stdint.h> (moved to
314         common/common-defs.h).
315         * linux-nat.c: Include nat/linux-personality.h.  Remove #include
316         <sys/personality.h>; do not define ADDR_NO_RANDOMIZE (moved to
317         nat/linux-personality.c).
318         (linux_nat_create_inferior): Remove code to disable address space
319         randomization (moved to nat/linux-personality.c).  Create cleanup
320         to disable address space randomization.
321         * nat/linux-personality.c: New file.
322         * nat/linux-personality.h: Likewise.
323
324 2015-01-15  Sergio Durigan Junior  <sergiodj@redhat.com>
325
326         * Makefile.in (ALLDEPFILES): Including common/mingw-strerror.c and
327         common/posix-strerror.c.
328         (posix-strerror.o): New rule.
329         (mingw-strerror.o): Likewise.
330         * common/common-utils.h (safe_strerror): Move prototype to here,
331         from utils.h.
332         * common/common.host: New file.
333         * common/mingw-strerror.c: Likewise.
334         * common/posix-strerror.c: Likewise.
335         * configure: Regenerated.
336         * configure.ac: Source common/common.host.  Add variable
337         common_host_obs to gdb_host_obs.
338         * contrib/ari/gdb_ari.sh: Mention gdb/common/mingw-strerror.c and
339         gdb/common/posix-strerror.c when warning about the use of
340         strerror.
341         * mingw-hdep.c (safe_strerror): Remove definition; move it to
342         common/mingw-strerror.c.
343         * posix-hdep.c (safe_strerror): Remove definition; move it to
344         common/posix-hdep.c.
345         * utils.h (safe_strerror): Remove prototype; move to
346         common/common-utils.h.
347
348 2015-01-15  Joel Brobecker  <brobecker@adacore.com>
349
350         GDB 7.8.2 released.
351
352 2015-01-15  Joel Brobecker  <brobecker@adacore.com>
353
354         * ada-lang.c (ada_array_bound_from_type): Ignore array's parallel
355         ___XA type if the array has already been fixed.
356
357 2015-01-14  Yao Qi  <yao@codesourcery.com>
358
359         * Makefile.in (ppc-linux.o): New rule.
360         * config/powerpc/ppc64-linux.mh (NATDEPFILES): Add ppc-linux.o.
361         * configure.ac: AC_CHECK_FUNCS(getauxval).
362         * config.in: Re-generated.
363         * configure: Re-generated.
364         * nat/ppc-linux.h [__powerpc64__] (ppc64_64bit_inferior_p):
365         Declare.
366         * nat/ppc-linux.c: New file.
367         * ppc-linux-nat.c (ppc_linux_target_wordsize) [__powerpc64__]:
368         Call ppc64_64bit_inferior_p.
369
370 2015-01-14  Yao Qi  <yao@codesourcery.com>
371
372         * ppc-linux-nat.c (PT_ORIG_R3, PT_TRAP): Move to
373         nat/ppc-linux.h.
374         (PPC_FEATURE_CELL, PPC_FEATURE_BOOKE): Likewise.
375         (PPC_FEATURE_HAS_DFP): Likewise.
376         (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
377         (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
378         (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
379         Include "nat/ppc-linux.h".
380         * nat/ppc-linux.h: New file.
381         * Makefile.in (HFILES_NO_SRCDIR): Add nat/ppc-linux.h.
382
383 2015-01-14  Pedro Alves  <palves@redhat.com>
384
385         PR gdb/17525
386         * breakpoint.c: Include "interps.h".
387         (bpstat_do_actions_1): Also check whether the interpreter is
388         async.
389
390 2015-01-14  Pedro Alves  <palves@redhat.com>
391
392         PR cli/17828
393         * infrun.c (reinstall_readline_callback_handler_cleanup): Don't
394         reinstall if the interpreter is sync.
395
396 2015-01-13  Doug Evans  <dje@google.com>
397
398         * objfiles.c (objfile_filename): New function.
399         * objfiles.h (objfile_filename): Declare it.
400         (objfile_name): Add function comment.
401         * python/py-objfile.c (objfpy_lookup_objfile_by_name): Try both the
402         bfd file name (which may be realpath'd), and the original name.
403
404 2015-01-13  Joel Brobecker  <brobecker@adacore.com>
405
406         * NEWS: Create a new section for the next release branch.
407         Rename the section of the current branch, now that it has
408         been cut.
409
410 2015-01-13  Joel Brobecker  <brobecker@adacore.com>
411
412         GDB 7.9 branch created (92fc2e6978d9a7c8324c7e851dbee59e22ec7a37):
413         * version.in: Bump version to 7.9.50.DATE-cvs.
414
415 2015-01-13  Joel Brobecker  <brobecker@adacore.com>
416
417         * nat/linux-procfs.c (linux_proc_attach_tgid_threads):
418         Remove trailing new-line in argument of call to warning.
419
420 2015-01-13  Joel Brobecker  <brobecker@adacore.com>
421
422         * linux-nat.c (attach_proc_task_lwp_callback): Remove trailing
423         new-line in argument of call to "warning".
424
425 2015-01-13  Joel Brobecker  <brobecker@adacore.com>
426
427         * ada-lang.c (ada_lookup_symbol_nonlocal): If name not found
428         in static block, then try searching for primitive types.
429
430 2015-01-12  Patrick Palka  <patrick@parcs.ath.cx>
431
432         * top.h (gdb_add_history): Declare.
433         * top.c (command_count): New variable.
434         (gdb_add_history): New function.
435         (gdb_safe_append_history): New static function.
436         (quit_force): Call it.
437         (command_line_input): Use gdb_add_history instead of
438         add_history.
439         * event-top.c (command_line_handler): Likewise.
440
441 2015-01-12  James Clarke  <jrtc27@jrtc27.com>  (tiny patch)
442
443         PR gdb/17046
444         * darwin-nat.c: Replace <machine/setjmp.h> #include by
445         <setjmp.h> #include.
446
447 2015-01-11  Doug Evans  <xdje42@gmail.com>
448
449         * dwarf2read.c (compute_delayed_physnames): Use TYPE_FN_FIELD_PHYSNAME.
450
451 2015-01-11  Doug Evans  <xdje42@gmail.com>
452
453         PR gdb/15830
454         * NEWS: The "maint demangle" command is renamed as "demangle".
455         * demangle.c: #include cli/cli-utils.h, language.h.
456         (demangle_command): New function.
457         (_initialize_demangle): Add new command "demangle".
458         * maint.c (maintenance_demangle): Stub out.
459         (_initialize_maint_cmds): Update help text for "maint demangle",
460         and mark as deprecated.
461
462 2015-01-11  Mark Kettenis  <kettenis@gnu.org>
463
464         * inf-ptrace.c (inf_ptrace_follow_fork): Adjust now that
465         inferior_thread is a function.
466
467 2015-01-09  Patrick Palka  <patrick@parcs.ath.cx>
468
469         * Makefile.in (.y.c): Don't munge yacc's #line
470         directives.
471
472 2015-01-09  Patrick Palka  <patrick@parcs.ath.cx>
473
474         * utils.c (defaulted_query): Rewrite to use gdb_readline_wrapper
475         to prompt for input.
476         * tui/tui-hooks.c (tui_query_hook): Remove.
477         (tui_install_hooks): Don't set deprecated_query_hook.
478         * tui/tui-io.c (tui_redisplay_readline): Fix off-by-one error in
479         height calculation.  Always update the command window's cur_line.
480
481 2015-01-09  Pedro Alves  <palves@redhat.com>
482
483         * breakpoint.c (hardware_breakpoint_inserted_here_p): New
484         function.
485         * breakpoint.h (hardware_breakpoint_inserted_here_p): New
486         declaration.
487         * linux-nat.c (linux_nat_status_is_event): Move higher up in file.
488         (linux_resume_one_lwp): Store the thread's PC.  Adjust to clear
489         stop_reason.
490         (check_stopped_by_watchpoint): New function.
491         (save_sigtrap): Reimplement.
492         (linux_nat_stopped_by_watchpoint): Adjust.
493         (linux_nat_lp_status_is_event): Delete.
494         (stop_wait_callback): Only call save_sigtrap after storing the
495         pending status.
496         (status_callback): If the thread had been stopped for a breakpoint
497         that has since been removed, discard the event and resume the LWP.
498         (count_events_callback, select_event_lwp_callback): Use
499         lwp_status_pending_p instead of linux_nat_lp_status_is_event.
500         (cancel_breakpoint): Rename to ...
501         (check_stopped_by_breakpoint): ... this.  Record whether the LWP
502         stopped for a software breakpoint or hardware breakpoint.
503         (select_event_lwp): Only give preference to the stepping LWP in
504         all-stop mode.  Adjust comments.
505         (stop_and_resume_callback): Remove references to new_pending_p.
506         (linux_nat_filter_event): Likewise.  Leave exit events of the
507         leader thread pending here.  Handle signal short circuiting here.
508         Only call save_sigtrap after storing the pending waitstatus.
509         (linux_nat_wait_1): Remove 'retry' label.  Remove references to
510         new_pending.  Don't handle leaving events the caller is not
511         interested in pending here, nor handle signal short-circuiting
512         here.  Also give equal priority to all LWPs that have had events
513         in non-stop mode.  If reporting a software breakpoint event,
514         unadjust the LWP's PC.
515         * linux-nat.h (enum lwp_stop_reason): New.
516         (struct lwp_info) <stop_pc>: New field.
517         (struct lwp_info) <stopped_by_watchpoint>: Delete field.
518         (struct lwp_info) <stop_reason>: New field.
519         * x86-linux-nat.c (x86_linux_prepare_to_resume): Adjust.
520
521 2015-01-09  Pedro Alves  <palves@redhat.com>
522
523         * linux-nat.c (linux_handle_extended_wait) <PTRACE_EVENT_EXEC>:
524         Set the LWP's 'resumed' flag.
525
526 2015-01-09  Pedro Alves  <palves@redhat.com>
527
528         * linux-nat.c (linux_resume_one_lwp): New function.
529         (resume_lwp): Use lwp_status_pending_p and linux_resume_one_lwp.
530         (linux_nat_resume): Use lwp_status_pending_p and
531         linux_resume_one_lwp.
532         (linux_handle_syscall_trap): Use linux_resume_one_lwp.
533         (linux_handle_extended_wait): Use linux_resume_one_lwp.
534         (status_callback, running_callback): Use lwp_status_pending_p.
535         (lwp_status_pending_p): New function.
536         (stop_and_resume_callback): Use lwp_status_pending_p.
537         (linux_nat_filter_event): Use linux_resume_one_lwp.
538         (linux_nat_wait_1): Always use status_callback to look for an LWP
539         with a pending status.  Use linux_resume_one_lwp.
540         (resume_stopped_resumed_lwps): Use lwp_status_pending_p and
541         linux_resume_one_lwp.
542
543 2015-01-09  Pedro Alves  <palves@redhat.com>
544
545         * breakpoint.c (bp_location_inserted_here_p): New function,
546         factored out from ...
547         (breakpoint_inserted_here_p): ... here.  Use
548         ALL_BP_LOCATIONS_AT_ADDR.
549         (software_breakpoint_inserted_here_p): Use
550         bp_location_inserted_here_p and ALL_BP_LOCATIONS_AT_ADDR.
551
552 2014-01-09  Pedro Alves  <palves@redhat.com>
553
554         Skip enabling event reporting if the kernel supports
555         PTRACE_EVENT_CLONE.
556         * linux-thread-db.c: Include "nat/linux-ptrace.h".
557         (thread_db_use_events): New function.
558         (try_thread_db_load_1): Check thread_db_use_events before enabling
559         event reporting.
560         (update_thread_state): New function.
561         (attach_thread): Use it.  Check thread_db_use_events before
562         enabling event reporting.
563         (thread_db_detach): Check thread_db_use_events before disabling
564         event reporting.
565         (find_new_threads_callback): Check thread_db_use_events before
566         enabling event reporting.  Update the thread's state if not using
567         libthread_db events.
568
569 2015-01-09  Pedro Alves  <palves@redhat.com>
570
571         * linux-nat.c (lin_lwp_attach_lwp): Assert that the lwp id we're
572         about to wait for is > 0.
573         * linux-thread-db.c (find_new_threads_callback): Ignore thread if
574         the kernel thread ID is -1.
575
576 2015-01-09  Pedro Alves  <palves@redhat.com>
577
578         * linux-nat.c (attach_proc_task_lwp_callback): New function.
579         (linux_nat_attach): Use linux_proc_attach_tgid_threads.
580         (wait_lwp, linux_nat_filter_event): If not set yet, set the lwp's
581         ptrace option flags.
582         * linux-nat.h (struct lwp_info) <must_set_ptrace_flags>: New
583         field.
584         * nat/linux-procfs.c: Include <dirent.h>.
585         (linux_proc_get_int): New parameter "warn".  Handle it.
586         (linux_proc_get_tgid): Adjust.
587         (linux_proc_get_tracerpid): Rename to ...
588         (linux_proc_get_tracerpid_nowarn): ... this.
589         (linux_proc_pid_get_state): New function, factored out from
590         (linux_proc_pid_has_state): ... this.  Add new parameter "warn"
591         and handle it.
592         (linux_proc_pid_is_gone): New function.
593         (linux_proc_pid_is_stopped): Adjust.
594         (linux_proc_pid_is_zombie_maybe_warn)
595         (linux_proc_pid_is_zombie_nowarn): New functions.
596         (linux_proc_pid_is_zombie): Use
597         linux_proc_pid_is_zombie_maybe_warn.
598         (linux_proc_attach_tgid_threads): New function.
599         * nat/linux-procfs.h (linux_proc_get_tgid): Update comment.
600         (linux_proc_get_tracerpid): Rename to ...
601         (linux_proc_get_tracerpid_nowarn): ... this, and update comment.
602         (linux_proc_pid_is_gone): New declaration.
603         (linux_proc_pid_is_zombie): Update comment.
604         (linux_proc_pid_is_zombie_nowarn): New declaration.
605         (linux_proc_attach_lwp_func): New typedef.
606         (linux_proc_attach_tgid_threads): New declaration.
607         * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason): Adjust to
608         use nowarn functions.
609         (linux_ptrace_attach_fail_reason_string): Move here from
610         gdbserver/linux-low.c and rename.
611         (ptrace_supports_feature): If the current ptrace options are not
612         known yet, check them now, instead of asserting.
613         * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason_string):
614         Declare.
615
616 2015-01-09  Pedro Alves  <palves@redhat.com>
617
618         * linux-thread-db.c (thread_db_find_new_threads_silently)
619         (try_thread_db_load_1, try_thread_db_load, thread_db_load_search)
620         (find_new_threads_once): Print debug output on gdb_stdlog.
621
622 2015-01-09  Chen Gang  <gang.chen.5i5j@gmail.com>
623             Pedro Alves  <palves@redhat.com>
624
625         * compile/compile.c: Include "gdb_wait.h".
626         (do_rmdir): Check return value, and free 'zap'.
627
628 2015-01-08  Pedro Alves  <palves@redhat.com>
629             Yao Qi  <yao@codesourcery.com>
630
631         * dwarf2loc.c (indirect_pieced_value): Don't call
632         gdb_sign_extend.  Call extract_signed_integer instead.
633         * utils.c (gdb_sign_extend): Remove.
634         * utils.h (gdb_sign_extend): Remove declaration.
635
636 2015-01-07  Pierre Muller  <muller@sourceware.org>
637
638         PR symtab/17811
639         * stabsread.c (define_symbol): Set language for C++ special symbols.
640
641 2015-01-07  Patrick Palka  <patrick@parcs.ath.cx>
642
643         * inflow.c (initial_gdb_ttystate): Tweak comment.
644
645 2015-01-07  Joel Brobecker  <brobecker@adacore.com>
646
647         * inflow.c (set_initial_gdb_ttystate): Add empty line after
648         comment documenting function.
649
650 2015-01-07  Patrick Palka  <patrick@parcs.ath.cx>
651
652         * terminal.h (set_initial_gdb_ttystate): Declare.
653         * inflow.c (initial_gdb_ttystate): New static variable.
654         (set_initial_gdb_ttystate): New setter.
655         (child_terminal_init_with_pgrp): Copy initial_gdb_ttystate
656         instead of our current terminal state.
657         * top.c (gdb_init): Call set_initial_gdb_ttystate.
658
659 2015-01-07  Joel Brobecker  <brobecker@adacore.com>
660
661         * guile/scm-type.c (tyscm_array_1): Add comment.
662         * python/py-type.c (typy_array_1): Add comment.
663
664 2015-01-06  Joel Brobecker  <brobecker@adacore.com>
665
666         * guile/scm-type.c (tyscm_array_1): Do not raise out-of-range
667         error if N2 is equal to N1 - 1.
668
669 2015-01-06  Joel Brobecker  <brobecker@adacore.com>
670
671         * python/py-type.c (typy_array_1): Do not raise negative-length
672         exception if N2 is equal to N1 - 1.
673
674 2015-01-03  Doug Evans  <xdje42@gmail.com>
675
676         * c-exp.y: Whitespace cleanup.
677         (classify_inner_name): Remove extra ;.
678
679 2015-01-02  Maciej W. Rozycki  <macro@codesourcery.com>
680
681         * mips-tdep.c (mips32_scan_prologue): Keep the extracted stack
682         offset signed.
683
684 2015-01-02  Doug Evans  <dje@google.com>
685
686         * dwarf2read.c (setup_type_unit_groups): Remove outdated comment.
687
688 2015-01-02  Doug Evans  <dje@google.com>
689
690         * symtab.h (struct symbol): Fix typo in comment.
691
692 2015-01-01  Joel Brobecker  <brobecker@adacore.com>
693
694         Update year range in copyright notice of all files.
695
696 2015-01-01  Joel Brobecker  <brobecker@adacore.com>
697
698         * top.c (print_gdb_version): Update copyright year to 2015.
699
700 2015-01-01  Joel Brobecker  <brobecker@adacore.com>
701
702         * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2014.
703
704 For older changes see ChangeLog-2014.
705 \f
706 Local Variables:
707 mode: change-log
708 left-margin: 8
709 fill-column: 74
710 version-control: never
711 coding: utf-8
712 End: