1 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
3 Fix compilation warning on gcc-3.4.
4 * exec.c (print_section_info): Move the `displacement' variable
5 initialization to its declaration.
7 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
9 * gdb-gdb.py (StructMainTypePrettyPrinter): Fix TYPE_CODE_RANGE
12 2010-01-15 Eric Botcazou <botcazou@adacore.com>
14 "info tasks" broken by typedefs in ATCB type definitions.
15 * ada-lang.c (ada_template_to_fixed_record_type_1): Add call to
16 ada_check_typedef before retrieving the length of the type for
19 2010-01-15 Joel Brobecker <brobecker@adacore.com>
21 Do not use name-based lookup for unconstrained packed arrays.
22 * ada-lang.c (find_parallel_type_by_descriptive_type):
23 Limit the fallback to name-based lookups to the case where
24 the type is a constrained packed array.
26 2010-01-15 Joel Brobecker <brobecker@adacore.com>
28 Enhance gdb-gdb.py to handle main_type.type_specific.
29 * gdb-gdb.py: Print the type-specific part of struct main_type.
31 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
33 * configure.ac (AC_CHECK_FUNCS): Check for setrlimit and getrlimit.
34 * configure: Regenerate.
35 * config.in: Regenerate.
36 * utils.c: Include sys/resource.h.
37 (dump_core, can_dump_core): New.
38 (internal_vproblem): Update the comment. Check can_dump_core while
39 setting dump_core_p. Replace two abort calls by dump_core calls.
41 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
42 Eli Zaretskii <eliz@gnu.org>
44 * NEWS: Document the PIE support.
46 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
48 * linux-tdep.c: Remove includes gdbcore.h, observer.h and elf-bfd.h.
49 (check_is_pie_binary, _initialize_linux_tdep): Remove.
51 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
53 * solib-svr4.c (svr4_exec_displacement): New comment for entry_point.
54 Replace exec_entry_point call by bfd_get_start_address.
56 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
58 Support Valgrind attachments broken by the PIE support.
59 * auxv.c: Include gdbcore.h.
60 (procfs_xfer_auxv): Make static. Reduce its comment. Drop its
61 parameters ops, object and annex. Remove their assertions.
62 (ld_so_xfer_auxv, memory_xfer_auxv): New function.
63 * auxv.h (procfs_xfer_auxv): Remove comment. Rename to ...
64 (memory_xfer_auxv): ... here.
65 * linux-nat.c (linux_xfer_partial): Rename procfs_xfer_auxv to
67 * procfs.c (procfs_xfer_partial): Likewise.
68 * solib-svr4.c (svr4_relocate_main_executable): New prototype.
69 (svr4_special_symbol_handling): Call svr4_relocate_main_executable.
70 (svr4_solib_create_inferior_hook): Conditionalize the
71 svr4_relocate_main_executable call.
73 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
75 * solib-svr4.c (scan_dyntag): Remove variable dyn_addr. New variable
76 target_section. Find SECT in current_target_sections, gdb_assert it.
77 (elf_lookup_lib_symbol): Pass the binary file if given symfile_objfile.
79 * symtab.c (lookup_objfile_from_block): Return the binary file instead
80 of separate debug info file.
82 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
84 Support PIEs with no symfile_objfile.
85 * exec.c (print_section_info <abfd == exec_bfd>): Relocate Entry point.
86 * solib-svr4.c (svr4_relocate_main_executable <exec_bfd>): New block.
88 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
90 * solib-svr4.c (svr4_relocate_main_executable): Move the static exec
92 (svr4_static_exec_displacement): ... a new function.
93 (svr4_exec_displacement): New function.
94 (svr4_relocate_main_executable): Call svr4_exec_displacement. Allocate
95 new_offsets using alloca now. Remove variable old_chain and changed.
96 Call objfile_relocate unconditionally now.
98 2010-01-14 Doug Evans <dje@google.com>
100 * gdbtypes.c (arch_flags_type): Fix comment.
101 * gdbtypes.h (arch_composite_type): Fix comment.
103 2009-01-14 Tristan Gingold <gingold@adacore.com>
105 * machoread.c (macho_add_oso_symfile): Add symfile_flags parameter.
106 Call xstrdup for abfd->filename. Pass symfile_flags and objfile flags
107 to symbol_file_add_from_bfd. Add OSO as separate objfile.
108 (macho_oso_symfile): Add symfile_flags parameter. Pass it to
109 macho_add_oso_symfile.
110 (macho_symfile_read): Pass symfile_flags to macho_oso_symfile.
112 2010-01-14 Joel Brobecker <brobecker@adacore.com>
114 Tru64: Dead threads are never deleted.
115 * dec-thread.c (dec_thread_ptid_is_alive): New function.
116 (dec_thread_count_gdb_threads): Fix counter increment.
117 (dec_thread_add_gdb_thread): Fix *listp increment.
118 (resync_thread_list): Fix bug in deletion of dead threads that
119 caused all threads to be deleted, instead of just the dead ones.
121 2010-01-13 Phil Muldoon <pmuldoon@redhat.com>
125 * python/python-internal.h: Add lazy_string_object_type
127 (create_lazy_string_object, gdbpy_initialize_lazy_string)
128 (gdbpy_is_lazystring, gdbpy_extract_lazy_string): Define.
129 * python/py-value.c (valpy_lazy_string): New function.
130 (convert_value_from_python): Add lazy string conversion.
131 * python/py-prettyprint.c (pretty_print_one_value): Check if
132 return is also a lazy string.
133 (print_string_repr): Add lazy string printing branch.
134 (print_children): Likewise.
135 * python/py-lazy-string.c: New file. Implement lazy strings.
136 * python/python.c (_initialize_python): Call
137 gdbpy_initialize_lazy_string.
138 * varobj.c (value_get_print_value): Add lazy string printing
139 branch. Account for encoding.
140 * c-lang.c (c_printstr): Account for new encoding argument. If
141 encoding is NULL, find encoding suited for type, otherwise use
143 * language.h (language_defn): Add encoding argument.
144 (LA_PRINT_STRING): Likewise.
145 * language.c (unk_lang_printstr): Update to reflect new encoding
146 argument to language_defn.
147 * ada-lang.h (ada_printstr): Likewise.
148 * c-lang.h (c_printstr): Likewise.
149 * p-lang.h (pascal_printstr);
150 * f-lang.c (f_printstr): Likewise.
151 * m2-lang.c (m2_printstr): Likewise.
152 * objc-lang.c (objc_printstr): Likewise.
153 * p-lang.c (pascal_printstr): Likewise.
154 * scm-lang.c (scm_printstr): Likewise.
155 * c-valprint.c (c_val_print): Update LA_PRINT_STRING call for
157 * ada-valprint.c (ada_printstr): Likewise.
158 * f-valprint.c (f_val_print): Likewise
159 * m2-valprint.c (m2_val_print): Likewise.
160 * p-valprint.c (pascal_val_print): Likewise.
161 * expprint.c (print_subexp_standard): Likewise.
162 * valprint.c (val_print_string): Likewise.
163 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-lazy-string.
164 (SUBDIR_PYTHON_SRCS): Likewise.
165 (py-lazy-string.o): New rule.
168 2010-01-13 Doug Evans <dje@google.com>
170 * mi/mi-main.c (list_available_thread_groups): Avoid "may be used
171 uninitialized" warning from gcc on local `tree'.
173 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
175 Implement core awareness.
177 * bcache.c (compare_ints): Remove
178 (print_percentage): Use compare_positive_ints.
179 * defs.h (compare_positive_ints): Declare.
180 * linux-nat.h (struct lin_lwp): New field core.
181 (linux_nat_core_of_thread_1): Declare.
182 * linux-nat.c (add_lwp): Init the 'core' field.
183 (linux_nat_wait_1): Record the core.
184 (linux_nat_core_of_thread_1, linux_nat_core_of_thread): New.
185 (linux_nat_add_target): Register the above.
186 * linux-thread-db.c (update_thread_core): New.
187 (thread_db_find_new_threads): Update core information for
189 * remote.c (struct private_thread_info): New.
190 (free_private_thread_info, demand_private_info): New.
191 (PACKET_qXfer_threads, use_osdata_threads): New.
192 (struct thread_item, threads_parsing_context
193 (start_thread, end_thread, thread_attributes)
194 (thread_children, threads_children, threads_elements): New.
195 (remote_threads_info): Try qXfer:threads before anything
197 (remote_protocol_packets): Register qXfer:threads.
198 (remote_open_1): Init use_osdata_threads.
199 (struct stop_reply): New field 'core'.
200 (remote_parse_stop_reply): Parse core number.
201 (process_stop_reply): Record core number.
202 (remote_xfer_partial): Handle qXfer:threads.
203 (remote_core_of_thread): New.
204 (init_remote_ops): Register remote_core_of_thread.
205 (_initialize_remote): Register qXfer:read.
206 * target.c (target_core_of_thread): New
207 * target.h (enum target_object): New value TARGET_OBJECT_THREADS.
208 (struct target_ops): New field to_core_of_threads.
209 (target_core_of_thread): Declare.
210 * gdbthread.h (struct thread_info): New field private_dtor.
211 * thread.c (print_thread_info): Report the core.
212 * ui-out.c (MAX_UI_OUT_LEVELS): Increase.
213 * utils.c (compare_positive_ints): New.
214 * features/threads.dtd: New.
215 * mi/mi-interp.c (mi_on_normal_stop): Report the core.
216 * mi/mi-main.c (struct collect_cores_data, collect_cores)
217 (do_nothing, free_vector_of_osdata_items)
218 (splay_tree_int_comparator, free_splay_tree): New.
219 (print_one_inferior_data): Implemented printing of selected
220 inferiors. Collect and print cores.
222 (mi_cmd_list_thread_groups): Support --recurse. Permit specifying
223 thread groups together with --available.
225 2010-01-12 Jan Kratochvil <jan.kratochvil@redhat.com>
227 * configure: Regenerate (for _STRUCTURED_PROC).
229 2010-01-12 Joel Brobecker <brobecker@adacore.com>
231 Delete dead function.
232 * ada-lang.c (extract_string): Delete. No longer used.
234 2010-01-12 Joel Brobecker <brobecker@adacore.com>
236 Fix -Wunused warning in dec-thread.c.
237 * dec-thread.c (dec_thread_count_gdb_threads)
238 (dec_thread_add_gdb_thread): Prevent -Wunused warning.
240 2010-01-12 Joel Brobecker <brobecker@adacore.com>
242 * ada-valprint.c (ada_print_floating): Remove trailing space.
244 2010-01-12 Joel Brobecker <brobecker@adacore.com>
246 Add support for DW_AT_GNAT_descriptive_type.
247 * gdbtypes.h (enum type_specific_kind): New enum.
248 (struct main_type) [type_specific_field]: New component.
249 [type_specific]: Add new component "gnat_stuff".
250 (struct gnat_aux_type): New type.
251 (INIT_CPLUS_SPECIFIC): Also set TYPE_SPECIFIC_FIELD (type).
252 (HAVE_CPLUS_STRUCT): Also check TYPE_SPECIFIC_FIELD (type).
253 (gnat_aux_default, allocate_gnat_aux_type): Add declaration.
254 (INIT_GNAT_SPECIFIC, ALLOCATE_GNAT_AUX_TYPE, HAVE_GNAT_AUX_INFO)
255 (TYPE_SPECIFIC_FIELD): New macros.
256 (TYPE_CPLUS_SPECIFIC): Return cplus_struct_default if the given
257 type does not hold any cplus-specific data.
258 (TYPE_RAW_CPLUS_SPECIFIC): New macro.
259 (TYPE_GNAT_SPECIFIC, TYPE_DESCRIPTIVE_TYPE): New macros.
260 (TYPE_IS_OPAQUE): Use HAVE_CPLUS_STRUCT to check if type has
262 * gdbtypes.c (allocate_cplus_struct_type): Minor stylistic rewrite.
263 Set new component TYPE_SPECIFIC_FIELD (type).
264 (gnat_aux_default): New constant.
265 (allocate_gnat_aux_type): New function.
266 (init_type): Add initialization the type-specific stuff for
267 TYPE_CODE_FLT and TYPE_CODE_FUNC types.
268 (print_gnat_stuff): New function.
269 (recursive_dump_type): Use HAVE_CPLUS_STRUCT to check for cplus-
270 specific data. Adjust code that prints the contents of the
271 type-specific union using the TYPE_SPECIFIC_FIELD value.
272 * dwarf2read.c (dwarf2_attach_fields_to_type): Do not allocate
273 the type cplus stuff for Ada types.
274 (dwarf2_add_member_fn, dwarf2_attach_fn_fields_to_type):
275 Error out if these routines are called with an Ada type.
276 (read_structure_type, read_array_type, read_subrange_type):
277 Add call to set_descriptive_type.
278 (set_die_type): Initialize the gnat-specific data if necessary.
279 (need_gnat_info, die_descriptive_type, set_descriptive_type):
281 * ada-lang.c (decode_constrained_packed_array_type): Use
282 decode_constrained_packed_array_type instead of doing a standard
283 lookup to locate a parallel type.
284 (find_parallel_type_by_descriptive_type): New function.
285 (ada_find_parallel_type_with_name): New function.
286 (ada_find_parallel_type): Reimplement using
287 ada_find_parallel_type_with_name.
288 * ada-valprint.c (print_field_values): Use HAVE_CPLUS_STRUCT
289 to check if type has a cplus stuff.
290 * linespec.c (total_number_of_methods): Likewise.
291 * mdebugread.c (new_type): Likewise.
293 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
295 * NEWS: Document the 0b binary number prefix parsing.
297 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
299 * objfiles.c (objfile_relocate1): Change the return type to int.
300 Describe the new return value. Return non-zero if data changed.
301 (objfile_relocate): New variable changed. Set it. Call
302 breakpoint_re_set depending on CHANGED.
304 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
306 Implement binary numbers parsing.
307 * c-exp.y (parse_number): New case 'b' and 'B'.
309 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
310 Tristan Gingold <gingold@adacore.com>
312 * solib.c (info_sharedlibrary_command): Replace
313 objfile_has_partial_symbols and objfile_has_full_symbols calls by
316 2010-01-10 Joel Brobecker <brobecker@adacore.com>
318 * NEWS: Document the improvements made to the mips-irix port.
320 2010-01-09 Joel Brobecker <brobecker@adacore.com>
322 Fix the documentation of valprint.c:value_print.
323 * valprint.c (value_print): Update the function description to
324 mention that the syntax of the output follows the current_language,
327 2010-01-09 Jan Kratochvil <jan.kratochvil@redhat.com>
329 Fix displacement of separate debug info files.
330 * objfiles.c (objfile_relocate): Rename to ...
331 (objfile_relocate1): ... here and make it static. Extend the comment.
332 (objfile_relocate): New function.
333 * solib-spu.c (spu_relocate_main_executable): Explicitly check if
334 SYMFILE_OBJFILE is NULL. Remove variables objfile and old_chain.
335 Remove following of SEPARATE_DEBUG_OBJFILE. new_offsets is now
336 allocated using alloca.
337 * symfile.c (copy_section_addr_info): Remove.
338 (build_section_addr_info_from_objfile): Make it global. New variables
339 addr_bit and mask, use them.
340 * symfile.h (build_section_addr_info_from_objfile): New prototype.
341 (copy_section_addr_info): Remove.
343 2010-01-09 Joel Brobecker <brobecker@adacore.com>
345 Signal unwinder for mips-irix N32.
346 * mips-irix-tdep.c: #include mips-tdep.h, trad-frame.h, and
348 (SIGTRAMP_FRAME_SIZE, SIGCONTEXT_PC_OFF, SIGCONTEXT_REGS_OFF)
349 (SIGCONTEXT_FPREGS_OFF, SIGCONTEXT_FPCSR_OFF, SIGCONTEXT_HI_OFF)
350 (SIGCONTEXT_LO_OFF): New macros.
351 (mips_irix_n32_tramp_frame_init): New function.
352 (mips_irix_n32_tramp_frame): New static constant.
353 (mips_irix_init_abi): Prepend the mips_irix_n32_tramp_frame unwinder.
355 2010-01-09 Joel Brobecker <brobecker@adacore.com>
357 Breakpoint in shared library does not work on mips-irix.
358 * procfs.c: #include "observer.h".
359 (procfs_inferior_created): New function, moving here the code
360 which unsets the syssgi syscall-exit notifications.
361 (procfs_create_inferior): Remove the code which unsets the syssgi
362 syscall-exit notifications. It is too early to do this here.
363 (_initialize_procfs): Attach the procfs_inferior_created observer.
365 2010-01-09 Joel Brobecker <brobecker@adacore.com>
367 Wrong return convention for arrays (mips-irix).
368 * mips-tdep.c (mips_n32n64_return_value): Arrays whose size is
369 128 bits or smaller are returned the same way as structs
370 and unions of the the same size.
372 2010-01-09 Joel Brobecker <brobecker@adacore.com>
374 Cannot set the PC on mips-irix.
375 * irix5-nat.c (fill_gregset): Check regno against the raw PC
376 register number, no the cooked one.
378 2010-01-09 Joel Brobecker <brobecker@adacore.com>
380 Error while loading core file on mips-irix.
381 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing
382 if debugging from a core file.
384 2010-01-09 Joel Brobecker <brobecker@adacore.com>
386 GDB hangs when attaching to process on mips-irix.
387 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing if
388 attaching to a process.
390 2010-01-09 Joel Brobecker <brobecker@adacore.com>
392 Use the correct breakpoint instruction on mips-irix.
393 * mips-tdep.c (mips_breakpoint_from_pc): Add new static variable
394 containing the correct breakpoint instruction to use on mips-irix.
395 Use it when the osabi is GDB_OSABI_IRIX.
397 2010-01-09 Joel Brobecker <brobecker@adacore.com>
399 -Wunused warning in procfs.c (mips-irix only).
400 * procfs.c (gdb_praddset, gdb_prdelset): New macros. Use them
401 throughout instead of using praddset and prdelset respectively.
403 2010-01-09 Joel Brobecker <brobecker@adacore.com>
405 GDB crash while stepping into function.
406 * infrun.c (handle_inferior_event): Refetch the current frame
407 after handling what.main_action, in case that pointer became
410 2010-01-09 Joel Brobecker <brobecker@adacore.com>
412 Fix build failure of solaris-hosted cross debuggers.
413 * ada-valprint.c, parse.c: Include defs.h before including ctype.h.
415 2010-01-09 Daniel Gutson <dgutson@codesourcery.com>
417 Fix build failure on sparc-solaris.
418 * procfs.c: (procfs_do_thread_registers) Use elfcore_write_lwpstatus.
420 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
422 Move some symfile code into subroutines.
423 * symfile.h (relative_addr_info_to_section_offsets)
424 (addr_info_make_relative): New prototypes.
425 * symfile.c (default_symfile_offsets): Move a part to ...
426 (relative_addr_info_to_section_offsets): ... this new function.
427 (default_symfile_offsets): Call it.
428 (syms_from_objfile <!mainline && addrs && addrs->other[0].name>): Move
430 (addr_info_make_relative): ... this new function.
432 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
434 Add from_tty to solib_create_inferior_hook.
435 * infcmd.c (post_create_inferior): Move solib_add after
436 solib_create_inferior_hook. Pass from_tty to
437 solib_create_inferior_hook. Call solib_add and SOLIB_ADD with
438 0 from_tty and comment why.
439 * infrun.c (follow_exec): Pass from_tty solib_create_inferior_hook as 0.
440 * linux-nat.c (linux_child_follow_fork): Likewise.
441 * nto-procfs.c (procfs_post_attach, procfs_create_inferior): Likewise.
442 * solib-darwin.c (darwin_solib_create_inferior_hook): New parameter
444 * solib-frv.c (frv_solib_create_inferior_hook): Likewise.
445 * solib-irix.c (irix_solib_create_inferior_hook): Likewise.
446 * solib-null.c (null_solib_create_inferior_hook): Likewise.
447 * solib-osf.c (osf_solib_create_inferior_hook): Likewise.
448 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
449 * solib-som.c (som_solib_create_inferior_hook): Likewise.
450 * solib-spu.c (spu_solib_create_inferior_hook): New parameter from_tty.
451 Pass it to svr4_so_ops.solib_create_inferior_hook.
452 * solib-sunos.c (sunos_solib_create_inferior_hook): New parameter
454 * solib-svr4.c (enable_break): New parameter from_tty. Pass it to
456 (svr4_solib_create_inferior_hook): New parameter from_tty. Pass it to
458 * solib-target.c (solib_target_solib_create_inferior_hook): New
460 * solib.c (solib_create_inferior_hook): New parameter from_tty. Pass
461 it to ops->solib_create_inferior_hook.
462 (reload_shared_libraries): Pass from_tty to solib_create_inferior_hook.
463 Move solib_add after solib_create_inferior_hook, call it now with
464 from_tty as 0. New comment there.
465 * solib.h (solib_create_inferior_hook): New parameter from_tty.
466 * solist.h (struct target_so_ops <solib_create_inferior_hook>):
469 2010-01-08 Vladimir Prus <vladimir@codesourcery.com>
472 * infrun.c (handle_inferior_event): Use get_thread_regcache
473 with events ptid, not get_current_regcache.
475 2009-01-08 Joel Brobecker <brobecker@adacore.com>
477 GDB crash with empty executable name (MinGW).
478 * source.c (openp): Add assert that parameter string is not NULL.
479 if parameter string is an empty string, then return with a failure
482 2009-01-08 Joel Brobecker <brobecker@adacore.com>
484 Get rid of support for VAX Floats.
485 * ada-lang.h (ada_is_vax_floating_type, ada_vax_float_type_suffix)
486 (ada_vax_float_print_function): Delete.
487 * ada-lang.c (ada_is_vax_floating_type, ada_vax_float_type_suffix)
488 (ada_vax_float_print_function): Delete.
489 * ada-typeprint.c (print_vax_floating_point_type): Delete.
490 (ada_print_type): Remove support for VAX floats.
491 * ada-valprint.c (ada_val_print_1): Remove support for VAX floats.
493 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
495 * stabsread.c (read_args): Handle zero arguments.
497 2009-01-08 Joel Brobecker <brobecker@adacore.com>
499 Cannot find in-tree libiconv.a after reconfigure.
500 * acinclude.m4 (AM_ICONV): If we find an in-tree libiconv.a
501 that we can use, then cache the path to this archive.
502 * configure: Regenerate.
504 2010-01-07 Stan Shebs <stan@codesourcery.com>
506 Make tracepoint operations go through target vector.
507 * target.h (enum trace_find_type): New enum.
508 (struct target_ops): New fields to_trace_init,
509 to_download_tracepoint, to_download_trace_state_variable,
510 to_trace_set_readonly_regions, to_trace_start, to_get_trace_status,
511 to_trace_stop, to_trace_find, to_get_trace_state_variable_value,
512 to_set_disconnected_tracing.
513 (target_trace_init): New macro.
514 (target_download_tracepoint): New macro.
515 (target_download_trace_state_variable): New macro.
516 (target_trace_start): New macro.
517 (target_trace_set_readonly_regions): New macro.
518 (target_get_trace_status): New macro.
519 (target_trace_stop): New macro.
520 (target_trace_find): New macro.
521 (target_get_trace_state_variable_value): New macro.
522 (target_set_disconnected_tracing): New macro.
523 * target.c (update_current_target): Inherit and set defaults for
524 tracepoint operations.
525 * tracepoint.c (default_collect): Make globally visible.
526 (target_is_remote): Remove, along with all calls.
527 (tvariables_info): Call target_get_trace_state_variable_value.
528 (remote_set_transparent_ranges): Remove.
529 (trace_start_command): Call target_trace_init,
530 target_download_tracepoint, etc.
531 (download_tracepoint): Remove.
532 (trace_stop_command): Simplify.
533 (stop_tracing): Call target_trace_stop.
534 (get_trace_status): Call target_get_trace_status.
535 (trace_status_command): Add case for targets that cannot trace.
536 (finish_tfind_command): Change to take numerical arguments, call
538 (trace_find_command): Update call to finish_tfind_command.
539 (trace_find_pc_command): Ditto.
540 (trace_find_tracepoint_command): Ditto.
541 (trace_find_line_command): Ditto.
542 (trace_find_range_command): Ditto.
543 (trace_find_outside_command): Ditto.
544 (set_disconnected_tracing_value): Call
545 target_set_disconnected_tracing.
546 * remote.c: Add protocol encoding bits from tracepoint.c.
547 (trace_error): Move from tracepoint.c.
548 (remote_get_noisy_reply): Ditto.
549 (free_actions_list_cleanup_wrapper): Ditto.
550 (free_actions_list): Ditto.
551 (remote_trace_init): New function.
552 (remote_download_tracepoint): New function.
553 (remote_download_trace_state_variable): New function.
554 (remote_trace_set_readonly_regions): New function.
555 (remote_trace_start): New function.
556 (remote_get_trace_status): New function.
557 (remote_trace_stop): New function.
558 (remote_trace_find): New function.
559 (remote_download_trace_state_variable): New function.
560 (remote_set_disconnected_tracing): New function.
561 (init_remote_ops): Add tracepoint operations.
563 * tracepoint.c (trace_dump_command): Don't decr_pc_after_break.
565 2010-01-07 Tristan Gingold <gingold@adacore.com>
567 * symfile.c (build_section_addr_info_from_objfile): New function.
568 (symbol_file_add_separate): Don't use offsets from objfile but
571 2010-01-06 Stan Shebs <stan@codesourcery.com>
573 Support disconnected tracing.
574 * infcmd.c (detach_command): Ask whether to stop tracing.
575 * cli/cli-cmds.c (quit_command): Ditto.
576 * breakpoint.h (struct breakpoint): New field number_on_target.
577 * breakpoint.c (create_tracepoint_from_upload): New function.
578 (get_tracepoint_by_number_on_target): New function.
579 * remote.c (struct remote): New field disconnected_tracing.
580 (remote_disconnected_tracing_feature): New function.
581 (remote_protocol_features): Add DisconnectedTracing.
582 (struct uploaded_tp): New struct.
583 (uploaded_tps): New global.
584 (get_uploaded_tp): New function.
585 (find_matching_tracepoint): New function.
586 (remote_get_tracing_state): New function.
587 (remote_start_remote): Call it.
588 * tracepoint.c (disconnected_tracing): New global.
589 (trace_start_command): Initialize number_on_target.
590 (stop_tracing): New function, split out from...
591 (trace_stop_command): Call stop_tracing.
592 (get_trace_status): New function, split out from...
593 (trace_status_command): Call get_trace_status, add info on
594 disconnection behavior.
595 (disconnect_or_stop_tracing): New function.
596 (finish_tfind_command): Translate from number on target.
597 (trace_find_tracepoint_command): Translate to number on target.
598 (send_disconnected_tracing_value): New function.
599 (set_disconnected_tracing): New function.
600 (_initialize_tracepoint): Add disconnected-tracing variable.
601 * NEWS: Mention disconnected tracing.
603 2010-01-06 Tristan Gingold <gingold@adacore.com>
605 * symtab.c (lookup_global_symbol_from_objfile): Rename objfile
606 parameter to main_objfile. Iterate on all separate debug objfiles.
607 * symfile.h (symbol_file_add_separate)
608 (find_separate_debug_file_by_debuglink): Remove parameter names.
609 * symfile.c (symbol_file_add_separate): Use add_separate_objfile.
610 (reread_symbols): Use free_objfile_separate_debug.
611 * objfiles.h (struct objfile): Add separate_debug_objfile_link.
613 (objfile_separate_debug_iterate, add_separate_debug_objfile)
614 (free_objfile_separate_debug): New prototypes.
615 * objfiles.c (objfile_separate_debug_iterate): New function.
616 (add_separate_debug_objfile, free_objfile_separate_debug): New
618 (free_objfile): Use free_objfile_separate_debug. Adjust for
619 multiple separate debug objfile.
620 (objfile_has_symbols): Adjust comment. Iterate on all separate
622 * minsyms.c (lookup_minimal_symbol): Adjust for multiple separate
624 (lookup_minimal_symbol_text): Ditto.
625 (lookup_minimal_symbol_by_pc_name): Ditto.
626 (lookup_minimal_symbol_solib_trampoline): Ditto.
627 (lookup_minimal_symbol_by_pc_section_1): Iterate on all separate
630 2010-01-05 Stan Shebs <stan@codesourcery.com>
632 Add fast tracepoints.
633 * arch-utils.h (default_fast_tracepoint_valid_at): Declare.
634 * arch-utils.c (default_fast_tracepoint_valid_at): New function.
635 * breakpoint.h (enum bptype): Add bp_fast_tracepoint.
636 * breakpoint.c (tracepoint_type): New function.
637 (ALL_TRACEPOINTS): Use it.
638 (should_be_inserted): Ditto.
639 (bpstat_check_location): Ditto.
640 (print_one_breakpoint_location): Ditto.
641 (user_settable_breakpoint): Ditto.
642 (set_breakpoint_location_function): Ditto.
643 (disable_breakpoints_in_shlibs): Ditto.
644 (delete_trace_command): Ditto.
645 (print_it_typical): Add bp_fast_tracepoint case.
646 (bpstat_what): Ditto.
647 (print_one_breakpoint_location): Ditto.
648 (allocate_bp_location): Ditto.
650 (breakpoint_re_set_one): Ditto.
651 (disable_command): Ditto.
652 (enable_command): Ditto.
653 (check_fast_tracepoint_sals): New function.
654 (break_command_really): Call it.
655 (ftrace_command): New function.
656 (_initialize_breakpoint): Add ftrace command.
657 * gdbarch.sh (fast_tracepoint_valid_at): New.
658 * gdbarch.h, gdbarch.c: Regenerate.
659 * i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
660 (i386_gdbarch_init): Use it.
661 * remote.c (struct remote_state): New field fast_tracepoints.
662 (PACKET_FastTracepoints): New packet config type.
663 (remote_fast_tracepoint_feature): New function.
664 (remote_protocol_features): Add FastTracepoints.
665 (remote_supports_fast_tracepoints): New function.
666 (_initialize_remote): Add FastTracepoints.
667 * tracepoint.c (download_tracepoint): Add fast tracepoint option.
668 * NEWS: Mention fast tracepoints.
670 2010-01-06 Joel Brobecker <brobecker@adacore.com>
672 * gdb-gdb.py: New file.
674 2010-01-05 Michael Snyder <msnyder@vmware.com>
676 * infrun.c (handle_inferior_event): Fix typo in comment.
678 2010-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
680 * symfile.c (syms_from_objfile): Remove the !MAINLINE conditional.
682 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
684 * features/Makefile (WHICH): Add s390-linux32, s390-linux64,
686 (s390-linux32-expedite): Define.
687 (s390-linux64-expedite): Define.
688 (s390x-linux64-expedite): Define.
689 * features/s390-acr.xml: New file.
690 * features/s390-fpr.xml: New file.
691 * features/s390-core32.xml: New file.
692 * features/s390-core64.xml: New file.
693 * features/s390x-core64.xml: New file.
694 * features/s390-linux32.xml: New file.
695 * features/s390-linux64.xml: New file.
696 * features/s390x-linux64.xml: New file.
697 * features/s390-linux32.c: New generated file.
698 * features/s390-linux64.c: New generated file.
699 * features/s390x-linux64.c: New generated file.
701 * regformats/s390-linux32.dat: New generated file.
702 * regformats/s390-linux64.dat: New generated file.
703 * regformats/s390x-linux64.dat: New generated file.
704 * regformats/reg-s390.dat: Remove.
705 * regformats/reg-s390x.dat: Remove.
707 * s390-nat.c: Include "auxv.h" and <elf.h>.
708 (HWCAP_S390_HIGH_GPRS): Define if undefined.
709 (s390_target_wordsize): New function.
710 (s390_auxv_parse): Likewise.
711 (s390_get_hwcap): Likewise.
712 (s390_read_description): Likewise.
713 (_initialize_s390_nat): Install s390_auxv_parse and
714 s390_read_description.
716 * s390-tdep.c: Include "features/s390-linux32.c",
717 "features/s390-linux64.c", and "features/s390x-linux64.c".
718 (struct gdbarch_tdep): Add gpr_full_regnum, pc_regnum, and cc_regnum.
719 (s390_register_call_saved): New function.
720 (s390_register_name): Remove.
721 (s390_register_type): Remove.
722 (s390_dwarf_regmap): Add lower half GPR pseudo DWARF CFI regnums.
723 (s390_dwarf_reg_to_regnum): Remap GPR regnums to full GPRs.
724 (s390_adjust_frame_regnum): Remap GPR regnums to lower halves for CFI.
725 (s390_pseudo_register_name): New function.
726 (s390_pseudo_register_type): New function.
727 (s390_pseudo_register_read): Handle both 32-bit and 64-bit cases.
728 Handle full GPR pesudos and varying pseudo register numbers.
729 (s390_pseudo_register_write): Likewise
730 (s390x_pseudo_register_read): Remove.
731 (s390x_pseudo_register_write): Likewise.
732 (s390_register_group): Remove.
733 (s390_pseudo_register_group): New function.
734 (s390_regmap_gregset): Add GPR upper halves.
735 (s390x_regmap_gregset): Likewise.
736 (s390_regmap_fpregset): Likewise.
737 (s390_regmap_upper): New global variable.
738 (s390_upper_regset): New global variable.
739 (s390_upper_regset_sections): New global variable.
740 (s390_regset_from_core_section): Handle GPR upper halves.
741 (s390_core_read_description): New function.
742 (s390_prologue_frame_unwind_cache): Set up ABI call-saved/clobbered
743 register information. Handle varying pseudo register numbers.
744 (s390_backchain_frame_unwind_cache): Likewise.
745 (s390_frame_prev_register): Unwind full GPRs to show lower halves.
746 (s390_stub_frame_unwind_cache): Handle varying pseudo register numbers.
747 (s390_sigtramp_frame_unwind_cache): Unwind PSWM and PSWA as well as
748 PC and CC pseudos. Unwind upper halves and full GPRs as appropriate.
749 Handle varying pseudo register numbers.
750 (s390_unwind_pc): Handle varying pseudo register numbers.
751 (s390_dwarf2_prev_register): New function.
752 (s390_dwarf2_frame_init_reg): Set up ABI call-saved/clobbered
753 register information. Handle varying pseudo register numbers.
754 Install s390_dwarf2_prev_register to unwind full GPRs.
755 (s390_gdbarch_init): Handle target descriptions. Assign varying
756 pseudo register numbers. Install s390_adjust_frame_regnum.
757 (_initialize_s390_tdep): Initialize target descriptions.
759 * s390-tdep.h (S390_R0_UPPER_REGNUM .. S390_R15_UPPER_REGNUM): Define.
760 (S390_NUM_REGS): Redefine to include upper half registers.
761 (S390_PC_REGNUM, S390_CC_REGNUM): Remove.
762 (S390_NUM_PSEUDO_REGS, S390_NUM_TOTAL_REGS): Likewise.
763 (tdesc_s390_linux32): Add declaration.
764 (tdesc_s390_linux64): Likewise.
765 (tdesc_s390x_linux64): Likewise.
767 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
769 * regset.h (struct core_regset_section): Add HUMAN_NAME.
770 * i386-linux-tdep.c (i386_linux_regset_sections): Fill in HUMAN_NAME.
771 * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections): Likewise.
772 (ppc_linux_vmx_regset_sections): Likewise.
773 (ppc_linux_fp_regset_sections): Likewise.
775 * corelow.c (get_core_register_section): Constify arguments.
776 (get_core_registers): Use gdbarch_core_regset_sections instead
777 of hard-coded platform-specific register section names.
779 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
781 * dwarf2loc.c (read_pieced_value): If a piece occupies part of
782 a register, assume the least-significant part is used.
783 (write_pieced_value): Likewise.
785 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
787 * printcmd.c: Include "arch-utils.h".
788 (do_one_display): Re-parse expression if current architecture changed.
790 2010-01-03 Jan Kratochvil <jan.kratochvil@redhat.com>
791 Joel Brobecker <brobecker@adacore.com>
793 * gdbtypes.c (check_typedef): New comment on type length.
794 * value.c (allocate_value_lazy): Remove the unused atype variable. New
795 comment on type length.
796 (value_primitive_field): Keep the original TYPE value, new comment.
798 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
800 * cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
801 p_start. Change != comparisons to > and < comparisons.
803 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
805 * cli/cli-script.c (process_next_line): Check P2 overrun.
807 2009-01-01 Joel Brobecker <brobecker@adacore.com>
809 Update the copyright hearder to add year 2010 for most GDB files.
811 2009-01-01 Joel Brobecker <brobecker@adacore.com>
813 Fix build failure in inf-ptrace.c.
814 * inf-ptrace.c (inf_ptrace_follow_fork): Fix typo.
816 2010-01-01 Joel Brobecker <brobecker@adacore.com>
818 * top.c (print_gdb_version): Update copyright year.
820 2010-01-01 Joel Brobecker <brobecker@adacore.com>
822 Fix break *FUN'address thread NUM.
823 * ada-lex.l (task): Expand rule to also match the thread keyword.
825 2010-01-01 Joel Brobecker <brobecker@adacore.com>
827 Fix break *FUN'address task NUM.
828 * ada-lex.l (task): New rule.
829 * ada-lang.c (valid_task_id): Make sure the Ada task list has
830 been built before using it.
832 For older changes see ChangeLog-2009.
838 version-control: never