]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
* procfs.c (proc_set_current_signal): Populate mysinfo before
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
73930d4d
KH
12009-07-31 Kazu Hirata <kazu@codesourcery.com>
2
3 * procfs.c (proc_set_current_signal): Populate mysinfo before
4 copying it to arg.
5 (proc_clear_current_signal): Likewise.
6 (proc_set_watchpoint): Populate pwatch before copying it to arg.
7
1f4437a4
MS
82009-07-31 Michael Snyder <msnyder@vmware.com>
9
10 * remote.c (store_register_using_P): Call putpkt and getpkt
11 directly instead of calling remote_send.
27a9c0bf
MS
12 (store_registers_using_G): Ditto.
13 (fetch_register_using_p): Ditto.
14
15 * remote.c (store_register_using_P): Make error msg more verbose.
16 (store_registers_using_G): Ditto.
1f4437a4
MS
17 (fetch_register_using_p): Ditto.
18
ff1a52c6
UW
192009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
20
21 * spu-tdep.c: Include "infcall.h".
22 (spu_address_class_type_flags): New function.
23 (spu_address_class_type_flags_to_name): Likewise.
24 (spu_address_class_name_to_type_flags): Likewise.
25 (spu_pointer_to_address): Handle __ea pointers.
26 (spu_auto_flush_cache_p): New static variable.
27 (spu_objfile_from_frame): New function.
28 (flush_ea_cache, spu_attach_normal_stop): Likewise.
29 (show_spu_auto_flush_cache): Likewise.
30 (spu_gdbarch_init): Install address class handlers.
31 (_initialize_spu_tdep): Attach to normal_stop observer.
32 Install "set spu auto-flush-cache" / "show spu auto-flush-cache"
33 commands.
34
35 * NEWS: Mention "set/show spu auto-flush-cache" commands.
36
3285f3fe
UW
372009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
38
39 * spu-tdep.c: Include "block.h".
40 (setspucmdlist, showspucmdlist): New static variables.
41 (spu_stop_on_load_p): Likewise.
42 (spu_catch_start): New function.
43 (show_spu_command, set_spu_command): New functions.
44 (show_spu_stop_on_load): Likewise.
45 (_initialize_spu_tdep): Attach spu_catch_start to new_objfile observer.
46 Install "set spu" / "show spu" prefix command handler.
47 Install "set spu stop-on-load" / "show spu stop-on-load" command.
48
49 * NEWS: Mention "set/show spu stop-on-load" commands.
50
cc5f0d61
UW
512009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
52
53 * ppc-linux-tdep.c: Include "solib.h", "solist.h", "exceptions.h",
54 "arch-utils.h", and "spu-tdep.h".
55 (spu_context_objfile, spe_context_lm_addr, spe_context_offset):
56 New static variables.
57 (spe_context_cache_ptid, spe_context_cache_address): Likewise.
58 (ppc_linux_spe_context_lookup): New function.
59 (ppc_linux_spe_context_inferior_created): Likewise.
60 (ppc_linux_spe_context_solib_loaded): Likewise.
61 (ppc_linux_spe_context_solib_unloaded): Likewise.
62 (ppc_linux_spe_context): Likewise.
63 (struct ppu2spu_cache, struct ppu2spu_data): New data types.
64 (ppu2spu_prev_arch, ppu2spu_this_id, ppu2spu_prev_register,
65 ppu2spu_unwind_register, ppu2spu_sniffer,
66 ppu2spu_dealloc_cache): New functions.
67 (ppu2spu_unwind): New static variable.
68 (ppc_linux_init_abi): Install cross-architecture unwinder.
69 (_initialize_ppc_linux_tdep): Attach to observers.
70
71 * spu-tdep.c (struct spu2ppu_cache): New data type.
72 (spu2ppu_prev_arch, spu2ppu_this_id, spu2ppu_prev_register,
73 spu2ppu_sniffer, spu2ppu_dealloc_cache): New functions.
74 (spu2ppu_unwind): New static variable.
75 (spu_gdbarch_init): Install cross-architecture unwinder.
76
85e747d2
UW
772009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
78
79 * target.h (enum strata): New value arch_stratum.
80 * target.c (target_require_runnable): Skip arch_stratum targets.
81
82 * configure.tgt (powerpc-*-linux* | powerpc64-*-linux*): Add
83 solib-spu.o and spu-multiarch.o to gdb_target_obs.
84 * Makefile.in (ALL_TARGET_OBS): Add solib-spu.o and spu-multiarch.o.
85 (ALLDEPFILES): Add solib-spu.c and spu-multiarch.c.
86
87 * solib-spu.c: New file.
88 * solib-spu.h: New file.
89 * spu-multiarch.c: New file.
90
91 * spu-tdep.h (SPUADDR, SPUADDR_SPU, SPUADDR_ADDR): New macros.
92
93 * spu-tdep.c (struct gdbarch_tdep): New member id.
94 (spu_gdbarch_id): New function.
95 (spu_lslr): New function.
96
97 (spu_address_to_pointer): New function.
98 (spu_pointer_to_address): Support SPU ID address encoding. Use
99 spu_gdbarch_id and spu_lslr.
100 (spu_integer_to_address): Likewise.
101 (spu_frame_unwind_cache): Update for encoded addresses.
102 (spu_unwind_pc, spu_unwind_sp): Likewise.
103 (spu_read_pc, spu_write_pc): Likewise.
104 (spu_push_dummy_call): Likewise.
105 (spu_software_single_step): Likewise.
106 (spu_get_longjmp_target): Likewise.
107 (spu_overlay_update_osect): Likewise.
108
109 (spu_dis_asm_print_address): New function.
110 (gdb_print_insn_spu): Likewise.
111
112 (spu_gdbarch_init): Store SPU ID in tdep structure.
113 Install spu_address_to_pointer and gdb_print_insn_spu.
114
115 * ppc-linux-tdep.c: Include "observer.h", "auxv.h", "elf/common.h"
116 and "solib-spu.h".
117 (ppc_linux_entry_point_addr): New static variable.
118 (ppc_linux_inferior_created): New function.
119 (ppc_linux_displaced_step_location): Likewise.
120 (ppc_linux_init_abi): Enable Cell/B.E. support if supported
121 by the target.
122 (_initialize_ppc_linux_tdep): Attach to inferior_created observer.
123
124 * NEWS: Mention multi-architecture and Cell/B.E. debugging
125 capabilities.
126
efcbbd14
UW
1272009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
128
129 * linux-nat.c: Include <sys/vfs.h>.
130 (SPUFS_MAGIC): Define.
131 (spu_enumerate_spu_ids): New function.
132 (linux_proc_xfer_spu): New function.
133 (linux_xfer_partial): Handle TARGET_OBJECT_SPU.
134
135 (iterate_over_spus): New function.
136 (struct linux_spu_corefile_data): New data type.
137 (linux_spu_corefile_callback): New function.
138 (linux_spu_make_corefile_notes): New function.
139 (linux_nat_make_corefile_notes): Call it.
140
141 * corelow.c (struct spuid_list): New data type.
142 (add_to_spuid_list): New function.
143 (core_xfer_partial): Handle TARGET_OBJECT_SPU.
144
f4d9bade
UW
1452009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
146
147 * features/Makefile: Allow sub-platform specific expedite settings.
148 (WHICH): Add rs6000/powerpc-cell32l and rs6000/powerpc-cell64l.
149 (rs6000/powerpc-cell32l-expedite): Define.
150 (rs6000/powerpc-cell64l-expedite): Likewise.
151 * features/rs6000/powerpc-cell32l.xml: New file.
152 * features/rs6000/powerpc-cell64l.xml: New file.
153 * features/rs6000/powerpc-cell32l.c: New generated file.
154 * features/rs6000/powerpc-cell64l.c: New generated file.
155
156 * regformats/rs6000/powerpc-cell32l.dat: New generated file.
157 * regformats/rs6000/powerpc-cell64l.dat: New generated file.
158
159 * config/djgpp/fnchange.lst: Add mappings for new files.
160
161 * ppc-linux-tdep.h (tdesc_powerpc_cell32l): Add prototype.
162 (tdesc_powerpc_cell64l): Likewise.
163 * ppc-linux-tdep.c: Include "features/rs6000/powerpc-cell32l.c"
164 and "features/rs6000/powerpc-cell64l.c".
165 (_initialize_ppc_linux_tdep): Initialize target descriptions.
166 (ppc_linux_spu_section): New function.
167 (ppc_linux_core_read_description): Detect Cell/B.E. core files.
168 * ppc-linux-nat.c (PPC_FEATURE_CELL): Define.
169 (ppc_linux_read_description): Detect Cell/B.E. architecture.
170
171 * rs6000-tdep.c (rs6000_gdbarch_init): Do not trust BFD wordsize
172 if exec file is not PowerPC architecture.
173
e35359c5
UW
1742009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
175
176 * features/gdb-target.dtd (target): Accept optional
177 <compatible> elements.
178 (compatible): Define element.
179
180 * target-descriptions.h (tdesc_compatible_p): New.
181 (tdesc_add_compatible): New.
182 * target-descriptions.c (arch_p): New VEC_P type.
183 (struct target_desc): New member compatible.
184 (free_target_description): Handle it.
185 (maint_print_c_tdesc_cmd): Likewise.
186 (tdesc_compatible_p): New function.
187 (tdesc_add_compatible): New function.
188
189 * xml-tdesc.c (tdesc_end_compatible): New function.
190 (target_children): Handle <compatible> element.
191
192 * arch-utils.c (choose_architecture_for_target): Accept target
193 description instead of BFD architecture as input. Query target
194 description for compatible architectures.
195 (gdbarch_info_fill): Update call.
196
197 * NEWS: Mention <compatible> element of target descriptions.
198
3a1bae8e
UW
1992009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
200
201 * breakpoint.c (remove_breakpoints): If removing one breakpoint
202 location fails, still continue to remove other locations.
203 (remove_hw_watchpoints): Likewise.
204 (detach_breakpoints): Likewise.
205
8bea4e01
UW
2062009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
207
208 * breakpoint.h (enum enable_state): Add bp_startup_disabled.
209 (disable_breakpoints_before_startup): Add prototype.
210 (enable_breakpoints_after_startup): Likewise.
211
212 * breakpoint.c (executing_startup): New static variable.
213 (describe_other_breakpoints): Handle bp_startup_disabled.
214 (check_duplicates_for): Likewise.
215 (disable_breakpoints_before_startup): New function.
216 (enable_breakpoints_after_startup): New function.
217 (create_breakpoint): Mark new breakpoints as bp_startup_disabled
218 if executing_startup flag is true.
219 (break_command_really): Likewise.
220 (breakpoint_re_set_one): Skip bp_startup_disabled breakpoints.
221
cca44b1b
JB
2222009-07-31 Julian Brown <julian@codesourcery.com>
223
224 * arm-linux-tdep.c (arch-utils.h, inferior.h, gdbthread.h, symfile.h):
225 Include files.
226 (arm_linux_cleanup_svc, arm_linux_copy_svc): New.
227 (cleanup_kernel_helper_return, arm_catch_kernel_helper_return): New.
228 (arm_linux_displaced_step_copy_insn): New.
229 (arm_linux_init_abi): Initialise displaced stepping callbacks.
230 * arm-tdep.c (DISPLACED_STEPPING_ARCH_VERSION): New macro.
231 (ARM_NOP): New.
232 (displaced_read_reg, displaced_in_arm_mode, branch_write_pc)
233 (bx_write_pc, load_write_pc, alu_write_pc, displaced_write_reg)
234 (insn_references_pc, copy_unmodified, cleanup_preload, copy_preload)
235 (copy_preload_reg, cleanup_copro_load_store, copy_copro_load_store)
236 (cleanup_branch, copy_b_bl_blx, copy_bx_blx_reg, cleanup_alu_imm)
237 (copy_alu_imm, cleanup_alu_reg, copy_alu_reg)
238 (cleanup_alu_shifted_reg, copy_alu_shifted_reg, cleanup_load)
239 (cleanup_store, copy_extra_ld_st, copy_ldr_str_ldrb_strb)
240 (cleanup_block_load_all, cleanup_block_store_pc)
241 (cleanup_block_load_pc, copy_block_xfer, cleanup_svc, copy_svc)
242 (copy_undef, copy_unpred): New.
243 (decode_misc_memhint_neon, decode_unconditional)
244 (decode_miscellaneous, decode_dp_misc, decode_ld_st_word_ubyte)
245 (decode_media, decode_b_bl_ldmstm, decode_ext_reg_ld_st)
246 (decode_svc_copro, arm_process_displaced_insn)
247 (arm_displaced_init_closure, arm_displaced_step_copy_insn)
248 (arm_displaced_step_fixup): New.
249 (arm_gdbarch_init): Initialise max insn length field.
250 * arm-tdep.h (DISPLACED_TEMPS, DISPLACED_MODIFIED_INSNS): New
251 macros.
252 (displaced_step_closure, pc_write_style): New.
253 (arm_displaced_init_closure, displaced_read_reg)
254 (arm_process_displaced_insn, arm_displaced_init_closure)
255 (displaced_read_reg, displaced_write_reg, arm_displaced_step_copy_insn)
256 (arm_displaced_step_fixup): Add prototypes.
257
929dfd4f
JB
2582009-07-31 Pedro Alves <pedro@codesourcery.com>
259 Julian Brown <julian@codesourcery.com>
260
261 * infrun.c (displaced_step_fixup): If this is a software
262 single-stepping arch, don't tell the target to single-step.
263 (maybe_software_singlestep): Return 0 if we're using displaced
264 stepping.
265 (resume): If this is a software single-stepping arch, and
266 displaced-stepping is enabled, use it for all single-step
267 requests.
268
1983cb9a
RW
2692009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
270
271 * Makefile.in (ACLOCAL, ACLOCAL_AMFLAGS, aclocal_m4_deps)
272 (AUTOCONF, configure_deps, AUTOHEADER): New variables.
273 ($(srcdir)/aclocal.m4, $(srcdir)/configure, $(srcdir)/config.in)
274 (am--refresh): New rules.
275 (stamp-h, config.status): List config.in and configure including
276 $(srcdir)/ prefix.
277 * aclocal.m4: Regenerate.
278 * configure: Regenerate.
279
fe79276f
TS
2802009-07-30 Thomas Schwinge <tschwinge@gnu.org>
281
282 * gnu-nat.c (add_task_commands) <stopped>: Register the correct
283 callback function.
284
2edfe795
L
2852009-07-30 H.J. Lu <hongjiu.lu@intel.com>
286
287 * ia64-tdep.c (ia64_access_reg): Correct paddress.
288
54333c3b
JK
2892009-07-30 Jan Kratochvil <jan.kratochvil@redhat.com>
290
291 Replace public function varobj_list by all_root_varobjs iterator.
292 * mi/mi-cmd-var.c (struct mi_cmd_var_update, mi_cmd_var_update_iter):
293 New.
294 (mi_cmd_var_update): Replace the varobj_list call by all_root_varobjs.
295 Remove the variables rootlist, cr. New variable data.
296 * varobj.c (rootcount, varobj_list): Remove.
297 (install_variable, uninstall_variable): Remove the rootcount updates.
298 (all_root_varobjs): New function.
299 (varobj_invalidate): Use the all_root_varobjs call. Move the code to...
300 (varobj_invalidate_iter): ... a new function.
301 * varobj.h (varobj_list): Remove the prototype.
302 (all_root_varobjs): New prototype.
303
60f25dfd
PP
3042009-07-29 Paul Pluzhnikov <ppluzhnikov@google.com>
305
306 PR gdb/6817
307 * dbxread.c (read_dbx_symtab): Reduce stack use.
308
e23cce45
JK
3092009-07-29 Jan Kratochvil <jan.kratochvil@redhat.com>
310
311 Fix gcc-4.5 HEAD warnings.
312 * cp-name-parser.y (%union <typed_val_int>, %token GLOBAL)
313 (GLOBAL_CONSTRUCTORS, GLOBAL_DESTRUCTORS, demangler_special <GLOBAL>):
314 Remove.
315 (yylex <"global constructors keyed to ">)
316 (yylex <"global destructors keyed to ">): Base it on DEMANGLER_SPECIAL.
317 (cp_comp_to_string): Remove variables str, prefix and buf. Remove the
318 GLOBAL_DESTRUCTORS and GLOBAL_CONSTRUCTORS handling.
319 (cp_print): Remove the GLOBAL_DESTRUCTORS and GLOBAL_CONSTRUCTORS
320 handling.
321
58d6951d
DJ
3222009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
323
324 * NEWS: Mention ARM VFP support.
325 * target-descriptions.c (tdesc_register_type): Make public.
326 (tdesc_unnumbered_register): New function.
327 (tdesc_register_reggroup_p): Allow missing
328 pseudo_register_reggroup_p.
329 * target-descriptions.h (tdesc_register_type): Declare.
330 (tdesc_unnumbered_register): Declare.
331 * arm-tdep.c (arm_neon_quad_read, arm_neon_quad_write): New functions.
332 (arm_push_dummy_call): Use arm_neon_quad_write.
333 (arm_neon_double_type, arm_neon_quad_type): New functions.
334 (arm_register_type): Handle VFP and NEON registers. Override the
335 types of double-precision registers for NEON. Disable FPA registers
336 if they are not present.
337 (arm_dwarf_reg_to_regnum): Add current VFP and NEON register numbers.
338 (arm_return_value): Use arm_neon_quad_write and arm_neon_quad_read.
339 (arm_register_name): Handle VFP single and NEON quad registers.
340 (arm_pseudo_read, arm_pseudo_write): New functions.
341 (arm_gdbarch_init): Check for VFP and NEON in the target description.
342 Assign numbers to double-precision registers. Register VFP and NEON
343 pseudo registers. Remove a shadowed "i" variable.
344 * arm-tdep.h (enum gdb_regnum): Add ARM_D0_REGNUM and
345 ARM_D31_REGNUM.
346 (struct gdbarch_tdep): Add have_neon_pseudos, have_neon,
347 have_vfp_registers, have_vfp_pseudos, neon_double_type,
348 and neon_quad_type.
349
350 * features/Makefile: Make expedite settings only architecture
351 specific.
352 (WHICH): Add new ARM descriptions.
353 * features/arm-with-neon.xml, features/arm-with-vfpv2.c,
354 features/arm-with-vfpv3.c, features/arm-vfpv2.xml,
355 features/arm-vfpv3.xml, features/arm-with-vfpv2.xml,
356 features/arm-with-vfpv3.xml, features/arm-with-neon.c: New files.
357 * regformats/arm-with-neon.dat, regformats/arm-with-vfpv2.dat,
358 regformats/arm-with-vfpv3.dat: Generate.
359
79626f8a
DJ
3602009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
361
362 * infrun.c (handle_inferior_event): Clear trap_expected after
363 stepping past a single-step breakpoint.
364
90445bd3
DJ
3652009-07-28 Joseph Myers <joseph@codesourcery.com>
366
367 * arm-tdep.c (enum arm_vfp_cprc_base_type,
368 arm_vfp_cprc_unit_length, arm_vfp_cprc_reg_char,
369 arm_vfp_cprc_sub_candidate, arm_vfp_call_candidate,
370 arm_vfp_abi_for_function): New.
371 (arm_push_dummy_call): Handle VFP ABI.
372 (arm_extract_return_value, arm_store_return_value): Handle
373 ARM_FLOAT_VFP case.
374 (arm_return_value): Handle VFP ABI.
375 (arm_gdbarch_init): Default fp_model based on Tag_ABI_VFP_args for
376 EABI binaries.
377
3612b192
DJ
3782009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
379
380 * arch-utils.c (displaced_step_at_entry_point): Do not call
381 gdbarch_convert_from_func_ptr_addr.
382 * cris-tdep.c: Remove outdated comment.
383 * infcall.c (call_function_by_hand): Do not call
384 gdbarch_convert_from_func_ptr_addr after entry_point_address.
385 * objfiles.c (entry_point_address): Call both
386 gdbarch_convert_from_func_ptr_addr and
387 gdbarch_addr_bits_remove.
388
745a434e
AR
3892009-07-28 Aleksandar Ristovski <aristovski@qnx.com>
390
391 * nto-tdep.c (nto_thread_state_str): New array.
392 (nto_extra_thread_info): New function definition.
393 * nto-tdep.h (gdbthread.h): New include.
394 (private_thread_info): New struct.
395 (nto_extra_thread_info): New declaration.
396 * nto-procfs.c (procfs_thread_alive): Properly check if
397 thread is still alive.
398 (update_thread_private_data_name, update_thread_private_data): New
399 function definition.
400 (procfs_find_new_threads): Fetch thread private data.
401 (init_procfs_ops): Register to_extra_thread_info.
402
46106157
PA
4032009-07-25 Pedro Alves <pedro@codesourcery.com>
404
405 * stack.c (backtrace_command_1): Remove dead check of NULL current
406 frame.
407
e681b284
KS
4082009-07-23 Keith Seitz <keiths@redhat.com>
409
410 * source.c (forward_search_command): Don't fclose the stream,
411 just run the cleanups.
412 (reverse_search_command): Likewise.
413
89295b4d
PP
4142009-07-23 Paul Pluzhnikov <ppluzhnikov@google.com>
415
416 * symtab.c (search_symbols): Add QUIT.
417
8caee43b
PP
4182009-07-22 Paul Pluzhnikov <ppluzhnikov@google.com>
419
420 * symfile.c (symbol_file_add_with_addrs_or_offsets): Call observer.
421
bb272892
PP
4222009-07-22 Paul Pluzhnikov <ppluzhnikov@google.com>
423
424 * objfiles.h (objfiles_changed): New prototype.
425 * objfiles.c (objfiles_updated_p): Rename to objfiles_changed_p.
426 (allocate_objfile, free_objfile): Must rebuild section map.
427 (objfile_relocate): Likewise.
428 (update_section_map, find_pc_section): Adjust.
429 (set_objfiles_updated_on_exe_change): Remove.
430 (set_objfiles_updated_on_solib_activity): Remove.
431 (_initialize_objfiles): Remove.
432 (objfiles_changed): New function.
433 * symfile.c (reread_symbols): Call objfiles_changed.
434
9a9dc473
HZ
4352009-07-22 Hui Zhu <teawater@gmail.com>
436
437 * record.c (record_xfer_partial): Call error When nquery
438 return "n".
439
a845f5cb
PP
4402009-07-21 Paul Pluzhnikov <ppluzhnikov@google.com>
441
442 * objfiles.c (objfiles_updated_p): New variable.
443 (qsort_cmp, bsearch_cmp, update_section_map): New function.
444 (find_pc_section): Use bsearch.
445 (set_objfiles_updated_on_exe_change): New function.
446 (set_objfiles_updated_on_solib_activity): New function.
447 (_initialize_objfiles): New function.
448
c761c4ee 4492009-07-21 Michael Eager <eager@eagercon.com>
4d09ffea
MS
450
451 * features/rs6000/powerpc-405.xml: New.
452 * rs6000-tdep.c: Add include & initialize for
453 powerpc-405.c, add 405 to variants.
454 * features/rs6000/powerpc-405.c: Generate.
455
26bb68be
PP
4562009-07-21 Paul Pluzhnikov <ppluzhnikov@google.com>
457
25f77bfa 458 * utils.c (internal_vproblem): Always print failure message.
26bb68be 459
4ea48cc1
DJ
4602009-07-21 Daniel Jacobowitz <dan@codesourcery.com>
461 Vladimir Prus <vladimir@codesourcery.com>
462
463 * valops.c (value_fetch_lazy): Handle bitfields explicitly.
464 (value_assign): Remove unnecessary FIXME. Honor the container
465 type of bitfields if possible.
466 * value.c (struct value): Add parent field.
467 (value_parent): New function.
468 (value_free): Free the parent also.
469 (value_copy): Copy the parent also.
470 (value_primitive_field): Do not read the contents of a lazy
471 value to create a child bitfield value. Set bitpos and offset
472 according to the container type if possible.
473 (unpack_bits_as_long): Rename from unpack_field_as_long. Take
474 field_type, bitpos, and bitsize instead of type and fieldno.
475 (unpack_field_as_long): Use unpack_bits_as_long.
476 * value.h (value_parent, unpack_bits_as_long): New prototypes.
477
828d3400
DJ
4782009-07-21 Daniel Jacobowitz <dan@codesourcery.com>
479
480 * value.c (struct value): Add reference_count field.
481 (allocate_value_lazy): Initialize reference_count.
482 (value_incref): New function.
483 (value_free): Check the reference count.
484 * value.h (value_incref): New prototype.
485
7a01c6e0
MK
4862009-07-20 Marc Khouzam <marc.khouzam@ericsson.com>
487
488 * utils.c (defaulted_query): Update comment and remove dead code.
489
348e048f
DE
4902009-07-20 Doug Evans <dje@google.com>
491
492 Add support for "comdat types" from DWARF4.
493 * dwarf2read.c (dwarf2_per_objfile): New member types,
494 signatured_types.
495 (TYPES_SECTION): New macro.
496 (dwarf2_per_cu_data): Change size of length field from 30 bits
497 to 29 bits. New member from_debug_types.
498 (signatured_type): New struct.
499 (struct attribute): New union member signatured_type.
500 (DW_SIGNATURED_TYPE): New macro.
501 (dwarf2_attr_no_follow): New function.
502 (read_type_unit_scope): New function.
503 (follow_die_ref_or_sig, follow_die_sig): New functions.
504 (dwarf2_locate_sectoins): Handle .debug_types.
505 (dwarf2_build_psymtabs): Read .debug_types.
506 (read_type_comp_unit_head): New function.
507 (hash_type_signature, eq_type_signature): New functions.
508 (create_debug_types_hash_table): New function.
509 (lookup_signatured_type): New function.
510 (process_psymtab_comp_unit): Handle type units too.
511 (process_type_comp_unit, build_type_psymtabs): New functions.
512 (dwarf2_build_psymtabs_hard): Call build_type_psymtabs.
513 (load_partial_comp_unit): Assert not called for a type unit.
514 (skip_one_die): Handle DW_FORM_sig8.
515 (queue_comp_unit): Don't call load_full_comp_unit here, or
516 update read_in_chain.
517 (psymtab_to_symtab_1): Call read_signatured_type_at_offset for
518 type units, or load_full_comp_unit for comp units after
519 queue_comp_unit returns.
520 (load_full_comp_unit): Assert not called for type units.
521 (load_full_comp_unit): Update read_in_chain here.
522 (process_die): Handle DW_TAG_type_unit.
523 (read_structure_type): Look for signatured types.
524 (read_enumeration_type): Ditto.
525 (init_cu_die_reader): Handle .debug_types.
526 (read_comp_unit): Assert hash not computed yet.
527 (read_die_and_children): Expand debugging printf to handle .debug_types.
528 (read_partial_die): Handle DW_TAG_type_unit:
529 (find_patial_die): Handle .debug_types.
530 (read_attribute_value): Handle DW_FORM_sig8.
531 (die_type): Call follow_die_ref_or_sig instead of follow_die_ref.
532 (die_containing_type): Ditto.
533 (dwarf_tag_name): Handle DW_TAG_type_unit.
534 (dwarf_attr_name): Handle DW_AT_signature.
535 (dwarf_form_name): Handle DW_FORM_sec_offset, DW_FORM_exprloc,
536 DW_FORM_flag_present, DW_FORM_sig8.
537 (dump_die_shallow): Handlel DW_FORM_sig8.
538 (maybe_queue_comp_unit): Change return type to int from void.
539 All callers updated.
540 (follow_die_ref): Handle .debug_types.
541 (lookup_signatured_type_at_offset): New function.
542 (read_signatured_type_at_offset): New function.
543 (read_signatured_type): New function.
544
f4290e2a
UW
5452009-07-20 Ulrich Weigand <uweigand@de.ibm.com>
546
547 * arch-utils.c (gdbarch_info_fill): Only reference GDB_OSABI_DEFAULT
548 if the macro is defined.
549
08d16641
PA
5502009-07-20 Pedro Alves <pedro@codesourcery.com>
551
552 * features/gdb-target.dtd (target): Accept an optional 'osabi'
553 element.
554 (osabi): Define element.
555 * features/mips-linux.xml (target): Add an osabi subelement set to
556 GNU/Linux.
557 * regformats/regdat.sh (xmlarch, xmlosabi): New variables. Don't
558 write the architecture into $xmltarget. Store it in $xmlarch.
559 Handle the 'osabi' type. Handle outputting the osabi element of
560 the target description.
561 * regformats/reg-x86-64-linux.dat (osabi): Set to GNU/Linux.
562 * regformats/reg-i386-linux.dat (osabi): Set to GNU/Linux.
563
564 * target-descriptions.h (tdesc_osabi, set_tdesc_osabi): Declare.
565 * target-descriptions.c (struct target_desc) <osabi>: New field.
566 (tdesc_osabi): New function.
567 (set_tdesc_osabi): New function.
568 * xml-tdesc.c: Include osabi.h.
569 (tdesc_end_osabi): New.
570 (target_children): Parse "osabi" elements.
571 * arch-utils.c (gdbarch_info_fill): Try to get the osabi from the
572 target description if the user didn't override it or it is not
573 extractable from the bfd. If that still fails, fallback to the
574 configured in default.
575 * osabi.h (osabi_from_tdesc_string): Declare.
576 * osabi.c (osabi_from_tdesc_string): New.
577 (gdbarch_lookup_osabi): Return GDB_OSABI_UNKNOWN instead of
578 GDB_OSABI_DEFAULT.
579
580 * NEWS: Mention that target descriptions can now describe the
581 target OS ABI.
582
a156a290
MF
5832009-07-20 Mike Frysinger <vapier@gentoo.org>
584
585 * configure.ac (AC_CHECK_FUNCS): Check for pipe.
586 * config.in, configure: Regenerate.
587 * tui/tui-io.c (TUI_USE_PIPE_FOR_READLINE): Define if HAVE_PIPE.
588
b4d1e8c7
PA
5892009-07-20 Pedro Alves <pedro@codesourcery.com>
590
591 * gnu-nat.c: Include "inf-child.h".
592 (gnu_mourn_inferior): Use the passed in target_ops
593 instead of the gnu_ops global.
594 (gnu_create_inferior): Inline `attach_to_child', use the passed in
595 target_ops instead of the gnu_ops global.
596 (gnu_can_run): Delete.
597 (gnu_attach): Use the passed in target_ops instead of the gnu_ops
598 global.
599 (gnu_detach): Ditto.
600 (gnu_prepare_to_store, gnu_open): Delete.
601 (gnu_store_registers, gnu_fetch_registers): Delete declarations.
602 (gnu_ops): Delete.
603 (init_gnu_ops): Delete.
604 (gnu_target): New.
605 (_initialize_gnu_nat): Don't call init_gnu_ops or add_target here.
606 * gnu-nat.h (gnu_target): Declare.
607 * i386gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Make
608 static.
609 (_initialize_i386gnu_nat): New.
610
b5758fe4
UW
6112009-07-20 Ulrich Weigand <uweigand@de.ibm.com>
612
613 * dwarf2loc.c (find_location_expression): Retrieve beginning and
614 ending address offsets in location list entries as integers,
615 not as addresses.
616
ec9499be
UW
6172009-07-20 Ulrich Weigand <uweigand@de.ibm.com>
618
619 * infrun.c (wait_for_inferior): Invalidate registers and overlay
620 cache every time before calling target_wait.
621 (handle_inferior_event): Make static. Always reset waiton_ptid.
622 Never call registers_changed.
623 (prepare_to_wait): Do not invaliate registers or overlay cache
624 (moved to wait_for_inferior). Do not reset waiton_ptid (moved
625 to handle_inferior_event).
626 (fetch_inferior_event): Remove check for always-true condition.
627
85a772a5
TS
6282009-07-20 Thomas Schwinge <tschwinge@gnu.org>
629
630 * i386gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Adjust to
631 2009-02-23 target_ops changes.
632
fdd654f3
MS
6332009-07-18 Michael Snyder <msnyder@vmware.com>
634
635 * infrun.c (handle_inferior_event): Remove an execution_direction
636 check in the "check for subroutine calls" test, and add some
637 additional handling for reverse-stepping through shared libraries.
638
99f75275
AG
6392009-07-18 Anthony Green <green@moxielogic.com>
640
641 * moxie-tdep.c (moxie_analyze_prologue): Take gdbarch as last
642 parameter instead of frame_info.
643 (moxie_frame_cache): Call moxie_analyze_prologue with different
644 args.
645
831a0c44
UW
6462009-07-17 Ulrich Weigand <uweigand@de.ibm.com>
647
648 * solib.c (solib_bfd_open): Do not call ops->bfd_open.
649 (solib_map_sections): Call ops->bfd_open instead of solib_bfd_open.
650 * solib-frv.c (_initialize_frv_solib): Initialize bfd_open member.
651 * solib-irix.c (_initialize_irix_solib): Likewise.
652 * solib-null.c (_initialize_null_solib): Likewise.
653 * solib-osf.c (_initialize_osf_solib): Likewise.
654 * solib-pa64.c (_initialize_pa64_solib): Likewise.
655 * solib-som.c (_initialize_som_solib): Likewise.
656 * solib-sunos.c (_initialize_sunos_solib): Likewise.
657 * solib-svr4.c (_initialize_svr4_solib): Likewise.
658 * solib-target.c (_initialize_solib_target): Likewise.
659
328d0145
UW
6602009-07-17 Ulrich Weigand <uweigand@de.ibm.com>
661
662 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Respect mixed_mode flag.
663
099cb4fb
DE
6642009-07-16 Doug Evans <dje@google.com>
665
666 * linux-thread.db.c (try_thread_db_load_1): Tweak comment.
667
456b0e24
PP
6682007-07-16 Paul Pluzhnikov <ppluzhnikov@google.com>
669
670 * linux-thread-db.c (thread_db_find_new_threads_silently):
671 New function.
672 (try_thread_db_load_1): Call it.
099cb4fb 673
93311388
DE
6742009-07-15 Doug Evans <dje@google.com>
675
676 Code reorg in preparation for adding comdat types support.
677 * dwarf2read.c (struct die_reader_specs): New struct.
678 (locate_pdi_sibling): New arg buffer. All callers updated.
679 (load_partial_dies, read_partial_die): Ditto.
680 (read_8_bytes): Change return type to ULONGEST.
681 (read_comp_unit): Delete arg abfd. All callers updated.
682 (read_die_and_children_1): Delete args abfd, cu. New arg reader.
683 All callers updated.
684 (read_die_and_children, read_die_and_siblings): Ditto.
685 (read_full_die): Ditto. Move closer to callers.
686 (skip_one_die): New arg buffer. All callers updated.
687 (load_full_comp_unit): Change return type to void. All callers
688 updated.
689 (partial_read_comp_unit_head): New args buffer, buffer_size.
690 All callers updated.
691 (process_psymtab_comp_unit): New function, split out from
692 dwarf2_build_psymtabs_hard.
693 (dwarf2_build_psymtabs_hard): Call it.
694 (load_partial_comp_unit): Renamed from load_comp_unit.
695 All callers updated.
696 (skip_children): New arg buffer. All callers updated.
697 (init_cu_die_reader): New function.
698 (is_ref_attr): New function.
699 (dwarf2_get_ref_die_offset): Call it.
700 (alloc_one_comp_unit): New function.
701
bf0d7e9c
SS
7022009-07-14 Stan Shebs <stan@codesourcery.com>
703
704 * MAINTAINERS (Global Maintainers): Add Doug Evans.
705
782b2b07
SS
7062009-07-14 Stan Shebs <stan@codesourcery.com>
707
708 Conditional tracepoints.
709 * ax-gdb.h (gen_eval_for_expr): Declare.
710 * ax-gdb.c (gen_expr): Generate bytecodes for BINOP_EQUAL
711 and other comparisons.
712 (gen_eval_for_expr): New function.
713 (agent_eval_command): New maintenance command.
714 (_initialize_ax_gdb): Define the command.
715 * remote.c (struct remote_state): New field cond_tracepoints.
716 (PACKET_ConditionalTracepoints): New packet config type.
717 (remote_cond_tracepoint_feature): New function.
718 (remote_protocol_features): Add ConditionalTracepoints.
719 (remote_supports_cond_tracepoints): New function.
720 (_initialize_remote): Add ConditionalTracepoints.
721 * tracepoint.c (download_tracepoint): Add conditional.
722 * NEWS: Mention conditional tracepoints.
723
b101f7a1
UW
7242009-07-14 Ulrich Weigand <uweigand@de.ibm.com>
725
726 * objfiles.c (objfile_relocate): Do not relocate the same
727 BLOCKVECTOR_MAP address map multiple times.
728
217f1f79
UW
7292009-07-14 Ulrich Weigand <uweigand@de.ibm.com>
730
731 * remote.c (process_stop_reply): Access expedited target registers
732 in target_gdbarch.
733
8f313923
JK
7342009-07-13 Jan Kratochvil <jan.kratochvil@redhat.com>
735
736 Fix memory access from signed 32bit inferior registers on 64bit GDB.
737 * linux-nat.c (linux_xfer_partial <TARGET_OBJECT_MEMORY>): New variable
738 addr_bit. Mask OFFSET by the ADDR_BIT width.
739
451fa05e
AG
7402009-07-13 Anthony Green <green@moxielogic.com>
741
742 * moxie-tdep.c (moxie_gdbarch_init): Call
743 set_gdbarch_process_record.
744 (moxie_process_record): New.
745 (moxie_process_readu): New.
746
06da04c6
MS
7472009-07-12 Michael Snyder <msnyder@vmware.com>
748
749 * i386-tdep.c: Add a frame unwinder for function epilogues.
750 (i386_in_function_epilogue_p): New function.
751 (i386_epilogue_frame_sniffer): New function.
752 (i386_epilogue_frame_cache): New function.
753 (i386_epilogue_frame_this_id): New function.
754 (i386_epilogue_frame_unwind): New struct frame_unwind.
755 (i386_gdbarch_init): Hook the new unwinder.
756
e6158f16
HZ
7572009-07-11 Hui Zhu <teawater@gmail.com>
758
759 * cli/cli-cmds.c (disassemble_command): Add a new modifier /r
760 to "disassemble" command to print the raw instructions in hex as
761 well as in symbolic form.
762 (init_cli_cmds): Ditto.
763 (print_disassembly): Change "mixed" to "flags" to translate
764 the behavior of disassemble.
765 (disassemble_current_function): Ditto.
766 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Ditto.
767 * stack.c (gdb_disassembly_stub): Ditto.
768 * disasm.c (do_mixed_source_and_assembly): Ditto.
769 (do_mixed_source_and_assembly): Ditto.
770 (do_assembly_only): Ditto.
771 (gdb_disassembly): Ditto.
772 (dump_insns): print the raw instructions in hex as well as in
773 symbolic form if DISASSEMBLY_RAW_INSN and flags is true.
774 * disasm.h (DISASSEMBLY_SOURCE): Include source code with the
775 assembly if it and flags is true.
776 (DISASSEMBLY_RAW_INSN): Include the raw instructions in hex with
777 the assembly if it and flags is true.
778 (gdb_disassembly): Update extern.
779 * NEWS: Document disassemble/r support.
780
fa8f86ff
TT
7812009-07-10 Tom Tromey <tromey@redhat.com>
782
783 * dwarf2-frame.c: Include dwarf2.h, not elf/dwarf2.h.
784 * dwarf2expr.c: Likewise.
785 * dwarf2loc.c: Likewise.
786 * dwarf2read.c: Likewise.
787 * sh-tdep.c: Likewise.
788 * xtensa-tdep.c: Likewise.
789
6e9ef2a8
JK
7902009-07-10 Jan Kratochvil <jan.kratochvil@redhat.com>
791
792 Tidy up the code.
793 * mi/mi-cmd-var.c (mi_cmd_var_update): Remove variable nv. Move
794 variables var, rootlist and cr to their local sub-block. Move the
795 make_cleanup_ui_out_tuple_begin_end, make_cleanup_ui_out_list_begin_end
796 and do_cleanups calls to the common base block. Remove the zero NV
797 check.
798
fbb8f299
PM
7992009-07-10 Phil Muldoon <pmuldoon@redhat.com>
800
801 * python/python-internal.h (apply_varobj_pretty_printer): Update
802 definition.
803 (python_string_to_target_python_string): Add definition.
804 * python/python-utils.c (unicode_to_encoded_python_string)
805 (unicode_to_target_python_string)
806 (python_string_to_target_python_string): New Functions.
807 * python/python-prettyprint.c (pretty_print_one_value): Likewise.
808 (print_string_repr): Refactor to logic to account for PyObject
809 returned strings.
810 (apply_varobj_pretty_printer): Likewise.
811 * python/python-value.c (valpy_string): Parse length keyword. Use
812 length keyword in LA_GET_STRING.
813 * varobj.c (value_get_print_value): Refactor logic to account for
814 PyObject returned strings.
815 * c-lang.c (c_get_string): If the length parameter is specified,
816 use that. Return value in characters. Update comments.
817 * language.h: Update c_get_string prototype comments.
818
b75f0b83
DE
8192009-07-09 Doug Evans <dje@google.com>
820
821 * i386-tdep.c (i386_displaced_step_fixup): Fix order of arguments
822 to read_memory_unsigned_integer.
823
c0ac0ec7
JK
8242009-07-09 Jan Kratochvil <jan.kratochvil@redhat.com>
825
826 Report error on inaccessible memory.
827 * cli/cli-dump.c: Include gdbcore.h.
828 (dump_memory_to_file): Call read_memory instead of target_read_memory.
829
378d2b72
HZ
8302009-07-09 Hui Zhu <teawater@gmail.com>
831
832 * solib.c (solib_bfd_open): Output a warning if solib's
833 architecture is not compatible with inferior's architecture.
834
3a8f7b07
JK
8352009-07-09 Ulrich Weigand <uweigand@de.ibm.com>
836 Jan Kratochvil <jan.kratochvil@redhat.com>
837
838 * target.h (struct target_ops <to_thread_architecture>): Describe it.
839 (target_thread_architecture): Refer to to_thread_architecture.
840
a177aad3
PM
8412009-07-08 Pierre Muller <muller@ics.u-strasbg.fr>
842
843 * cli/cli-cmds.c (init_cli_cmds): Add "inf" alias for "info" command.
844
2d5f09f0
UW
8452009-07-07 Ulrich Weigand <uweigand@de.ibm.com>
846
847 * tui/tui-stack.c (tui_make_status_line): Display PC as ?? if unknown.
848
63c252f8
PM
8492009-07-07 Pierre Muller <muller@ics.u-strasbg.fr>
850
851 * breakpoint.c (set_raw_breakpoint): Remove static modifier.
852
30b66ecc
TT
8532009-07-07 Tom Tromey <tromey@redhat.com>
854
855 * c-lang.c (convert_octal): Only allow 3 octal digits.
856 (print_wchar): Prefer 3-digit octal form. Fall back to hex if
857 needed.
858 * c-exp.y (c_parse_escape): Only allow 3 octal digits.
859
06878dd2
PP
8602009-07-07 Paul Pluzhnikov <ppluzhnikov@google.com>
861
862 * python/python-value.c (valpy_getitem): Remove incorrect assert.
863
570e2b1a
PP
8642009-07-07 Paul Pluzhnikov <ppluzhnikov@google.com>
865
866 * python/python-value.c (valpy_getitem): Don't return from TRY_CATCH.
867
8c902bb1
SW
8682009-07-07 Sami Wagiaalla <swagiaal@redhat.com>
869
870 * cp-support.h (struct using_direct): Rename members inner and
871 outer to import_src, and import_dest respectively.
872 * cp-namespace.c (cp_add_using_directive): Update.
873 (cp_add_using): Update.
874 (cp_copy_usings): Update.
875 (cp_lookup_symbol_namespace): Update.
876 (cp_scan_for_anonymous_namespaces): Update.
877 * cp-support.c (make_symbol_overload_list_using): Update.
878 * cp-support.h (cp_add_using_directive, cp_add_using): Rename
879 arguments from inner and outer to src and dest respectively.
880 * cp-namespace.c (cp_add_using_directive): Ditto.
881 (cp_add_using): Ditto.
882
fd115a4b
JK
8832009-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
884
885 * mi/mi-cmd-var.c (mi_cmd_var_update): Replace a while loop by for loop.
886 * varobj.c (varobj_invalidate): Replace a while loop by for loop.
887
60d32970
VP
8882009-07-07 Vladimir Prus <vladimir@codesourcery.com>
889
890 Fix hang in floating varobjs.
891
c0ac0ec7 892 * varobj.c (varobj_invalidate): Advance to next
60d32970
VP
893 element when processing floating varobj.
894
9a139cba
VP
8952009-07-07 Vladimir Prus <vladimir@codesourcery.com>
896
897 * varobj.c: Remove unnecessary include.
898
02b96ddc
TG
8992009-07-07 Tristan Gingold <gingold@adacore.com>
900
901 * config/i386/darwin.mh (NATDEPFILES): Remove excServer.o.
902 Remove excServer.c target. Remove _all target.
903 * darwin.defs: Removed.
904
7f86f499
AR
9052009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
906
907 * configure.tgt (i[34567]86-*-nto*): Add build_gdbserver=yes.
908
e2357892
JK
9092009-07-06 Jan Kratochvil <jan.kratochvil@redhat.com>
910
911 * source.c (find_and_open_source): Remove the `objfile' parameter.
912 Update the function comment.
913 (open_source_file, symtab_to_fullname, psymtab_to_fullname): Update the
914 find_and_open_source callers.
915
5e13bd89
PA
9162009-07-05 Pedro Alves <pedro@codesourcery.com>
917
918 * coff-pe-read.c (read_pe_exported_syms): Recognize
919 "pe-arm-wince-little" and "pei-arm-wince-little" bfd targets as PE
920 targets.
921
d7117c03
PA
9222009-07-05 Pedro Alves <pedro@codesourcery.com>
923
924 * arm-wince-tdep.c (arm_wince_skip_main_prologue): New.
925 (arm_wince_init_abi): Register it as gdbarch_skip_main_prologue
926 callback.
927
5cd226f2
TG
9282009-06-29 Tristan Gingold <gingold@adacore.com>
929
930 * i386-darwin-tdep.c (amd64_darwin_thread_state_reg_offset)
931 (amd64_darwin_thread_state_num_regs)
932 (amd64_darwin_sigcontext_addr, x86_darwin_init_abi_64): Moved to
933 amd64-darwin-tdep.c
934 (_initialize_i386_darwin_tdep): Remove 64 bits parts.
935 (darwin_dwarf_signal_frame_p): Make public.
936 * amd64-darwin-tdep.c: New file with most chunks from
937 i386-darwin-tdep.c
938 * i386-darwin-tdep.h: Add a prototype for darwin_dwarf_signal_frame_p.
939 (amd64_darwin_thread_state_reg_offset)
940 (amd64_darwin_thread_state_num_regs): Moved to amd64-darwin-tdep.h
941 * amd64-darwin-tdep.h: New file.
942 * i386-darwin-nat.c: Only includes amd64-nat.h and amd64-darwin-tdep.h
943 if BFD64 is defined.
944 (i386_darwin_fetch_inferior_registers): Add #ifdef BFD64/#endif around
945 64 bits parts.
946 (i386_darwin_store_inferior_registers): Ditto.
947 (darwin_set_sstep): Ditto.
948 (darwin_complete_target): Ditto.
949 (amd64_darwin_sstep_at_sigreturn): Ditto.
950 * configure.tgt: Create a separate entry for x86_64-*-darwin.
951 Add 64 bits support for i386-*-darwin if --enable-64-bit-bfd.
952 * Makefile.in (ALLDEPFILES): Add amd64-darwin-tdep.c, darwin-nat.c,
953 i386-darwin-tdep.c i386-darwin-nat.c
954 (ALL_64_TARGET_OBS): Add amd64-darwin-tdep.o
955
3cb5bea9
PA
9562009-07-02 Pedro Alves <pedro@codesourcery.com>
957
958 * linux-fork.c (forks_exist_p): Drop unnecessary extern.
959 (add_fork, linux_fork_killall, linux_fork_mourn_inferior)
960 (linux_fork_detach): Ditto.
961 (delete_fork_command): Rename to ...
962 (delete_checkpoint_command): ... this.
963 (detach_fork_command): Rename to ...
964 (detach_checkpoint_command): ... this.
965 (info_forks_command): Rename to ...
966 (info_checkpoints_command): ... this.
967 (_initialize_linux_fork): Remove stale comments. Adjust.
968
2277426b
PA
9692009-07-02 Pedro Alves <pedro@codesourcery.com>
970
971 * linux-nat.c (linux_child_follow_fork): If we're staying attached
972 to the child process, enable event reporting on it. Don't handle
973 checkpoints here. Instead, add the child fork to the lwp thread
974 and inferior lists without clobbering the previous inferior. Let
975 the thread_db layer learn about a new child process, even if
976 following the parent.
977 (linux_nat_switch_fork): Delete lwps of the current inferior only,
978 instead of clearing the whole list. Use thread_change_ptid to
979 give the core the illusion the new checkpoint is still the same
980 inferior. Clear the register cache.
981 (linux_handle_extended_wait): Handle checkpoints here.
982 (linux_multi_process): Turn on.
983 * linux-fork.c (struct fork_info) <pc>: Remove field.
984 (init_fork_list): Do not delete the checkpoint from the inferior
985 list (it is not there).
986 (fork_load_infrun_state): Don't switch inferior_ptid here. Pass
987 the new checkpoint's ptid to linux_nat_switch_fork.
988 (fork_save_infrun_state): Make static. Don't stop the pc field of
989 fork_info, it's gone.
990 (linux_fork_mourn_inferior): Don't delete the checkpoint from the
991 inferior list, it's not there.
992 (linux_fork_detach): Ditto.
993 (delete_fork_command): Replace mention of fork/checkpoint by
994 checkpoint only.
995 (detach_fork_command): Likewise. Don't delete the checkpoint from
996 the inferior list.
997 (info_forks_command): Adjust.
998 (restore_detach_fork): Delete.
999 (checkpointing_pid): New.
1000 (linux_fork_checkpointing_p): New.
1001 (save_detach_fork): Delete.
1002 (checkpoint_command): Delete temp_detach_fork. Don't remove
1003 breakpoints, that's a nop. Store the pid of the process we're
1004 checkpointing, and use make_cleanup_restore_integer to restore it.
1005 Don't reinsert breakpoints here.
1006 (process_command, fork_command): Delete.
1007 (restart_command): Update comments to only mention checkpoints,
1008 not forks.
1009 (_initialize_linux_fork): Delete "fork", "process", "info forks"
1010 commands.
1011 * linux-fork.h (fork_save_infrun_state, fork_list): Delete
1012 declarations.
1013 (linux_fork_checkpointing_p): Declare.
1014 * cli/cli-cmds.c (killlist): New.
1015 * cli/cli-cmds.h (killlist): Declare.
1016 * gdbcmd.h (killlist): Declare.
1017 * inferior.c: Include "gdbthread.h".
1018 (detach_inferior_command, kill_inferior_command)
1019 (inferior_command): New.
1020 (info_inferiors_command): Allow specifying a specific inferior id.
1021 (_initialize_inferiors): Register "inferior", "kill inferior" and
1022 "detach inferior" commands.
1023 * infcmd.c (_initialize_infcmd): Make "kill" a prefix command.
1024 * gdbthread.h (any_thread_of_process): Declare.
1025 * thread.c (any_thread_of_process): New.
1026
1027 * NEWS: Mention multi-inferior debugging. Mention 'info
1028 inferiors', 'inferior', 'detach inferior' and 'kill inferior' as
1029 new commands.
1030 (Removed commands): New section, mentioning that 'info forks',
1031 'fork', 'process', 'delete fork' and 'detach fork' are now gone.
1032
59837fe0
UW
10332009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
1034
1035 * gdbarch.sh (current_gdbarch): Remove global variable.
1036 (find_arch_by_info): Remove, inline into ...
1037 (gdbarch_find_by_info): ... this. Remove current_gdbarch swapping.
1038 (deprecated_current_gdbarch_select_hack): Rename to ...
1039 (deprecated_target_gdbarch_select_hack): ... this. Do not set
1040 or access current_gdbarch.
1041 * gdbarch.c, gdbarch.h: Regenerate.
1042
1043 * arch-utils.c (gdbarch_update_p): Update call.
1044 (set_gdbarch_from_file): Likewise.
1045
e17a4113
UW
10462009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
1047
1048 * defs.h (extract_signed_integer, extract_unsigned_integer,
1049 extract_long_unsigned_integer, store_signed_integer,
1050 store_unsigned_integer): Add BYTE_ORDER parameter.
1051 * findvar.c (extract_signed_integer, extract_unsigned_integer,
1052 extract_long_unsigned_integer, store_signed_integer,
1053 store_unsigned_integer): Add BYTE_ORDER parameter. Use it
1054 instead of current_gdbarch.
1055
1056 * gdbcore.h (read_memory_integer, safe_read_memory_integer,
1057 read_memory_unsigned_integer, write_memory_signed_integer,
1058 write_memory_unsigned_integer): Add BYTE_ORDER parameter.
1059 * corefile.c (struct captured_read_memory_integer_arguments): Add
1060 BYTE_ORDER member.
1061 (safe_read_memory_integer): Add BYTE_ORDER parameter. Store it into
1062 struct captured_read_memory_integer_arguments.
1063 (do_captured_read_memory_integer): Pass it to read_memory_integer.
1064 (read_memory_integer): Add BYTE_ORDER parameter. Pass it to
1065 extract_signed_integer.
1066 (read_memory_unsigned_integer): Add BYTE_ORDER parameter. Pass it to
1067 extract_unsigned_integer.
1068 (write_memory_signed_integer): Add BYTE_ORDER parameter. Pass it
1069 to store_signed_integer.
1070 (write_memory_unsigned_integer): Add BYTE_ORDER parameter. Pass it
1071 to store_unsigned_integer.
1072
1073 * target.h (get_target_memory_unsigned): Add BYTE_ORDER parameter.
1074 * target.c (get_target_memory_unsigned): Add BYTE_ORDER parameter.
1075 Pass it to extract_unsigned_integer.
1076
1077
1078 Update calls to extract_signed_integer, extract_unsigned_integer,
1079 extract_long_unsigned_integer, store_signed_integer,
1080 store_unsigned_integer, read_memory_integer,
1081 read_memory_unsigned_integer, safe_read_memory_integer,
1082 write_memory_signed_integer, write_memory_unsigned_integer, and
1083 get_target_memory_unsigned to pass byte order:
1084 * ada-lang.c (ada_value_binop): Update.
1085 * ada-valprint.c (char_at): Update.
1086 * alpha-osf1-tdep.c (alpha_osf1_sigcontext_addr): Update.
1087 * alpha-tdep.c (alpha_lds, alpha_sts, alpha_push_dummy_call,
1088 alpha_extract_return_value, alpha_read_insn,
1089 alpha_get_longjmp_target): Update.
1090 * amd64-linux-tdep.c (amd64_linux_sigcontext_addr): Update.
1091 * amd64obsd-tdep.c (amd64obsd_supply_uthread,
1092 amd64obsd_collect_uthread, amd64obsd_trapframe_cache): Update.
1093 * amd64-tdep.c (amd64_push_dummy_call, amd64_analyze_prologue,
1094 amd64_frame_cache, amd64_sigtramp_frame_cache, fixup_riprel,
1095 amd64_displaced_step_fixup): Update.
1096 * arm-linux-tdep.c (arm_linux_sigreturn_init,
1097 arm_linux_rt_sigreturn_init, arm_linux_supply_gregset): Update.
1098 * arm-tdep.c (thumb_analyze_prologue, arm_skip_prologue,
1099 arm_scan_prologue, arm_push_dummy_call, thumb_get_next_pc,
1100 arm_get_next_pc, arm_extract_return_value, arm_store_return_value,
1101 arm_return_value): Update.
1102 * arm-wince-tdep.c (arm_pe_skip_trampoline_code): Update.
1103 * auxv.c (default_auxv_parse): Update.
1104 * avr-tdep.c (avr_address_to_pointer, avr_pointer_to_address,
1105 avr_scan_prologue, avr_extract_return_value,
1106 avr_frame_prev_register, avr_push_dummy_call): Update.
1107 * bsd-uthread.c (bsd_uthread_check_magic, bsd_uthread_lookup_offset,
1108 bsd_uthread_wait, bsd_uthread_thread_alive,
1109 bsd_uthread_extra_thread_info): Update.
1110 * c-lang.c (c_printstr, print_wchar): Update.
1111 * cp-valprint.c (cp_print_class_member): Update.
1112 * cris-tdep.c (cris_sigcontext_addr, cris_sigtramp_frame_unwind_cache,
1113 cris_push_dummy_call, cris_scan_prologue, cris_store_return_value,
1114 cris_extract_return_value, find_step_target, dip_prefix,
1115 sixteen_bit_offset_branch_op, none_reg_mode_jump_op,
1116 move_mem_to_reg_movem_op, get_data_from_address): Update.
1117 * dwarf2expr.c (dwarf2_read_address, execute_stack_op): Update.
1118 * dwarf2-frame.c (execute_cfa_program): Update.
1119 * dwarf2loc.c (find_location_expression): Update.
1120 * dwarf2read.c (dwarf2_const_value): Update.
1121 * expprint.c (print_subexp_standard): Update.
1122 * findvar.c (unsigned_pointer_to_address, signed_pointer_to_address,
1123 unsigned_address_to_pointer, address_to_signed_pointer,
1124 read_var_value): Update.
1125 * frame.c (frame_unwind_register_signed,
1126 frame_unwind_register_unsigned, get_frame_memory_signed,
1127 get_frame_memory_unsigned): Update.
1128 * frame-unwind.c (frame_unwind_got_constant): Update.
1129 * frv-linux-tdep.c (frv_linux_pc_in_sigtramp,
1130 frv_linux_sigcontext_reg_addr, frv_linux_sigtramp_frame_cache):
1131 Update.
1132 * frv-tdep.c (frv_analyze_prologue, frv_skip_main_prologue,
1133 frv_extract_return_value, find_func_descr,
1134 frv_convert_from_func_ptr_addr, frv_push_dummy_call): Update.
1135 * f-valprint.c (f_val_print): Update.
1136 * gnu-v3-abi.c (gnuv3_decode_method_ptr, gnuv3_make_method_ptr):
1137 Update.
1138 * h8300-tdep.c (h8300_is_argument_spill, h8300_analyze_prologue,
1139 h8300_push_dummy_call, h8300_extract_return_value,
1140 h8300h_extract_return_value, h8300_store_return_value,
1141 h8300h_store_return_value): Update.
1142 * hppabsd-tdep.c (hppabsd_find_global_pointer): Update.
1143 * hppa-hpux-nat.c (hppa_hpux_fetch_register, hppa_hpux_store_register):
1144 Update.
1145 * hppa-hpux-tdep.c (hppa32_hpux_in_solib_call_trampoline,
1146 hppa64_hpux_in_solib_call_trampoline,
1147 hppa_hpux_in_solib_return_trampoline, hppa_hpux_skip_trampoline_code,
1148 hppa_hpux_sigtramp_frame_unwind_cache,
1149 hppa_hpux_sigtramp_unwind_sniffer, hppa32_hpux_find_global_pointer,
1150 hppa64_hpux_find_global_pointer, hppa_hpux_search_pattern,
1151 hppa32_hpux_search_dummy_call_sequence,
1152 hppa64_hpux_search_dummy_call_sequence, hppa_hpux_supply_save_state,
1153 hppa_hpux_unwind_adjust_stub): Update.
1154 * hppa-linux-tdep.c (insns_match_pattern,
1155 hppa_linux_find_global_pointer): Update.
1156 * hppa-tdep.c (hppa_in_function_epilogue_p, hppa32_push_dummy_call,
1157 hppa64_convert_code_addr_to_fptr, hppa64_push_dummy_call,
1158 skip_prologue_hard_way, hppa_frame_cache, hppa_fallback_frame_cache,
1159 hppa_pseudo_register_read, hppa_frame_prev_register_helper,
1160 hppa_match_insns): Update.
1161 * hpux-thread.c (hpux_thread_fetch_registers): Update.
1162 * i386-tdep.c (i386bsd_sigcontext_addr): Update.
1163 * i386-cygwin-tdep.c (core_process_module_section): Update.
1164 * i386-darwin-nat.c (i386_darwin_sstep_at_sigreturn,
1165 amd64_darwin_sstep_at_sigreturn): Update.
1166 * i386-darwin-tdep.c (i386_darwin_sigcontext_addr,
1167 amd64_darwin_sigcontext_addr): Likewise.
1168 * i386-linux-nat.c (i386_linux_sigcontext_addr): Update.
1169 * i386nbsd-tdep.c (i386nbsd_sigtramp_cache_init): Update.
1170 * i386-nto-tdep.c (i386nto_sigcontext_addr): Update.
1171 * i386obsd-nat.c (i386obsd_supply_pcb): Update.
1172 * i386obsd-tdep.c (i386obsd_supply_uthread, i386obsd_collect_uthread,
1173 i386obsd_trapframe_cache): Update.
1174 * i386-tdep.c (i386_displaced_step_fixup, i386_follow_jump,
1175 i386_analyze_frame_setup, i386_analyze_prologue,
1176 i386_skip_main_prologue, i386_frame_cache, i386_sigtramp_frame_cache,
1177 i386_get_longjmp_target, i386_push_dummy_call,
1178 i386_pe_skip_trampoline_code, i386_svr4_sigcontext_addr,
1179 i386_fetch_pointer_argument): Update.
1180 * i387-tdep.c (i387_supply_fsave): Update.
1181 * ia64-linux-tdep.c (ia64_linux_sigcontext_register_address): Update.
1182 * ia64-tdep.c (ia64_pseudo_register_read, ia64_pseudo_register_write,
1183 examine_prologue, ia64_frame_cache, ia64_frame_prev_register,
1184 ia64_sigtramp_frame_cache, ia64_sigtramp_frame_prev_register,
1185 ia64_access_reg, ia64_access_rse_reg, ia64_libunwind_frame_this_id,
1186 ia64_libunwind_frame_prev_register,
1187 ia64_libunwind_sigtramp_frame_this_id,
1188 ia64_libunwind_sigtramp_frame_prev_register, ia64_find_global_pointer,
1189 find_extant_func_descr, find_func_descr,
1190 ia64_convert_from_func_ptr_addr, ia64_push_dummy_call, ia64_dummy_id,
1191 ia64_unwind_pc): Update.
1192 * iq2000-tdep.c (iq2000_pointer_to_address, iq2000_address_to_pointer,
1193 iq2000_scan_prologue, iq2000_extract_return_value,
1194 iq2000_push_dummy_call): Update.
1195 * irix5nat.c (fill_gregset): Update.
1196 * jv-lang.c (evaluate_subexp_java): Update.
1197 * jv-valprint.c (java_value_print): Update.
1198 * lm32-tdep.c (lm32_analyze_prologue, lm32_push_dummy_call,
1199 lm32_extract_return_value, lm32_store_return_value): Update.
1200 * m32c-tdep.c (m32c_push_dummy_call, m32c_return_value,
1201 m32c_skip_trampoline_code, m32c_m16c_address_to_pointer,
1202 m32c_m16c_pointer_to_address): Update.
1203 * m32r-tdep.c (m32r_store_return_value, decode_prologue,
1204 m32r_skip_prologue, m32r_push_dummy_call, m32r_extract_return_value):
1205 Update.
1206 * m68hc11-tdep.c (m68hc11_pseudo_register_read,
1207 m68hc11_pseudo_register_write, m68hc11_analyze_instruction,
1208 m68hc11_push_dummy_call): Update.
1209 * m68linux-tdep.c (m68k_linux_pc_in_sigtramp,
1210 m68k_linux_get_sigtramp_info, m68k_linux_sigtramp_frame_cache):
1211 Update.
1212 * m68k-tdep.c (m68k_push_dummy_call, m68k_analyze_frame_setup,
1213 m68k_analyze_register_saves, m68k_analyze_prologue, m68k_frame_cache,
1214 m68k_get_longjmp_target): Update.
1215 * m88k-tdep.c (m88k_fetch_instruction): Update.
1216 * mep-tdep.c (mep_pseudo_cr32_read, mep_pseudo_csr_write,
1217 mep_pseudo_cr32_write, mep_get_insn, mep_push_dummy_call): Update.
1218 * mi/mi-main.c (mi_cmd_data_write_memory): Update.
1219 * mips-linux-tdep.c (mips_linux_get_longjmp_target, supply_32bit_reg,
1220 mips64_linux_get_longjmp_target, mips64_fill_gregset,
1221 mips64_fill_fpregset, mips_linux_in_dynsym_stub): Update.
1222 * mipsnbdsd-tdep.c (mipsnbsd_get_longjmp_target): Update.
1223 * mips-tdep.c (mips_fetch_instruction, fetch_mips_16,
1224 mips_eabi_push_dummy_call, mips_n32n64_push_dummy_call,
1225 mips_o32_push_dummy_call, mips_o64_push_dummy_call,
1226 mips_single_step_through_delay, mips_skip_pic_trampoline_code,
1227 mips_integer_to_address): Update.
1228 * mn10300-tdep.c (mn10300_analyze_prologue, mn10300_push_dummy_call):
1229 Update.
1230 * monitor.c (monitor_supply_register, monitor_write_memory,
1231 monitor_read_memory_single): Update.
1232 * moxie-tdep.c (moxie_store_return_value, moxie_extract_return_value,
1233 moxie_analyze_prologue): Update.
1234 * mt-tdep.c (mt_return_value, mt_skip_prologue, mt_select_coprocessor,
1235 mt_pseudo_register_read, mt_pseudo_register_write, mt_registers_info,
1236 mt_push_dummy_call): Update.
1237 * objc-lang.c (read_objc_method, read_objc_methlist_nmethods,
1238 read_objc_methlist_method, read_objc_object, read_objc_super,
1239 read_objc_class, find_implementation_from_class): Update.
1240 * ppc64-linux-tdep.c (ppc64_desc_entry_point,
1241 ppc64_linux_convert_from_func_ptr_addr, ppc_linux_sigtramp_cache):
1242 Update.
1243 * ppcobsd-tdep.c (ppcobsd_sigtramp_frame_sniffer,
1244 ppcobsd_sigtramp_frame_cache): Update.
1245 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call,
1246 do_ppc_sysv_return_value, ppc64_sysv_abi_push_dummy_call,
1247 ppc64_sysv_abi_return_value): Update.
1248 * ppc-linux-nat.c (ppc_linux_auxv_parse): Update.
1249 * procfs.c (procfs_auxv_parse): Update.
1250 * p-valprint.c (pascal_val_print): Update.
1251 * regcache.c (regcache_raw_read_signed, regcache_raw_read_unsigned,
1252 regcache_raw_write_signed, regcache_raw_write_unsigned,
1253 regcache_cooked_read_signed, regcache_cooked_read_unsigned,
1254 regcache_cooked_write_signed, regcache_cooked_write_unsigned): Update.
1255 * remote-m32r-sdi.c (m32r_fetch_register): Update.
1256 * remote-mips.c (mips_wait, mips_fetch_registers, mips_xfer_memory):
1257 Update.
1258 * rs6000-aix-tdep.c (rs6000_push_dummy_call, rs6000_return_value,
1259 rs6000_convert_from_func_ptr_addr, branch_dest,
1260 rs6000_software_single_step): Update.
1261 * rs6000-tdep.c (rs6000_in_function_epilogue_p,
1262 ppc_displaced_step_fixup, ppc_deal_with_atomic_sequence,
1263 bl_to_blrl_insn_p, rs6000_fetch_instruction, skip_prologue,
1264 rs6000_skip_main_prologue, rs6000_skip_trampoline_code,
1265 rs6000_frame_cache): Update.
1266 * s390-tdep.c (s390_pseudo_register_read, s390_pseudo_register_write,
1267 s390x_pseudo_register_read, s390x_pseudo_register_write, s390_load,
1268 s390_backchain_frame_unwind_cache, s390_sigtramp_frame_unwind_cache,
1269 extend_simple_arg, s390_push_dummy_call, s390_return_value): Update.
1270 * scm-exp.c (scm_lreadr): Update.
1271 * scm-lang.c (scm_get_field, scm_unpack): Update.
1272 * scm-valprint.c (scm_val_print): Update.
1273 * score-tdep.c (score_breakpoint_from_pc, score_push_dummy_call,
1274 score_fetch_inst): Update.
1275 * sh64-tdep.c (look_for_args_moves, sh64_skip_prologue_hard_way,
1276 sh64_analyze_prologue, sh64_push_dummy_call, sh64_extract_return_value,
1277 sh64_pseudo_register_read, sh64_pseudo_register_write,
1278 sh64_frame_prev_register): Update:
1279 * sh-tdep.c (sh_analyze_prologue, sh_push_dummy_call_fpu,
1280 sh_push_dummy_call_nofpu, sh_extract_return_value_nofpu,
1281 sh_store_return_value_nofpu, sh_in_function_epilogue_p): Update.
1282 * solib-darwin.c (darwin_load_image_infos): Update.
1283 * solib-frv.c (fetch_loadmap, lm_base, frv_current_sos, enable_break2,
1284 find_canonical_descriptor_in_load_object): Update.
1285 * solib-irix.c (extract_mips_address, fetch_lm_info, irix_current_sos,
1286 irix_open_symbol_file_object): Update.
1287 * solib-som.c (som_solib_create_inferior_hook, link_map_start,
1288 som_current_sos, som_open_symbol_file_object): Update.
1289 * solib-sunos.c (SOLIB_EXTRACT_ADDRESS, LM_ADDR, LM_NEXT, LM_NAME):
1290 Update.
1291 * solib-svr4.c (read_program_header, scan_dyntag_auxv,
1292 solib_svr4_r_ldsomap): Update.
1293 * sparc64-linux-tdep.c (sparc64_linux_step_trap): Update.
1294 * sparc64obsd-tdep.c (sparc64obsd_supply_uthread,
1295 sparc64obsd_collect_uthread): Update.
1296 * sparc64-tdep.c (sparc64_pseudo_register_read,
1297 sparc64_pseudo_register_write, sparc64_supply_gregset,
1298 sparc64_collect_gregset): Update.
1299 * sparc-linux-tdep.c (sparc32_linux_step_trap): Update.
1300 * sparcobsd-tdep.c (sparc32obsd_supply_uthread,
1301 sparc32obsd_collect_uthread): Update.
1302 * sparc-tdep.c (sparc_fetch_wcookie, sparc32_push_dummy_code,
1303 sparc32_store_arguments, sparc32_return_value, sparc_supply_rwindow,
1304 sparc_collect_rwindow): Update.
1305 * spu-linux-nat.c (parse_spufs_run): Update.
1306 * spu-tdep.c (spu_pseudo_register_read_spu,
1307 spu_pseudo_register_write_spu, spu_pointer_to_address,
1308 spu_analyze_prologue, spu_in_function_epilogue_p,
1309 spu_frame_unwind_cache, spu_push_dummy_call, spu_software_single_step,
1310 spu_get_longjmp_target, spu_get_overlay_table, spu_overlay_update_osect,
1311 info_spu_signal_command, info_spu_mailbox_list, info_spu_dma_cmdlist,
1312 info_spu_dma_command, info_spu_proxydma_command): Update.
1313 * stack.c (print_frame_nameless_args, frame_info): Update.
1314 * symfile.c (read_target_long_array, simple_read_overlay_table,
1315 simple_read_overlay_region_table): Update.
1316 * target.c (debug_print_register): Update.
1317 * tramp-frame.c (tramp_frame_start): Update.
1318 * v850-tdep.c (v850_analyze_prologue, v850_push_dummy_call,
1319 v850_extract_return_value, v850_store_return_value,
1320 * valarith.c (value_binop, value_bit_index): Update.
1321 * valops.c (value_cast): Update.
1322 * valprint.c (val_print_type_code_int, val_print_string,
1323 read_string): Update.
1324 * value.c (unpack_long, unpack_double, unpack_field_as_long,
1325 modify_field, pack_long): Update.
1326 * vax-tdep.c (vax_store_arguments, vax_push_dummy_call,
1327 vax_skip_prologue): Update.
1328 * xstormy16-tdep.c (xstormy16_push_dummy_call,
1329 xstormy16_analyze_prologue, xstormy16_in_function_epilogue_p,
1330 xstormy16_resolve_jmp_table_entry, xstormy16_find_jmp_table_entry,
1331 xstormy16_pointer_to_address, xstormy16_address_to_pointer): Update.
1332 * xtensa-tdep.c (extract_call_winsize, xtensa_pseudo_register_read,
1333 xtensa_pseudo_register_write, xtensa_frame_cache,
1334 xtensa_push_dummy_call, call0_track_op, call0_frame_cache): Update.
1335
1336
1337 * dfp.h (decimal_to_string, decimal_from_string, decimal_from_integral,
1338 decimal_from_floating, decimal_to_doublest, decimal_is_zero): Add
1339 BYTE_ORDER parameter.
1340 (decimal_binop): Add BYTE_ORDER_X, BYTE_ORDER_Y, and BYTE_ORDER_RESULT
1341 parameters.
1342 (decimal_compare): Add BYTE_ORDER_X and BYTE_ORDER_Y parameters.
1343 (decimal_convert): Add BYTE_ORDER_FROM and BYTE_ORDER_TO parameters.
1344 * dfp.c (match_endianness): Add BYTE_ORDER parameter. Use it
1345 instead of current_gdbarch.
1346 (decimal_to_string, decimal_from_integral, decimal_from_floating,
1347 decimal_to_doublest, decimal_is_zero): Add BYTE_ORDER parameter.
1348 Pass it to match_endianness.
1349 (decimal_binop): Add BYTE_ORDER_X, BYTE_ORDER_Y, and BYTE_ORDER_RESULT
1350 parameters. Pass them to match_endianness.
1351 (decimal_compare): Add BYTE_ORDER_X and BYTE_ORDER_Y parameters.
1352 Pass them to match_endianness.
1353 (decimal_convert): Add BYTE_ORDER_FROM and BYTE_ORDER_TO parameters.
1354 Pass them to match_endianness.
1355 * valarith.c (value_args_as_decimal): Add BYTE_ORDER_X and
1356 BYTE_ORDER_Y output parameters.
1357 (value_binop): Update call to value_args_as_decimal.
1358
1359 Update calls to decimal_to_string, decimal_from_string,
1360 decimal_from_integral, decimal_from_floating, decimal_to_doublest,
1361 decimal_is_zero, decimal_binop, decimal_compare and decimal_convert
1362 to pass/receive byte order:
1363 * c-exp.y (parse_number): Update.
1364 * printcmd.c (printf_command): Update.
1365 * valarith.c (value_args_as_decimal, value_binop, value_logical_not,
1366 value_equal, value_less): Update.
1367 * valops.c (value_cast, value_one): Update.
1368 * valprint.c (print_decimal_floating): Update.
1369 * value.c (unpack_long, unpack_double): Update.
1370 * python/python-value.c (valpy_nonzero): Update.
1371
1372
1373 * ada-valprint.c (char_at): Add BYTE_ORDER parameter.
1374 (printstr): Update calls to char_at.
1375 (ada_val_print_array): Likewise.
1376 * valprint.c (read_string): Add BYTE_ORDER parameter.
1377 (val_print_string): Update call to read_string.
1378 * c-lang.c (c_get_string): Likewise.
1379 * charset.h (target_wide_charset): Add BYTE_ORDER parameter.
1380 * charset.c (target_wide_charset): Add BYTE_ORDER parameter.
1381 Use it instead of current_gdbarch.
1382 * printcmd.c (printf_command): Update calls to target_wide_charset.
1383 * c-lang.c (charset_for_string_type): Add BYTE_ORDER parameter.
1384 Pass to target_wide_charset. Use it instead of current_gdbarch.
1385 (classify_type): Add BYTE_ORDER parameter. Pass to
1386 charset_for_string_type. Allow NULL encoding pointer.
1387 (print_wchar): Add BYTE_ORDER parameter.
1388 (c_emit_char): Update calls to classify_type and print_wchar.
1389 (c_printchar, c_printstr): Likewise.
1390
1391
1392 * gdbarch.sh (in_solib_return_trampoline): Convert to type "m".
1393 * gdbarch.c, gdbarch.h: Regenerate.
1394 * arch-utils.h (generic_in_solib_return_trampoline): Add GDBARCH
1395 parameter.
1396 * arch-utils.c (generic_in_solib_return_trampoline): Likewise.
1397 * hppa-hpux-tdep.c (hppa_hpux_in_solib_return_trampoline): Likewise.
1398 * rs6000-tdep.c (rs6000_in_solib_return_trampoline): Likewise.
1399 (rs6000_skip_trampoline_code): Update call.
1400
1401 * alpha-tdep.h (struct gdbarch_tdep): Add GDBARCH parameter to
1402 dynamic_sigtramp_offset and pc_in_sigtramp callbacks.
1403 (alpha_read_insn): Add GDBARCH parameter.
1404 * alpha-tdep.c (alpha_lds, alpha_sts): Add GDBARCH parameter.
1405 (alpha_register_to_value): Pass architecture to alpha_sts.
1406 (alpha_extract_return_value): Likewise.
1407 (alpha_value_to_register): Pass architecture to alpha_lds.
1408 (alpha_store_return_value): Likewise.
1409 (alpha_read_insn): Add GDBARCH parameter.
1410 (alpha_skip_prologue): Pass architecture to alpha_read_insn.
1411 (alpha_heuristic_proc_start): Likewise.
1412 (alpha_heuristic_frame_unwind_cache): Likewise.
1413 (alpha_next_pc): Likewise.
1414 (alpha_sigtramp_frame_this_id): Pass architecture to
1415 tdep->dynamic_sigtramp_offset callback.
1416 (alpha_sigtramp_frame_sniffer): Pass architecture to
1417 tdep->pc_in_sigtramp callback.
1418 * alphafbsd-tdep.c (alphafbsd_pc_in_sigtramp): Add GDBARCH parameter.
1419 (alphafbsd_sigtramp_offset): Likewise.
1420 * alpha-linux-tdep.c (alpha_linux_sigtramp_offset_1): Add GDBARCH
1421 parameter. Pass to alpha_read_insn.
1422 (alpha_linux_sigtramp_offset): Add GDBARCH parameter. Pass to
1423 alpha_linux_sigtramp_offset_1.
1424 (alpha_linux_pc_in_sigtramp): Add GDBARCH parameter. Pass to
1425 alpha_linux_sigtramp_offset.
1426 (alpha_linux_sigcontext_addr): Pass architecture to alpha_read_insn
1427 and alpha_linux_sigtramp_offset.
1428 * alphanbsd-tdep.c (alphanbsd_sigtramp_offset): Add GDBARCH parameter.
1429 (alphanbsd_pc_in_sigtramp): Add GDBARCH parameter. Pass to
1430 alphanbsd_sigtramp_offset.
1431 * alphaobsd-tdep.c (alphaobsd_sigtramp_offset): Add GDBARCH parameter.
1432 (alphaobsd_pc_in_sigtramp): Add GDBARCH parameter. Pass to
1433 alpha_read_insn.
1434 (alphaobsd_sigcontext_addr): Pass architecture to
1435 alphaobsd_sigtramp_offset.
1436 * alpha-osf1-tdep.c (alpha_osf1_pc_in_sigtramp): Add GDBARCH
1437 parameter.
1438
1439 * amd64-tdep.c (amd64_analyze_prologue): Add GDBARCH parameter.
1440 (amd64_skip_prologue): Pass architecture to amd64_analyze_prologue.
1441 (amd64_frame_cache): Likewise.
1442
1443 * arm-tdep.c (SWAP_SHORT, SWAP_INT): Remove.
1444 (thumb_analyze_prologue, arm_skip_prologue, arm_scan_prologue,
1445 thumb_get_next_pc, arm_get_next_pc): Do not use SWAP_ macros.
1446 * arm-wince-tdep.c: Include "frame.h".
1447
1448 * avr-tdep.c (EXTRACT_INSN): Remove.
1449 (avr_scan_prologue): Add GDBARCH argument, inline EXTRACT_INSN.
1450 (avr_skip_prologue): Pass architecture to avr_scan_prologue.
1451 (avr_frame_unwind_cache): Likewise.
1452
1453 * cris-tdep.c (struct instruction_environment): Add BYTE_ORDER member.
1454 (find_step_target): Initialize it.
1455 (get_data_from_address): Add BYTE_ORDER parameter.
1456 (bdap_prefix): Pass byte order to get_data_from_address.
1457 (handle_prefix_assign_mode_for_aritm_op): Likewise.
1458 (three_operand_add_sub_cmp_and_or_op): Likewise.
1459 (handle_inc_and_index_mode_for_aritm_op): Likewise.
1460
1461 * frv-linux-tdep.c (frv_linux_pc_in_sigtramp): Add GDBARCH parameter.
1462 (frv_linux_sigcontext_reg_addr): Pass architecture to
1463 frv_linux_pc_in_sigtramp.
1464 (frv_linux_sigtramp_frame_sniffer): Likewise.
1465
1466 * h8300-tdep.c (h8300_is_argument_spill): Add GDBARCH parameter.
1467 (h8300_analyze_prologue): Add GDBARCH parameter. Pass to
1468 h8300_is_argument_spill.
1469 (h8300_frame_cache, h8300_skip_prologue): Pass architecture
1470 to h8300_analyze_prologue.
1471
1472 * hppa-tdep.h (struct gdbarch_tdep): Add GDBARCH parameter to
1473 in_solib_call_trampoline callback.
1474 (hppa_in_solib_call_trampoline): Add GDBARCH parameter.
1475 * hppa-tdep.c (hppa64_convert_code_addr_to_fptr): Add GDBARCH
1476 parameter.
1477 (hppa64_push_dummy_call): Pass architecture to
1478 hppa64_convert_code_addr_to_fptr.
1479 (hppa_match_insns): Add GDBARCH parameter.
1480 (hppa_match_insns_relaxed): Add GDBARCH parameter. Pass to
1481 hppa_match_insns.
1482 (hppa_skip_trampoline_code): Pass architecture to hppa_match_insns.
1483 (hppa_in_solib_call_trampoline): Add GDBARCH parameter. Pass to
1484 hppa_match_insns_relaxed.
1485 (hppa_stub_unwind_sniffer): Pass architecture to
1486 tdep->in_solib_call_trampoline callback.
1487 * hppa-hpux-tdep.c (hppa_hpux_search_pattern): Add GDBARCH parameter.
1488 (hppa32_hpux_search_dummy_call_sequence): Pass architecture to
1489 hppa_hpux_search_pattern.
1490 * hppa-linux-tdep.c (insns_match_pattern): Add GDBARCH parameter.
1491 (hppa_linux_sigtramp_find_sigcontext): Add GDBARCH parameter.
1492 Pass to insns_match_pattern.
1493 (hppa_linux_sigtramp_frame_unwind_cache): Pass architecture to
1494 hppa_linux_sigtramp_find_sigcontext.
1495 (hppa_linux_sigtramp_frame_sniffer): Likewise.
1496 (hppa32_hpux_in_solib_call_trampoline): Add GDBARCH parameter.
1497 (hppa64_hpux_in_solib_call_trampoline): Likewise.
1498
1499 * i386-tdep.c (i386_follow_jump): Add GDBARCH parameter.
1500 (i386_analyze_frame_setup): Add GDBARCH parameter.
1501 (i386_analyze_prologue): Add GDBARCH parameter. Pass to
1502 i386_follow_jump and i386_analyze_frame_setup.
1503 (i386_skip_prologue): Pass architecture to i386_analyze_prologue
1504 and i386_follow_jump.
1505 (i386_frame_cache): Pass architecture to i386_analyze_prologue.
1506 (i386_pe_skip_trampoline_code): Add FRAME parameter.
1507 * i386-tdep.h (i386_pe_skip_trampoline_code): Add FRAME parameter.
1508 * i386-cygwin-tdep.c (i386_cygwin_skip_trampoline_code): Pass
1509 frame to i386_pe_skip_trampoline_code.
1510
1511 * ia64-tdep.h (struct gdbarch_tdep): Add GDBARCH parameter
1512 to sigcontext_register_address callback.
1513 * ia64-tdep.c (ia64_find_global_pointer): Add GDBARCH parameter.
1514 (ia64_find_unwind_table): Pass architecture to
1515 ia64_find_global_pointer.
1516 (find_extant_func_descr): Add GDBARCH parameter.
1517 (find_func_descr): Pass architecture to find_extant_func_descr
1518 and ia64_find_global_pointer.
1519 (ia64_sigtramp_frame_init_saved_regs): Pass architecture to
1520 tdep->sigcontext_register_address callback.
1521 * ia64-linux-tdep.c (ia64_linux_sigcontext_register_address): Add
1522 GDBARCH parameter.
1523
1524 * iq2000-tdep.c (iq2000_scan_prologue): Add GDBARCH parameter.
1525 (iq2000_frame_cache): Pass architecture to iq2000_scan_prologue.
1526
1527 * lm32-tdep.c (lm32_analyze_prologue): Add GDBARCH parameter.
1528 (lm32_skip_prologue, lm32_frame_cache): Pass architecture to
1529 lm32_analyze_prologue.
1530
1531 * m32r-tdep.c (decode_prologue): Add GDBARCH parameter.
1532 (m32r_skip_prologue): Pass architecture to decode_prologue.
1533
1534 * m68hc11-tdep.c (m68hc11_analyze_instruction): Add GDBARCH parameter.
1535 (m68hc11_scan_prologue): Pass architecture to
1536 m68hc11_analyze_instruction.
1537
1538 * m68k-tdep.c (m68k_analyze_frame_setup): Add GDBARCH parameter.
1539 (m68k_analyze_prologue): Pass architecture to
1540 m68k_analyze_frame_setup.
1541
1542 * m88k-tdep.c (m88k_fetch_instruction): Add BYTE_ORDER parameter.
1543 (m88k_analyze_prologue): Add GDBARCH parameter. Pass byte order
1544 to m88k_fetch_instruction.
1545 (m88k_skip_prologue): Pass architecture to m88k_analyze_prologue.
1546 (m88k_frame_cache): Likewise.
1547
1548 * mep-tdep.c (mep_get_insn): Add GDBARCH parameter.
1549 (mep_analyze_prologue): Pass architecture to mep_get_insn.
1550
1551 * mips-tdep.c (mips_fetch_instruction): Add GDBARCH parameter.
1552 (mips32_next_pc): Pass architecture to mips_fetch_instruction.
1553 (deal_with_atomic_sequence): Likewise.
1554 (unpack_mips16): Add GDBARCH parameter, pass to mips_fetch_instruction.
1555 (mips16_scan_prologue): Likewise.
1556 (mips32_scan_prologue): Likewise.
1557 (mips16_in_function_epilogue_p): Likewise.
1558 (mips32_in_function_epilogue_p): Likewise.
1559 (mips_about_to_return): Likewise.
1560 (mips_insn16_frame_cache): Pass architecture to mips16_scan_prologue.
1561 (mips_insn32_frame_cache): Pass architecture to mips32_scan_prologue.
1562 (mips_skip_prologue): Pass architecture to mips16_scan_prologue
1563 and mips32_scan_prologue.
1564 (mips_in_function_epilogue_p): Pass architecture to
1565 mips16_in_function_epilogue_p and
1566 mips32_in_function_epilogue_p.
1567 (heuristic_proc_start): Pass architecture to mips_fetch_instruction
1568 and mips_about_to_return.
1569 (mips_skip_mips16_trampoline_code): Pass architecture to
1570 mips_fetch_instruction.
1571 (fetch_mips_16): Add GDBARCH parameter.
1572 (mips16_next_pc): Pass architecture to fetch_mips_16.
1573 (extended_mips16_next_pc): Pass architecture to unpack_mips16 and
1574 fetch_mips_16.
1575
1576 * objc-lang.c (read_objc_method, read_objc_methlist_nmethods,
1577 read_objc_methlist_method, read_objc_object, read_objc_super,
1578 read_objc_class): Add GDBARCH parameter.
1579 (find_implementation_from_class): Add GDBARCH parameter, pass
1580 to read_objc_class, read_objc_methlist_nmethods, and
1581 read_objc_methlist_method.
1582 (find_implementation): Add GDBARCH parameter, pass to
1583 read_objc_object and find_implementation_from_class.
1584 (resolve_msgsend, resolve_msgsend_stret): Pass architecture
1585 to find_implementation.
1586 (resolve_msgsend_super, resolve_msgsend_super_stret): Pass
1587 architecture to read_objc_super and find_implementation_from_class.
1588
1589 * ppc64-linux-tdep.c (ppc64_desc_entry_point): Add GDBARCH parameter.
1590 (ppc64_standard_linkage1_target, ppc64_standard_linkage2_target,
1591 ppc64_standard_linkage3_target): Pass architecture to
1592 ppc64_desc_entry_point.
1593 * rs6000-tdep.c (bl_to_blrl_insn_p): Add BYTE_ORDER parameter.
1594 (skip_prologue): Pass byte order to bl_to_blrl_insn_p.
1595 (rs6000_fetch_instruction): Add GDBARCH parameter.
1596 (rs6000_skip_stack_check): Add GDBARCH parameter, pass to
1597 rs6000_fetch_instruction.
1598 (skip_prologue): Pass architecture to rs6000_fetch_instruction.
1599
1600 * remote-mips.c (mips_store_word): Return old_contents as host
1601 integer value instead of target bytes.
1602
1603 * s390-tdep.c (struct s390_prologue_data): Add BYTE_ORDER member.
1604 (s390_analyze_prologue): Initialize it.
1605 (extend_simple_arg): Add GDBARCH parameter.
1606 (s390_push_dummy_call): Pass architecture to extend_simple_arg.
1607
1608 * scm-lang.c (scm_get_field): Add BYTE_ORDER parameter.
1609 * scm-lang.h (scm_get_field): Add BYTE_ORDER parameter.
1610 (SCM_CAR, SCM_CDR): Pass SCM_BYTE_ORDER to scm_get_field.
1611 * scm-valprint.c (scm_scmval_print): Likewise.
1612 (scm_scmlist_print, scm_ipruk, scm_scmval_print): Define
1613 SCM_BYTE_ORDER.
1614
1615 * sh64-tdep.c (look_for_args_moves): Add GDBARCH parameter.
1616 (sh64_skip_prologue_hard_way): Add GDBARCH parameter, pass to
1617 look_for_args_moves.
1618 (sh64_skip_prologue): Pass architecture to
1619 sh64_skip_prologue_hard_way.
1620 * sh-tdep.c (sh_analyze_prologue): Add GDBARCH parameter.
1621 (sh_skip_prologue): Pass architecture to sh_analyze_prologue.
1622 (sh_frame_cache): Likewise.
1623
1624 * solib-irix.c (extract_mips_address): Add GDBARCH parameter.
1625 (fetch_lm_info, irix_current_sos, irix_open_symbol_file_object):
1626 Pass architecture to extract_mips_address.
1627
1628 * sparc-tdep.h (sparc_fetch_wcookie): Add GDBARCH parameter.
1629 * sparc-tdep.c (sparc_fetch_wcookie): Add GDBARCH parameter.
1630 (sparc_supply_rwindow, sparc_collect_rwindow): Pass architecture
1631 to sparc_fetch_wcookie.
1632 (sparc32_frame_prev_register): Likewise.
1633 * sparc64-tdep.c (sparc64_frame_prev_register): Likewise.
1634 * sparc32nbsd-tdep.c (sparc32nbsd_sigcontext_saved_regs): Likewise.
1635 * sparc64nbsd-tdep.c (sparc64nbsd_sigcontext_saved_regs): Likewise.
1636
1637 * spu-tdep.c (spu_analyze_prologue): Add GDBARCH parameter.
1638 (spu_skip_prologue): Pass architecture to spu_analyze_prologue.
1639 (spu_virtual_frame_pointer): Likewise.
1640 (spu_frame_unwind_cache): Likewise.
1641 (info_spu_mailbox_list): Add BYTE_ORER parameter.
1642 (info_spu_mailbox_command): Pass byte order to info_spu_mailbox_list.
1643 (info_spu_dma_cmdlist): Add BYTE_ORER parameter.
1644 (info_spu_dma_command, info_spu_proxydma_command): Pass byte order
1645 to info_spu_dma_cmdlist.
1646
1647 * symfile.c (read_target_long_array): Add GDBARCH parameter.
1648 (simple_read_overlay_table, simple_read_overlay_region_table,
1649 simple_overlay_update_1): Pass architecture to read_target_long_array.
1650
1651 * v850-tdep.c (v850_analyze_prologue): Add GDBARCH parameter.
1652 (v850_frame_cache): Pass architecture to v850_analyze_prologue.
1653
1654 * xstormy16-tdep.c (xstormy16_analyze_prologue): Add GDBARCH
1655 parameter.
1656 (xstormy16_skip_prologue, xstormy16_frame_cache): Pass architecture
1657 to xstormy16_analyze_prologue.
1658 (xstormy16_resolve_jmp_table_entry): Add GDBARCH parameter.
1659 (xstormy16_find_jmp_table_entry): Likewise.
1660 (xstormy16_skip_trampoline_code): Pass architecture to
1661 xstormy16_resolve_jmp_table_entry.
1662 (xstormy16_pointer_to_address): Likewise.
1663 (xstormy16_address_to_pointer): Pass architecture to
1664 xstormy16_find_jmp_table_entry.
1665
1666 * xtensa-tdep.c (call0_track_op): Add GDBARCH parameter.
1667 (call0_analyze_prologue): Add GDBARCH parameter, pass to
1668 call0_track_op.
1669 (call0_frame_cache): Pass architecture to call0_analyze_prologue.
1670 (xtensa_skip_prologue): Likewise.
1671
5af949e3
UW
16722009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
1673
1674 * defs.h (strlen_paddr, paddr, paddr_nz): Remove.
1675 (paddress): Add GDBARCH parameter.
1676 * utils.c (strlen_paddr, paddr, paddr_nz): Remove.
1677 (paddress): Add GDBARCH parameter, use it instead of current_gdbarch.
1678 * ui-out.h (ui_out_field_core_addr): Add GDBARCH parameter.
1679 * ui-out.c (ui_out_field_core_addr): Add GDBARCH parameter,
1680 use it instead of current_gdbarch.
1681
1682 Update calls to ui_out_field_core_addr to pass architecture:
1683 * ada-lang.c (print_one_exception): Update.
1684 * breakpoint.c (print_one_breakpoint_location,
1685 print_one_exception_catchpoint): Update.
1686 * disasm.c (dump_insns): Update.
1687 * darwin-nat-info.c (darwin_debug_regions_recurse): Update.
1688 * mi/mi-main.c (mi_cmd_data_read_memory): Update.
1689 * mi/mi-symbol-cmds.c: Include "objfiles.h".
1690 (mi_cmd_symbol_list_lines): Update.
1691 * stack.c (print_frame_info, print_frame): Update.
1692
1693 Update callers of paddress to pass architecture:
1694 * ada-tasks.c (info_task): Update.
1695 * ada-valprint.c (ada_val_print_1): Update.
1696 * annotate.c (annotate_source, annotate_frame_begin): Update.
1697 * breakpoint.c (insert_bp_location, describe_other_breakpoints,
1698 mention): Update.
1699 * cli/cli-cmds.c (edit_command, list_command, print_disassembly):
1700 Update.
1701 * corefile.c (memory_error): Update.
1702 * c-valprint.c (print_function_pointer_address, c_val_print): Update.
1703 * disasm.c (dis_asm_print_address): Update.
1704 * exec.c (print_section_info): Update.
1705 * f-valprint.c (f_val_print): Update.
1706 * infcmd.c: Include "arch-utils.h".
1707 (jump_command, program_info): Update.
1708 * linux-fork.c: Include "arch-utils.h".
1709 (info_forks_command): Update.
1710 * m2-valprint.c (print_function_pointer_address,
1711 print_unpacked_pointer, print_variable_at_address,
1712 m2_val_print): Update.
1713 * m32r-rom.c (m32r_load_section, m32r_load, m32r_upload_command):
1714 Update.
1715 * printcmd.c (print_address, print_address_demangle, address_info):
1716 Update.
1717 * p-valprint.c (pascal_val_print): Update.
1718 * source.c: Include "arch-utils.h".
1719 (line_info): Update.
1720 * stack.c (frame_info, print_block_frame_labels): Update.
1721 * symfile.c (add_symbol_file_command, list_overlays_command): Update.
1722 * symmisc.c (dump_msymbols, dump_psymtab, dump_symtab_1,
1723 print_symbol, print_partial_symbols, maintenance_info_psymtabs,
1724 maintenance_check_symtabs): Update.
1725 * symtab.c (find_pc_sect_symtab): Update.
1726 * target.c (deprecated_debug_xfer_memory): Update.
1727 * tracepoint.c (scope_info): Update.
1728 * tui/tui-stack.c (tui_make_status_line): Update.
1729 * valprint.c (val_print_string): Update.
1730
1731 Update callers of paddr_nz to use paddress instead (keeping
1732 user-visible output identical):
1733 * alpha-tdep.c (alpha_heuristic_proc_start): Update.
1734 * amd64-tdep.c (fixup_riprel, amd64_displaced_step_copy_insn,
1735 amd64_displaced_step_fixup): Update.
1736 * arch-utils.c (simple_displaced_step_copy_insn): Update.
1737 * auxv.c (fprint_target_auxv): Update.
1738 * breakpoint.c (insert_single_step_breakpoint): Update.
1739 * buildsym.c (finish_block): Update.
1740 * cli/cli-dump.c (restore_section_callback): Update.
1741 * fbsd-nat.c (fbsd_find_memory_regions): Update.
1742 * frame.c (frame_unwind_register_value): Update.
1743 * gcore.c (gcore_create_callback): Update.
1744 * hppa-tdep.c (hppa_frame_cache, hppa_skip_trampoline_code): Update.
1745 * i386-tdep.c (i386_displaced_step_fixup, i386_record_modrm,
1746 i386_record_lea_modrm_addr, i386_record_lea_modrm,
1747 i386_process_record): Update.
1748 * ia64-tdep.c (ia64_frame_this_id, ia64_sigtramp_frame_this_id,
1749 ia64_libunwind_frame_this_id, ia64_libunwind_sigtramp_frame_this_id,
1750 ia64_dummy_id, ia64_access_reg, ia64_access_rse_reg): Update.
1751 * infrun.c (displaced_step_prepare, displaced_step_fixup,
1752 handle_inferior_event, insert_step_resume_breakpoint_at_sal,
1753 insert_longjmp_resume_breakpoint): Update.
1754 * linux-nat.c (linux_nat_find_memory_regions): Update.
1755 * linux-record.c (record_linux_system_call): Update.
1756 * mips-tdep.c (heuristic_proc_start, mips_eabi_push_dummy_call,
1757 mips_n32n64_push_dummy_call, mips_o32_push_dummy_call,
1758 mips_o64_push_dummy_call): Update.
1759 * monitor.c (monitor_error, monitor_remove_breakpoint): Update.
1760 * record.c (record_arch_list_add_mem, record_wait,
1761 record_xfer_partial): Update.
1762 * remote-mips.c (mips_fetch_word, mips_check_lsi_error,
1763 mips_common_breakpoint): Update.
1764 * remote-sim.c (gdbsim_xfer_inferior_memory): Update.
1765 * rs6000-tdep.c (ppc_displaced_step_fixup): Update.
1766 * solib-som.c (som_current_sos): Update.
1767 * symfile.c (load_progress, generic_load): Update.
1768 * symfile-mem.c (add_vsyscall_page): Update.
1769 * valops.c (value_fetch_lazy): Update.
1770 * windows-tdep.c (windows_xfer_shared_library): Update.
1771
1772 Update callers of paddr_nz to use paddress instead (changing
1773 user-visible output to make it more correct):
1774 * dwarf2loc.c (locexpr_describe_location): Update.
1775 * ia64-tdep.c (ia64_memory_insert_breakpoint,
1776 ia64_memory_remove_breakpoint): Update.
1777 * jv-valprint.c (java_value_print): Update.
1778 * m32c-tdep.c (m32c_m16c_address_to_pointer): Update.
1779 * monitor.c (monitor_read_memory): Update.
1780
1781 Update callers of paddr to use paddress instead (changing
1782 user-visible output to make it more correct):
1783 * arm-tdep.c (arm_push_dummy_call): Update.
1784 * breakpoint.c (insert_bp_location, create_thread_event_breakpoint,
1785 create_breakpoint): Update.
1786 * darwin-nat-info.c (darwin_debug_regions): Update.
1787 * dcache.c (dcache_info): Update.
1788 * dsrec.c (load_srec, make_srec): Update.
1789 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program,
1790 dwarf2_frame_cache): Update.
1791 * gcore.c (gcore_copy_callback): Update.
1792 * gnu-nat.c (gnu_xfer_memory): Update.
1793 * mips-linux-nat.c (mips_show_dr): Update.
1794 * monitor.c (monitor_write_memory, monitor_insert_breakpoint,
1795 monitor_remove_breakpoint): Update.
1796 * remote.c (compare_sections_command): Update.
1797 * remote-m32r-sdi.c (m32r_xfer_memory, m32r_insert_breakpoint,
1798 m32r_remove_breakpoint, m32r_insert_watchpoint,
1799 m32r_remove_watchpoint): Update.
1800 * sol-thread.c (info_cb): Update.
1801 * symfile.c (load_progress): Update.
1802
1803 Update callers of paddress or paddr_nz to use hex_string instead
1804 (changes output of internal/error/debug messages only):
1805 * dwarf2read.c (dump_die_shallow): Update.
1806 * frame.c (fprint_field, fprint_frame, frame_pc_unwind,
1807 get_frame_func, create_new_frame): Update.
1808 * hppa-tdep.c (find_unwind_entry, unwind_command): Update.
1809 * ia64-tdep.c (get_kernel_table, ia64_find_proc_info_x,
1810 ia64_get_dyn_info_list): Update.
1811 * maint.c (maintenance_translate_address): Update.
1812 * mi/mi-cmd-var.c (mi_cmd_var_create): Update.
1813 * target.c (target_flash_erase): Update.
1814
1815 Update callers of paddr/paddr_nz to use phex/phex_nz instead,
1816 using an appropriate address size. Remove use of strlen_paddr.
1817 * exec.c (exec_files_info): Update.
1818 * i386-nat.c (i386_show_dr): Update.
1819 * remote.c (remote_flash_erase): Update.
1820 * m32r-rom.c (m32r_load_section): Update.
1821 * monitor.c (monitor_vsprintf, monitor_store_register): Update.
1822 * remote.c (remote_check_symbols, remote_search_memory): Update.
1823 * remote-mips.c (mips_request, mips_common_breakpoint): Update.
1824 * scm-valprint.c (scm_ipruk, scm_scmval_print): Update.
1825 * sh64-tdep.c (sh64_show_media_regs, sh64_show_compact_regs): Update.
1826 * sh-tdep.c (sh_generic_show_regs, sh3_show_regs, sh2e_show_regs,
1827 sh2a_show_regs, sh2a_nofpu_show_regs, sh3e_show_regs,
1828 sh3_dsp_show_regs, sh4_show_regs, sh4_nofpu_show_regs,
1829 sh_dsp_show_regs): Update.
1830 * xcoffsolib.c (sharedlibrary_command): Update.
1831
1832
1833 * maint.c (maint_print_section_info): Add ADDR_SIZE parameter.
1834 Use hex_string_custom instead of paddr.
1835 (print_bfd_section_info): Pass address size.
1836 (print_objfile_section_info): Likewise.
1837
1838 * annotate.h (annotate_source): Add GDBARCH parameter.
1839 (annotate_frame_begin): Likewise.
1840 * annotate.c (annotate_source): Add GDBARCH parameter.
1841 (annotate_frame_begin): Likewise.
1842 * source.c (identify_source_line): Update call to annotate_source.
1843 * stack.c (print_frame_info, print_frame): Update call to
1844 annotate_frame_begin.
1845
1846 * breakpoint.c (describe_other_breakpoints): Add GDBARCH parameter.
1847 (create_breakpoint, create_ada_exception_breakpoint): Update call.
1848
1849 * stack.c (print_block_frame_labels): Add GDBARCH parameter.
1850 (print_frame_label_vars): Update call.
1851
1852 * symmisc.c (print_partial_symbols): Add GDBARCH parameter.
1853 (dump_psymtab): Update call to print_partial_symbols.
1854 (struct print_symbol_args): Add GDBARCH member.
1855 (dump_symtab_1): Set print_symbol_args architecture member.
1856 (print_symbol): Use it.
1857
1858 * windows-tdep.h (windows_xfer_shared_library): Add GDBARCH
1859 parameter.
1860 * windows-tdep.c (windows_xfer_shared_library): Likewise.
1861 * i386-cygwin-tdep.c (struct cpms_data): Add GDBARCH member.
1862 (core_process_module_section): Pass architecture from cpms_data to
1863 windows_xfer_shared_library.
1864 (windows_core_xfer_shared_libraries): Initialize cmps_data
1865 architecture member.
1866 * windows-nat.c (windows_xfer_shared_libraries): Pass architecture
1867 to windows_xfer_shared_library.
1868
1869 * defs.h (print_address): Add GDBARCH parameter.
1870 * printcmd.c (print_address): Add GDBARCH parameter.
1871 (print_scalar_formatted, do_examine): Update call.
1872 * findcmd.c (find_command): Update call.
1873 * tracepoint.c: Include "arch-utils.h".
1874 (trace_find_line_command): Update call.
1875 * tui/tui-disasm.c (tui_disassemble): Update call.
1876
1877 * value.h (print_address_demangle): Add GDBARCH parameter.
1878 * printcmd.c (print_address_demangle): Add GDBARCH parameter.
1879 * c-valprint.c (print_function_pointer_address, c_val_print):
1880 Update call.
1881 * f-valprint.c (f_val_print): Update call.
1882 * gnu-v3-abi.c (gnuv3_print_method_ptr): Update call.
1883 * jv-valprint.c (java_val_print): Update call.
1884 * m2-valprint.c (print_function_pointer_address, m2_val_print):
1885 Update call.
1886 * p-valprint.c (pascal_val_print): Update call.
1887
1888 * disasm.c (gdb_disassemble_info): Install architecture into
1889 di.application_data field.
1890
13274fc3
UW
18912009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
1892
1893 * disasm.h (gdb_disassembly): Add GDBARCH parameter.
1894 (gdb_print_insn): Likewise.
1895 * disasm.c (dump_insns): Add GDBARCH parameter. Use it instead
1896 of current_gdbarch.
1897 (do_mixed_source_and_assembly): Add GDBARCH parameter. Pass to
1898 dump_insns.
1899 (do_assembly_only): Likewise.
1900 (gdb_disassembly): Add GDBARCH parameter. Use it instead of
1901 current_gdbarch. Pass to subroutines.
1902 (gdb_print_insn): Add GDBARCH parameter. Use it instead of
1903 current_gdbarch.
1904
1905 * stack.c (struct gdb_disassembly_stub_args): Add GDBARCH member.
1906 (gdb_disassembly_stub): Pass architecture to gdb_disassembly.
1907 (do_gdb_disassembly): Add GDBARCH argument. Store into args.
1908 (print_frame_info): Pass architecture to do_gdb_disassembly.
1909
1910 * printcmd.c (print_formatted): Pass architecture to gdb_print_insn.
1911
1912 * mi/mi-cmd-disas.c: Include "arch-utils.h"
1913 (mi_cmd_disassemble): Pass architecture to gdb_disassembly.
1914
1915 * cli/cli-cmds.c: Include "arch-utils.h".
1916 (print_disassembly): Add GDBARCH parameter. Pass to gdb_disassembly
1917 and tui_show_assembly.
1918 (disassemble_current_function): Pass architecture to
1919 tui_get_low_disassembly_address and print_disassembly.
1920 (disassemble_command): Pass architecture to
1921 tui_get_low_disassembly_address and print_disassembly.
1922
1923 * tui/tui.c (tui_show_assembly): Add GDBARCH parameter. Pass to
1924 tui_update_source_windows_with_addr.
1925
1926 * tui/tui-data.h (struct tui_locator_element): Add GDBARCH member.
1927 (struct tui_source_info): Likewise.
1928 * tui/tui-data.c (tui_clear_win_detail): Clear source_info.gdbarch.
1929
1930 * tui/tui-disasm.c (tui_disassemble): Add GDBARCH parameter.
1931 Pass to gdb_print_insn.
1932 (tui_find_disassembly_address): Add GDBARCH parameter. Pass to
1933 tui_disassemble.
1934 (tui_set_disassem_content): Add GDBARCH parameter. Install into
1935 source_info.gdbarch. Pass to tui_disassemble.
1936 (tui_show_disassem): Add GDBARCH parameter. Pass to
1937 tui_update_source_window.
1938 (tui_show_disassem_and_update_source): Add GDBARCH parameter. Pass to
1939 tui_show_disassem and tui_update_source_window.
1940
1941 (tui_get_begin_asm_address): Return locator architecture in addition
1942 to locator PC value.
1943
1944 (tui_get_low_disassembly_address): Add GDBARCH parameter. Pass to
1945 tui_get_low_disassembly_address.
1946
1947 (tui_vertical_disassem_scroll): Pass architecture to subroutines.
1948
1949 * tui/tui-disasm.h (tui_set_disassem_content): Add GDBARCH parameter.
1950 (tui_show_disassem): Likewise.
1951 (tui_show_disassem_and_update_source): Likewise.
1952 (tui_get_begin_asm_address): Return architecture and PC value.
1953
1954 * tui/tui.h (tui_get_low_disassembly_address): Add GDBARCH parameter.
1955 (tui_show_assembly): Add GDBARCH parameter.
1956
1957 * tui/tui-layout.c (extract_display_start_addr): Return current window
1958 architecture in addition to current PC value.
1959
1960 (tui_set_layout): Update calls to tui_get_low_disassembly_address and
1961 extract_display_start_addr. Pass architecture to
1962 tui_update_source_windows_with_addr.
1963
1964 * tui/tui-source.c: Include "objfiles.h".
1965 (tui_set_source_content): Initialize window architecture.
1966 (tui_show_symtab_source): Add GDBARCH parameter. Pass to
1967 tui_update_source_window_as_is
1968
1969 * tui/tui-source.h (tui_show_symtab_source): Add GDBARCH parameter.
1970
1971 * tui/tui-stack.c (tui_set_locator_info): Add GDBARCH parameter.
1972 Install locator architecture.
1973 (tui_set_locator_filename): Update call.
1974 (tui_show_frame_info): Pass architecture to tui_set_locator_info
1975 and subroutines.
1976
1977 * tui/tui-win.c (make_visible_with_new_height): Pass architecture
1978 to tui_update_source_window.
1979
1980 * tui/tui-winsource.c: Include "objfiles.h".
1981 (tui_display_main): Update call to tui_get_begin_asm_address.
1982 Pass architecture to tui_update_source_windows_with_addr.
1983 (tui_update_source_window): Add GDBARCH parameter. Pass to
1984 tui_update_source_window_as_is.
1985 (tui_update_source_window_as_is): Add GDBARCH parameter.
1986 Pass to tui_set_disassem_content.
1987 (tui_update_source_windows_with_addr): Add GDBARCH parameter.
1988 Pass to subroutines.
1989 (tui_update_source_windows_with_line): Pass objfile architecture
1990 to subroutines.
1991 (tui_horizontal_source_scroll): Pass architecture to
1992 tui_update_source_window_as_is.
1993
1994 * tui/tui-winsource.h (tui_update_source_window): Add GDBARCH
1995 parameter.
1996 (tui_update_source_window_as_is): Likewise.
1997 (tui_update_source_windows_with_addr): Likewise.
1998
a6d9a66e
UW
19992009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2000
2001 * breakpoint.h (struct breakpoint): New member GDBARCH.
2002 * breakpoint.c: Include "arch-utils.h".
2003 (set_raw_breakpoint_without_location): Add GDBARCH parameter.
2004 Use it to set breakpoint architecture.
2005 (set_raw_breakpoint): Add GDBARCH parameter.
2006 (create_internal_breakpoint): Likewise.
2007 (create_catchpoint): Likewise.
2008 (create_fork_vfork_event_catchpoint): Likewise.
2009 (create_breakpoint): Likewise.
2010 (create_breakpoints): Likewise.
2011 (break_command_really): Likewise.
2012 (create_ada_exception_breakpoint): Likewise.
2013 Update local callers to pass architecture:
2014 (create_internal_breakpoint): Update.
2015 (create_overlay_event_breakpoint): Update.
2016 (create_longjmp_master_breakpoint): Update.
2017 (create_thread_event_breakpoint): Update.
2018 (create_solib_event_breakpoint): Update.
2019 (create_catchpoint): Update.
2020 (create_fork_vfork_event_catchpoint): Update.
2021 (set_momentary_breakpoint): Update.
2022 (clone_momentary_breakpoint): Update.
2023 (create_breakpoint): Update.
2024 (create_breakpoints): Update.
2025 (break_command_really): Update.
2026 (break_command_1): Update.
2027 (set_breakpoint): Update.
2028 (watch_command_1): Update.
2029 (catch_fork_command_1): Update.
2030 (catch_exec_commnd_1): Update.
2031 (handle_gnu_v3_exceptions): Update.
2032 (create_ada_exception_breakpoint): Update.
2033 (catch_ada_exception_command): Update.
2034 (catch_assert_command): Update.
2035 (trace_command): Update.
2036
2037 * breakpoint.h (struct bp_location): New member GDBARCH.
2038 * breakpoint.c (get_sal_arch): New function.
2039 (set_raw_breakpoint): Set location architecture.
2040 (add_location_to_breakpoint): Likewise.
2041 (clone_momentary_breakpoint): Likewise.
2042 (watch_command_1): Likewise.
2043 (update_watchpoint): Likewise.
2044 (bp_loc_is_permanent): Use location architecture instead of
2045 current_gdbarch.
2046 (adjust_breakpoint_address): Add GDBARCH parameter; use it
2047 instead of current_gdbarch.
2048 Update callers of adjust_breakpoint_address to pass
2049 breakpoint location architecture:
2050 (set_raw_breakpoint): Update.
2051 (watch_command_1): Update.
2052
2053 * tracepoint.c: (collect_symbol): Add GDBARCH parameter, use instead
2054 of current_gdbarch.
2055 (add_local_symbols): Add GDBARCH parameter. Pass to collect_symbol.
2056 (encode_actions): Pass tracepoint architecture to add_local_symbols
2057 (encode_actions): Use tracepoint architecture instead of
2058 current_gdbarch. Pass it to add_local_symbols and collect_symbol.
2059
2060 * breakpoint.h (struct breakpoint_ops): Replace last_addr parameter
2061 of print_one callback with last_loc.
2062 * breakpoint.c (print_one_breakpoint_location): Replace last_addr
2063 parameter with last_loc.
2064 (print_one_breakpoint): Likewise.
2065 (do_captured_breakpoint_query): Update call.
2066 (breakpoint_1): Pass last_loc instead of last_addr to
2067 print_one_breakpoint. Pass last location architecture instead of
2068 current_gdbarch to set_next_address.
2069 Update all implementations of the print_one callback:
2070 * breakpoint.c (print_one_catch_fork): Update.
2071 (print_one_catch_vfork): Update.
2072 (print_one_catch_exec): Update.
2073 (print_one_exception_catchpoint): Update.
2074 * ada-lang.c (print_one_exception): Update.
2075 (print_one_catch_exception): Update.
2076 (print_one_catch_exception_unhandled): Update.
2077 (print_one_catch_assert): Update.
2078
2079 * breakpoint.c (print_one_breakpoint_location): Add PRINT_ADDRESS_BITS
2080 parameter. Use it instead of gdbarch_addr_bit (current_gdbarch).
2081 (print_one_breakpoint): Add PRINT_ADDRESS_BITS parameter and pass it
2082 to print_one_breakpoint_location.
2083 (breakpoint_address_bits): New function.
2084 (do_captured_breakpoint_query): Compute number of address bits to print
2085 and pass it to print_one_breakpoint.
2086 (breakpoint_1): Likewise. Use it instead of current_gdbarch.
2087
2088 * breakpoint.h (create_thread_event_breakpoint): Add GDBARCH.
2089 * breakpoint.c (create_thread_event_breakpoint): Likewise.
2090 Update callers to create_thread_event_breakpoint:
2091 * aix-thread.c (pd_enable): Update.
2092 * linux-thread-db.c (enable_thread_event): Update.
2093
2094 * breakpoint.h (create_solib_event_breakpoint): Add GDBARCH.
2095 * breakpoint.c (create_solib_event_breakpoint): Likewise.
2096 Update callers to create_solib_event_breakpoint:
2097 * solib-frv.c (enable_break, enable_break2): Update.
2098 * solib-pa64.c (pa64_solib_create_inferior_hook): Update.
2099 * solib-som.c (som_solib_create_inferior_hook): Update.
2100 * solib-darwin.c (darwin_solib_create_inferior_hook): Update.
2101 * solib-svr4.c (enable_break): Update.
2102
2103 * breakpoint.h (insert_single_step_breakpoint): Add GDBARCH.
2104 * breakpoint.c (insert_single_step_breakpoint): Likewise.
2105 Update callers to insert_single_step_breakpoint:
2106 * alpha-tdep.c (alpha_software_single_step): Update.
2107 * arm-linux-tdep.c (arm_linux_software_single_step): Update.
2108 * arm-tdep.c (arm_software_single_step): Update.
2109 * cris-tdep.c (cris_software_single_step): Update.
2110 * rs6000-aix-tdep.c (rs6000_software_single_step): Update.
2111 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Update.
2112 * sparc-tdep.c (sparc_software_single_step): Update.
2113 * spu-tdep.c (spu_software_single_step): Update.
2114 * mips-tdep.c (deal_with_atomic_sequence): Add GDBARCH parameter.
2115 Pass it to insert_single_step_breakpoint.
2116 (mips_software_single_step): Pass architecture to
2117 deal_with_atomic_sequence and insert_single_step_breakpoint.
2118
2119 * breakpoint.h (deprecated_insert_raw_breakpoint): Add GDBARCH.
2120 (deprecated_remove_raw_breakpoint): Likewise.
2121 * breakpoint.c (deprecated_insert_raw_breakpoint): Add GDBARCH.
2122 (deprecated_remove_raw_breakpoint): Likewise.
2123 Update callers to deprecated_insert_raw_breakpoint and
2124 deprecated_remove_raw_breakpoint:
2125 * breakpoint.c (single_step_gdbarch): New static variable.
2126 (insert_single_step_breakpoint): Pass GDBARCH parameter to
2127 deprecated_insert_raw_breakpoint. Store it in single_step_gdbarch.
2128 (remove_single_step_breakpoints): Pass architecture stored in
2129 single_step_gdbarch to deprecated_remove_raw_breakpoint.
2130 * rs6000-nat.c (exec_one_dummy_insn): Update.
2131 * solib-irix.c (enable_break, disable_break): Update.
2132 * procfs.c (procfs_mourn_inferior): Update.
2133 (remove_dbx_link_breakpoint): Update.
2134
2135 * breakpoint.h (set_breakpoint): Add GDBARCH parameter.
2136 (set_momentary_breakpoint, set_momentary_breakpoint_at_pc): Likewise.
2137 * breakpoint.c (set_breakpoint): Add GDBARCH parameter.
2138 (set_momentary_breakpoint, set_momentary_breakpoint_at_pc): Likewise.
2139 Update callers to set_breakpoint, set_momentary_breakpoint and
2140 set_momentary_breakpoint_at_pc:
2141 * breakpoint.c (set_momentary_breakpoint_at_pc): Update.
2142 (until_break_command): Update.
2143 * infcall.c (call_function_by_hand): Update.
2144 * infcmd.c (finish_backward, finish_forward): Update.
2145 * infrun.c (insert_step_resume_breakpoint_at_sal): Add GDBARCH
2146 parameter. Pass it to set_momentary_breakpoint.
2147 (insert_longjmp_resume_breakpoint): Add GDBARCH parameter.
2148 Pass it to set_momentary_breakpoint_at_pc.
2149 (handle_inferior_event): Update.
2150 (insert_step_resume_breakpoint_at_frame): Update.
2151 (insert_step_resume_breakpoint_at_caller): Update..
2152 * mi/mi-cmd-break.c: Include "arch-utils.h".
2153 (mi_cmd_break_insert): Update.
2154
2155 * target.h (struct target_ops): Add GDBARCH parameter to
2156 to_insert_breakpoint, to_remove_breakpoint, to_insert_hw_breakpoint,
2157 and to_remove_hw_breakpoint members.
2158 (target_insert_breakpoint, target_remove_breakpoint,
2159 target_insert_hw_breakpoint, target_remove_hw_breakpoint): Add GDBARCH
2160 parameter, pass to target routine.
2161 (memory_remove_breakpoint, memory_insert_breakpoint): Add GDBARCH
2162 parameter.
2163 * target.c (debug_to_insert_breakpoint, debug_to_remove_breakpoint,
2164 debug_to_insert_hw_breakpoint, debug_to_remove_hw_breakpoint): Add
2165 GDBARCH parameter, pass to target routine.
2166 (update_current_target): Update function signature.
2167 * breakpoint.c (insert_bp_location, remove_breakpoint,
2168 deprecated_insert_raw_breakpoint, deprecated_remove_raw_breakpoint):
2169 Pass architecture to target_ routines.
2170 Update all implementations of the target breakpoint routines to take
2171 GDBARCH parameter and use it instead of GDBARCH as appropriate:
2172 * corelow.c (ignore): Update.
2173 * exec.c (ignore): Update.
2174 * mem-break.c (memory_insert_breakpoint): Update.
2175 (memory_remove_breakpoint): Update.
2176 * monitor.c (monitor_insert_breakpoint): Update.
2177 (monitor_remove_breakpoint): Update.
2178 * record.c (record_insert_breakpoint): Update.
2179 (record_beneath_to_insert_breakpoint): Update.
2180 (record_remove_breakpoint): Update.
2181 (record_beneath_to_remove_breakpoint): Update.
2182 * remote.c (remote_insert_breakpoint): Update.
2183 (remote_remove_breakpoint): Update.
2184 (remote_insert_hw_breakpoint): Update.
2185 (remote_remove_hw_breakpoint): Update.
2186 * remote-m32r-sdi.c (m32r_insert_breakpoint): Update.
2187 (m32r_remove_breakpoint): Update.
2188 * remote-mips.c (mips_insert_breakpoint): Update.
2189 (mips_remove_breakpoint): Update.
2190 * i386-nat.c (i386_insert_hw_breakpoint): Update.
2191 (i386_remove_hw_breakpoint): Update.
2192 * nto-procfs.c (procfs_insert_breakpoint): Update.
2193 (procfs_remove_breakpoint): Update.
2194 (procfs_insert_hw_breakpoint): Update.
2195 (procfs_remove_hw_breakpoint): Update.
2196
36f15f55
UW
21972009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2198
2199 * frame.h (frame_unwind_arch): New.
2200 (frame_unwind_caller_arch): Likewise.
2201 * frame-unwind.h (frame_prev_arch_ftype): New type.
2202 (struct frame_unwind): New member prev_arch.
2203 * frame.c (struct frame_info): New member prev_arch.
2204 (frame_unwind_arch): New function.
2205 (frame_unwind_caller_arch): Likewise..
2206 (get_frame_arch): Reimplement in terms of frame_unwind_arch.
2207 * sentinel-frame.c (sentinel_frame_prev_arch): New function.
2208 (sentinel_frame_unwinder): Install it.
2209
2210 * frame.c (frame_pc_unwind): Use frame_unwind_arch instead
2211 of get_frame_arch.
2212 (frame_unwind_register_value): Likewise.
2213 (frame_unwind_register_signed): Likewise.
2214 (frame_unwind_register_unsigned): Likewise.
2215 * frame-unwind.c (frame_unwind_got_optimized): Likewise.
2216 (frame_unwind_got_register): Likewise.
2217 (frame_unwind_got_constant): Likewise.
2218 (frame_unwind_got_bytes): Likewise.
2219 (frame_unwind_got_address): Likewise.
2220
2221 * frame.h (enum frame_type): New value ARCH_FRAME.
2222 * frame.c (fprint_frame_type): Handle ARCH_FRAME.
2223 * stack.c (print_frame_info): Likewise.
2224
c2250ad1
UW
22252009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2226
2227 * target.h (struct target_ops): New member to_thread_architecture.
2228 (target_thread_architecture): New macro.
2229 * target.c (update_current_target): Inherit to_thread_architecture.
2230 (default_thread_architecture): New function.
2231 (debug_to_thread_architecture): New function.
2232 (setup_target_debug): Handle to_thread_architecture.
2233
2234 * regcache.h (get_thread_arch_regcache): New.
2235 * regcache.c (struct regcache_list): New data type.
2236 (current_regcache): Hold regcache list instead of single regcache.
2237 (current_thread_ptid, current_thread_arch): New static variables.
2238 (get_thread_arch_regcache): New function.
2239 (get_thread_regcache): Use it. Call target_thread_architecture.
2240 (regcache_thread_ptid_changed): Update to current_regcache changes.
2241 (registers_changed): Likewise. Reset current_thread_arch and
2242 current_thread_ptid.
2243
2244 * remote.c (remote_wait): Access target registers in target_gdbarch.
2245 * linux-nat.c (linux_nat_do_thread_registers): Likewise.
2246 * proc-service.c (ps_lgetregs, ps_lsetregs): Likewise.
2247 (ps_lgetfpregs, ps_lsetfpregs): Likewise.
2248 * sol-thread.c (ps_lgetregs, ps_lsetregs): Likewise.
2249 (ps_lgetfpregs, ps_lsetfpregs): Likewise.
2250 * solib-svr4.c (enable_break): Likewise.
2251 (svr4_relocate_main_executable): Likewise.
2252
d452c4bc
UW
22532009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2254
2255 * python/python-internal.h (struct language_defn): Declare.
2256 (python_gdbarch, python_language): Likewise.
2257 (ensure_python_env): Add prototype.
2258 (make_cleanup_py_restore_gil): Remove prototype.
2259
2260 * python/python.c: Include "arch-utils.h", "value.h" and "language.h".
2261 (python_gdbarch, python_language): New global variables.
2262 (struct python_env): New data type.
2263 (ensure_python_env, restore_python_env): New functions.
2264 (eval_python_from_control_command): Call ensure_python_env to
2265 install current architecture and language.
2266 (python_command, gdbpy_new_objfile): Likewise.
2267 * python/python-cmd.c: Include "arch-utils.h" and "language.h".
2268 (cmdpy_destroyer, cmdpy_function, cmdpy_completer): Call
2269 ensure_python_env.
2270 * python/python-type.c (clean_up_objfile_types): Likewise.
2271 * python/python-objfile.c: Include "language.h".
2272 (clean_up_objfile): Call ensure_python_env.
2273 * python/python-prettyprint.c (apply_val_pretty_printer): Likewise.
2274 (apply_varobj_pretty_printer): Do not call PyGILState_Ensure.
2275 * varobj.c (varobj_ensure_python_env): New helper function.
2276 (varobj_get_display_hint, update_dynamic_varobj_children,
2277 install_default_visualizer, varobj_set_visualizer, free_variable,
2278 value_get_print_value): Call it.
2279 (value_get_print_value): Add varobj argument instead of pretty
2280 printer argument. Update all callers.
2281
2282 * python/python-utils.c (py_gil_restore, make_cleanup_py_restore_gil):
2283 Remove.
2284
2285 * value.h (internal_function_fn): Add GDBARCH and LANGUAGE argument.
2286 (call_internal_function): Likewise.
2287 * value.c (call_internal_function): Likewise. Pass to handler.
2288 * eval.c (evaluate_subexp_standard): Update call.
2289 * python/python-function.c: Include "language.h".
2290 (fnpy_call): Add GDBARCH and LANGAUAGE arguments and call
2291 make_cleanup_python_env.
2292
2293 * python/python-value.c (builtin_type_pyint, builtin_type_pyfloat,
2294 builtin_type_pylong, builtin_type_pybool, builtin_type_pychar,
2295 valpy_str): Use python_gdbarch and python_language instead of
2296 current_gdbarch and current_language.
2297 * python/python-type.c (typy_lookup_typename): Likewise.
2298
e17c207e
UW
22992009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2300
2301 * arch-utils.c (selected_byte_order): Return target_byte_order_user.
2302 (show_endian): Use target_byte_order_user if specified; otherwise
2303 use get_current_arch () instead of current_gdbarch.
2304 (show_architecture): Use set_architecture_string if specified;
2305 otherwise use get_current_arch () instead of current_gdbarch.
2306 (get_current_arch): New function.
2307 * arch-utils.h (get_current_arch): Add prototype.
2308
2309 * osabi.c (show_osabi): Use get_current_arch () instead of
2310 current_gdbarch.
2311
2312 * findcmd.c: Include "arch-utils.h".
2313 (parse_find_args): Add BIG_P argument. Use it instead of byte order
2314 of current_gdbarch.
2315 (find_command): Use get_current_arch () instead of current_gdbarch.
2316 Pass byte order to parse_find_args.
2317
2318 * maint.c: Include "arch-utils.h".
2319 (maintenance_print_architecture): Use get_current_arch () instead
2320 of current_gdbarch.
2321
2322 * reggroups.c: Include "arch-utils.h".
2323 (maintenance_print_reggroups): Use get_current_arch () instead
2324 of current_gdbarch.
2325
2326 * symfile.c: Include "arch-utils.h".
2327 (overlay_load_command): Use get_current_arch () instead of
2328 current_gdbarch.
2329
2330 * value.c: Include "arch-utils.h".
2331 (show_convenience): Use get_current_arch () instead of
2332 current_gdbarch.
2333
2334 * tui/tui-regs.c: Include "arch-utils.h".
2335 (tui_reg_next_command): Use get_current_arch () instead of
2336 current_gdbarch.
2337
2338 * mi/mi-main.c: Include "arch-utils.h".
2339 (mi_cmd_data_read_memory): Use get_current_arch () instead of
2340 current_gdbarch.
2341
2342 * parse.c: Include "arch-utils.h".
2343 (parse_exp_in_context): Use get_current_arch () instead of
2344 current_gdbarch.
2345
50810684
UW
23462009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2347
2348 * gdbtypes.c (make_pointer_type, make_reference_type,
2349 smash_to_memberptr_type, lookup_array_range_type, check_stub_method):
2350 Use type architecture instead of current_gdbarch.
2351
2352 * gdbtypes.h (address_space_name_to_int, address_space_int_to_name):
2353 Add GDBARCH paramter.
2354 * gdbtypes.c (address_space_name_to_int, address_space_int_to_name):
2355 Add GDBARCH parameter. Use it instead of current_gdbarch.
2356 * c-typeprint.c (c_type_print_modifier): Update call.
2357 * parse.c (push_type_address_space): Likewise.
2358
2359 * findvar.c (extract_typed_address, store_typed_address): Use type
2360 architecture instead of current_gdbarch.
2361
2362 * value.c (value_as_address, unpack_field_as_long): Use type architecture
2363 instead of current_gdbarch.
2364
2365 * doublest.c (floatformat_from_length): Add GDBARCH argument. Use it
2366 instead of current_gdbarch.
2367 (floatformat_from_type): Pass type architecture.
2368
2369 * infcall.c (find_function_addr): Use type architecture instead
2370 of current_gdbarch.
2371
2372 * valarith.c (value_bitstring_subscript, value_x_binop, value_neg,
2373 value_bit_index): Use type architecture instead of current_gdbarch.
2374 * valops.c (value_cast, value_slice): Likewise.
2375
2376 * value.h (modify_field): Add TYPE argument.
2377 * value.c (modify_field): Add TYPE argument. Use type architecture
2378 instead of current_gdbarch.
2379 (set_internalvar_component): Likewise.
2380 * eval.c (evaluate_struct_tuple): Update call.
2381 * valops.c (value_assign): Likewise.
2382 * ada-lang.c (modify_general_field): Likewise. Add TYPE argument.
2383 (make_array_descriptor): Update calls.
2384 (move_bits): Add BITS_BIG_ENDIAN_P argument. Use it instead of
2385 current_gdbarch.
2386 (ada_value_assign, value_assign_to_component): Update calls.
2387 (decode_packed_array, ada_value_primitive_packed_val, ada_value_assign,
2388 value_assign_to_component): Use type arch instead of current_gdbarch.
2389
2390 * printcmd.c (float_type_from_length): Remove GDBARCH argument,
2391 use type architecture instead.
2392 (print_scalar_formatted, printf_command): Update calls. Use type
2393 architecture instead of current_gdbarch.
2394 * valprint.c (val_print_type_code_int): Use type architecture
2395 instead of current_gdbarch.
2396 * varobj.c (value_get_print_value): Likewise.
2397 * python/python-prettyprint.c (print_string_repr): Add GDBARCH
2398 argument. Use it instead of current_gdbarch.
2399 (apply_val_pretty_printer): Update call.
2400
2401 * ada-valprint.c (ada_val_print_1): Use type architecture instead
2402 of current_gdbarch.
2403 * c-valprint.c (print_function_pointer_address): Add GDBARCH argument.
2404 Use it instead of current_gdbarch.
2405 (c_val_print): Update calls passing type architecture.
2406 * f-valprint.c (f_val_print): Use type architecture instead of
2407 current_gdbarch.
2408 * jv-valprint (java_value_print): Likewise.
2409 * m2-valprint.c (print_function_pointer_address): Add GDBARCH argument.
2410 Use it instead of current_gdbarch.
2411 (print_unpacked_pointer): Update calls passing type architecture.
2412 * scm-valprint.c (scm_scmval_print): Use type architecture instead of
2413 current_gdbarch.
2414
2415 * gnu-v3-abi.c (get_class_arch): Remove.
2416 (gnuv3_rtti_type): Use get_type_arch instead of get_class_arch. Remove
2417 special-case check for Java classes.
2418 (gnuv3_virtual_fn_field, gnuv3_baseclass_offset, gnuv3_print_method_ptr,
2419 gnuv3_method_ptr_size, gnuv3_make_method_ptr, gnuv3_method_ptr_to_value):
2420 Use get_type_arch instead of get_class_arch.
2421
e9bb382b
UW
24222009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2423
2424 * gdbtypes.h (TYPE_OBJFILE_OWNED, TYPE_OWNER): New macros.
2425 (TYPE_OBJFILE, TYPE_ALLOC, TYPE_ZALLOC): Reimplement.
2426 (alloc_type_arch): Add prototype.
2427 (alloc_type_copy): Likewise.
2428 (get_type_arch): Likewise.
2429 (arch_type): Likewise.
2430 (arch_integer_type): Likewise.
2431 (arch_character_type): Likewise.
2432 (arch_boolean_type): Likewise.
2433 (init_float_type): Remove, replace by ...
2434 (arch_float_type): ... this.
2435 (init_complex_type): Remove, replace by ...
2436 (arch_complex_type): ... this.
2437 (init_flags_type): Remove, replace by ...
2438 (arch_flags_type): ... this.
2439 (init_composite_type): Remove, replace by ...
2440 (arch_composite_type): ... this.
2441
2442 * gdbtypes.c (alloc_type): No longer support NULL objfile.
2443 (init_type): Likewise.
2444 (alloc_type_arch): New function.
2445 (alloc_type_copy): New function.
2446 (get_type_arch): New function.
2447
2448 (smash_type): Preserve type ownership information.
2449 (make_pointer_type, make_reference_type, make_function_type,
2450 smash_to_memberptr_type, smash_to_method_type): No longer
2451 preserve OBJFILE across smash_type calls.
2452 (make_pointer_type, make_reference_type, make_function_type,
2453 lookup_memberptr_type, lookup_methodptr_type, allocate_stub_method,
2454 create_range_type, create_array_type, create_set_type, copy_type):
2455 Use alloc_type_copy when allocating types.
2456 (check_typedef): Use alloc_type_arch.
2457 (copy_type_recursive): Likewise. Preserve type ownership data
2458 after copying type.
2459 (recursive_dump_type): Dump type ownership data.
2460 (alloc_type_instance): Update type ownership check.
2461 (copy_type, copy_type_recursive): Likewise.
2462
2463 (arch_type): New function.
2464 (arch_integer_type): Likewise.
2465 (arch_character_type): Likewise.
2466 (arch_boolean_type): Likewise.
2467 (init_float_type): Remove, replace by ...
2468 (arch_float_type): ... this.
2469 (init_complex_type): Remove, replace by ...
2470 (arch_complex_type): ... this.
2471 (init_flags_type): Remove, replace by ...
2472 (arch_flags_type): ... this.
2473 (append_flags_type_flag): Move down.
2474 (init_composite_type): Remove, replace by ...
2475 (arch_composite_type): ... this.
2476 (append_composite_type_field_aligned,
2477 append_composite_type_field): Move down.
2478
2479 * gdbarch.c (gdbtypes_post_init): Allocate all types
2480 using per-architecture routines.
2481 * ada-lang.c (ada_language_arch_info): Likewise.
2482 * f-lang.c (build_fortran_types): Likewise.
2483 * jv-lang.c (build_java_types): Likewise.
2484 * m2-lang.c (build_m2_types): Likewise.
2485 * scm-lang.c (build_scm_types): Likewise.
2486
2487 * ada-lang.c (ada_type_of_array): Use alloc_type_copy.
2488 (packed_array_type): Likewise.
2489 (ada_template_to_fixed_record_type_1): Likewise.
2490 (template_to_static_fixed_type): Likewise.
2491 (to_record_with_fixed_variant_part): Likewise.
2492 (to_fixed_variant_branch_type): Likewise.
2493 (to_fixed_array_type): Likewise.
2494 (to_fixed_range_type): Likewise.
2495 (empty_record): Use type instead of objfile argument.
2496 Use alloc_type_copy.
2497 (to_fixed_variant_branch_type): Update call to empty_record.
2498 * jv-lang.c (type_from_class): Use alloc_type_arch.
2499
2500 * arm-tdep.c (arm_ext_type): Allocate per-architecture type.
2501 * i386-tdep.c (i386_eflags_type, i386_mxcsr_type, i387_ext_type,
2502 i386_mmx_type, i386_sse_type): Likewise.
2503 * ia64-tdep.c (ia64_ext_type): Likewise.
2504 * m32c-tdep.c (make_types): Likewise.
2505 * m68k-tdep.c (m68k_ps_type, m68881_ext_type): Likewise.
2506 * rs6000-tdep.c (rs6000_builtin_type_vec64,
2507 rs6000_builtin_type_vec128): Likewise.
2508 * sparc-tdep.c (sparc_psr_type, sparc_fsr_type): Likewise.
2509 * sparc64-tdep.c (sparc64_pstate_type, sparc64_fsr_type,
2510 sparc64_fprs_type): Likewise.
2511 * spu-tdep.c (spu_builtin_type_vec128): Likewise.
2512 * xtensa-tdep.c (xtensa_register_type): Likewise.
2513 * linux-tdep.c (linux_get_siginfo_type): Likewise.
2514 * target-descriptions.c (tdesc_gdb_type): Likewise.
2515 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2516
209bd28e
UW
25172009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2518
2519 * i386-tdep.h (struct gdbarch_tdep): Add i386_eflags_type and
2520 i386_mxcsr_type members.
2521 (i386_eflags_type): Make into function.
2522 (i386_mxcsr_type): Likewise.
2523 * i386-tdep.c (i386_eflags_type): Make into function.
2524 (i386_mxcsr_type): Likewise.
2525 (i386_register_type): Update uses.
2526 (i386_init_types): Remove.
2527 (_initialize_i386_tdep): Do not call it.
2528 * amd64-tdep.c (amd64_register_type): Update uses.
2529
2530 * m68k-tdep.h (struct gdbarch_tdep): Add m68k_ps_type member.
2531 * m68k-tdep.c (m68k_ps_type): Make into function.
2532 (m68k_register_type): Update use.
2533 (m68k_init_types): Remove.
2534 (_initialize_m68k_tdep): Do not call it.
2535
2536 * sparc-tdep.h (struct gdbarch_tdep): Add sparc_psr_type,
2537 sparc_fsr_type, sparc64_pstate_type, sparc64_fsr_type, and
2538 sparc64_fprs_type members.
2539 * sparc-tdep.c (sparc_psr_type): Make into function.
2540 (sparc_fsr_type): Likewise.
2541 (sparc32_register_type): Update uses.
2542 (sparc_init_types): Remove.
2543 (_initialize_sparc_tdep): Do not call it.
2544 * sparc64-tdep.c (sparc64_pstate_type): Make into function.
2545 (sparc64_fsr_type): Likewise.
2546 (sparc64_fprs_type): Likewise.
2547 (sparc64_register_type): Update uses.
2548 (sparc64_init_types): Remove.
2549 (_initialize_sparc64_tdep): Likewise.
2550
27067745
UW
25512009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2552
2553 * gdbtypes.h (builtin_type_ieee_single, builtin_type_ieee_double,
2554 builtin_type_i387_ext, builtin_type_m68881_ext, builtin_type_arm_ext,
2555 builtin_type_ia64_spill, builtin_type_ia64_quad): Remove.
2556 (init_float_type, init_complex_type): Add prototypes.
2557 * gdbtypes.c (builtin_type_ieee_single, builtin_type_ieee_double,
2558 builtin_type_i387_ext, builtin_type_m68881_ext, builtin_type_arm_ext,
2559 builtin_type_ia64_spill, builtin_type_ia64_quad): Remove.
2560 (_initialize_gdbtypes): Do not initialize them.
2561 (build_flt): Rename to ...
2562 (init_float_type): ... this. Make global.
2563 (build_complex): Rename to ...
2564 (init_complex_type): ... this. Make global. Remove BIT argument.
2565 (gdbtypes_post_init): Update calls.
2566
2567 * ada-lang.c (ada_language_arch_info): Use init_float_type.
2568 * jv-lang.c (build_java_types): Likewise.
2569 * m2-lang.c (build_m2_types): Likewise.
2570 * f-lang.c (build_fortran_types): Use init_float_type and
2571 init_complex_type.
2572
2573 * target-descriptions.c (tdesc_gdb_type): Call init_float_type instead
2574 of using builtin_type_ieee_single, builtin_type_ieee_double, or
2575 builtin_type_arm_ext.
2576
2577 * ia64-tdep.h (struct gdbarch_tdep): Add ia64_ext_type member.
2578 * ia64-tdep.c (builtin_type_ia64_ext): Remove.
2579 (_initialize_ia64_tdep): Do not initialize it.
2580 (floatformat_valid, floatformat_ia64_ext, floatformats_ia64_ext):
2581 Move up.
2582 (ia64_ext_type): New function.
2583 (ia64_register_reggroup_p, ia64_convert_register_p,
2584 ia64_register_to_value, ia64_value_to_register,
2585 ia64_extract_return_value, ia64_store_return_value): Use ia64_ext_type
2586 instead of builtin_type_ia64_ext.
2587
2588 * i386-tdep.h (struct gdbarch_tdep): Add i387_ext_type member.
2589 (i387_ext_type): Add prototype.
2590 * i386-tdep.c (i387_ext_type): New function.
2591 (i386_extract_return_value, i386_store_return_value,
2592 i386_register_type): Use it instead of builtin_type_i387_ext.
2593 * amd64-tdep.c (amd64_register_type): Likewise.
2594 * i387-tdep.c (print_i387_value, i387_register_to_value,
2595 i387_value_to_register): Likewise.
2596 (print_i387_value, print_i387_ext): Add GDBARCH argument.
2597 (print_i387_ext, i387_print_float_info): Pass to subroutines.
2598
2599 * m68k-tdep.h (struct gdbarch_tdep): Add m68881_ext_type member.
2600 * m68k-tdep.c (m68881_ext_type): New function.
2601 (m68k_register_type, m68k_convert_register_p): Use it instead
2602 of builtin_type_m68881_ext.
2603
2604 * arm-tdep.h (struct gdbarch_tdep): Add arm_ext_type member.
2605 * arm-tdep.c (arm_ext_type): New function.
2606 (arm_register_type): Use it instead of builtin_type_arm_ext.
2607
2608 * alpha-tdep.c (alpha_register_type): Use builtin types
2609 instead of builtin_type_ieee_double.
2610
2611 * mips-tdep.c (mips_float_register_type, mips_double_register_type):
2612 Remove.
2613 (mips_register_type): Use builtin types instead of
2614 builtin_type_ieee_single and builtin_type_ieee_double.
2615 (mips_print_fp_register): Use builtin types instead of
2616 mips_float_register_type and mips_double_register_type.
2617
2618 * hppa-tdep.c (hppa32_register_type, hppa64_register_type):
2619 Use builtin types instead of builtin_type_ieee_single and
2620 builtin_type_ieee_double.
2621
df4df182
UW
26222009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2623
2624 * gdbtypes.h (builtin_type_int0, builtin_type_int8, builtin_type_uint8,
2625 builtin_type_int16, builtin_type_uint16, builtin_type_int32,
2626 builtin_type_uint32, builtin_type_int64, builtin_type_uint64,
2627 builtin_type_int128, builtin_type_uint128): Remove.
2628 (struct builtin_type): New members builtin_int0, builtin_int8,
2629 builtin_uint8, builtin_int16, builtin_uint16, builtin_int32,
2630 builtin_uint32, builtin_int64, builtin_uint64, builtin_int128,
2631 and builtin_uint128.
2632 * gdbtypes.c (builtin_type_int0, builtin_type_int8, builtin_type_uint8,
2633 builtin_type_int16, builtin_type_uint16, builtin_type_int32,
2634 builtin_type_uint32, builtin_type_int64, builtin_type_uint64,
2635 builtin_type_int128, builtin_type_uint128): Remove.
2636 (_initialize_gdbtypes): Do not initialize them.
2637 (gdbtypes_post_init): Initialize fixed-size integer types.
2638
2639 * dwarf2expr.c (unsigned_address_type, signed_address_type): Add
2640 GDBARCH argument. Return platform-specific type.
2641 (dwarf2_read_address, execute_stack_op): Update calls.
2642
2643 * target-descriptions.c (tdesc_gdb_type): Use platform-specific types
2644 instead of global builtin_int_... variables.
2645 * mi/mi-main.c (mi_cmd_data_read_memory): Likewise.
2646 * printcmd.c (do_examine): Likewise.
2647 * jv-exp.y (parse_number): Likewise.
2648
2649 * alpha-tdep.c (alpha_register_type, alpha_push_dummy_call,
2650 alpha_store_return_value): Likewise.
2651 * amd64-linux-tdep.c (amd64_linux_register_type): Likewise.
2652 * amd64-tdep.c (amd64_register_type): Likewise.
2653 * arm-tdep.c (arm_register_type): Likewise.
2654 * avr-tdep.c (avr_register_type): Likewise.
2655 * cris-tdep.c (cris_register_type, crisv32_register_type): Likewise.
2656 * frv-tdep.c (frv_register_type): Likewise.
2657 * h8300-tdep.c h8300_register_type): Likewise.
2658 * hppa-tdep.c (hppa64_push_dummy_call, hppa32_register_type,
2659 hppa64_register_type): Likewise.
2660 * i386-tdep.c (i386_mmx_type, i386_sse_type): Likewise.
2661 * iq2000-tdep.c (iq2000_register_type): Likewise.
2662 * lm32-tdep.c (lm32_register_type, lm32_push_dummy_call): Likewise.
2663 * m32r-tdep.c (m32r_register_type): Likewise.
2664 * m68hc11-tdep.c (m68hc11_register_type, m68hc11_pseudo_register_read,
2665 m68hc11_pseudo_register_write): Likewise.
2666 * m68k-tdep.c (m68k_register_type): Likewise.
2667 * m88k-tdep.c (m88k_register_type, m88k_store_arguments): Likewise.
2668 * mep-tdep.c (mep_register_type): Likewise.
2669 * mips-tdep.c (mips_register_type, mips_pseudo_register_type,
2670 mips_print_fp_register): Likewise.
2671 * moxie-tdep.c (moxie_register_type): Likewise.
2672 * mt-tdep.c (mt_copro_register_type, mt_register_type): Likewise.
2673 * rs6000-tdep.c (rs6000_builtin_type_vec64,
2674 rs6000_builtin_type_vec128): Likewise.
2675 * score-tdep.c (score_register_type): Likewise.
2676 * sparc-tdep.c (sparc32_register_type, sparc32_store_arguments):
2677 Likewise.
2678 * sparc64-tdep.c (sparc64_register_type, sparc64_store_arguments):
2679 Likewise.
2680 * spu-tdep.c (spu_builtin_type_vec128, spu_register_type): Likewise.
2681 * v850-tdep.c (v850_register_type): Likewise.
2682 * xstormy16-tdep.c (xstormy16_register_type): Likewise.
2683 * xtensa-tdep.c (xtensa_register_type): Likewise.
2684
2685 * mt-tdep.c (struct gdbarch_tdep): New data structure.
2686 (mt_gdbarch_init): Alloc TDEP structures.
2687 (mt_register_type): Cache coprocessor type in TDEP instead of
2688 static global variable.
2689
2690 * xtensa-tdep.h (struct gdbarch_tdep): Add type_entries member.
2691 * xtensa-tdep.c (type_entries): Remove.
2692 (xtensa_register_type): Cache fixed-size types in TDEP instead
2693 of in global variable.
2694
69feb676
UW
26952009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2696
2697 * gdbtypes.h (builtin_type_true_char): Remove.
2698 (builtin_type_true_unsigned_char): Likewise.
2699 (struct builtin_type): Add builtin_true_char and
2700 builtin_true_unsigned_char members.
2701 * gdbtypes.c (builtin_type_true_char): Remove.
2702 (builtin_type_true_unsigned_char): Likewise.
2703 (_initialize_gdbtypes): Do not initialize them.
2704 (gdbtypes_post_init): Initialize builtin_true_char and
2705 builtin_true_unsigned_char members of builtin_type.
2706
2707 * printcmd.c (print_scalar_formatted): Use builtin_type
2708 members instead of builtin_type_true_char and
2709 builtin_type_true_unsigned_char.
2710 * ada-valprint.c (ada_val_print_1): Likewise.
2711
48319d1f
UW
27122009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2713
2714 * gdbtypes.h (builtin_type_void): Remove.
2715 * gdbtypes.c (builtin_type_void): Remove.
2716 (_initialize_gdbtypes): Do not initialize it.
2717
2718 (safe_parse_type): Add GDBARCH argument. Use it to construct
2719 void return type.
2720 (check_stub_method): Update call.
2721
2722 * infcall.c (call_function_by_hand): Use platform-specific type
2723 instead of builtin_type_void.
2724 * valops.c (value_cast): Use input void type instead of
2725 builtin_type_void.
2726
22601c15
UW
27272009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2728
2729 * ada-lang.c (assign_component): Use platform-specific integer type
2730 instead of builtin_type_int32 type.
2731 (ada_evaluate_subexp) [OP_ATR_SIZE]: Likewise.
2732
2733 * ax-gdb.c (gen_expr) [UNOP_NEG]: Use platform-specific integer type
2734 instead of builtin_type_int8 type.
2735 * valarith.c (value_x_unop): Likewise.
2736 * python/python-value.c (valpy_absolute): Avoid reference to
2737 builtin_type_int8 type.
2738
2739 * eval.c (evaluate_subexp_standard): Use platform-specific integer
2740 type instead of builtin_type_int8 as EVAL_SKIP return value type.
2741 * ada-lang.c (ada_evaluate_subexp): Likewise.
2742 * jv-lang.c (evaluate_subexp_java): Likewise.
2743 * m2-lang.c (evaluate_subexp_modula2): Likewise.
2744 * scm-lang.c (evaluate_exp): Likewise.
2745
2746 * value.h (value_bitstring): Add INDEX_TYPE argument.
2747 * valops.c (value_bitstring): Add INDEX_TYPE argument, use it instead
2748 of builtin_type_int32 as base range type.
2749 * eval.c (evaluate_subexp_standard): Update value_bitstring call.
2750
e3506a9f
UW
27512009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2752
2753 * gdbtypes.c (lookup_array_range_type): Add prototype.
2754 (lookup_string_range_type): Likewise.
2755 * gdbtypes.c (lookup_array_range_type): New function.
2756 (lookup_string_range_type): Likewise.
2757
2758 * ax-gdb.c (gen_repeat): Use lookup_array_range_type.
2759 * parse.c (follow_types): Likewise.
2760 * jv-lang.c (java_array_type): Likewise.
2761 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
2762 * mt-tdep.c (mt_register_type): Likewise.
2763 * sh-tdep.c (sh_sh4_build_float_register_type): Likewise.
2764 * sh64-tdep.c (sh64_build_float_register_type): Likewise.
2765 * value.c (allocate_repeat_value): Likewise.
2766 * valops.c (value_array, value_cstring): Likewise.
2767 * valops.c (value_string): Use lookup_string_range_type.
2768
d5c831bd
UW
27692009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2770
2771 * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Remove
2772 redundant check for NULL TYPE_TARGET_TYPE.
2773 * m2-valprint.c (m2_print_long_set): Likewise.
2774 * p-valprint.c (pascal_type_print_base): Likewise.
2775
5d3729b5
UW
27762009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2777
2778 * printcmd.c (next_gdbarch): New static variable.
2779 (set_next_address, do_examine, x_command): Set it.
2780 (decode_format): Use 'a' size to indicate width of an address.
2781 (do_examine): Add GDBARCH argument. Handle 'a' size.
2782 (x_command): Pass architecture to do_examine.
2783 Error if called without argument the first time.
2784 (do_one_display): Pass architecture to do_examine.
2785
2786 (examine_i_type, examine_b_type, examine_h_type, examine_w_type,
2787 examine_g_type): Remove.
2788 (_initialize_printcmd): Do not initialize them.
2789 (do_examine): Use builin_type_int... instead of examine_..._type.
2790
78267919
UW
27912009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2792
2793 * gdbtypes.h (struct builtin_type): Add internal_fn member.
2794 * gdbtypes.c (gdbtypes_post_init): Initialize it.
2795 * value.c (internal_fn_type): Remove.
2796 (_initialize_values): Do not initialize it.
2797
2798 * value.c (struct internalvar): Add enum internalvar_kind type and
2799 kind member. Restructure union internalvar_data type. Remove type,
2800 canonical, and make_value members.
2801 (init_if_undefined_command): Update for data structure changes.
2802 (create_internalvar): Likewise.
2803 (create_internalvar_type_lazy): Likewise.
2804 (get_internalvar_integer): Likewise.
2805 (get_internalvar_function): Likewise.
2806 (set_internalvar_component): Likewise.
2807 (set_internalvar): Likewise.
2808 (set_internalvar_integer): Likewise.
2809 (set_internalvar_function): Likewise.
2810 (clear_internalvar): Likewise.
2811 (add_internal_function): Likewise.
2812 (preserve_one_internalvar): New function.
2813 (preserve_values): Call it.
2814
2815 * value.h (value_of_internalvar): Add GDBARCH parameter.
2816 (internalvar_make_value): Likewise.
2817 * value.c (value_of_internalvar): Add GDBARCH parameter. Pass it to
2818 make_value callback. Use it to generate per-architecture result value
2819 types for internal variables with no pre-defined type. Update for data
2820 structure changes.
2821 (show_convenience): Pass architecture to value_of_internalvar.
2822 * eval.c (evaluate_subexp_standard): Likewise.
2823 * infrun.c (siginfo_make_value): Add GDBARCH parameter. Use it
2824 instead of current frame architecture. Return per-architecture type.
2825
2826 * value.h (set_internalvar_string): Add prototype.
2827 * value.c (set_internalvar_string): New function.
2828 * tracepoint.c (set_traceframe_context): Use it.
2829
0daa2b63
UW
28302009-07-02 Ulrich Weigand <uweigand@de.ibm.com>
2831
2832 * jv-lang.h (java_int_type, java_byte_type, java_short_type,
2833 java_long_type, java_boolean_type, java_char_type, java_float_type,
2834 java_double_type, java_void_type): Remove.
2835 (struct builtin_java_type): New data type.
2836 (builtin_java_type): Add prototype.
2837 (java_primitive_type): Add GDBARCH argument.
2838 (java_primitive_type_from_name): Likewise.
2839 (type_from_class): Likewise.
2840
2841 * jv-lang.c (java_int_type, java_byte_type, java_short_type,
2842 java_long_type, java_boolean_type, java_char_type, java_float_type,
2843 java_double_type, java_void_type): Remove.
2844
2845 (build_java_types, builtin_java_type): New functions.
2846 (java_type_data): New static variable.
2847 (_initialize_java_language): Initialize it. No longer initialize
2848 global types.
2849 (java_language_arch_info): Use per-architecture types.
2850
2851 (java_primitive_type): Add GDBARCH argument. Return per-architecture
2852 type instead of refering to global variable.
2853 (java_primitive_type_from_name): Add GDBARCH argument.
2854 (java_primitive_type_name): New function.
2855 (java_demangled_signature_length): Use it instead of
2856 java_primitive_type_from_name.
2857 (java_demangled_signature_copy): Likewise.
2858
2859 (type_from_class): Add GDBARCH argument. Pass to java_link_class_type,
2860 java_primitive_type, and recursive type_from_class call.
2861 (java_link_class_type): Add GDBARCH argument. Pass to type_from_class
2862 calls. Use per-architecture types instead of global types.
2863
2864 * jv-exp.y (parse_java_type): New define.
2865 Use per-architecture types instead of global types througout.
2866
2867 * jv-valprint.c (java_value_print): Pass architecture to
2868 type_from_class and java_primitive_type_from_name. Use per-
2869 architecture types instead of global types.
2870
d70e31dd
DE
28712009-07-01 Doug Evans <dje@google.com>
2872
2873 * NEWS: Mention biarch amd64-linux gdbserver and hardware watchpoint
2874 support for i386-linux, amd64-linux, and i386-win32 builds of
2875 gdbserver.
2876
b565e757 28772009-07-01 Nick Roberts <nickrob@snap.net.nz>
7371bfdc
NR
2878
2879 * Makefile.in (HFILES_NO_SRCDIR): Remove entries for deleted files.
2880
59dd3af6
JK
28812009-06-30 Jan Kratochvil <jan.kratochvil@redhat.com>
2882
2883 * Makefile.in (TARGET_FLAGS_TO_PASS): Include also FORCE_PARALLEL.
2884 (check//%): Construct FORCE_PARALLEL for the sub-make. Extend the
2885 comment for it.
2886
2fd481e1
PP
28872009-06-30 Paul Pluzhnikov <ppluzhnikov@google.com>
2888
2889 gdb/10275
2890 * dwarf2-frame.c (dwarf2_frame_state): Move cfa_offset, cfa_reg,
2891 cfa_how and cfa_exp into regs and adjust users.
2892
c38f313d
DJ
28932009-06-30 Daniel Jacobowitz <dan@codesourcery.com>
2894
2895 * dwarf2read.c (inherit_abstract_dies): Work around GCC PR 40573.
2896
8b777f02
VP
28972009-06-30 Vladimir Prus <vladimir@codesourcery.com>
2898
2899 * mi/mi-cmd-stack.c (parse_print_values): New.
2900 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args): Use the above.
2901
1a4300e9
VP
29022009-06-30 Vladimir Prus <vladimir@codesourcery.com>
2903
2904 * varobj.c (varobj_get_type): Use type_to_string.
2905
173853dc
PA
29062009-06-29 Pedro Alves <pedro@codesourcery.com>
2907
2908 * infrun.c (handle_inferior_event): Context switch to the new
2909 thread when resuming for a new_thread_event.
2910
4a399546
UW
29112009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2912
2913 * ada-lang.h (ada_convert_actual): Add GDBARCH argument.
2914 * ada-lang.c (convert_actual): Remove stale prototype.
2915 (ensure_lval, make_array_descriptor, ada_convert_actual):
2916 Add GDBARCH argument and pass through to subroutine calls.
2917 (ensure_lval): Use GDBARCH instead of current_gdbarch.
2918 * infcall.c (value_arg_coerce): Update ada_convert_actual call.
2919
30b15541
UW
29202009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2921
2922 * ada-lang.c (resolve): Use per-architecture void type instead
2923 of platform-independent one.
2924 (ada_evaluate_subexp) [STRUCTOP_STRUCT]: Likewise.
2925 (ada_resolve_function): Reimplement fallback logic to avoid
2926 explicit reference to builtin_type_void.
2927
7c964f07
UW
29282009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2929
2930 * ada-valprint.c (ada_print_scalar): Accept NULL type argument
2931 to indicate scalar should be printed as default integer.
2932 (print_optional_low_bound): Pass NULL to ada_print_scalar to
2933 indicate default integer output.
2934 * ada-typeprint.c (print_range, print_range_bound): Likewise.
2935 (print_choices): Likewise. Thus, accept NULL as val_type.
2936 * ada-lang.c (ada_variant_discrim_type): Return NULL when failed
2937 to look up controlling discriminant name.
2938
1ce677a4
UW
29392009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2940
2941 * ada-lang.c (to_fixed_range_type): Add ORIG_TYPE argument.
2942 Fall back to orig_type as index type if symbol lookup fails.
2943 Allocate result types from ORIG_TYPE's objfile.
2944 (ada_array_bound_from_type, to_fixed_array_type,
2945 ada_evaluate_subexp): Pass original index type to
2946 to_fixed_range_type. Do not pass objfile.
2947
2948 * ada-typeprint.c (print_range_type_named): Add ORIG_TYPE argument.
2949 Fall back to orig_type as index type if symbol lookup fails.
2950 (print_array_type, ada_print_type): Pass original index type
2951 to print_range_type_named.
2952
dd19d49e
UW
29532009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2954
2955 * ada-lang.c (ada_index_type): Update comment.
2956
1eea4ebd
UW
29572009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2958
2959 * ada-lang.c (ada_index_type): Make static. Add NAME argument.
2960 Throw error on invalid input arguments. Return NULL if unable
2961 to determine index type.
2962
2963 (ada_array_bound_from_type): Remove TYPEP argument.
2964 (ada_array_bound): Make static. Return LONGEST instead of value.
2965 Update for ada_array_bound_from_type change.
2966 (ada_array_length): Return LONGEST instead of value.
2967 Update for ada_array_bound_from_type change.
2968 (make_array_descriptor): Update for ada_array_bound change.
2969
2970 (ada_evaluate_subexp) [OP_ATR_RANGE, OP_ATR_FIRST, OP_ATR_LAST,
2971 OP_ATR_LENGTH]: Update for ada_array_bound_from_type,
2972 ada_array_bound, ada_array_length, ada_index_type changes.
2973 Always use ada_index_type to compute result type; fall back
2974 to architecture-specific integer type if ada_index_type fails.
2975
2976 * ada-lang.h (ada_index_type): Remove prototype.
2977 (ada_array_bound): Likewise.
2978
578933ab
PA
29792009-06-29 Pedro Alves <pedro@codesourcery.com>
2980
2981 * dbxread.c (read_dbx_symtab): Clear has_line_numbers when ending
2982 a psymtab.
2983
6bc80edc
TT
29842009-06-29 Tom Tromey <tromey@redhat.com>
2985
2986 * README: Mention parallel check.
2987
794684b6
SW
29882009-06-29 Sami Wagiaalla <swagiaal@redhat.com>
2989
2990 * dwarf2read.c (read_import_statement): Properly set import location
2991 and destination.
2992 * cp-support.h (cp_add_using, cp_add_using_directive): Now take char*
2993 inner, char* outer arguments. Updated callers.
2994
2497b498
UW
29952009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
2996
2997 * value.h (value_subscript, value_subscripted_rvalue,
2998 value_bitstring_subscript, value_ptradd): Use LONGEST instead
2999 of value as type of the index argument.
3000 (value_ptrsub): Remove.
3001 * valarith.c (value_subscript, value_subscripted_rvalue,
3002 value_bitstring_subscript, value_ptradd): Use LONGEST instead
3003 of value as type of the index argument.
3004 (value_ptrsub): Remove.
3005
3006 * wrapper.h (gdb_value_subscript): Use LONGEST instead of
3007 value as type of the index argument.
3008 * wrapper.c (gdb_value_subscript): Likewise.
3009
3010 Update calls to gdb_value_subscript, value_subscript,
3011 value_subscripted_rvalue, value_bitstring_subscript and
3012 value_ptradd to use LONGEST instead of value as index
3013 argument type. Use value_ptradd instead of value_ptrsub.
3014 * ada-lang.c (ada_value_subscript, ada_value_ptr_subscript,
3015 ada_tag_name_2): Update.
3016 * ada-tasks.c (read_atcb): Update.
3017 * eval.c (evaluate_subexp_standard): Update.
3018 * valarith.c (value_subscript): Update.
3019 * gnu-v2-abi.c (gnuv2_virtual_fn_field): Update.
3020 * gnu-v3-abi.c (gnuv3_get_virtual_fn, gnuv3_baseclass_offset,
3021 gnuv3_method_ptr_to_value): Update.
3022 * jv-lang.c (evaluate_subexp_java): Update.
3023 * m2-lang.c (evaluate_subexp_modula2): Update.
3024 * python/python-value.c (valpy_getitem, valpy_binop): Update.
3025 * wrapper.c (gdb_value_subscript): Update.
3026 * varobj.c (c_describe_child): Update.
3027
0c8b41f1
UW
30282009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
3029
3030 * gdbtypes.h (make_function_type): Remove OBJFILE parameter.
3031 * gdbtypes.c (make_function_type): Remove OBJFILE parameter.
3032 (lookup_function_type): Update call.
3033 * stabsread.c (read_type): Likewise.
3034 * dwarf2read.c (read_subroutine_type): Use lookup_function_type
3035 instead of make_function_type.
3036 * jv-lang.c (type_from_class): Likewise. Do not allocate types
3037 on the fake "dynamics" obstack.
3038
46bf5051
UW
30392009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
3040
3041 * gdbtypes.h (struct builtin_type): Remove builtin_core_addr,
3042 nodebug_text_symbol, nodebug_data_symbol, nodebug_unknown_symbol,
3043 and nodebug_tls_symbol members.
3044 (struct objfile_type): New data structure.
3045 (objfile_type): Add prototype.
3046 * gdbtypes.c (gdbtypes_post_init): Remove initialization code
3047 for types no longer in struct builtin_type.
3048 (objfile_type_data): New static variable.
3049 (_initialize_gdbtypes): Initialize it.
3050 (objfile_type): New function.
3051
3052 * gdbtypes.h (builtin_type_error): Remove.
3053 * gdbtypes.c (build_complex): Do not use builtin_type_error.
3054 * symtab.c (builtin_type_error): Remove.
3055 (_initialize_symtab): Remove initialization.
3056
3057 * stabsread.c (dbx_lookup_type, define_symbol, error_type,
3058 rs6000_builtin_type, read_range_type): Use per-objfile types
3059 instead of global or per-architecture builtin types.
3060 * coffread.c (decode_type): Likewise.
3061 * dwarf2read.c (read_array_type, read_tag_string_type,
3062 new_symbol, die_type): Likewise.
3063 * mdebugread.c (parse_symbol, basic_type, upgrade_type,
3064 parse_procedure, psymtab_to_symtab_1): Likewise.
3065 * xcoffread.c (process_xcoff_symbol): Likewise.
3066 * parse.c (write_exp_msymbol): Likewise.
3067
3068 * stabsread.c (rs6000_builtin_type_data): New static variable.
3069 (_initialize_stabsread): Initialize it.
3070 (rs6000_builtin_type): Add OBJFILE argument. Allocate builtin
3071 types per-objfile instead of globally.
3072
3073 * stabsread.c (dbx_lookup_type): Add OBJFILE argument. Use it
3074 instead of current_objfile; pass it to rs6000_builtin_type.
3075 (dbx_alloc_type, read_type, read_range_type): Update calls.
3076 (cleanup_undefined_types_noname): Add OBJFILE argument and
3077 pass it to dbx_lookup_type.
3078 (cleanup_undefined_types): Add OBJFILE argument and pass it
3079 to cleanup_undefined_types_noname.
3080 * stabsread.h (cleanup_undefined_types): Add OBJFILE argument.
3081 * buildsym.c (end_symtab): Update call.
3082
b08f1e8d
UW
30832009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
3084
3085 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
3086 target_gdbarch instead of current_gdbarch.
3087
6d10c194
UW
30882009-06-29 Ulrich Weigand <uweigand@de.ibm.com>
3089
3090 * Makefile.in (ALL_64_TARGET_OBS): Add amd64-windows-tdep.o.
3091 (ALL_TARGET_OBS): Add moxie-tdep.o, i386-darwin-tdep.o, and
3092 solib-darwin.o.
3093
3094 * configure.tgt: Add comment.
3095
9901a55b
PP
30962009-06-28 Paul Pluzhnikov <ppluzhnikov@google.com>
3097
3098 * mi/mi-cmds.c (mi_cmds): Remove unimplemented entries.
3099
edb3359d
DJ
31002009-06-27 Daniel Jacobowitz <dan@codesourcery.com>
3101 Jan Kratochvil <jan.kratochvil@redhat.com>
3102
3103 * NEWS: Document inlined function support.
3104 * Makefile.in (SFILES): Add inline-frame.c.
3105 (COMMON_OBS): Add inline-frame.o.
3106 * block.c (contained_in): Rewrite to use lexical nesting.
3107 (block_linkage_function): Skip inlined function blocks.
3108 (block_inlined_p): New.
3109 * block.h (struct block): Update comment.
3110 (block_inlined_p): New prototype.
3111 * blockframe.c (get_frame_block): Handle inlined functions.
3112 (get_frame_function): Do not use block_linkage_function.
3113 (block_innermost_frame): Use get_frame_block and contained_in.
3114 * breakpoint.c (watchpoint_check): Remove extra reinit_frame_cache.
3115 Skip over inlined functions. Simplify epilogue check.
3116 (bpstat_check_breakpoint_conditions): Use get_stack_frame_id.
3117 Update comments.
3118 (set_momentary_breakpoint): Only accept non-inlined frames.
3119 (watch_command_1): Use frame_unwind_caller_pc and
3120 frame_unwind_caller_id instead of get_prev_frame.
3121 (until_break_command): Likewise. Use get_stack_frame_id.
3122 * buildsym.c (end_symtab): Set SYMBOL_SYMTAB for block functions.
3123 * dwarf2loc.c (dwarf_expr_frame_base): Use block_linkage_function.
3124 * dwarf2read.c (process_die): Handle DW_TAG_inlined_subroutine.
3125 (read_func_scope, new_symbol): Likewise. Handle arguments specially
3126 for inlined functions without call site information.
3127 (inherit_abstract_dies): Allow tag mismatch for inlined subroutines.
3128 (die_specification): Treat DW_AT_abstract_origin as a specification.
3129 (read_type_die): Handle DW_TAG_inlined_subroutine.
3130 * frame-unwind.c (frame_unwind_init): Add inline_frame_unwind.
3131 * frame.c (fprint_frame_id): Print inline depth.
3132 (fprint_frame_type): Handle INLINE_FRAME and SENTINEL_FRAME.
3133 (skip_inlined_frames, get_stack_frame_id): New.
3134 (frame_unwind_caller_id): Use skip_inlined_frames.
3135 (frame_id_inlined_p): New.
3136 (frame_id_eq): Make the logic match the comments. Add inline_depth
3137 check.
3138 (frame_id_inner): Handle inlined functions.
3139 (frame_unwind_pc): New function, copied from frame_unwind_caller_pc.
3140 (frame_unwind_caller_pc): Use skip_inlined_frames and frame_unwind_pc.
3141 (get_prev_frame_1): Check for inline frames. Split out frame
3142 allocation to get_prev_frame_raw.
3143 (get_prev_frame_raw): New function.
3144 (get_prev_frame): Handle inline frames.
3145 (get_frame_pc): Use frame_unwind_pc.
3146 (get_frame_address_in_block): Skip inlined frames on both sides.
3147 (pc_notcurrent): Delete.
3148 (find_frame_sal): Rewrite to handle inline call sites. Use
3149 get_frame_address_in_block.
3150 (deprecated_update_frame_pc_hack): Make static.
3151 * frame.h: Update comments.
3152 (struct frame_id): Add inline_depth.
3153 (enum frame_type): Add INLINE_FRAME.
3154 (frame_id_inlined_p, get_stack_frame_id): New prototypes.
3155 * gdbthread.h (struct thread_info): Add step_stack_frame_id field.
3156 * infcmd.c (set_step_frame): New function.
3157 (step_once): Use set_step_frame. Handle inlined functions.
3158 (until_next_command): Use set_step_frame.
3159 (finish_backward), finish_forward): Use get_stack_frame_id.
3160 (finish_command): Support inlined functions.
3161 * inferior.h (set_step_info): New prototype.
3162 * infrun.c (RESUME_ALL): Use minus_one_ptid.
3163 (clear_proceed_status): Clear step_stack_frame_id.
3164 (init_wait_for_inferior): Call clear_inline_frame_state.
3165 (init_execution_control_state): Make static.
3166 (set_step_info): New function.
3167 (init_thread_stepping_state): Do not set the symtab or line here.
3168 (stepped_in_from): New function.
3169 (handle_inferior_event): Handle inlined functions. Use set_step_info.
3170 (insert_step_resume_breakpoint_at_frame): Use get_stack_frame_id.
3171 (struct inferior_status): Add step_stack_frame_id.
3172 (save_inferior_status, restore_inferior_status): Save and restore
3173 step_stack_frame_id.
3174 * inline-frame.c, inline-frame.h: New files.
3175 * minsyms.c (prim_record_minimal_symbol_and_info): Use XCALLOC.
3176 * regcache.c (regcache_write_pc): Call reinit_frame_cache.
3177 * s390-tdep.c (s390_prologue_frame_unwind_cache): Handle INLINE_FRAME.
3178 * stack.c (frame_show_address): New.
3179 (print_frame_info, print_frame): Use it.
3180 (find_frame_funname): Use get_frame_function. Handle inlined blocks.
3181 (frame_info): Mark inlined functions.
3182 (backtrace_command_1): Use get_current_user_frame.
3183 (print_frame_local_vars, print_frame_label_vars): Update comments.
3184 (return_command): Refuse inlined functions.
3185 * symtab.c (lookup_symbol_aux_local): Stop at inlined function
3186 boundaries.
3187 (find_function_start_sal): Avoid inlined functions.
3188 (completion_list_add_fields): New function.
3189 (default_make_symbol_completion_list): Use it. Use block_static_block
3190 and block_global_block. Check for inlined functions.
3191 (skip_prologue_using_sal): Avoid line number comparison across
3192 inlining.
3193 * symtab.h (struct symbol): Add is_inlined.
3194 (SYMBOL_INLINED): New.
3195 * target.c (target_resume): Call clear_inline_frame_state.
3196 * valops.c (value_of_variable): Check block_inlined_p.
3197
c7ce8faa
DJ
31982009-06-27 Daniel Jacobowitz <dan@codesourcery.com>
3199
3200 * frame.c (frame_unwind_id): Renamed to ...
3201 (frame_unwind_caller_id): ... this. All callers updated.
3202 (frame_pc_unwind): Renamed to ...
3203 (frame_unwind_caller_pc): ... this. All callers updated.
3204 * frame.h: Document frame_unwind_caller_WHAT functions.
3205 (frame_unwind_id): Renamed to ...
3206 (frame_unwind_caller_id): ... this.
3207 (frame_pc_unwind): Renamed to ...
3208 (frame_unwind_caller_pc): ... this.
3209 * hppa-tdep.c (hppa_find_unwind_entry_in_block): Correct comment.
3210 * stack.c (parse_frame_specification_1): Do not rely on
3211 frame_unwind_id.
3212
388a8562
MS
32132009-06-27 Michael Snyder <msnyder@vmware.com>
3214
3215 * infrun.c (handle_inferior_event): Improve handling of
3216 reverse-stepping into and over shared library functions.
3217
f3a5f1de
KO
32182009-06-25 Karen Osmond <karen.osmond@gmail.com>
3219
3220 * linespec.c (find_method): Add new not_found_ptr parameter to
3221 bring in line with symtab_from_filename, decode_variable.
3222 (decode_compound): Likewise. Also propagate not_found_ptr to
3223 find_method.
3224 (decode_line_1): Propagate not_found_ptr to decode_compound.
3225 (cplusplus_error): Now throws NOT_FOUND_ERROR.
3226
123e3958
KO
32272009-06-25 Karen Osmond <karen.osmond@gmail.com>
3228
3229 * MAINTAINERS (Write After Approval): Add self.
3230
4e608b4f
UW
32312009-06-23 Ulrich Weigand <uweigand@de.ibm.com>
3232
3233 * valops.c (value_one): Reimplement broken decimal-float case.
3234
34e13b5b
UW
32352009-06-23 Ulrich Weigand <uweigand@de.ibm.com>
3236
3237 * eval.c (evaluate_subexp_standard): Use expression architecture
3238 instead of current_gdbarch.
3239
3240 * infrun.c (handle_inferior_event): Avoid unncessary reference
3241 to current_gdbarch and get_current_frame ().
3242
0fd8e87f
UW
32432009-06-23 Ulrich Weigand <uweigand@de.ibm.com>
3244
3245 * breakpoint.h (set_longjmp_breakpoint): Add THREAD argument.
3246 (enum bptype): Add bp_longjmp_master.
3247
3248 * breakpoint.c (create_longjmp_master_breakpoint): New function.
3249 (update_breakpoints_after_exec): Handle bp_longjmp_master
3250 breakpoints. Call create_longjmp_master_breakpoint.
3251 (print_it_typical, bpstat_stop_status, bpstat_what,
3252 print_one_breakpoint_location, allocate_bp_location, mention,
3253 delete_command, breakpoint_re_set_one): Handle bp_longjmp_master.
3254 (breakpoint_re_set): Call create_longjmp_master_breakpoint.
3255 (create_longjmp_breakpoint): Delete.
3256 (set_longjmp_breakpoint): Add THREAD argument. Reimplement
3257 to install momentary clones of bp_longjmp_master breakpoints.
3258
3259 * infcmd.c (step_1): Pass thread to set_longjmp_breakpoint.
3260
ca5f395d
CC
32612009-06-23 Cary Coutant <ccoutant@google.com>
3262
3263 * dwarf2read.c (dwarf_decode_lines): Ignore rows where is_stmt is 0.
3264 Set basic_block to 0 after a special opcode.
3265
5b2ab461
JK
32662009-06-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3267
3268 Fix a regression by the mmap patch from 2009-06-16.
3269 * symfile.c (reread_symbols): Move sym_finish and clear_objfile_data
3270 calls before deleting the OBJFILE obstack. Extend the comment.
3271
45d5d5ca
UW
32722009-06-23 Ulrich Weigand <uweigand@de.ibm.com>
3273
3274 * jv-lang.h (JAVA_OBJECT_SIZE): Remove.
3275 (get_java_object_header_size): Add GDBARCH parameter.
3276 * jv-lang.c (get_java_object_header_size): Add GDBARCH parameter.
3277 Use it instead of current_gdbarch.
3278 (evaluate_subexp_java): Replace JAVA_OBJECT_SIZE with call to
3279 get_java_object_header_size.
3280 * jv-valprint.c (java_value_print): Likewise.
3281
27aa8d6a
SW
32822009-06-23 Sami Wagiaalla <swagiaal@redhat.com>
3283
01fc9d36
TG
3284 * dwarf2read.c (process_die): Handle import statements
3285 (DW_TAG_imported_declaration, case DW_TAG_imported_module)
3286 (read_import_statement): New.
3287 (read_func_scope): Update using_directives to point to current context
3288 (read_lexical_block_scope): Ditto.
3289 * cp-support.h: Added prototype for cp_add_using.
3290 * cp-namespace.c: Removed local context_stack.
3291 (cp_initialize_namespace): Deleted.
3292 (cp_finalize_namespace): Deleted.
3293 (cp_add_using_directive): Use using_directives instead of using_list.
3294 (cp_add_using): No longer static.
3295 * buildsym.h: Created global using_direct variable.
3296 Created using_direct variable in context_stack.
3297 * buildsym.c (finish_block): Set using directives for the block under
3298 construction.
3299 (start_symtab): Removed call to cp_initialize_namespace().
3300 (end_symtab): Removed call to cp_finalize_namespace().
3301 (push_context): Save and reset using_directives.
3302 * block.c (block_using): Return using directives for given
3303 block instead of static block.
27aa8d6a 3304
ad068eab
UW
33052009-06-23 Ulrich Weigand <uweigand@de.ibm.com>
3306
3307 * target-descriptions.h (struct type): Do not declare.
3308 (struct tdesc_type): Declare.
3309 (tdesc_named_type): Change return type to struct tdesc_type *.
3310 (tdesc_record_type): Remove.
3311 (tdesc_create_vector): Add prototype.
3312 (tdesc_create_union): Likewise.
3313 (tdesc_add_field): Likewise.
3314
3315 * target-descriptions.c (struct tdesc_reg): Replace gdb_type
3316 member by tdesc_type member.
3317 (struct tdesc_type_field, tdesc_type_field): Add type and vector def.
3318 (struct tdesc_type, tdesc_type_p): Likewise.
3319 (struct tdesc_arch_reg, tdesc_arch_reg): Likewise.
3320 (struct tdesc_feature): Change type of "types" to VEC(tdesc_type_p).
3321 (struct tdesc_arch_data): Replace registers member by arch_regs.
3322
3323 (tdesc_predefined_types): Change to array of pre-defined
3324 struct tdesc_type structures. Add "code_ptr" and "data_ptr".
3325 (tdesc_named_type): Return struct tdesc_type * instead of GDB type.
3326 (tdesc_gdb_type): New function.
3327
3328 (target_find_description): Update for data structure changes.
3329 (tdesc_data_cleanup): Likewise.
3330 (tdesc_numbered_register): Likewise.
3331 (tdesc_use_registers): Likewise.
3332 (tdesc_create_reg): Likewise.
3333
3334 (tdesc_find_arch_register): New function.
3335 (tdesc_find_register): Use it.
3336 (tdesc_register_type): Use tdesc_gdb_type to generate GDB type from
3337 tdesc_type on demand; cache generated types in tdesc_arch_reg.
3338
3339 (tdesc_free_type): New function.
3340 (tdesc_free_feature): Call it.
3341
3342 (tdesc_create_vector): New function.
3343 (tdesc_create_union): Likewise.
3344 (tdesc_add_field): Likewise.
3345 (tdesc_record_type): Remove.
3346
3347 (tdesc_type_id): Remove.
3348 (maint_print_c_tdesc_cmd): Update for data structure changes. Update
3349 generated code to create tdesc_type structures instead of GDB types.
3350
3351 * xml-tdesc.c: Do not include "gdbtypes.h".
3352 (struct tdesc_parsing_data): Change type of current_union to
3353 struct tdesc_type *.
3354 (tdesc_start_reg): Do not special-case "code_ptr" or "data_ptr".
3355 (tdesc_start_union): Call tdesc_create_union.
3356 (tdesc_start_field): Call tdesc_add_field.
3357 (tdesc_start_vector): Call tdesc_create_vector.
3358 (tdesc_end_union): Remove.
3359 (feature_children): Remove reference to tdesc_end_union.
3360
3361 * features/arm-with-iwmmxt.c: Regenerate.
3362 * features/mips-linux.c: Regenerate.
3363 * features/mips64-linux.c: Regenerate.
3364 * features/rs6000/powerpc-32.c: Regenerate.
3365 * features/rs6000/powerpc-32l.c: Regenerate.
3366 * features/rs6000/powerpc-403.c: Regenerate.
3367 * features/rs6000/powerpc-403gc.c: Regenerate.
3368 * features/rs6000/powerpc-505.c: Regenerate.
3369 * features/rs6000/powerpc-601.c: Regenerate.
3370 * features/rs6000/powerpc-602.c: Regenerate.
3371 * features/rs6000/powerpc-603.c: Regenerate.
3372 * features/rs6000/powerpc-604.c: Regenerate.
3373 * features/rs6000/powerpc-64.c: Regenerate.
3374 * features/rs6000/powerpc-64l.c: Regenerate.
3375 * features/rs6000/powerpc-7400.c: Regenerate.
3376 * features/rs6000/powerpc-750.c: Regenerate.
3377 * features/rs6000/powerpc-860.c: Regenerate.
3378 * features/rs6000/powerpc-altivec32.c: Regenerate.
3379 * features/rs6000/powerpc-altivec32l.c: Regenerate.
3380 * features/rs6000/powerpc-altivec64.c: Regenerate.
3381 * features/rs6000/powerpc-altivec64l.c: Regenerate.
3382 * features/rs6000/powerpc-e500.c: Regenerate.
3383 * features/rs6000/powerpc-e500l.c: Regenerate.
3384 * features/rs6000/powerpc-isa205-32l.c: Regenerate.
3385 * features/rs6000/powerpc-isa205-64l.c: Regenerate.
3386 * features/rs6000/powerpc-isa205-altivec32l.c: Regenerate.
3387 * features/rs6000/powerpc-isa205-altivec64l.c: Regenerate.
3388 * features/rs6000/powerpc-isa205-vsx32l.c: Regenerate.
3389 * features/rs6000/powerpc-isa205-vsx64l.c: Regenerate.
3390 * features/rs6000/powerpc-vsx32.c: Regenerate.
3391 * features/rs6000/powerpc-vsx32l.c: Regenerate.
3392 * features/rs6000/powerpc-vsx64.c: Regenerate.
3393 * features/rs6000/powerpc-vsx64l.c: Regenerate.
3394 * features/rs6000/rs6000.c: Regenerate.
3395
284614f0
JB
33962009-06-23 Joel Brobecker <brobecker@adacore.com>
3397
3398 * ada-lang.c (decode_packed_array): If the value is a pointer to
3399 an array, then use value_ind to dereference it, not ada_value_ind.
3400 (ada_template_to_fixed_record_type_1): Handle the case where a
3401 dynamic field is an aligner type.
3402 (to_fixed_array_type): Add handling for packed array types.
3403 (ada_get_base_type): Do not follow the XVS type if the type is
3404 an aligner type.
3405 (ada_evaluate_subexp): Split a few statements up for clarity
3406 and debuggability.
3407 <OP_FUNCALL>: Add handling of the case of a packed array that
3408 has already been fixed.
3409
4b27a620
JB
34102009-06-23 Joel Brobecker <brobecker@adacore.com>
3411
3412 * ada-lang.c (evaluate_subexp): Delete. Use the version from eval.c.
3413 (evaluate_subexp_type): Reimplement using evaluate_subexp.
3414 * value.h (evaluate_subexp): Add declaration.
3415 * eval.c (evaluate_subexp): Make non-static.
3416 * objc-lang.c (print_object_command): Use evaluate_subexp.
3417
69de3c6a
PP
34182009-06-23 Paul Pluzhnikov <ppluzhnikov@google.com>
3419
3420 Revert 2009-05-14 breakpoint commit (no longer needed).
3421 * breakpoint.h (breakpoint_re_set_objfile): Remove
3422 * breakpoint.c (breakpoint_re_set_objfile): Likewise
3423 (create_overlay_event_breakpoint): Remove objfile parameter,
3424 iterate over all objfiles.
3425 * objfiles.c (objfile_relocate): Update.
3426 * symfile.c (new_symfile_objfile): Likewise.
3427
85e306ed
TT
34282009-06-23 Tom Tromey <tromey@redhat.com>
3429
3430 PR gdb/10309:
3431 * c-lang.c (classify_type): Iterate over typedefs.
3432 * c-valprint.c (textual_element_type): Iterate over typedefs.
3433
7bd06e87
TG
34342009-06-22 Tristan Gingold <gingold@adacore.com>
3435
3436 * darwin-nat.c (darwin_xfer_partial): Use host_address_to_string
3437 instead of "%p".
3438
07e7f39f
JK
34392009-06-22 Jan Kratochvil <jan.kratochvil@redhat.com>
3440
3441 PR gdb/9988:
3442 * buildsym.c (block_compar): New function.
3443 (end_symtab): Replace the bubble sort by a qsort based code.
3444
34452009-06-22 Sami Wagiaalla <swagiaal@redhat.com>
f667014e
SW
3446
3447 * MAINTAINERS (Write After Approval): Add self.
3448
6e3f70d7
UW
34492009-06-22 Ulrich Weigand <uweigand@de.ibm.com>
3450
3451 * spu-tdep.c (spu_get_longjmp_target): New function.
3452 (spu_gdbarch_init): Install it.
3453
df4b58fe
L
34542009-06-22 H.J. Lu <hongjiu.lu@intel.com>
3455
3456 PR server/10306
3457 * remote.c (getpkt_or_notif_sane_1): Initialize val to -1.
3458
a49f981f
MS
34592009-06-21 Michael Snyder <msnyder@vmware.com>
3460
3461 * inferior.h: Update ancient comment.
3462
0763ab81
PA
34632009-06-20 Aleksandar Ristovski <aristovski@qnx.com>
3464 Pedro Alves <pedro@codesourcery.com>
3465
3466 * solib-svr4.c (IGNORE_FIRST_LINK_MAP_ENTRY): Avoid dereferencing
3467 NULL pointer.
3468 (scan_dyntag): Skip if input bfd isn't elf flavoured.
3469 (locate_base): Call elf_locate_base even without an exec_bfd.
3470
5d2c29b8
TT
34712009-06-19 Samuel Bronson <naesten@gmail.com>
3472
121e16b5 3473 PR cli/9903:
5d2c29b8
TT
3474 * cli/cli-decode.c (apropos_cmd): Skip traversing abbreviations
3475 for prefix commands to avoid duplicates in the output.
3476
4a98be19
TT
34772009-06-19 Samuel Bronson <naesten@gmail.com>
3478
121e16b5 3479 PR cli/9903:
4a98be19
TT
3480 * cli/cli-decode.c (apropos_cmd): Fix avoidance of double
3481 printing.
3482
3daf8fe5
JG
34832009-06-19 Jerome Guitton <guitton@adacore.com>
3484
3485 * breakpoint.c (expand_line_sal_maybe): When explicit_line,
3486 skip prologue on each sals.
3487 (skip_prologue_sal): Return explicit_line and explicit_pc
3488 unmodified.
3489
bb00b29d
TG
34902009-06-19 Tristan Gingold <gingold@adacore.com>
3491
8e54f210
TG
3492 * darwin-nat.c (_initialize_darwin_inferior): Remove commented-out
3493 line.
3494
34952009-06-19 Tristan Gingold <gingold@adacore.com>
bb00b29d
TG
3496 * machoread.c (macho_symtab_read): Adjust for bfd changes.
3497 * darwin-nat.h (struct darwin_exception_msg): New type to describe
3498 a mach exception.
3499 (struct private_thread_info): New type to describe the state of the
3500 thread.
3501 (DEF_VEC_I thread_t): Removed, replaced by ...
3502 (DEF_VEC_O darwin_thread_t): ... this new type.
3503 (struct darwin_inferior): Renamed to ...
3504 (struct private_inferior): ... this type. Fields added.
3505 (darwin_not_port): Moved into the private inferior structure.
3506 * darwin-nat.c: Add includes, improve comments.
3507 Rewrite to handle multiple threads and processes.
3508 (darwin_resume_to): New function and protype.
3509 (darwin_resume, darwin_wait_to, darwin_wait): Ditto.
3510 (darwin_kill_inferior): Add ops argument.
3511 (darwin_pid_to_str): New function.
3512 (darwin_thread_alive): Ditto.
3513 (darwin_inf, darwin_not_port): Removed.
3514 (darwin_inf_fake_stop): New variable.
3515 (msgin, msgout, msg_state, exc_msg): Removed.
3516 (mach_check_error): Use warning instead of error.
3517 (darwin_ptrace): Adjust debug level.
3518 (cmp_thread_t): Fix names (typo).
3519 (darwin_check_new_threads): Argument is now an inferior,
3520 adjust for new structures, add no change check, ignore dead ports,
3521 handle first thread case.
3522 (find_inferior_task_it): New function.
3523 (find_inferior_notify_it): Ditto.
3524 (darwin_find_inferior_by_task): Ditto.
3525 (darwin_find_inferior_by_notify): Ditto.
3526 (darwin_find_thread): Ditto.
3527 (darwin_suspend_inferior): Ditto.
3528 (darwin_resume_inferior): Ditto.
3529 (catch_exception_raise_state): Removed.
3530 (catch_exception_raise_state_identity): Removed.
3531 (darwin_suspend_inferior_it): New function.
3532 (darwin_resume_inferior_it): Ditto.
3533 (darwin_dump_message): New function, extracted from darwin_wait.
3534 (darwin_decode_exception_message): New function.
3535 (darwin_encode_reply): New function.
3536 (catch_exception_raise): Removed.
3537 (darwin_send_reply): New function, extracted from darwin_resume.
3538 (darwin_resume_thread): New function, extracted from darwin_resume.
3539 (struct resume_inferior_threads_param): New type.
3540 (darwin_resume_inferior_threads_it): New function.
3541 (darwin_resume_inferior_threads): New function.
3542 (darwin_suspend_inferior_threads): New function.
3543 (darwin_resume): Mostly rewritten to handle multiple threads and
3544 some corner cases.
3545 (darwin_decode_message): New function extracted from darwin_wait.
3546 (cancel_breakpoint): New function.
3547 (darwin_wait): Mostly rewritten. Handle multiple threads.
3548 (darwin_mourn_inferior): Adjust for per process structures.
3549 (darwin_reply_to_all_pending_messages): New function.
3550 (darwin_stop_inferior): Adjust for per inferior structures.
3551 (darwin_attach_pid): Ditto.
3552 (darwin_init_thread_list): Ditto.
3553 (darwin_attach): Ditto.
3554 (darwin_detach): Ditto.
3555 (darwin_files_info): Now empty.
3556 (darwin_pid_to_str): Adjust returns string to match one expected by
3557 the testsuite.
3558 (darwin_read_write_inferior): Rename err variable to match other uses.
3559 Adjust debug message. Handle submaps.
3560 (darwin_xfer_memory): Adjust for per inferior structures.
3561 (set_enable_mach_exceptions): Ditto.
3562 (darwin_pid_to_exec_file): New function.
3563 (darwin_get_ada_task_ptid): Ditto.
3564 (darwin_supports_multi_process): Ditto.
3565 (_initialize_darwin_inferior): Remove useless assertion, adjust for
3566 per inferior structures. Add new target operations.
3567
31410e84
MS
35682009-06-18 Hui Zhu <teawater@gmail.com>
3569 Michael Snyder <msnyder@vmware.com>
3570
3571 * infrun.c (handle_inferior_event): Improve reverse stepping
3572 through function epilogue.
3573
6373d119
MS
3574 * infrun.c (handle_inferior_event): Reverse-next through
3575 trampoline.
3576
c098b58b
PP
35772009-06-18 Paul Pluzhnikov <ppluzhnikov@google.com>
3578
3579 * dwarf2-frame.c (struct comp_unit): Use bfd_size_type for
3580 dwarf_frame_size.
3581
affddf13
TT
35822009-06-17 Tom Tromey <tromey@redhat.com>
3583
3584 * dwarf2read.c (zlib_decompress_section): Use a cleanup.
3585
9898f801
UW
35862009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3587
3588 * gdbarch.sh (pointer_to_address): Change to type 'm'.
3589 (address_to_pointer): Likewise.
3590 * gdbarch.c, gdbarch.h: Regenerate.
3591
3592 * inferior.h (unsigned_pointer_to_address): Add GDBARCH argument.
3593 (signed_pointer_to_address): Likewise.
3594 (unsigned_address_to_pointer, address_to_signed_pointer): Likewise.
3595 * findvar.c (unsigned_pointer_to_address): Likewise.
3596 (signed_pointer_to_address): Likewise.
3597 (unsigned_address_to_pointer, address_to_signed_pointer): Likewise.
3598
3599 * avr-tdep.c (avr_address_to_pointer): Likewise.
3600 (avr_pointer_to_address): Likewise.
3601 * iq2000-tdep.c (iq2000_pointer_to_address): Likewise.
3602 (iq2000_address_to_pointer): Likewise.
3603 * m32c-tdep.c (m32c_m16c_address_to_pointer): Likewise.
3604 (m32c_m16c_pointer_to_address): Likewise.
3605 * spu-tdep.c (spu_pointer_to_address): Likewise.
3606 * xstormy16-tdep.c (xstormy16_pointer_to_address): Likewise.
3607 (xstormy16_address_to_pointer): Likewise.
3608
1fac167a
UW
36092009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3610
3611 * printcmd.c (print_scalar_formatted): Always truncate
3612 unsigned data types.
3613
3614 * cli-dump.c (struct callback_data): Change type of load_offset
3615 to CORE_ADDR.
3616 (restore_binary_file): Update type casts.
3617 (restore_command): Parse load_offset as address, not long.
3618
3619 * utils.c (string_to_core_addr): Do not sign-extend value.
3620 * varobj.c (find_frame_addr_in_frame_chain): Truncate frame_base
3621 before comparing against requested frame address.
3622
a78c2d62
UW
36232009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3624
3625 * gdbarch.sh (gcore_bfd_target): New gdbarch callback.
3626 * gdbarch.h, gdbarch.c: Regenerate.
3627
3628 * gcore.c (default_gcore_target): Make return value const.
3629 Call gdbarch_gcore_bfd_target if present.
3630 (default_gcore_arch, default_gcore_mach): Use target_gdbarch.
3631
3632 * corelow.c (core_read_description): Call gdbarch_core_read_description
3633 on core_gdbarch instead of current_gdbarch.
3634
3635 * ppc-linux-tdep.c (ppc_linux_init_abi): Install gcore_bfd_target.
3636
3b7538c0
UW
36372009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3638
3639 * gdbtypes.c (create_string_type): Receive character type as argument.
3640 * gdbtypes.h (create_string_type): Add character type argument.
3641 * dwarf2read.c (read_tag_string_type): Pass character type to
3642 create_string_type.
3643
3644 * value.h (value_string): Add character type argument.
3645 * valops.c (value_string): Add character type argument. Pass it to
3646 create_string_type. Do not allocate space in inferior.
3647 * valarith.c (value_concat): Pass character type to value_string.
3648
3649 * value.h (value_typed_string): Rename to ...
3650 (value_cstring): ... this.
3651 * valops.c (value_typed_string): Rename to ...
3652 (value_cstring): ... this.
3653 * c-lang.c (evaluate_subexp_c): Update.
3654
3655 * python/python-value.c (builtin_type_pychar): New define.
3656 (convert_value_from_python): Call value_cstring instead
3657 of value_from_string.
3658 * value.c (value_from_string): Remove.
3659 * value.h (value_from_string): Remove.
3660
3661 * eval.c (evaluate_subexp_standard): Pass character type to
3662 value_string. Pass expression architecture to value_nsstring
3663 and lookup_child_selector.
3664 * objc-lang.h (lookup_objc_class): Add GDBARCH parameter.
3665 (lookup_child_selector): Likewise.
3666 (value_nsstring): Likewise.
3667 * objc-lang.c (lookup_objc_class): Add GDBARCH parameter.
3668 Pass character type to value_string..
3669 (lookup_child_selector): Likewise.
3670 (value_nsstring): Add GDBARCH parameter, use it instead of
3671 objfile architecture. Pass architecture to lookup_objc_class
3672 and lookup_child_selector. Pass character type to value_string.
3673 (end_msglist): Pass architecture to lookup_objc_class.
3674 * objc-exp.y: Pass architecture to lookup_objc_class.
3675
e6c014f2
UW
36762009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3677
3678 * gdbtypes.h (struct language_defn): Add forward declaration.
3679 (lookup_typename): Add LANGUAGE and GDBARCH parameters.
3680 (lookup_unsigned_typename): Likewise.
3681 (lookup_signed_typename): Likewise.
3682 * gdbtypes.c (lookup_typename): Add LANGUAGE and GDBARCH parameters.
3683 Use them instead of current_language and current_gdbarch.
3684 (lookup_unsigned_typename): Add LANGUAGE and GDBARCH parameters.
3685 Pass them to lookup_typename.
3686 (lookup_signed_typename): Likewise.
3687
3688 * c-exp.y: Pass parse_language and parse_gdbarch to
3689 lookup_unsigned_typename and lookup_signed_typename.
3690 * objc-exp.y: Likewise.
3691 * m2-exp.y: Pass parse_language and parse_gdbarch to lookup_typename.
3692
3693 * c-lang.c (evaluate_subexp_c): Pass expression language and
3694 gdbarch to lookup_typename.
3695 * printcmd.c (printf_command): Pass current language and
3696 gdbarch to lookup_typename.
3697 * python/python-type.c (typy_lookup_typename): Likewise.
3698 Include "language.h".
3699
ec22ec34
UW
37002009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3701
3702 * sparc64-nat.c (sparc64_gregset_supplies_p): Add GDBARCH parameter.
3703 Use it instead of current_gdbarch. Pass architecture to
3704 sparc32_gregset_supplies_p.
3705 (sparc64_fpregset_supplies_p): Add GDBARCH parameter. Use it instead
3706 of current_gdbarch. Pass architecture to sparc32_fpregset_supplies_p.
3707 * sparc64nbsd-nat.c (sparc64nbsd_gregset_supplies_p,
3708 sparc64nbsd_fpregset_supplies_p): Likewise.
3709 * sparc-nat.c (sparc_gregset_supplies_p, sparc_fpregset_supplies_p):
3710 Add GDBARCH parameter.
3711 (sparc32_gregset_supplies_p, sparc32_fpregset_supplies_p): Likewise.
3712 (sparc_fetch_inferior_registers): Pass regcache architecture to
3713 sparc_gregset_supplies_p and sparc_fpregset_supplies_p.
3714 (sparc_store_inferior_registers): Likewise.
3715 * sparc-nat.h (sparc_gregset_supplies_p, sparc_fpregset_supplies_p:
3716 Add GDBARCH parameter.
3717 (sparc32_gregset_supplies_p, sparc32_fpregset_supplies_p): Likewise.
3718
a97b0ac8
UW
37192009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3720
3721 * ada-tasks.c (read_known_tasks_array): Use target_gdbarch instead
3722 of current_gdbarch.
3723 * aix-thread.c (pd_enable): Likewise.
3724 * amd64-linux-nat.c (ps_get_thread_area): Likewise.
3725 * bsd-uthread.c (bsd_uthread_activate): Likewise.
3726 * linux-nat.c (linux_nat_info_proc_cmd): Likewise.
3727 * linux-thread-db.c (enable_thread_event): Likewise.
3728 * monitor.c (monitor_write_memory, monitor_read_memory): Likewise.
3729 * nto-procfs.c (procfs_open): Likewise.
3730 * procfs.c (invalidate_cache, procfs_insert_watchpoint,
3731 info_proc_mappings, info_mappings_callback): Likewise.
3732 * record.c (record_open): Likewise.
3733 * rs6000-nat.c (ARCH64): Likewise.
3734 * solib-darwin.c (darwin_solib_create_inferior_hook): Likewise.
3735 (darwin_bfd_open): Likewise.
3736 * memattr.c (mem_info_command): Likewise.
3737
3738 * windows-nat.c (win32_resume): Use current regcache architecture
3739 instead of current_gdbarch.
3740
3741 * dbug-rom.c (dbug_regname): Remove check against number of
3742 registers in current_gdbarch.
3743 * solib-pa64.c (read_dynamic_info): Remove unused variable.
3744
d80b854b
UW
37452009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3746
3747 * dummy-frame.c (deprecated_pc_in_call_dummy): Add GDBARCH parameter,
3748 use it instead of current_gdbarch.
3749 * frame.h (deprecated_pc_in_call_dummy): Add GDBARCH parameter.
3750 * arm-tdep.c (arm_skip_prologue): Pass architecture to
3751 deprecated_pc_in_call_dummy.
3752
3753 * symtab.c (skip_prologue_using_sal): Add GDBARCH parameter.
3754 Use it instead of current_gdbarch.
3755 * symtab.h (skip_prologue_using_sal): Add GDBARCH parameter.
3756 * breakpoint.c (expand_line_sal_maybe): Pass architecture to
3757 skip_prologue_using_sal.
3758 * arm-tdep.c (skip_prologue_using_sal): Likewise.
3759 * lm32-tdep.c (lm32_skip_prologue): Likewise.
3760 * m32-tdep.c (m32c_skip_prologue): Likewise.
3761 * mips-tdep.c (mips_skip_prologue): Likewise.
3762 * moxie-tdep.c (moxie_skip_prologue): Likewise.
3763 * mt-tdep.c (mt_frame_unwind_cache): Likewise.
3764 * rs6000-tdep.c (rs6000_skip_prologue): Likewise.
3765 * frv-tdep.c (frv_analyze_prologue): Add GDBARCH parameter, pass
3766 it to skip_prologue_using_sal. Update call sites ...
3767 (frv_skip_prologue, frv_frame_unwind_cache): ... here.
3768
3769 * mn10300-tdep.c (struct mn10300_prologue): Add GDBARCH member.
3770 (check_for_saved): Use it instead of current_gdbarch.
3771 (mn10300_analyze_prologue): Set it.
3772
3773 * value.c (using_struct_return): Add GDBARCH parameter. Use it
3774 instead of current_gdbarch.
3775 * value.h (using_struct_return): Add GDBARCH parameter.
3776 * eval.c (evaluate_subexp_standard): Pass architecture to
3777 using_struct_return.
3778 * infcall.c (call_function_by_hand): Likewise.
3779 * stack.c (return_command): Likewise.
3780 * sparc-tdep.c (sparc32_push_dummy_code): Likewise.
3781
3782 * symtab.c (in_prologue): Add GDBARCH parameter. Use it instead of
3783 current_gdbarch.
3784 * symtab.h (in_prologue): Add GDBARCH parameter.
3785 * infrun.c (handle_inferior_event): Pass architecture to in_prologue.
3786
3787 * eval.c (evaluate_subexp_standard): Use expression architecture
3788 instead of current_gdbarch.
3789
3790 * c-lang.c (evaluate_subexp_c): Use expression architecture and
3791 language instead of current_gdbarch and current_language.
3792
3793 * printcmd.c (do_one_display): Use expression architecture instead
3794 of current_gdbarch.
3795
3796 * infcmd.c (print_return_value): Use architecture of stop_regcache
3797 instead of current_gdbarch.
3798 (print_vector_info, print_float_info): Remove GDBARCH argument,
3799 use frame architecture instead.
3800 (vector_info, float_info): Update calls.
3801
3802 * objc-lang.c (objc_skip_trampoline): Use frame architecture
3803 instead of current_gdbarch.
3804
3805 * parse.c (write_dollar_variable): Use parse architecture instead
3806 of current_gdbarch.
3807
3808 * source.c (line_info): Use objfile architecture instead of
3809 current_gdbarch.
3810
3811 * symtab.c (find_function_start_sal): Use gdbarch instead of
3812 current_gdbarch.
3813 (print_msymbol_info): Use objfile architecture instead of
3814 current_gdbarch.
3815
3816 * valops.c (value_assign): Use frame architecture instead of
3817 current_gdbarch.
3818
fbf65064
UW
38192009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3820
3821 * buildsym.c (record_line): Remove call to gdbarch_addr_bits_remove.
3822
3823 * coffread.c (coff_symtab_read): Call gdbarch_addr_bits_remove before
3824 calling record_line.
3825 (enter_linenos): Likewise.
3826 * dbxread.c (process_one_symbol): Likewise.
3827 * dwarf2read.c (dwarf_decode_lines): Likewise.
3828 * mdebugread.c (psymtab_to_symtab_1): Likewise.
3829 * xcoffread.c (enter_line_range): Likewise.
3830
505e835d
UW
38312009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3832
3833 * ax-gdb.c (gen_bitfield_ref): Add EXP argument, use expression
3834 architecture instead of current_gdbarch.
3835 (gen_struct_ref): Add EXP argument, pass to get_bitfield_ref.
3836 (gen_expr): Pass expression to get_struct_ref.
3837
3838 * symtab.h (struct symbol_ops): Add GDBARCH parameter to
3839 tracepoint_var_ref callback.
3840 * ax-gdb.c (gen_var_ref): Pass architecture to tracepoint_var_ref
3841 symbol operation callback.
3842 * dwarf2loc.c (dwarf2_tracepoint_var_ref): Add GDBARCH parameter.
3843 Use it instead of current_gdbarch.
3844 (locexpr_tracepoint_var_ref): Add GDBARCH parameter. Pass it to
3845 dwarf2_tracepoint_var_ref.
3846 (loclist_tracepoint_var_ref): Likewise.
3847
55f960e1
UW
38482009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3849
3850 * prologue-value.c (make_pv_area): Add ADDR_BIT argument.
3851 Use it instead of address bits of current_gdbarch.
3852 * prologue-value.c (make_pv_area): Add ADDR_BIT argument.
3853 * arm-tdep.c (thumb_analyze_prologue): Pass address bits to
3854 make_pv_area.
3855 (arm_scan_prologue): Likewise.
3856 * m32c-tdep.c (m32c_analyze_prologue): Likewise.
3857 * mep-tdep.c (mep_analyze_prologue): Likewise.
3858 * mn10300-tdep.c (mn10300_analyze_prologue): Likewise.
3859 * s390-tdep.c (s390_analyze_prologue): Likewise.
3860
7ccb0be9
UW
38612009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3862
3863 * mi/mi-main.c (mi_cmd_data_list_register_names): Use selected
3864 frame architecture instead of current_gdbarch.
3865 (mi_cmd_data_list_changed_registers): Likewise.
3866 (mi_cmd_data_list_register_values): Likewise. Pass selected
3867 frame to get_register.
3868 (get_register): Add FRAME argument, use it as frame to retrieve
3869 registers from (instead of selected frame). Use frame architecture
3870 instead of current_gdbarch.
3871 (mi_cmd_data_write_register_values): Use current regcache
3872 architecture instead of current_gdbarch.
3873
5eccfcc2
UW
38742009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3875
3876 * tui/tui-regs.c (tui_show_register_group): Remove GDBARCH parameter;
3877 use frame architecture instead. Replace current_gdbarch uses.
3878 (tui_show_registers): Update call.
3879 (tui_get_register): Remove GDBARCH parameter; use frame architecture
3880 instead.
3881 (tui_show_register_group): Update call.
3882 (tui_check_register_values): Likewise.
3883 (tui_register_format): Remove GDBARCH parameter; use frame
3884 architecture instead. Replace current_gdbarch uses.
3885 (tui_get_register): Update call.
3886
bd57a748
UW
38872009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3888
3889 * gdbarch.sh (construct_inferior_arguments): Remove.
3890 * gdbarch.c, gdbarch.h: Regenerate.
3891 * infcmd.c (get_inferior_args): Call construct_inferior_arguments
3892 directly instead of gdbarch_construct_inferior_arguments.
3893 (construct_inferior_arguments): Remove GDBARCH argument.
3894 * inferior.h (construct_inferior_arguments): Likewise.
3895
9216df95
UW
38962009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3897
3898 * symfile.c (section_is_mapped): Use objfile architecture instead
3899 of current_gdbarch.
3900 (TARGET_LONG_BYTES): Remove.
3901 (read_target_long_array): Add SIZE argument. Use it instead of
3902 TARGET_LONG_BYTES.
3903 (simple_read_overlay_table): Retrieve long size from objfile
3904 architecture; pass it to read_target_long_array.
3905 (simple_read_overlay_region_table): Likewise.
3906 (simple_overlay_update_1): Likewise.
3907
9f5a595d
UW
39082009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3909
3910 * infrun.c (cleanup_displaced_step_closure): Remove.
3911 (displaced_step_clear_cleanup): Move to before displaced_step_prepare.
3912 (displaced_step_prepare): Use displaced_step_clear_cleanup instead
3913 of cleanup_displaced_step_closure.
3914 (handle_inferior_event, keep_going): Use thread architecture instead
3915 of current_gdbarch.
3916
568d6575
UW
39172009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
3918
3919 * infrun.c (handle_inferior_event): Use current frame architecture
3920 or thread architecture instead of current_gdbarch. Pass to
3921 handle_step_into_function and handle_step_into_function_backward.
3922 (handle_step_into_function): Add GDBARCH parameter. Use it instead
3923 of current_gdbarch.
3924 (handle_step_into_function_backward): Likewise.
3925 (insert_step_resume_breakpoint_at_frame): Use frame architecture
3926 instead of current_gdbarch.
3927 (insert_step_resume_breakpoint_at_caller): Likewise.
3928
ea5d7a99
PM
39292009-06-17 Pierre Muller <muller@ics.u-strasbg.fr>
3930 Pedro Alves <pedro@codesourcery.com>
3931
3932 * infcmd.c (post_create_inferior): Call breakpoint_re_set after target
3933 is pushed for watchpoint promotion to hardware watchpoint.
3934
dce234bc
PP
39352009-06-16 Paul Pluzhnikov <ppluzhnikov@google.com>
3936
3937 * dwarf2read.c (dwarf_info_section, dwarf_abbrev_section)
3938 (dwarf_line_section, dwarf_pubnames_section, dwarf_aranges_section)
3939 (dwarf_loc_section, dwarf_macinfo_section, dwarf_str_section)
3940 (dwarf_ranges_section, dwarf_frame_section)
3941 (dwarf_eh_frame_section): Removed.
3942 (dwarf2_resize_section): Likewise.
3943 (dwarf2_read_section): Now static, use bfd_mmap() if possible.
3944 (dwarf2_get_section_info): New function.
3945 (munmap_section_buffer): Likewise.
3946 (dwarf2_per_objfile_cleanup): Likewise.
3947 (section_is_p): Signature change.
3948 * dwarf2-frame.c (dwarf2_build_frame_info): Use
3949 dwarf2_get_section_info instead of dwarf2_read_section.
3950
7eedccfa
PP
39512009-06-16 Paul Pluzhnikov <ppluzhnikov@google.com>
3952
3953 * solib.c (symbol_add_stub): New FLAGS parameter.
3954 (solib_read_symbols): FROM_TTY -> FLAGS, call symbol_add_stub
3955 directly.
3956 (solib_add): Defer breakpoint_re_set until after all solibs.
3957 * bsd-uthread.c (bsd_uthread_solib_loaded): Adjust.
3958 * rs6000-nat.c (objfile_symbol_add): Adjust.
3959 * symfile.c (syms_from_objfile): Merge parameters into ADD_FLAGS.
3960 (new_symfile_objfile): Likewise.
3961 (symbol_file_add_with_addrs_or_offsets): Likewise.
3962 (symbol_file_add_from_bfd): Likewise.
3963 (symbol_file_add): Likewise.
3964 * symfile.h (enum symfile_add_flags): New. Adjust prototypes.
3965 * symfile-mem.c (symbol_file_add_from_memory): Adjust.
3966 * windows-nat.c (safe_symbol_file_add_stub): Adjust.
3967 * machoread.c (macho_oso_symfile, macho_symfile_read): Adjust.
3968
19ef5c71
KS
39692009-06-16 Keith Seitz <keiths@redhat.com>
3970
3971 * linespec.c (collect_methods): Delete.
3972 (add_matching_methods): Reove destructor special case.
3973 (find_method): Call find_methods directly instead of
3974 collect_methods.
3975 * valops.c (value_struct_elt): Remove destructor
3976 special cases.
3977 (check_field): Likewise.
3978 (value_struct_elt_for_reference): Likewise.
3979 (destructor_name_p): Remove misleading comment about dtors
3980 being "special cases".
3981 * gdbtypes.h (get_destructor_fn_field): Remove. No longer needed.
3982 * gdbtypes.c (get_destructor_fn_field): Likewise.
3983
a4261689
PA
39842009-06-16 Pedro Alves <pedro@codesourcery.com>
3985
3986 * mi/mi-main.c (mi_cmd_data_read_memory): Dispatch
3987 TARGET_OJECT_MEMORY reads to the topmost target, not to the
3988 flattened current_target.
3989
4e99ad69
TG
39902009-06-16 Tristan Gingold <gingold@adacore.com>
3991
3992 * avr-tdep.c (struct gdbarch_tdep): Replace the unused field with
3993 call_length field.
3994 (avr_register_name): Add const to register_names.
3995 (avr_scan_arg_moves): Move inside avr_scan_prologue.
3996 (avr_scan_prologue): Add pc_end argument.
3997 Only read prologue bytes that can be read.
3998 Limit the scan to the known prologue length.
3999 Makes pattern variables static and const.
4000 Fix indentation.
4001 (avr_skip_prologue): Pass func_end argument to avr_scan_prologue.
4002 Fix indentation.
4003 (avr_breakpoint_from_pc): Constify avr_break_insn.
4004 (avr_extract_return_value): Fix function comment.
4005 (avr_frame_unwind_cache): Fix GNU style violations.
4006 Pass current_pc argument to avr_scan_prologue to stop prologue
4007 analysis to the current pc. This fixes the bug with the 'next'
4008 command.
4009 Correctly set the SP register of the previous frame (use call_length).
4010 (avr_frame_prev_register): Fix indentation.
4011 Correctly read PC from the stack on avr6 architectures.
4012 (avr_push_dummy_call): Fix indentation.
4013 (avr_gdbarch_init): Set call_length according to the architecture.
4014
7cd1089b
PM
40152009-06-15 Phil Muldoon <pmuldoon@redhat.com>
4016
4017 * infcall.c (show_unwind_on_terminating_exception_p): New
4018 function.
4019 (call_function_by_hand): Create breakpoint and clean-up call for
4020 std::terminate.breakpoint. Add unwind_on_terminating_exception_p
4021 gate. Pop frame on breakpoint hit.
4022 (_initialize_infcall): Add add_setshow_boolean_cmd for
4023 unwind-on-terminating-exception.
4024
b2ab525c
KB
40252009-06-12 Kevin Buettner <kevinb@redhat.com>
4026
4027 * dwarf2read.c (dwarf2_psymtab_to_symtab): Propagate
4028 `has_section_at_zero' flag from stripped objfile to separate,
4029 debug info only, objfile.
4030
4b477ade
PA
40312009-06-12 Pedro Alves <pedro@codesourcery.com>
4032
4033 * exec.h (section_table_xfer_memory_partial): Improve description,
4034 mention SECTION_NAME.
4035 * exec.c (section_table_xfer_memory_partial): Remove stale
4036 description.
4037
c59fcb4c
AR
40382009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
4039
4040 * nto-tdep.h (nto_generic_supply_gpregset)
4041 (nto_generic_supply_fpregset, nto_generic_supply_altregset): Remove.
4042 * nto-tdep.c (nto_generic_supply_gpregset)
4043 (nto_generic_supply_fpregset, nto_generic_supply_altregset): Remove.
4044
19a934d8
AR
40452009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
4046
4047 * i386-nto-tdep.c (I386_NTO_SIGCONTEXT_OFFSET): Remove define.
4048 (i386nto_sigcontext_addr): Change the way context address is calculated.
4049 (i386nto_init_abi): Remove usage of deprecated sc_reg_offset and
4050 sc_sp_offset and set sc_reg_offset and sc_num_regs.
4051
80b1849c
AR
40522009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
4053
4054 * i386-nto-tdep.c (i386_nto_target): Remove definition.
4055 (init_i386nto_ops): Use macros to set fields to global
4056 current_nto_target directly.
4057 (i386nto_init_abi): Remove unused nto_set_target call.
4058 * nto-tdep.h (nto_set_target): Remove unused declaration.
4059 * nto-tdep.c (nto_set_target): Remove unused function.
4060
80c99de1
PA
40612009-06-11 Pedro Alves <pedro@codesourcery.com>
4062
4063 * breakpoint.c (break_command_really): Rename local variable
4064 breakpoint_chain to bkpt_chain.
4065
dbfb31a4
AR
40662009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
4067
4068 Add support for XMM registers.
4069 * i386-nto-tdep.c (i386nto_regset_id): Add case for SSE register set.
4070 (i386nto_register_area): Correctly calculate offsets and sizes for
4071 all supported registers.
4072
17dd65ce
TT
40732009-06-11 Tom Tromey <tromey@redhat.com>
4074
4075 * eval.c (evaluate_subexp_standard) <OP_OBJC_MSGCALL>: Remove
4076 'static' from local variable definitions.
4077
828cd292
PA
40782009-06-11 Pedro Alves <pedro@codesourcery.com>
4079
4080 * symtab.c (append_expanded_sal): Remove unused local variables.
4081
d4db2f36
PA
40822009-06-11 Pedro Alves <pedro@codesourcery.com>
4083
4084 * infrun.c (sched_multi): New global.
4085 (resume): If sched_multi is set, resume only threads of the
4086 current inferior.
4087 (prepare_to_proceed): Don't switch over to wait_ptid if we're
4088 resuming a different inferior, and sched_multi is off.
4089 (show_schedule_multiple): New.
4090 (_initialize_infrun): Register new "set schedule-multiple" command.
4091 * inferior.h (sched_multi): Declare.
4092 * NEWS: Mention new "schedule-multiple" setting.
4093
e21458b2
PA
40942009-06-11 Pedro Alves <pedro@codesourcery.com>
4095
4096 * varobj.c (varobj_create): Properly restore the selected frame.
4097
8bb318c6
TT
40982009-06-05 Tom Tromey <tromey@redhat.com>
4099
4100 * inferior.c (print_inferior): Make a table, not a list. Emit
4101 table headers.
4102
bbb29520
PA
41032009-06-10 Jonas Maebe <jonas.maebe@elis.ugent.be>
4104
4105 * darwin-nat.c (darwin_stop_inferior): Pass 0 as options to
4106 darwin_wait (blocking wait).
4107 (darwin_kill_inferior): Likewise.
4108
66852e9c
PA
41092009-06-10 Pedro Alves <pedro@codesourcery.com>
4110
4111 * infrun.c (handle_inferior_event): Update comment around trying
4112 to revert back to a stepping thread that has exited.
4113
d0c6ba3d
CC
41142009-06-10 Cary Coutant <ccoutant@google.com>
4115
4116 * dwarf2read.c (dwarf_decode_lines): Recognize and ignore
4117 DW_LNE_set_discriminator.
4118
059fb39f
PM
41192009-06-10 Pierre Muller <muller@ics.u-strasbg.fr>
4120
4121 * breakpoint.c: ARI fixes.
4122 (create_overlay_event_breakpoint): Avoid assignment inside if statement.
4123 (print_one_breakpoint_location): Likewise.
4124 (create_longjmp_breakpoint): Likewise.
4125 (tracepoint_save_command): Likewise
4126 (bpstat_find_step_resume_breakpoint): No operator at end of line.
4127 (bpstat_stop_status): Likewise.
4128 (describe_other_breakpoints): Likewise.
4129 (hw_watchpoint_used_count): Likewise.
4130 (expand_line_sal_maybe): Likewise.
4131 (break_command_really): Likewise.
4132 (delete_command): Likewise.
4133 (do_enable_breakpoint): Likewise.
4134 (delete_trace_command): Likewise.
4135 (catch_exception_command_1): Likewise and remove extra parentheses.
4136
7681d515
PM
41372009-06-08 Pierre Muller <muller@ics.u-strasbg.fr>
4138
4139 * breakpoint.c (_initialize_breakpoint): Remove "bu" command alias of
4140 "ubreak" command that does not exist.
4141
300d0284
PM
41422009-06-08 Pierre Muller <muller@ics.u-strasbg.fr>
4143
4144 * cli/cli-decode.c (add_alias_cmd): Correct assertion.
4145
72753510
PA
41462009-06-07 Pedro Alves <pedro@codesourcery.com>
4147
4148 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
4149
d1a7880c
PA
41502009-06-07 Pedro Alves <pedro@codesourcery.com>
4151
4152 * procfs.h: New.
4153 * proc-utils.h (procfs_first_available): Don't declare here.
4154 * sol-thread.c: Include procfs.h instead of sys/procfs.h and
4155 proc-utils.h.
4156 * procfs.c: Include procfs.h.
4157 (procfs_target): Make it public. Don't register
4158 procfs_can_use_hw_breakpoint here.
4159 (proc_set_watchpoint): Check for PCWATCH or PIOCSWATCH being
4160 defined instead of TARGET_HAS_HARDWARE_WATCHPOINTS.
4161 (procfs_can_use_hw_breakpoint): Remove check of
4162 TARGET_HAS_HARDWARE_WATCHPOINTS.
4163 (procfs_use_watchpoints): Register procfs_can_use_hw_breakpoint
4164 here.
4165 (_initialize_procfs): Don't add the procfs target here.
4166
4167 * i386-sol2-nat.c: Include target.h and procfs.h.
4168 (_initialize_amd64_sol2_nat): Install the procfs target here,
4169 customized with watchpoints support.
4170 * irix5-nat.c: Include target.h.
4171 (_initialize_core_irix5): Rename to ...
4172 (_initialize_irix5_nat): ... this. Install the procfs target
4173 here, customized with watchpoints support.
4174 * alpha-nat.c: Include procfs.h.
4175 (_initialize_core_alpha): Rename to...
4176 (_initialize_alpha_nat): ... this. Install the procfs target
4177 here, customized with watchpoints support.
4178 * sparc-sol2-nat.c: Include target.h and procfs.h.
4179 (_initialize_sparc_sol2_nat): New.
4180
4181 * config/i386/nm-i386sol2.h (TARGET_HAS_HARDWARE_WATCHPOINTS): Delete.
4182 * config/sparc/nm-sol2.h (TARGET_HAS_HARDWARE_WATCHPOINTS): Delete.
4183 * config/mips/irix5.mh (NAT_FILE): Delete.
4184 * config/mips/irix6.mh (NAT_FILE): Delete.
4185 * config/mips/nm-irix5.h: Delete.
4186
81b92222
PA
418720009-06-07 Pedro Alves <pedro@codesourcery.com>
4188
4189 * auxv.c (procfs_xfer_auxv): Change type of the `object' argument
4190 to enum target_object. Cleanup comments.
4191 * auxv.h: Include "target.h". Cleanup comments to not mention
4192 NATIVE_XFER_AUXV anymore.
4193
cc35222d
PA
41942009-06-07 Pedro Alves <pedro@codesourcery.com>
4195
4196 * inferior.h (procfs_first_available): Move declaration to...
4197 * proc-utils.h: ... here.
4198 * sol-thread.c: Include procfs.h and proc-utils.h.
4199
09d3bde9
PA
42002009-06-07 Pedro Alves <pedro@codesourcery.com>
4201
4202 * inferior.h (proc_iterate_over_mappings): Delete declaration.
4203 * nto-tdep.h (proc_iterate_over_mappings): Delete declaration.
4204 * procfs.c (proc_iterate_over_mappings): Delete.
4205
c35b1492
PA
42062009-06-07 Pedro Alves <pedro@codesourcery.com>
4207
4208 * target.h (struct target_ops): Make to_has_all_memory,
4209 to_has_memory, to_has_stack, to_has_registers and to_has_execution
4210 methods instead of variables.
4211 (target_has_all_memory_1, target_has_memory_1, target_has_stack_1)
4212 (target_has_registers_1, target_has_execution_1): Declare
4213 functions.
4214 (target_has_all_memory): Rewrite to call target_has_all_memory_1.
4215 (target_has_memory): Rewrite to call target_has_memory_1.
4216 (target_has_stack): Rewrite to call target_has_all_stack_1.
4217 (target_has_registers): Rewrite to call target_has_registers_1.
4218 (target_has_execution): Rewrite to call target_has_execution_1.
4219 (default_child_has_all_memory, default_child_has_memory)
4220 (default_child_has_stack, default_child_has_registers)
4221 (default_child_has_execution): Declare.
4222 (target_mark_running, target_mark_exited): Delete declarations.
4223 * target.c (default_child_has_all_memory,
4224 default_child_has_memory, default_child_has_stack,
4225 default_child_has_registers, default_child_has_execution): New.
4226 (target_has_all_memory_1, target_has_memory_1, target_has_stack_1,
4227 target_has_registers_1, target_has_execution_1): New.
4228 (add_target): Default the to_has_all_memory, to_has_all_memory,
4229 to_has_memory, to_has_stack, to_has_registers and to_has_execution
4230 callbacks to return 0.
4231 (update_current_target): Do not inherit to_has_all_memory,
4232 to_has_memory, to_has_stack, to_has_registers or to_has_execution.
4233 (target_mark_running, target_mark_exited): Delete.
4234 (memory_xfer_partial): Adjust.
4235 (target_read_memory, target_write_memory, target_search_memory):
4236 Dispatch to the the top-most target, not the flattened
4237 current_target.
4238 (target_info): Adjust.
4239 (init_dummy_target): Install return_zero as callback for
4240 to_has_all_memory, to_has_memory, to_has_stack, to_has_registers,
4241 to_has_execution.
4242 (set_maintenance_target_async_permitted): Use have_live_inferiors
4243 instead of target_has_execution.
4244 * target-memory.c (target_write_memory_blocks): Dispatch memory
4245 writes to the the top-most target, not the flattened
4246 current_target.
4247
4248 * breakpoint.c (insert_breakpoints): Don't check for
4249 target_has_execution here.
4250 (update_global_location_list): Check if there are live inferiors
4251 to debug instead of target_has_execution.
4252 * infcmd.c (kill_command, detach_command): Check if there are
4253 inferiors instead of target_has_execution.
4254 * inferior.h (have_live_inferiors): Declare.
4255 * inferior.c (have_live_inferiors): New.
4256 * infrun.c (normal_stop): Don't check for target_has_execution to
4257 finish the thread states.
4258 * thread.c (is_thread_state, is_stopped, is_exited, is_running)
4259 (any_running, is_executing): Remove checks for
4260 target_has_execution.
4261 * top.c (kill_or_detach): Don't try to kill core inferiors.
4262 (quit_target): Don't check for target_has_execution.
4263
4264 * corelow.c (core_has_memory, core_has_stack, core_has_registers):
4265 New.
4266 (init_core_ops): Install core_has_memory, core_has_stack and
4267 core_has_registers.
4268 * exec.c (exec_has_memory): New.
4269 (init_exec_ops): Install exec_has_memory.
4270 * remote.c (remote_add_inferior): Don't call target_mark_running.
4271 (remote_start_remote): Don't call target_mark_exited or call
4272 target_mark_running.
4273 (remote_open_1): Use have_inferiors instead of
4274 target_has_execution. Don't use target_mark_exited.
4275 (init_remote_ops): Install deafult_child_has_all_memory,
4276 default_child_has_memory, default_child_has_stack,
4277 default_child_has_registers, default_child_has_execution.
4278 * bsd-kvm.c (bsd_kvm_return_one): New.
4279 (bsd_kvm_add_target): Register bsd_kvm_return_one as
4280 to_has_memory, to_has_stack and to_has_registers callbacks.
4281 * remote-m32r-sdi.c (m32r_return_one): New.
4282 (init_m32r_ops): Register it.
4283 * inf-child.c (inf_child_target): Adjust to register
4284 default_child_has_all_memory, default_child_has_memory,
4285 default_child_has_stack, default_child_has_registers,
4286 default_child_has_execution callbacks.
4287 * gnu-nat.c (init_gnu_ops): Likewise.
4288 * go32-nat.c (init_go32_ops): Likewise.
4289 * hpux-thread.c (init_hpux_thread_ops): Likewise.
4290 * monitor.c (init_base_monitor_ops): Likewise.
4291 * nto-procfs.c (init_procfs_ops): Likewise.
4292 * remote-mips.c (_initialize_remote_mips): Likewise.
4293 * windows-nat.c (init_windows_ops): Likewise.
4294 * remote-sim.c (gdbsim_create_inferior): Don't use
4295 target_mark_running or target_mark_exited.
4296 (gdbsim_mourn_inferior): Don't call target_mark_exited.
4297 (init_gdbsim_ops): Adjust to register
4298 default_child_has_all_memory, default_child_has_memory,
4299 default_child_has_stack, default_child_has_registers,
4300 default_child_has_execution callbacks.
4301
4302 * linux-nat.c (linux_nat_xfer_partial): If reading memory, and
4303 there's no inferior selected, defer to a lower stratum.
4304
da1f2771
TT
43052009-06-05 Tom Tromey <tromey@redhat.com>
4306
4307 * varobj.c (update_dynamic_varobj_children): Wrap error text in
4308 _().
4309 (install_visualizer): Likewise.
4310 (varobj_set_visualizer): Likewise.
4311
68c9c314 43122009-06-05 Marc Khouzam <marc.khouzam@ericsson.com>
4b459977
VP
4313
4314 * mi/mi-main.c (mi_cmd_exec_continue)
4315 (mi_cmd_exec_interrupt): Adjust parsing of thread group
4316 ids to current reality, where they don't have any 'p' prefix.
4317
b3ed98d2
AR
43182009-06-05 Aleksandar Ristovski <aristovski@qnx.com>
4319
4320 * corelow.c (core_open): Check for core_gdbarch before calling
4321 gdbarch_target_signal_from_host.
4322
68c1b02d
TT
43232009-06-05 Tom Tromey <tromey@redhat.com>
4324
4325 * c-exp.y (parse_number): Don't use K&R definition.
4326 (yylex): Likewise.
4327 (yyerror): Likewise.
4328
0b4bc29a
JK
43292009-06-04 Jan Kratochvil <jan.kratochvil@redhat.com>
4330
4331 * varobj.c (varobj_update): Fix out of scope varobjs to not to change.
4332
768a979c
UW
43332009-06-04 Ulrich Weigand <uweigand@de.ibm.com>
4334
4335 * symtab.h: Rename SYMBOL_OPS to SYMBOL_COMPUTED_OPS.
4336 * ax-gdb.c (gen_var_ref): Likewise.
4337 * findvar.c (read_var_value, symbol_read_needs_frame): Likewise.
4338 * printcmd.c (address_info): Likewise.
4339 * dwarf2loc.c (dwarf_expr_frame_base): Likewise.
4340 * dwarf2read.c (dwarf2_symbol_mark_computed): Likewise.
4341 * symtab.h: Rename struct symbol_ops to struct symbol_computed_ops.
4342 * dwarf2loc.h: Likewise.
4343 * dwarf2loc.c (dwarf2_locexpr_funcs, dwarf2_loclist_funcs): Likewise.
4344
4345 * symtab.h: (struct symbol_register_ops): New struct definition.
4346 (struct symbol): Make "ops" member a union of symbol_computed_ops and
4347 symbol_register_ops callback pointers.
4348 (SYMBOL_REGISTER_OPS): New macro.
4349 * tracepoint.c: Include "objfiles.h".
4350 (scope_info, collect_symbol): Use SYMBOL_REGISTER_OPS register_number
4351 callback to retrieve register numbers.
4352 * ax-gdb.c (gen_var_ref): Likewise.
4353 * findvar.c (read_var_value): Likewise.
4354 * printcmd.c (address_info): Likewise.
4355
4356 * coffread.c (coff_reg_to_regnum): New function.
4357 (coff_register_funcs): New static variable.
4358 (process_coff_symbol): Do not call gdbarch_sdb_reg_to_regnum.
4359 Install SYMBOL_REGISTER_OPS callbacks.
4360 * mdebugread.c (mdebug_reg_to_regnum): New function.
4361 (mdebug_register_funcs): New static variable.
4362 (parse_symbol): Do not call gdbarch_ecoff_reg_to_regnum.
4363 Install SYMBOL_REGISTER_OPS callbacks.
4364 * stabsread.c (stab_reg_to_regnum): New function.
4365 (stab_register_funcs): New static variable.
4366 (define_symbol): Do not call gdbarch_stab_reg_to_regnum.
4367 Install SYMBOL_REGISTER_OPS callbacks.
4368
930123b7
DE
43692009-06-03 Doug Evans <dje@google.com>
4370
4371 * symfile.c (reread_symbols): Reset psymtabs_addrmap to NULL
4372 after discarding its contents.
4373
07b82ea5
PA
43742009-06-03 Pedro Alves <pedro@codesourcery.com>
4375
4376 * target.c: Include "exec.h".
4377 (update_current_target): Don't inherit to_sections or
4378 to_sections_end.
4379 (target_get_section_table): New.
4380 (target_section_by_addr): Fetch the section table from the passed
4381 in target.
4382 (memory_xfer_partial): Handle unmapped overlay sections before
4383 anything else. Get the overlay mapped address here. Adjust to
4384 use section_table_xfer_memory_partial.
4385 (get_target_memory): Request a TARGET_OBJECT_RAW_MEMORY object
4386 instead of TARGET_OBJECT_MEMORY.
4387 (target_resize_to_sections): Delete.
4388 (remove_target_sections): Adjust to remove target sections from
4389 `current_target_sections', and use resize_section_table.
4390 * target.h (struct target_ops) <to_sections, to_sections_end>:
4391 Remove fields.
4392 <to_get_section_table>: New method.
4393 (xfer_memory, print_section_info): Delete declarations.
4394 (struct target_section_table): New type.
4395 (target_get_section_table): Declare.
4396 (target_resize_to_sections): Delete declaration.
4397 (remove_target_sections): Delete declaration.
4398 * bfd-target.c (target_bfd_xfer_partial): Get the section table
4399 from to_data.
4400 (target_bfd_get_section_table): New.
4401 (target_bfd_xclose): Adjust.
4402 (target_bfd_reopen): Store the section table in the to_data field.
4403 * corelow.c (core_data): New.
4404 (core_close): Adjust to release core_data and its sections.
4405 (core_open): Allocate core_data, and build its target sections
4406 table.
4407 (deprecated_core_resize_section_table): New.
4408 (core_files_info): Pass core_data to print_section_info.
4409 (core_xfer_partial): Adjust to use
4410 section_table_xfer_memory_partial for TARGET_OBJECT_MEMORY xfers.
4411 (init_core_ops): Do not install a deprecated_xfer_memory callback
4412 anymore.
4413 * solib.c (update_solib_list): Add the shared library sections
4414 to the current target sections table.
4415 * exec.c (current_target_sections_1): New global.
4416 (current_target_sections): New global.
4417 (exec_close_1): New function, refactored from exec_close. Remove
4418 the exec_bfd's sections from the current target sections table.
4419 Adjust to not use to_sections.
4420 (exec_close): Remove all target sections. Call exec_close_1.
4421 (exec_file_clear): Use exec_close_1 instead of unpushing the
4422 target.
4423 (exec_file_attach): Likewise. Adjust to not use to_sections. Add
4424 exec_bfd's sections to the current target sections table. Don't
4425 push the exec_ops target here.
4426 (resize_section_table): New.
4427 (add_target_sections): New.
4428 (remove_target_sections): Moved here.
4429 (section_table_xfer_memory): Adjust to implement the xfer_partial
4430 interface, and rename to...
4431 (section_table_xfer_memory_partial): ... this, replacing the
4432 current function of that same name.
4433 (exec_get_section_table): New.
4434 (exec_xfer_partial): New.
4435 (xfer_memory): Delete.
4436 (print_section_info): Replace the target_ops parameter by a
4437 target_section_table parameter.
4438 (exec_files_info, set_section_command, exec_set_section_address):
4439 Adjust to use the current sections table.
4440 (init_exec_ops): Do not register a deprecated_xfer_memory
4441 callback. Register to_xfer_partial and to_get_section_table
4442 callbacks.
4443 * infrun.c (handle_inferior_event): Update comments around
4444 solib_add.
4445 * rs6000-nat.c (xcoff_relocate_core): Adjust to use
4446 deprecated_core_resize_section_table.
4447 * exec.h (resize_section_table): Declare.
4448 (section_table_xfer_memory_partial): Add const char * argument.
4449 (remove_target_sections): Declare here.
4450 (add_target_sections): Declare.
4451 (print_section_info): Declare here.
4452 * gdbcore.h (deprecated_core_resize_section_table): Declare.
4453
4fa62494
UW
44542009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
4455
4456 * value.h (struct internalvar): Remove.
4457 (get_internalvar_integer): Add prototype.
4458 (set_internalvar_integer): Add prototype.
4459 (clear_internalvar): Add prototype.
4460
4461 * value.c (struct internalvar): Move here. Add type member. Remove
4462 endian member. Add union_internalvar member instead of value member.
4463 (init_if_undefined_command): Use intvar->type.
4464 (create_internalvar): Do not initialize value/endian, but type.
4465 (create_internalvar_type_lazy): Call create_internalvar.
4466 (value_of_internalvar): Handle host-side internalvar contents.
4467 (set_internalvar_component): Likewise.
4468 (set_internalvar): Likewise.
4469 (get_internalvar_integer): New function.
4470 (clear_internalvar): Likewise.
4471 (set_internalvar_integer): Likewise.
4472 (preserve_values): Handle host-side internalvar contents.
4473
4474 * breakpoint.c (set_breakpoint_count, set_tracepoint_count): Call
4475 set_internalvar_integer instead of set_internalvar.
4476 * findcmd.c (find_command): Likewise.
4477 * infrun.c (handle_inferior_event): Likewise.
4478 * source.c (forward_search_command, reverse_search_command): Likewise.
4479 * tracepoint.c (set_traceframe_num, set_tracepoint_num,
4480 set_traceframe_context): Likewise.
4481
4482 * printcmd.c (x_command): Call clear_internalvar instead of
4483 set_internalvar.
4484 * tracepoint.c (set_traceframe_context): Likewise.
4485
4486 * breakpoint.c (get_number_trailer): Call get_internalvar_integer
4487 instead of value_of_internalvar.
4488 * linespec.c (decode_dollar): Likewise.
4489
4490 * expprint.c (dump_subexp_body_standard): Use internalvar_name
4491 instead of accessing internalvar private elements.
4492 * valops.c (value_assign): Copy from original source instead of
4493 accessing internalvar private elements.
4494
6ceaaae5
UW
44952009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
4496
4497 * scm-lang.c (builtin_type_scm): Remove.
4498 (scm_lookup_name): Add GDBARCH parameter. Use it instead of
4499 objfile architecture. Use per-architecture builtin_scm_type instead
4500 of builtin_type_scm.
4501 (evaluate_exp): Pass expression architecture to scm_lookup_name.
4502
4503 (scm_get_field): Add SIZE parameter. Use it instead of
4504 TYPE_LENGTH (builtin_type_scm).
4505
4506 (build_scm_types): New function.
4507 (scm_type_data): New variable.
4508 (builtin_scm_type): New function.
4509 (_initialize_scheme_language): Do not initialize builtin_type_scm.
4510 Register build_scm_types as post-init function for scm_type_data.
4511
4512 * scm-exp.c (scm_lreadr): Use per-architecture builtin_scm_type
4513 instead of builtin_type_scm.
4514
4515 * scm-lang.h (SCM_CAR, SCM_CDR): Pass SCM_SIZE to scm_get_field.
4516 (scm_get_field): Add SIZE paramter.
4517 (scm_scmval_print): Remove prototype.
4518 (builtin_type_scm): Remove.
4519 (struct builtin_scm_type): Add structure definition.
4520 (builtin_scm_type): Add prototype.
4521
4522 * scm-valprint.c (scm_inferior_print): Add TYPE parameter. Use it
4523 instead of builtin_core_addr type; do not use objfile architecture.
4524 (scm_scmlist_print): Add TYPE parameter. Use it to define SCM_SIZE.
4525 Pass type to scm_scmval_print.
4526 (scm_ipruk): Add TYPE parameter. Use it to define SCM_SIZE.
4527 (scm_scmval_print): Make static. Add TYPE parameter. Use it to
4528 define SCM_SIZE. Pass type to scm_ipruk and scm_scmlist_print.
4529 (scm_val_print): Pass type to scm_inferior_print and scm_scmval_print.
4530
0a9d309a
UW
45312009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
4532
4533 * mdebugread.c (mdebug_type_void, mdebug_type_char, mdebug_type_short,
4534 mdebug_type_int, mdebug_type_int_32, mdebug_type_int_64,
4535 mdebug_type_long_32, mdebug_type_long_64, mdebug_type_long_long_64,
4536 mdebug_type_unsigned_char, mdebug_type_unsigned_short,
4537 mdebug_type_unsigned_int_32, mdebug_type_unsigned_int_64,
4538 mdebug_type_unsigned_long_32, mdebug_type_unsigned_long_64,
4539 mdebug_type_unsigned_long_long_64, mdebug_type_adr_32,
4540 mdebug_type_adr_64, mdebug_type_float, mdebug_type_double,
4541 mdebug_type_complex, mdebug_type_double_complex,
4542 mdebug_type_fixed_dec, mdebug_type_float_dec, mdebug_type_string):
4543 Remove.
4544
4545 (basic_type_data): New global variable.
4546 (basic_type): New function.
4547 (parse_type): Remove static basic type map map_bt. Call basic_type
4548 to get basic types instead of using mdebug_type_ variables.
4549
4550 (parse_symbol): Use builtin types instead of mdebug_type_ variables.
4551 (upgrade_type): Likewise.
4552 (parse_procedure): Likewise.
4553 (psymtab_to_symtab_1): Likewise.
4554
4555 (_initialize_mdebugread): Do not initialize mdebug_type_ variables.
4556 Initialize basic_type_data.
4557
289bd67a
UW
45582009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
4559
4560 * dfp.h (decimal_binop): Convert LEN_RESULT to input parameter.
4561 * dfp.c (promote_decimal): Remove.
4562 (decimal_binop): Convert LEN_RESULT to input parameter.
4563 Remove call to decimal_binop.
4564 (decimal_compare): Remove call to decimal_binop.
4565
4566 * valarith.c (value_binop): Pass desired result type length
4567 to decimal_binop.
4568
64c9be2e
TG
45692009-06-01 Tristan Gingold <gingold@adacore.com>
4570
4571 * configure.tgt (avr): Set gdb_sim to use the simulator.
4572
5a437975
DE
45732009-05-29 Doug Evans <dje@google.com>
4574
4575 * infrun.c (prepare_to_proceed): Document. Assert !non_stop.
4576 If scheduler-locking is enabled, we're not going to be singlestepping
4577 any other previously stopped thread.
4578
ab730e72
PA
45792009-05-29 Pedro Alves <pedro@codesourcery.com>
4580
4581 * mi/mi-interp.c (mi_on_resume): Initialize `count' to 0.
4582
3d22076f
EZ
45832009-05-29 Eli Zaretskii <eliz@gnu.org>
4584
4585 * i386-tdep.c (i386_go32_init_abi): Use SVR4 register numbering
4586 for stabs and COFF debug info.
4587
b3444185
PA
45882009-05-28 Pedro Alves <pedro@codesourcery.com>
4589
4590 * infrun.c (handle_inferior_event): When thread hoping, switch
4591 inferior_ptid to the event thread before removing breakpoints from
4592 the target. If not stopping, also try to revert back to a thread
4593 that was doing a "next". Check if that thread still exists before
4594 resuming.
4595 (currently_stepping_thread): Delete and merge with ...
4596 (currently_stepping): ... this.
4597 (currently_stepping_callback): Rename to ...
4598 (currently_stepping_or_nexting_callback): ... this, and also
4599 return true if the thread was stepping over a call (has a
4600 step-resume breakpoint).
4601
8f500870
TT
46022009-05-28 Tom Tromey <tromey@redhat.com>
4603
4604 * python/python.c (gdbpy_parameter): Rename. Fix error message.
4605 (GdbMethods): Change "get_parameter" to "parameter".
4606
6bf0ce2b
PP
46072009-05-28 Pierre Muller <muller@ics.u-strasbg.fr>
4608 Paul Pluzhnikov <ppluzhnikov@google.com>
4609
4610 * configure.ac (!have_libpython): Add python-prettyprint source
4611 and object files.
4612 * configure: Regenerate.
4613 * python/python-prettyprint.c: Move "#ifdef HAVE_PYTHON" before
4614 python headers.
4615
b6313243
TT
46162009-05-27 Vladimir Prus <vladimir@codesourcery.com>
4617 Tom Tromey <tromey@redhat.com>
4618 Thiago Jung Bauermann <bauerman@br.ibm.com>
4619
4620 * mi/mi-main.c (mi_cmd_list_features): List "python" feature.
4621 * varobj.h (varobj_set_visualizer): Declare.
4622 (varobj_get_display_hint): Likewise.
4623 (varobj_update_result_t) <children_changed, value_installed>: New
4624 fields.
4625 * mi/mi-cmds.c (mi_cmds): Add var-set-visualizer.
4626 * mi/mi-cmds.h (mi_cmd_var_set_visualizer,
4627 mi_cmd_var_set_child_range): Declare.
4628 * mi/mi-cmd-var.c (mi_cmd_var_set_visualizer): New function.
4629 (mi_cmd_var_list_children): Emit display hint.
4630 (varobj_update_one): Emit display hint. Handle dynamic children.
4631 * python/python.c (GdbMethods): Add "default_visualizer".
4632 * python/python-internal.h (apply_varobj_pretty_printer,
4633 gdbpy_get_varobj_pretty_printer, gdbpy_get_display_hint):
4634 Declare.
4635 (gdbpy_default_visualizer): Likewise.
4636 * varobj.c: Include python.h, python-internal.h.
4637 (PyObject): New typedef.
4638 (struct varobj) <children_requested, pretty_printer>: New fields.
4639 (varobj_create): Call install_default_visualizer.
4640 (instantiate_pretty_printer): New function.
4641 (varobj_set_display_format): Update.
4642 (varobj_get_display_hint): New function.
4643 (update_dynamic_varobj_children): New function.
4644 (varobj_get_num_children): Handle dynamic children.
4645 (varobj_list_children): Likewise.
4646 (install_new_value): Likewise.
4647 (varobj_add_child): New function.
4648 (install_visualizer): Likewise.
4649 (install_default_visualizer): Likewise.
4650 (varobj_set_visualizer): Likewise.
4651 (varobj_update): Handle dynamic children.
4652 (create_child): Use create_child_with_value.
4653 (create_child_with_value): New function.
4654 (value_get_print_value): Call pretty printer. Add value_formatter
4655 argument.
4656 (c_value_of_variable): Update.
4657 (varobj_invalidate): Always free all_rootvarobj.
4658 * python/python-prettyprint.c (apply_varobj_pretty_printer): New
4659 function.
4660 (gdbpy_get_varobj_pretty_printer): Likewise.
4661 (gdbpy_default_visualizer): Likewise.
4662
a6bac58e
TT
46632009-05-27 Tom Tromey <tromey@redhat.com>
4664 Thiago Jung Bauermann <bauerman@br.ibm.com>
4665 Phil Muldoon <pmuldoon@redhat.com>
4666 Paul Pluzhnikov <ppluzhnikov@google.com>
4667 Vladimir Prus <vladimir@codesourcery.com>
4668
4669 * python/python-value.c (value_object_to_value): New function.
4670 * python/python-internal.h: Include frameobject.h.
4671 (gdbpy_children_cst, gdbpy_to_string_cst, gdbpy_display_hint_cst):
4672 Declare.
4673 (value_object_to_value): Declare.
4674 * printcmd.c (struct format_data) <raw>: New field.
4675 (last_format): Default to 0.
4676 (decode_format): Initialize val.raw. Handle /r flag.
4677 (print_command_1): Initialize fmt.raw and opts.raw.
4678 (output_command): Likewise.
4679 (x_command): Fix initialization of fmt.format. Initialize
4680 fmt.raw.
4681 (display_command): Initialize fmt.raw.
4682 (do_one_display): Set opts.raw.
4683 * python/python.c (gdbpy_to_string_cst, gdbpy_children_cst,
4684 gdbpy_display_hint_cst): New globals.
4685 (_initialize_python): Initialize them. Set gdb.pretty_printers.
4686 * cp-valprint.c: Include python.h.
4687 (cp_print_value): Call apply_val_pretty_printer.
4688 * python/python.h (apply_val_pretty_printer): Declare.
4689 * stack.c (print_this_frame_argument_p): Remove.
4690 (print_frame_args): Compute summary flag. Don't use
4691 print_this_frame_argument_p.
4692 * valprint.c: Include python.h.
4693 (user_print_options): Initialize new fields.
4694 (scalar_type_p): New function.
4695 (val_print): Handle 'raw' and 'summary' modes. Call
4696 apply_val_pretty_printer.
4697 (value_print): Handle 'raw' mode.
4698 * valprint.h (struct value_print_options) <raw, summary>: New
4699 fields.
4700 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-prettyprint.o
4701 (SUBDIR_PYTHON_SRCS): Add python-prettyprint.c.
4702 (python-prettyprint.o): New target.
4703 * python/python-prettyprint.c: New file.
4704
42ae5230
TT
47052009-05-27 Tom Tromey <tromey@redhat.com>
4706 Paul Pluzhnikov <ppluzhnikov@google.com>
4707
4708 * mi/mi-main.c (mi_cmd_data_evaluate_expression): Use
4709 value_address.
4710 * cli/cli-dump.c (dump_value_to_file): Use value_address.
4711 * valprint.c (common_val_print): Likewise.
4712 * v850-tdep.c (v850_push_dummy_call): Use value_address.
4713 * tracepoint.c (encode_actions): Use value_address.
4714 * printcmd.c (print_formatted): Use value_address.
4715 (x_command): Likewise.
4716 * p-valprint.c (pascal_object_print_static_field): Use
4717 value_address.
4718 * mn10300-tdep.c (mn10300_push_dummy_call): Use value_address.
4719 * mips-tdep.c (mips_eabi_push_dummy_call): Use value_address.
4720 * m32r-tdep.c (m32r_push_dummy_call): Use value_address.
4721 * jv-valprint.c (java_value_print): Use value_address.
4722 * infcall.c (find_function_addr): Use value_address.
4723 * gnu-v3-abi.c (gnuv3_rtti_type): Use value_address.
4724 * gnu-v2-abi.c (gnuv2_value_rtti_type): Use value_address.
4725 * frv-tdep.c (frv_push_dummy_call): Use value_address.
4726 * frame.c (frame_register_unwind): Use value_address.
4727 (frame_unwind_register_value): Likewise.
4728 * darwin-nat-info.c (info_mach_region_command): Use
4729 value_address.
4730 * cp-valprint.c (cp_print_static_field): Use value_address.
4731 * c-valprint.c (c_value_print): Use value_address.
4732 * breakpoint.c (update_watchpoint): Use value_address.
4733 (can_use_hardware_watchpoint): Likewise.
4734 * ada-valprint.c (ada_val_print_1): Use value_address.
4735 (ada_value_print): Likewise.
4736 * ada-tasks.c (read_fat_string_value): Use value_address.
4737 * jv-lang.c (java_link_class_type): Use set_value_address.
4738 (java_link_class_type): Likewise.
4739 (get_java_utf8_name): Use value_address.
4740 (type_from_class): Likewise.
4741 (java_link_class_type): Likewise.
4742 * findvar.c (value_of_register): Use set_value_address.
4743 (read_var_value): Likewise.
4744 (read_var_value): Likewise.
4745 * eval.c (evaluate_subexp_standard): Use set_value_address.
4746 (evaluate_subexp_standard): Use value_address.
4747 * dwarf2loc.c (dwarf2_evaluate_loc_desc): Use set_value_address.
4748 * ada-lang.c (coerce_unspec_val_to_type): Use set_value_address.
4749 (ada_value_primitive_packed_val): Likewise.
4750 (ensure_lval): Likewise.
4751 (thin_data_pntr): Use value_address.
4752 (desc_bounds): Likewise.
4753 (ada_value_primitive_packed_val): Likewise.
4754 (value_assign_to_component): Likewise.
4755 (ensure_lval): Likewise.
4756 (make_array_descriptor): Likewise.
4757 (ada_to_fixed_value): Likewise.
4758 (unwrap_value): Likewise.
4759 * value.c (deprecated_value_address_hack): Remove.
4760 (value_address): New function.
4761 (value_raw_address): Likewise.
4762 (set_value_address): Likewise.
4763 (value_fn_field): Use set_value_address.
4764 (value_from_contents_and_address): Likewise.
4765 (value_fn_field): Likewise.
4766 (allocate_value_lazy): Don't use VALUE_ADDRESS.
4767 (value_as_address): Use value_address.
4768 (value_static_field): Likewise.
4769 * valops.c (search_struct_field): Use set_value_address.
4770 (value_at): Likewise.
4771 (value_at_lazy): Likewise.
4772 (value_repeat): Likewise.
4773 (value_cast_structs): Use value_address.
4774 (value_cast): Likewise.
4775 (value_fetch_lazy): Likewise.
4776 (value_assign): Likewise.
4777 (value_repeat): Likewise.
4778 (address_of_variable): Likewise.
4779 (value_coerce_array): Likewise.
4780 (value_coerce_function): Likewise.
4781 (value_addr): Likewise.
4782 (search_struct_field): Likewise.
4783 (search_struct_method): Likewise.
4784 (find_method_list): Likewise.
4785 (value_struct_elt_for_reference): Likewise.
4786 (value_full_object): Likewise.
4787 * jv-valprint.c (java_value_print): Use set_value_address.
4788 * value.h (deprecated_value_address_hack): Remove.
4789 (VALUE_ADDRESS): Remove.
4790 (value_address): Declare.
4791 (value_raw_address): Declare.
4792 (set_value_address): Declare.
4793
2c74e833
TT
47942009-05-27 Tom Tromey <tromey@redhat.com>
4795 Thiago Jung Bauermann <bauerman@br.ibm.com>
4796 Phil Muldoon <pmuldoon@redhat.com>
4797 Paul Pluzhnikov <ppluzhnikov@google.com>
4798
4799 * python/python.c (_initialize_python): Call
4800 gdbpy_initialize_types.
4801 (GdbMethods): Add "lookup_type".
4802 * python/python-value.c (value_object) <type>: New field.
4803 (valpy_dealloc): Decref type.
4804 (valpy_new): Initialize type.
4805 (valpy_get_type): New function.
4806 (value_to_value_object): Initialize type.
4807 (valpy_cast): New function.
4808 (value_object_getset): Add "type".
4809 (value_object_methods): Add "cast".
4810 * python/python-internal.h (type_to_type_object): Declare.
4811 (type_object_to_type): Likewise.
4812 (gdbpy_initialize_types): Likewise.
4813 (gdbpy_lookup_type): Declare.
4814 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-type.o.
4815 (SUBDIR_PYTHON_SRCS): Add python-type.c.
4816 (python-type.o): New target.
4817 * python/python-type.c: New file.
4818
89c73ade
TT
48192009-05-27 Tom Tromey <tromey@redhat.com>
4820 Thiago Jung Bauermann <bauerman@br.ibm.com>
4821 Phil Muldoon <pmuldoon@redhat.com>
4822
4823 * python/python.c: Include objfiles.h, observer.h.
4824 (gdbpy_auto_load): New global.
4825 (gdbpy_current_objfile): Likewise.
4826 (GDBPY_AUTO_FILENAME): New define.
4827 (gdbpy_new_objfile): New function.
4828 (gdbpy_get_current_objfile): Likewise.
4829 (gdbpy_objfiles): Likewise.
4830 (_initialize_python): Add "maint set auto-load". Call
4831 gdbpy_initialize_objfile. Attach objfile observer.
4832 (GdbMethods): New methods current_objfile, objfiles.
4833 * python/python-objfile.c: New file.
4834 * python/python-internal.h (objfile_to_objfile_object): Declare.
4835 (objfpy_get_printers): Likewise.
4836 (gdbpy_initialize_objfile): Likewise.
4837 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-objfile.o.
4838 (SUBDIR_PYTHON_SRCS): Add python-objfile.c.
4839 (python-objfile.o): New target.
4840
a75724bc
PA
48412009-05-27 Pedro Alves <pedro@codesourcery.com>
4842
4843 * infrun.c (follow_exec): Clear the stop_requested flag.
4844 * linux-nat.c (linux_handle_extended_wait) <PTRACE_EVENT_EXEC>:
4845 Add debug output.
4846
97c44116
AR
48472009-05-27 Aleksandar Ristovski <aristovski@qnx.com>
4848
4849 * nto-procfs.c (get_regset): Pass correct pointer.
4850
f504f079
DE
48512009-05-26 Doug Evans <dje@google.com>
4852
4853 * dwarf2read.c (follow_die_ref): Add comment.
4854 (dwarf2_mark_helper): Tweak comment.
4855 (dwarf2_mark): Move description to its proper place.
4856
4fcbb494
PM
48572009-05-25 Pierre Muller <muller@ics.u-strasbg.fr>
4858
4859 * procfs.c (procfs_wait): Add options parameter.
4860
4e3990f4
DE
48612009-05-24 Doug Evans <dje@google.com>
4862
e09875d4
DE
4863 Global renaming of find_thread_pid to find_thread_ptid.
4864 * gdbthread.h (find_thread_ptid): Renamed from find_thread_pid.
4865 * thread.c (find_thread_ptid): Renamed from find_thread_pid.
4866 All callers updated.
4867
4e3990f4
DE
4868 * infrun.c (follow_fork): Initialize new step_* locals
4869 to avoid "may be used uninitialized" warnings.
4870
98b54c18
PA
48712009-05-24 Pedro Alves <pedro@codesourcery.com>
4872
4873 * inflow.c (copy_terminal_info): Deep copy `run_terminal'.
4874
e58b0e63
PA
48752009-05-24 Pedro Alves <pedro@codesourcery.com>
4876
4877 * gdbthread.h (struct thread_info): New `pending_follow' field.
4878 * thread.c (new_thread): New function.
4879 (add_thread_silent): Use it.
4880 * breakpoint.c (internal_breakpoint_number): New global, moved
4881 from inside...
4882 (create_internal_breakpoint): ... this.
4883 (clone_momentary_breakpoint): New.
4884 * breakpoint.h (clone_momentary_breakpoint): Declare.
4885 * infrun.c (nullify_last_target_wait_ptid): Move declaration
4886 higher.
4887 (pending_follow): Delete.
4888 (follow_fork): Handle pending follow fork event here. Moved the
4889 preserving of thread stepping state here.
4890 (resume): Don't handle pending follow fork events here. Only
4891 install the inferior's terminal modes if we're about to resume it.
4892 (proceed): Handle possible pending follow fork events here.
4893 (init_wait_for_inferior): No need to clear pending_follow anymore,
4894 it's gone.
4895 (handle_inferior_event): Adjust to per-thread `pending_follow'.
4896 Call `follow_fork' to handle following the fork. If the
4897 follow-fork is cancelled, stop stepping.
4898 * linux-nat.c (linux_child_follow_fork): Adjust to per-thread
4899 `pending_follow' events. Remove code that handled preserving the
4900 thread stepping state.
4901 * inf-ptrace.c (inf_ptrace_follow_fork): Ditto.
4902 * inf-ttrace.c (inf_ttrace_follow_fork): Ditto.
4903
ea26755d 49042009-05-24 Pierre Muller <muller@ics.u-strasbg.fr>
70992597
PM
4905
4906 * symfile.c (add_shared_symbol_files_command): Remove
4907 prototype and function.
4908 (_initialize _symfile): Move "add-shared-symbol-files"
4909 command and "assf" alias.
4910 * windows-nat.c (_initialize_windows_nat): to here.
4911 Change "add-shared-symbol-files" to alias.
4912
4913 * config/i386/cygwin.mh: Remove NAT_FILE.
4914 * config/i386/mingw.mh: Remove NAT_FILE.
4915 * config/i386/mingw64.mh: Remove NAT_FILE.
4916 * config/i386/nm-cygwin.h: Remove file.
4917 * config/i386/nm-cygwin64.h: Remove file.
4918
5e31abdf
HZ
49192009-05-24 Hui Zhu <teawater@gmail.com>
4920
4921 * i386-linux-tdep.c (I386_LINUX_RECORD_SIZE_*,
4922 I386_LINUX_RECORD_IOCTL_*,
4923 I386_LINUX_RECORD_FCNTL_*) Removed.
4924 (i386_linux_init_abi): Change size of record from macros to
4925 numbers.
4926
49272009-05-24 Hui Zhu <teawater@gmail.com>
4928
4929 * i386-linux-tdep.c (i386_linux_init_abi): Remove size_char.
4930 * linux-record.c (record_linux_system_call): Ditto.
4931 * linux-record.h (linux_record_tdep): Ditto.
4932
1b36a34b
JK
49332009-05-23 Jan Kratochvil <jan.kratochvil@redhat.com>
4934
4935 Replace the savestring calls by xstrdup calls where possible.
4936 * breakpoint.c (condition_command, set_raw_breakpoint)
4937 (create_catchpoint, update_breakpoint_locations): Replace the
4938 savestring calls by xstrdup calls where possible.
4939 * buildsym.c (start_subfile, patch_subfile_names, record_debugformat)
4940 (record_producer): Likewise.
4941 * coffread.c (coff_start_symtab, complete_symtab): Likewise.
4942 * corefile.c (set_gnutarget): Likewise.
4943 * dbxread.c (add_new_header_file): Likewise.
4944 * demangle.c (set_demangling_command, set_demangling_style): Likewise.
4945 * event-top.c (push_prompt, pop_prompt, command_line_handler)
4946 (set_async_prompt): Likewise.
4947 * infcmd.c (set_inferior_io_terminal, attach_command_post_wait):
4948 Likewise.
4949 * language.c (set_language_command, _initialize_language): Likewise.
4950 * linespec.c (decode_line_2): Likewise.
4951 * rs6000-nat.c (add_vmap): Likewise.
4952 * top.c (set_prompt, init_history, init_main): Likewise.
4953 * tracepoint.c (stringify_collection_list): Likewise.
4954 * varobj.c (varobj_create): Remove variable expr_len. Replace the
4955 savestring calls by xstrdup calls where possible.
4956 (value_of_root, c_name_of_variable, c_describe_child): Replace the
4957 savestring calls by xstrdup calls where possible.
4958 * xcoffread.c (complete_symtab): Likewise.
4959 * cli/cli-script.c (build_command_line, define_command): Likewise.
4960 * cli/cli-setshow.c (do_setshow_command): Likewise.
4961
61d8f275
JK
49622009-05-23 Jan Kratochvil <jan.kratochvil@redhat.com>
4963
4964 Remove already unreachable code.
4965 * varobj.c (varobj_get_handle): Fix comment when error is called.
4966 All callers updated.
4967
969107c5
EZ
49682009-05-23 Eli Zaretskii <eliz@gnu.org>
4969
70926f63
EZ
4970 * README (`configure' options): Document GDB-specific options to
4971 `configure'.
4972
8c7a1ee8
EZ
4973 * symtab.c (skip_prologue_using_lineinfo): New function.
4974 (find_function_start_sal): Use it to get to the first line of
4975 function's body that has an entry in the lineinfo table.
4976
969107c5
EZ
4977 * symmisc.c (dump_symtab): Switch the current language to
4978 the language of the symtab we are dumping only if the symtab's
4979 language is neither language_auto nor language_unknown.
4980
4981 * coffread.c (coff_symtab_read): Set language_minimal as the
4982 language for the "_globals_" pseudo-file.
754dd031
EZ
4983 (process_coff_symbol): Set the symbol's language to the language
4984 of current_subfile.
969107c5 4985
0542c86d
PA
49862009-05-22 Pedro Alves <pedro@codesourcery.com>
4987
4988 * target.h (struct section_table): Rename to ...
4989 (struct target_section): ... this.
4990 * exec.c: Adjust all references.
4991 * exec.h: Adjust all references.
4992 * nto-tdep.c: Adjust all references.
4993 * nto-tdep.h: Adjust all references.
4994 * ppc-linux-tdep.c: Adjust all references.
4995 * rs6000-nat.c: Adjust all references.
4996 * s390-tdep.c: Adjust all references.
4997 * solib-darwin.c: Adjust all references.
4998 * solib-frv.c: Adjust all references.
4999 * solib-irix.c: Adjust all references.
5000 * solib-null.c: Adjust all references.
5001 * solib-osf.c: Adjust all references.
5002 * solib-pa64.c: Adjust all references.
5003 * solib-som.c: Adjust all references.
5004 * solib-sunos.c: Adjust all references.
5005 * solib-svr4.c: Adjust all references.
5006 * solib-target.c: Adjust all references.
5007 * solib.c: Adjust all references.
5008 * solist.h: Adjust all references.
5009 * symfile.c: Adjust all references.
5010 * symfile.h: Adjust all references.
5011 * target.c: Adjust all references.
5012
b34fab9a
HZ
50132009-05-22 Hui Zhu <teawater@gmail.com>
5014
5015 Add sys_fcntl argument interfaces to linux_record_tdep.
5016
5017 * linux-record.h (linux_record_tdep): Add fcntl_F_GETLK,
5018 fcntl_F_GETLK64, fcntl_F_SETLK64 and fcntl_F_SETLKW64 to be
5019 interfaces.
5020 * i386-linux-tdep.c (I386_LINUX_RECORD_FCNTL_F_GETLK,
5021 I386_LINUX_RECORD_FCNTL_F_GETLK64,
5022 I386_LINUX_RECORD_FCNTL_F_SETLK64,
5023 I386_LINUX_RECORD_FCNTL_F_SETLKW64): New macros. The values
5024 of I386 Linux sys_fcntl arguments.
5025 (i386_linux_init_abi): Set macros values to linux_record_tdep.
5026 * linux-record.c (record_linux_system_call): Change to use
5027 the interface in linux_record_tdep in sys_fcntl and
5028 sys_fcntl64.
5029
5030 * linux-record.c (record_linux_system_call): Fix the process
5031 record build error about type in CYGWIN.
5032
88c0ab9d
PA
50332009-05-22 Pedro Alves <pedro@codesourcery.com>
5034
5035 * inflow.c (kill_command): Delete left over static declaration.
5036
348f8c02
PA
50372009-05-22 Pedro Alves <pedro@codesourcery.com>
5038
5039 * bfd-target.c: Don't include gdb_assert.h or gdb_string.h.
5040 Include exec.h.
5041 (struct section_closure): Delete.
5042 (add_to_section_table): Delete.
5043 (build_target_sections_from_bfd): Delete.
5044 (target_bfd_xfer_partial): Use section_table_xfer_memory_partial.
5045 (target_bfd_reopen): Use build_section_table.
5046 * exec.c (xfer_memory): Move most code except for overlay
5047 debugging support from here...
5048 (section_table_xfer_memory): ... to this new function.
5049 (section_table_xfer_memory_partial): New.
5050 * exec.h (section_table_xfer_memory_partial): Declare.
5051 * bfd-target.h (build_target_sections_from_bfd): Delete
5052 declaration.
5053
41575630
PA
50542009-05-22 Pedro Alves <pedro@codesourcery.com>
5055
5056 * remote.c (compare_sections_command): Don't declare exec_bfd.
5057 * tracepoint.c: Include "gdbcore.h".
5058 (remote_set_transparent_ranges): Don't declare exec_bfd.
5059
783425fc
PA
50602009-05-21 Pedro Alves <pedro@codesourcery.com>
5061
5062 * aix-thread.c (init_aix_thread_ops): Whitespace.
5063
61439e34
PA
50642009-05-21 Pedro Alves <pedro@codesourcery.com>
5065
5066 * dec-thread.c (dec_thread_wait): Add options parameter. Use it
5067 to call the to_wait method in the target beneath.
5068 * remote-m32r-sdi.c (m32r_wait): Add options parameter.
5069
8914d83b
JB
50702009-05-21 Joel Brobecker <brobecker@adacore.com>
5071
5072 * aix-thread.c (aix_thread_wait): Add options parameter. Use it
5073 to call the to_wait method in the target_beneath.
5074
d9d2d8b6
PA
50752009-05-21 Pedro Alves <pedro@codesourcery.com>
5076
5077 * linux-nat.c (linux_nat_terminal_inferior)
5078 (linux_nat_terminal_ours): Don't check sync_execution.
5079 * remote.c (remote_terminal_inferior, remote_terminal_ours):
5080 Don't check sync_execution. Update comments.
5081 * target.c (target_terminal_inferior): New.
5082 * target.h (target_terminal_inferior): Delete macro, and declare
5083 as function.
5084 * event-top.c (async_disable_stdin): Make idempotent. Don't give
5085 the target the terminal here.
5086 * inflow.c (terminal_ours_1): Don't return early without setting
5087 `terminal_is_ours'.
5088
47608cb1
PA
50892009-05-21 Pedro Alves <pedro@codesourcery.com>
5090
5091 * target.h (TARGET_WNOHANG): New.
5092 * target.c (target_wait): Add `options' argument. Adjust.
5093 (struct target_ops) <to_wait>: Add `options' argument.
5094 (target_wait): Add `options' argument.
5095 * infrun.c (wait_for_inferior): Pass 0 as options to
5096 target_wait (blocking wait).
5097 (fetch_inferior_event): Pass TARGET_WNOHANG as options to
5098 target_wait.
5099 * fork-child.c (startup_inferior): Pass 0 as options to
5100 target_wait (blocking wait).
5101 * linux-nat.c (linux_nat_create_inferior): Remove async masking.
5102 (linux_nat_wait_1): Add `target_options' argument. Use it instead
5103 of checking on target_can_async_p.
5104 (linux_nat_wait): Add `target_options' argument. Adjust.
5105 * remote.c (remote_wait_ns): Add `options' argument. Adjust to
5106 check on TARGET_WNOWAIT instead of checking on remote_is_async_p.
5107 (remote_wait_as): Add `options' argument. Adjust to check on
5108 TARGET_WNOWAIT instead of checking on remote_is_async_p. If doing
5109 a blocking wait, keep waiting until an interesting event comes
5110 out.
5111 (remote_wait): Add `options' argument. Don't loop here if the
5112 target is in async mode, and a blocking wait has been requested.
5113
5114 * top.c (deprecated_target_wait_hook): Add `options' argument.
5115 * linux-thread-db.c (thread_db_wait): Add `options' argument, and
5116 pass it down to the layer beneath.
5117 * inf-ptrace.c (inf_ptrace_wait): Add `options' argument.
5118 * record.c (record_beneath_to_wait): Add `options' argument.
5119 (record_wait): Add `options' argument, and pass it down to the
5120 layer beneath.
5121 * bsd-uthread.c (bsd_uthread_wait): Add `options' argument.
5122 * darwin-nat.c (darwin_wait): Likewise.
5123 * defs.h (deprecated_target_wait_hook): Likewise.
5124 * gnu-nat.c (gnu_wait): Add `options' argument.
5125 * go32-nat.c (go32_wait): Likewise.
5126 * hpux-thread.c (hpux_thread_wait): Add `options' argument, and
5127 pass it down to the layer beneath.
5128 * inf-ttrace.c (inf_ttrace_wait): Add `options' argument.
5129 * monitor.c (monitor_wait): Likewise.
5130 * nto-procfs.c (procfs_wait): Likewise.
5131 * remote-mips.c (mips_wait): Add `options' argument.
5132 * remote-sim.c (gdbsim_wait): Likewise.
5133 * rs6000-nat.c (rs6000_wait): Add `options' argument.
5134 * sol-thread.c (sol_thread_wait): Add `options' argument, and pass
5135 it down to the layer beneath.
5136 * spu-linux-nat.c (spu_child_wait): Add `options' argument.
5137 * windows-nat.c (windows_wait): Likewise.
5138 * tui/tui-hooks.c (tui_target_wait_hook): Likewise. Adjust.
5139
9944e9c2
PA
51402009-05-21 Pedro Alves <pedro@codesourcery.com>
5141
5142 * mi/mi-interp.c (mi_on_resume): Account for whole process
5143 resumes.
5144
c244a140
JK
51452009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
5146
5147 * m2-exp.y (MAX_FUNC): Fix trailing UNOP_MAX.
5148
76bee0cc
JK
51492009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
5150
5151 * dwarf2read.c (set_cu_language): Recognize also DW_LANG_C99.
5152
4ac36638
JK
51532009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
5154
5155 Fix parsing DW_AT_const_value using DW_FORM_string.
5156 * dwarf2read.c (dwarf2_const_value <DW_FORM_string>): New.
5157
77f0be4e
JB
51582009-05-20 Joel Brobecker <brobecker@adacore.com>
5159
5160 * aix-thread.c (giter_count): Do not count the main thread.
5161 (giter_accum): Do not include the main thread.
5162
fbdebf46
JK
51632009-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
5164
5165 Remove the PROT parameter from openp.
5166 * source.c (openp): Remove the parameter PROT. Assertion check MODE.
5167 defs.h (openp): Update the prototype.
5168 Update all the openp callers.
5169
5fd62852
PA
51702009-05-19 Pedro Alves <pedro@codesourcery.com>
5171
5172 * inflow.c (kill_command): Moved to infcmd.c.
5173 (_initialize_inflow): Don't add the "kill" command or clear
5174 inferior_ptid here.
5175 * infcmd.c (kill_command): Moved here from inflow.c.
5176 (_initialize_infcmd): Add the "kill" command here.
5177
191c4426
PA
51782009-05-19 Pedro Alves <pedro@codesourcery.com>
5179
5180 * fork-child.c: Don't include frame.h. Include terminal.h.
5181 (fork_inferior): Call new_tty_postfork after forking adn adding
5182 the child to the inferior list.
5183 * inferior.h (new_tty_prefork, gdb_has_a_terminal): Don't declare
5184 here.
5185 * inflow.c (struct terminal_info): Remove const qualifier from
5186 `run_terminal' field.
5187 (inferior_thisrun_terminal): Tweak comment.
5188 (inflow_inferior_exit): Release the `run_terminal' field.
5189 (copy_terminal_info): New function.
5190 (new_tty_postfork): New function.
5191 * terminal.h (new_tty_prefork, new_tty, new_tty_postfork,
5192 (copy_terminal_info, gdb_has_a_terminal, gdb_setpgid): Declare.
5193 * inf-ptrace.c: Include terminal.h.
5194 (inf_ptrace_follow_fork): Copy the parent's terminal info to the
5195 child.
5196 * linux-nat.c: Include terminal.h.
5197 (linux_child_follow_fork): Copy the parent's terminal info to the
5198 child.
5199 * inf-ttrace.c: Include terminal.h.
5200 (inf_ttrace_follow_fork): Copy the parent's terminal info to the
5201 child.
5202
2ea7b647
PA
52032009-05-19 Pedro Alves <pedro@codesourcery.com>
5204
5205 * breakpoint.c (insert_breakpoints, breakpoint_init_inferior)
5206 (update_global_location_list): Use gdbarch_has_global_breakpoints
5207 instead of gdbarch_has_global_solist and
5208 target_supports_multi_process.
5209 * dicos-tdep.c (dicos_init_abi): Set
5210 gdbarch_has_global_breakpoints.
5211 * gdbarch.sh (has_global_solist): Update comment.
5212 (has_global_breakpoints): New.
5213 * remote.c (remote_start_remote): Use
5214 gdbarch_has_global_breakpoints instead of
5215 gdbarch_has_global_solist.
5216 * target.c (target_detach): Use gdbarch_has_global_breakpoints
5217 instead of gdbarch_has_global_solist.
5218 * infcmd.c (attach_command): Use gdbarch_has_global_solist instead
5219 of target_supports_multi_process.
5220
6342b74a
PP
52212009-05-18 Paul Pluzhnikov <ppluzhnikov@google.com>
5222
5223 * objc-lang.c (find_methods): Plug a small memory leak.
5224
1a816a87
PA
52252009-05-18 Pedro Alves <pedro@codesourcery.com>
5226
5227 * solib-svr4.c: Include observer.h.
5228 (debug_base, debug_loader_offset_p, debug_loader_offset)
5229 (debug_loader_name, main_lm_addr): Move these globals...
5230 (struct svr4_info): ... into this new structure.
5231 (svr4_info_p): New typedef.
5232 (svr4_info): New global.
5233 (get_svr4_info, remove_svr4_info, solib_svr4_inferior_exit): New
5234 functions.
5235 (locate_base, solib_svr4_r_map, solib_svr4_r_brk)
5236 (solib_svr4_r_ldsomap): Add svr4_info argument. Adjust to
5237 per-inferior svr4.
5238 (open_symbol_file_object): Adjust to per-inferior svr4.
5239 (svr4_default_sos, svr4_current_sos, svr4_fetch_objfile_link_map):
5240 Ditto.
5241 (enable_break): Add svr4_info argument. Adjust to per-inferior
5242 svr4.
5243 (enable_break, svr4_solib_create_inferior_hook, svr4_clear_solib):
5244 Adjust to per-inferior svr4.
5245 (_initialize_svr4_solib): Install the solib_svr4_inferior_exit
5246 observer.
5247
4d062f1a
PA
52482009-05-18 Pedro Alves <pedro@codesourcery.com>
5249
5250 * linux-nat.h (linux_proc_get_tgid): Declare.
5251 * linux-nat.c (linux_proc_get_tgid): New.
5252 * linux-thread-db.c (struct thread_db_info): New field
5253 `need_stale_parent_threads_check'.
5254 (add_thread_db_info): Set it.
5255 (find_new_threads_callback): Ignore stale fork parent threads.
5256 (thread_db_resume): New.
5257 (init_thread_db_ops): Install thread_db_resume.
5258
d90e17a7
PA
52592009-05-18 Pedro Alves <pedro@codesourcery.com>
5260
5261 * fork-child.c (fork_inferior): Only reset the thread list if this
5262 is the first inferior.
5263 (startup_inferior): If the target support multi-process, tell it
5264 to resume only the new process.
5265 * linux-nat.c (num_lwps): Delete global.
5266 (purge_lwp_list): New function.
5267 (num_lwps): New function.
5268 (add_lwp, delete_lwp): Adjust.
5269 (ptid_match): New.
5270 (iterate_over_lwps): Add filter argument. Handle it.
5271 (linux_nat_attach): Remove FIXME note.
5272 (linux_nat_detach): Adjust to iterate over threads of the inferior
5273 we're detaching from. Adjust to num_lwps being a function. Don't
5274 assume the head of the lwp list is the main thread of the process
5275 we're detaching from. Don't destroy the LWP list.
5276 (resume_callback): Add debug output.
5277 (linux_nat_resume): Handle resuming a single inferior. Allow a
5278 wildcard resume in non-stop mode.
5279 (linux_handle_extended_wait): Don't assume inferior_ptid is the
5280 correct inferior of the parent LWP.
5281 (status_callback): Also check lp->waitstatus.
5282 (select_event_lwp): Add new filter parameter. Handle it.
5283 (linux_nat_filter_event): Adjust to num_lwps being a function.
5284 (linux_nat_wait_1): When adding the first lwp of the inferior, use
5285 an is_lwp check instead of checking for the number of lwps.
5286 (linux_nat_wait_1): Handle waiting for a specific tgid. Handle
5287 pending process exit statuses.
5288 (linux_nat_mourn_inferior): Don't destroy all the LWP info.
5289 Instead delete LWPs of the inferior that we're mourning. Don't
5290 unregister from the event loop here.
5291 (linux_nat_pid_to_str): Use `num_lwps'.
5292 (linux_nat_make_corefile_notes): Adjust to walk over lwps of a
5293 single inferior.
5294 (linux_nat_is_async_p): Check if async was masked out.
5295 (linux_multi_process): New global.
5296 (linux_nat_supports_multi_process): New.
5297 (linux_nat_stop_lwp): Remove LWP filtering. It is done by the
5298 caller.
5299 (linux_nat_stop): Adjust to make iterate_over_lwps itself do the
5300 LWP filtering.
5301 (linux_nat_close): New.
5302 (linux_nat_add_target): Register linux_nat_close and
5303 linux_nat_supports_multi_process.
5304 * linux-nat.h (iterate_over_lwps): Add filter argument.
5305 * linux-thread-db.c (thread_db_handle): Delete.
5306 (proc_handle, thread_agent, td_init_p, td_ta_new_p)
5307 (td_ta_map_id2thr_p, td_ta_map_lwp2thr_p, td_ta_thr_iter_p)
5308 (td_ta_event_addr_p, td_ta_set_event_p, td_ta_event_getmsg_p)
5309 (td_thr_validate_p, td_thr_get_info_p, td_thr_event_enable_p)
5310 (td_thr_tls_get_addr_p, td_create_bp_addr, td_death_bp_addr): No
5311 longer globals, moved to...
5312 (struct thread_db_info): ... this new structure.
5313 (thread_db_list): New.
5314 (add_thread_db_info, get_thread_db_info, delete_thread_db_info):
5315 New.
5316 (have_threads_callback): Filter out threads of all inferiors but
5317 the one specified by the ARGS argument.
5318 (have_threads): Add ptid argument specifying the inferior we're
5319 interested in. Handle it.
5320 (struct thread_get_info_inout): New.
5321 (thread_get_info_callback, thread_from_lwp): Adjust to use it.
5322 (thread_db_attach_lwp): Check that inferior of the passed in
5323 thread is using thread-db. Adjust.
5324 (enable_thread_event): Remove thread_agent parameter. Instead,
5325 get it from the per-inferior thread-db info.
5326 (dladdr_to_soname): Move higher up.
5327 (enable_thread_event_reporting): Adjust to use per-inferior
5328 thread-db info.
5329 (try_thread_db_load_1): Replace `handle' parameter by a
5330 thread_db_info parameter. Adjust to use per-inferior thread-db
5331 info.
5332 (try_thread_db_load): Adjust to use per-inferior thread-db info.
5333 (thread_db_load, disable_thread_event_reporting): Ditto.
5334 (check_for_thread_db): Remove conditional reporting of which
5335 libthread_db is in use.
5336 (thread_db_new_objfile): Add comment about inferior_ptid.
5337 (attach_thread): Adjust to use per-inferior thread-db info.
5338 (thread_db_detach): Adjust to use per-inferior thread-db info.
5339 Remove thread event breakpoints of the current inferior. Only
5340 unpush the thread-db target if there are no more processes using
5341 it.
5342 (check_event): Adjust to use per-inferior thread-db info.
5343 (thread_db_wait): Adjust to use per-inferior thread-db info. Only
5344 unpush the thread-db target if there are no more processes using
5345 it.
5346 (thread_db_mourn_inferior): Adjust to use per-inferior thread-db
5347 info. Mark breakpoints of the current inferior out before
5348 deleting them. Only unpush the thread-db target if there are no
5349 more processes using it.
5350 (find_new_threads_callback): Adjust to use per-inferior thread_db
5351 info.
5352 (thread_db_find_new_threads_1): Add new ptid argument. Adjust to
5353 use per-inferior thread-db info.
5354 (thread_db_find_new_threads): Adjust to use per-inferior thread-db
5355 info.
5356 (thread_db_get_thread_local_address): Adjust.
5357 (thread_db_get_ada_task_ptid): Adjust.
5358 * inf-ptrace.c (inf_ptrace_mourn_inferior): Only unpush the target
5359 if there no more processes left to debug.
5360 * thread.c (set_running, set_executing): Handle resuming all
5361 threads of a single inferior.
5362 * mi/mi-interp.c (mi_output_running_pid): New.
5363 (mi_inferior_count): New.
5364 (mi_on_resume): For backwards compatibility, if resuming all
5365 threads of an inferior, and there is only one inferior, output
5366 "all".
5367
dddfab26
UW
53682009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5369
5370 * ada-lang.c (ada_find_any_type): Move check for primitive types ...
5371 (to_fixed_range_type): ... to here.
5372
556bdfd4
UW
53732009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5374
5375 * ada-lang.c (desc_data_type): Remove, replace by ...
5376 (desc_data_target_type): ... this.
5377 (thin_data_pntr): Use desc_data_target_type instead of desc_data_type.
5378 (ada_is_array_descriptor_type): Likewise.
5379 (ada_type_of_array): Likewise.
5380 (ada_coerce_to_simple_array_type): Likewise.
5381 (ada_array_element_type): Likewise.
5382
aaa88a99
UW
53832009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5384
5385 * ada-valprint.c (ada_val_print_1): Use val_print_string to print
5386 result of ada_vax_float_print_function inferior call.
5387
17280b9f
UW
53882009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5389
5390 * ada-lang.c (ada_coerce_to_simple_array_type): Reimplement to
5391 avoid creating a dummy value.
5392
830bb937
UW
53932009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5394
5395 * p-valprint.c (pascal_val_print): Use extract_typed_address
5396 to extract reference value.
5397
e035e373
UW
53982009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
5399
5400 * doublest.c (NAN): Remove unused define.
5401 (extract_floating_by_length, deprecated_extract_floating): Remove.
5402 (store_floating_by_length, deprecated_store_floating): Remove.
5403 (extract_typed_floating): Do not call extract_floating_by_length.
5404 (store_typed_floating): Do not call store_floating_by_length.
5405 (convert_typed_floating): Remove redundant assertions.
5406 * doublest.h (deprecated_extract_floating): Remove.
5407 (deprecated_store_floating): Remove.
5408 * sh64-tdep.c (sh64_register_convert_to_raw): Call
5409 extract_typed_floating instead of deprecated_extract_floating.
5410
c28c63d8
JB
54112009-05-18 Jon Beniston <jon@beniston.com>
5412
5413 * MAINTAINERS: Add lm32 target.
5414 * Makefile.in: Add lm32 dependencies.
5415 * NEWS: Indicate lm32 is a new target.
5416 * configure.tgt: Add lm32 targets.
5417 * lm32-tdep.c: New file.
5418
739fc47a
PA
54192009-05-18 Pedro Alves <pedro@codesourcery.com>
5420
5421 * corelow.c (core_open): Flush the register cache before doing
5422 anything with registers.
5423
7e1789f5
PA
54242009-05-18 Pedro Alves <pedro@codesourcery.com>
5425
5426 * inflow.h (our_process_group): Remove declaration.
5427 (inferior_process_group): Delete global variable declaration.
5428 (inferior_process_group): New function declaration.
5429 * inflow.c: Include observer.h.
5430 (inferior_ttystate, our_ttystate, tflags_inferior, tflags_ours):
5431 Delete.
5432 (struct terminal_info): New struct.
5433 (our_terminal_info): New global.
5434 (inferior_process_group): New function.
5435 (inferior_thisrun_terminal): Extend description comment.
5436 (gdb_has_a_terminal): Adjust to write to our_terminal_info fields
5437 instead of globals.
5438 (terminal_init_inferior_with_pgrp): Adjust to per-inferior
5439 terminal settings.
5440 (terminal_inferior): Ditto.
5441 (terminal_ours_1): Ditto.
5442 (inflow_new_inferior, inflow_inferior_exit): New functions.
5443 (child_terminal_info): Adjust to per-inferior terminal settings.
5444 (osig_set): New global.
5445 (set_sigint_trap): Adjust to per-inferior terminal settings. Set
5446 or clear `osig_set' accordingly.
5447 (clear_sigint_trap): Check `osig_set' to decide wheater to restore
5448 SIGINT handler, instead of checking the current inferior (which
5449 may be none).
5450 (_initialize_inflow): Attach inflow_new_inferior and
5451 inflow_inferior_exit to the "new_inferior" and "inferior_exit"
5452 notifications, respectively.
5453 * inferior.h (struct terminal_info): Forward declare.
5454 (struct inferior): Add `terminal_info' field.
5455 * inferior.c (delete_inferior_1): Notify the inferior_exit
5456 observers before removing the inferior from the lists and deleting
5457 it.
5458 * inf-ptrace.c (inf_ptrace_stop): `inferior_process_group' is now
5459 a function instead of a variable. Adjust.
5460 * procfs.c (procfs_stop): Ditto.
5461
b242c3c2
PA
54622009-05-17 Pedro Alves <pedro@codesourcery.com>
5463
5464 * infrun.c (handle_inferior_event): When handling a
5465 TARGET_WAITKIND_FORKED, detach breakpoints from the fork child
5466 immediatelly.
60a7d074 5467 * linux-nat.c (linux_child_follow_fork): Only detach breakpoints
b242c3c2
PA
5468 from the child if vforking.
5469 * inf-ptrace.c (inf_ptrace_follow_fork): No need to detach
5470 breakpoints from the child here.
5471
71b43ef8
PA
54722009-05-17 Pedro Alves <pedro@codesourcery.com>
5473
5474 * infrun.c (pending_follow): Remove execd_pathname member.
5475 (resume): No longer handle TARGET_WAITKIND_EXECD pending follow.
5476 (handle_inferior_event): When handling a TARGET_WAITKIND_EXECD
5477 event, don't copy `execd_pathname' to pending_follow, use the
5478 event copy instead. Release `execd_pathname' once done with
5479 handling the event.
5480
235f2b04
PA
5481 * infrun.c (pending_follow): Remove mention of exec events.
5482
a6b808b4
HZ
54832009-05-17 Hui Zhu <teawater@gmail.com>
5484
5485 * i386-tdep.c (i386_process_record): Make it extern.
5486 (i386_gdbarch_init): Don't call set_gdbarch_process_record
5487 here.
d5f3b873 5488 * i386-tdep.h (i386_process_record): Declare.
a6b808b4
HZ
5489 * i386-linux-tdep.c (i386_linux_init_abi): Call
5490 set_gdbarch_process_record.
5491
ee342b23
VP
54922009-05-17 Vladimir Prus <vladimir@codesourcery.com>
5493
5494 Always report varobj as changed when in_scope attribute changes.
5495
5496 * varobj.c (install_new_value): If non-NULL-ness of value
5497 changed, return 1.
5498
17a37d48
PP
54992009-05-15 Paul Pluzhnikov <ppluzhnikov@google.com>
5500
5501 * NEWS: Mention set/show libthread-db-search-path.
5502 * gdb_thread_db.h (LIBTHREAD_DB_SEARCH_PATH): New define.
5503 (LIBTHREAD_DB_SO): Moved from linux-thread-db.c
5504 * linux-thread-db.c (libthread_db_search_path): New setting.
5505 (thread_db_handle): New variable (replaces using_thread_db).
5506 (try_thread_db_load_1): New function.
5507 (try_thread_db_load, thread_db_load_search): Likewise.
5508 (dladdr_to_soname): Likewise.
5509 (thread_db_load): Iterate over possibly multiple libthread_db's.
5510 (check_for_thread_db): Attempt to load new libthread_db.
5511 (thread_db_detach, thread_db_wait): Unload libthread_db.
5512 (thread_db_mourn_inferior): Likewise.
5513 (_initialize_thread_db): Add new libthread-db-search-path option.
5514 Defer loading of libthread_db to check_for_thread_db.
5515 * solib.c (libpthread_name_p): New function.
5516 (libpthread_solib_p): Call it.
5517 * solib.h (libpthread_name_p): New prototype.
5518
0643c12e
PM
55192009-05-15 Pierre Muller <muller@ics.u-strasbg.fr>
5520
5521 * MAINTAINERS: Update my email address.
5522
e62c965a
PP
55232009-05-14 Paul Pluzhnikov <ppluzhnikov@google.com>
5524
5525 * breakpoint.h: Add breakpoint_re_set_objfile prototype.
5526 * breakpoint.c (create_overlay_event_breakpoint): Renamed
5527 from create_overlay_event_breakpoint_1, old
5528 create_overlay_event_breakpoint deleted.
5529 (breakpoint_re_set_objfile): Don't rescan all objfiles
5530 unnecessarily.
5531 (breakpoint_re_set): New function.
5532 * symfile.c (new_symfile_objfile): Call breakpoint_re_set_objfile
5533 instead of breakpoint_re_set.
5534 * objfiles.c (objfile_relocate): Likewise.
5535
9e2ace22
JB
55362009-05-14 Joel Brobecker <brobecker@adacore.com>
5537
5538 * gdbarch.sh: Add comment documenting the target_gdbarch global.
5539 gdbarch.h does NOT need to be regenerated as the corresponding
5540 change has already been made in a previous commit.
5541
39a90fca 55422009-05-14 Pierre Muller <muller@ics.u-strasbg.fr>
9bb9e8ad
PM
5543
5544 Remove all i386 debug register low level macros in config nm files.
5545 (I386_DR_LOW_SET_ADDR, I386_DR_LOW_RESET_ADDR): Remove.
5546 (I386_DR_LOW_GET_STATUS, I386_DR_LOW_SET_CONTROL): Remove.
5547 (I386_USE_GENERIC_WATCHPOIINTS): Remove.
5548
5549 * i386-nat.h: New file (adapted from config/i386/nm-i386.h).
5550 (struct i386_dr_low_type): New type.
5551 (i386_dr_low): New global variable.
5552 * i386-nat.c (TARGET_HAS_DR_LEN_8): Update macro.
5553 (i386_insert_aligned_watchpoint): Replace i386 dr low macros by
5554 i386_dr_low struct variable fields.
5555 (i386_remove_aligned_watchpoint): Likewise.
5556 (i386_stopped_data_address): Likewise.
5557 (i386_stopped_by_hwbp): Likewise.
5558 (show_debug_regs_command_added): New static variable.
5559 (add_show_debug_regs_command): New static function.
5560 (i386_use_watchpoints): Call add_show_debug_regs_command if not done.
5561 (i386_set_debug_register_length): New function.
5562 (_initialize_i386_nat): Delete.
5563
5564 * amd64-linux-nat.c: Include "i386-nat.h".
5565 (amd64_linux_dr_set_control): Change to static.
5566 (amd64_linux_dr_get_status): Change to static.
5567 (amd64_linux_dr_set_addr,amd64_linux_dr_reset_addr): Likewise.
5568 (_initialize_amd64_linux_nat): Set i386_dr_low variable fields.
5569
5570 * go32-nat.c: Include "i386-nat.h".
5571 (go32_set_addr): Change to static.
5572 (go32_set_dr7): Change to static. Change arg type to unisgned long.
5573 (go32_get_dr6): Change to static. Change return type to unisnged long.
5574 (init_go32_ops): Set i386_dr_low variable fields.
5575 * i386-linux-nat.c: Include "i386-nat.h".
5576 (i386_linux_dr_set_control, i386_linux_dr_get_status): Change to static.
5577 (i386_linux_dr_set_addr, i386_linux_dr_reset_addr): Idem.
5578 (_initialize_i386_linux_nat): Set i386_dr_low variable fields.
5579 * i386bsd-nat.h: Declare functions used for
5580 i386_dr_low fields in i386fbsd-nat.c.
5581 * i386fbsd-nat.c: Include "i386-nat.h".
5582 (_initialize_i386fbsd_nat): Set i386_dr_low variable fields.
5583 * windows-nat.c: Include "i386-nat.h".
5584 (cygwin_set_dr, cygwin_get_dr6, cygwin_set_dr7): Add prototypes.
5585 Change to static.
5586 (cygwin_get_dr6): Change return type to unisnged long.
5587 (cygwin_set_dr7): Change arg type to unisgned long.
5588 (init_windows_ops): Set i386_dr_low function fields.
5589
5590 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Call
5591 i386_set_debug_register_length.
5592 * i386-windows-nat.c (_initialize_i386_windows_nat): Likewise.
5593
5594 * config/i386/nm-cygwin.h: Remove all I386_* macros.
5595 * config/i386/nm-cygwin64.h: Likewise.
5596 * config/i386/nm-fbsd.h: Likewise.
5597 * config/i386/nm-linux.h: Likewise.
5598 * config/i386/nm-i386.h: Remove completely.
5599 * config/i386/nm-go32.h: Remove completely.
5600 * config/i386/nm-linux64.h: Remove completely.
5601 * config/i386/go32.mh (NAT_FILE): Remove entry.
5602 * config/i386/linux64.h (NAT_FILE): Change to config/nm-linux.h.
5603
7a893eb8
JB
56042009-05-14 Jon Beniston <jon@beniston.com>
5605
5606 * MAINTAINERS: Add Jon Beniston to write after approval list.
5607
57a9e6af
PP
56082009-05-13 Paul Pluzhnikov <ppluzhnikov@google.com>
5609
5610 * objc-lang.c (objc_objfile_data): New variable.
5611 (find_methods): Skip objfiles without Obj-C methods.
5612 (_initialize_objc_lang): New function.
5613
3f7f5fe4
JB
56142009-05-13 Joel Brobecker <brobecker@adacore.com>
5615
5616 * c-lang.c (print_wchar): Remove unnecessary cast.
5617
25ad2853
JB
56182009-05-12 Jim Blandy <jimb@red-bean.com>
5619
5620 * MAINTAINERS: Remove self as m32c target maintainer.
5621
cbe54154
PA
56222009-05-12 Pedro Alves <pedro@codesourcery.com>
5623
5624 * cli/cli-decode.c (deprecated_add_set_cmd): Delete.
5625 * command.h (deprecated_add_set_cmd): Delete declaration.
5626 * gnu-nat.c (_initialize_gnu_nat): Replace 'maint gnu-debug' with
5627 'set debug gnu-nat' and 'show debug gnu-nat'.
5628 * i386-nat.c (_initialize_i386_nat): Replace 'maint
5629 show-debug-registers' with 'maint set show-debug-registers' and
5630 'maint show show-debug-registers'.
5631 * mips-linux-nat.c (_initialize_mips_linux_nat): Replace 'maint
5632 show-debug-registers' with 'maint set show-debug-registers' and
5633 'maint show show-debug-registers'.
5634
2d90c72a
JB
56352009-05-12 Joel Brobecker <brobecker@adacore.com>
5636
5637 * c-lang.c (print_wchar): Convert w into a gdb_wchar_t before
5638 pushing it on the output obstack.
5639
00903456
JK
56402009-05-11 Joel Brobecker <brobecker@adacore.com>
5641
5642 Fix internal error on breaking at a multi-locations caller source line.
5643 * breakpoint.c (parse_breakpoint_sals): Set EXPLICIT_PC for the `break'
5644 command with no parameters.
5645
7feb7d06
PA
56462009-05-11 Pedro Alves <pedro@codesourcery.com>
5647
5648 * linux-nat.c (enum sigchld_state): Delete.
5649 (linux_nat_async_events_state): Delete.
5650 (struct waitpid_result): Delete.
5651 (waitpid_queue): Delete.
5652 (queued_waitpid_1): Delete.
5653 (async_file_flush): New.
5654 (queued_waitpid, push_waitpid): Delete.
5655 (async_file_mark): New.
5656 (drain_queued_events): Delete.
5657 (my_waitpid): Remove locally queued events handling.
5658 (linux_test_for_tracefork): Upjust.
5659 (linux_child_follow_fork): Ditto.
5660 (sync_sigchld_action): Delete.
5661 (blocked_mask): Reinstate.
5662 (async_sigchld_action): Rename to...
5663 (sigchld_action): ... this.
5664 (block_child_signals): New.
5665 (restore_child_signals_mask): New.
5666 (lin_lwp_attach_lwp): Adjust.
5667 (linux_nat_create_inferior): Ditto.
5668 (linux_nat_attach): Also use lp->status in async mode.
5669 (get_pending_status): Don't use queued_waitpid.
5670 (linux_nat_detach): Don't drain locally queued events.
5671 (linux_nat_resume): Allow pending wait statuses stored lp->status
5672 in async mode. If returning early due to a pending event,
5673 re-register the event source.
5674 (stop_wait_callback): Allow pending wait statuses stored
5675 lp->status in async mode.
5676 (pipe_to_local_event_queue, local_event_queue_to_pipe): Delete.
5677 (linux_nat_wait): Rename to ...
5678 (linux_nat_wait_1): ... this. Allow pending wait statuses stored
5679 lp->status in async mode. Always add WNOHANG to the waitpid
5680 options in async mode.
5681 (linux_nat_wait): New.
5682 (kill_callback): Don't drain locally queued events.
5683 (sigchld_handler): Rewrite.
5684 (linux_nat_is_async_p, linux_nat_can_async_p): Fix comments to
5685 refer to "set target-async".
5686 (linux_nat_async_mask): If in non-stop, and re-enabling async
5687 mode, re-register the target event source in the event loop.
5688 (linux_nat_event_pipe_pop, linux_nat_event_pipe_push)
5689 (get_pending_events, async_sigchld_handler)
5690 (linux_nat_async_events): Delete.
5691 (handle_target_event): New.
5692 (linux_nat_async_file_handler): Delete.
5693 (linux_async_pipe): New.
5694 (linux_nat_async): Only re-register in the event loop if not
5695 registered yet. Always notify the event-loop once if enabling the
5696 event source.
5697 (linux_nat_stop_lwp): Rewrite to handle pending events stored in
5698 lp->status, not in the locally queued event list.
5699 (linux_nat_stop): Don't mask out async event handling.
5700 (linux_nat_setup_async): Delete.
5701 (_initialize_linux_nat): Adjust.
5702 (lin_thread_get_thread_signals): blocked_mask is global again.
5703 Adjust.
5704
39a90fca 57052009-05-11 Pierre Muller <muller@ics.u-strasbg.fr>
d92524f1
PM
5706
5707 Unify target macros.
5708
5709 * target.h (STOPPED_BY_WATCHPOINT): Delete, replaced by ...
5710 (target_stoppped_by_watchpoint): New macro.
5711 (HAVE_STEPPABLE_WATCHPOINT): Delete, replaced by ...
5712 (target_have_steppable_watchpoint): New macro.
5713 (HAVE_CONTINUABLE_WATCHPOINT): Delete, replace by ...
5714 (target_have_continuable_watchpoint): New macro.
5715 (TARGET_CAN_USE_HARDWARE_WATCHPOINT):Delete, replaced by ...
5716 (target_can_use_hardware_watchpoint): New macro.
5717 (TARGET_REGION_OK_FOR_HW_WATCHPOINT):Delete, replaced by ...
5718 (target_region_ok_for_hw_watchpoint): New macro.
5719
5720 * breakpoint.c (update_watchpoint): Use new macros.
5721 (bpstat_alloc): Likewise.
5722 (create_breakpoint): Likewise.
5723 (watch_command_1): Likewise.
5724 (can_use_hardware_watchpoint): Likewise.
5725 (do_enable_breakpoint): Likewise.
5726 * infrun.c (handle_inferior_event): Adapt to new macros.
5727 * mips-tdep.c (mips_gdbarch_init): Update comments.
5728 * procfs.c (procfs_set_watchpoint): Update comment.
5729 (procfs_insert_watchpoint): Adapt to new macros.
5730 * remote-m32r-sdi.c (m32r_stop):
5731 * remote-mips.c (mips_remove_breakpoint):
5732 * target.c (debug_to_region_ok_for_hw_watchpoint): Update to new macros.
5733 (debug_to_stopped_by_watchpoint): Likewise.
5734
5735
39a90fca 57362009-05-10 Pierre Muller <muller@ics.u-strasbg.fr>
fe524716
PM
5737
5738 * src/gdb/target.h: Remove all tests for already defined
5739 macros. All macros defined here should not be set in config
5740 headers anymore.
5741
1dfe79e8
SDJ
57422009-05-08 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
5743
5744 * ppc-linux-nat.c (have_ptrace_getsetregs): New variable.
5745 (have_ptrace_getsetfpregs): Likewise.
5746 fetch_all_gp_regs): New function.
5747 (fetch_gp_regs): New function.
5748 (fetch_all_fp_regs): Likewise.
5749 (fetch_fp_regs): New function.
5750 (fetch_ppc_registers): Using the new methods to fetch general-
5751 purpose and floating-pointer registers.
5752 (store_all_gp_regs): New function.
5753 (store_gp_regs): Likewise.
5754 (store_all_fp_regs): New function.
5755 (store_fp_regs): Likewise.
5756 (store_ppc_registers): Using the new methods to store general-
5757 purpose and floating-pointer registers.
5758
2cda8d2f
DE
57592009-05-08 Doug Evans <dje@google.com>
5760
5761 * linux-nat.c (linux_xfer_siginfo): Delete unused locals lp, n.
5762
b0afac70
SDJ
57632009-05-07 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
5764
5765 * MAINTAINERS (Write After Approval): Add self.
5766
6b614274
JB
57672009-05-07 Joel Brobecker <brobecker@adacore.com>
5768
5769 * gdbarch.h (target_gdbarch): Add comment documenting this global.
5770
57712009-05-06 Joel Brobecker <brobecker@adacore.com>
4edb1e84
JB
5772
5773 * acinclude.m4 (AM_ICONV): Prefer in-tree libiconv if present over
5774 system iconv.
5775 * configure: Regenerate.
5776
6b614274 57772009-05-06 Joel Brobecker <brobecker@adacore.com>
8626589c
JB
5778
5779 * utils.c: Add include of gdb_usleep.h.
5780 (defaulted_query): Detect false EOF conditions that happen
5781 on terminals opened with the O_NONBLOCK flag when there is
5782 nothing to read.
5783
a562dc8f
PA
57842009-05-06 Pedro Alves <pedro@codesourcery.com>
5785
5786 * inferior.c (add_inferior): Move observer_notify_new_inferior
5787 call to ...
5788 (add_inferior_silent): ... here.
5789
39a90fca 57902009-05-06 Pierre Muller <muller@ics.u-strasbg.fr>
25513619
PA
5791 Pedro Alves <pedro@codesourcery.com>
5792
5793 * procfs.c (procfs_insert_watchpoint, procfs_remove_watchpoint)
5794 (procfs_region_ok_for_hw_watchpoint, procfs_use_watchpoints): New
5795 functions.
5796 (procfs_stopped_by_watchpoint): Made static, ptid argument
5797 removed.
5798 (_initialize_procfs): Register new watchpoint related target
5799 functions.
5800 * config/i386/nm-i386sol2.h (TARGET_CAN_USE_HARDWARE_WATCHPOINT)
5801 (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT, STOPPED_BY_WATCHPOINT)
5802 (HAVE_CONTINUABLE_WATCHPOINT): Delete.
5803 (target_insert_watchpoint, target_remove_watchpoint): Delete.
5804 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
5805 declarations.
5806 * config/mips/nm-irix5.h (STOPPED_BY_WATCHPOINT)
5807 (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT): Delete.
5808 (target_insert_watchpoint, target_remove_watchpoint): Delete.
5809 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
5810 declarations.
5811 * config/sparc/nm-sol2.h (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT)
5812 (HAVE_CONTINUABLE_WATCHPOINT, STOPPED_BY_WATCHPOINT): Delete.
5813 (target_insert_watchpoint, target_remove_watchpoint): Delete.
5814 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
5815 declarations.
5816
51f4db83 58172009-05-06 Hui Zhu <teawater@gmail.com>
e7a8dbfb 5818
8408d274
HZ
5819 * i386-tdep.c (i386_process_record): Change bzero to memset.
5820
51f4db83 58212009-05-06 Hui Zhu <teawater@gmail.com>
8408d274
HZ
5822
5823 * NEWS: Add item for process record and replay.
e7a8dbfb 5824
f6402f18
MG
58252009-05-05 Maxim Grigoriev <maxim2405@gmail.com>
5826
5827 * xtensa-tdep.c (xtensa_frame_cache): Use pc instead of cache->pc.
5828
fb14de7b
UW
58292009-05-05 Ulrich Weigand <uweigand@de.ibm.com>
5830
5831 * inferior.h (read_pc, write_pc): Remove.
5832 * regcache.c (read_pc, write_pc): Remove.
5833
5834 * infrun.c (displaced_step_fixup): Use regcache_read_pc instead
5835 of read_pc.
5836 (handle_inferior_event): Use regcache_read_pc instead of read_pc
5837 when determining value of stop_pc. Replace subsequent uses of
5838 read_pc by inspecting already-retrieved stop_pc value.
5839 (keep_going): Use regcache_read_pc instead of read_pc.
5840
5841 * breakpoint.c (watchpoint_check): Use current frame architecture
5842 and PC instead of current_gdbarch and read_pc ().
5843 * tracepoint.c (set_traceframe_context): Replace PC argument
5844 with FRAME argument.
5845 (trace_start_command, finish_tfind_command): Update calls.
5846 (finish_tfind_command): Compare frame IDs to identify transitions
5847 between frames.
5848 (trace_find_pc_command): Use regcache_read_pc instead of read_pc.
5849 * rs6000-nat.c (exec_one_dummy_insn): Pass in regcache instead
5850 of gdbarch. Use regcache_read_pc and regcache_write_pc instead
5851 of read_pc and write_pc.
5852 (store_register): Make regcache argument non-const. Update call
5853 to exec_one_dummy_insn.
5854
5855 * thread.c (switch_to_thread): Use regcache_read_pc instead of read_pc.
5856 * infcmd.c (post_create_inferior): Likewise.
5857 * solib-darwin.c (darwin_solib_create_inferior_hook): Likewise.
5858 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
5859 * solib-sunos.c (sunos_solib_create_inferior_hook): Likewise.
5860 * solib-svr4.c (enable_break, svr4_relocate_main_executable): Likewise.
5861 * linux-fork.c (fork_load_infrun_state): Likewise.
5862 * hppa-hpux-tdep.c (hppa_hpux_push_dummy_code): Likewise.
5863 * record.c (record_wait): Likewise.
5864 * procfs.c (procfs_wait): Likewise.
5865 * remote-mips.c (common_open, mips_wait): Likewise.
5866 * remote-m32r-sdi.c (m32r_resume): Likewise.
5867
5868 * symfile.c (generic_load): Use regcache_write_pc instead of write_pc.
5869 * monitor.c (monitor_create_inferior, monitor_load): Likewise.
5870 * m32r-rom.c (m32r_load, m32r_upload_command): Likewise.
5871 * remote-m32r-sdi.c (m32r_create_inferior, m32r_load): Likewise.
5872 * remote-mips.c (mips_create_inferior, mips_load): Likewise.
5873
5874 * solib-darwin.c: Include "regcache.h".
5875 * solib-pa64.c: Include "regcache.h".
5876 * solib-svr4.c: Include "regcache.h.".
5877
5878 * symfile.c: Do not mention read_pc or write_pc in comments.
5879 * dink32-rom.c: Likewise.
5880 * m32r-rom.c: Likewise.
5881 * mips-tdep.c: Likewise.
5882
f698437e
UW
58832009-05-05 Ulrich Weigand <uweigand@de.ibm.com>
5884
5885 * fork-child.c (startup_inferior): Move setting stop_pc ...
5886 * infcmd.c (post_create_inferior): ... to here.
5887
64644d9b
MS
58882009-05-04 Michael Snyder <msnyder@vmware.com>
5889
5890 * NEWS: Add item for reverse debugging commands.
5891
67ce33d7
PA
58922009-05-04 Pedro Alves <pedro@codesourcery.com>
5893
5894 * go32-nat.c (go32_stop): Delete.
5895 (go32_kill_inferior): Rewrite to only call go32_mourn_inferior.
5896 (go32_create_inferior): Don't call go32_stop or
5897 go32_kill_inferior.
5898 (go32_mourn_inferior): Inline go32_stop and go32_kill_inferior
5899 here.
5900 (init_go32_ops): Don't register go32_stop.
5901
26a4ddaa
EZ
59022009-05-02 Eli Zaretskii <eliz@gnu.org>
5903
5904 * dbxread.c (read_dbx_symtab): Avoid compiler warnings for
5905 sym_name.
5906
5907 * infcall.c (find_function_addr): Avoid compiler warnings for
5908 funaddr.
5909
a11a1416
JK
59102009-05-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5911
5912 * dictionary.c (dict_hashed_vector, dict_hashed_expandable_vector)
5913 (dict_linear_vector, dict_linear_expandable_vector): Fix a comment typo.
5914
ee78f3e5
DE
59152009-05-01 Doug Evans <dje@google.com>
5916
5917 * linux-thread-db.c (thread_db_pid_to_str): Delete unused assignment
5918 to thread_info.
5919
699275c9
EZ
59202009-05-01 Eli Zaretskii <eliz@gnu.org>
5921
299a410e
EZ
5922 * record.c (_initialize_record): Reformat and clarify doc strings
5923 for stop-at-limit and insn-number-max.
5924
699275c9
EZ
5925 * go32-nat.c: Add comments about dirty secrets of DJGPP debugging.
5926
323427d1
JK
59272009-05-01 Jan Kratochvil <jan.kratochvil@redhat.com>
5928
5929 Make specifiable the make_function_type type memory ownership.
5930 * gdbtypes.c (make_function_type): New parameter `objfile', use it
5931 explicitely instead of TYPE-initialized removed local variable
5932 `objfile'. Describe `objfile' it in the function comment.
5933 (lookup_function_type): Update make_function_type callers.
5934 * gdbtypes.h (make_function_type): Update the prototype.
5935 * jv-lang.c (java_link_class_type): Update make_function_type callers.
5936 * dwarf2read.c (read_subroutine_type): Likewise.
5937 * stabsread.c (read_type): Likewise.
5938
15430fc0
EZ
59392009-05-01 Eli Zaretskii <eliz@gnu.org>
5940
89c9c2ec
EZ
5941 * go32-nat.c (go32_pid_to_str): Call normal_pid_to_str instead of
5942 printing a bogus "Thread <main>".
5943 (go32_thread_alive): Don't return 1 for null_ptid.
5944
15430fc0
EZ
5945 * i386-tdep.c (i386_go32_init_abi): Override the number of
5946 registers due to non-support of SSE.
5947
c7098c41
AG
59482009-04-30 Anthony Green <green@moxielogic.com>
5949
5950 * configure.tgt: Link the moxie simulator in with gdb.
5951
25c2f6ab
PP
59522009-04-30 Paul Pluzhnikov <ppluzhnikov@google.com>
5953
5954 * elfread.c (elf_symtab_read): Don't assume .data and .rodata
5955 are present.
15430fc0 5956
77fcef51
HZ
59572009-04-30 Hui Zhu <teawater@gmail.com>
5958 Michael Snyder <msnyder@vmware.com>
5959
5960 I386 Linux process record and replay support.
5961
5962 * i386-linux-tdep.c (i386_linux_record_tdep): New variable.
5963 This struct has the argument for the function
5964 "record_linux_system_call".
5965 (i386_linux_intx80_sysenter_record): New function. Parse the
5966 system call instruction and call function
5967 "record_linux_system_call" to record execute log.
5968 (i386_linux_init_abi): Initialize "i386_linux_record_tdep".
5969 Set "i386_linux_intx80_sysenter_record" to
5970 "i386_intx80_record" and "i386_sysenter_record".
5971
7ad10968
HZ
59722009-04-30 Hui Zhu <teawater@gmail.com>
5973 Michael Snyder <msnyder@vmware.com>
5974
5975 I386 architecture process record and replay support.
5976
5977 * i386-tdep.c (PREFIX_REPZ, PREFIX_REPNZ, PREFIX_LOCK,
5978 PREFIX_DATA, PREFIX_ADDR): New macros. Help decode the i386
5979 instruction set.
5980 (aflag, dflag, override, modrm, mod, reg, rm, ot,
5981 i386_record_pc): New variables. Ditto.
5982 (i386_record_modrm, i386_record_lea_modrm_addr,
5983 i386_record_lea_modrm): New functions. Ditto.
5984 (i386_process_record): New function. Parse the instruction in
5985 address "addr" and record the values of registers and memory
5986 that will be changed by this instruction.
5987 (i386_gdbarch_init): Set "i386_process_record" to GDBARCH
5988 "process_record" interface.
5989 * i386-tdep.h (gdbarch_tdep): New function pointers
5990 "i386_intx80_record" and "i386_sysenter_record" that point to
5991 the function that can record "intx80" and "sysenter" execute
5992 log.
5993
96429cc8
HZ
59942009-04-30 Hui Zhu <teawater@gmail.com>
5995 Michael Snyder <msnyder@vmware.com>
5996
5997 * infrun.c (use_displaced_stepping): Return false if process
5998 record and replay target is used.
5999 (proceed): Call function "record_not_record_set" if pocess
6000 record and replay target is used.
6001
b7f6bf22
HZ
60022009-04-30 Hui Zhu <teawater@gmail.com>
6003 Michael Snyder <msnyder@vmware.com>
6004
6005 Linux process record and replay support.
6006
6007 * Makefile.in (ALLDEPFILES): Add linux-record.c.
6008 (ALL_TARGET_OBS): Add linux-record.o.
6009 * configure.tgt (x86_64-*-linux*): Add linux-record.o.
6010 (i[34567]86-*-linux*): Add linux-record.o.
6011 * linux-record.c, linux-record.h: New file.
6012
69d05d38
HZ
60132009-04-30 Hui Zhu <teawater@gmail.com>
6014 Michael Snyder <msnyder@vmware.com>
6015
6016 Process record and replay target.
6017
6018 * Makefile.in (SFILES): Add record.c.
6019 (COMMON_OBS): Add record.o.
6020 * record.c, record.h: New file.
6021
81e64f55
HZ
60222009-04-30 Hui Zhu <teawater@gmail.com>
6023 Michael Snyder <msnyder@vmware.com>
6024
6025 * target.h (strata): New stratum "record_stratum".
6026
0407e712
HZ
60272009-04-30 Hui Zhu <teawater@gmail.com>
6028 Michael Snyder <msnyder@vmware.com>
6029
6030 GDBARCH interface for process record and replay.
6031
6032 * gdbarch.sh (process_record): This interface point to the
6033 function that records the inferior execute log.
6034
c5af0dad
DE
60352009-04-29 Doug Evans <dje@google.com>
6036
6037 * i386-nat.c (child_post_startup_inferior): Delete, unused.
6038
df2b6d2d
PA
60392009-04-29 Pedro Alves <pedro@codesourcery.com>
6040
6041 * breakpoint.c (print_exception_catchpoint): Access `b' directly
6042 instead of `b->loc->owner'.
6043 (print_mention_exception_catchpoint): Ditto.
6044
484086b7
JK
60452009-04-29 Jan Kratochvil <jan.kratochvil@redhat.com>
6046
6047 * macrocmd.c (info_macro_command): Print -Dname=value if LINE is zero.
6048
379a77b5
TT
60492009-04-27 Tom Tromey <tromey@redhat.com>
6050
6051 * c-exp.y (yylex): Handle '[' and ']' like '(' and ')'.
6052
aad80b26
JG
60532009-04-27 Jerome Guitton <guitton@adacore.com>
6054
6055 * symtab.c (append_exact_match_to_sals): New function, extracted
6056 from expand_line_sal.
6057 (expand_line_sal): Use append_exact_match_to_sals to append exact
6058 matches. If none found, append all best items.
6059
57a46001
JG
60602009-04-27 Jerome Guitton <guitton@adacore.com>
6061
6062 * main.c (captured_main): Move gdbinit lookups after gdb_init.
6063
d389af10
JK
60642009-04-27 Jan Kratochvil <jan.kratochvil@redhat.com>
6065
6066 PR gdb/9675:
6067 * dwarf2read.c (unsigned_int_compar, inherit_abstract_dies): New.
6068 (read_func_scope): Call inherit_abstract_dies.
6069
90b9b517
EZ
60702009-04-25 Eli Zaretskii <eliz@gnu.org>
6071
6072 * Makefile.in (ALLDEPFILES): Remove duplicate entries for
6073 sparc-sol2-nat.c and sparc-sol2-tdep.c.
80a0ea0f
EZ
6074
6075 * stack.c (_initialize_stack) <disassemble-next-line>: Doc fix.
6076
39a90fca 60772009-04-24 Pierre Muller <muller@ics.u-strasbg.fr>
5ac79d78
PM
6078
6079 ARI change: Use "/* ARI: rule */" pattern.
6080 * utils.c: Update ARI patterns.
6081 * gdb_dirent.h: Likewise.
6082
d7066cce
AG
60832009-04-23 Anthony Green <green@moxielogic.com>
6084
6085 * MAINTAINERS: Add moxie target.
6086 * configure.tgt: Add moxie-*-elf target.
6087 * moxie-tdep.c: New file.
6088 * moxie-tdep.h: New file.
6089
fc84d355 60902009-04-23 Joel Brobecker <brobecker@adacore.com>
72fcaa05
JB
6091
6092 * ada-lang.c: Remove an extra empty line. No code change.
6093
217dc9e2
JK
60942009-04-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6095
6096 Fix double free on error inserting the breakpoint instruction.
6097 * breakpoint.c (create_breakpoints): Move the
6098 update_global_location_list call to ...
6099 (break_command_really): ... here together with the second local call
6100 both unified after all the cleanups.
6101
b14b1491
TT
61022009-04-23 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
6103 Tom Tromey <tromey@redhat.com>
6104
6105 * configure, config.in: Regenerate.
6106 * configure.ac: Support for relocatable GDB datadir. Use
6107 GDB_AC_WITH_DIR. Always define TARGET_SYSTEM_ROOT_RELOCATABLE.
6108 * acinclude.m4 (GDB_AC_WITH_DIR): New defun.
6109 * top.c (init_main): Add "set data-directory".
6110 * defs.h (gdb_datadir): Declare.
6111 * main.c (gdb_datadir): New global.
6112 (captured_main): Initialize gdb_datadir. Use relocate_directory.
6113 (relocate_path): New function.
6114 (relocate_directory): Likewise.
6115 (get_init_files): Use relocate_path.
6116 (README): Mention --with-gdb-datadir.
6117
5e7b5f74
JB
61182009-04-23 Joel Brobecker <brobecker@adacore.com>
6119
6120 * ada-tasks (task_command_1): Call target_find_new_threads.
6121
465f42bb
JB
61222009-04-23 Joel Brobecker <brobecker@adacore.com>
6123
6124 * stack.c (do_gdb_disassembly): Print the exception message if an
6125 error was thrown while trying to perform the disassembly.
6126
3038237c
JK
61272009-04-22 Jan Kratochvil <jan.kratochvil@redhat.com>
6128
6129 * varobj.c (free_variable): Replace free_current_contents by xfree.
6130
17c12639
KH
61312009-04-22 Kazu Hirata <kazu@codesourcery.com>
6132
6133 * arm-linux-nat.c (fetch_register, store_register): Use
6134 ARM_CPSR_GREGNUM instead of ARM_CPSR_REGNUM.
6135 * arm-linux-tdep.c (arm_linux_supply_gregset,
6136 arm_linux_collect_gregset): Likewise.
6137 * arm-linux-tdep.h (ARM_CPSR_GREGNUM): New.
6138 * arm-tdep.h (ARM_CPSR_REGNUM): Remove.
6139
a362e3d3
HZ
61402009-04-22 Hui Zhu <teawater@gmail.com>
6141
6142 * stack.c (_initialize_stack): Set the default of
6143 disassemble-next-line to off.
6144
d2596e2e
TT
61452009-04-21 Tom Tromey <tromey@redhat.com>
6146
6147 * acinclude.m4: Use AS_HELP_STRING, not AC_HELP_STRING.
6148 * configure.ac: Use AS_HELP_STRING, not AC_HELP_STRING.
6149
62e4f60c
AS
61502009-04-21 Andreas Schwab <schwab@linux-m68k.org>
6151
6152 * configure.ac: Add quotes to not lose brackets in help text.
6153 * configure: Rebuild.
6154
82cd387f 61552009-04-21 Andreas Schwab <schwab@linux-m68k.org>
cfd53605
AS
6156
6157 * configure.ac: Don't postprocess Makefile in config.status.
6158 Substitute GDB_NM_FILE. Don't substitute nm_h.
6159 * Makefile.in (GDB_NM_FILE): Substitute.
6160 (TAGS): Use $(GDB_NM_FILE) instead of $(NAT_FILE).
6161 * configure: Regenerate.
6162 * gnulib/Makefile.in: Regenerate.
6163
26e251b6
JM
61642009-04-21 Joseph Myers <joseph@codesourcery.com>
6165
6166 * configure.ac (--with-datarootdir, --with-docdir, --with-pdfdir,
6167 --with-htmldir): New.
6168 * configure: Regenerate.
6169
32c1c914
TT
61702009-04-21 Tom Tromey <tromey@redhat.com>
6171
6172 * configure: Rebuild.
6173 * configure.ac: Use lower case for start of help strings. Clean
6174 up --with-sysroot help.
6175
a1220294
TT
61762009-04-21 Tom Tromey <tromey@redhat.com>
6177
6178 * configure: Rebuild.
6179 * acinclude.m4 (AM_ICONV): Use AC_HELP_STRING.
6180 * configure.ac: Use AC_HELP_STRING. Use upper case for variables
6181 in help.
6182
39a90fca 61832009-04-21 Pierre Muller <muller@ics.u-strasbg.fr>
dfc3cd0e
PM
6184
6185 ARI fix: remove "%p".
6186 * ia64-tdep.c (ia64_frame_this_id): Use host_address_to_string function.
6187 (ia64_sigtramp_frame_this_id): Ditto.
6188 (ia64_libunwind_frame_this_id): Ditto.
6189 (ia64_libunwind_sigtramp_frame_this_id): Ditto.
6190 * symmisc.c (maintenance_info_psymtabs): Ditto.
6191
29b0e8a2
JM
61922009-04-21 Joseph Myers <joseph@codesourcery.com>
6193
6194 * configure.ac (--with-relocated-sources): New.
6195 * configure, config.in: Regenerate.
6196 * source.c (add_substitute_path_rule): Remove static.
6197 * source.h (add_substitute_path_rule): Declare.
6198 * main.c: Include "source.h".
6199 (captured_main): Add substitution rule if RELOC_SRCDIR.
6200
39a90fca 62012009-04-21 Pierre Muller <muller@ics.u-strasbg.fr>
ccabeb57
PM
6202
6203 * gnu-nat.h (proc_debug): Add missing continuation line in macro.
cfd53605 6204
b9412953
DD
62052009-04-20 David Daney <ddaney@caviumnetworks.com>
6206
6207 * NEWS: Mention MIPS/Linux hardware watchpoint support.
6208
62092009-04-20 David Daney <ddaney@caviumnetworks.com>
6210
6211 * mips-linux-nat.c (command.h, gdbcmd.h, gdb_assert.h): New #includes.
6212 (maint_show_dr, super_close): New variables.
6213 (super_fetch_registers, super_store_registers): Make static.
6214 (PTRACE_GET_WATCH_REGS, PTRACE_SET_WATCH_REGS, W_BIT, R_BIT, I_BIT)
6215 (W_MASK, R_MASK, I_MASK, IRW_MASK, MAX_DEBUG_REGISTER): Define.
6216 (pt_watch_style): Define new enum.
6217 (mips32_watch_regs, mips64_watch_regs, pt_watch_regs, mips_watchpoint):
6218 Define new structs.
6219 (watch_readback_valid, watch_readback, current_watches, watch_mirror):
6220 New variables.
6221 (get_irw_mask, get_reg_mask, get_num_valid, get_watchlo)
6222 (set_watchlo, get_watchhi, set_watchhi, mips_show_dr)
6223 (mips_linux_read_watch_registers, mips_linux_can_use_hw_breakpoint)
6224 (mips_linux_stopped_by_watchpoint, mips_linux_stopped_data_address)
6225 (type_to_irw, fill_mask, try_one_watch)
6226 (mips_linux_region_ok_for_hw_watchpoint, write_watchpoint_regs)
6227 (mips_linux_new_thread, populate_regs_from_watches)
6228 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6229 (mips_linux_close): New functions.
6230 (_initialize_mips_linux_nat): Register watchpoint functions with
6231 the target_ops. Add show-debug-regs maintenance command.
6232
62332009-04-20 David Daney <ddaney@caviumnetworks.com>
6234
6235 * infrun.c (handle_inferior_event): Move gegisters_changed call down.
6236
6de3146c
PA
62372009-04-19 Pedro Alves <pedro@codesourcery.com>
6238
6239 * NEWS: Mention gdbserver support for x86 Windows CE.
6240
10085bb5
EZ
62412009-04-19 Eli Zaretskii <eliz@gnu.org>
6242
e424a02e
EZ
6243 * config/djgpp/fnchange.lst: Fix typos.
6244
10085bb5
EZ
6245 Set default host and target charsets in the DJGPP port.
6246
6247 * config/djgpp/config.sed (am_cv_langinfo_codeset)
6248 (bash_cv_langinfo_codeset, ac_cv_header_nl_types_h): Set to "yes"
6249 in all configure scripts that define ac_cv_env_CPP_value.
6250
6251 * go32-nat.c (dos_codepage, nl_langinfo): New functions.
6252 Include langinfo.h.
6253
6254 * config/djgpp/nl_types.h: New file.
6255
6256 * config/djgpp/langinfo.h: New file.
6257
6258 * config/i386/go32.mh (MH_CFLAGS): Add $(srcdir)/config/djgpp.
6259
2b831889
JM
62602009-04-18 Carlos O'Donell <carlos@codesourcery.com>
6261
6262 * Makefile.in (MAKEHTML): Set to makeinfo --html.
6263 (MAKEHTMLFLAGS): Set to empty.
6264
d647eed6
EZ
62652009-04-18 Eli Zaretskii <eliz@gnu.org>
6266
d7713ae0
EZ
6267 * NEWS: Mention all new set/show commands added since GDB 6.8 was
6268 released.
6269
d647eed6
EZ
6270 * go32-nat.c (go32_sysinfo): Check if the call to
6271 __dpmi_get_capabilities fills the buffer with information, and
6272 don't use the buffer if not.
6273
58720494
TT
62742009-04-17 Tom Tromey <tromey@redhat.com>
6275
6276 * charset.c (_initialize_charset): Add special case for "646".
6277
89a34d1b
JM
62782009-04-17 Carlos O'Donell <carlos@codesourcery.com>
6279
6280 * configure.ac: AC_SUBST datarootdir, docdir, htmldir, pdfdir.
6281 * configure: Regenerate.
6282 * Makefile.in: Set datarootdir, docdir, htmldir, and pdfdir from
6283 configure substitutions.
6284 (FLAGS_TO_PASS): Add datarootdir, docdir, and htmldir.
6285
39a90fca 62862009-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
a74ce742
PM
6287
6288 ARI fix: Do not use %p, replace by call to host_address_to_string
6289 for host pointers.
6290 * darwin-nat.c (darwin_xfer_partial): Apply change.
6291 * gnu-nat.c (inf_continue, gnu_xfer_memory): Ditto.
6292 * gnu-nat.h (proc_debug): Ditto.
6293 * symmisc.c (maintenance_info_symtabs): Ditto.
6294 (maintenance_info_psymtabs): Ditto.
6295 * windows-nat.c (handle_load_dll): Ditto.
6296 (handle_unload_dll, info_w32_command, handle_exception): Ditto.
6297 * xtensa-tdep.c (xtensa_unwind_pc): Ditto.
6298
0ca8834f
JM
62992009-04-17 Joseph Myers <joseph@codesourcery.com>
6300
6301 * configure.tgt (i[34567]86-*-linux*): Use 64-bit configuration if
6302 --enable-64-bit-bfd.
6303 (sparc-*-linux*): Likewise.
6304
541f1105
EZ
63052009-04-17 Eli Zaretskii <eliz@gnu.org>
6306
6307 * go32-nat.c (go32_sysinfo): Update list of Windows versions of
6308 the NT family.
6309
1554e9be
PA
63102009-04-16 Pedro Alves <pedro@codesourcery.com>
6311
6312 * remote.c (remote_query_attached): Fix pasto in packet_ok result
6313 checking.
6314
bf75638e
JB
63152009-04-16 Joel Brobecker <brobecker@adacore.com>
6316
6317 * procfs.c (solib_mappings_callback, find_memory_regions_callback):
6318 Revert the previous change. Might not be correct, actually.
6319
3705b1c5
JB
63202009-04-16 Joel Brobecker <brobecker@adacore.com>
6321
6322 * ada-lang.h (ada_adjust_exception_stop, ada_print_exception_stop)
6323 (ada_get_current_task, ada_print_exception_breakpoint_nontask)
6324 (ada_print_exception_breakpoint_task, ada_reset_thread_registers):
6325 Remove declaration. These are non-existent functions.
6326
37da21bc
JB
63272009-04-16 Joel Brobecker <brobecker@adacore.com>
6328
6329 * procfs.c (solib_mappings_callback, find_memory_regions_callback):
6330 Fix a compilation warning on mips-irix due to casting from
6331 a pointer of different size.
6332
6f38eac8
JB
63332009-04-16 Joel Brobecker <brobecker@adacore.com>
6334
6335 * ada-lang.c (symtab_for_sym): Delete.
6336 (user_select_syms): Use sym->symtab instead of calling symtab_for_sym.
6337
f9bc20b9
JB
63382009-04-16 Joel Brobecker <brobecker@adacore.com>
6339
6340 * ada-lang.c (extract_string): Delete.
6341 (ada_main_name): Reimplement using target_read_string instead of
6342 extract_string.
6343
335d71d6
AS
63442009-04-16 Andreas Schwab <schwab@linux-m68k.org>
6345
6346 * m68klinux-nat.c: Remove obsolete comment.
6347 (fetch_register, store_register): Don't call
6348 gdbarch_cannot_fetch_register or gdbarch_cannot_store_register,
6349 which are always nops here.
6350
732f6a93
TT
63512009-04-14 Tom Tromey <tromey@redhat.com>
6352
6353 * c-lang.c (c_emit_char): Use INTERMEDIATE_ENCODING.
6354 (c_printstr): Likewise.
6355 * charset.c: Include gdb_wait.h.
6356 (make_wchar_iterator): Use INTERMEDIATE_ENCODING.
6357 (find_charset_names): Use pexecute. Handle libiconv's output.
6358 Detect errors.
6359 (_initialize_charset): Use xstrdup.
6360 * gdb_wchar.h: Check HAVE_BTOWC. Split PHONY_ICONV and wchar
6361 cases.
6362 (INTERMEDIATE_ENCODING): New define.
6363 * configure, config.in: Rebuild.
6364 * configure.ac: Check for btowc.
6365
334cc82d
TT
63662009-04-15 Tom Tromey <tromey@redhat.com>
6367
6368 * c-lang.c (evaluate_subexp_c): Correctly handle EVAL_SKIP.
6369
27e3013d
EZ
63702009-04-15 Eli Zaretskii <eliz@gnu.org>
6371
6372 * utils.c (parse_escape): Initialize target_char to pacify GCC.
6373
8ea5dfdf
JK
63742009-04-14 Jan Kratochvil <jan.kratochvil@redhat.com>
6375
6376 * c-lang.c (c_get_string): Fix xfree crash on a failed string read.
6377
88c15c34
PM
63782009-04-14 Pierre Muller <muller@ics.u-strasbg.fr>
6379
6380 ARI fix: sprintf rule.
6381 * ada-exp.y (convert_char_literal): Replace sprintf by xsnprintf.
6382 * ada-lang.c (add_angle_brackets): Use xstrprintf.
6383 (ada_decode): Replace sprintf by xsnprintf.
6384 (find_old_style_renaming_symbol): Ditto.
6385 (ada_to_fixed_type_1, ada_enum_name): Ditto.
6386
6387
efbd6e75
JB
63882009-04-14 Joel Brobecker <brobecker@adacore.com>
6389
6390 * target.c (target_mourn_inferior): Call bfd_cache_close_all
6391 after having executed the target mourn_inferior routine.
6392
b46df7a1
EZ
63932009-04-14 Eli Zaretskii <eliz@gnu.org>
6394
6395 * config/djgpp/djconfig.sh (DEPDIR): Define to "_deps", if
6396 undefined.
6397
2facfe5c
DD
63982009-04-13 David Daney <ddaney@caviumnetworks.com>
6399
6400 * infrun.c (maybe_software_singlestep): New function.
6401 (resume): Call maybe_software_singlestep.
6402 (handle_inferior_event): Same.
6403
18e8c3bc
TT
64042009-04-13 Tom Tromey <tromey@redhat.com>
6405
6406 * python/python-frame.c (frapy_richcompare): Return
6407 Py_NotImplemented, not an error. Handle Py_NE as well.
6408
e726d784
EZ
64092009-04-13 Eli Zaretskii <eliz@gnu.org>
6410
6411 * charset.c (EILSEQ): Define if not defined by system headers.
6412
685af672
EZ
64132009-04-11 Eli Zaretskii <eliz@gnu.org>
6414
238f4807 6415 * config/djgpp/config.sed: Tweak ac_config_files in intl/configure
a2effb2e 6416 to be consistent with renaming config.intl.in into config_intl.in.
238f4807 6417
c03b3c32
EZ
6418 * go32-nat.c (go32_attach, go32_detach): Fix prototypes to be
6419 consistent with the change from 2008-11-09.
685af672 6420
c16abbde
JK
64212009-04-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6422
6423 * gdbtypes.c: Remove excessive parentheses at the return keywords.
2dbd25e5 6424 * varobj.c (varobj_invalidate): Fix indentation.
f4a34a08 6425 * varobj.c (varobj_invalidate): Fix formatting text width.
c16abbde 6426
143260c9
VP
64272009-04-08 Vladimir Prus <vladimir@codesourcery.com>
6428
6429 Implement -exec-jump.
6430
6431 * mi/mi-cmds.h (mi_cmd_exec_jump): Declare.
6432 * mi/mi-main.c (mi_cmd_exec_jump): New.
6433 * mi/mi-cmds.c (mi_cmds): Register exec-jump.
6434
d10c338d
DE
64352009-04-07 Doug Evans <dje@google.com>
6436
6437 * symfile.c (symbol_file_clear): Fix indentation.
6438
e5a6ba44
MK
64392009-04-06 Mark Kettenis <kettenis@gnu.org>
6440
6441 * sparc64nbsd-nat.c (sparc64nbsd_supply_pcb): Fix comment.
6442
409c383c
UW
64432009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
6444
6445 * ppc-linux-nat.c (ppc_linux_target_wordsize): New function.
6446 (ppc_linux_auxv_parse): New function.
6447 (ppc_linux_read_description): Use ppc_linux_target_wordsize.
6448 (_initialize_ppc_linux_nat): Install ppc_linux_auxv_parse.
6449
64502009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
9592c5d0
UW
6451
6452 * spu-linux-nat.c (spu_bfd_open): Set filename of in-memory
6453 BFD to contents of SPU name note.
6454 (spu_symbol_file_add_from_memory): Call symbol_file_add_from_bfd
6455 with "from_tty" argument 1 instead of 0.
6456
de40b933
JK
64572009-04-02 Jan Kratochvil <jan.kratochvil@redhat.com>
6458
6459 * dwarf2read.c
6460 (new_symbol <DW_TAG_variable> <!DW_AT_location> <DW_AT_external>):
6461 Create the symbol in local scope.
6462 * symtab.h (cu->list_in_scope <LOC_UNRESOLVED>): New comment part.
6463
6cbbcdfe
KS
64642009-04-02 Keith Seitz <keiths@redhat.com>
6465
6466 * stabsread.c (read_member_functions): GCC may emit an extra space
6467 at the end of the names "__base_ctor" and "__base_dtor"; so ignore
6468 whitespace when looking for these functions.
6469
476f7b68
JB
64702009-04-01 Joel Brobecker <brobecker@adacore.com>
6471
6472 Change the default value for "set print frame-arguments" to scalars.
6473
6474 * stack.c (print_frame_arguments): Set initial value to "scalars".
6475
865093a3
AR
64762009-04-01 Aleksandar Ristovski <aristovski@qnx.com>
6477
6478 * mips-tdep.c (mips_numeric_register_alieses): New definition.
cfd53605 6479 (mips_gdbarch_init): Add user registers from
865093a3
AR
6480 mips_numeric_register_aliases.
6481
5d3b6af6
JB
64822009-04-01 Joel Brobecker <brobecker@adacore.com>
6483
6484 * linux-nat.c (linux_nat_filter_event): Minor comment reformatting.
6485
9db03742
JB
64862009-04-01 Joel Brobecker <brobecker@adacore.com>
6487
6488 * linux-nat.c (linux_nat_filter_events): Do not delete the lwp if
6489 this is the last one.
6490
0d8f58ca
PA
64912009-04-01 Pedro Alves <pedro@codesourcery.com>
6492
6493 * remote.c (append_resumption): New.
6494 (remote_vcont_resume): Use it.
6495
1e2f1c5c
JB
64962009-04-01 Joel Brobecker <brobecker@adacore.com>
6497
6498 * windows-nat.c (+windows_get_ada_task_ptid): New function.
6499 (init_windows_ops): Set windows_ops.to_get_ada_task_ptid.
6500
71c25dea
TT
65012009-03-31 Daniel Jacobowitz <dan@codesourcery.com>
6502 Keith Seitz <keiths@redhat.com>
6503 Jan Kratochvil <jan.kratochvil@redhat.com>
6504
6505 PR gdb/6817
6506 * Makefile.in (dbxread.o): Update.
6507 * dbxread.c (read_dbx_symtab): Use cp_canonicalize_string.
6508 * dwarf2read.c (GDB_FORM_cached_string): New.
6509 (read_partial_die): Use dwarf2_canonicalize_name.
6510 (dwarf2_linkage_name): Use dwarf2_name.
6511 (dwarf2_canonicalize_name): New.
6512 (dwarf2_name): Use dwarf2_canonicalize_name.
6513 (dwarf_form_name, dump_die): Handle GDB_FORM_cached_string.
6514 * stabsread.c (define_symbol, read_type): Use cp_canonicalize_string.
6515 * symtab.c (lookup_symbol_in_language): Canonicalize input before
6516 searching.
6517 * cp-name-parser.y: operator() requires two parameters,
6518 according to libiberty.
6519 * minsyms.c (lookup_minimal_symbol): Canonicalize input
6520 before searching.
6521 * NEWS: Update.
6522
4a306c9a
JB
65232009-03-31 Joel Brobecker <brobecker@adacore.com>
6524
6525 Provide support for (Ada) task-specific breakpoints.
6526
6527 * ada-lang.h (ada_get_task_number): Add declaration.
6528 (breakpoint_ada_task_match): Delete declaration.
6529 * ada-tasks.c (ada_get_task_number): Make non-static.
6530 * breakpoint.h (struct breakpoint): Add field "task".
6531 * breakpoint.c (print_one_breakpoint_location): Add handling of
6532 task-specific breakpoints.
6533 (create_breakpoint, create_breakpoints, find_condition_and_thread):
6534 New parameter "task".
6535 (break_command_really): Update calls to find_condition_and_thread
6536 and create_breakpoints.
6537 (breakpoint_re_set_one): Update call to find_condition_and_thread.
6538 Set b->task.
6539
4a5a9917
JB
65402009-03-31 Joel Brobecker <brobecker@adacore.com>
6541
6542 * ada-tasks.c (short_task_info): Eliminate the "Running" task state.
6543
bad34192
PA
65442009-03-31 Pedro Alves <pedro@codesourcery.com>
6545
6546 * remote.c (remote_notice_new_inferior): Use ptid_is_pid. Check
6547 if the thread's ptid without a thread id field is in the list
6548 before calling thread_change_ptid.
6549 (extended_remote_attach_1): In non-stop mode, do not rely on
6550 querying the current thread, instead, query the thread list, and
6551 select the first thread of the process.
6552 * gdbthread.h (first_thread_of_process): Declare.
6553 * thread.c (first_thread_of_process): Define.
6554
1042e4c0
SS
65552009-03-30 Stan Shebs <stan@codesourcery.com>
6556
6557 Make tracepoints into a type of breakpoint.
6558 * breakpoint.h (enum bptype): Add bp_tracepoint.
6559 (struct breakpoint): Add fields step_count, pass_count, actions.
6560 (get_tracepoint, get_tracepoint_by_number): Declare.
6561 (all_tracepoints): Declare.
6562 * breakpoint.c: Include tracepoint.h, readline.h.
6563 (ALL_TRACEPOINTS): Move here from tracepoint.c.
6564 (tracepoint_count): Ditto.
6565 (should_be_inserted): GDB does not insert tracepoints itself.
6566 (print_it_typical): Add tracepoint case.
6567 (bpstat_what): Ditto.
6568 (print_one_breakpoint_location): Ditto, and add printing for
6569 pass count, step count, and action list.
6570 (user_settable_breakpoint): Add tracepoint case.
6571 (allocate_bp_location): Ditto.
6572 (set_breakpoint_location_function): Ditto.
6573 (disable_breakpoints_in_shlibs): Ditto.
6574 (mention): Ditto.
6575 (break_command_really): Add argument traceflag, use to choose
6576 basic breakpoint type.
6577 (break_command_1): Pass extra argument.
6578 (set_breakpoint, handle_gnu_v3_exceptions): Ditto.
6579 (breakpoint_re_set_one): Add tracepoint case.
6580 (disable_command, enable_command): Ditto.
6581 (set_tracepoint_count): Move here from tracepoint.c.
6582 (trace_command): Move here from tracepoint.c and use
6583 break_command_really.
6584 (tracepoints_info): Move here from tracepoint.c and call
6585 breakpoints_info.
6586 (enable_trace_command): Move here from tracepoint.c and call
6587 enable_command.
6588 (disable_trace_command): Move here from tracepoint.c and call
6589 disable_command.
6590 (delete_trace_command): Move here from tracepoint.c and call
6591 delete_breakpoint.
6592 (trace_pass_command): Move here from tracepoint.c.
6593 (get_tracepoint_by_number): Ditto.
6594 (tracepoint_save_command): Ditto.
6595 (get_tracepoint): New function.
6596 (all_tracepoints): New function.
6597 (_initialize_breakpoint): Move tracepoint init from tracepoint.c,
6598 deprecate "enable trace" and "disable trace" commands.
6599 * tracepoint.h (struct tracepoint): Remove.
6600 (tracepoint_chain): Remove decl.
6601 (deprecated_create_tracepoint_hook): Remove decl.
6602 (deprecated_delete_tracepoint_hook): Remove decl.
6603 (deprecated_modify_tracepoint_hook): Remove decl.
6604 (ALL_TRACEPOINTS, ALL_TRACEPOINTS_SAFE): Remove.
6605 (free_actions): Update signature.
6606 (validate_actionline): Update signature.
6607 (end_actions_pseudocommand): Declare.
6608 (while_stepping_pseudocommand): Declare.
6609 * tracepoint.c: Include breakpoint.h.
6610 (tracepoint_chain, tracepoint_count): Remove.
6611 (free_actions, make_cleanup_free_actions): Update signature.
6612 (trace_command, set_raw_tracepoint): Remove.
6613 (trace_mention): Remove.
6614 (tracepoints_info): Remove.
6615 (tracepoint_operation, map_args_over_tracepoints): Remove.
6616 (get_tracepoint_by_number): Remove.
6617 (enable_trace_command, disable_trace_command): Remove.
6618 (delete_trace_command, trace_pass_command): Remove.
6619 (trace_actions_command, read_actions): Update signature.
6620 (validate_actionline): Update signature, use bp loc.
6621 (encode_actions): Ditto.
6622 (download_tracepoint): New function, body of trace_start_command.
6623 (trace_start_command): Call it, use all_tracepoints.
6624 (tracepoint_save_command): Remove.
6625 (tracepoint_dump_command): Use get_tracepoint.
6626 (end_actions_pseudocommand): Make globally visible.
6627 (while_stepping_pseudocommand): Ditto.
6628 (_initialize_tracepoint): Move command definitions to breakpoint.c.
6629
f8f6f20b
TJB
66302009-03-30 Thiago Jung Bauermann <bauerman@br.ibm.com>
6631
6632 Expose frames to Python.
6633 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-frame.o.
6634 (SUBDIR_PYTHON_SRCS): Add python-frame.c.
6635 (python-frame.o): New target.
6636 * python/python-frame.c: New file.
6637 * python/python-internal.h (gdbpy_frames, gdbpy_newest_frame,
6638 gdbpy_frame_stop_reason_string, gdbpy_selected_frame,
6639 gdbpy_initialize_frames): New prototypes.
6640 * python/python.c (_initialize_python): Call gdbpy_initialize_frames.
6641 (GdbMethods): Add `selected_frame' and `frame_stop_reason_string'
6642 entries.
6643 * stack.c (find_frame_funname): New function, factored out of
6644 print_frame.
6645 (print_frame): Call find_frame_funname.
6646 * stack.h (find_frame_funname): Add prototype.
6647
77316f4c
TJB
66482009-03-29 Thiago Jung Bauermann <bauerman@br.ibm.com>
6649
6650 Remove unused value_object attribute `owned_by_gdb'.
6651 * python/python-value.c (value_object): Remove owned_by_gdb
6652 attribute.
6653 (valpy_dealloc): Remove reference to self->owned_by_gdb.
6654 (valpy_new): Likewise.
6655 (value_to_value_object): Likewise.
6656
c0c6f777
TJB
66572009-03-29 Thiago Jung Bauermann <bauerman@br.ibm.com>
6658
6659 Change gdb.Value.address from a method to an attribute.
6660 * python/python-value.c (value_object): Add `address' element.
6661 (valpy_dealloc): Decrement reference to self->address if set.
6662 (valpy_new): Initialize val_obj->address.
6663 (valpy_address): Rename to ...
6664 (valpy_get_address): ... this. Change signature from method to
6665 attribute. Update self->address if not set.
6666 (value_to_value_object): Initialize val_obj->address.
6667 (value_object_getset): Add `address' element.
6668 (value_object_methods): Remove `address' element.
6669
c2c8d75b
AS
66702009-03-29 Andreas Schwab <schwab@linux-m68k.org>
6671
6672 * observer.sh: Set LANG/LC_ALL to C, not c.
6673
1b31f75d
KB
66742009-03-28 Kevin Buettner <kevinb@redhat.com>
6675
6676 * mn10300-tdep.c (mn10300_gdbarch_init): For mn10300, by default,
6677 `char' is unsigned.
6678
f91d3df5
PA
66792009-03-28 Pedro Alves <pedro@codesourcery.com>
6680
6681 * remote.c (remote_stop_ns): If multi-process extensions are off,
6682 and GDB is requesting the whole process to stop, sent "vCont;t",
6683 not "vCont;t:-1"
6684
7b0e8051
PA
66852009-03-28 Pedro Alves <pedro@codesourcery.com>
6686
6687 * inf-loop.c (inferior_event_handler): Avoid calling is_running on
6688 null inferior_ptid.
6689
5362e076
EZ
66902009-03-27 Eli Zaretskii <eliz@gnu.org>
6691
6692 * config/djgpp/fnchange.lst: Update to fix ARI-reported problems.
6693
88fc996f
DE
66942009-03-26 Doug Evans <dje@google.com>
6695
6696 * thread.c (do_restore_current_thread_cleanup): Redo test for
6697 whether to restore old->inferior_ptid.
6698
56ef84b1
TT
66992009-03-26 Tom Tromey <tromey@redhat.com>
6700
6701 * breakpoint.c (resolve_sal_pc): Preserve original line number
6702 when skipping prologue.
6703
a5321aa4
DE
67042009-03-26 Doug Evans <dje@google.com>
6705
6706 * thread.c (inferior_thread) Remove "extern" in definition.
6707
def2b000
TJB
67082009-03-26 Thiago Jung Bauermann <bauerman@br.ibm.com>
6709
6710 Add gdb.Value.is_optimized_out attribute.
6711 * python/python-value.c (valpy_get_is_optimized_out): New
6712 function.
6713 (value_object_getset): New variable.
6714 (value_object_type): Initialize tp_getset element.
6715
442ddf59
JK
67162009-03-26 Joel Brobecker <brobecker@adacore.com>
6717
6718 Recognize missing DW_AT_location as <value optimized out>.
6719 * dwarf2read.c
6720 (new_symbol <DW_TAG_variable> <!DW_AT_location> <!DW_AT_external>):
6721 Call add_symbol_to_list.
6722
78485d59
TT
67232009-03-25 Tom Tromey <tromey@redhat.com>
6724
6725 * gdbtypes.h (CHECK_TYPEDEF): Don't yield a value.
6726 * stack.c (print_this_frame_argument_p): Use check_typedef.
6727
94ae1714
TT
67282009-03-25 Tom Tromey <tromey@redhat.com>
6729
6730 * configure: Rebuild.
6731 * acinclude.m4 (AM_ICONV): Set am_cv_use_build_libiconv.
6732 Rearrange flags setting. Add comments.
6733
2bc57ae3
PM
67342009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
6735
6736 * config/i386/nm-i386.h: Remove code within
6737 I386_WATCHPOINTS_IN_TARGET_VECTOR conditional.
6738 * config/i386/nm-cygwin.h: Remove I386_WATCHPOINTS_IN_TARGET_VECTOR
6739 macro.
6740 * config/i386/nm-cygwin64.h: Ditto.
6741 * config/i386/nm-fbsd.h: Ditto.
6742 * config/i386/nm-go32.h: Ditto.
6743 * config/i386/nm-linux.h: Ditto.
6744 * config/i386/nm-linux64.h: Ditto.
6745
549ba0f8
PM
67462009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
6747
6748 ARI fix: "xasprintf" rule.
6749 * printcmd.c (sym_info): Replace xasprintf by xstrprintf.
6750
68c97600
PA
67512009-03-25 Pedro Alves <pedro@codesourcery.com>
6752
6753 * remote.c (remote_start_remote): In non-stop mode, call
6754 init_wait_for_inferior before adding threads and inferiors.
6755
a6f1cd96
JB
67562009-03-25 Joel Brobecker <brobecker@adacore.com>
6757
6758 * breakpoint.c (breakpoint_thread_match): Split a large condition
6759 into several smaller conditions. No behavior change.
6760
dbfb4bc7 67612009-03-25 Pedro Alves <pedro@codesourcery.com>
a07daef3
PA
6762
6763 * infrun.c (infrun_thread_thread_exit): New.
6764 (_initialize_infrun): Attach it to the thread_exit observer.
6765 * thread.c (delete_thread_1): Always call the observer, passing it
6766 the silent flag.
6767 * mi/mi-interp.c (mi_thread_exit): Add "silent" parameter. If
6768 SILENT, return immediately.
6769
d729566a
PA
67702009-03-25 Pedro Alves <pedro@codesourcery.com>
6771
6772 * infrun.c (normal_stop): Use has_stack_frames instead of
6773 target_has_stack.
6774 * mi/mi-main.c (mi_execute_command): Avoid calling inferior_thread
6775 when there is no thread selected.
6776 (mi_cmd_execute): Don't special case commands that can run without
6777 a valid selected thread.
6778 * top.c (execute_command): Don't special case commands that can
6779 run without a valid selected thread. Use has_stack_frames.
6780 * infcmd.c (ensure_valid_thread): New.
6781 (continue_1, step_1, jump_command, signal_command): Use it.
6782 (detach_command): Error out if there's no selected thread/inferior.
6783 * thread.c (print_thread_info): Allow having no thread selected.
6784 (switch_to_thread): Don't read the PC if there is no current thread.
6785 (do_restore_current_thread_cleanup): Don't record the current
6786 frame if there is no current thread.
6787 (make_cleanup_restore_current_thread): Don't read frame info if
6788 there is no selected thread.
6789 (_initialize_thread): Don't mark commands as
6790 "no_selected_thread_ok".
6791 * frame.c (get_current_frame): Error out if there is no valid
6792 selected thread.
6793 (has_stack_frames): Return false if there is no valid
6794 selected thread.
6795 * cli/cli-cmds.c (init_cli_cmds): Don't mark commands as
6796 "no_selected_thread_ok".
6797 * cli/cli-decode.c (set_cmd_no_selected_thread_ok)
6798 (get_cmd_no_selected_thread_ok): Delete.
6799 * cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): Delete.
6800 (set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
6801 Delete declaration.
6802 * stack.c (get_selected_block): Use has_stack_frames.
6803
f04c6d38
TJB
68042009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
6805
6806 Fix size of FPSCR in Power 7 processors.
6807 * ppc-linux-nat.c (PPC_FEATURE_ARCH_2_05): Remove #define.
6808 (PPC_FEATURE_HAS_DFP): New #define.
6809 (ppc_linux_read_description): Check for DFP feature instead of
6810 ISA 2.05 to decide on size of the FPSCR.
6811
6c02c64c
KB
68122009-03-25 Kevin Buettner <kevinb@redhat.com>
6813
6814 * mn10300-tdep.c (trad-frame.h): Don't include.
6815 (prologue-value.h): Include.
6816 (mn10300_frame_unwind_cache, set_reg_offsets): Delete.
6817 (struct mn10300_prologue): Define.
6818 (push_reg, translate_rreg, check_for_saved): New functions.
6819 (mn10300_analyze_prologue): Rewrite, using prologue-value
6820 machinery. Handle more instructions than before. Permit
6821 instructions to occur in any order.
6822 (mn10300_skip_prologue): Find the extents of the function
6823 in question; mn10300_analyze_prologue no longer does this.
6824 (mn10300_analyze_frame_prologue): New function.
6825 (mn10300_frame_base): New function.
6826 (mn10300_frame_this_id): Rewrite, no longer using trad-frame
6827 implementation.
6828 (mn10300_frame_prev_register): Likewise.
6829 (mn10300_frame_base_address, mn10300_frame_base struct): Delete.
6830 (mn10300_unwind_pc, mn10300_unwind_sp): Rename `next_frame' to
6831 `this_frame'.
6832 (mn10300_frame_unwind_init): Don't call frame_base_set_default().
6833
67c296a2
PM
68342009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
6835
6836 Fix completer problem for filename completion on the first try.
6837
6838 * gdb/completer.h (gdb_completion_word_break_characters): New function.
6839 * gdb/completer.c: Include gdb_assert.h.
6840 (complete_line_internal_reason): New enum.
6841 (complete_line_internal): Change last argument type to
6842 complete_line_internal_reason.
6843 Modify function to handle the different complete_line_internal_reason
6844 argument values.
6845 (complete_line): Adapt to change in complete_line_internal.
6846 (command_completer): Ditto.
6847 (gdb_completion_word_break_characters): Implement new function.
6848 * top.c (init_main): Set rl_completion_word_break_hook to
6849 gdb_completion_word_break_characters.
c2c8d75b 6850
67c296a2 6851
1a6d2f2f
PM
68522009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
6853
6854 ARI fix: "strlen d_name" rule.
6855 * linux-nat.c (linux_nat_xfer_osdata): Use NAMELEN macro.
6856
6857
fc3b640d
TT
68582009-03-24 Tom Tromey <tromey@redhat.com>
6859 Pedro Alves <pedro@codesourcery.com>
6860
6861 * configure, config.in: Rebuild.
6862 * configure.ac: Check for libiconvlist.
6863 * charset.c: Check HAVE_LIBICONVLIST.
6864 * acinclude.m4 (AM_ICONV): Don't subst LIBICONV, LIBICONV_INCLUDE,
6865 LIBICONV_LIBDIR. Update CPPFLAGS and LIBS.
6866 * Makefile.in (LIBICONV, LIBICONV_INCLUDE, LIBICONV_LIBDIR):
6867 Remove.
6868 (INTERNAL_CFLAGS_BASE): Update.
6869 (INTERNAL_LDFLAGS): Update.
6870 (CLIBS): Update.
6871
76a39ba7
JK
68722009-03-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6873
6874 * configure.ac: Initialize the variable $PREFER_CURSES.
6875 * configure: Regenerated.
6876
bd8a8e1b
JK
68772009-03-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6878
6879 * configure.ac: Enable $PREFER_CURSES even with default $ENABLE_TUI.
6880 * configure: Regenerated.
6881
a3224241
PM
68822009-03-24 Pierre Muller <muller@ics.u-strasbg.fr>
6883
6884 ARI fix: "strerror" rule.
6885 * darwin-nat.c (darwin_ptrace): Use safe_strerror.
6886 (darwin_stop_inferior, darwin_attach, darwin_detach): Ditto.
6887
6cdd57f4
JB
68882009-03-23 Joel Brobecker <brobecker@adacore.com>
6889
6890 * ada-exp.y (get_symbol_field_type): Make sure to resolve typedefs
6891 before looking up the fields inside our struct type.
6892
17466c1a
JB
68932009-03-23 Joel Brobecker <brobecker@adacore.com>
6894
6895 * ada-lang.c (resolve_subexp) [UNOP_QUAL]: Resolve typedefs before
6896 trying to resolve the type qualification.
6897
8008e265
JB
68982009-03-23 Joel Brobecker <brobecker@adacore.com>
6899
6900 * ada-lang.c (ada_evaluate_subexp) [UNOP_IN_RANGE]: make sure
6901 we try to apply the attribute on the real type, rather than
6902 its associated typedef.
6903
31dedfee
JB
69042009-03-23 Joel Brobecker <brobecker@adacore.com>
6905
6906 * ada-lang.c (ada_evaluate_subexp) [OP_ATR_MODULUS]: Use check_typdef
6907 to make sure we try to get the modulus of the actual type, not the
6908 associated typedef.
6909
5bc23cb3
JB
69102009-03-23 Joel Brobecker <brobecker@adacore.com>
6911
6912 * ada-lang.c (ada_evaluate_subexp): [OP_ATR_FIRST, OP_ATR_LAST]
6913 [OP_ATR_LENGTH]: When using the attribute on a type, make sure
6914 to get the real type, not the associated typedef.
6915
872c8b51
JB
69162009-03-23 Joel Brobecker <brobecker@adacore.com>
6917
6918 * ada-lang.c (ada_get_field_index): Add handling of the case
6919 when TYPE is a typedef of a struct.
6920
dcb626be
JB
69212009-03-23 Joel Brobecker <brobecker@adacore.com>
6922
e0cfd8e3 6923 Add gdb_usleep as a portable version of usleep based on gdb_select.
dcb626be
JB
6924 * gdb_usleep.h, gdb_usleep.c: New files.
6925 * Makefile.in (SFILES): Add gdb_usleep.c.
6926 (HFILES_NO_SRCDIR): Add gdb_usleep.h.
6927 (COMMON_OBS): Add gdb_usleep.o.
6928 * ser-unix.c (hardwire_send_break): Replace call to gdb_select
6929 by call to gdb_usleep.
6930
24be086d
JB
69312009-03-23 Joel Brobecker <brobecker@adacore.com>
6932
6933 * buildsym.c (end_symtab): If we ignore the subfiles, then
6934 unlink the associated symtabs if they were already allocated.
6935
cb01cfba
JB
69362009-03-23 Jerome Guitton <guitton@adacore.com>
6937
6938 Provide a way to force building of GDB with libcurses.
6939 * configure.ac: Add --with-curses.
6940 * configure: Regenerated.
6941
9c482037
TT
69422009-03-23 Tom Tromey <tromey@redhat.com>
6943
6944 * dwarf2expr.c (execute_stack_op) <DW_OP_GNU_uninit>: Fix typo in
6945 error message.
6946
e2dd7057
PP
69472009-03-23 Paul Pluzhnikov <ppluzhnikov@google.com>
6948
6949 * breakpoint.c (disable_breakpoints_in_unloaded_shlib): Use
6950 solib_contains_address_p instead of searching.
c2c8d75b 6951
0dd7fb99
TT
69522009-03-23 Tom Tromey <tromey@redhat.com>
6953
6954 * charset.c (ICONV_CONST) <PHONY_ICONV>: Define.
6955 (iconv): Make 'inbuf' argument const.
6956 (convert_between_encodings): Use ICONV_CONST.
6957 (wchar_iterate): Likewise.
6958
418c6cb3
CF
69592009-03-22 Christopher Faylor <me+cygwin@cgf.cx>
6960
6961 * windows-nat.c (AdjustTokenPrivileges): Implement macro wraparound for
6962 dynamically loaded function.
6963 (LookupPrivilegeValueA): Ditto.
6964 (OpenProcessToken): Ditto.
6965 (AdjustTokenPrivileges): Rename and define placeholder for address of
c2c8d75b 6966 dynamically loaded function.
418c6cb3
CF
6967 (LookupPrivilegeValueA): Ditto.
6968 (OpenProcessToken): Ditto.
6969 (set_process_privilege): Remove check for loaded functions.
6970 (bad_OpenProcessToken): Define.
6971 (_initialize_loadable): Load token functions from advapi here, setting
6972 OpenProcessToken function to a dummy static function which always return
6973 error if OS doesn't support this functionality.
6974
695de547
CF
69752009-03-22 Nicolas Roche <roche@adacore.com>
6976 Christopher Faylor <me+cygwin@cgf.cx>
6977
6978 * win32-nat.c (ctrl_c_handler): New function.
6979 (win32_wait): Register ctrl_c_handler as Ctrl-C handler if the inferior
6980 is run in a separate console.
6981
2b008701
CF
69822009-03-22 Christopher Faylor <me+cygwin@cgf.cx>
6983
6984 * windows-nat.c (DebugActiveProcessStop): Implement macro wraparound
6985 for dynamically loaded function.
6986 (DebugBreakProcess): Ditto.
6987 (DebugSetProcessKillOnExit): Ditto.
6988 (EnumProcessModules): Ditto.
6989 (GetModuleFileNameExA): Ditto.
6990 (GetModuleInformation): Ditto.
6991 (DebugActiveProcessStop): Rename and define placeholder for address of
418c6cb3 6992 dynamically loaded function.
2b008701
CF
6993 (DebugBreakProcess): Ditto.
6994 (DebugSetProcessKillOnExit): Ditto.
6995 (EnumProcessModules): Ditto.
6996 (GetModuleFileNameExA): Ditto.
6997 (GetModuleInformation): Ditto.
6998 (psapi_loaded): Delete.
6999 (get_module_name): Don't check psapi_loaded, just rely on the fact that
7000 dynamically loaded functions will return failure if they weren't
7001 previously found.
7002 (has_detach_ability): Delete.
7003 (windows_attach): Remove call to has_detach_ability (). Just rely on
7004 functions being callable.
7005 (bad_DebugActiveProcessStop): Define.
7006 (bad_DebugBreakProcess): Ditto.
7007 (bad_DebugSetProcessKillOnExit): Ditto.
7008 (bad_EnumProcessModules): Ditto.
7009 (bad_GetModuleFileNameExA): Ditto.
7010 (bad_GetModuleInformation): Ditto.
7011 (_initialize_loadable): Rename from _initialize_psapi. Initialize all
7012 dynamic storage here, setting nonexistent functions to dummy static
7013 functions which always return error.
7014
f3b1572e
PA
70152009-03-22 Pedro Alves <pedro@codesourcery.com>
7016
7017 * mi/mi-interp.c (mi_interpreter_init): Attach mi_about_to_proceed
7018 to the about_to_proceed observer notification.
7019 (mi_about_to_proceed): New.
7020 (mi_on_resume): Only output ^running and the prompt here if the
7021 target was proceeded.
7022 * breakpoint.c (breakpoint_proceeded): New static.
7023 (breakpoint_about_to_proceed): New.
7024 (_initialize_breakpoints): Attach breakpoint_about_to_proceed to
7025 the about_to_proceed observer notification.
7026 * inferior.h (breakpoint_proceeded): Delete declaration.
7027 * infrun.c (clear_proceed_status): Don't set breakpoint_proceeded.
7028 Notify the about_to_proceed observers.
7029 (struct inferior_status): Delete breakpoint_proceeded member.
7030 (save_inferior_status): Don't save it.
7031 (restore_inferior_status): Don't restore it.
7032 * mi-main.h (mi_proceeded): Declare.
7033 * mi/mi-main.c (mi_cmd_execute): Clear mi_proceeded before running
7034 a command.
7035
c5a4d20b
PA
70362009-03-22 Pedro Alves <pedro@codesourcery.com>
7037
7038 * gdbthread.h (struct thread_info): Add in_infcall member.
7039 * infcall.c (run_inferior_call): Save, set and restore in_infcall.
7040 Remove reverences to suppress_resume_observer. Refresh
7041 `call_thread' after returning from `proceed'.
7042 * infcmd.c (suppress_resume_observer): Delete.
7043 * inferior.h (suppress_resume_observer): Delete declaration.
7044 * mi/mi-interp.c (mi_on_resume): Suppress output while calling an
7045 inferior function.
7046 * thread.c (set_running): Remove references to
7047 suppress_resume_observer.
7048 * infrun.c (struct inferior_status): Add in_infcall member.
7049 (save_inferior_status): Save it.
7050 (restore_inferior_status): Restore it.
7051
41d2bdb4
PA
70522009-03-22 Pedro Alves <pedro@codesourcery.com>
7053
7054 * infcall.c (run_inferior_call): Remove references to
7055 suppress_stop_observer.
7056 * infcmd.c (suppress_stop_observer): Delete.
7057 (finish_command_continuation): Remove NOTE. Don't clear
7058 suppress_stop_observer anymore.
7059 (finish_command_continuation_free_arg): Likewise.
7060 (finish_forward): Remove references to suppress_stop_observer.
7061 Call normal_stop observer if we haven't already.
7062 * inferior.h (suppress_stop_observer): Delete.
7063 * infrun.c (normal_stop): When deciding to suppress the
7064 normal_stop observer, check for proceed_to_finish instead of
7065 suppress_stop_observer.
7066
065a2c74
PA
70672009-03-22 Pedro Alves <pedro@codesourcery.com>
7068
7069 * symfile.c (symfile_relocate_debug_section): Remove check for
7070 SEC_DEBUGGING.
7071
cc924cad
TJB
70722009-03-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7073 Jim Blandy <jimb@red-bean.com>
7074 Thiago Jung Bauermann <bauerman@br.ibm.com>
7075 Tom Tromey <tromey@redhat.com>
7076
7077 Miscellaneous fixes to the Python code.
7078 * python/python-cmd.c (cmdpy_init): Accept keyword
7079 arguments.
7080 * python/python-value.c (valpy_string): Accept keyword
7081 arguments.
7082 (valpy_binop): Use `break' to exit from the TRY_CATCH block.
7083 Do not call value_to_value_object on NULL RES_VAL.
7084 (value_object_methods): Change `string' entry to also accept
7085 keyword arguments.
7086 (convert_value_from_python): Return a copy of the value if obj is
7087 a gdb.Value object.
7088 (value_object_methods): Mark the `string' method as accepting
7089 keywords, and show method "prototype" in the doc string.
7090 * python/python.c (get_parameter): Don't return inside a
7091 TRY_CATCH.
7092
bc3b79fd
TJB
70932009-03-20 Tom Tromey <tromey@redhat.com>
7094
7095 Add support for convenience functions in Python.
7096 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-function.o.
7097 (SUBDIR_PYTHON_SRCS): Add python-function.c.
7098 (python-function.o): New target.
7099 * eval.c: Include "python/python.h" and <ctype.h>.
7100 (evaluate_subexp_standard): Handle values of type
7101 TYPE_CODE_INTERNAL_FUNCTION.
7102 * gdbtypes.h (type_code): Add TYPE_CODE_INTERNAL_FUNCTION.
7103 * parse.c (write_exp_string): Remove duplicate word in comment.
7104 * python/python-function.c: New file.
7105 * python/python-internal.h (gdbpy_initialize_functions): Add
7106 prototype.
7107 * python/python.c (_initialize_python): Call
7108 gdbpy_initialize_functions.
7109 * valprint.c (value_check_printable): Handle values of type
7110 TYPE_CODE_INTERNAL_FUNCTION.
7111 * value.c: Include "cli/cli-decode.h".
7112 (internal_function): New struct.
7113 (functionlist, internal_fn_type): New static variables.
7114 (lookup_only_internalvar,
7115 lookup_internalvar): Add const qualifier to name argument.
7116 (create_internalvar): Likewise. Initialize new field.
7117 (set_internal_var): Fix typo in comment. Don't allow assignment
7118 to canonical variable.
7119 (value_create_internal_function, value_internal_function_name,
7120 call_internal_function, function_command, function_destroyer,
7121 add_internal_function): New functions.
7122 (_initialize_values): Create `function' placeholder command.
7123 Initialize internal_fn_type.
7124 * value.h (lookup_only_internalvar, create_internalvar,
7125 lookup_internalvar): Add const qualifier to name argument.
7126 (internal_function_fn, add_internal_function, call_internal_function,
7127 value_internal_function_name): Add prototypes.
7128 (struct internalvar) <canonical>: New field.
7129
546e879e
TT
71302009-03-20 Tom Tromey <tromey@redhat.com>
7131
7132 * c-lang.c (evaluate_subexp_c): Call check_typedef.
7133
6c7a06a3
TT
71342009-03-20 Tom Tromey <tromey@redhat.com>
7135 Julian Brown <julian@codesourcery.com>
7136
7137 PR i18n/7220, PR i18n/7821, PR exp/8815, PR exp/9103,
7138 PR i18n/9401, PR exp/9613:
7139 * NEWS: Update
7140 * value.h (value_typed_string): Declare.
7141 (val_print_string): Update.
7142 * valprint.h (print_char_chars): Update.
7143 * valprint.c (print_char_chars): Add type argument. Update.
7144 (val_print_string): Likewise.
7145 * valops.c (value_typed_string): New function.
7146 * utils.c (host_char_to_target): New function.
7147 (parse_escape): Use host_char_to_target, host_hex_value. Update.
7148 Remove '^' case.
7149 (no_control_char_error): Remove.
7150 * typeprint.c (print_type_scalar): Update.
7151 * scm-valprint.c (scm_scmval_print): Update.
7152 * scm-lang.h (scm_printchar, scm_printstr): Update.
7153 * scm-lang.c (scm_printchar): Add type argument.
7154 (scm_printstr): Likewise.
7155 * printcmd.c (print_formatted): Update.
7156 (print_scalar_formatted): Update.
7157 (printf_command) <wide_string_arg, wide_char_arg>: New constants.
7158 Handle '%lc' and '%ls'.
7159 * parser-defs.h (struct typed_stoken): New type.
7160 (struct stoken_vector): Likewise.
7161 (write_exp_string_vector): Declare.
7162 * parse.c (write_exp_string_vector): New function.
7163 * p-valprint.c (pascal_val_print): Update.
7164 * p-lang.h (is_pascal_string_type, pascal_printchar,
7165 pascal_printstr): Update.
7166 * p-lang.c (is_pascal_string_type): Remove 'char_size' argument.
7167 Add 'char_type' argument.
7168 (pascal_emit_char): Add type argument.
7169 (pascal_printchar): Likewise.
7170 (pascal_printstr): Likewise.
7171 * objc-lang.c (objc_emit_char): Add type argument.
7172 (objc_printchar): Likewise.
7173 (objc_printstr): Likewise.
7174 * macroexp.c (get_character_constant): Handle unicode characters.
7175 Use c_parse_escape.
7176 (get_string_literal): Handle unicode strings. Use
7177 c_parse_escape.
7178 * m2-valprint.c (print_unpacked_pointer): Update.
7179 (m2_print_array_contents): Update.
7180 (m2_val_print): Update.
7181 * m2-lang.c (m2_emit_char): Add type argument.
7182 (m2_printchar): Likewise.
7183 (m2_printstr): Likewise.
7184 * language.h (struct language_defn) <la_printchar>: Add type
7185 argument.
7186 <la_printstr, la_emitchar>: Likewise.
7187 (LA_PRINT_CHAR): Likewise.
7188 (LA_PRINT_STRING): Likewise.
7189 (LA_EMIT_CHAR): Likewise.
7190 * language.c (unk_lang_emit_char): Add type argument.
7191 (unk_lang_printchar): Likewise.
7192 (unk_lang_printstr): Likewise.
7193 * jv-valprint.c (java_val_print): Update.
7194 * jv-lang.c (java_emit_char): Add type argument.
7195 * f-valprint.c (f_val_print): Update.
7196 * f-lang.c (f_emit_char): Add type argument.
7197 (f_printchar): Likewise.
7198 (f_printstr): Likewise.
7199 * expprint.c (print_subexp_standard): Update.
7200 * charset.h (target_wide_charset): Declare.
7201 (c_target_char_has_backslash_escape, c_parse_backslash,
7202 host_char_print_literally, host_char_to_target,
7203 target_char_to_host, target_char_to_control_char): Remove.
7204 (enum transliterations): New type.
7205 (convert_between_encodings): Declare.
7206 (HOST_ESCAPE_CHAR): New define.
7207 (host_letter_to_control_character, host_hex_value): Declare.
7208 (enum wchar_iterate_result): New enum.
7209 (struct wchar_iterator): Declare.
7210 (make_wchar_iterator, make_cleanup_wchar_iterator, wchar_iterator,
7211 wchar_push_back): Declare.
7212 * charset-list.h: New file.
7213 * c-valprint.c (textual_name): New function.
7214 (textual_element_type): Handle wide character types.
7215 (c_val_print): Pass original type to textual_element_type. Handle
7216 wide character types.
7217 (c_value_print): Use textual_element_type. Pass original type of
7218 value to val_print.
7219 * c-lang.h (enum c_string_type): New type.
7220 (c_printchar, c_printstr): Update.
7221 * c-lang.c (classify_type): New function.
7222 (print_wchar): Likewise.
7223 (c_emit_char): Add type argument. Handle wide characters.
7224 (c_printchar): Likewise.
7225 (c_printstr): Add type argument. Handle wide and multibyte
7226 character sets.
7227 (convert_ucn): New function.
7228 (emit_numeric_character): Likewise.
7229 (convert_octal): Likewise.
7230 (convert_hex): Likewise.
7231 (ADVANCE): New macro.
7232 (convert_escape): New function.
7233 (parse_one_string): Likewise.
7234 (evaluate_subexp_c): Likewise.
7235 (exp_descriptor_c): New global.
7236 (c_language_defn): Use exp_descriptor_c.
7237 (cplus_language_defn): Likewise.
7238 (asm_language_defn): Likewise.
7239 (minimal_language_defn): Likewise.
7240 (charset_for_string_type): New function.
7241 * c-exp.y (%union): Add 'svec' and 'tsval'.
7242 (CHAR): New token.
7243 (exp): Add CHAR production.
7244 (string_exp): Rewrite.
7245 (exp) <string_exp>: Rewrite.
7246 (tempbuf): Now global.
7247 (tempbuf_init): New global.
7248 (parse_string_or_char): New function.
7249 (yylex) <tempbuf>: Now global.
7250 <tokptr, tempbufindex, tempbufsize, token_string, class_prefix>:
7251 Remove.
7252 Handle 'u', 'U', and 'L' prefixes. Call parse_string_or_char.
7253 (c_parse_escape): New function.
7254 * auxv.c (fprint_target_auxv): Update.
7255 * ada-valprint.c (ada_emit_char): Add type argument.
7256 (ada_printchar): Likewise.
7257 (ada_print_scalar): Update.
7258 (printstr): Add type argument. Update calls to ada_emit_char.
7259 (ada_printstr): Add type argument.
7260 (ada_val_print_array): Update.
7261 (ada_val_print_1): Likewise.
7262 * ada-lang.c (emit_char): Add type argument.
7263 * ada-lang.h (ada_emit_char, ada_printchar, ada_printstr): Add
7264 type arguments.
7265 * gdb_locale.h: Include langinfo.h.
7266 * charset.c (_initialize_charset): Set default host charset from
7267 the locale. Don't register charsets. Add target-wide-charset
7268 commands. Call find_charset_names.
7269 (struct charset, struct translation): Remove.
7270 (GDB_DEFAULT_HOST_CHARSET): Remove.
7271 (GDB_DEFAULT_TARGET_WIDE_CHARSET): New define.
7272 (target_wide_charset_name): New global.
7273 (show_host_charset_name): Handle "auto".
7274 (show_target_wide_charset_name): New function.
7275 (host_charset_enum, target_charset_enum): Remove.
7276 (charset_enum): New global.
7277 (all_charsets, register_charset, lookup_charset, all_translations,
7278 register_translation, lookup_translation): Remove.
7279 (simple_charset, ascii_print_literally, ascii_to_control): Remove.
7280 (iso_8859_print_literally, iso_8859_to_control,
7281 iso_8859_family_charset): Remove.
7282 (ebcdic_print_literally, ebcdic_to_control,
7283 ebcdic_family_charset): Remove.
7284 (struct cached_iconv, check_iconv_cache, cached_iconv_convert,
7285 register_iconv_charsets): Remove.
7286 (target_wide_charset_be_name, target_wide_charset_le_name): New
7287 globals.
7288 (identity_either_char_to_other): Remove.
7289 (set_be_le_names, validate): New functions.
7290 (backslashable, backslashed, represented): Remove.
7291 (default_c_target_char_has_backslash_escape): Remove.
7292 (default_c_parse_backslash, iconv_convert): Remove.
7293 (ascii_to_iso_8859_1_table, ascii_to_ebcdic_us_table,
7294 ascii_to_ibm1047_table, iso_8859_1_to_ascii_table,
7295 iso_8859_1_to_ebcdic_us_table, iso_8859_1_to_ibm1047_table,
7296 ebcdic_us_to_ascii_table, ebcdic_us_to_iso_8859_1_table,
7297 ebcdic_us_to_ibm1047_table, ibm1047_to_ascii_table,
7298 ibm1047_to_iso_8859_1_table, ibm1047_to_ebcdic_us_table): Remove.
7299 (table_convert_char, table_translation, simple_table_translation):
7300 Remove.
7301 (current_host_charset, current_target_charset,
7302 c_target_char_has_backslash_escape_func,
7303 c_target_char_has_backslash_escape_baton): Remove.
7304 (c_parse_backslash_func, c_parse_backslash_baton): Remove.
7305 (host_char_to_target_func, host_char_to_target_baton): Remove.
7306 (target_char_to_host_func, target_char_to_host_baton): Remove.
7307 (cached_iconv_host_to_target, cached_iconv_target_to_host):
7308 Remove.
7309 (lookup_charset_or_error, check_valid_host_charset): Remove.
7310 (set_host_and_target_charsets): Remove.
7311 (set_host_charset, set_target_charset): Remove.
7312 (set_host_charset_sfunc, set_target_charset_sfunc): Rewrite.
7313 (set_target_wide_charset_sfunc): New function.
7314 (show_charset): Print target wide character set.
7315 (host_charset, target_charset): Rewrite.
7316 (target_wide_charset): New function.
7317 (c_target_char_has_backslash_escape): Remove.
7318 (c_parse_backslash): Remove.
7319 (host_letter_to_control_character): New function.
7320 (host_char_print_literally): Remove.
7321 (host_hex_value): New function.
7322 (target_char_to_control_char): Remove.
7323 (cleanup_iconv): New function.
7324 (convert_between_encodings): New function.
7325 (target_char_to_host): Remove.
7326 (struct wchar_iterator): Define.
7327 (make_wchar_iterator, make_cleanup_wchar_iterator, wchar_iterator,
7328 wchar_push_back): New functions.
7329 (do_cleanup_iterator): New function.
7330 (char_ptr): New typedef.
7331 (charsets): New global.
7332 (add_one, find_charset_names): New functions.
7333 (default_charset_names): New global.
7334 (auto_host_charset_name): Likewise.
7335 * aclocal.m4, config.in, configure: Rebuild.
7336 * configure.ac: Call AM_LANGINFO_CODESET.
7337 (GDB_DEFAULT_HOST_CHARSET): Default to UTF-8.
7338 (AM_ICONV): Invoke earlier.
7339 * acinclude.m4: Include codeset.m4. Subst LIBICONV_INCLUDE and
7340 LIBICONV_LIBDIR. Check for libiconv in build tree.
7341 * Makefile.in (LIBICONV_LIBDIR, LIBICONV_INCLUDE): New macros.
7342 (INTERNAL_CFLAGS_BASE): Add LIBICONV_INCLUDE.
7343 (INTERNAL_LDFLAGS): Add LIBICONV_LIBDIR.
7344 * gdb_obstack.h (obstack_grow_wstr): New define.
c2c8d75b
AS
7345 * gdb_wchar.h: New file.
7346 * defs.h: Include it.
6c7a06a3 7347
cb249c71
TT
73482009-03-20 Tom Tromey <tromey@redhat.com>
7349 Jan Kratochvil <jan.kratochvil@redhat.com>
7350
7351 * dwarf2read.c (process_die): Handle DW_TAG_typedef.
7352 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Strip a single
7353 typedef.
7354 * ada-lang.c (decode_packed_array_type): Call CHECK_TYPEDEF on the
7355 SYMBOL_TYPE result.
7356 * ada-typeprint.c (print_array_type): Do the NULL check
7357 unconditionally.
7358
16ad9370
TT
73592009-03-19 Tom Tromey <tromey@redhat.com>
7360
7361 * utils.c (do_obstack_free): New function.
7362 (make_cleanup_obstack_free): Likewise.
7363 * defs.h (make_cleanup_obstack_free): Declare.
7364
36dc683c
DE
73652009-03-18 Doug Evans <dje@google.com>
7366
89ecc4f5
DE
7367 * linux-nat.c (linux_nat_find_memory_regions): Result of PIDGET is an
7368 int, not a long long.
7369 (linux_nat_info_proc_cmd): Store pid in long instead of long long.
7370
a411cd0e
DE
7371 * expprint.c (dump_raw_expression): Print note if non-NULL.
7372
36dc683c
DE
7373 * printcmd.c (display_uses_solib_p): Redo loop, scan element list
7374 backwards.
7375
5b1ba0e5
NS
73762009-03-18 Nathan Sidwell <nathan@codesourcery.com>
7377
7378 * Makefile.in: Update license to GPLv3.
7379 * ada-exp.y: Update license to GPLv3.
7380 * ada-lex.l: Update license to GPLv3.
7381 * c-exp.y: Update license to GPLv3.
7382 * cp-name-parser.y: Update license to GPLv3.
7383 * darwin-nat-info.c: Update license to GPLv3.
7384 * f-exp.y: Update license to GPLv3.
7385 * gdb_thread_db.h: Update license to GPLv3.
7386 * hppanbsd-nat.c: Update license to GPLv3.
7387 * hppanbsd-tdep.c: Update license to GPLv3.
7388 * hppaobsd-tdep.c: Update license to GPLv3.
7389 * jv-exp.y: Update license to GPLv3.
7390 * m2-exp.y: Update license to GPLv3.
7391 * objc-exp.y: Update license to GPLv3.
7392 * p-exp.y: Update license to GPLv3.
7393 * reply_mig_hack.awk: Update license to GPLv3.
7394 * reverse.c: Update license to GPLv3.
7395 * xtensa-xtregs.c: Update license to GPLv3.
7396
8a2492ee
PA
73972009-03-18 Pedro Alves <pedro@codesourcery.com>
7398
7399 * remote.c (remote_close): Don't call generic_mourn_inferior.
7400 (remote_mourn_1): Call generic_mourn_inferior after closing the
7401 target.
7402
5338cef1
PA
74032009-03-18 Pedro Alves <pedro@codesourcery.com>
7404
7405 * remote.c (remote_start_remote): Add missing call to
7406 init_wait_for_inferior in non-stop mode.
7407
717a8278
PA
74082009-03-18 Pedro Alves <pedro@codesourcery.com>
7409
7410 * breakpoint.c (bpstat_should_step): Only consider software
7411 watchpoints that have a location.
7412
7d85a9c0
JB
74132009-03-17 Joel Brobecker <brobecker@adacore.com>
7414
7415 Add a target_ops parameter to the to_kill method in struct target_ops.
7416
7417 * target.h (struct target_ops): Add a "target_ops *" parameter to
7418 method to_kill.
7419 (target_kill): Remove macro. Add declaration.
7420 * target.c (debug_to_kill): Delete, no longer necessary.
7421 (target_kill): New function.
7422 (update_current_target): Stop inheriting the to_kill method.
7423 Do not de_fault it to no_process either.
7424 (setup_target_debug): Do not set current_target.to_kill.
7425 * gnu-nat.c, go32-nat.c, hpux-thread.c, inf-ptrace.c, inf-ttrace.c,
7426 linux-nat.c, monitor.c, nto-procfs.c, procfs.c, remote-m32r-sdi.c,
7427 remote-mips.c, remote-sim.c, remote.c, windows-nat.c: Update
7428 accordingly.
7429
14064aa2
DE
74302009-03-17 Doug Evans <dje@google.com>
7431
7432 * amd64-linux-nat.c (si_timerid,si_overrun): Provide definition for
7433 glibc 2.3.2 and earlier.
7434
f06eadd9
JB
74352009-03-17 Joel Brobecker <brobecker@adacore.com>
7436
7437 * frame.c (get_prev_frame_1): Do not perform the inner_frame
7438 sanity check if this_frame is not NORMAL.
7439 (frame_id_inner): Update the description of this function.
7440
481df73e
HZ
74412009-03-17 Hui Zhu <teawater@gmail.com>
7442
7443 * stack.c: Change the introduce of "disassemble-next-line".
7444
6b251945
PA
74452009-03-17 Pedro Alves <pedro@codesourcery.com>
7446
7447 * mi/mi-main.h (mi_print_timing_maybe): Add strict prototype,
7448 declare as extern.
7449
30c33a9f
HZ
74502009-03-17 Hui Zhu <teawater@gmail.com>
7451
dafb3b41 7452 * stack.c: Include valprint.h.
30c33a9f
HZ
7453 (disassemble_next_line): New enum.
7454 (show_disassemble_next_line): New function. Show the current
7455 value of disassemble-next-line.
7456 (gdb_disassembly_stub_args): New struct for argument passing
7457 between function do_gdb_disassembly and function
7458 gdb_disassembly_stub.
7459 (gdb_disassembly_stub): New function. Helper for
7460 gdb_disassembly.
7461 (do_gdb_disassembly): New function. Use TRY_CATCH to catch
7462 the exception from the gdb_disassembly because it will be
7463 broken by filter sometime.
7464 (print_frame_info): If disassemble-next-line is set to auto
7465 or on and doesn't have the line debug messages for $pc,
7466 output the next instruction.
7467 If disassemble-next-line is set to on and there is line debug
7468 messages, output assembly codes for next line.
7469 (_initialize_stack): Make the "set disassemble-next-line"
7470 command an auto-boolean command. Change its class to
7471 class_stack. Place it in the top level set list. Extend help
7472 to describe the auto mode.
7473
fee0be5d
PA
74742009-03-17 Pedro Alves <pedro@codesourcery.com>
7475
7476 * infrun.c (normal_stop): Don't overwrite old_chain.
7477
a624e111
JB
74782009-03-16 Joel Brobecker <brobecker@adacore.com>
7479
7480 * remote-mips.c (mips_load): Replace call to regcache_set_valid_p,
7481 which is undefined, by call to regcache_invalidate, which should
7482 do what the original author wanted to do.
7483
383c0389
JB
74842009-03-16 Joel Brobecker <brobecker@adacore.com>
7485
7486 * remote-mips.c (mips_mourn_inferior): Add missing ops parameter.
7487 (mips_create_inferior): Likewise.
7488
267fbcde
JB
74892009-03-16 Joel Brobecker <brobecker@adacore.com>
7490
7491 * go32-nat.c (go32_create_inferior): Add missing ops parameter.
7492
da66f6a6
JB
74932009-03-16 Joel Brobecker <brobecker@adacore.com>
7494
7495 * darwin-nat.c (darwin_resume): Fix a compiler warning when
7496 building on x86_64-darwin.
7497
58529c02
JB
74982009-03-16 Tristan Gingold <gingold@adacore.com>
7499
7500 * configure.tgt: Add handling for x86_64-darwin.
7501
ba30a4e9
JK
75022009-03-16 Jan Kratochvil <jan.kratochvil@redhat.com>
7503
7504 * auxv.c (fprint_target_auxv): New TAG for AT_RANDOM.
7505
7fc0c7b5
JB
75062009-03-15 Joel Brobecker <brobecker@adacore.com>
7507
7508 * aix-thread.c (aix_thread_thread_alive, aix_thread_pid_to_str):
7509 Use the ops parameter to get to the target beneath, rather than
7510 using the current_target global. Using the current_target global
7511 was an unintended accident.
7512
1ba0a4ee
JB
75132009-03-15 Joel Brobecker <brobecker@adacore.com>
7514
7515 Fix an error happening while loading symbols from a core file
7516 (on AIX).
7517
7518 * rs6000-nat.c (xcoff_relocate_symtab): Use target_has_execution
7519 to detect whether we're debugging a core file or not.
7520
d30acaa7
JB
75212009-03-15 Joel Brobecker <brobecker@adacore.com>
7522
7523 Modernize the aix-thread later by getting rid of the base_target
7524 global. This brings back to life the AIX port which was otherwise
7525 crashing all the time.
7526
7527 * aix-thread.c (base_target): Delete.
7528 (pd_enable): Do not set base_target.
7529 (aix_thread_attach): Use find_target_beneath instead of base_target.
7530 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
7531 (aix_thread_fetch_registers, aix_thread_store_registers),
7532 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
7533 (aix_thread_thread_alive, aix_thread_pid_to_str): Likewise.
7534 (aix_thread_kill): Delete. Does not seem necessary.
7535 (init_aix_thread_ops): Do not set aix_thread_ops.to_kill.
7536
61ff14c6
JK
75372009-03-15 Jan Kratochvil <jan.kratochvil@redhat.com>
7538
7539 * stack.c (return_command <retval_exp>): New variables retval_expr
7540 and old_chain. Inline parse_and_eval to initialize retval_expr. Check
7541 RETVAL_EXPR for UNOP_CAST and set RETURN_TYPE to the RETURN_VALUE type
7542 if RETURN_TYPE is NULL.
7543
0b16c5cf
PA
75442009-03-14 Pedro Alves <pedro@codesourcery.com>
7545
7546 * remote.c (PACKET_qAttached): New.
7547 (remote_query_attached): New.
7548 (remote_add_inferior): Add new `attached' argument. Handle it.
7549 (remote_notice_new_inferior, remote_start_remote): Adjust to pass
7550 -1 to remote_add_inferior in new parameter.
7551 (extended_remote_attach_1): Adjust to pass 1 to
7552 remote_add_inferior in the new parameter.
7553 (extended_remote_create_inferior_1): Adjust to pass 0 to
7554 remote_add_inferior in the new parameter.
7555 (_initialize_remote): Add "set/show remote query-attached-packet"
7556 commands.
7557
9ee6bb93
TT
75582009-03-13 Tom Tromey <tromey@redhat.com>
7559
7560 * symtab.c (lookup_symbol_in_language): Use a cleanup.
7561
787274f0
DE
75622009-03-13 Doug Evans <dje@google.com>
7563
7564 * exceptions.h: Clean up some comments on catch_exceptions usage.
7565 * exceptions.c: Ditto. Plus mark catch_errors as superseded by
7566 catch_exceptions.
7567
24f81874
JB
75682009-02-17 Joel Brobecker <brobecker@adacore.com>
7569
7570 The following patch helps getting rid of a warning inside solib-som.c.
7571
7572 * source.c (source_full_path_of): Constify parameter filename.
7573 * defs.h (source_full_path_of): Update declaration accordingly.
7574
e1578042
JB
75752009-03-12 Joel Brobecker <brobecker@adacore.com>
7576
7577 * ada-lang.c (ada_evaluate_subexp): Merge case BINOP_REM and
7578 BINOP_MOD cases with the handling of case BINOP_DIV and BINOP_MUL.
7579 Remove useless op value checks when EVAL_AVOID_SIDE_EFFECTS.
7580
9c2be529
JB
75812009-03-12 Joel Brobecker <brobecker@adacore.com>
7582
7583 * ada-lang.c (ada_evaluate_subexp) <BINOP_DIV>: make sure to
7584 promote the operands when noside is EVAL_AVOID_SIDE_EFFECTS.
7585
2360f94a 75862009-03-12 Joel Brobecker <brobecker@adacore.com>
e22dccb5
JB
7587
7588 * ada-tasks.c (ada_task_is_alive): Move up and make static.
7589 * ada-lang.h (ada_task_is_alive): Remove declaration.
7590
facc390f
JB
75912009-03-12 Jerome Guitton <guitton@adacore.com>
7592
7593 * ada-lang.c (ada_delta): Change the type of numerators and
7594 denominators to DOUBLEST, as they may not fit into a long.
7595 (scaling_factor): Ditto.
7596
47e729a8
JB
75972009-03-12 Jerome Guitton <guitton@adacore.com>
7598
5c20fa2a 7599 * language.c (lang_bool_type): Set lai->bool_type_symbol to NULL.
47e729a8 7600
b79819ba
JB
76012009-03-12 Joel Brobecker <brobecker@adacore.com>
7602
7603 * ada-lang.c (ada_evaluate_subexp) [OP_VAR_VALUE]: For tagged
7604 types, if we are unable to determine the actual symbol type
7605 from its tag, then use the static approximation instead.
7606
0056e4d5
JB
76072009-03-12 Joel Brobecker <brobecker@adacore.com>
7608
7609 Fix crash printing packed record with packed array.
7610
7611 * ada-lang.c (ada_modulus_from_name): New function.
7612 (ada_modulus): In the case where the type length is bigger than
7613 the size of the type used to hold the bounds, try determining
7614 the modulus from the type name.
7615 (ada_value_primitive_packed_val): Fix bug in the computation of
7616 ntarg causing an out-of-buffer invalid access.
7617
3c513ee6
JB
76182009-03-12 Joel Brobecker <brobecker@adacore.com>
7619
7620 Fix segfault when printing short_integer'last.
7621
7622 * ada-lang.c (ada_find_any_type): Search in the primitive types
7623 if a symbol could not be found.
7624
680f3fad
JB
76252009-03-12 Joel Brobecker <brobecker@adacore.com>
7626
7627 * ada-tasks.c (task_states,long_task_states): Add new states
7628 Activating and Acceptor_Delay_Sleep. Update the description
7629 of state Acceptor_Sleep.
7630
2ab1c2d9
JB
76312009-03-12 Jonas Maebe <jonas.maebe@elis.ugent.be> (obvious change)
7632
7633 Fix a build failure on Darwin following some changes in
7634 the profile of some target_ops methods.
7635
7636 * darwin-nat.c (darwin_kill_inferior): Add target_ops parameter
7637 where missing.
7638 (darwin_stop_inferior, darwin_detach): Likewise.
7639
1f31650a
VP
76402009-03-12 Vladimir Prus <vladimir@codesourcery.com>
7641
7642 Include token in ^running notification for CLI commands.
7643
c2c8d75b
AS
7644 * mi/mi-main.c (mi_execute_command): Set current_token here.
7645 (mi_cmd_execute): Do not set current_token here.
1f31650a 7646
4333ada3
VP
76472009-03-12 Vladimir Prus <vladimir@codesourcery.com>
7648
7649 Fix MI timings.
7650
c2c8d75b
AS
7651 * mi/mi-main.c (mi_print_timing_maybe): New.
7652 (captured_mi_execute_command): Simplify. Output timings to
7653 CLI commands, too.
7654 (mi_execute_async_cli_command): Do not print timings.
7655 * mi/mi-main.h (mi_print_timing_maybe): Declare.
7656 * mi/mi-interp.c (mi_on_normal_stop): Call mi_print_timing_maybe.
4333ada3 7657
c5933f6d
JB
76582009-03-12 Jerome Guitton <guitton@adacore.com>
7659
7660 * xcoffread.c (process_linenos): Check if the line in the
7661 include table refers to the main source file and, if so,
7662 add them to the main subfile.
7663
c7660128
JB
76642009-03-12 Joel Brobecker <brobecker@adacore.com>
7665
7666 Fix a build failure on AIX introduced after a change in the profile
7667 of some of the "methods" in the target_ops structure.
7668 * aix-thread.c: Add missing target_ops parameter throughout.
7669
7670 Implement Ada task switching on AIX.
7671 * aix-thread.c (aix_thread_get_ada_task_ptid): New function.
7672 (init_aix_thread_ops): Set aix_thread_ops.to_get_ada_task_ptid.
7673
c5bc3a77
DJ
76742009-03-11 Daniel Jacobowitz <dan@codesourcery.com>
7675
7676 * breakpoint.c (bpstat_check_breakpoint_conditions): Use
7677 value_mark and value_free_to_mark.
7678 * objfiles.c (free_objfile): Call objfile_free_data before
7679 freeing the BFD.
7680
55518360
HZ
76812009-03-10 Hui Zhu <teawater@gmail.com>
7682
7683 * disasm.c (gdb_disassembly): Remove unused argument
7684 "line_num".
7685 * disasm.h (gdb_disassembly): Ditto.
7686 * cli/cli-cmds.c (print_disassembly): Ditto.
7687 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Ditto.
7688
5fd1a349
PP
76892009-03-09 Paul Pluzhnikov <ppluzhnikov@google.com>
7690
7691 * solib.c (solib_contains_address_p): New function.
7692 (solib_name_from_address): Use it.
7693 * printcmd.c (display_uses_solib_p): Use it.
c2c8d75b
AS
7694 * solib.h (solib_contains_address_p): Declare it.
7695
36746093
JK
76962009-03-09 Jan Kratochvil <jan.kratochvil@redhat.com>
7697
7698 * varobj.c (free_variable): Call value_free.
7699
757a13d0
JK
77002009-03-09 Jan Kratochvil <jan.kratochvil@redhat.com>
7701
7702 PR gdb/9873:
7703 * dwarf2read.c (dwarf_decode_macros): New variable `at_commandline'.
7704 Move the variable `macinfo_type' out of the loop. Create a new
7705 processing pass before the current one to pre-create `current_file'.
7706 New complaint on misplaced zero/non-zero definitions/includes.
7707 Skip first DW_MACINFO_start_file with `at_commandline' set.
7708
c8fa6cdd
VP
77092008-03-09 Vladimir Prus <vladimir@codesourcery.com>
7710
7711 * solib.c (reload_shared_libraries): Give
7712 inferior a chance to reset solib breakpoint.
7713 Reinit frame cache.
7714
41b4aadc
CF
77152009-03-08 Christopher Faylor <me+cygwin@cgf.cx>
7716
7717 * windows-nat.c (dr): Redefine to use largest possible integer which
7718 holds a pointer.
7719 (cygwin_set_dr): Avoid coercion.
7720
77212009-03-08 Oswald Buddenhagen <oswald.buddenhagen@trolltech.de>
7722
14b69f28 7723 * windows-nat.c (windows_create_inferior): Implement --tty handling on
41b4aadc
CF
7724 non-cygwin.
7725
f5c9a895
PP
77262009-03-06 Paul Pluzhnikov <ppluzhnikov@google.com>
7727
7728 Rename solib_address to solib_name_from_address.
7729 * breakpoint.c (insert_bp_location, disable_breakpoints_in_shlibs)
7730 (disable_breakpoints_in_unloaded_shlib): Update.
7731 * printcmd.c (display_uses_solib_p): Likewise.
7732 * stack.c (print_frame): Likewise.
7733 * solib.c: Rename.
7734 * solib.h: Rename.
c2c8d75b 7735
a3247a22
PP
77362009-03-05 Paul Pluzhnikov <ppluzhnikov@google.com>
7737
7738 * printcmd.c (do_one_display): Reparse exp_string.
7739 (display_uses_solib_p): New function.
7740 (clear_dangling_display_expressions): New function.
7741 (_initialize_printcmd): Add observer.
7742 * solib.c (no_shared_libraries): Swap order of calls to
7743 clear_solib and objfile_purge_solibs.
c2c8d75b 7744
d36df9c5
JB
77452009-03-05 Joel Brobecker <brobecker@adacore.com>
7746
7747 Implement the target-specific part of Ada tasking support
7748 on Tru64.
7749
7750 * dec-thread.c (dec_thread_get_ada_task_ptid): New function.
7751 (init_dec_thread_ops): Set the to_get_ada_task_ptid method.
7752
b254c0b2
JB
77532009-03-05 Joel Brobecker <brobecker@adacore.com>
7754
7755 Get rid of the global "base_target" and use "find_target_beneath"
7756 to find the underlying target.
7757 * dec-thread.c (base_target): Delete.
7758 (enable_dec_thread): Remove assignement to base_target.
7759 (dec_thread_detach, dec_thread_wait, dec_thread_wait)
7760 (dec_thread_fetch_registers, dec_thread_store_registers)
7761 (dec_thread_mourn_inferior, dec_thread_pid_to_str):
7762 Update the function profile if necessary.
7763 Use find_target_beneath to call the same method but from
7764 the underlying target, removing the need for "base_target".
7765
7766 * dec-thread.c (dec_thread_get_regsets, dec_thread_set_regsets):
7767 Fix a copy/paste error in a few debug traces...
7768
7769 * solib-osf.c (init_so): Use a simpler method for computing
7770 the size of lm_info structure. This also gets rid of warning
7771 emitted by the compiler.
7772
aae64587
PA
77732009-03-05 Pedro Alves <pedro@codesourcery.com>
7774
7775 * breakpoint.c (check_duplicates_for): Skip permanent breakpoints
7776 duplicates of permanent breakpoints.
7777
1941c569
PA
77782009-03-04 Pedro Alves <pedro@codesourcery.com>
7779
7780 * inferior.h (notice_new_inferior): Declare.
7781 * infcmd.c (notice_new_inferior): New.
7782 * remote.c (remote_add_inferior, remote_add_thread): New.
7783 (notice_new_inferiors): Rename to...
7784 (remote_notice_new_inferior): ... this. Add RUNNING argument.
7785 Use remote_add_thread instead of add_thread, passing it the
7786 RUNNING argument. Add an inferior with remote_add_inferior. If
7787 we just learned about an inferior, call notice_new_inferior.
7788 (record_currthread): Adjust.
7789 (remote_threads_info): Adjust to use remote_notice_new_inferior.
237d4315
PA
7790 (remote_start_remote, extended_remote_attach_1): Use
7791 remote_add_inferior.
1941c569
PA
7792 (process_stop_reply): Adjust. Call remote_notice_new_inferior
7793 after handling expedited registers and watchpoint state.
7794 (extended_remote_create_inferior_1): Use remote_add_inferior.
7795
9bde0732
AR
77962009-03-04 Aleksandar Ristovski <aristovski@qnx.com>
7797
7798 * infcmd.c (registers_info): Remove register number case.
7799
6aa8e5c2
PA
78002009-03-03 Pedro Alves <pedro@codesourcery.com>
7801
7802 * top.c (quit_target): Check for target_has_execution before
7803 killing or detaching from inferiors.
7804
1d59cee5
JB
78052009-03-02 Joel Brobecker <brobecker@adacore.com>
7806
7807 Remove some unused routines.
7808
7809 * ada-lang.c (is_suppressed_name, ada_suppress_symbol_printing):
7810 Delete.
7811 * ada-lang.c (ada_task_list_iterator_ftype)
7812 (iterate_over_live_ada_tasks): Delete.
7813 * ada-tasks.c (ada_get_environment_task, iterate_over_live_ada_tasks):
7814 Delete.
7815
223698f8
DE
78162009-03-01 Doug Evans <dje@google.com>
7817
9af17804
DE
7818 * symtab.c: Remove trailing whitespace throughout the file.
7819 (expand_line_sal): Fix some typos and whitespace.
7820
3c54f140
DE
7821 * Makefile.in (clean): rm -f $(DEPDIR)/*.
7822
2aecd87f
DE
7823 * Makefile.in (GDB_CFLAGS): Add -I$(srcdir)/common.
7824 (init.c): signals/ -> common/.
7825 (signals.o): Update.
7826 * target.h (target_signal_to_string,target_signal_to_string)
7827 (target_signal_from_name,target_signal_to_host_p)
7828 (target_signal_from_host,target_signal_to_host): Move to ...
7829 * common/gdb_signals.h: ... here. New file.
7830 * common/signals.c: Moved here from signals/signals.c.
7831 #include gdb_signals.h, remove #include of target.h in gdb case.
7832 (target_signal_from_command,default_target_signal_to_host)
7833 (default_target_signal_from_host): Move inside #ifndef GDBSERVER.
7834
223698f8
DE
7835 Include thread ID in target_wait debugging output.
7836 * infrun.c (print_target_wait_results): New function.
7837 (wait_for_inferior,fetch_inferior_event): Call it.
7838
93a91755
PA
78392009-02-27 Pedro Alves <pedro@codesourcery.com>
7840
7841 * gdb_proc_service.h (struct ps_prochandle): Replace pid_t field
7842 with a ptid_t field.
7843 * linux-thread-db.c (thread_get_info_callback): Build the ptid
7844 using the pid stored in proc_handle.ptid.
7845 (thread_from_lwp, thread_db_attach_lwp, enable_thread_event)
7846 (check_for_thread_db, thread_db_detach, check_event)
7847 (thread_db_mourn_inferior, find_new_threads_callback)
7848 (thread_db_find_new_threads_1): Adjust.
7849 * proc-service.c (ps_xfer_memory, ps_lgetregs, ps_lsetregs)
7850 (ps_lgetfpregs, ps_lsetfpregs, ps_getpid): Adjust.
7851
b5096abe
PM
78522009-02-27 Phil Muldoon <pmuldoon@redhat.com>
7853
7854 * valprint.c (read_string): Rework clean-up logic. Use
7855 free_current_contents to clean-up buffer.
7856
a2f63f5e
AS
78572009-02-27 Andreas Schwab <schwab@linux-m68k.org>
7858
7859 * MAINTAINERS: Update e-mail address.
7860
83390453
PM
78612009-02-26 Phil Muldoon <pmuldoon@redhat.com>
7862
7863 * python/python-utils.c (python_string_to_unicode): Always return
7864 a new reference.
7865 (python_string_to_target_string): Decrement transient python
7866 instance.
7867 (python_string_to_host_string): Likewise.
7868
78692007-02-26 Pedro Alves <pedro@codesourcery.com>
a0740d21
PA
7870
7871 * mips-linux-nat.c (mips64_linux_fetch_registers): Pass `ops' to
7872 call to super_fetch_registers.
7873 (mips64_linux_store_registers): Pass `ops' to call to
7874 super_store_registers.
7875
89c83b10
DE
78762009-02-25 Doug Evans <dje@google.com>
7877
99361f52
DE
7878 * breakpoint.c (insert_bp_location): Add \n to overlay breakpoint
7879 error message.
7880
1c2af6c4
DE
7881 * breakpoint.c (disable_breakpoints_in_shlibs): Delete local
7882 disabled_shlib_breaks, unused.
7883
89c83b10
DE
7884 * printcmd.c (build_address_symbolic): Fix comment.
7885
9e2f0ad4
HZ
78862009-02-25 Hui Zhu <teawater@gmail.com>
7887
7888 * cli/cli-script.c (define_command): Add _() to query.
7889 * gnu-nat.c (inf_validate_task_sc): Ditto.
7890 * infcmd.c (kill_if_already_running): Ditto.
7891 (jump_command): Ditto.
7892 (attach_command): Ditto.
7893 * inflow.c (kill_command): Ditto.
7894 * infrun.c (handle_command): Ditto.
7895 * maint.c (maintenance_dump_me): Ditto.
7896 * memattr.c (mem_delete_command): Ditto.
7897 * monitor.c (monitor_interrupt_query): Ditto.
7898 * nto-procfs.c (interrupt_query): Ditto.
7899 * printcmd.c (undisplay_command): Ditto.
7900 * remote-mips.c (mips_kill): Ditto.
7901 * remote.c (interrupt_query): Ditto.
7902 * solib-irix.c (irix_open_symbol_file_object): Ditto.
7903 * solib-osf.c (osf_open_symbol_file_object): Ditto.
7904 * solib-pa64.c (pa64_open_symbol_file_object): Ditto.
7905 * solib-som.c (som_open_symbol_file_object): Ditto.
7906 * solib-svr4.c (open_symbol_file_object): Ditto.
7907 * symfile.c (symbol_file_add_with_addrs_or_offsets): Ditto.
7908 * target.c (kill_or_be_killed): Ditto.
7909 * tracepoint.c (delete_trace_command): Ditto.
7910 * top.c (quit_confirm): Add _() to s that will be used
7911 in query.
7912
02529b48
PM
79132009-02-24 Pierre Muller <muller@ics.u-strasbg.fr>
7914
7915 Fix windows-nat.c compilation failure.
7916
7917 * windows-nat.c (windows_thread_alive): Fix forward declaration.
7918 (get_windows_debug_event): Add ops parameter to call to windows_resume.
7919
2fb89e62
PA
79202009-02-23 Pedro Alves <pedro@codesourcery.com>
7921
7922 * remote-sim.c (gdbsim_resume): Add target_ops* argument.
7923
6f43c46f
JB
79242009-02-23 Jay Krell <jay.krell@cornell.edu> (tiny change)
7925
7926 * symtab.c (find_line_symtab): Initialize exact to avoid
7927 a compiler warning.
7928
84e473c8
PA
79292009-02-23 Pedro Alves <pedro@codesourcery.com>
7930
7931 * i386-linux-nat.c (i386_linux_fetch_inferior_registers): Pass
7932 `ops' to recursive call.
7933
28439f5e
PA
79342009-02-23 Pedro Alves <pedro@codesourcery.com>
7935
7936 * corelow.c (get_core_registers): Adjust.
7937 (core_file_thread_alive): Rename to...
7938 (core_thread_alive): ... this.
7939 (core_pid_to_str): Try gdbarch_core_pid_to_str first.
7940 (init_core_ops): Adjust.
7941 (coreops_suppress_target): Delete.
7942 (_initialize_corelow): Unconditionally add core_ops.
7943 * procfs.c: Include "inf-child.h".
7944 (procfs_ops): Delete.
7945 (init_procfs_ops): Delete. Reimplement as...
7946 (procfs_target): ... this, inheriting from inf-child.
7947 (procfs_attach, procfs_detach, procfs_fetch_registers): Adjust.
7948 (procfs_prepare_to_store): Delete.
7949 (procfs_store_registers, procfs_resume): Adjust.
7950 (procfs_open): Delete.
7951 (procfs_suppress_run): Delete.
7952 (procfs_can_run): Delete.
7953 (procfs_mourn_inferior): Adjust.
7954 (procfs_init_inferior): Add target_ops parameter. Adjust.
7955 (procfs_create_inferior): Don't pass procfs_init_inferior to
7956 fork_inferior. Instead call it after fork_inferior returns.
7957 (procfs_find_new_threads): Adjust.
7958 (_initialize_procfs): Adjust to use procfs_target instead of
7959 init_procfs_ops.
7960 * sol-thread.c (orig_core_ops, sol_core_ops): Delete.
7961 (lwp_to_thread): Use target_thread_alive.
7962 (sol_thread_open): Delete.
7963 (sol_thread_attach): Delete.
7964 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
7965 (sol_thread_fetch_registers, sol_thread_store_registers): Adjust
7966 to use find_target_beneath.
7967 (sol_thread_prepare_to_store, sol_thread_xfer_memory): Delete.
7968 (sol_thread_xfer_partial): Adjust to use find_target_beneath.
7969 (sol_thread_files_info, sol_thread_kill_inferior): Delete.
7970 (check_for_thread_db): New.
7971 (sol_thread_notice_signals, sol_thread_create_inferior): Delete.
7972 (sol_thread_new_objfile): Call check_for_thread_db.
7973 (sol_thread_mourn_inferior): Adjust to use find_target_beneath.
7974 (sol_thread_can_run): Delete.
7975 (sol_thread_alive): Adjust to use find_target_beneath.
7976 (sol_thread_stop): Delete.
7977 (rw_common): Use target_write_memory or target_read_memory.
7978 (ps_lgetregs, ps_lgetfpregs): Use target_fetch_registers.
7979 (ps_lsetregs, ps_lsetfpregs): Use target_store_registers.
7980 (solaris_pid_to_str): Remove check for libthread_db initialization
7981 failing.
7982 (sol_find_new_threads): Remove check for libthread_db
7983 initialization failing, or for an invalid inferior_ptid. Adjust
7984 to use find_target_beneath.
7985 (sol_core_open, sol_core_close, sol_core_detach,
7986 sol_core_files_info, sol_find_memory_regions,
7987 sol_make_note_section, ignore): Delete.
7988 (init_sol_thread_ops): Make it a thread_stratum target. Remove
7989 unneeded callback settings.
7990 (init_sol_core_ops): Delete.
7991 (_initialize_sol_thread): No longer call init_sol_core_ops, set
7992 procfs_suppress_run, or hack with core_ops.
7993
7994 * target.h (struct target_ops): Add a target_ops * parameter to
7995 to_resume, to_fetch_registers, to_store_registers, to_thread_alive
7996 and to_find_new_threads.
7997 (target_fetch_registers, target_store_registers)
7998 (target_thread_alive, target_find_new_threads): Redeclare as
7999 function.
a2f63f5e 8000
28439f5e
PA
8001 * target.c (update_current_target): Do not inherit or de_fault
8002 to_resume, to_fetch_registers, to_store_registers,
8003 to_thread_alive, to_find_new_threads.
8004 (target_resume): Adjust.
8005 (target_thread_alive, target_find_new_threads): New.
8006 (debug_to_resume, debug_to_fetch_registers): Delete.
8007 (target_fetch_registers): New.
8008 (debug_to_store_registers): Delete.
8009 (target_store_registers): New.
8010 (debug_to_thread_alive, debug_to_find_new_threads): Delete.
8011 (setup_target_debug): Adjust.
a2f63f5e 8012
28439f5e 8013 * gdbcore.h (core_ops): Delete declaration.
a2f63f5e 8014
28439f5e
PA
8015 * inf-ptrace.c, linux-nat.c, remote.c, amd64-linux-nat.c,
8016 inf-child.c, linux-thread-db.c, bsd-uthread.c, inf-ttrace.c,
8017 i386-sol2-tdep.c, darwin-nat.c, gnu-nat.c, go32-nat.c,
8018 hpux-thread.c, i386-linux-nat.c, i386fbsd-nat.c, monitor.c,
8019 nto-procfs.c, remote-m32r-sdi.c, remote-mips.c, windows-nat.c,
8020 alphabsd-nat.c, amd64bsd-nat.c, arm-linux-nat.c, armnbsd-nat.c,
8021 bsd-kvm.c, hppa-hpux-nat.c, hppa-linux-nat.c, hppabsd-nat.c,
8022 hppanbsd-nat.c, i386-darwin-nat.c, i386bsd-nat.c,
8023 ia64-linux-nat.c, m32r-linux-nat.c, m68kbsd-nat.c,
8024 m68klinux-nat.c, m88kbsd-nat.c, mips-linux-nat.c,
8025 mips64obsd-nat.c, mipsnbsd-nat.c, ppc-linux-nat.c, ppcnbsd-nat.c,
8026 ppcobsd-nat.c, remote-sim.c, rs6000-nat.c, s390-nat.c,
8027 shnbsd-nat.c, sparc-nat.c, sparc-nat.h, spu-linux-nat.c,
8028 vaxbsd-nat.c, xtensa-linux-nat.c: Adjust to target_ops changes.
8029
8030 * gdbarch.sh (core_pid_to_str): New gdbarch callback.
8031 * gdbarch.h, gdbarch.c: Regenerate.
8032
8033 * sol2-tdep.c: Include "inferior.h".
8034 (sol2_core_pid_to_str): New.
8035 * sol2-tdep.h (sol2_core_pid_to_str): Declare.
8036
8037 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Set it.
8038 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Set it.
8039 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Set it.
8040 * i386-sol2-tdep.c (i386_sol2_init_abi): Set it.
8041
907083d1
DE
80422009-02-22 Doug Evans <dje@google.com>
8043
8044 * exec.c (exec_file_attach): Fix comment.
8045
63807e1d
PA
80462009-02-22 Pedro Alves <pedro@codesourcery.com>
8047
8048 Silence a few -Wmissing-prototypes warnings.
8049
8050 PR build/9877:
a2f63f5e 8051 * alpha-linux-tdep.c (alpha_linux_regset_from_core_section): Make
63807e1d 8052 it static.
a2f63f5e
AS
8053 * alpha-osf1-tdep.c (_initialize_alpha_osf1_tdep): Declare.
8054 * amd64fbsd-tdep.c (amd64fbsd_init_abi): Make it static.
8055 * amd64nbsd-tdep.c (_initialize_amd64nbsd_ndep): Rename to ...
63807e1d
PA
8056 (_initialize_amd64nbsd_tdep): ... this.
8057 * arm-linux-tdep.c (arm_linux_software_single_step): Make it static.
8058 (_initialize_arm_linux_tdep): Declare.
8059 * armbsd-tdep.c (armbsd_fpreg_offset): Make it static.
8060 * armnbsd-tdep.c (_initialize_arm_netbsd_tdep): Declare.
8061 * armobsd-tdep.c (_initialize_armobsd_tdep): Declare.
8062 * avr-tdep.c (avr_return_value): Make it static.
8063 (avr_frame_unwind_cache): Ditto.
8064 * bsd-uthread.c (bsd_uthread_inferior_created): Ditto.
8065 (bsd_uthread_solib_loaded): Ditto.
8066 (bsd_uthread_solib_unloaded): Ditto.
8067 (bsd_uthread_target): Ditto.
8068 (_initialize_bsd_uthread): Declare.
8069 * cris-tdep.c (crisv32_single_step_through_delay): Make it static.
8070 (cris_frame_unwind_cache): Ditto.
8071 * frv-tdep.c (frv_return_value): Ditto.
8072 * h8300-tdep.c (h8300_use_struct_convention): Ditto.
8073 (h8300h_use_struct_convention): Ditto.
8074 * hppa-tdep.c (hppa_sign_extend, hppa_low_hppa_sign_extend):
8075 Ditto.
8076 * hppa-tdep.h (hppa_low_sign_extend, hppa_sign_extend): Delete
8077 declarations.
8078 * hppabsd-tdep.c: Include hppabsd-tdep.h.
8079 (hppabsd_find_global_pointer): Make it static.
8080 * hppabsd-tdep.h: New.
8081 * hppanbsd-tdep.c: Include hppabsd-tdep.h.
8082 (hppabsd_init_abi): Remove declaration.
8083 (_initialize_hppabsd_tdep): Remove declaration.
8084 (_initialize_hppanbsd_tdep): Declare.
8085 * hppaobsd-tdep.c: Include hppabsd-tdep.h.
8086 (hppabsd_init_abi): Delete declaration.
8087 (hppaobsd_init_abi): Make it static.
8088 * i386-nto-tdep.c (_initialize_i386nto_tdep): Declare.
8089 * i386nbsd-tdep.c (_initialize_i386nbsd_tdep): Declare.
8090 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Declare.
8091 * ia64-tdep.c (ia64_register_reggroup_p): Make it static.
8092 * iq2000-tdep.c (_initialize_iq2000_tdep): Declare.
8093 * m32c-tdep.c (m32c_register_reggroup_p): Make it static.
8094 (m32c_analyze_prologue, m32c_virtual_frame_pointer): Ditto.
8095 (_initialize_m32c_tdep): Declare.
8096 * m32r-rom.c (_initialize_m32r_rom): Declare.
8097 * m32r-tdep.c (m32r_skip_prologue): Make it static.
8098 (m32r_return_value): Ditto.
8099 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Make it static.
8100 (m68hc11_return_value): Ditto.
8101 * m68klinux-tdep.c (_initialize_m68k_linux_tdep): Declare.
8102 * m88k-tdep.c (m88k_frame_cache): Make it static.
8103 * mep-tdep.c (mep_gdb_print_insn): Ditto.
8104 (mep_return_value): Ditto.
8105 (_initialize_mep_tdep): Declare.
8106 * mips-irix-tdep.c (_initialize_mips_irix_tdep): Declare.
8107 * mips-linux-tdep.c (supply_64bit_reg): Make it static.
8108 (mips_linux_syscall_next_pc): Ditto.
8109 (_initialize_mips_linux_tdep): Declare.
8110 * mips-tdep.c (mips_single_step_through_delay): Make it static.
8111 * mipsnbsd-tdep.c (_initialize_mipsnbsd_tdep): Declare.
8112 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Declare.
8113 * mn10300-tdep.c (_initialize_mn10300_tdep): Declare.
8114 * mt-tdep.c (_initialize_mt_tdep): Declare.
8115 * nbsd-tdep.c: Include nbsd-tdep.h.
8116 * nto-tdep.c (find_load_phdr): Make it static.
8117 (_initialize_nto_tdep): Declare.
8118 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Make it
8119 static.
8120 (_initialize_ppc_linux_tdep): Declare.
8121 * remote-m32r-sdi.c (m32r_can_use_hw_watchpoint)
8122 (m32r_insert_watchpoint, m32r_remove_watchpoint)
8123 (m32r_stopped_data_address, m32r_stopped_by_watchpoint): Make
8124 static.
8125 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Declare.
8126 * rs6000-nat.c: Include xcoffread.h.
8127 (find_toc_address): Don't extern declare get_toc_offset. Adjust
8128 to call xcoff_get_to_offset.
8129 * rs6000-tdep.c (ppc_vsx_support_p, ppc_displaced_step_fixup)
8130 (rs6000_skip_main_prologue, rs6000_in_solib_return_trampoline)
8131 (rs6000_skip_trampoline_code): Make static.
8132 * s390-tdep.c (s390_regset_from_core_section): Ditto.
8133 * sh-tdep.c (sh_register_reggroup_p): Ditto.
8134 * shnbsd-tdep.c (shnbsd_regset_from_core_section): Ditto.
8135 (_initialize_shnbsd_tdep): Declare.
8136 * solib-frv.c (displacement_from_map): Make static.
8137 (_initialize_frv_solib): Declare.
8138 * solib-irix.c (fetch_lm_info): Make static.
8139 (_initialize_irix_solib): Declare.
8140 * solib-som.c: Include solib-som.h.
8141 (som_solib_select): Line break.
8142 * sparc-tdep.c (sparc_regset_from_core_section): Make static.
8143 * sparcnbsd-tdep.c (_initialize_sparnbsd_tdep): Rename to ...
8144 (_initialize_sparcnbsd_tdep): ... this.
8145 * spu-tdep.c (spu_software_single_step): Make it static.
8146 (_initialize_spu_tdep): Declare.
8147 * vax-tdep.c (vax_frame_cache): Make it static.
8148 * xcoffread.c: Include xcoffread.h.
8149 (get_toc_offset): Rename to ...
8150 (xcoff_get_toc_offset): ... this.
8151 (_initialize_xcoffread): Declare.
8152 * xcoffread.h: New.
8153 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Declare.
8154 * xtensa-tdep.c (xtensa_skip_prologue, xtensa_derive_tdep): Make
8155 static.
8156 (_initialize_xtensa_tdep): Declare.
8157
2c0b251b
PA
81582008-02-21 Pedro Alves <pedro@codesorcery.com>
8159
8160 Silence a few -Wmissing-prototypes warnings.
8161
8162 PR build/9877:
8163 * amd64-nat.c: Include "amd64-nat.h".
8164 * fork-child.c (_initialize_fork_child): Ditto.
8165 * gcore.c (_initialize_gcore): Ditto.
8166 * inf-ptrace.c: Include "inf-ptrace.h".
8167 (inf_ptrace_store_registers): Make it static.
8168 * linux-nat.c (linux_nat_terminal_ours): Make it static.
8169 (_initialize_linux_nat): Declare before definition.
8170 * linux-tdep.c: Include "linux-tdep.h".
8171 * linux-thread-db.c (_initialize_thread_db): Declare before
8172 definition.
8173 * proc-service.c (_initialize_proc_service): Ditto.
8174 * remote.c (remote_send_printf): Make it static.
8175 * solib.c: Include "solib.h".
8176 * symfile-mem.c (_initialize_symfile_mem): Declare before
8177 definition.
8178 * ada-lang.c (ada_la_decode, ada_match_name)
8179 (ada_suppress_symbol_printing, ada_is_array_type)
8180 (ada_value_ptr_subscript, ada_array_length)
8181 (ada_to_static_fixed_value): Make them static.
8182 (_initialize_ada_language): Declare before definition.
8183 * ada-tasks.c (ada_get_task_number, ada_get_environment_task)
8184 (ada_task_list_changed, ada_new_objfile_observer): Make them
8185 static.
8186 (_initialize_tasks): Declare before definition.
8187 * addrmap.c (_initialize_addrmap): Declare before definition.
8188 * auxv.c (default_auxv_parse): Make it static.
8189 * bfd-target.c (target_bfd_xfer_partial, target_bfd_xclose): Make
8190 them static.
8191 * breakpoint.c (remove_sal): Add line break.
8192 (expand_line_sal_maybe): Make it static.
8193 * cp-name-parser.y: Include "cp-support.h".
8194 * cp-valprint.c (cp_find_class_member): Make it static.
8195 * eval.c (value_f90_subarray): Ditto.
8196 * exceptions.c (print_any_exception): Ditto.
8197 * findcmd.c (_initialize_mem_search): Declare before definition.
8198 * frame.c (frame_observer_target_changed): Make it static.
8199 * gnu-v3-abi.c (gnuv3_find_method_in): Make it static.
8200 * inf-child.c: Include "inf-child.h".
8201 * inferior.h (valid_inferior_id): Rename to ...
8202 (valid_gdb_inferior_id): ... this.
8203 * infrun.c (infrun_thread_stop_requested, siginfo_make_value):
8204 Make them static.
8205 * jv-lang.c (java_language_arch_info): Make it static.
8206 * m2-typeprint.c (m2_get_discrete_bounds): Ditto.
8207 * osdata.c (info_osdata_command): Make it static.
8208 * regcache.c (regcache_observer_target_changed): Make it static.
8209 * reverse.c (_initialize_reverse): Declare before definition.
8210 * stabsread.c (cleanup_undefined_types_noname)
8211 (cleanup_undefined_types_1): Make them static.
8212 * symfile.c (place_section): Make it static.
8213 * symtab.c (find_pc_sect_psymtab_closer): Make it static.
8214 * target-descriptions.c (_initialize_target_descriptions): Declare
8215 before definition.
8216 * target.c (default_get_ada_task_ptid, find_default_can_async_p)
8217 (find_default_is_async_p, find_default_supports_non_stop): Make
8218 them static.
8219 (target_supports_non_stop): Add prototype.
8220 (dummy_pid_to_str): Make it static.
8221 * utils.c (_initialize_utils): Declare before definition.
8222 * ada-exp.y (_initialize_ada_exp): Declare before definition.
8223 * solib-svr4.c (HAS_LM_DYNAMIC_FROM_LINK_MAP): Add a prototype.
8224 * target.h (struct target_ops): Add a prototype to the
8225 to_can_execute_reverse callback.
a2f63f5e
AS
8226 * macroscope.c (_initialize_macroscope): Declare before definition.
8227 * cp-namespace.c (_initialize_cp_namespace): Declare before definition.
2c0b251b
PA
8228 * python/python.c (_initialize_python): Declare before definition.
8229 * tui/tui-command.c: Include "tui/tui-command.h".
8230 * tui/tui-data.c (init_content_element, init_win_info): Make them
8231 static.
8232 * tui/tui-disasm.c: Include "tui/tui-disasm.h".
8233 * tui/tui-interp.c (_initialize_tui_interp): Declare before
8234 definition.
8235 * tui/tui-layout.c: Include "tui/tui-layout.h".
8236 (_initialize_tui_layout): Declare before definition.
8237 * tui/tui-regs.c: Include "tui/tui-regs.h".
8238 (tui_display_reg_element_at_line): Make it static.
8239 (_initialize_tui_regs): Declare before definition.
8240 * tui/tui-stack.c (_initialize_tui_stack): Declare before
8241 definition.
8242 * tui/tui-win.c: Include "tui/tui-win.h".
8243 (_initialize_tui_win): Declare before definition.
8244 (tui_sigwinch_handler): Make it static. Wrap in ifdef SIGWINCH.
8245 * tui/tui-win.h (tui_sigwinch_handler): Delete declaration.
8246 (tui_get_cmd_list): Add a prototype.
8247 * tui/tui-windata.c: Include tui-windata.h.
8248 * tui/tui-wingeneral.c (box_win): Make it static.
8249 * cli/cli-logging.c (show_logging_command): Make it static.
8250 (_initialize_cli_logging): Declare before definition.
8251 * mi/mi-common.c (_initialize_gdb_mi_common): Declare before
8252 definition.
8253
5aca5a82
PM
82542009-02-20 Pierre Muller <muller@ics.u-strasbg.fr>
8255
08c1f091 8256 Extend use of i386_use_watchpoints to all i386 native files
5aca5a82 8257 using hardware watchpoints.
08c1f091
DE
8258 * go32-nat.c (init_go32_ops): Call i386_use_watchpoints.
8259 * i386fbsd-nat.c (_initialize_i386fbsd_nat): Ditto.
8260 * windows-nat.c (init_windows_ops): Ditto.
8261 * config/i386/nm-cygwin.h: Define I386_WATCHPOINTS_IN_TARGET_VECTOR.
8262 * config/i386/nm-cygwin64.h: Ditto.
8263 * config/i386/nm-fbsd.h: Ditto.
8264 * config/i386/nm-go32.h: Ditto.
5aca5a82 8265
1db300f1
JB
82662009-02-19 Joel Brobecker <brobecker@adacore.com>
8267
8268 * ada-typeprint.c (ada_typedef_print): Remove. Unused.
8269
c86cf029
VP
82702009-02-18 Vladimir Prus <vladimir@codesourcery.com>
8271
8272 * mi/mi-interp.c (mi_solib_loaded, mi_solib_unloaded): New.
8273 (mi_interpreter_init): Register the above.
8274 * solib.c (clear_solib): Notify solib unload.
8275 * breakpoint.c (disable_breakpoints_in_unloaded_shlib): Do not
8276 disable breakpoints on a.out targets.
8277
3ea85240
VP
82782009-02-17 Vladimir Prus <vladimir@codesourcery.com>
8279
8280 * observer.c (observer_test_first_notification_function)
8281 (observer_test_second_notification_function)
8282 (observer_test_third_notification_function): Adjust prototype.
8283
4c1d2973
PA
82842009-02-17 Pedro Alves <pedro@codesourcery.com>
8285
8286 * Makefile.in (ALL_64_TARGET_OBS): Add amd64-dicos-tdep.o.
8287 (ALL_TARGET_OBS): Add dicos-tdep.o.
8288 (ALLDEPFILES): Add amd64-dicos-tdep.c and dicos-tdep.c.
8289 * configure.tgt (i[34567]86-*-dicos*): Add dicos-tdep.o to
8290 gdb_target_obs.
8291 (x86_64-*-dicos*): Add dicos-tdep.o and amd64-dicos-tdep.o to
8292 gdb_target_obs.
8293 * dicos-tdep.h, dicos-tdep.c: New.
8294 * amd64-dicos-tdep.c: New.
8295 * i386-dicos-tdep.c: Don't include solib.h, solib-target.h or
8296 inferior.h. Include dicos-tdep.h.
8297 (i386_dicos_init_abi): Call dicos_init_abi.
8298 (i386_dicos_bfd_has_symbol_p): Delete.
8299 (i386_dicos_osabi_sniffer): Use dicos_load_module_p.
8300
8301 * NEWS: Mention x86-64 DICOS target support.
8302
1903f0e6
DE
83032009-02-16 Doug Evans <dje@google.com>
8304
8305 * amd64-tdep.c (amd64_skip_prefixes): Renamed from skip_prefixes.
8306 All callers updated.
8307 (amd64_get_insn_details): Handle more 3-byte opcode insns.
8308 (amd64_breakpoint_p): Delete.
8309 (amd64_displaced_step_fixup): When fixing up after stepping an int3,
8310 don't back up pc to the start of the int3.
8311 * i386-tdep.c: #include opcode/i386.h.
8312 (i386_skip_prefixes): New function.
8313 (i386_absolute_jmp_p): Constify argument.
8314 (i386_absolute_call_p,i386_ret_p,i386_call_p,i386_syscall_p): Ditto.
8315 (i386_breakpoint_p): Delete.
8316 (i386_displaced_step_fixup): Handle unnecessary or redundant prefixes.
8317 When fixing up after stepping an int3, don't back up pc to the start
8318 of the int3.
8319
959b8724
PA
83202009-02-16 Pedro Alves <pedro@codesourcery.com>
8321
8322 * corelow.c (core_close): Don't hardcode the core's pid.
8323 (core_open): Find core threads before calling
8324 post_create_inferior.
8325 (add_to_thread_list, get_core_register_section): Take into account
8326 systems where the regset section names encode the pid of the
8327 inferior.
8328
8329 * gdbarch.sh (core_reg_section_encodes_pid): New gdbarch setting.
8330 * gdbarch.h, gdbarch.c: Regenerate.
8331
8332 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Set it.
8333 * i386-sol2-tdep.c (i386_sol2_init_abi): Set it.
8334 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Set it.
8335 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Set it.
8336
1d33d6ba
VP
83372009-02-14 Vladimir Prus <vladimir@codesourcery.com>
8338
8339 Include frame information for *stopped due to CLI commands.
8340
a2f63f5e
AS
8341 * ada-tasks.c (ada_normal_stop_observer): Adjust prototype.
8342 * infcmd.c (finish_command_continuation): Pass '1' for
8343 'print_frame' parameter to the observer.
8344 * infrun.c (normal_stop): Don't print mi-specific information
8345 here. Pass 'stop_print_frame' to the 'print_frame' parameter
8346 of the observer.
8347 * mi/mi-interp.c (mi_on_normal_stop): Adjust prototype.
8348 If we need to print frame, and current uiout is not the MI one,
8349 print frame again.
1d33d6ba 8350
2ff5e605
PM
83512009-02-13 Pierre Muller <muller@ics.u-strasbg.fr>
8352
8353 * xtensa-tdep.c (call0_analyze_prologue): Delete BSZ macro.
8354 Replace BSZ macro uses by XTENSA_ISA_BSZ macro.
8355
5d7cb8df
JK
83562009-02-12 Jan Kratochvil <jan.kratochvil@redhat.com>
8357
8358 PR fortran/9806
8359 * dwarf2read.c (process_die <DW_TAG_module>, read_module)
8360 (scan_partial_symbols <DW_TAG_module>, add_partial_module): New.
8361
868a0084
PM
83622009-02-11 Pierre Muller <muller@ics.u-strasbg.fr>
8363
8364 * dwarf2read.c (read_base_type): Set code to TYPE_CODE_CHAR
5d7cb8df 8365 for DW_ATE_signed_char and DW_ATE_unsigned_char
868a0084
PM
8366 for pascal language.
8367
42e2132c
JK
83682009-02-11 Jim Meyering <meyering@redhat.com>
8369 Jan Kratochvil <jan.kratochvil@redhat.com>
8370
8371 Avoid NULL dereference.
8372 * stack.c (return_command): Guard use of SYMBOL_TYPE (thisfun).
8373 New variable func_type.
8374
315aef0a
PA
83752009-02-11 Pedro Alves <pedro@codesourcery.com>
8376
8377 * gdbarch.c: Regenerate.
8378
58159490
PM
83792009-02-10 Pierre Muller <muller@ics.u-strasbg.fr>
8380
8381 * p-lang.c (is_pascal_string_type): Fix comment.
8382 Determine exact size of char elements for GPC
8383 strings.
8384 (pascal_printstr): Handle char width of 2 or 4.
8385 * p-valprint.c (pascal_val_print): Handle char
8386 of width 2 or 4.
a2f63f5e 8387
d3f36a39
DJ
83882009-02-07 Daniel Jacobowitz <dan@codesourcery.com>
8389
8390 * dwarf2read.c (dwarf2_build_psymtabs_hard): Move lowpc and highpc
8391 inside the loop. Only call addrmap_set_empty if the compilation unit
8392 had DW_AT_high_pc and DW_AT_low_pc. Update call to
8393 scan_partial_symbols.
8394 (scan_partial_symbols): Take NEED_PC argument and pass it along with
8395 LOWPC and HIGHPC.
8396 (add_partial_namespace): Take NEED_PC argument and pass it through.
8397 (add_partial_subprogram): Take NEED_PC argument. Update the addrmap
8398 if necessary.
8399
47a3467a
PA
84002009-02-07 Pedro Alves <pedro@codesourcery.com>
8401
8402 * NEWS: Mention inspecting extra signal information, $_siginfo,
8403 and the qXfer:siginfo:read and qXfer:siginfo:write packets.
8404
1ef18d08
PA
84052009-02-07 Pedro Alves <pedro@codesourcery.com>
8406
8407 * linux-nat.c (PTRACE_SETSIGINFO): Define if PTRACE_GETSIGINFO
8408 isn't defined.
8409
5b009018
PA
84102009-02-06 Pedro Alves <pedro@codesourcery.com>
8411
8412 * amd64-linux-nat.c (compat_int_t, compat_uptr_t, compat_time_t)
8413 (compat_timer_t, compat_clock_t, struct compat_timeval)
8414 (compat_sigval_t, compat_siginfo_t): New types.
8415 (cpt_si_pid, cpt_si_uid, cpt_si_timerid, cpt_si_overrun)
8416 (cpt_si_status, cpt_si_utime, cpt_si_stime, cpt_si_ptr)
8417 (cpt_si_addr, cpt_si_band, cpt_si_fd): New defines.
8418 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
8419 (amd64_linux_siginfo_fixup): New.
8420 * linux-nat.c (linux_nat_siginfo_fixup): New.
8421 (siginfo_fixup): New.
8422 (linux_xfer_siginfo): Use siginfo_fixup to convert between the
8423 siginfo layout expected by ptrace and the siginfo layout of the
8424 inferior.
8425 (linux_nat_set_siginfo_fixup): New.
8426 * linux-nat.h (linux_nat_set_siginfo_fixup): Declare.
8427
4aa995e1
PA
84282009-02-06 Pedro Alves <pedro@codesourcery.com>
8429
8430 * target.h (enum target_object): Add new TARGET_OBJECT_SIGNAL_INFO.
8431 * infrun.c (siginfo_value_read, siginfo_value_write): New.
8432 (siginfo_value_funcs): New.
8433 (siginfo_make_value): New.
8434 (_initialize_infrun): Create the $_siginfo convenience variable.
8435 * gdbtypes.h (append_composite_type_field_aligned): Declare.
8436 * gdbtypes.c (append_composite_type_field): Rename to...
8437 (append_composite_type_field_aligned): ... this. Add ALIGNMENT
8438 argument. Handle it.
8439 (append_composite_type_field): Rewrite on top of
8440 append_composite_type_field_aligned.
8441 * value.h (internalvar_make_value): New typedef.
8442 (struct internalvar) <make_value>: New field.
8443 (create_internalvar_type_lazy): Declare.
8444 * value.c (create_internalvar): Clear make_value.
8445 (create_internalvar_type_lazy): New.
8446 (value_of_internalvar): If make_value is set use it.
8447 (preserve_values): Skip internal variables that don't have a
8448 value.
8449 * gdbarch.sh (get_siginfo_type): New.
8450 * gdbarch.h, gdbarch.c: Regenerate.
8451
8452 * linux-tdep.h, linux-tdep.c: New.
8453 * amd64-linux-tdep.c: Include "linux-tdep.h".
8454 (amd64_linux_init_abi): Register linux_get_siginfo_type and
8455 linux_get_siginfo_mapper.
8456 * i386-linux-tdep.c: Include "linux-tdep.h".
8457 (i386_linux_init_abi): Register linux_get_siginfo_type and
8458 linux_get_siginfo_mapper.
8459 * arm-linux-tdep.c: Include "linux-tdep.h".
8460 (i386_linux_init_abi): Register linux_get_siginfo_type and
8461 linux_get_siginfo_mapper.
8462
8463 * linux-nat.c (linux_xfer_siginfo): New.
8464 (linux_nat_xfer_partial): Handle TARGET_OBJECT_SIGNAL_INFO.
8465 * remote.c (PACKET_qXfer_siginfo_read)
8466 (PACKET_qXfer_siginfo_write): New.
8467 (feature remote_protocol_features): Add "qXfer:siginfo:read" and
8468 "qXfer:siginfo:write" features.
8469 (remote_xfer_partial): Handle TARGET_OBJECT_SIGNAL_INFO.
8470 (_initialize_remote): Add "set/show remote read-siginfo-object"
8471 and "set/show remote write-siginfo-object" commands.
8472
8473 * Makefile.in (ALL_TARGET_OBS): Add linux-tdep.o.
8474 (HFILES_NO_SRCDIR): Add linux-tdep.h.
8475 (ALLDEPFILES): Add linux-tdep.c.
a2f63f5e 8476
4aa995e1
PA
8477 * configure.tgt (arm*-*-linux* | arm*-*-uclinux*)
8478 (i[34567]86-*-linux*, x86_64-*-linux*): Add linux-tdep.o to
8479 gdb_target_obs.
8480
5f5233d4
PA
84812009-02-06 Jim Blandy <jimb@codesourcery.com>
8482 Daniel Jacobowitz <dan@codesourcery.com>
8483 Vladimir Prus <vladimir@codesourcery.com>
8484 Pedro Alves <pedro@codesourcery.com>
8485
8486 * defs.h (enum lval_type): New value: lval_computed.
8487 * value.h (struct lval_funcs): New type.
8488 (allocate_computed_value, value_computed_funcs)
8489 (value_computed_closure): New declarations.
8490 * value.c (struct value): Add a structure to the location union
8491 for computed lvalues, containing 'funcs' and 'closure' members.
8492 (allocate_computed_value, value_computed_funcs)
8493 (value_computed_closure): New functions.
8494 (value_free): For computed lvalues, call the closure's
8495 'free_closure' function before freeing the value itself.
8496 (value_copy): If we're copying an lval_computed value, call the
8497 closure's 'copy_closure' function.
8498 (set_value_component_location): If the original value is a
8499 computed lvalue, then call the closure's 'copy_closure' function.
8500 (value_of_internalvar): If an internal variable's value is a
8501 computed lvalue, make retrieving its value produce an equivalent
8502 computed lvalue.
8503 * valops.c (value_fetch_lazy): Unlazy computed lvalues by calling
8504 their read function.
8505 (value_assign): Assign to computed lvalues by calling their write
8506 function.
8507
117de6a9
PA
85082009-02-06 Pedro Alves <pedro@codesourcery.com>
8509
8510 * linux-nat.c (linux_nat_wait): Adjust.
8511 (linux_nat_pid_to_str): Adjust. Remove call to thread_db_init.
8512 * linux-nat.h (thread_db_init): Delete declaration.
8513 * linux-thread-db.c (target_beneath): Delete.
8514 (thread_db_init): Delete.
8515 (thread_db_detach): Use find_target_beneath.
8516 (thread_db_wait): Adjust interface. Use find_target_beneath.
8517 (thread_db_mourn_inferior): Use find_target_beneath.
8518 (thread_db_can_async_p, thread_db_is_async_p, thread_db_async)
8519 (thread_db_async_mask): Delete.
8520 (thread_db_pid_to_str): Adjust interface. Use
8521 find_target_beneath.
8522 (thread_db_get_thread_local_address): Adjust interface. Use
8523 find_target_beneath.
8524 (init_thread_db_ops): Delete references to delete functions.
8525 * target.c (update_current_target): Don't inherit or default
8526 to_wait. Don't inherit to_pid_to_str and
8527 to_get_thread_local_address.
8528 (target_translate_tls_address): Look for a pushed target that
8529 implements to_get_thread_local_address, and use it instead of
8530 checking for target_get_thread_local_address_p.
8531 (target_wait, target_pid_to_str): Reimplement as functions.
8532 (dummy_pid_to_str): New.
8533 (init_dummy_target): Register it.
8534 (debug_to_wait): Delete.
8535 * target.h (struct target_ops): Make to_wait, to_pid_to_str and
8536 to_get_thread_local_address accept a pointer to struct target_ops.
8537 (target_wait): Delete macro, and declare as function.
8538 (target_pid_to_str): Likewise.
8539 (target_get_thread_local_address)
8540 (target_get_thread_local_address_p): Delete.
8541 (noprocess): Add NORETURN and ATTR_NORETURN tags.
8542 * inf-ptrace.c (inf_ptrace_wait): Adjust.
8543 (inf_ptrace_pid_to_str): New.
8544 (inf_ptrace_target): Use inf_ptrace_pid_to_str.
8545 * aix-thread.c (aix_thread_wait, aix_thread_pid_to_str): Adjust.
8546 * bsd-kvm.c (bsd_kvm_pid_to_str): Adjust.
8547 * bsd-uthread.c (bsd_uthread_wait, bsd_uthread_pid_to_str):
8548 Adjust.
8549 * corelow.c (core_pid_to_str): Adjust.
8550 * darwin-nat.c (darwin_wait, darwin_pid_to_str): Adjust.
8551 * dec-thread.c (dec_thread_wait, dec_thread_pid_to_str): Adjust.
8552 * gnu-nat.c (gnu_wait, gnu_pid_to_str): Adjust.
8553 * go32-nat.c (go32_wait, go32_pid_to_str): Adjust.
8554 * hpux-thread.c (hpux_thread_wait): Adjust.
8555 * inf-ttrace.c (inf_ttrace_wait, inf_ttrace_pid_to_str): Adjust.
8556 * monitor.c (monitor_wait, monitor_pid_to_str): Adjust.
8557 * nto-procfs.c (procfs_wait, procfs_pid_to_str): Adjust.
8558 * procfs.c (procfs_pid_to_str): Adjust.
8559 * remote-m32r-sdi.c (m32r_wait, m32r_pid_to_str): Adjust.
8560 * remote-mips.c (mips_wait): Adjust.
8561 * remote-sim.c (gdbsim_wait, gdbsim_pid_to_str): Adjust.
8562 * remote.c (remote_wait, remote_pid_to_str)
8563 (remote_get_thread_local_address): Adjust.
8564 * rs6000-nat.c (rs6000_wait): Adjust.
8565 * sol-thread.c (procfs_pid_to_str): Adjust declaration.
8566 (sol_thread_wait, solaris_pid_to_str): Adjust.
8567 * spu-linux-nat.c (spu_child_wait): Adjust.
8568 * windows-nat.c (windows_wait, windows_pid_to_str): Adjust.
8569
d8906c6f
TJB
85702009-02-06 Tom Tromey <tromey@redhat.com>
8571
8572 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-cmd.o.
8573 (SUBDIR_PYTHON_SRCS): Add python-cmd.c.
8574 (python-cmd.o): New target.
8575 * cli/cli-decode.c (set_cmd_completer): Add self parameter to
8576 completer prototype.
8577 (add_cmd): Initialize destroyer member of cmd_list_element. Use
8578 make_symbol_completion_list_fn as completer.
8579 (delete_cmd): Call destroyer if one is set.
8580 * cli/cli-decode.h (cmd_list_element): Add cmd parameter to
8581 completer member. Add destroyer member.
8582 (set_cmd_completer): Add self parameter to
8583 completer prototype.
8584 * command.h (set_cmd_completer): Add cmd parameter to
8585 completer prototype.
8586 * completer.c (noop_completer, filename_completer,
8587 location_completer, expression_completer, command_completer): Adapt
8588 to new completer prototype.
8589 (complete_line_internal): Pass new parameter to completer function.
8590 * completer.h (noop_completer, filename_completer,
8591 location_completer, expression_completer, command_completer): Adapt
8592 prototypes to new completer prototype.
8593 * interps.c (interpreter_completer): Adapt to new completer
8594 prototype.
8595 * python/python-cmd.c: New file.
8596 * python/python-internal.h (gdbpy_initialize_commands): Add
8597 prototype.
8598 (gdbpy_doc_cst): Add forward declaration.
8599 * python/python.c (gdbpy_doc_cst): Declare.
8600 (_initialize_python): Call gdbpy_initialize_commands. Initialize
8601 gdbpy_doc_cst.
8602 * symtab.c (make_symbol_completion_list_fn): New function.
8603 * symtab.h (make_symbol_completion_list_fn): Add prototype.
8604
739ef7fb
PA
86052009-02-06 Pedro Alves <pedro@codesourcery.com>
8606
8607 * target.c (target_get_osdata): Check for equal or higher than
8608 process_stratum, not dummy_stratum.
8609
6d097e65
PA
86102009-02-06 Pedro Alves <pedro@codesourcery.com>
8611
8612 * remote.c (extended_remote_can_run): Delete.
8613 (init_remote_ops): Don't register it.
8614 * target.c (target_get_osdata): Don't check for target_can_run.
8615 Instead any target that has already been pushed, otherwise
739ef7fb 8616 fallback to the default run target.
6d097e65 8617
947b8855
PA
86182009-02-06 Pedro Alves <pedro@codesourcery.com>
8619
8620 * target.c (target_create_inferior, target_detach)
8621 (target_mourn_inferior, target_attach, target_close): Do target
8622 debug output.
8623 (debug_to_attach, debug_to_detach, debug_to_create_inferior)
8624 (debug_to_mourn_inferior, debug_to_close): Delete.
8625 (setup_target_debug): Adjust.
8626
611041af
PA
86272009-02-05 Pedro Alves <pedro@codesourcery.com>
8628
8629 * target.h (target_stopped_data_address_p): Delete declaration,
8630 and don't define as macro.
8631 * target.c (target_stopped_data_address_p): Delete.
8632
b6cb8e7d
TJB
86332009-02-05 Thiago Jung Bauermann <bauerman@br.ibm.com>
8634 Tom Tromey <tromey@redhat.com>
8635
8636 * python/python-utils.c (target_string_to_unicode): New function.
8637 * python/python-internal.h (target_string_to_unicode): New prototype.
8638 * python/python-value.c (valpy_string): New function.
8639 (value_object_methods): Add `string' entry.
8640
54ba13f7
PA
86412009-02-05 Pedro Alves <pedro@codesourcery.com>
8642
8643 * target.h (target_tid_to_str): Delete.
8644 * thread.c (print_thread_info, thread_apply_all_command)
8645 (thread_apply_command, thread_command, do_captured_thread_select):
8646 Use target_pid_to_str instead of target_tid_to_str.
8647 * linux-fork.c (delete_fork_command): Likewise.
8648
9d49bdc2
PA
86492009-02-05 Pedro Alves <pedro@codesourcery.com>
8650
8651 * frame.c (has_stack_frames): Make public.
8652 (get_prev_frame): Don't allow a NULL this_frame anymore.
8653 * frame.h (has_stack_frames): Declare.
8654 * varobj.c (find_frame_addr_in_frame_chain): Don't ever pass NULL
8655 to get_prev_frame, instead start at get_current_frame.
8656 (varobj_create): Check has_stack_frames before getting any frame;
8657 eliminate one usage of deprecated_safe_get_selected_frame.
8658
12453b93
TJB
86592009-02-05 Tom Tromey <tromey@redhat.com>
8660 Thiago Jung Bauermann <bauerman@br.ibm.com>
8661
8662 * python/python.c (GdbMethods): Move to bottom of file.
8663 (get_parameter, execute_gdb_command, gdbpy_write,
8664 gdbpy_flush): Remove forward declarations.
8665 (eval_python_from_control_command): Fix error checking of function
8666 PyRun_SimpleString. Fix error string.
8667 (python_command): Likewise.
8668 (execute_gdb_command): Added from_tty argument.
8669
ae6a3a4c
TJB
86702009-02-05 Thiago Jung Bauermann <bauerman@br.ibm.com>
8671
8672 * language.h (language_dfn): Add la_get_string member.
8673 (LA_GET_STRING): New macro.
8674 (default_get_string): New prototype.
8675 * language.c (default_get_string): New function.
8676 (unknown_language_defn, auto_language_defn, local_language_defn): Use
8677 default_get_string for la_get_string.
8678 * c-lang.c (c_get_string): New function.
8679 (c_language_defn, cplus_language_defn, asm_language_defn): Use
8680 c_get_string for la_get_string.
8681 (minimal_language_defn): Likewise
8682 * ada-lang.c (ada_language_defn): Likewise.
8683 * f-lang.c (f_language_defn): Use default_get_string for
8684 la_get_string.
8685 * jv-lang.c (java_language_defn): Likewise.
8686 * m2-lang.c (m2_language_defn): Likewise.
8687 * objc-lang.c (objc_language_defn): Likewise.
8688 * p-lang.c (p_language_defn): Likewise.
8689 * scm-lang.c (scm_language_defn): Likewise.
8690 * typeprint.c (type_to_string): New function.
8691 * value.h (type_to_string): New prototype.
8692 * valprint.c (val_print_string): Factor out code for reading string
8693 from the inferior into its own function. Put 2 spaces after period
8694 in comments.
8695 (read_string): New function.
8696 * valprint.h (read_string): New prototype.
8697
fa8a61dc
TT
86982009-01-07 Pierre Muller <muller@ics.u-strasbg.fr>
8699 Tom Tromey <tromey@redhat.com>
8700
8701 PR breakpoints/8079:
8702 * breakpoint.c (print_one_breakpoint): Use exp_string field
8703 to display expression of watchpoints.
8704 (mention): Likewise.
8705 (watch_command_1): Remove trailing whitespace from expression.
8706 * printcmd.c (struct display) <exp_string>: New field.
8707 (display_command): Set exp_string.
8708 (free_display): Free exp_string.
8709 (clear_displays): Use free_display.
8710 (do_one_display): Print exp_string.
8711 (display_info): Likewise.
8712
08c637de
TJB
87132009-02-04 Tom Tromey <tromey@redhat.com>
8714 Thiago Jung Bauermann <bauerman@br.ibm.com>
8715 Phil Muldoon <pmuldoon@redhat.com>
8716
8717 * python/python-internal.h (gdbpy_get_value_from_history): Rename
8718 prototype to gdbpy_history.
8719 (gdbpy_is_string): Declare.
8720 (python_string_to_host_string): Declare.
8721 * python/python-utils.c (gdbpy_is_string): New function.
8722 (unicode_to_encoded_string): New function.
8723 (unicode_to_target_string): Use it.
8724 (python_string_to_host_string): New function.
8725 * python/python-value.c (valpy_address): New function.
8726 (convert_value_from_python): Use gdbpy_is_string. Change to throw
8727 Python exception instead of a GDB exception on error. Properly check
8728 Python booleans.
8729 (valpy_getitem): Convert field name to host string. Handle array
8730 accesses. Adapt to new behaviour of convert_value_from_python.
8731 (valpy_new): Adapt to new behaviour of convert_value_from_python.
8732 (enum valpy_opcode) <VALPY_LSH, VALPY_RSH, VALPY_BITAND,
8733 VALPY_BITXOR, VALPY_BITOR>: New constants.
8734 (valpy_binop): Update. Adapt to new behaviour of
8735 convert_value_from_python.
8736 (valpy_invert): New function.
8737 (valpy_lsh): Likewise.
8738 (valpy_rsh): Likewise.
8739 (valpy_and): Likewise.
8740 (valpy_or): Likewise.
8741 (valpy_xor): Likewise.
8742 (valpy_richcompare): Call convert_value_from_python instead of doing
8743 conversions itself.
8744 (is_intlike, valpy_int, valpy_long, valpy_float): New functions.
8745 (gdbpy_get_value_from_history): Rename
8746 function to gdbpy_history.
8747 (gdbpy_initialize_values): Don't set tp_new.
8748 (value_object_type): Add valpy_new.
8749 (value_object_methods): Add `address' entry.
8750 (value_object_as_number): Update for new methods.
8751 * python/python.c (GdbMethods): Rename entry from
8752 `get_value_from_history' to `history'.
8753
538e13a6 87542009-02-04 Jerome Guitton <guitton@adacore.com>
b5304971
JG
8755
8756 * ada-lang.c (ada_template_to_fixed_record_type_1): Check size
8757 of type to guard against a crash.
8758
33d502b4
JG
87592009-02-04 Jerome Guitton <guitton@adacore.com>
8760
8761 * value.c (value_from_contents_and_address): Always return
8762 a lval_memory value, even if address is null.
8763
9f08ae4f
TG
87642009-02-04 Tristan Gingold <gingold@adacore.com>
8765
8766 * i386-darwin-tdep.c (i386_darwin_sigcontext_addr): New function.
8767 (amd64_darwin_sigcontext_addr): Ditto.
8768 (darwin_dwarf_signal_frame_p): Ditto.
8769 (i386_darwin_init_abi): Handle signal frames, use the const for
8770 sc_num_regs.
8771 (x86_darwin_init_abi_64): Ditto.
8772
4bd207ef
TG
87732009-02-04 Tristan Gingold <gingold@adacore.com>
8774
8775 * i386-tdep.c (i386_sigtramp_p): Make it public.
8776 * i386-tdep.h (i386_sigtramp_p): Declare.
8777
4aa99a88
TG
87782009-02-04 Tristan Gingold <gingold@adacore.com>
8779
8780 * machoread.c (macho_symfile_read): Read minsymtab also from
8781 shared libraries.
8782 (macho_symfile_read): Try to read dwarf2 frame info from main
8783 object file, but not from OSO files.
8784 (macho_symfile_offsets): Update section names for latest BFD
8785 changes.
8786 * i386-darwin-tdep.c (i386_darwin_init_abi): Call set_solib_ops.
8787 (x86_darwin_init_abi_64): Ditto.
8788 * solib-darwin.c: New file.
8789 * solib-darwin.h: New file.
8790 * configure.tgt: Add solib.o solib-darwin.o for Darwin.
8791
7a848be1
TG
87922009-02-04 Tristan Gingold <gingold@adacore.com>
8793
8794 * solist.h (struct target_so_ops): Comment fallback behavior for
8795 operation same.
8796
b32d97f3
TT
87972009-02-03 Tom Tromey <tromey@redhat.com>
8798
8799 * completer.c (add_struct_fields): Check type_name against NULL
8800 before use.
8801
692263b8
JB
88022009-02-03 Joel Brobecker <brobecker@adacore.com>
8803
8804 * MAINTAINERS: Update Elena's email address.
8805
bfa149ac
JB
88062009-02-02 Joel Brobecker <brobecker@adacore.com>
8807
8808 * breakpoint (update_watchpoint): Minor comment adjustment.
8809
1c71341a
TT
88102009-02-02 Tom Tromey <tromey@redhat.com>
8811
52e44b43 8812 PR gdb/9594:
1c71341a
TT
8813 * completer.c (count_struct_fields): Count method names.
8814 (add_struct_fields): Add matching method names.
8815
85541719
DE
88162009-02-02 Doug Evans <dje@google.com>
8817
8818 * configure.ac (gdbkt): Check both no_tcl/no_tk first, before
8819 doing any further tcl/tk configury. Don't configure gdbtk if
8820 tcl or tk check fails.
8821 * aclocal.m4: Regenerate.
8822 * configure: Regenerate.
8823
a4295225
TT
88242009-02-02 Tom Tromey <tromey@redhat.com>
8825
8826 PR exp/9059:
8827 * valops.c (find_overload_match): Follow typedefs before taking
8828 address of object argument.
8829
f00150c9
DE
88302009-02-01 Doug Evans <dje@google.com>
8831
8832 * target.h (target_waitstatus_to_string): Declare.
8833 * target.c (target_waitstatus_to_string): New function. Copied from
8834 debug_to_wait. Add missing entries for TARGET_WAITKIND_SYSCALL_ENTRY,
8835 TARGET_WAITKIND_SYSCALL_RETURN, TARGET_WAITKIND_IGNORE,
8836 TARGET_WAITKIND_NO_HISTORY.
8837 (debug_to_wait): Call it.
8838 * infrun.c (wait_for_inferior): If debug_infrun, print result of
8839 target_wait.
8840 (fetch_inferior_event): Ditto.
8841
5abdf4bd
TT
88422009-01-30 Tom Tromey <tromey@redhat.com>
8843
8844 * Makefile.in (HFILES_NO_SRCDIR): Remove i386-cygwin-tdep.h.
8845
592375cd
VP
88462009-01-30 Vladimir Prus <vladimir@codesourcery.com>
8847
8848 PR 8145.
8849 * thread.c (do_captured_list_thread_ids): Report the current
8850 thread id.
8851
41447f92
VP
88522009-01-30 Vladimir Prus <vladimir@codesourcery.com>
8853
8854 * breakpoint.c (create_breakpoint, create_breakpoints)
8855 (break_command_really, set_breakpoint): New parameter enabled.
8856 (create_breakpoint, break_command_really): Make breakpoint
8857 disabled if so requested.
8858 * breakpoint.h (set_breakpoint): New parameter enabled.
8859 * mi/mi-cmd-break.c (mi_cmd_break_insert): Handle the -d option.
8860
35669430
DE
88612009-01-28 Doug Evans <dje@google.com>
8862
8863 * amd64-tdep.h (amd64_displaced_step_copy_insn): Declare.
8864 (amd64_displaced_step_fixup): Declare.
8865 * amd64-tdep.c: #include opcode/i386.h, dis-asm.h.
8866 (amd64_arch_regmap): Move out of amd64_analyze_stack_align
8867 and make static global.
8868 (amd64_arch_regmap_len): New static global.
8869 (amd64_arch_reg_to_regnum): New function.
8870 (struct amd64_insn): New struct.
8871 (struct displaced_step_closure): New struct.
8872 (onebyte_has_modrm,twobyte_has_modrm): New static globals.
8873 (rex_prefix_p,skip_prefixes)
8874 (amd64_insn_length_fprintf,amd64_insn_length_init_dis)
8875 (amd64_insn_length,amd64_get_unused_input_int_reg)
8876 (amd64_get_insn_details,fixup_riprel,fixup_displaced_copy)
8877 (amd64_displaced_step_copy_insn)
8878 (amd64_absolute_jmp_p,amd64_absolute_call_p,amd64_ret_p)
8879 (amd64_call_p,amd64_breakpoint_p,amd64_syscall_p)
8880 (amd64_displaced_step_fixup): New functions.
8881 * amd64-linux-tdep.c: #include arch-utils.h.
8882 (amd64_linux_init_abi): Install displaced stepping support.
8883
4eb7c016
JG
88842009-01-28 Daniel Jacobowitz <dan@codesourcery.com>
8885 Jerome Guitton <guitton@adacore.com>
8886
8887 * configure, config.in: Regenerated.
8888 * configure.ac: Add --with-system-gdbinit.
8889 * main.c (get_init_files): New.
8890 (captured_main): Use get_init_files. Load system gdbinit before
8891 $HOME/.gdbinit.
8892 (print_gdb_help): Print location of init files.
8893
7df3ce47
PA
88942009-01-28 Pedro Alves <pedro@codesourcery.com>
8895
8896 * corefile.c (generic_search): Delete disabled code.
8897 * gdbcore.h (generic_search): Delete declaration.
8898
77435e4c
PA
88992009-01-26 Pedro Alves <pedro@codesourcery.com>
8900
8901 * linux-nat.c (linux_child_follow_fork): Copy attach_flag from the
8902 parent to the child.
8903 * inf-ttrace.c (inf_ttrace_follow_fork): Likewise.
8904 * inf-ptrace.c (inf_ptrace_follow_fork): Likewise. Use
8905 remove_breakpoints to remove breakpoints from the parent.
8906
1e275f79
PA
89072009-01-26 Pedro Alves <pedro@codesourcery.com>
8908
7488432f 8909 PR backtrace/9458, PR backtrace/8864:
1e275f79
PA
8910 * frame.c (create_new_frame): Update the frame's cached PC before
8911 finding its unwinder. Use frame_id_build to build the new frame's
8912 id.
8913 * stack.c (parse_frame_specification_1): Correct setting ``addrs''
8914 array values from the ``args'' array values.
8915
1deafd4e
PA
89162009-01-26 Pedro Alves <pedro@codesourcery.com>
8917
8918 * gdbtypes.c (alloc_type, alloc_type_instance, create_range_type)
8919 (create_array_type, create_set_type, init_flags_type)
8920 (copy_type_recursive): Replace pairs of calls to XALLOC and memset
8921 with a call to XZALLOC or XCALLOC, and pairs of calls to
8922 obstack_alloc and memset with a call to OBSTACK_ZALLOC.
8923
3c16cced
PA
89242009-01-26 Pedro Alves <pedro@codesourcery.com>
8925
8926 Add "maint set|show internal-error|internal-warning quit|corefile
8927 ask|yes|no" commands.
8928
8929 PR gdb/7580:
8930 * utils.c (internal_problem_ask, internal_problem_yes)
8931 (internal_problem_no, internal_problem_modes): New.
8932 (struct internal_problem): Remove FIXME. Make should_quit and
8933 should_dump_core types to char *.
8934 (internal_vproblem, internal_error_problem)
8935 (internal_warning_problem): Adjust.
8936 (set_internal_problem_cmd, show_internal_problem_cmd): New dummy
8937 functions.
8938 (add_internal_problem_command): New.
8939 (_initialize_utils): New.
8940
616d7dd2
PA
89412009-01-25 Pedro Alves <pedro@codesourcery.com>
8942
8943 * infcmd.c (program_info): Use paddress instead of casting stop_pc
8944 to unsigned long.
8945
0516318b
PA
89462009-01-24 Pedro Alves <pedro@codesourcery.com>
8947
8948 * infrun.c (normal_stop): Don't call
8949 deprecated_update_frame_pc_hack.
8950 * frame.c (deprecated_update_frame_pc_hack)
8951 (deprecated_update_frame_base_hack): Delete, and ...
8952 (create_new_frame): ... inline here.
8953 * frame.h (deprecated_update_frame_pc_hack)
8954 (deprecated_update_frame_base_hack): Delete declarations.
8955
1e8fb976
PA
89562009-01-23 Pedro Alves <pedro@codesourcery.com>
8957
8958 * cli/cli-decode.c (add_setshow_zuinteger_cmd): New.
8959 * cli/cli-setshow.c (do_setshow_command): Handle it.
8960 * command.h (enum var_types): Add var_zuinteger.
8961 (add_setshow_zuinteger_cmd): Declare.
8962
8963 * valprint.c (_initialize_valprint): Change the set input-radix
8964 and set output-radix commands to zuinteger type.
8965
dd7e2d2b
PA
89662009-01-23 Pedro Alves <pedro@codesourcery.com>
8967
8968 PR gdb/9664:
8969 * infrun.c (normal_stop): Tag threads as stopped, and run the
8970 hook-stop before printing the stack frame.
8971
392452f6
PA
89722009-01-22 Pedro Alves <pedro@codesourcery.com>
8973
8974 PR c++/9631:
8975 * gnu-v3-abi.c (gnuv3_baseclass_offset): Call check_typedef on
8976 vbasetype.
8977
f6a96b83
KH
89782009-01-20 Kazu Hirata <kazu@codesourcery.com>
8979
8980 * gdb/procfs.c (info_mappings_callback): Cast map->pr_size to
8981 unsigned long.
8982
5d277928 89832009-01-20 Daniel Jacobowitz <dan@codesourcery.com>
a12cc160
DJ
8984
8985 PR gdb/9346
8986 * infcmd.c (signal_command): Do not specify a resume PC.
8987
b89667eb
DE
89882009-01-19 Doug Evans <dje@google.com>
8989
8990 * dummy-frame.c (dummy_frame): Replace regcache member with
8991 caller_state.
8992 (dummy_frame_push): Replace caller_regcache arg with caller_state.
8993 All callers updated.
8994 (remove_dummy_frame,pop_dummy_frame,lookup_dummy_frame): New fns.
8995 (dummy_frame_pop): Rewrite. Verify requested frame is in the
8996 dummy frame stack. Restore program state.
8997 (cleanup_dummy_frames): Rewrite.
8998 (dummy_frame_sniffer): Update. Make static.
8999 * dummy-frame.h (regcache,frame_info): Delete forward decls.
9000 (inferior_thread_state): New forward decl.
9001 (dummy_frame_push): Update prototype.
9002 * frame.c (frame_pop): dummy_frame_pop now does all the work for
9003 DUMMY_FRAMEs.
9004 * infcall.c (breakpoint_auto_delete_contents): Delete.
9005 (get_function_name,run_inferior_call): New fns.
9006 (call_function_by_hand): Simplify by moving some code to
9007 get_function_name, run_inferior_call. Inferior function call wrapped
9008 in TRY_CATCH so there's less need for cleanups and all exits from
9009 proceed are handled similarily. Detect program exit.
9010 Detect program stopping in a different thread.
9011 Make error messages more consistent.
9012 * inferior.h (inferior_thread_state): Declare (opaque type).
9013 (save_inferior_thread_state,restore_inferior_thread_state,
9014 make_cleanup_restore_inferior_thread_state,
9015 discard_inferior_thread_state, get_inferior_thread_state_regcache):
9016 Declare.
9017 (save_inferior_status): Update prototype.
9018 * infrun.c: (normal_stop): When stopped for the completion of an
9019 inferior function call, verify the expected stack frame kind.
9020 (inferior_thread_state): New struct.
9021 (save_inferior_thread_state,restore_inferior_thread_state,
9022 do_restore_inferior_thread_state_cleanup,
9023 make_cleanup_restore_inferior_thread_state,
9024 discard_inferior_thread_state,
9025 get_inferior_thread_state_regcache): New functions.
9026 (inferior_status): Move stop_signal, stop_pc, registers to
9027 inferior_thread_state. Remove restore_stack_info.
9028 (save_inferior_status): Remove arg restore_stack_info.
9029 All callers updated. Remove saving of state now saved by
9030 save_inferior_thread_state.
9031 (restore_inferior_status): Remove restoration of state now done by
9032 restore_inferior_thread_state.
9033 (discard_inferior_status): Remove freeing of registers, now done by
9034 discard_inferior_thread_state.
9035
aefc7064
PA
90362009-01-18 Pedro Alves <pedro@codesourcery.com>
9037
9038 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Scroll one line
9039 at a time, times NUM_TO_SCROLL.
9040 * tui/tui-winsource.c (tui_horizontal_source_scroll): Don't try to
9041 fetch the selected frame if there is no stack.
9042
29f49a6a
PA
90432009-01-18 Pedro Alves <pedro@codesourcery.com>
9044
9045 PR gdb/9747:
9046 * gdbthread.h (finish_thread_state, finish_thread_state_cleanup):
9047 Declare.
9048 * thread.c (finish_thread_state, finish_thread_state_cleanup): New.
9049 * infrun.c (wait_for_inferior, fetch_inferior_event): If an error
9050 is thrown while handling an event, finish the thread state.
9051 (normal_stop): Use finish_thread_state cleanup.
9052 * infcmd.c (run_command_1): If an error is thrown while starting
9053 the inferior, finish the thread state.
9054
e7243d73
PA
90552009-01-18 Pedro Alves <pedro@codesourcery.com>
9056
9057 * tui/tui-winsource.c (tui_update_breakpoint_info): In asm layout,
9058 skip breakpoints without a location (pending breakpoints).
9059
e74994b5
PA
90602009-01-18 Pedro Alves <pedro@codesourcery.com>
9061
9062 PR build/9186:
9063 * hppa-hpux-tdep.c (hppa_hpux_write_pc): Remove 'return'.
9064
8405c36e
NR
90652009-01-18 Nick Roberts <nickrob@snap.net.nz>
9066
9067 * thread.c (thread_command): Move call to annotate_thread_changed
9068 to...
9069 (do_captured_thread_select): ... here, to avoid printing an
9070 annotation if the thread change generates an exception.
9071
b8bfd3ed
JB
90722009-01-16 Joel Brobecker <brobecker@adacore.com>
9073
9074 * NEWS: Document x86_64/MinGW as a new native configuration.
9075
2dde91e9
JB
90762009-01-16 Joel Brobecker <brobecker@adacore.com>
9077
9078 * NEWS: Move the documentation of "info os processes" to
9079 the appropriate section (documenting the new commands).
9080
54363045
DE
90812009-01-15 Doug Evans <dje@google.com>
9082
9083 * target.h (target_signal_to_string): Make return type const char *.
9084 (target_signal_to_name): Ditto.
9085 (target_signal_from_name): Make arg const char *.
54363045 9086 * infrun.c (sig_print_info): Update.
54363045
DE
9087 * signals/signals.c (signals): Make array and struct members const.
9088 (target_signal_to_string): Make return type const char *.
9089 (target_signal_to_name): Ditto.
9090 (target_signal_from_name): Make arg const char *.
9091
572d275c
UW
90922009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
9093 Tristan Gingold <gingold@adacore.com>
9094
9095 * solist.h (struct target_so_ops): New member bfd_open.
9096 (solib_find): Add prototype.
9097 (solib_bfd_fopen): Add prototype.
9098 * solib.c (solib_find, solib_bfd_fopen): New functions, extracted
9099 from solib_bfd_open.
9100 (solib_bfd_open): Use ops->bfd_open override if present. Call
9101 solib_find and solib_bfd_open otherwise.
9102
9103 * objfiles.h (OBJF_KEEPBFD): New define.
9104 * objfiles.c (free_objfile): Do not close BFD if OBJF_KEEPBFD
9105 objfile flag is set.
9106 * solib.c (symbol_add_stub): Do not allocate second BFD for
9107 shared library; use OBJF_KEEPBFD flag on solib objfile.
9108
0701b271
UW
91092009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
9110
9111 * frame.c (get_frame_arch): Abort if called with NULL this_frame.
9112
61212c0f
UW
91132009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
9114
9115 * value.h (address_of_variable): Add prototype.
9116 (locate_var_value): Remove prototype.
9117
9118 * findvar.c (read_var_value): Do not attempt to default frame
9119 to selected frame.
9120 (locate_var_value): Remove function.
9121 * valops.c (value_of_variable): Retrieve selected frame for
9122 symbols that require a frame when called with NULL block.
9123 * valops.c (address_of_variable): New function.
9124
9125 * eval.c (evaluate_subexp_for_address): Call address_of_variable
9126 instead of calling locate_var_value.
9127 (evaluate_subexp_with_coercion): Likewise.
9128
adb483fe
DJ
91292009-01-14 Daniel Jacobowitz <dan@codesourcery.com>
9130
9131 * NEWS: Document "define" for prefixed commands.
9132 * cli/cli-cmds.c (show_user): Update calls to show_user_1. Call
9133 show_user_1 for prefix commands.
9134 * cli/cli-decode.c (help_cmd_list): Recurse for "help user-defined".
9135 * cli/cli-script.c (validate_comname): Rewrite to handle prefix
9136 commands. Return the containing command list.
9137 (define_command, document_command): Update to handle prefix commands.
9138 (show_user_1): Add prefix and name arguments. Handle prefix
9139 commands.
9140 * cli/cli-script.h (show_user_1): Update prototype.
9141
a32d7317
KT
91422009-01-14 Kai Tietz <kai.tietz@onevision.com>
9143
92a610f3 9144 * ser-mingw.c (console_select_thread): Add return to make
a32d7317
KT
9145 compiler happy.
9146 (pipe_select_thread): Likewise.
9147 (file_select_thread): Likewise.
9148
041d0fd7
PA
91492009-01-14 Pedro Alves <pedro@codesourcery.com>
9150
9151 * mi/mi-main.c (mi_cmd_execute): Clean up parenthesis mess from
9152 previous change.
9153
dc1981d7
PA
91542009-01-14 Pedro Alves <pedro@codesourcery.com>
9155
9156 * remote.c (extended_remote_mourn_1): Invalidate our notion of
9157 current general thread.
9158
244bf9ae
PA
91592009-01-14 Pedro Alves <pedro@codesourcery.com>
9160
9161 * mi/mi-main.c (mi_cmd_execute): Also allow -list-thread-groups
9162 without a live selected thread.
9163
e4d013fc
JB
91642009-01-14 Joel Brobecker <brobecker@adacore.com>
9165
9166 Update the copyright notice of some of the files I missed
9167 in the previous copyright update.
9168
a588db63
JB
91692009-01-14 Joel Brobecker <brobecker@adacore.com>
9170
9171 * windows-nat.c (handle_unload_dll): Use %p to print the DLL
9172 base address instead of casting it to DWORD.
9173
77a732d9
UW
91742009-01-13 Ulrich Weigand <uweigand@de.ibm.com>
9175
9176 * dwarf2loc.c (dwarf2_evaluate_loc_desc): Do not call get_frame_arch
9177 for NULL frame pointers.
9178
773698b5
JB
91792009-01-13 Mark Kettenis <kettenis@gnu.org>
9180
9181 * utils.c (host_address_to_string): Reimplement in a way that
9182 avoids the cast of the address to long.
9183
9918cab9
JB
91842009-01-13 Joel Brobecker <brobecker@adacore.com>
9185
9186 * mdebugread.c (parse_symbol): Save the symbol private data
9187 using SYMBOL_VALUE_BYTES instead of SYMBOL_VALUE.
9188 (psymtab_to_symtab_1): Likewise.
9189 (parse_procedure): Declare variable "e" only in the scope
9190 where it is used. Extract the symbol private data using
9191 SYMBOL_VALUE_BYTES.
9192
74bcbdf3
PA
91932009-01-13 Jim Blandy <jimb@codesourcery.com>
9194
9195 Abstract out common code for copying value locations.
9196
9197 * value.h (set_value_component_location): New declaration.
9198 * value.c (set_value_component_location): New function.
9199 (value_primitive_field): Use it.
9200 * valarith.c (value_subscript, value_subscripted_rvalue): Same.
9201 * valops.c (search_struct_field, value_slice): Same.
9202 * ada-lang.c (coerce_unspec_val_to_type)
9203 (ada_value_primitive_packed_val): Same.
9204
d7dc3873
JB
92052009-01-13 Joel Brobecker <brobecker@adacore.com>
9206
9207 * MAINTAINERS (GLOBAL MAINTAINERS): Add Tom Tromey.
9208
dc05df57
CF
92092009-01-12 Christopher Faylor <me+cygwin@cgf.cx>
9210
9211 * amd64-windows-nat.c Rename gdb-specific win32_* to windows_*
9212 throughout.
9213 * i386-cygwin-tdep.c: Ditto.
9214 * i386-windows-nat.c: Ditto.
9215 * windows-nat.h: Ditto.
9216 * windows-tdep.c: Ditto.
9217 * windows-tdep.h: Ditto.
9218 * windows-nat.c: Ditto.
9219 (cygwin_load_start): Redefine as CORE_ADDR.
9220 (cygwin_load_end): Ditto.
b8511eeb 9221 (windows_make_so): Coerce result of address arithmetic to uintptr_t
dc05df57
CF
9222 before coercing to CORE_ADDR to avoid a compiler warning.
9223 (handle_exception): Define addr as CORE_ADDR and coerce
9224 ExceptionAddress to uintptr_t before assigining to avoid a compiler
9225 warning.
9226 * config/djgpp/fnchange.lst: Add mappings for recently renamed windows
9227 files.
9228
31b060a2
CF
92292009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
9230
9231 Fix linking with --enable-targets=all:
9232 * Makefile.in (ALL_TARGET_OBS): Add windows-tdep.o.
9233 (HFILES_NO_SRCDIR): Add windows-tdep.h.
9234 (ALLDEPFILES): Add windows-tdep.c.
9235
f3b6bd60 92362009-01-11 Chris Faylor <me.gdb@cgf.cx>
31b060a2
CF
9237
9238 * win32-nat.h: Delete.
9239 * windows-nat.h: Rename from win32-nat.h.
9240 * win32-nat.c: Delete.
9241 * windows-nat.c: Rename from win32-nat.c.
9242 * win32-termcap.c: Delete.
9243 * windows-termcap.c: Rename from win32-termcap.c.
9244 * amd64-windows-nat.c: Handle rename from win32-nat.h -> windows-nat.h.
9245 * configure.ac: Handle rename from win32-termcap.c ->
9246 windows-termcap.c.
9247 * configure: Regenerate.
9248 * gdb_curses.h: Change comment to reflect rename from win32-termcap.c
9249 -> windows-termcap.c.
9250 * i386-cygwin-tdep.c: Handle rename from win32-tdep.h ->
9251 windows-tdep.h.
9252 * i386-windows-nat.c: Refect rename from win32-nat.h -> windows-nat.h.
9253 * windows-nat.c: Ditto. Also reflect rename from from win32-tdep.h ->
9254 windows-tdep.h.
9255 (win32_make_so): Handle cygwin compiler warning due to change of
9256 load_addr from DWORD to LPVOID.
9257 (handle_load_dll): Use %p in format string to properly print address
9258 and avoid a compiler warning.
9259 (DEBUG_EXCEPTION_SIMPLE): Ditto.
9260 (handle_exception): Ditto.
9261 * windows-tdep.c: Handle rename from win32-tdep.h -> windows-tdep.h.
9262 * config/i386/cygwin.mh: Handle rename from win32-nat.o ->
9263 windows-nat.o.
9264 * config/i386/mingw.mh: Ditto.
9265 * config/i386/mingw64.mh: Ditto.
9266
0311118f
JK
92672009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
9268
9269 * f-typeprint.c (f_type_print_varspec_suffix): Convert the autovariable
9270 arrayprint_recurse_level to a parameter. Update all the callers. New
9271 comment at autovariables.
9272
5f61c20e
JK
92732009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
9274
9275 * gdbtypes.c (make_qualified_type, replace_type): Reformat to the GNU
9276 coding style.
9277
92782009-01-11 Joel Brobecker <brobecker@adacore.com>
53b71562
JB
9279
9280 * target.c (target_xfer_partial): Use host_address_to_string to
9281 print the address of readbuf and writebuf. Cast the address of
9282 elements inside the myaddr buffer into intptr_t.
9283 (deprecated_debug_xfer_memory): Use paddress to print memaddr.
9284 Cast the address of elements inside the myaddr buffer into
9285 intptr_t.
9286
5f61c20e 92872009-01-11 Joel Brobecker <brobecker@adacore.com>
d0761299
JB
9288
9289 * amd64-windows-nat.c, amd64-windows-tdep.c: New files.
9290 * config/i386/mingw64.mh, config/i386/nm-cygwin64.h: New files.
9291 * configure.host, configure.tgt: Add handling for x86_64/windows.
9292 * config/djgpp/fnchange.lst: Add entries for amd64-windows-nat.c
9293 and amd64-windows-tdep.c.
9294
5f61c20e 92952009-01-11 Joel Brobecker <brobecker@adacore.com>
bfb87e33
JB
9296
9297 * win32-tdep.h, win32-tdep.c: New files.
9298 * i386-cygwin-tdep.h: Delete.
9299 * i386-cygwin-tdep.c: Include win32-tdep.h instead of
9300 i386-cygwin-tdep.h.
9301 (win32_xfer_shared_library): Delete. Moved to win32-tdep.c.
9302 * win32-nat.c: Likewise.
9303 * configure.tgt: Add win32-tdep.o to the list of target object
9304 files for i386-cygwin and i386-mingw targets.
9305
5f61c20e 93062009-01-11 Joel Brobecker <brobecker@adacore.com>
7e63b4e4
JB
9307
9308 * win32-nat.h: New file.
9309 * win32-nat.c (mappings): Initialize to NULL.
9310 (win32_set_context_register_offsets): New function.
9311 * i386-windows-nat.c: New file.
9312 (mappings): Moved here from win32-nat.c.
9313 (_initialize_i386_windows_nat): New function.
9314 * config/i386/mingw.mh (NATDEPFILES): Add i386-windows-nat.o.
9315 * config/i386/cygwin.mh (NATDEPFILES): Likewise.
9316
25fc6591
AS
93172009-01-09 Andreas Schwab <schwab@suse.de>
9318
9319 * Makefile.in (init.c): Set LANG/LC_ALL to C, not c.
9320
87f70781
PA
93212009-01-09 Daniel Jacobowitz <dan@codesourcery.com>
9322
9323 * gdbtypes.c (append_composite_type_field): Correct the location of
9324 appended fields.
9325
58d4abe1
PA
93262009-01-09 Pedro Alves <pedro@codesourcery.com>
9327
9328 * defs.h (deprecated_error_hook): Delete declaration.
9329 * interps.c (clear_interpreter_hooks): Adjust.
9330 * remote-sim.c (gdb_os_error): Don't try to call
9331 deprecated_error_hook. No need to call exit anymore.
9332 * top.c (deprecated_error_hook): Delete.
9333
e3cb3832
JB
93342009-01-09 Joel Brobecker <brobecker@adacore.com>
9335
9336 * arch-utils.c (gdbarch_update_p): Use host_address_to_string
9337 to print the address of the gdbarch pointer.
9338
30737ed9
JB
93392009-01-09 Joel Brobecker <brobecker@adacore.com>
9340
9341 * gdbarch.sh: Fix all the compilation errors on amd64-windows
9342 due to casting a pointer to a long when printing a function
9343 address. Instead, use host_address_to_string to convert our
9344 address to a string.
9345 * gdbarch.c: Regenerate.
9346
ec4dfccf
JB
93472009-01-09 Joel Brobecker <brobecker@adacore.com>
9348
9349 * event-top.c (async_disconnect, async_stop_sig): use "raise"
9350 instead of "kill" to raise a signal.
9351
d3653bf6
JB
93522009-01-09 Joel Brobecker <brobecker@adacore.com>
9353
9354 * win32-nat.c (get_module_name): Change the type of parameter
9355 "base_address" to LPVOID. Remove unnecessary cast.
9356 (struct lm_info): Change type of load_addr to LPVOID.
9357 (win32_make_so): Change the type of parameter "load_addr"
9358 to LPVOID. Remove some unnecessary casts.
9359 (handle_unload_dll): Change the type of "lpBaseOfDll" to LPVOID.
9360 (win32_xfer_shared_libraries): Add missing cast.
9361
308a8808
JB
93622009-01-09 Joel Brobecker <brobecker@adacore.com>
9363
9364 * win32-nat.c (has_detach_ability, set_process_privilege):
9365 Cast the result of GetProcAddress to (void *) to avoid
9366 a compilation warning.
9367
5851ab76
JB
93682009-01-09 Joel Brobecker <brobecker@adacore.com>
9369
9370 * win32-nat.c (CONTEXT_EXTENDED_REGISTERS): Define to 0 if not
9371 already defined.
9372
5732a500
JB
93732009-01-09 Joel Brobecker <brobecker@adacore.com>
9374
9375 * win32-nat.c (get_image_name, win32_xfer_memory): Fix type
9376 definition of local variable "done".
9377 (info_w32_command, handle_exception): Remove unnecessary cast.
9378
def4de3a
JB
93792009-01-09 Joel Brobecker <brobecker@adacore.com>
9380
9381 * win32-nat.c (kernel32_DebugSetProcessKillOnExit): Renames
9382 DebugSetProcessKillOnExit. Update all uses in this file.
9383 (kernel32_DebugActiveProcessStop): Renames DebugActiveProcessStop.
9384 Update all uses in this file.
9385
93862009-01-09 Joel Brobecker <brobecker@adacore.com>
0795be10
JB
9387
9388 * win32-nat.c (do_initial_win32_stuff): Add new ops parameter,
9389 and use it when pushing the target.
9390 (win32_attach, win32_create_inferior): Update call to
9391 do_initial_win32_stuff.
9392 (win32_detach, win32_mourn_inferior): Use our ops parameter
9393 instead of the global win32_ops to unpush the target.
9394
1be7fe8d
JB
93952009-01-09 Joel Brobecker <brobecker@adacore.com>
9396
9397 * ser-mingw.c (ser_windows_open): Use proper type when casting
9398 in call to _open_osfhandle.
9399
1dac1b47
KT
94002009-01-09 Kai Tietz <kai.tietz@onevision.com>
9401
9402 * coff-pe-read.c (read_pe_exported_syms): Fix typo.
9403
ecf180db
JB
94042009-01-09 Joel Brobecker <brobecker@adacore.com>
9405
9406 * CONTRIBUTE: Minor reformatting.
9407
8234eceb
KT
94082009-01-08 Kai Tietz <kai.tietz@onevision.com>
9409
9410 * MAINTAINERS: Add myself to Write After Approval.
a68ddad5
KT
9411 * coff-pe-read.c (read_pe_exported_syms): Enable read of PE+
9412 export directory.
8234eceb 9413
72ee8797
NF
94142009-01-08 Nathan Froyd <froydnj@codesourcery.com>
9415
9416 * remote-sim.c (gdb_os_error): Mark as a noreturn function.
9417 Call exit to make it obvious to GCC.
9418
f7545552
TT
94192009-01-08 Tom Tromey <tromey@redhat.com>
9420
9421 PR breakpoints/9350:
9422 * varobj.c (varobj_invalidate): Unconditionally free
9423 all_rootvarobj.
9424 * symfile.c (syms_from_objfile): Free local_addr when returning
9425 normally.
9426 * exec.c (exec_file_attach): Do cleanups before returning.
9427 (exec_file_command): Likewise.
9428 * corefile.c (reopen_exec_file): Do cleanups before returning.
9429 * breakpoint.c (insert_breakpoint_locations): Do cleanups before
a2f63f5e 9430 returning.
f7545552
TT
9431 (do_vec_free): New function.
9432 (update_global_location_list): Make a cleanup for old_locations.
9433 Do cleanups before returning. Remove unused variable 'e'.
9434 (find_condition_and_thread): Free result of parsing the
9435 expression.
9436 (print_it_typical): Do cleanups before returning.
9437 (breakpoint_re_set_one): Always free sals.sals.
9438
dde02812
ES
94392009-01-08 Joel Brobecker <brobecker@adacore.com>
9440 Emi Suzuki <emi-suzuki@tjsys.co.jp>
a2f63f5e 9441
dde02812
ES
9442 * breakpoint.c (do_enable_breakpoint): Use update_watchpoint for
9443 watchpoints.
9444
69bcc6bc
DE
94452009-01-07 Doug Evans <dje@google.com>
9446
9447 * top.c (gdb_prompt_string): Delete, unused.
9448
fa3a767f
PA
94492009-01-07 Pedro Alves <pedro@codesourcery.com>
9450
9451 Delete ONE_PROCESS_WRITETEXT leftovers.
9452
9453 * breakpoint.c (insert_bp_location): Delete process_warning
9454 argument. Adjust.
9455 (insert_breakpoint_locations): Adjust.
9456 (reattach_breakpoints): Adjust.
9457 * infrun.c (normal_stop): Drop "It might be running in another
9458 process" notice.
9459
7b93f36d
SS
94602009-01-07 Stan Shebs <stan@codesourcery.com>
9461
9462 * config/pa/linux.mh (XDEPFILES): Remove.
9463
0380c18b
DE
94642009-01-07 Doug Evans <dje@google.com>
9465
9466 * cli/cli-cmds.c (set_debug): Fix cut-n-paste error.
9467
60023297
JK
94682009-01-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9469
9470 * f-typeprint.c (f_type_print_base <TYPE_CODE_STRUCT>): Fix output
9471 spacing, a regression from 2008-04-22.
9472
ea8992ce
JB
94732009-01-07 Joel Brobecker <brobecker@adacore.com>
9474
9475 * utils.c (gdb_print_host_address): Adjust implementation to
9476 reuse host_address_to_string. Move comment explaining the conversion
9477 from host address to string from here...
9478 (host_address_to_string): ... to there.
9479
301d2c47
ES
94802009-01-07 Emi Suzuki <emi-suzuki@tjsys.co.jp>
9481
9482 * MAINTAINERS: Add myself for write after approval privileges.
9483
170ce852
TT
94842009-01-06 Tom Tromey <tromey@redhat.com>
9485
9486 * value.c (set_internalvar): Use value_free, not xfree.
9487
fdb7262a
JB
94882009-01-06 Jim Blandy <jimb@red-bean.com>
9489
bf1d7d9c
JB
9490 Check return values of functions declared with warn_unused_result
9491 attribute in GLIBC 2.8.
9492 * cli/cli-cmds.c (pwd_command): Check return value from getcwd.
9493 * inflow.c (check_syscall): New function.
9494 (new_tty): Use check_syscall to check return values from open and dup.
9495 * linux-nat.c (linux_nat_info_proc_cmd): Check return value from fgets.
9496 * main.c (captured_main): Call cwd after setting up gdb_stderr;
9497 check for errors from getcwd.
9498 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Check return value from getcwd.
9499 * ui-file.c (stdio_file_write): Ignore return value from fwrite.
9500 (stdio_file_fputs): Same.
9501 * utils.c (internal_vproblem): abort if last-ditch error message
9502 write fails.
9503
fdb7262a
JB
9504 * top.c (gdb_init): Don't set the current directory here; that's
9505 already been done in captured_main.
9506
84603566
SL
95072009-01-06 Sandra Loosemore <sandra@codesourcery.com>
9508
9509 * ser-tcp.c: Adjust includes.
9510 (tcp_set_cmdlist, tcp_show_cmdlist): Declare.
9511 (tcp_auto_retry, tcp_retry_limit): Declare.
9512 (TIMEOUT): Remove, in favor of tcp_retry_limit.
9513 (POLL_INTERVAL): Increase to 5, in favor of backoff logic.
9514 (wait_for_connect): New function.
9515 (net_open): Use it. Add auto-retry logic.
9516 (set_tcp_cmd, show_tcp_cmd): New functions.
9517 (_initialize_ser_tcp): Initialize new "set/show tcp auto-retry"
9518 and "set/show tcp connect-timeout" commands.
9519 * NEWS: Document new commands.
9520
5171e6b3
TT
95212009-01-05 Tom Tromey <tromey@redhat.com>
9522
9523 * python/python-internal.h (Py_ssize_t): Define as int.
9524
a367a1f2
JB
95252009-01-05 Jim Blandy <jimb@red-bean.com>
9526
9527 * MAINTAINERS: Fix my e-mail address as steering committee member.
9528
0fb0cc75
JB
95292009-01-03 Joel Brobecker <brobecker@adacore.com>
9530
9531 Updated copyright notices for most files.
9532
c9fc347d
JB
95332009-01-03 Joel Brobecker <brobecker@adacore.com>
9534
9535 * top.c (print_gdb_version): Update copyright year.
9536
a85d99b4
JB
95372009-01-03 Joel Brobecker <brobecker@adacore.com>
9538
9539 * config/djgpp/fnchange.lst: Add entry for ChangeLog-2008.
9540
4d78a120
JB
95412009-01-01 Pedro Alves <pedro@codesourcery.com>
9542
9543 PR breakpoints/9681:
9544 * exceptions.h (enum errors): New error type, MEMORY_ERROR.
9545 * corefile.c (memory_error): Rewrite to throw a MEMORY_ERROR.
9546 * breakpoint.c (fetch_watchpoint_value): Ignore MEMORY_ERRORs, but
9547 retrow all other exceptions.
9548
67de2a4c 9549For older changes see ChangeLog-2008.
c906108c
SS
9550\f
9551Local Variables:
9552mode: change-log
9553left-margin: 8
9554fill-column: 74
9555version-control: never
57da7796 9556coding: utf-8
c906108c 9557End: