1 2010-01-19 Joel Brobecker <brobecker@adacore.com>
3 "delete" ada-lex.c:input function, not used.
4 * ada-lex.l: #define YY_NO_INPUT.
6 2010-01-19 Joel Brobecker <brobecker@adacore.com>
8 Delete free_named_symtabs and associated cleanup.
9 * symfile.h (free_named_symtabs): Delete declaration.
10 * symfile.c: Remove some commented out code (clear_symtab_users_once).
11 (cashier_psymtab): Comment function out.
13 (free_named_symtabs): Delete.
14 * coffread.c (coff_end_symtab): Remove call to free_named_symtabs.
15 * dbxread.c (end_psymtab): Likewise.
16 * dwarf2read.c (process_psymtab_comp_unit): Ditto.
17 * exec.c (exec_close_1): Ditto.
18 * xcoffread.c (xcoff_end_psymtab): Likewise.
20 2010-01-19 Joel Brobecker <brobecker@adacore.com>
22 * stack.c (print_block_frame_labels): Comment function out.
24 2010-01-19 Joel Brobecker <brobecker@adacore.com>
26 Delete unused or undefined functions.
27 * breakpoint.c (ep_parse_optional_filename): Delete.
28 * dcache.c (dcache_write_line): Remove declaration.
29 * infrun.c (build_infrun): Remove declaration.
30 * tracepoint.c (tracepoint_save_command): Remove declaration.
31 * linux-nat.c (init_lwp_list): Delete. No longer used.
32 * event-loop.c (check_async_signal_handlers): Delete declaration.
33 * infrun.c (init_execution_control_state): Delete.
34 (proceed): Update comment to avoid mentioning
35 init_execution_control_state.
36 * target.c (kill_or_be_killed, nosupport_runtime): Delete.
37 * ada-lang.c (ada_to_static_fixed_value): Delete.
38 * scm-lang.c (evaluate_subexp_scm): Delete declaration.
39 * cp-namespace.c (cp_copy_usings): Delete.
40 * xml-syscall.c (xml_number_of_syscalls): Delete.
41 * progspace.c (find_program_space_by_num): Delete.
42 * inflow.c (handle_sigio): Delete declaration.
43 * hppa-tdep.c (hppa_alignof): Delete.
44 * mipsnbsd-tdep.c (mipsnbsd_sigtramp_offset)
45 (mipsnbsd_core_osabi_sniffer): Delete.
47 2010-01-18 Tom Tromey <tromey@redhat.com>
50 * c-exp.y (REINTERPRET_CAST, DYNAMIC_CAST, STATIC_CAST)
51 (CONST_CAST): New tokens.
52 (exp): Add new productions.
53 (ident_tokens): Add const_cast, dynamic_cast, static_cast, and
55 (is_cast_operator): New function.
56 (yylex): Handle cast operators specially.
57 * eval.c (evaluate_subexp_standard) <UNOP_DYNAMIC_CAST,
58 UNOP_REINTERPRET_CAST>: New cases.
59 * expprint.c (print_subexp_standard): Likewise.
60 (op_name_standard): Likewise.
61 (dump_subexp_body_standard): Likewise.
62 * parse.c (operator_length_standard): Likewise.
63 * expression.h (enum exp_opcode): New constants UNOP_DYNAMIC_CAST,
64 UNOP_REINTERPRET_CAST.
65 * gdbtypes.c (class_types_same_p): New function.
66 (is_ancestor): Use it.
67 (is_public_ancestor): New function.
68 (is_unique_ancestor_worker): Likewise.
69 (is_unique_ancestor): Likewise.
70 * gdbtypes.h (class_types_same_p, is_public_ancestor)
71 (is_unique_ancestor): Declare.
72 * valops.c (value_reinterpret_cast): New function.
73 (dynamic_cast_check_1): Likewise.
74 (dynamic_cast_check_2): Likewise.
75 (value_dynamic_cast): Likewise.
76 * value.h (value_reinterpret_cast, value_dynamic_cast): Declare.
78 2010-01-18 Joel Brobecker <brobecker@adacore.com>
80 Fix build failure when building without Python support.
81 * python/python.c: Always include exceptions.h, even when HAVE_PYTHON
84 2010-01-18 Joel Brobecker <brobecker@adacore.com>
86 Use XVS field type instead of doing a parallel lookup.
87 * ada-lang.c (ada_get_base_type): Follow the XVS field type
88 if it is a reference type instead of doing a type lookup using
91 2010-01-18 Joel Brobecker <brobecker@adacore.com>
93 Trust PAD types instead of using PAD___XVS.
94 * ada-lang.c (trust_pad_over_xvs): New static variable.
95 (ada_is_aligner_type): If !trust_pad_over_xvs and there is a
96 parallel XVS type, follow the XVS type instead of the PAD type.
97 (unwrap_value): Make sure that there is no parallel XVE type
98 before returning the value as is.
99 (set_ada_list, show_ada_list): New static variables.
100 (set_ada_command, show_ada_command): New functions.
101 (_initialize_ada_language): Add new "set/show ada" prefix commands.
102 Add new "set/show ada trust-PAD-over-XVS" setting.
104 2010-01-18 Tom Tromey <tromey@redhat.com>
105 Thiago Jung Bauermann <bauerman@br.ibm.com>
107 Allow "source" to load python scripts.
108 * exceptions.h (enum errors): Add UNSUPPORTED_ERROR.
109 * python/python.c (source_python_script): New function.
110 * python/python.h (source_python_script): Add declaration.
111 * cli/cli-cmds.c: #include exceptions.h and python/python.h.
112 (script_ext_off, script_ext_soft, script_ext_strict)
113 (script_ext_enums, script_ext_mode): New static constants.
114 (show_script_ext_mode, find_and_open_script): New functions.
115 (source_script): Enhance to handle Python scripts.
116 (init_cli_cmds): Add set/show script-extension commands.
118 2010-01-16 Stan Shebs <stan@codesourcery.com>
120 * tracepoint.h (struct trace_status): Use unsigned long long
122 * tracepoint.c (trace_status_command): Fix printf directive.
123 (trace_save_command): Check fwrite returns, fix printf directive.
124 (trace_filename): New global.
125 (tfile_open): Set it, check read returns.
126 (tfile_close): Free trace_filename.
127 (tfile_get_traceframe_address): Check read returns.
128 (tfile_trace_find): Ditto.
129 (tfile_fetch_registers): Ditto.
130 (tfile_xfer_partial): Ditto.
131 (tfile_get_trace_state_variable_value): Ditto.
133 2010-01-15 Stan Shebs <stan@codesourcery.com>
135 Add trace file support.
136 * tracepoint.h (enum trace_stop_reason): New enum.
137 (struct trace_status): New struct.
138 (parse_trace_status): Declare.
139 (struct uploaded_tp): Move here from remote.c,
140 add fields for actions.
141 (struct uploaded_tsv): New struct.
142 * tracepoint.c (tfile_ops): New target vector.
143 (trace_fd): New global.
144 (tfile_open): New function.
145 (tfile_close): New function.
146 (tfile_files_info): New function.
147 (tfile_get_trace_status): New function.
148 (tfile_get_traceframe_address): New function.
149 (tfile_trace_find): New function.
150 (tfile_fetch_registers): New function.
151 (tfile_xfer_partial): New function.
152 (tfile_get_trace_state_variable_value): New function.
153 (init_tfile_ops): New function.
154 (_initialize_tracepoint): Call it, add tfile target.
155 (trace_status): New global.
156 (current_trace_status): New function.
157 (trace_running_p): Remove, change all users to get from
158 current_trace_status()->running.
159 (get_trace_status): Remove.
160 (trace_status_command): Call target_get_trace_status directly,
161 report more detail including tracing stop reasons.
162 (trace_find_command): Always allow tfind on a file.
163 (trace_find_pc_command): Ditto.
164 (trace_find_tracepoint_command): Ditto.
165 (trace_find_line_command): Ditto.
166 (trace_find_range_command): Ditto.
167 (trace_find_outside_command): Ditto.
168 (trace_frames_offset, cur_offset): Declare as off_t.
169 (trace_regblock_size): Rename from reg_size, update users.
170 (parse_trace_status): New function.
171 (tfile_interp_line): New function.
172 (disconnect_or_stop_tracing): Ensure current trace
173 status before asking what to do.
174 (stop_reason_names): New global.
175 (trace_save_command): New command.
176 (get_uploaded_tp): Move here from remote.c.
177 (find_matching_tracepoint): Ditto.
178 (merge_uploaded_tracepoints): New function.
179 (parse_trace_status): Use stop_reason_names.
180 (_initialize_tracepoint): Define tsave command.
181 * target.h (target_ops): New fields to_save_trace_data,
182 to_upload_tracepoints, to_upload_trace_state_variables,
183 to_get_raw_trace_data, change to_get_trace_status
184 to take a pointer to a status struct.
185 (target_save_trace_data): New macro.
186 (target_upload_tracepoints): New macro.
187 (target_upload_trace_state_variables): New macro.
188 (target_get_raw_trace_data): New macro.
189 * target.c (update_current_target): Add new methods, change
190 signature of to_get_trace_status.
191 * remote.c (hex2bin): Make globally visible.
193 (remote_download_trace_state_variable): Download name also.
194 (remote_get_trace_status): Update parameter, use
196 (remote_save_trace_data): New function.
197 (remote_upload_tracepoints): New function.
198 (remote_upload_trace_state_variables): New function.
199 (remote_get_raw_trace_data): New function.
200 (remote_start_remote): Use them.
201 (_initialize_remote_ops): Add operations.
202 * ax-gdb.c: Include breakpoint.h.
203 * breakpoint.c (create_tracepoint_from_upload): Use
204 break_command_really, return tracepoint, warn about unimplemented
206 * NEWS: Mention trace file addition.
208 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
210 Fix compilation warning on gcc-3.4.
211 * exec.c (print_section_info): Move the `displacement' variable
212 initialization to its declaration.
214 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
216 * gdb-gdb.py (StructMainTypePrettyPrinter): Fix TYPE_CODE_RANGE
219 2010-01-15 Eric Botcazou <botcazou@adacore.com>
221 "info tasks" broken by typedefs in ATCB type definitions.
222 * ada-lang.c (ada_template_to_fixed_record_type_1): Add call to
223 ada_check_typedef before retrieving the length of the type for
226 2010-01-15 Joel Brobecker <brobecker@adacore.com>
228 Do not use name-based lookup for unconstrained packed arrays.
229 * ada-lang.c (find_parallel_type_by_descriptive_type):
230 Limit the fallback to name-based lookups to the case where
231 the type is a constrained packed array.
233 2010-01-15 Joel Brobecker <brobecker@adacore.com>
235 Enhance gdb-gdb.py to handle main_type.type_specific.
236 * gdb-gdb.py: Print the type-specific part of struct main_type.
238 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
240 * configure.ac (AC_CHECK_FUNCS): Check for setrlimit and getrlimit.
241 * configure: Regenerate.
242 * config.in: Regenerate.
243 * utils.c: Include sys/resource.h.
244 (dump_core, can_dump_core): New.
245 (internal_vproblem): Update the comment. Check can_dump_core while
246 setting dump_core_p. Replace two abort calls by dump_core calls.
248 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
249 Eli Zaretskii <eliz@gnu.org>
251 * NEWS: Document the PIE support.
253 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
255 * linux-tdep.c: Remove includes gdbcore.h, observer.h and elf-bfd.h.
256 (check_is_pie_binary, _initialize_linux_tdep): Remove.
258 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
260 * solib-svr4.c (svr4_exec_displacement): New comment for entry_point.
261 Replace exec_entry_point call by bfd_get_start_address.
263 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
265 Support Valgrind attachments broken by the PIE support.
266 * auxv.c: Include gdbcore.h.
267 (procfs_xfer_auxv): Make static. Reduce its comment. Drop its
268 parameters ops, object and annex. Remove their assertions.
269 (ld_so_xfer_auxv, memory_xfer_auxv): New function.
270 * auxv.h (procfs_xfer_auxv): Remove comment. Rename to ...
271 (memory_xfer_auxv): ... here.
272 * linux-nat.c (linux_xfer_partial): Rename procfs_xfer_auxv to
274 * procfs.c (procfs_xfer_partial): Likewise.
275 * solib-svr4.c (svr4_relocate_main_executable): New prototype.
276 (svr4_special_symbol_handling): Call svr4_relocate_main_executable.
277 (svr4_solib_create_inferior_hook): Conditionalize the
278 svr4_relocate_main_executable call.
280 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
282 * solib-svr4.c (scan_dyntag): Remove variable dyn_addr. New variable
283 target_section. Find SECT in current_target_sections, gdb_assert it.
284 (elf_lookup_lib_symbol): Pass the binary file if given symfile_objfile.
286 * symtab.c (lookup_objfile_from_block): Return the binary file instead
287 of separate debug info file.
289 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
291 Support PIEs with no symfile_objfile.
292 * exec.c (print_section_info <abfd == exec_bfd>): Relocate Entry point.
293 * solib-svr4.c (svr4_relocate_main_executable <exec_bfd>): New block.
295 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
297 * solib-svr4.c (svr4_relocate_main_executable): Move the static exec
299 (svr4_static_exec_displacement): ... a new function.
300 (svr4_exec_displacement): New function.
301 (svr4_relocate_main_executable): Call svr4_exec_displacement. Allocate
302 new_offsets using alloca now. Remove variable old_chain and changed.
303 Call objfile_relocate unconditionally now.
305 2010-01-14 Doug Evans <dje@google.com>
307 * gdbtypes.c (arch_flags_type): Fix comment.
308 * gdbtypes.h (arch_composite_type): Fix comment.
310 2009-01-14 Tristan Gingold <gingold@adacore.com>
312 * machoread.c (macho_add_oso_symfile): Add symfile_flags parameter.
313 Call xstrdup for abfd->filename. Pass symfile_flags and objfile flags
314 to symbol_file_add_from_bfd. Add OSO as separate objfile.
315 (macho_oso_symfile): Add symfile_flags parameter. Pass it to
316 macho_add_oso_symfile.
317 (macho_symfile_read): Pass symfile_flags to macho_oso_symfile.
319 2010-01-14 Joel Brobecker <brobecker@adacore.com>
321 Tru64: Dead threads are never deleted.
322 * dec-thread.c (dec_thread_ptid_is_alive): New function.
323 (dec_thread_count_gdb_threads): Fix counter increment.
324 (dec_thread_add_gdb_thread): Fix *listp increment.
325 (resync_thread_list): Fix bug in deletion of dead threads that
326 caused all threads to be deleted, instead of just the dead ones.
328 2010-01-13 Phil Muldoon <pmuldoon@redhat.com>
332 * python/python-internal.h: Add lazy_string_object_type
334 (create_lazy_string_object, gdbpy_initialize_lazy_string)
335 (gdbpy_is_lazystring, gdbpy_extract_lazy_string): Define.
336 * python/py-value.c (valpy_lazy_string): New function.
337 (convert_value_from_python): Add lazy string conversion.
338 * python/py-prettyprint.c (pretty_print_one_value): Check if
339 return is also a lazy string.
340 (print_string_repr): Add lazy string printing branch.
341 (print_children): Likewise.
342 * python/py-lazy-string.c: New file. Implement lazy strings.
343 * python/python.c (_initialize_python): Call
344 gdbpy_initialize_lazy_string.
345 * varobj.c (value_get_print_value): Add lazy string printing
346 branch. Account for encoding.
347 * c-lang.c (c_printstr): Account for new encoding argument. If
348 encoding is NULL, find encoding suited for type, otherwise use
350 * language.h (language_defn): Add encoding argument.
351 (LA_PRINT_STRING): Likewise.
352 * language.c (unk_lang_printstr): Update to reflect new encoding
353 argument to language_defn.
354 * ada-lang.h (ada_printstr): Likewise.
355 * c-lang.h (c_printstr): Likewise.
356 * p-lang.h (pascal_printstr);
357 * f-lang.c (f_printstr): Likewise.
358 * m2-lang.c (m2_printstr): Likewise.
359 * objc-lang.c (objc_printstr): Likewise.
360 * p-lang.c (pascal_printstr): Likewise.
361 * scm-lang.c (scm_printstr): Likewise.
362 * c-valprint.c (c_val_print): Update LA_PRINT_STRING call for
364 * ada-valprint.c (ada_printstr): Likewise.
365 * f-valprint.c (f_val_print): Likewise
366 * m2-valprint.c (m2_val_print): Likewise.
367 * p-valprint.c (pascal_val_print): Likewise.
368 * expprint.c (print_subexp_standard): Likewise.
369 * valprint.c (val_print_string): Likewise.
370 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-lazy-string.
371 (SUBDIR_PYTHON_SRCS): Likewise.
372 (py-lazy-string.o): New rule.
374 2010-01-13 Doug Evans <dje@google.com>
376 * mi/mi-main.c (list_available_thread_groups): Avoid "may be used
377 uninitialized" warning from gcc on local `tree'.
379 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
381 Implement core awareness.
383 * bcache.c (compare_ints): Remove
384 (print_percentage): Use compare_positive_ints.
385 * defs.h (compare_positive_ints): Declare.
386 * linux-nat.h (struct lin_lwp): New field core.
387 (linux_nat_core_of_thread_1): Declare.
388 * linux-nat.c (add_lwp): Init the 'core' field.
389 (linux_nat_wait_1): Record the core.
390 (linux_nat_core_of_thread_1, linux_nat_core_of_thread): New.
391 (linux_nat_add_target): Register the above.
392 * linux-thread-db.c (update_thread_core): New.
393 (thread_db_find_new_threads): Update core information for
395 * remote.c (struct private_thread_info): New.
396 (free_private_thread_info, demand_private_info): New.
397 (PACKET_qXfer_threads, use_osdata_threads): New.
398 (struct thread_item, threads_parsing_context
399 (start_thread, end_thread, thread_attributes)
400 (thread_children, threads_children, threads_elements): New.
401 (remote_threads_info): Try qXfer:threads before anything
403 (remote_protocol_packets): Register qXfer:threads.
404 (remote_open_1): Init use_osdata_threads.
405 (struct stop_reply): New field 'core'.
406 (remote_parse_stop_reply): Parse core number.
407 (process_stop_reply): Record core number.
408 (remote_xfer_partial): Handle qXfer:threads.
409 (remote_core_of_thread): New.
410 (init_remote_ops): Register remote_core_of_thread.
411 (_initialize_remote): Register qXfer:read.
412 * target.c (target_core_of_thread): New
413 * target.h (enum target_object): New value TARGET_OBJECT_THREADS.
414 (struct target_ops): New field to_core_of_threads.
415 (target_core_of_thread): Declare.
416 * gdbthread.h (struct thread_info): New field private_dtor.
417 * thread.c (print_thread_info): Report the core.
418 * ui-out.c (MAX_UI_OUT_LEVELS): Increase.
419 * utils.c (compare_positive_ints): New.
420 * features/threads.dtd: New.
421 * mi/mi-interp.c (mi_on_normal_stop): Report the core.
422 * mi/mi-main.c (struct collect_cores_data, collect_cores)
423 (do_nothing, free_vector_of_osdata_items)
424 (splay_tree_int_comparator, free_splay_tree): New.
425 (print_one_inferior_data): Implemented printing of selected
426 inferiors. Collect and print cores.
428 (mi_cmd_list_thread_groups): Support --recurse. Permit specifying
429 thread groups together with --available.
431 2010-01-12 Jan Kratochvil <jan.kratochvil@redhat.com>
433 * configure: Regenerate (for _STRUCTURED_PROC).
435 2010-01-12 Joel Brobecker <brobecker@adacore.com>
437 Delete dead function.
438 * ada-lang.c (extract_string): Delete. No longer used.
440 2010-01-12 Joel Brobecker <brobecker@adacore.com>
442 Fix -Wunused warning in dec-thread.c.
443 * dec-thread.c (dec_thread_count_gdb_threads)
444 (dec_thread_add_gdb_thread): Prevent -Wunused warning.
446 2010-01-12 Joel Brobecker <brobecker@adacore.com>
448 * ada-valprint.c (ada_print_floating): Remove trailing space.
450 2010-01-12 Joel Brobecker <brobecker@adacore.com>
452 Add support for DW_AT_GNAT_descriptive_type.
453 * gdbtypes.h (enum type_specific_kind): New enum.
454 (struct main_type) [type_specific_field]: New component.
455 [type_specific]: Add new component "gnat_stuff".
456 (struct gnat_aux_type): New type.
457 (INIT_CPLUS_SPECIFIC): Also set TYPE_SPECIFIC_FIELD (type).
458 (HAVE_CPLUS_STRUCT): Also check TYPE_SPECIFIC_FIELD (type).
459 (gnat_aux_default, allocate_gnat_aux_type): Add declaration.
460 (INIT_GNAT_SPECIFIC, ALLOCATE_GNAT_AUX_TYPE, HAVE_GNAT_AUX_INFO)
461 (TYPE_SPECIFIC_FIELD): New macros.
462 (TYPE_CPLUS_SPECIFIC): Return cplus_struct_default if the given
463 type does not hold any cplus-specific data.
464 (TYPE_RAW_CPLUS_SPECIFIC): New macro.
465 (TYPE_GNAT_SPECIFIC, TYPE_DESCRIPTIVE_TYPE): New macros.
466 (TYPE_IS_OPAQUE): Use HAVE_CPLUS_STRUCT to check if type has
468 * gdbtypes.c (allocate_cplus_struct_type): Minor stylistic rewrite.
469 Set new component TYPE_SPECIFIC_FIELD (type).
470 (gnat_aux_default): New constant.
471 (allocate_gnat_aux_type): New function.
472 (init_type): Add initialization the type-specific stuff for
473 TYPE_CODE_FLT and TYPE_CODE_FUNC types.
474 (print_gnat_stuff): New function.
475 (recursive_dump_type): Use HAVE_CPLUS_STRUCT to check for cplus-
476 specific data. Adjust code that prints the contents of the
477 type-specific union using the TYPE_SPECIFIC_FIELD value.
478 * dwarf2read.c (dwarf2_attach_fields_to_type): Do not allocate
479 the type cplus stuff for Ada types.
480 (dwarf2_add_member_fn, dwarf2_attach_fn_fields_to_type):
481 Error out if these routines are called with an Ada type.
482 (read_structure_type, read_array_type, read_subrange_type):
483 Add call to set_descriptive_type.
484 (set_die_type): Initialize the gnat-specific data if necessary.
485 (need_gnat_info, die_descriptive_type, set_descriptive_type):
487 * ada-lang.c (decode_constrained_packed_array_type): Use
488 decode_constrained_packed_array_type instead of doing a standard
489 lookup to locate a parallel type.
490 (find_parallel_type_by_descriptive_type): New function.
491 (ada_find_parallel_type_with_name): New function.
492 (ada_find_parallel_type): Reimplement using
493 ada_find_parallel_type_with_name.
494 * ada-valprint.c (print_field_values): Use HAVE_CPLUS_STRUCT
495 to check if type has a cplus stuff.
496 * linespec.c (total_number_of_methods): Likewise.
497 * mdebugread.c (new_type): Likewise.
499 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
501 * NEWS: Document the 0b binary number prefix parsing.
503 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
505 * objfiles.c (objfile_relocate1): Change the return type to int.
506 Describe the new return value. Return non-zero if data changed.
507 (objfile_relocate): New variable changed. Set it. Call
508 breakpoint_re_set depending on CHANGED.
510 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
512 Implement binary numbers parsing.
513 * c-exp.y (parse_number): New case 'b' and 'B'.
515 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
516 Tristan Gingold <gingold@adacore.com>
518 * solib.c (info_sharedlibrary_command): Replace
519 objfile_has_partial_symbols and objfile_has_full_symbols calls by
522 2010-01-10 Joel Brobecker <brobecker@adacore.com>
524 * NEWS: Document the improvements made to the mips-irix port.
526 2010-01-09 Joel Brobecker <brobecker@adacore.com>
528 Fix the documentation of valprint.c:value_print.
529 * valprint.c (value_print): Update the function description to
530 mention that the syntax of the output follows the current_language,
533 2010-01-09 Jan Kratochvil <jan.kratochvil@redhat.com>
535 Fix displacement of separate debug info files.
536 * objfiles.c (objfile_relocate): Rename to ...
537 (objfile_relocate1): ... here and make it static. Extend the comment.
538 (objfile_relocate): New function.
539 * solib-spu.c (spu_relocate_main_executable): Explicitly check if
540 SYMFILE_OBJFILE is NULL. Remove variables objfile and old_chain.
541 Remove following of SEPARATE_DEBUG_OBJFILE. new_offsets is now
542 allocated using alloca.
543 * symfile.c (copy_section_addr_info): Remove.
544 (build_section_addr_info_from_objfile): Make it global. New variables
545 addr_bit and mask, use them.
546 * symfile.h (build_section_addr_info_from_objfile): New prototype.
547 (copy_section_addr_info): Remove.
549 2010-01-09 Joel Brobecker <brobecker@adacore.com>
551 Signal unwinder for mips-irix N32.
552 * mips-irix-tdep.c: #include mips-tdep.h, trad-frame.h, and
554 (SIGTRAMP_FRAME_SIZE, SIGCONTEXT_PC_OFF, SIGCONTEXT_REGS_OFF)
555 (SIGCONTEXT_FPREGS_OFF, SIGCONTEXT_FPCSR_OFF, SIGCONTEXT_HI_OFF)
556 (SIGCONTEXT_LO_OFF): New macros.
557 (mips_irix_n32_tramp_frame_init): New function.
558 (mips_irix_n32_tramp_frame): New static constant.
559 (mips_irix_init_abi): Prepend the mips_irix_n32_tramp_frame unwinder.
561 2010-01-09 Joel Brobecker <brobecker@adacore.com>
563 Breakpoint in shared library does not work on mips-irix.
564 * procfs.c: #include "observer.h".
565 (procfs_inferior_created): New function, moving here the code
566 which unsets the syssgi syscall-exit notifications.
567 (procfs_create_inferior): Remove the code which unsets the syssgi
568 syscall-exit notifications. It is too early to do this here.
569 (_initialize_procfs): Attach the procfs_inferior_created observer.
571 2010-01-09 Joel Brobecker <brobecker@adacore.com>
573 Wrong return convention for arrays (mips-irix).
574 * mips-tdep.c (mips_n32n64_return_value): Arrays whose size is
575 128 bits or smaller are returned the same way as structs
576 and unions of the the same size.
578 2010-01-09 Joel Brobecker <brobecker@adacore.com>
580 Cannot set the PC on mips-irix.
581 * irix5-nat.c (fill_gregset): Check regno against the raw PC
582 register number, no the cooked one.
584 2010-01-09 Joel Brobecker <brobecker@adacore.com>
586 Error while loading core file on mips-irix.
587 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing
588 if debugging from a core file.
590 2010-01-09 Joel Brobecker <brobecker@adacore.com>
592 GDB hangs when attaching to process on mips-irix.
593 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing if
594 attaching to a process.
596 2010-01-09 Joel Brobecker <brobecker@adacore.com>
598 Use the correct breakpoint instruction on mips-irix.
599 * mips-tdep.c (mips_breakpoint_from_pc): Add new static variable
600 containing the correct breakpoint instruction to use on mips-irix.
601 Use it when the osabi is GDB_OSABI_IRIX.
603 2010-01-09 Joel Brobecker <brobecker@adacore.com>
605 -Wunused warning in procfs.c (mips-irix only).
606 * procfs.c (gdb_praddset, gdb_prdelset): New macros. Use them
607 throughout instead of using praddset and prdelset respectively.
609 2010-01-09 Joel Brobecker <brobecker@adacore.com>
611 GDB crash while stepping into function.
612 * infrun.c (handle_inferior_event): Refetch the current frame
613 after handling what.main_action, in case that pointer became
616 2010-01-09 Joel Brobecker <brobecker@adacore.com>
618 Fix build failure of solaris-hosted cross debuggers.
619 * ada-valprint.c, parse.c: Include defs.h before including ctype.h.
621 2010-01-09 Daniel Gutson <dgutson@codesourcery.com>
623 Fix build failure on sparc-solaris.
624 * procfs.c: (procfs_do_thread_registers) Use elfcore_write_lwpstatus.
626 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
628 Move some symfile code into subroutines.
629 * symfile.h (relative_addr_info_to_section_offsets)
630 (addr_info_make_relative): New prototypes.
631 * symfile.c (default_symfile_offsets): Move a part to ...
632 (relative_addr_info_to_section_offsets): ... this new function.
633 (default_symfile_offsets): Call it.
634 (syms_from_objfile <!mainline && addrs && addrs->other[0].name>): Move
636 (addr_info_make_relative): ... this new function.
638 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
640 Add from_tty to solib_create_inferior_hook.
641 * infcmd.c (post_create_inferior): Move solib_add after
642 solib_create_inferior_hook. Pass from_tty to
643 solib_create_inferior_hook. Call solib_add and SOLIB_ADD with
644 0 from_tty and comment why.
645 * infrun.c (follow_exec): Pass from_tty solib_create_inferior_hook as 0.
646 * linux-nat.c (linux_child_follow_fork): Likewise.
647 * nto-procfs.c (procfs_post_attach, procfs_create_inferior): Likewise.
648 * solib-darwin.c (darwin_solib_create_inferior_hook): New parameter
650 * solib-frv.c (frv_solib_create_inferior_hook): Likewise.
651 * solib-irix.c (irix_solib_create_inferior_hook): Likewise.
652 * solib-null.c (null_solib_create_inferior_hook): Likewise.
653 * solib-osf.c (osf_solib_create_inferior_hook): Likewise.
654 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
655 * solib-som.c (som_solib_create_inferior_hook): Likewise.
656 * solib-spu.c (spu_solib_create_inferior_hook): New parameter from_tty.
657 Pass it to svr4_so_ops.solib_create_inferior_hook.
658 * solib-sunos.c (sunos_solib_create_inferior_hook): New parameter
660 * solib-svr4.c (enable_break): New parameter from_tty. Pass it to
662 (svr4_solib_create_inferior_hook): New parameter from_tty. Pass it to
664 * solib-target.c (solib_target_solib_create_inferior_hook): New
666 * solib.c (solib_create_inferior_hook): New parameter from_tty. Pass
667 it to ops->solib_create_inferior_hook.
668 (reload_shared_libraries): Pass from_tty to solib_create_inferior_hook.
669 Move solib_add after solib_create_inferior_hook, call it now with
670 from_tty as 0. New comment there.
671 * solib.h (solib_create_inferior_hook): New parameter from_tty.
672 * solist.h (struct target_so_ops <solib_create_inferior_hook>):
675 2010-01-08 Vladimir Prus <vladimir@codesourcery.com>
678 * infrun.c (handle_inferior_event): Use get_thread_regcache
679 with events ptid, not get_current_regcache.
681 2009-01-08 Joel Brobecker <brobecker@adacore.com>
683 GDB crash with empty executable name (MinGW).
684 * source.c (openp): Add assert that parameter string is not NULL.
685 if parameter string is an empty string, then return with a failure
688 2009-01-08 Joel Brobecker <brobecker@adacore.com>
690 Get rid of support for VAX Floats.
691 * ada-lang.h (ada_is_vax_floating_type, ada_vax_float_type_suffix)
692 (ada_vax_float_print_function): Delete.
693 * ada-lang.c (ada_is_vax_floating_type, ada_vax_float_type_suffix)
694 (ada_vax_float_print_function): Delete.
695 * ada-typeprint.c (print_vax_floating_point_type): Delete.
696 (ada_print_type): Remove support for VAX floats.
697 * ada-valprint.c (ada_val_print_1): Remove support for VAX floats.
699 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
701 * stabsread.c (read_args): Handle zero arguments.
703 2009-01-08 Joel Brobecker <brobecker@adacore.com>
705 Cannot find in-tree libiconv.a after reconfigure.
706 * acinclude.m4 (AM_ICONV): If we find an in-tree libiconv.a
707 that we can use, then cache the path to this archive.
708 * configure: Regenerate.
710 2010-01-07 Stan Shebs <stan@codesourcery.com>
712 Make tracepoint operations go through target vector.
713 * target.h (enum trace_find_type): New enum.
714 (struct target_ops): New fields to_trace_init,
715 to_download_tracepoint, to_download_trace_state_variable,
716 to_trace_set_readonly_regions, to_trace_start, to_get_trace_status,
717 to_trace_stop, to_trace_find, to_get_trace_state_variable_value,
718 to_set_disconnected_tracing.
719 (target_trace_init): New macro.
720 (target_download_tracepoint): New macro.
721 (target_download_trace_state_variable): New macro.
722 (target_trace_start): New macro.
723 (target_trace_set_readonly_regions): New macro.
724 (target_get_trace_status): New macro.
725 (target_trace_stop): New macro.
726 (target_trace_find): New macro.
727 (target_get_trace_state_variable_value): New macro.
728 (target_set_disconnected_tracing): New macro.
729 * target.c (update_current_target): Inherit and set defaults for
730 tracepoint operations.
731 * tracepoint.c (default_collect): Make globally visible.
732 (target_is_remote): Remove, along with all calls.
733 (tvariables_info): Call target_get_trace_state_variable_value.
734 (remote_set_transparent_ranges): Remove.
735 (trace_start_command): Call target_trace_init,
736 target_download_tracepoint, etc.
737 (download_tracepoint): Remove.
738 (trace_stop_command): Simplify.
739 (stop_tracing): Call target_trace_stop.
740 (get_trace_status): Call target_get_trace_status.
741 (trace_status_command): Add case for targets that cannot trace.
742 (finish_tfind_command): Change to take numerical arguments, call
744 (trace_find_command): Update call to finish_tfind_command.
745 (trace_find_pc_command): Ditto.
746 (trace_find_tracepoint_command): Ditto.
747 (trace_find_line_command): Ditto.
748 (trace_find_range_command): Ditto.
749 (trace_find_outside_command): Ditto.
750 (set_disconnected_tracing_value): Call
751 target_set_disconnected_tracing.
752 * remote.c: Add protocol encoding bits from tracepoint.c.
753 (trace_error): Move from tracepoint.c.
754 (remote_get_noisy_reply): Ditto.
755 (free_actions_list_cleanup_wrapper): Ditto.
756 (free_actions_list): Ditto.
757 (remote_trace_init): New function.
758 (remote_download_tracepoint): New function.
759 (remote_download_trace_state_variable): New function.
760 (remote_trace_set_readonly_regions): New function.
761 (remote_trace_start): New function.
762 (remote_get_trace_status): New function.
763 (remote_trace_stop): New function.
764 (remote_trace_find): New function.
765 (remote_download_trace_state_variable): New function.
766 (remote_set_disconnected_tracing): New function.
767 (init_remote_ops): Add tracepoint operations.
769 * tracepoint.c (trace_dump_command): Don't decr_pc_after_break.
771 2010-01-07 Tristan Gingold <gingold@adacore.com>
773 * symfile.c (build_section_addr_info_from_objfile): New function.
774 (symbol_file_add_separate): Don't use offsets from objfile but
777 2010-01-06 Stan Shebs <stan@codesourcery.com>
779 Support disconnected tracing.
780 * infcmd.c (detach_command): Ask whether to stop tracing.
781 * cli/cli-cmds.c (quit_command): Ditto.
782 * breakpoint.h (struct breakpoint): New field number_on_target.
783 * breakpoint.c (create_tracepoint_from_upload): New function.
784 (get_tracepoint_by_number_on_target): New function.
785 * remote.c (struct remote): New field disconnected_tracing.
786 (remote_disconnected_tracing_feature): New function.
787 (remote_protocol_features): Add DisconnectedTracing.
788 (struct uploaded_tp): New struct.
789 (uploaded_tps): New global.
790 (get_uploaded_tp): New function.
791 (find_matching_tracepoint): New function.
792 (remote_get_tracing_state): New function.
793 (remote_start_remote): Call it.
794 * tracepoint.c (disconnected_tracing): New global.
795 (trace_start_command): Initialize number_on_target.
796 (stop_tracing): New function, split out from...
797 (trace_stop_command): Call stop_tracing.
798 (get_trace_status): New function, split out from...
799 (trace_status_command): Call get_trace_status, add info on
800 disconnection behavior.
801 (disconnect_or_stop_tracing): New function.
802 (finish_tfind_command): Translate from number on target.
803 (trace_find_tracepoint_command): Translate to number on target.
804 (send_disconnected_tracing_value): New function.
805 (set_disconnected_tracing): New function.
806 (_initialize_tracepoint): Add disconnected-tracing variable.
807 * NEWS: Mention disconnected tracing.
809 2010-01-06 Tristan Gingold <gingold@adacore.com>
811 * symtab.c (lookup_global_symbol_from_objfile): Rename objfile
812 parameter to main_objfile. Iterate on all separate debug objfiles.
813 * symfile.h (symbol_file_add_separate)
814 (find_separate_debug_file_by_debuglink): Remove parameter names.
815 * symfile.c (symbol_file_add_separate): Use add_separate_objfile.
816 (reread_symbols): Use free_objfile_separate_debug.
817 * objfiles.h (struct objfile): Add separate_debug_objfile_link.
819 (objfile_separate_debug_iterate, add_separate_debug_objfile)
820 (free_objfile_separate_debug): New prototypes.
821 * objfiles.c (objfile_separate_debug_iterate): New function.
822 (add_separate_debug_objfile, free_objfile_separate_debug): New
824 (free_objfile): Use free_objfile_separate_debug. Adjust for
825 multiple separate debug objfile.
826 (objfile_has_symbols): Adjust comment. Iterate on all separate
828 * minsyms.c (lookup_minimal_symbol): Adjust for multiple separate
830 (lookup_minimal_symbol_text): Ditto.
831 (lookup_minimal_symbol_by_pc_name): Ditto.
832 (lookup_minimal_symbol_solib_trampoline): Ditto.
833 (lookup_minimal_symbol_by_pc_section_1): Iterate on all separate
836 2010-01-05 Stan Shebs <stan@codesourcery.com>
838 Add fast tracepoints.
839 * arch-utils.h (default_fast_tracepoint_valid_at): Declare.
840 * arch-utils.c (default_fast_tracepoint_valid_at): New function.
841 * breakpoint.h (enum bptype): Add bp_fast_tracepoint.
842 * breakpoint.c (tracepoint_type): New function.
843 (ALL_TRACEPOINTS): Use it.
844 (should_be_inserted): Ditto.
845 (bpstat_check_location): Ditto.
846 (print_one_breakpoint_location): Ditto.
847 (user_settable_breakpoint): Ditto.
848 (set_breakpoint_location_function): Ditto.
849 (disable_breakpoints_in_shlibs): Ditto.
850 (delete_trace_command): Ditto.
851 (print_it_typical): Add bp_fast_tracepoint case.
852 (bpstat_what): Ditto.
853 (print_one_breakpoint_location): Ditto.
854 (allocate_bp_location): Ditto.
856 (breakpoint_re_set_one): Ditto.
857 (disable_command): Ditto.
858 (enable_command): Ditto.
859 (check_fast_tracepoint_sals): New function.
860 (break_command_really): Call it.
861 (ftrace_command): New function.
862 (_initialize_breakpoint): Add ftrace command.
863 * gdbarch.sh (fast_tracepoint_valid_at): New.
864 * gdbarch.h, gdbarch.c: Regenerate.
865 * i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
866 (i386_gdbarch_init): Use it.
867 * remote.c (struct remote_state): New field fast_tracepoints.
868 (PACKET_FastTracepoints): New packet config type.
869 (remote_fast_tracepoint_feature): New function.
870 (remote_protocol_features): Add FastTracepoints.
871 (remote_supports_fast_tracepoints): New function.
872 (_initialize_remote): Add FastTracepoints.
873 * tracepoint.c (download_tracepoint): Add fast tracepoint option.
874 * NEWS: Mention fast tracepoints.
876 2010-01-06 Joel Brobecker <brobecker@adacore.com>
878 * gdb-gdb.py: New file.
880 2010-01-05 Michael Snyder <msnyder@vmware.com>
882 * infrun.c (handle_inferior_event): Fix typo in comment.
884 2010-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
886 * symfile.c (syms_from_objfile): Remove the !MAINLINE conditional.
888 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
890 * features/Makefile (WHICH): Add s390-linux32, s390-linux64,
892 (s390-linux32-expedite): Define.
893 (s390-linux64-expedite): Define.
894 (s390x-linux64-expedite): Define.
895 * features/s390-acr.xml: New file.
896 * features/s390-fpr.xml: New file.
897 * features/s390-core32.xml: New file.
898 * features/s390-core64.xml: New file.
899 * features/s390x-core64.xml: New file.
900 * features/s390-linux32.xml: New file.
901 * features/s390-linux64.xml: New file.
902 * features/s390x-linux64.xml: New file.
903 * features/s390-linux32.c: New generated file.
904 * features/s390-linux64.c: New generated file.
905 * features/s390x-linux64.c: New generated file.
907 * regformats/s390-linux32.dat: New generated file.
908 * regformats/s390-linux64.dat: New generated file.
909 * regformats/s390x-linux64.dat: New generated file.
910 * regformats/reg-s390.dat: Remove.
911 * regformats/reg-s390x.dat: Remove.
913 * s390-nat.c: Include "auxv.h" and <elf.h>.
914 (HWCAP_S390_HIGH_GPRS): Define if undefined.
915 (s390_target_wordsize): New function.
916 (s390_auxv_parse): Likewise.
917 (s390_get_hwcap): Likewise.
918 (s390_read_description): Likewise.
919 (_initialize_s390_nat): Install s390_auxv_parse and
920 s390_read_description.
922 * s390-tdep.c: Include "features/s390-linux32.c",
923 "features/s390-linux64.c", and "features/s390x-linux64.c".
924 (struct gdbarch_tdep): Add gpr_full_regnum, pc_regnum, and cc_regnum.
925 (s390_register_call_saved): New function.
926 (s390_register_name): Remove.
927 (s390_register_type): Remove.
928 (s390_dwarf_regmap): Add lower half GPR pseudo DWARF CFI regnums.
929 (s390_dwarf_reg_to_regnum): Remap GPR regnums to full GPRs.
930 (s390_adjust_frame_regnum): Remap GPR regnums to lower halves for CFI.
931 (s390_pseudo_register_name): New function.
932 (s390_pseudo_register_type): New function.
933 (s390_pseudo_register_read): Handle both 32-bit and 64-bit cases.
934 Handle full GPR pesudos and varying pseudo register numbers.
935 (s390_pseudo_register_write): Likewise
936 (s390x_pseudo_register_read): Remove.
937 (s390x_pseudo_register_write): Likewise.
938 (s390_register_group): Remove.
939 (s390_pseudo_register_group): New function.
940 (s390_regmap_gregset): Add GPR upper halves.
941 (s390x_regmap_gregset): Likewise.
942 (s390_regmap_fpregset): Likewise.
943 (s390_regmap_upper): New global variable.
944 (s390_upper_regset): New global variable.
945 (s390_upper_regset_sections): New global variable.
946 (s390_regset_from_core_section): Handle GPR upper halves.
947 (s390_core_read_description): New function.
948 (s390_prologue_frame_unwind_cache): Set up ABI call-saved/clobbered
949 register information. Handle varying pseudo register numbers.
950 (s390_backchain_frame_unwind_cache): Likewise.
951 (s390_frame_prev_register): Unwind full GPRs to show lower halves.
952 (s390_stub_frame_unwind_cache): Handle varying pseudo register numbers.
953 (s390_sigtramp_frame_unwind_cache): Unwind PSWM and PSWA as well as
954 PC and CC pseudos. Unwind upper halves and full GPRs as appropriate.
955 Handle varying pseudo register numbers.
956 (s390_unwind_pc): Handle varying pseudo register numbers.
957 (s390_dwarf2_prev_register): New function.
958 (s390_dwarf2_frame_init_reg): Set up ABI call-saved/clobbered
959 register information. Handle varying pseudo register numbers.
960 Install s390_dwarf2_prev_register to unwind full GPRs.
961 (s390_gdbarch_init): Handle target descriptions. Assign varying
962 pseudo register numbers. Install s390_adjust_frame_regnum.
963 (_initialize_s390_tdep): Initialize target descriptions.
965 * s390-tdep.h (S390_R0_UPPER_REGNUM .. S390_R15_UPPER_REGNUM): Define.
966 (S390_NUM_REGS): Redefine to include upper half registers.
967 (S390_PC_REGNUM, S390_CC_REGNUM): Remove.
968 (S390_NUM_PSEUDO_REGS, S390_NUM_TOTAL_REGS): Likewise.
969 (tdesc_s390_linux32): Add declaration.
970 (tdesc_s390_linux64): Likewise.
971 (tdesc_s390x_linux64): Likewise.
973 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
975 * regset.h (struct core_regset_section): Add HUMAN_NAME.
976 * i386-linux-tdep.c (i386_linux_regset_sections): Fill in HUMAN_NAME.
977 * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections): Likewise.
978 (ppc_linux_vmx_regset_sections): Likewise.
979 (ppc_linux_fp_regset_sections): Likewise.
981 * corelow.c (get_core_register_section): Constify arguments.
982 (get_core_registers): Use gdbarch_core_regset_sections instead
983 of hard-coded platform-specific register section names.
985 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
987 * dwarf2loc.c (read_pieced_value): If a piece occupies part of
988 a register, assume the least-significant part is used.
989 (write_pieced_value): Likewise.
991 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
993 * printcmd.c: Include "arch-utils.h".
994 (do_one_display): Re-parse expression if current architecture changed.
996 2010-01-03 Jan Kratochvil <jan.kratochvil@redhat.com>
997 Joel Brobecker <brobecker@adacore.com>
999 * gdbtypes.c (check_typedef): New comment on type length.
1000 * value.c (allocate_value_lazy): Remove the unused atype variable. New
1001 comment on type length.
1002 (value_primitive_field): Keep the original TYPE value, new comment.
1004 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1006 * cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
1007 p_start. Change != comparisons to > and < comparisons.
1009 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1011 * cli/cli-script.c (process_next_line): Check P2 overrun.
1013 2009-01-01 Joel Brobecker <brobecker@adacore.com>
1015 Update the copyright hearder to add year 2010 for most GDB files.
1017 2009-01-01 Joel Brobecker <brobecker@adacore.com>
1019 Fix build failure in inf-ptrace.c.
1020 * inf-ptrace.c (inf_ptrace_follow_fork): Fix typo.
1022 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1024 * top.c (print_gdb_version): Update copyright year.
1026 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1028 Fix break *FUN'address thread NUM.
1029 * ada-lex.l (task): Expand rule to also match the thread keyword.
1031 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1033 Fix break *FUN'address task NUM.
1034 * ada-lex.l (task): New rule.
1035 * ada-lang.c (valid_task_id): Make sure the Ada task list has
1036 been built before using it.
1038 For older changes see ChangeLog-2009.
1044 version-control: never