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