Error while loading core file on mips-irix.
[binutils-gdb.git] / gdb / ChangeLog
1 2010-01-09 Joel Brobecker <brobecker@adacore.com>
2
3 Error while loading core file on mips-irix.
4 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing
5 if debugging from a core file.
6
7 2010-01-09 Joel Brobecker <brobecker@adacore.com>
8
9 GDB hangs when attaching to process on mips-irix.
10 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing if
11 attaching to a process.
12
13 2010-01-09 Joel Brobecker <brobecker@adacore.com>
14
15 Use the correct breakpoint instruction on mips-irix.
16 * mips-tdep.c (mips_breakpoint_from_pc): Add new static variable
17 containing the correct breakpoint instruction to use on mips-irix.
18 Use it when the osabi is GDB_OSABI_IRIX.
19
20 2010-01-09 Joel Brobecker <brobecker@adacore.com>
21
22 -Wunused warning in procfs.c (mips-irix only).
23 * procfs.c (gdb_praddset, gdb_prdelset): New macros. Use them
24 throughout instead of using praddset and prdelset respectively.
25
26 2010-01-09 Joel Brobecker <brobecker@adacore.com>
27
28 GDB crash while stepping into function.
29 * infrun.c (handle_inferior_event): Refetch the current frame
30 after handling what.main_action, in case that pointer became
31 dangling.
32
33 2010-01-09 Joel Brobecker <brobecker@adacore.com>
34
35 Fix build failure of solaris-hosted cross debuggers.
36 * ada-valprint.c, parse.c: Include defs.h before including ctype.h.
37
38 2010-01-09 Joel Brobecker <brobecker@adacore.com>
39
40 Fix build failure on sparc-solaris.
41 * procfs.c: (procfs_do_thread_registers) Use elfcore_write_lwpstatus.
42
43 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
44
45 Move some symfile code into subroutines.
46 * symfile.h (relative_addr_info_to_section_offsets)
47 (addr_info_make_relative): New prototypes.
48 * symfile.c (default_symfile_offsets): Move a part to ...
49 (relative_addr_info_to_section_offsets): ... this new function.
50 (default_symfile_offsets): Call it.
51 (syms_from_objfile <!mainline && addrs && addrs->other[0].name>): Move
52 this part to ...
53 (addr_info_make_relative): ... this new function.
54
55 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
56
57 Add from_tty to solib_create_inferior_hook.
58 * infcmd.c (post_create_inferior): Move solib_add after
59 solib_create_inferior_hook. Pass from_tty to
60 solib_create_inferior_hook. Call solib_add and SOLIB_ADD with
61 0 from_tty and comment why.
62 * infrun.c (follow_exec): Pass from_tty solib_create_inferior_hook as 0.
63 * linux-nat.c (linux_child_follow_fork): Likewise.
64 * nto-procfs.c (procfs_post_attach, procfs_create_inferior): Likewise.
65 * solib-darwin.c (darwin_solib_create_inferior_hook): New parameter
66 from_tty.
67 * solib-frv.c (frv_solib_create_inferior_hook): Likewise.
68 * solib-irix.c (irix_solib_create_inferior_hook): Likewise.
69 * solib-null.c (null_solib_create_inferior_hook): Likewise.
70 * solib-osf.c (osf_solib_create_inferior_hook): Likewise.
71 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
72 * solib-som.c (som_solib_create_inferior_hook): Likewise.
73 * solib-spu.c (spu_solib_create_inferior_hook): New parameter from_tty.
74 Pass it to svr4_so_ops.solib_create_inferior_hook.
75 * solib-sunos.c (sunos_solib_create_inferior_hook): New parameter
76 from_tty.
77 * solib-svr4.c (enable_break): New parameter from_tty. Pass it to
78 solib_add.
79 (svr4_solib_create_inferior_hook): New parameter from_tty. Pass it to
80 enable_break.
81 * solib-target.c (solib_target_solib_create_inferior_hook): New
82 parameter from_tty.
83 * solib.c (solib_create_inferior_hook): New parameter from_tty. Pass
84 it to ops->solib_create_inferior_hook.
85 (reload_shared_libraries): Pass from_tty to solib_create_inferior_hook.
86 Move solib_add after solib_create_inferior_hook, call it now with
87 from_tty as 0. New comment there.
88 * solib.h (solib_create_inferior_hook): New parameter from_tty.
89 * solist.h (struct target_so_ops <solib_create_inferior_hook>):
90 Likewise.
91
92 2010-01-08 Vladimir Prus <vladimir@codesourcery.com>
93
94 Fix multiexec race.
95 * infrun.c (handle_inferior_event): Use get_thread_regcache
96 with events ptid, not get_current_regcache.
97
98 2009-01-08 Joel Brobecker <brobecker@adacore.com>
99
100 GDB crash with empty executable name (MinGW).
101 * source.c (openp): Add assert that parameter string is not NULL.
102 if parameter string is an empty string, then return with a failure
103 immediately.
104
105 2009-01-08 Joel Brobecker <brobecker@adacore.com>
106
107 Get rid of support for VAX Floats.
108 * ada-lang.h (ada_is_vax_floating_type, ada_vax_float_type_suffix)
109 (ada_vax_float_print_function): Delete.
110 * ada-lang.c (ada_is_vax_floating_type, ada_vax_float_type_suffix)
111 (ada_vax_float_print_function): Delete.
112 * ada-typeprint.c (print_vax_floating_point_type): Delete.
113 (ada_print_type): Remove support for VAX floats.
114 * ada-valprint.c (ada_val_print_1): Remove support for VAX floats.
115
116 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
117
118 * stabsread.c (read_args): Handle zero arguments.
119
120 2009-01-08 Joel Brobecker <brobecker@adacore.com>
121
122 Cannot find in-tree libiconv.a after reconfigure.
123 * acinclude.m4 (AM_ICONV): If we find an in-tree libiconv.a
124 that we can use, then cache the path to this archive.
125 * configure: Regenerate.
126
127 2010-01-07 Stan Shebs <stan@codesourcery.com>
128
129 Make tracepoint operations go through target vector.
130 * target.h (enum trace_find_type): New enum.
131 (struct target_ops): New fields to_trace_init,
132 to_download_tracepoint, to_download_trace_state_variable,
133 to_trace_set_readonly_regions, to_trace_start, to_get_trace_status,
134 to_trace_stop, to_trace_find, to_get_trace_state_variable_value,
135 to_set_disconnected_tracing.
136 (target_trace_init): New macro.
137 (target_download_tracepoint): New macro.
138 (target_download_trace_state_variable): New macro.
139 (target_trace_start): New macro.
140 (target_trace_set_readonly_regions): New macro.
141 (target_get_trace_status): New macro.
142 (target_trace_stop): New macro.
143 (target_trace_find): New macro.
144 (target_get_trace_state_variable_value): New macro.
145 (target_set_disconnected_tracing): New macro.
146 * target.c (update_current_target): Inherit and set defaults for
147 tracepoint operations.
148 * tracepoint.c (default_collect): Make globally visible.
149 (target_is_remote): Remove, along with all calls.
150 (tvariables_info): Call target_get_trace_state_variable_value.
151 (remote_set_transparent_ranges): Remove.
152 (trace_start_command): Call target_trace_init,
153 target_download_tracepoint, etc.
154 (download_tracepoint): Remove.
155 (trace_stop_command): Simplify.
156 (stop_tracing): Call target_trace_stop.
157 (get_trace_status): Call target_get_trace_status.
158 (trace_status_command): Add case for targets that cannot trace.
159 (finish_tfind_command): Change to take numerical arguments, call
160 target_trace_find.
161 (trace_find_command): Update call to finish_tfind_command.
162 (trace_find_pc_command): Ditto.
163 (trace_find_tracepoint_command): Ditto.
164 (trace_find_line_command): Ditto.
165 (trace_find_range_command): Ditto.
166 (trace_find_outside_command): Ditto.
167 (set_disconnected_tracing_value): Call
168 target_set_disconnected_tracing.
169 * remote.c: Add protocol encoding bits from tracepoint.c.
170 (trace_error): Move from tracepoint.c.
171 (remote_get_noisy_reply): Ditto.
172 (free_actions_list_cleanup_wrapper): Ditto.
173 (free_actions_list): Ditto.
174 (remote_trace_init): New function.
175 (remote_download_tracepoint): New function.
176 (remote_download_trace_state_variable): New function.
177 (remote_trace_set_readonly_regions): New function.
178 (remote_trace_start): New function.
179 (remote_get_trace_status): New function.
180 (remote_trace_stop): New function.
181 (remote_trace_find): New function.
182 (remote_download_trace_state_variable): New function.
183 (remote_set_disconnected_tracing): New function.
184 (init_remote_ops): Add tracepoint operations.
185
186 * tracepoint.c (trace_dump_command): Don't decr_pc_after_break.
187
188 2010-01-07 Tristan Gingold <gingold@adacore.com>
189
190 * symfile.c (build_section_addr_info_from_objfile): New function.
191 (symbol_file_add_separate): Don't use offsets from objfile but
192 built an addr info.
193
194 2010-01-06 Stan Shebs <stan@codesourcery.com>
195
196 Support disconnected tracing.
197 * infcmd.c (detach_command): Ask whether to stop tracing.
198 * cli/cli-cmds.c (quit_command): Ditto.
199 * breakpoint.h (struct breakpoint): New field number_on_target.
200 * breakpoint.c (create_tracepoint_from_upload): New function.
201 (get_tracepoint_by_number_on_target): New function.
202 * remote.c (struct remote): New field disconnected_tracing.
203 (remote_disconnected_tracing_feature): New function.
204 (remote_protocol_features): Add DisconnectedTracing.
205 (struct uploaded_tp): New struct.
206 (uploaded_tps): New global.
207 (get_uploaded_tp): New function.
208 (find_matching_tracepoint): New function.
209 (remote_get_tracing_state): New function.
210 (remote_start_remote): Call it.
211 * tracepoint.c (disconnected_tracing): New global.
212 (trace_start_command): Initialize number_on_target.
213 (stop_tracing): New function, split out from...
214 (trace_stop_command): Call stop_tracing.
215 (get_trace_status): New function, split out from...
216 (trace_status_command): Call get_trace_status, add info on
217 disconnection behavior.
218 (disconnect_or_stop_tracing): New function.
219 (finish_tfind_command): Translate from number on target.
220 (trace_find_tracepoint_command): Translate to number on target.
221 (send_disconnected_tracing_value): New function.
222 (set_disconnected_tracing): New function.
223 (_initialize_tracepoint): Add disconnected-tracing variable.
224 * NEWS: Mention disconnected tracing.
225
226 2010-01-06 Tristan Gingold <gingold@adacore.com>
227
228 * symtab.c (lookup_global_symbol_from_objfile): Rename objfile
229 parameter to main_objfile. Iterate on all separate debug objfiles.
230 * symfile.h (symbol_file_add_separate)
231 (find_separate_debug_file_by_debuglink): Remove parameter names.
232 * symfile.c (symbol_file_add_separate): Use add_separate_objfile.
233 (reread_symbols): Use free_objfile_separate_debug.
234 * objfiles.h (struct objfile): Add separate_debug_objfile_link.
235 Adjust comment.
236 (objfile_separate_debug_iterate, add_separate_debug_objfile)
237 (free_objfile_separate_debug): New prototypes.
238 * objfiles.c (objfile_separate_debug_iterate): New function.
239 (add_separate_debug_objfile, free_objfile_separate_debug): New
240 functions.
241 (free_objfile): Use free_objfile_separate_debug. Adjust for
242 multiple separate debug objfile.
243 (objfile_has_symbols): Adjust comment. Iterate on all separate
244 debug objfiles.
245 * minsyms.c (lookup_minimal_symbol): Adjust for multiple separate
246 debug objfile.
247 (lookup_minimal_symbol_text): Ditto.
248 (lookup_minimal_symbol_by_pc_name): Ditto.
249 (lookup_minimal_symbol_solib_trampoline): Ditto.
250 (lookup_minimal_symbol_by_pc_section_1): Iterate on all separate
251 debug objfiles.
252
253 2010-01-05 Stan Shebs <stan@codesourcery.com>
254
255 Add fast tracepoints.
256 * arch-utils.h (default_fast_tracepoint_valid_at): Declare.
257 * arch-utils.c (default_fast_tracepoint_valid_at): New function.
258 * breakpoint.h (enum bptype): Add bp_fast_tracepoint.
259 * breakpoint.c (tracepoint_type): New function.
260 (ALL_TRACEPOINTS): Use it.
261 (should_be_inserted): Ditto.
262 (bpstat_check_location): Ditto.
263 (print_one_breakpoint_location): Ditto.
264 (user_settable_breakpoint): Ditto.
265 (set_breakpoint_location_function): Ditto.
266 (disable_breakpoints_in_shlibs): Ditto.
267 (delete_trace_command): Ditto.
268 (print_it_typical): Add bp_fast_tracepoint case.
269 (bpstat_what): Ditto.
270 (print_one_breakpoint_location): Ditto.
271 (allocate_bp_location): Ditto.
272 (mention): Ditto.
273 (breakpoint_re_set_one): Ditto.
274 (disable_command): Ditto.
275 (enable_command): Ditto.
276 (check_fast_tracepoint_sals): New function.
277 (break_command_really): Call it.
278 (ftrace_command): New function.
279 (_initialize_breakpoint): Add ftrace command.
280 * gdbarch.sh (fast_tracepoint_valid_at): New.
281 * gdbarch.h, gdbarch.c: Regenerate.
282 * i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
283 (i386_gdbarch_init): Use it.
284 * remote.c (struct remote_state): New field fast_tracepoints.
285 (PACKET_FastTracepoints): New packet config type.
286 (remote_fast_tracepoint_feature): New function.
287 (remote_protocol_features): Add FastTracepoints.
288 (remote_supports_fast_tracepoints): New function.
289 (_initialize_remote): Add FastTracepoints.
290 * tracepoint.c (download_tracepoint): Add fast tracepoint option.
291 * NEWS: Mention fast tracepoints.
292
293 2010-01-06 Joel Brobecker <brobecker@adacore.com>
294
295 * gdb-gdb.py: New file.
296
297 2010-01-05 Michael Snyder <msnyder@vmware.com>
298
299 * infrun.c (handle_inferior_event): Fix typo in comment.
300
301 2010-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
302
303 * symfile.c (syms_from_objfile): Remove the !MAINLINE conditional.
304
305 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
306
307 * features/Makefile (WHICH): Add s390-linux32, s390-linux64,
308 and s390x-linux64.
309 (s390-linux32-expedite): Define.
310 (s390-linux64-expedite): Define.
311 (s390x-linux64-expedite): Define.
312 * features/s390-acr.xml: New file.
313 * features/s390-fpr.xml: New file.
314 * features/s390-core32.xml: New file.
315 * features/s390-core64.xml: New file.
316 * features/s390x-core64.xml: New file.
317 * features/s390-linux32.xml: New file.
318 * features/s390-linux64.xml: New file.
319 * features/s390x-linux64.xml: New file.
320 * features/s390-linux32.c: New generated file.
321 * features/s390-linux64.c: New generated file.
322 * features/s390x-linux64.c: New generated file.
323
324 * regformats/s390-linux32.dat: New generated file.
325 * regformats/s390-linux64.dat: New generated file.
326 * regformats/s390x-linux64.dat: New generated file.
327 * regformats/reg-s390.dat: Remove.
328 * regformats/reg-s390x.dat: Remove.
329
330 * s390-nat.c: Include "auxv.h" and <elf.h>.
331 (HWCAP_S390_HIGH_GPRS): Define if undefined.
332 (s390_target_wordsize): New function.
333 (s390_auxv_parse): Likewise.
334 (s390_get_hwcap): Likewise.
335 (s390_read_description): Likewise.
336 (_initialize_s390_nat): Install s390_auxv_parse and
337 s390_read_description.
338
339 * s390-tdep.c: Include "features/s390-linux32.c",
340 "features/s390-linux64.c", and "features/s390x-linux64.c".
341 (struct gdbarch_tdep): Add gpr_full_regnum, pc_regnum, and cc_regnum.
342 (s390_register_call_saved): New function.
343 (s390_register_name): Remove.
344 (s390_register_type): Remove.
345 (s390_dwarf_regmap): Add lower half GPR pseudo DWARF CFI regnums.
346 (s390_dwarf_reg_to_regnum): Remap GPR regnums to full GPRs.
347 (s390_adjust_frame_regnum): Remap GPR regnums to lower halves for CFI.
348 (s390_pseudo_register_name): New function.
349 (s390_pseudo_register_type): New function.
350 (s390_pseudo_register_read): Handle both 32-bit and 64-bit cases.
351 Handle full GPR pesudos and varying pseudo register numbers.
352 (s390_pseudo_register_write): Likewise
353 (s390x_pseudo_register_read): Remove.
354 (s390x_pseudo_register_write): Likewise.
355 (s390_register_group): Remove.
356 (s390_pseudo_register_group): New function.
357 (s390_regmap_gregset): Add GPR upper halves.
358 (s390x_regmap_gregset): Likewise.
359 (s390_regmap_fpregset): Likewise.
360 (s390_regmap_upper): New global variable.
361 (s390_upper_regset): New global variable.
362 (s390_upper_regset_sections): New global variable.
363 (s390_regset_from_core_section): Handle GPR upper halves.
364 (s390_core_read_description): New function.
365 (s390_prologue_frame_unwind_cache): Set up ABI call-saved/clobbered
366 register information. Handle varying pseudo register numbers.
367 (s390_backchain_frame_unwind_cache): Likewise.
368 (s390_frame_prev_register): Unwind full GPRs to show lower halves.
369 (s390_stub_frame_unwind_cache): Handle varying pseudo register numbers.
370 (s390_sigtramp_frame_unwind_cache): Unwind PSWM and PSWA as well as
371 PC and CC pseudos. Unwind upper halves and full GPRs as appropriate.
372 Handle varying pseudo register numbers.
373 (s390_unwind_pc): Handle varying pseudo register numbers.
374 (s390_dwarf2_prev_register): New function.
375 (s390_dwarf2_frame_init_reg): Set up ABI call-saved/clobbered
376 register information. Handle varying pseudo register numbers.
377 Install s390_dwarf2_prev_register to unwind full GPRs.
378 (s390_gdbarch_init): Handle target descriptions. Assign varying
379 pseudo register numbers. Install s390_adjust_frame_regnum.
380 (_initialize_s390_tdep): Initialize target descriptions.
381
382 * s390-tdep.h (S390_R0_UPPER_REGNUM .. S390_R15_UPPER_REGNUM): Define.
383 (S390_NUM_REGS): Redefine to include upper half registers.
384 (S390_PC_REGNUM, S390_CC_REGNUM): Remove.
385 (S390_NUM_PSEUDO_REGS, S390_NUM_TOTAL_REGS): Likewise.
386 (tdesc_s390_linux32): Add declaration.
387 (tdesc_s390_linux64): Likewise.
388 (tdesc_s390x_linux64): Likewise.
389
390 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
391
392 * regset.h (struct core_regset_section): Add HUMAN_NAME.
393 * i386-linux-tdep.c (i386_linux_regset_sections): Fill in HUMAN_NAME.
394 * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections): Likewise.
395 (ppc_linux_vmx_regset_sections): Likewise.
396 (ppc_linux_fp_regset_sections): Likewise.
397
398 * corelow.c (get_core_register_section): Constify arguments.
399 (get_core_registers): Use gdbarch_core_regset_sections instead
400 of hard-coded platform-specific register section names.
401
402 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
403
404 * dwarf2loc.c (read_pieced_value): If a piece occupies part of
405 a register, assume the least-significant part is used.
406 (write_pieced_value): Likewise.
407
408 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
409
410 * printcmd.c: Include "arch-utils.h".
411 (do_one_display): Re-parse expression if current architecture changed.
412
413 2010-01-03 Jan Kratochvil <jan.kratochvil@redhat.com>
414 Joel Brobecker <brobecker@adacore.com>
415
416 * gdbtypes.c (check_typedef): New comment on type length.
417 * value.c (allocate_value_lazy): Remove the unused atype variable. New
418 comment on type length.
419 (value_primitive_field): Keep the original TYPE value, new comment.
420
421 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
422
423 * cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
424 p_start. Change != comparisons to > and < comparisons.
425
426 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
427
428 * cli/cli-script.c (process_next_line): Check P2 overrun.
429
430 2009-01-01 Joel Brobecker <brobecker@adacore.com>
431
432 Update the copyright hearder to add year 2010 for most GDB files.
433
434 2009-01-01 Joel Brobecker <brobecker@adacore.com>
435
436 Fix build failure in inf-ptrace.c.
437 * inf-ptrace.c (inf_ptrace_follow_fork): Fix typo.
438
439 2010-01-01 Joel Brobecker <brobecker@adacore.com>
440
441 * top.c (print_gdb_version): Update copyright year.
442
443 2010-01-01 Joel Brobecker <brobecker@adacore.com>
444
445 Fix break *FUN'address thread NUM.
446 * ada-lex.l (task): Expand rule to also match the thread keyword.
447
448 2010-01-01 Joel Brobecker <brobecker@adacore.com>
449
450 Fix break *FUN'address task NUM.
451 * ada-lex.l (task): New rule.
452 * ada-lang.c (valid_task_id): Make sure the Ada task list has
453 been built before using it.
454
455 For older changes see ChangeLog-2009.
456 \f
457 Local Variables:
458 mode: change-log
459 left-margin: 8
460 fill-column: 74
461 version-control: never
462 coding: utf-8
463 End: