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