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