1 2009-06-19 Tristan Gingold <gingold@adacore.com>
3 * darwin-nat.c (_initialize_darwin_inferior): Remove commented-out
6 2009-06-19 Tristan Gingold <gingold@adacore.com>
7 * machoread.c (macho_symtab_read): Adjust for bfd changes.
8 * darwin-nat.h (struct darwin_exception_msg): New type to describe
10 (struct private_thread_info): New type to describe the state of the
12 (DEF_VEC_I thread_t): Removed, replaced by ...
13 (DEF_VEC_O darwin_thread_t): ... this new type.
14 (struct darwin_inferior): Renamed to ...
15 (struct private_inferior): ... this type. Fields added.
16 (darwin_not_port): Moved into the private inferior structure.
17 * darwin-nat.c: Add includes, improve comments.
18 Rewrite to handle multiple threads and processes.
19 (darwin_resume_to): New function and protype.
20 (darwin_resume, darwin_wait_to, darwin_wait): Ditto.
21 (darwin_kill_inferior): Add ops argument.
22 (darwin_pid_to_str): New function.
23 (darwin_thread_alive): Ditto.
24 (darwin_inf, darwin_not_port): Removed.
25 (darwin_inf_fake_stop): New variable.
26 (msgin, msgout, msg_state, exc_msg): Removed.
27 (mach_check_error): Use warning instead of error.
28 (darwin_ptrace): Adjust debug level.
29 (cmp_thread_t): Fix names (typo).
30 (darwin_check_new_threads): Argument is now an inferior,
31 adjust for new structures, add no change check, ignore dead ports,
32 handle first thread case.
33 (find_inferior_task_it): New function.
34 (find_inferior_notify_it): Ditto.
35 (darwin_find_inferior_by_task): Ditto.
36 (darwin_find_inferior_by_notify): Ditto.
37 (darwin_find_thread): Ditto.
38 (darwin_suspend_inferior): Ditto.
39 (darwin_resume_inferior): Ditto.
40 (catch_exception_raise_state): Removed.
41 (catch_exception_raise_state_identity): Removed.
42 (darwin_suspend_inferior_it): New function.
43 (darwin_resume_inferior_it): Ditto.
44 (darwin_dump_message): New function, extracted from darwin_wait.
45 (darwin_decode_exception_message): New function.
46 (darwin_encode_reply): New function.
47 (catch_exception_raise): Removed.
48 (darwin_send_reply): New function, extracted from darwin_resume.
49 (darwin_resume_thread): New function, extracted from darwin_resume.
50 (struct resume_inferior_threads_param): New type.
51 (darwin_resume_inferior_threads_it): New function.
52 (darwin_resume_inferior_threads): New function.
53 (darwin_suspend_inferior_threads): New function.
54 (darwin_resume): Mostly rewritten to handle multiple threads and
56 (darwin_decode_message): New function extracted from darwin_wait.
57 (cancel_breakpoint): New function.
58 (darwin_wait): Mostly rewritten. Handle multiple threads.
59 (darwin_mourn_inferior): Adjust for per process structures.
60 (darwin_reply_to_all_pending_messages): New function.
61 (darwin_stop_inferior): Adjust for per inferior structures.
62 (darwin_attach_pid): Ditto.
63 (darwin_init_thread_list): Ditto.
64 (darwin_attach): Ditto.
65 (darwin_detach): Ditto.
66 (darwin_files_info): Now empty.
67 (darwin_pid_to_str): Adjust returns string to match one expected by
69 (darwin_read_write_inferior): Rename err variable to match other uses.
70 Adjust debug message. Handle submaps.
71 (darwin_xfer_memory): Adjust for per inferior structures.
72 (set_enable_mach_exceptions): Ditto.
73 (darwin_pid_to_exec_file): New function.
74 (darwin_get_ada_task_ptid): Ditto.
75 (darwin_supports_multi_process): Ditto.
76 (_initialize_darwin_inferior): Remove useless assertion, adjust for
77 per inferior structures. Add new target operations.
79 2009-06-18 Hui Zhu <teawater@gmail.com>
80 Michael Snyder <msnyder@vmware.com>
82 * infrun.c (handle_inferior_event): Improve reverse stepping
83 through function epilogue.
85 * infrun.c (handle_inferior_event): Reverse-next through
88 2009-06-18 Paul Pluzhnikov <ppluzhnikov@google.com>
90 * dwarf2-frame.c (struct comp_unit): Use bfd_size_type for
93 2009-06-17 Tom Tromey <tromey@redhat.com>
95 * dwarf2read.c (zlib_decompress_section): Use a cleanup.
97 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
99 * gdbarch.sh (pointer_to_address): Change to type 'm'.
100 (address_to_pointer): Likewise.
101 * gdbarch.c, gdbarch.h: Regenerate.
103 * inferior.h (unsigned_pointer_to_address): Add GDBARCH argument.
104 (signed_pointer_to_address): Likewise.
105 (unsigned_address_to_pointer, address_to_signed_pointer): Likewise.
106 * findvar.c (unsigned_pointer_to_address): Likewise.
107 (signed_pointer_to_address): Likewise.
108 (unsigned_address_to_pointer, address_to_signed_pointer): Likewise.
110 * avr-tdep.c (avr_address_to_pointer): Likewise.
111 (avr_pointer_to_address): Likewise.
112 * iq2000-tdep.c (iq2000_pointer_to_address): Likewise.
113 (iq2000_address_to_pointer): Likewise.
114 * m32c-tdep.c (m32c_m16c_address_to_pointer): Likewise.
115 (m32c_m16c_pointer_to_address): Likewise.
116 * spu-tdep.c (spu_pointer_to_address): Likewise.
117 * xstormy16-tdep.c (xstormy16_pointer_to_address): Likewise.
118 (xstormy16_address_to_pointer): Likewise.
120 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
122 * printcmd.c (print_scalar_formatted): Always truncate
125 * cli-dump.c (struct callback_data): Change type of load_offset
127 (restore_binary_file): Update type casts.
128 (restore_command): Parse load_offset as address, not long.
130 * utils.c (string_to_core_addr): Do not sign-extend value.
131 * varobj.c (find_frame_addr_in_frame_chain): Truncate frame_base
132 before comparing against requested frame address.
134 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
136 * gdbarch.sh (gcore_bfd_target): New gdbarch callback.
137 * gdbarch.h, gdbarch.c: Regenerate.
139 * gcore.c (default_gcore_target): Make return value const.
140 Call gdbarch_gcore_bfd_target if present.
141 (default_gcore_arch, default_gcore_mach): Use target_gdbarch.
143 * corelow.c (core_read_description): Call gdbarch_core_read_description
144 on core_gdbarch instead of current_gdbarch.
146 * ppc-linux-tdep.c (ppc_linux_init_abi): Install gcore_bfd_target.
148 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
150 * gdbtypes.c (create_string_type): Receive character type as argument.
151 * gdbtypes.h (create_string_type): Add character type argument.
152 * dwarf2read.c (read_tag_string_type): Pass character type to
155 * value.h (value_string): Add character type argument.
156 * valops.c (value_string): Add character type argument. Pass it to
157 create_string_type. Do not allocate space in inferior.
158 * valarith.c (value_concat): Pass character type to value_string.
160 * value.h (value_typed_string): Rename to ...
161 (value_cstring): ... this.
162 * valops.c (value_typed_string): Rename to ...
163 (value_cstring): ... this.
164 * c-lang.c (evaluate_subexp_c): Update.
166 * python/python-value.c (builtin_type_pychar): New define.
167 (convert_value_from_python): Call value_cstring instead
168 of value_from_string.
169 * value.c (value_from_string): Remove.
170 * value.h (value_from_string): Remove.
172 * eval.c (evaluate_subexp_standard): Pass character type to
173 value_string. Pass expression architecture to value_nsstring
174 and lookup_child_selector.
175 * objc-lang.h (lookup_objc_class): Add GDBARCH parameter.
176 (lookup_child_selector): Likewise.
177 (value_nsstring): Likewise.
178 * objc-lang.c (lookup_objc_class): Add GDBARCH parameter.
179 Pass character type to value_string..
180 (lookup_child_selector): Likewise.
181 (value_nsstring): Add GDBARCH parameter, use it instead of
182 objfile architecture. Pass architecture to lookup_objc_class
183 and lookup_child_selector. Pass character type to value_string.
184 (end_msglist): Pass architecture to lookup_objc_class.
185 * objc-exp.y: Pass architecture to lookup_objc_class.
187 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
189 * gdbtypes.h (struct language_defn): Add forward declaration.
190 (lookup_typename): Add LANGUAGE and GDBARCH parameters.
191 (lookup_unsigned_typename): Likewise.
192 (lookup_signed_typename): Likewise.
193 * gdbtypes.c (lookup_typename): Add LANGUAGE and GDBARCH parameters.
194 Use them instead of current_language and current_gdbarch.
195 (lookup_unsigned_typename): Add LANGUAGE and GDBARCH parameters.
196 Pass them to lookup_typename.
197 (lookup_signed_typename): Likewise.
199 * c-exp.y: Pass parse_language and parse_gdbarch to
200 lookup_unsigned_typename and lookup_signed_typename.
201 * objc-exp.y: Likewise.
202 * m2-exp.y: Pass parse_language and parse_gdbarch to lookup_typename.
204 * c-lang.c (evaluate_subexp_c): Pass expression language and
205 gdbarch to lookup_typename.
206 * printcmd.c (printf_command): Pass current language and
207 gdbarch to lookup_typename.
208 * python/python-type.c (typy_lookup_typename): Likewise.
209 Include "language.h".
211 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
213 * sparc64-nat.c (sparc64_gregset_supplies_p): Add GDBARCH parameter.
214 Use it instead of current_gdbarch. Pass architecture to
215 sparc32_gregset_supplies_p.
216 (sparc64_fpregset_supplies_p): Add GDBARCH parameter. Use it instead
217 of current_gdbarch. Pass architecture to sparc32_fpregset_supplies_p.
218 * sparc64nbsd-nat.c (sparc64nbsd_gregset_supplies_p,
219 sparc64nbsd_fpregset_supplies_p): Likewise.
220 * sparc-nat.c (sparc_gregset_supplies_p, sparc_fpregset_supplies_p):
221 Add GDBARCH parameter.
222 (sparc32_gregset_supplies_p, sparc32_fpregset_supplies_p): Likewise.
223 (sparc_fetch_inferior_registers): Pass regcache architecture to
224 sparc_gregset_supplies_p and sparc_fpregset_supplies_p.
225 (sparc_store_inferior_registers): Likewise.
226 * sparc-nat.h (sparc_gregset_supplies_p, sparc_fpregset_supplies_p:
227 Add GDBARCH parameter.
228 (sparc32_gregset_supplies_p, sparc32_fpregset_supplies_p): Likewise.
230 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
232 * ada-tasks.c (read_known_tasks_array): Use target_gdbarch instead
234 * aix-thread.c (pd_enable): Likewise.
235 * amd64-linux-nat.c (ps_get_thread_area): Likewise.
236 * bsd-uthread.c (bsd_uthread_activate): Likewise.
237 * linux-nat.c (linux_nat_info_proc_cmd): Likewise.
238 * linux-thread-db.c (enable_thread_event): Likewise.
239 * monitor.c (monitor_write_memory, monitor_read_memory): Likewise.
240 * nto-procfs.c (procfs_open): Likewise.
241 * procfs.c (invalidate_cache, procfs_insert_watchpoint,
242 info_proc_mappings, info_mappings_callback): Likewise.
243 * record.c (record_open): Likewise.
244 * rs6000-nat.c (ARCH64): Likewise.
245 * solib-darwin.c (darwin_solib_create_inferior_hook): Likewise.
246 (darwin_bfd_open): Likewise.
247 * memattr.c (mem_info_command): Likewise.
249 * windows-nat.c (win32_resume): Use current regcache architecture
250 instead of current_gdbarch.
252 * dbug-rom.c (dbug_regname): Remove check against number of
253 registers in current_gdbarch.
254 * solib-pa64.c (read_dynamic_info): Remove unused variable.
256 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
258 * dummy-frame.c (deprecated_pc_in_call_dummy): Add GDBARCH parameter,
259 use it instead of current_gdbarch.
260 * frame.h (deprecated_pc_in_call_dummy): Add GDBARCH parameter.
261 * arm-tdep.c (arm_skip_prologue): Pass architecture to
262 deprecated_pc_in_call_dummy.
264 * symtab.c (skip_prologue_using_sal): Add GDBARCH parameter.
265 Use it instead of current_gdbarch.
266 * symtab.h (skip_prologue_using_sal): Add GDBARCH parameter.
267 * breakpoint.c (expand_line_sal_maybe): Pass architecture to
268 skip_prologue_using_sal.
269 * arm-tdep.c (skip_prologue_using_sal): Likewise.
270 * lm32-tdep.c (lm32_skip_prologue): Likewise.
271 * m32-tdep.c (m32c_skip_prologue): Likewise.
272 * mips-tdep.c (mips_skip_prologue): Likewise.
273 * moxie-tdep.c (moxie_skip_prologue): Likewise.
274 * mt-tdep.c (mt_frame_unwind_cache): Likewise.
275 * rs6000-tdep.c (rs6000_skip_prologue): Likewise.
276 * frv-tdep.c (frv_analyze_prologue): Add GDBARCH parameter, pass
277 it to skip_prologue_using_sal. Update call sites ...
278 (frv_skip_prologue, frv_frame_unwind_cache): ... here.
280 * mn10300-tdep.c (struct mn10300_prologue): Add GDBARCH member.
281 (check_for_saved): Use it instead of current_gdbarch.
282 (mn10300_analyze_prologue): Set it.
284 * value.c (using_struct_return): Add GDBARCH parameter. Use it
285 instead of current_gdbarch.
286 * value.h (using_struct_return): Add GDBARCH parameter.
287 * eval.c (evaluate_subexp_standard): Pass architecture to
289 * infcall.c (call_function_by_hand): Likewise.
290 * stack.c (return_command): Likewise.
291 * sparc-tdep.c (sparc32_push_dummy_code): Likewise.
293 * symtab.c (in_prologue): Add GDBARCH parameter. Use it instead of
295 * symtab.h (in_prologue): Add GDBARCH parameter.
296 * infrun.c (handle_inferior_event): Pass architecture to in_prologue.
298 * eval.c (evaluate_subexp_standard): Use expression architecture
299 instead of current_gdbarch.
301 * c-lang.c (evaluate_subexp_c): Use expression architecture and
302 language instead of current_gdbarch and current_language.
304 * printcmd.c (do_one_display): Use expression architecture instead
307 * infcmd.c (print_return_value): Use architecture of stop_regcache
308 instead of current_gdbarch.
309 (print_vector_info, print_float_info): Remove GDBARCH argument,
310 use frame architecture instead.
311 (vector_info, float_info): Update calls.
313 * objc-lang.c (objc_skip_trampoline): Use frame architecture
314 instead of current_gdbarch.
316 * parse.c (write_dollar_variable): Use parse architecture instead
319 * source.c (line_info): Use objfile architecture instead of
322 * symtab.c (find_function_start_sal): Use gdbarch instead of
324 (print_msymbol_info): Use objfile architecture instead of
327 * valops.c (value_assign): Use frame architecture instead of
330 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
332 * buildsym.c (record_line): Remove call to gdbarch_addr_bits_remove.
334 * coffread.c (coff_symtab_read): Call gdbarch_addr_bits_remove before
336 (enter_linenos): Likewise.
337 * dbxread.c (process_one_symbol): Likewise.
338 * dwarf2read.c (dwarf_decode_lines): Likewise.
339 * mdebugread.c (psymtab_to_symtab_1): Likewise.
340 * xcoffread.c (enter_line_range): Likewise.
342 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
344 * ax-gdb.c (gen_bitfield_ref): Add EXP argument, use expression
345 architecture instead of current_gdbarch.
346 (gen_struct_ref): Add EXP argument, pass to get_bitfield_ref.
347 (gen_expr): Pass expression to get_struct_ref.
349 * symtab.h (struct symbol_ops): Add GDBARCH parameter to
350 tracepoint_var_ref callback.
351 * ax-gdb.c (gen_var_ref): Pass architecture to tracepoint_var_ref
352 symbol operation callback.
353 * dwarf2loc.c (dwarf2_tracepoint_var_ref): Add GDBARCH parameter.
354 Use it instead of current_gdbarch.
355 (locexpr_tracepoint_var_ref): Add GDBARCH parameter. Pass it to
356 dwarf2_tracepoint_var_ref.
357 (loclist_tracepoint_var_ref): Likewise.
359 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
361 * prologue-value.c (make_pv_area): Add ADDR_BIT argument.
362 Use it instead of address bits of current_gdbarch.
363 * prologue-value.c (make_pv_area): Add ADDR_BIT argument.
364 * arm-tdep.c (thumb_analyze_prologue): Pass address bits to
366 (arm_scan_prologue): Likewise.
367 * m32c-tdep.c (m32c_analyze_prologue): Likewise.
368 * mep-tdep.c (mep_analyze_prologue): Likewise.
369 * mn10300-tdep.c (mn10300_analyze_prologue): Likewise.
370 * s390-tdep.c (s390_analyze_prologue): Likewise.
372 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
374 * mi/mi-main.c (mi_cmd_data_list_register_names): Use selected
375 frame architecture instead of current_gdbarch.
376 (mi_cmd_data_list_changed_registers): Likewise.
377 (mi_cmd_data_list_register_values): Likewise. Pass selected
378 frame to get_register.
379 (get_register): Add FRAME argument, use it as frame to retrieve
380 registers from (instead of selected frame). Use frame architecture
381 instead of current_gdbarch.
382 (mi_cmd_data_write_register_values): Use current regcache
383 architecture instead of current_gdbarch.
385 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
387 * tui/tui-regs.c (tui_show_register_group): Remove GDBARCH parameter;
388 use frame architecture instead. Replace current_gdbarch uses.
389 (tui_show_registers): Update call.
390 (tui_get_register): Remove GDBARCH parameter; use frame architecture
392 (tui_show_register_group): Update call.
393 (tui_check_register_values): Likewise.
394 (tui_register_format): Remove GDBARCH parameter; use frame
395 architecture instead. Replace current_gdbarch uses.
396 (tui_get_register): Update call.
398 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
400 * gdbarch.sh (construct_inferior_arguments): Remove.
401 * gdbarch.c, gdbarch.h: Regenerate.
402 * infcmd.c (get_inferior_args): Call construct_inferior_arguments
403 directly instead of gdbarch_construct_inferior_arguments.
404 (construct_inferior_arguments): Remove GDBARCH argument.
405 * inferior.h (construct_inferior_arguments): Likewise.
407 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
409 * symfile.c (section_is_mapped): Use objfile architecture instead
411 (TARGET_LONG_BYTES): Remove.
412 (read_target_long_array): Add SIZE argument. Use it instead of
414 (simple_read_overlay_table): Retrieve long size from objfile
415 architecture; pass it to read_target_long_array.
416 (simple_read_overlay_region_table): Likewise.
417 (simple_overlay_update_1): Likewise.
419 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
421 * infrun.c (cleanup_displaced_step_closure): Remove.
422 (displaced_step_clear_cleanup): Move to before displaced_step_prepare.
423 (displaced_step_prepare): Use displaced_step_clear_cleanup instead
424 of cleanup_displaced_step_closure.
425 (handle_inferior_event, keep_going): Use thread architecture instead
428 2009-06-17 Ulrich Weigand <uweigand@de.ibm.com>
430 * infrun.c (handle_inferior_event): Use current frame architecture
431 or thread architecture instead of current_gdbarch. Pass to
432 handle_step_into_function and handle_step_into_function_backward.
433 (handle_step_into_function): Add GDBARCH parameter. Use it instead
435 (handle_step_into_function_backward): Likewise.
436 (insert_step_resume_breakpoint_at_frame): Use frame architecture
437 instead of current_gdbarch.
438 (insert_step_resume_breakpoint_at_caller): Likewise.
440 2009-06-17 Pierre Muller <muller@ics.u-strasbg.fr>
441 Pedro Alves <pedro@codesourcery.com>
443 * infcmd.c (post_create_inferior): Call breakpoint_re_set after target
444 is pushed for watchpoint promotion to hardware watchpoint.
446 2009-06-16 Paul Pluzhnikov <ppluzhnikov@google.com>
448 * dwarf2read.c (dwarf_info_section, dwarf_abbrev_section)
449 (dwarf_line_section, dwarf_pubnames_section, dwarf_aranges_section)
450 (dwarf_loc_section, dwarf_macinfo_section, dwarf_str_section)
451 (dwarf_ranges_section, dwarf_frame_section)
452 (dwarf_eh_frame_section): Removed.
453 (dwarf2_resize_section): Likewise.
454 (dwarf2_read_section): Now static, use bfd_mmap() if possible.
455 (dwarf2_get_section_info): New function.
456 (munmap_section_buffer): Likewise.
457 (dwarf2_per_objfile_cleanup): Likewise.
458 (section_is_p): Signature change.
459 * dwarf2-frame.c (dwarf2_build_frame_info): Use
460 dwarf2_get_section_info instead of dwarf2_read_section.
462 2009-06-16 Paul Pluzhnikov <ppluzhnikov@google.com>
464 * solib.c (symbol_add_stub): New FLAGS parameter.
465 (solib_read_symbols): FROM_TTY -> FLAGS, call symbol_add_stub
467 (solib_add): Defer breakpoint_re_set until after all solibs.
468 * bsd-uthread.c (bsd_uthread_solib_loaded): Adjust.
469 * rs6000-nat.c (objfile_symbol_add): Adjust.
470 * symfile.c (syms_from_objfile): Merge parameters into ADD_FLAGS.
471 (new_symfile_objfile): Likewise.
472 (symbol_file_add_with_addrs_or_offsets): Likewise.
473 (symbol_file_add_from_bfd): Likewise.
474 (symbol_file_add): Likewise.
475 * symfile.h (enum symfile_add_flags): New. Adjust prototypes.
476 * symfile-mem.c (symbol_file_add_from_memory): Adjust.
477 * windows-nat.c (safe_symbol_file_add_stub): Adjust.
478 * machoread.c (macho_oso_symfile, macho_symfile_read): Adjust.
480 2009-06-16 Keith Seitz <keiths@redhat.com>
482 * linespec.c (collect_methods): Delete.
483 (add_matching_methods): Reove destructor special case.
484 (find_method): Call find_methods directly instead of
486 * valops.c (value_struct_elt): Remove destructor
488 (check_field): Likewise.
489 (value_struct_elt_for_reference): Likewise.
490 (destructor_name_p): Remove misleading comment about dtors
491 being "special cases".
492 * gdbtypes.h (get_destructor_fn_field): Remove. No longer needed.
493 * gdbtypes.c (get_destructor_fn_field): Likewise.
495 2009-06-16 Pedro Alves <pedro@codesourcery.com>
497 * mi/mi-main.c (mi_cmd_data_read_memory): Dispatch
498 TARGET_OJECT_MEMORY reads to the topmost target, not to the
499 flattened current_target.
501 2009-06-16 Tristan Gingold <gingold@adacore.com>
503 * avr-tdep.c (struct gdbarch_tdep): Replace the unused field with
505 (avr_register_name): Add const to register_names.
506 (avr_scan_arg_moves): Move inside avr_scan_prologue.
507 (avr_scan_prologue): Add pc_end argument.
508 Only read prologue bytes that can be read.
509 Limit the scan to the known prologue length.
510 Makes pattern variables static and const.
512 (avr_skip_prologue): Pass func_end argument to avr_scan_prologue.
514 (avr_breakpoint_from_pc): Constify avr_break_insn.
515 (avr_extract_return_value): Fix function comment.
516 (avr_frame_unwind_cache): Fix GNU style violations.
517 Pass current_pc argument to avr_scan_prologue to stop prologue
518 analysis to the current pc. This fixes the bug with the 'next'
520 Correctly set the SP register of the previous frame (use call_length).
521 (avr_frame_prev_register): Fix indentation.
522 Correctly read PC from the stack on avr6 architectures.
523 (avr_push_dummy_call): Fix indentation.
524 (avr_gdbarch_init): Set call_length according to the architecture.
526 2009-06-15 Phil Muldoon <pmuldoon@redhat.com>
528 * infcall.c (show_unwind_on_terminating_exception_p): New
530 (call_function_by_hand): Create breakpoint and clean-up call for
531 std::terminate.breakpoint. Add unwind_on_terminating_exception_p
532 gate. Pop frame on breakpoint hit.
533 (_initialize_infcall): Add add_setshow_boolean_cmd for
534 unwind-on-terminating-exception.
536 2009-06-12 Kevin Buettner <kevinb@redhat.com>
538 * dwarf2read.c (dwarf2_psymtab_to_symtab): Propagate
539 `has_section_at_zero' flag from stripped objfile to separate,
540 debug info only, objfile.
542 2009-06-12 Pedro Alves <pedro@codesourcery.com>
544 * exec.h (section_table_xfer_memory_partial): Improve description,
545 mention SECTION_NAME.
546 * exec.c (section_table_xfer_memory_partial): Remove stale
549 2009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
551 * nto-tdep.h (nto_generic_supply_gpregset)
552 (nto_generic_supply_fpregset, nto_generic_supply_altregset): Remove.
553 * nto-tdep.c (nto_generic_supply_gpregset)
554 (nto_generic_supply_fpregset, nto_generic_supply_altregset): Remove.
556 2009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
558 * i386-nto-tdep.c (I386_NTO_SIGCONTEXT_OFFSET): Remove define.
559 (i386nto_sigcontext_addr): Change the way context address is calculated.
560 (i386nto_init_abi): Remove usage of deprecated sc_reg_offset and
561 sc_sp_offset and set sc_reg_offset and sc_num_regs.
563 2009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
565 * i386-nto-tdep.c (i386_nto_target): Remove definition.
566 (init_i386nto_ops): Use macros to set fields to global
567 current_nto_target directly.
568 (i386nto_init_abi): Remove unused nto_set_target call.
569 * nto-tdep.h (nto_set_target): Remove unused declaration.
570 * nto-tdep.c (nto_set_target): Remove unused function.
572 2009-06-11 Pedro Alves <pedro@codesourcery.com>
574 * breakpoint.c (break_command_really): Rename local variable
575 breakpoint_chain to bkpt_chain.
577 2009-06-11 Aleksandar Ristovski <aristovski@qnx.com>
579 Add support for XMM registers.
580 * i386-nto-tdep.c (i386nto_regset_id): Add case for SSE register set.
581 (i386nto_register_area): Correctly calculate offsets and sizes for
582 all supported registers.
584 2009-06-11 Tom Tromey <tromey@redhat.com>
586 * eval.c (evaluate_subexp_standard) <OP_OBJC_MSGCALL>: Remove
587 'static' from local variable definitions.
589 2009-06-11 Pedro Alves <pedro@codesourcery.com>
591 * symtab.c (append_expanded_sal): Remove unused local variables.
593 2009-06-11 Pedro Alves <pedro@codesourcery.com>
595 * infrun.c (sched_multi): New global.
596 (resume): If sched_multi is set, resume only threads of the
598 (prepare_to_proceed): Don't switch over to wait_ptid if we're
599 resuming a different inferior, and sched_multi is off.
600 (show_schedule_multiple): New.
601 (_initialize_infrun): Register new "set schedule-multiple" command.
602 * inferior.h (sched_multi): Declare.
603 * NEWS: Mention new "schedule-multiple" setting.
605 2009-06-11 Pedro Alves <pedro@codesourcery.com>
607 * varobj.c (varobj_create): Properly restore the selected frame.
609 2009-06-05 Tom Tromey <tromey@redhat.com>
611 * inferior.c (print_inferior): Make a table, not a list. Emit
614 2009-06-10 Jonas Maebe <jonas.maebe@elis.ugent.be>
616 * darwin-nat.c (darwin_stop_inferior): Pass 0 as options to
617 darwin_wait (blocking wait).
618 (darwin_kill_inferior): Likewise.
620 2009-06-10 Pedro Alves <pedro@codesourcery.com>
622 * infrun.c (handle_inferior_event): Update comment around trying
623 to revert back to a stepping thread that has exited.
625 2009-06-10 Cary Coutant <ccoutant@google.com>
627 * dwarf2read.c (dwarf_decode_lines): Recognize and ignore
628 DW_LNE_set_discriminator.
630 2009-06-10 Pierre Muller <muller@ics.u-strasbg.fr>
632 * breakpoint.c: ARI fixes.
633 (create_overlay_event_breakpoint): Avoid assignment inside if statement.
634 (print_one_breakpoint_location): Likewise.
635 (create_longjmp_breakpoint): Likewise.
636 (tracepoint_save_command): Likewise
637 (bpstat_find_step_resume_breakpoint): No operator at end of line.
638 (bpstat_stop_status): Likewise.
639 (describe_other_breakpoints): Likewise.
640 (hw_watchpoint_used_count): Likewise.
641 (expand_line_sal_maybe): Likewise.
642 (break_command_really): Likewise.
643 (delete_command): Likewise.
644 (do_enable_breakpoint): Likewise.
645 (delete_trace_command): Likewise.
646 (catch_exception_command_1): Likewise and remove extra parentheses.
648 2009-06-08 Pierre Muller <muller@ics.u-strasbg.fr>
650 * breakpoint.c (_initialize_breakpoint): Remove "bu" command alias of
651 "ubreak" command that does not exist.
653 2009-06-08 Pierre Muller <muller@ics.u-strasbg.fr>
655 * cli/cli-decode.c (add_alias_cmd): Correct assertion.
657 2009-06-07 Pedro Alves <pedro@codesourcery.com>
659 * hppa-tdep.c (_initialize_hppa_tdep): Add declaration.
661 2009-06-07 Pedro Alves <pedro@codesourcery.com>
664 * proc-utils.h (procfs_first_available): Don't declare here.
665 * sol-thread.c: Include procfs.h instead of sys/procfs.h and
667 * procfs.c: Include procfs.h.
668 (procfs_target): Make it public. Don't register
669 procfs_can_use_hw_breakpoint here.
670 (proc_set_watchpoint): Check for PCWATCH or PIOCSWATCH being
671 defined instead of TARGET_HAS_HARDWARE_WATCHPOINTS.
672 (procfs_can_use_hw_breakpoint): Remove check of
673 TARGET_HAS_HARDWARE_WATCHPOINTS.
674 (procfs_use_watchpoints): Register procfs_can_use_hw_breakpoint
676 (_initialize_procfs): Don't add the procfs target here.
678 * i386-sol2-nat.c: Include target.h and procfs.h.
679 (_initialize_amd64_sol2_nat): Install the procfs target here,
680 customized with watchpoints support.
681 * irix5-nat.c: Include target.h.
682 (_initialize_core_irix5): Rename to ...
683 (_initialize_irix5_nat): ... this. Install the procfs target
684 here, customized with watchpoints support.
685 * alpha-nat.c: Include procfs.h.
686 (_initialize_core_alpha): Rename to...
687 (_initialize_alpha_nat): ... this. Install the procfs target
688 here, customized with watchpoints support.
689 * sparc-sol2-nat.c: Include target.h and procfs.h.
690 (_initialize_sparc_sol2_nat): New.
692 * config/i386/nm-i386sol2.h (TARGET_HAS_HARDWARE_WATCHPOINTS): Delete.
693 * config/sparc/nm-sol2.h (TARGET_HAS_HARDWARE_WATCHPOINTS): Delete.
694 * config/mips/irix5.mh (NAT_FILE): Delete.
695 * config/mips/irix6.mh (NAT_FILE): Delete.
696 * config/mips/nm-irix5.h: Delete.
698 20009-06-07 Pedro Alves <pedro@codesourcery.com>
700 * auxv.c (procfs_xfer_auxv): Change type of the `object' argument
701 to enum target_object. Cleanup comments.
702 * auxv.h: Include "target.h". Cleanup comments to not mention
703 NATIVE_XFER_AUXV anymore.
705 2009-06-07 Pedro Alves <pedro@codesourcery.com>
707 * inferior.h (procfs_first_available): Move declaration to...
708 * proc-utils.h: ... here.
709 * sol-thread.c: Include procfs.h and proc-utils.h.
711 2009-06-07 Pedro Alves <pedro@codesourcery.com>
713 * inferior.h (proc_iterate_over_mappings): Delete declaration.
714 * nto-tdep.h (proc_iterate_over_mappings): Delete declaration.
715 * procfs.c (proc_iterate_over_mappings): Delete.
717 2009-06-07 Pedro Alves <pedro@codesourcery.com>
719 * target.h (struct target_ops): Make to_has_all_memory,
720 to_has_memory, to_has_stack, to_has_registers and to_has_execution
721 methods instead of variables.
722 (target_has_all_memory_1, target_has_memory_1, target_has_stack_1)
723 (target_has_registers_1, target_has_execution_1): Declare
725 (target_has_all_memory): Rewrite to call target_has_all_memory_1.
726 (target_has_memory): Rewrite to call target_has_memory_1.
727 (target_has_stack): Rewrite to call target_has_all_stack_1.
728 (target_has_registers): Rewrite to call target_has_registers_1.
729 (target_has_execution): Rewrite to call target_has_execution_1.
730 (default_child_has_all_memory, default_child_has_memory)
731 (default_child_has_stack, default_child_has_registers)
732 (default_child_has_execution): Declare.
733 (target_mark_running, target_mark_exited): Delete declarations.
734 * target.c (default_child_has_all_memory,
735 default_child_has_memory, default_child_has_stack,
736 default_child_has_registers, default_child_has_execution): New.
737 (target_has_all_memory_1, target_has_memory_1, target_has_stack_1,
738 target_has_registers_1, target_has_execution_1): New.
739 (add_target): Default the to_has_all_memory, to_has_all_memory,
740 to_has_memory, to_has_stack, to_has_registers and to_has_execution
741 callbacks to return 0.
742 (update_current_target): Do not inherit to_has_all_memory,
743 to_has_memory, to_has_stack, to_has_registers or to_has_execution.
744 (target_mark_running, target_mark_exited): Delete.
745 (memory_xfer_partial): Adjust.
746 (target_read_memory, target_write_memory, target_search_memory):
747 Dispatch to the the top-most target, not the flattened
749 (target_info): Adjust.
750 (init_dummy_target): Install return_zero as callback for
751 to_has_all_memory, to_has_memory, to_has_stack, to_has_registers,
753 (set_maintenance_target_async_permitted): Use have_live_inferiors
754 instead of target_has_execution.
755 * target-memory.c (target_write_memory_blocks): Dispatch memory
756 writes to the the top-most target, not the flattened
759 * breakpoint.c (insert_breakpoints): Don't check for
760 target_has_execution here.
761 (update_global_location_list): Check if there are live inferiors
762 to debug instead of target_has_execution.
763 * infcmd.c (kill_command, detach_command): Check if there are
764 inferiors instead of target_has_execution.
765 * inferior.h (have_live_inferiors): Declare.
766 * inferior.c (have_live_inferiors): New.
767 * infrun.c (normal_stop): Don't check for target_has_execution to
768 finish the thread states.
769 * thread.c (is_thread_state, is_stopped, is_exited, is_running)
770 (any_running, is_executing): Remove checks for
771 target_has_execution.
772 * top.c (kill_or_detach): Don't try to kill core inferiors.
773 (quit_target): Don't check for target_has_execution.
775 * corelow.c (core_has_memory, core_has_stack, core_has_registers):
777 (init_core_ops): Install core_has_memory, core_has_stack and
779 * exec.c (exec_has_memory): New.
780 (init_exec_ops): Install exec_has_memory.
781 * remote.c (remote_add_inferior): Don't call target_mark_running.
782 (remote_start_remote): Don't call target_mark_exited or call
784 (remote_open_1): Use have_inferiors instead of
785 target_has_execution. Don't use target_mark_exited.
786 (init_remote_ops): Install deafult_child_has_all_memory,
787 default_child_has_memory, default_child_has_stack,
788 default_child_has_registers, default_child_has_execution.
789 * bsd-kvm.c (bsd_kvm_return_one): New.
790 (bsd_kvm_add_target): Register bsd_kvm_return_one as
791 to_has_memory, to_has_stack and to_has_registers callbacks.
792 * remote-m32r-sdi.c (m32r_return_one): New.
793 (init_m32r_ops): Register it.
794 * inf-child.c (inf_child_target): Adjust to register
795 default_child_has_all_memory, default_child_has_memory,
796 default_child_has_stack, default_child_has_registers,
797 default_child_has_execution callbacks.
798 * gnu-nat.c (init_gnu_ops): Likewise.
799 * go32-nat.c (init_go32_ops): Likewise.
800 * hpux-thread.c (init_hpux_thread_ops): Likewise.
801 * monitor.c (init_base_monitor_ops): Likewise.
802 * nto-procfs.c (init_procfs_ops): Likewise.
803 * remote-mips.c (_initialize_remote_mips): Likewise.
804 * windows-nat.c (init_windows_ops): Likewise.
805 * remote-sim.c (gdbsim_create_inferior): Don't use
806 target_mark_running or target_mark_exited.
807 (gdbsim_mourn_inferior): Don't call target_mark_exited.
808 (init_gdbsim_ops): Adjust to register
809 default_child_has_all_memory, default_child_has_memory,
810 default_child_has_stack, default_child_has_registers,
811 default_child_has_execution callbacks.
813 * linux-nat.c (linux_nat_xfer_partial): If reading memory, and
814 there's no inferior selected, defer to a lower stratum.
816 2009-06-05 Tom Tromey <tromey@redhat.com>
818 * varobj.c (update_dynamic_varobj_children): Wrap error text in
820 (install_visualizer): Likewise.
821 (varobj_set_visualizer): Likewise.
823 2009-06-05 Marc Khouzam <marc.khouzam@ericsson.com>
825 * mi/mi-main.c (mi_cmd_exec_continue)
826 (mi_cmd_exec_interrupt): Adjust parsing of thread group
827 ids to current reality, where they don't have any 'p' prefix.
829 2009-06-05 Aleksandar Ristovski <aristovski@qnx.com>
831 * corelow.c (core_open): Check for core_gdbarch before calling
832 gdbarch_target_signal_from_host.
834 2009-06-05 Tom Tromey <tromey@redhat.com>
836 * c-exp.y (parse_number): Don't use K&R definition.
840 2009-06-04 Jan Kratochvil <jan.kratochvil@redhat.com>
842 * varobj.c (varobj_update): Fix out of scope varobjs to not to change.
844 2009-06-04 Ulrich Weigand <uweigand@de.ibm.com>
846 * symtab.h: Rename SYMBOL_OPS to SYMBOL_COMPUTED_OPS.
847 * ax-gdb.c (gen_var_ref): Likewise.
848 * findvar.c (read_var_value, symbol_read_needs_frame): Likewise.
849 * printcmd.c (address_info): Likewise.
850 * dwarf2loc.c (dwarf_expr_frame_base): Likewise.
851 * dwarf2read.c (dwarf2_symbol_mark_computed): Likewise.
852 * symtab.h: Rename struct symbol_ops to struct symbol_computed_ops.
853 * dwarf2loc.h: Likewise.
854 * dwarf2loc.c (dwarf2_locexpr_funcs, dwarf2_loclist_funcs): Likewise.
856 * symtab.h: (struct symbol_register_ops): New struct definition.
857 (struct symbol): Make "ops" member a union of symbol_computed_ops and
858 symbol_register_ops callback pointers.
859 (SYMBOL_REGISTER_OPS): New macro.
860 * tracepoint.c: Include "objfiles.h".
861 (scope_info, collect_symbol): Use SYMBOL_REGISTER_OPS register_number
862 callback to retrieve register numbers.
863 * ax-gdb.c (gen_var_ref): Likewise.
864 * findvar.c (read_var_value): Likewise.
865 * printcmd.c (address_info): Likewise.
867 * coffread.c (coff_reg_to_regnum): New function.
868 (coff_register_funcs): New static variable.
869 (process_coff_symbol): Do not call gdbarch_sdb_reg_to_regnum.
870 Install SYMBOL_REGISTER_OPS callbacks.
871 * mdebugread.c (mdebug_reg_to_regnum): New function.
872 (mdebug_register_funcs): New static variable.
873 (parse_symbol): Do not call gdbarch_ecoff_reg_to_regnum.
874 Install SYMBOL_REGISTER_OPS callbacks.
875 * stabsread.c (stab_reg_to_regnum): New function.
876 (stab_register_funcs): New static variable.
877 (define_symbol): Do not call gdbarch_stab_reg_to_regnum.
878 Install SYMBOL_REGISTER_OPS callbacks.
880 2009-06-03 Doug Evans <dje@google.com>
882 * symfile.c (reread_symbols): Reset psymtabs_addrmap to NULL
883 after discarding its contents.
885 2009-06-03 Pedro Alves <pedro@codesourcery.com>
887 * target.c: Include "exec.h".
888 (update_current_target): Don't inherit to_sections or
890 (target_get_section_table): New.
891 (target_section_by_addr): Fetch the section table from the passed
893 (memory_xfer_partial): Handle unmapped overlay sections before
894 anything else. Get the overlay mapped address here. Adjust to
895 use section_table_xfer_memory_partial.
896 (get_target_memory): Request a TARGET_OBJECT_RAW_MEMORY object
897 instead of TARGET_OBJECT_MEMORY.
898 (target_resize_to_sections): Delete.
899 (remove_target_sections): Adjust to remove target sections from
900 `current_target_sections', and use resize_section_table.
901 * target.h (struct target_ops) <to_sections, to_sections_end>:
903 <to_get_section_table>: New method.
904 (xfer_memory, print_section_info): Delete declarations.
905 (struct target_section_table): New type.
906 (target_get_section_table): Declare.
907 (target_resize_to_sections): Delete declaration.
908 (remove_target_sections): Delete declaration.
909 * bfd-target.c (target_bfd_xfer_partial): Get the section table
911 (target_bfd_get_section_table): New.
912 (target_bfd_xclose): Adjust.
913 (target_bfd_reopen): Store the section table in the to_data field.
914 * corelow.c (core_data): New.
915 (core_close): Adjust to release core_data and its sections.
916 (core_open): Allocate core_data, and build its target sections
918 (deprecated_core_resize_section_table): New.
919 (core_files_info): Pass core_data to print_section_info.
920 (core_xfer_partial): Adjust to use
921 section_table_xfer_memory_partial for TARGET_OBJECT_MEMORY xfers.
922 (init_core_ops): Do not install a deprecated_xfer_memory callback
924 * solib.c (update_solib_list): Add the shared library sections
925 to the current target sections table.
926 * exec.c (current_target_sections_1): New global.
927 (current_target_sections): New global.
928 (exec_close_1): New function, refactored from exec_close. Remove
929 the exec_bfd's sections from the current target sections table.
930 Adjust to not use to_sections.
931 (exec_close): Remove all target sections. Call exec_close_1.
932 (exec_file_clear): Use exec_close_1 instead of unpushing the
934 (exec_file_attach): Likewise. Adjust to not use to_sections. Add
935 exec_bfd's sections to the current target sections table. Don't
936 push the exec_ops target here.
937 (resize_section_table): New.
938 (add_target_sections): New.
939 (remove_target_sections): Moved here.
940 (section_table_xfer_memory): Adjust to implement the xfer_partial
941 interface, and rename to...
942 (section_table_xfer_memory_partial): ... this, replacing the
943 current function of that same name.
944 (exec_get_section_table): New.
945 (exec_xfer_partial): New.
946 (xfer_memory): Delete.
947 (print_section_info): Replace the target_ops parameter by a
948 target_section_table parameter.
949 (exec_files_info, set_section_command, exec_set_section_address):
950 Adjust to use the current sections table.
951 (init_exec_ops): Do not register a deprecated_xfer_memory
952 callback. Register to_xfer_partial and to_get_section_table
954 * infrun.c (handle_inferior_event): Update comments around
956 * rs6000-nat.c (xcoff_relocate_core): Adjust to use
957 deprecated_core_resize_section_table.
958 * exec.h (resize_section_table): Declare.
959 (section_table_xfer_memory_partial): Add const char * argument.
960 (remove_target_sections): Declare here.
961 (add_target_sections): Declare.
962 (print_section_info): Declare here.
963 * gdbcore.h (deprecated_core_resize_section_table): Declare.
965 2009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
967 * value.h (struct internalvar): Remove.
968 (get_internalvar_integer): Add prototype.
969 (set_internalvar_integer): Add prototype.
970 (clear_internalvar): Add prototype.
972 * value.c (struct internalvar): Move here. Add type member. Remove
973 endian member. Add union_internalvar member instead of value member.
974 (init_if_undefined_command): Use intvar->type.
975 (create_internalvar): Do not initialize value/endian, but type.
976 (create_internalvar_type_lazy): Call create_internalvar.
977 (value_of_internalvar): Handle host-side internalvar contents.
978 (set_internalvar_component): Likewise.
979 (set_internalvar): Likewise.
980 (get_internalvar_integer): New function.
981 (clear_internalvar): Likewise.
982 (set_internalvar_integer): Likewise.
983 (preserve_values): Handle host-side internalvar contents.
985 * breakpoint.c (set_breakpoint_count, set_tracepoint_count): Call
986 set_internalvar_integer instead of set_internalvar.
987 * findcmd.c (find_command): Likewise.
988 * infrun.c (handle_inferior_event): Likewise.
989 * source.c (forward_search_command, reverse_search_command): Likewise.
990 * tracepoint.c (set_traceframe_num, set_tracepoint_num,
991 set_traceframe_context): Likewise.
993 * printcmd.c (x_command): Call clear_internalvar instead of
995 * tracepoint.c (set_traceframe_context): Likewise.
997 * breakpoint.c (get_number_trailer): Call get_internalvar_integer
998 instead of value_of_internalvar.
999 * linespec.c (decode_dollar): Likewise.
1001 * expprint.c (dump_subexp_body_standard): Use internalvar_name
1002 instead of accessing internalvar private elements.
1003 * valops.c (value_assign): Copy from original source instead of
1004 accessing internalvar private elements.
1006 2009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
1008 * scm-lang.c (builtin_type_scm): Remove.
1009 (scm_lookup_name): Add GDBARCH parameter. Use it instead of
1010 objfile architecture. Use per-architecture builtin_scm_type instead
1011 of builtin_type_scm.
1012 (evaluate_exp): Pass expression architecture to scm_lookup_name.
1014 (scm_get_field): Add SIZE parameter. Use it instead of
1015 TYPE_LENGTH (builtin_type_scm).
1017 (build_scm_types): New function.
1018 (scm_type_data): New variable.
1019 (builtin_scm_type): New function.
1020 (_initialize_scheme_language): Do not initialize builtin_type_scm.
1021 Register build_scm_types as post-init function for scm_type_data.
1023 * scm-exp.c (scm_lreadr): Use per-architecture builtin_scm_type
1024 instead of builtin_type_scm.
1026 * scm-lang.h (SCM_CAR, SCM_CDR): Pass SCM_SIZE to scm_get_field.
1027 (scm_get_field): Add SIZE paramter.
1028 (scm_scmval_print): Remove prototype.
1029 (builtin_type_scm): Remove.
1030 (struct builtin_scm_type): Add structure definition.
1031 (builtin_scm_type): Add prototype.
1033 * scm-valprint.c (scm_inferior_print): Add TYPE parameter. Use it
1034 instead of builtin_core_addr type; do not use objfile architecture.
1035 (scm_scmlist_print): Add TYPE parameter. Use it to define SCM_SIZE.
1036 Pass type to scm_scmval_print.
1037 (scm_ipruk): Add TYPE parameter. Use it to define SCM_SIZE.
1038 (scm_scmval_print): Make static. Add TYPE parameter. Use it to
1039 define SCM_SIZE. Pass type to scm_ipruk and scm_scmlist_print.
1040 (scm_val_print): Pass type to scm_inferior_print and scm_scmval_print.
1042 2009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
1044 * mdebugread.c (mdebug_type_void, mdebug_type_char, mdebug_type_short,
1045 mdebug_type_int, mdebug_type_int_32, mdebug_type_int_64,
1046 mdebug_type_long_32, mdebug_type_long_64, mdebug_type_long_long_64,
1047 mdebug_type_unsigned_char, mdebug_type_unsigned_short,
1048 mdebug_type_unsigned_int_32, mdebug_type_unsigned_int_64,
1049 mdebug_type_unsigned_long_32, mdebug_type_unsigned_long_64,
1050 mdebug_type_unsigned_long_long_64, mdebug_type_adr_32,
1051 mdebug_type_adr_64, mdebug_type_float, mdebug_type_double,
1052 mdebug_type_complex, mdebug_type_double_complex,
1053 mdebug_type_fixed_dec, mdebug_type_float_dec, mdebug_type_string):
1056 (basic_type_data): New global variable.
1057 (basic_type): New function.
1058 (parse_type): Remove static basic type map map_bt. Call basic_type
1059 to get basic types instead of using mdebug_type_ variables.
1061 (parse_symbol): Use builtin types instead of mdebug_type_ variables.
1062 (upgrade_type): Likewise.
1063 (parse_procedure): Likewise.
1064 (psymtab_to_symtab_1): Likewise.
1066 (_initialize_mdebugread): Do not initialize mdebug_type_ variables.
1067 Initialize basic_type_data.
1069 2009-06-03 Ulrich Weigand <uweigand@de.ibm.com>
1071 * dfp.h (decimal_binop): Convert LEN_RESULT to input parameter.
1072 * dfp.c (promote_decimal): Remove.
1073 (decimal_binop): Convert LEN_RESULT to input parameter.
1074 Remove call to decimal_binop.
1075 (decimal_compare): Remove call to decimal_binop.
1077 * valarith.c (value_binop): Pass desired result type length
1080 2009-06-01 Tristan Gingold <gingold@adacore.com>
1082 * configure.tgt (avr): Set gdb_sim to use the simulator.
1084 2009-05-29 Doug Evans <dje@google.com>
1086 * infrun.c (prepare_to_proceed): Document. Assert !non_stop.
1087 If scheduler-locking is enabled, we're not going to be singlestepping
1088 any other previously stopped thread.
1090 2009-05-29 Pedro Alves <pedro@codesourcery.com>
1092 * mi/mi-interp.c (mi_on_resume): Initialize `count' to 0.
1094 2009-05-29 Eli Zaretskii <eliz@gnu.org>
1096 * i386-tdep.c (i386_go32_init_abi): Use SVR4 register numbering
1097 for stabs and COFF debug info.
1099 2009-05-28 Pedro Alves <pedro@codesourcery.com>
1101 * infrun.c (handle_inferior_event): When thread hoping, switch
1102 inferior_ptid to the event thread before removing breakpoints from
1103 the target. If not stopping, also try to revert back to a thread
1104 that was doing a "next". Check if that thread still exists before
1106 (currently_stepping_thread): Delete and merge with ...
1107 (currently_stepping): ... this.
1108 (currently_stepping_callback): Rename to ...
1109 (currently_stepping_or_nexting_callback): ... this, and also
1110 return true if the thread was stepping over a call (has a
1111 step-resume breakpoint).
1113 2009-05-28 Tom Tromey <tromey@redhat.com>
1115 * python/python.c (gdbpy_parameter): Rename. Fix error message.
1116 (GdbMethods): Change "get_parameter" to "parameter".
1118 2009-05-28 Pierre Muller <muller@ics.u-strasbg.fr>
1119 Paul Pluzhnikov <ppluzhnikov@google.com>
1121 * configure.ac (!have_libpython): Add python-prettyprint source
1123 * configure: Regenerate.
1124 * python/python-prettyprint.c: Move "#ifdef HAVE_PYTHON" before
1127 2009-05-27 Vladimir Prus <vladimir@codesourcery.com>
1128 Tom Tromey <tromey@redhat.com>
1129 Thiago Jung Bauermann <bauerman@br.ibm.com>
1131 * mi/mi-main.c (mi_cmd_list_features): List "python" feature.
1132 * varobj.h (varobj_set_visualizer): Declare.
1133 (varobj_get_display_hint): Likewise.
1134 (varobj_update_result_t) <children_changed, value_installed>: New
1136 * mi/mi-cmds.c (mi_cmds): Add var-set-visualizer.
1137 * mi/mi-cmds.h (mi_cmd_var_set_visualizer,
1138 mi_cmd_var_set_child_range): Declare.
1139 * mi/mi-cmd-var.c (mi_cmd_var_set_visualizer): New function.
1140 (mi_cmd_var_list_children): Emit display hint.
1141 (varobj_update_one): Emit display hint. Handle dynamic children.
1142 * python/python.c (GdbMethods): Add "default_visualizer".
1143 * python/python-internal.h (apply_varobj_pretty_printer,
1144 gdbpy_get_varobj_pretty_printer, gdbpy_get_display_hint):
1146 (gdbpy_default_visualizer): Likewise.
1147 * varobj.c: Include python.h, python-internal.h.
1148 (PyObject): New typedef.
1149 (struct varobj) <children_requested, pretty_printer>: New fields.
1150 (varobj_create): Call install_default_visualizer.
1151 (instantiate_pretty_printer): New function.
1152 (varobj_set_display_format): Update.
1153 (varobj_get_display_hint): New function.
1154 (update_dynamic_varobj_children): New function.
1155 (varobj_get_num_children): Handle dynamic children.
1156 (varobj_list_children): Likewise.
1157 (install_new_value): Likewise.
1158 (varobj_add_child): New function.
1159 (install_visualizer): Likewise.
1160 (install_default_visualizer): Likewise.
1161 (varobj_set_visualizer): Likewise.
1162 (varobj_update): Handle dynamic children.
1163 (create_child): Use create_child_with_value.
1164 (create_child_with_value): New function.
1165 (value_get_print_value): Call pretty printer. Add value_formatter
1167 (c_value_of_variable): Update.
1168 (varobj_invalidate): Always free all_rootvarobj.
1169 * python/python-prettyprint.c (apply_varobj_pretty_printer): New
1171 (gdbpy_get_varobj_pretty_printer): Likewise.
1172 (gdbpy_default_visualizer): Likewise.
1174 2009-05-27 Tom Tromey <tromey@redhat.com>
1175 Thiago Jung Bauermann <bauerman@br.ibm.com>
1176 Phil Muldoon <pmuldoon@redhat.com>
1177 Paul Pluzhnikov <ppluzhnikov@google.com>
1178 Vladimir Prus <vladimir@codesourcery.com>
1180 * python/python-value.c (value_object_to_value): New function.
1181 * python/python-internal.h: Include frameobject.h.
1182 (gdbpy_children_cst, gdbpy_to_string_cst, gdbpy_display_hint_cst):
1184 (value_object_to_value): Declare.
1185 * printcmd.c (struct format_data) <raw>: New field.
1186 (last_format): Default to 0.
1187 (decode_format): Initialize val.raw. Handle /r flag.
1188 (print_command_1): Initialize fmt.raw and opts.raw.
1189 (output_command): Likewise.
1190 (x_command): Fix initialization of fmt.format. Initialize
1192 (display_command): Initialize fmt.raw.
1193 (do_one_display): Set opts.raw.
1194 * python/python.c (gdbpy_to_string_cst, gdbpy_children_cst,
1195 gdbpy_display_hint_cst): New globals.
1196 (_initialize_python): Initialize them. Set gdb.pretty_printers.
1197 * cp-valprint.c: Include python.h.
1198 (cp_print_value): Call apply_val_pretty_printer.
1199 * python/python.h (apply_val_pretty_printer): Declare.
1200 * stack.c (print_this_frame_argument_p): Remove.
1201 (print_frame_args): Compute summary flag. Don't use
1202 print_this_frame_argument_p.
1203 * valprint.c: Include python.h.
1204 (user_print_options): Initialize new fields.
1205 (scalar_type_p): New function.
1206 (val_print): Handle 'raw' and 'summary' modes. Call
1207 apply_val_pretty_printer.
1208 (value_print): Handle 'raw' mode.
1209 * valprint.h (struct value_print_options) <raw, summary>: New
1211 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-prettyprint.o
1212 (SUBDIR_PYTHON_SRCS): Add python-prettyprint.c.
1213 (python-prettyprint.o): New target.
1214 * python/python-prettyprint.c: New file.
1216 2009-05-27 Tom Tromey <tromey@redhat.com>
1217 Paul Pluzhnikov <ppluzhnikov@google.com>
1219 * mi/mi-main.c (mi_cmd_data_evaluate_expression): Use
1221 * cli/cli-dump.c (dump_value_to_file): Use value_address.
1222 * valprint.c (common_val_print): Likewise.
1223 * v850-tdep.c (v850_push_dummy_call): Use value_address.
1224 * tracepoint.c (encode_actions): Use value_address.
1225 * printcmd.c (print_formatted): Use value_address.
1226 (x_command): Likewise.
1227 * p-valprint.c (pascal_object_print_static_field): Use
1229 * mn10300-tdep.c (mn10300_push_dummy_call): Use value_address.
1230 * mips-tdep.c (mips_eabi_push_dummy_call): Use value_address.
1231 * m32r-tdep.c (m32r_push_dummy_call): Use value_address.
1232 * jv-valprint.c (java_value_print): Use value_address.
1233 * infcall.c (find_function_addr): Use value_address.
1234 * gnu-v3-abi.c (gnuv3_rtti_type): Use value_address.
1235 * gnu-v2-abi.c (gnuv2_value_rtti_type): Use value_address.
1236 * frv-tdep.c (frv_push_dummy_call): Use value_address.
1237 * frame.c (frame_register_unwind): Use value_address.
1238 (frame_unwind_register_value): Likewise.
1239 * darwin-nat-info.c (info_mach_region_command): Use
1241 * cp-valprint.c (cp_print_static_field): Use value_address.
1242 * c-valprint.c (c_value_print): Use value_address.
1243 * breakpoint.c (update_watchpoint): Use value_address.
1244 (can_use_hardware_watchpoint): Likewise.
1245 * ada-valprint.c (ada_val_print_1): Use value_address.
1246 (ada_value_print): Likewise.
1247 * ada-tasks.c (read_fat_string_value): Use value_address.
1248 * jv-lang.c (java_link_class_type): Use set_value_address.
1249 (java_link_class_type): Likewise.
1250 (get_java_utf8_name): Use value_address.
1251 (type_from_class): Likewise.
1252 (java_link_class_type): Likewise.
1253 * findvar.c (value_of_register): Use set_value_address.
1254 (read_var_value): Likewise.
1255 (read_var_value): Likewise.
1256 * eval.c (evaluate_subexp_standard): Use set_value_address.
1257 (evaluate_subexp_standard): Use value_address.
1258 * dwarf2loc.c (dwarf2_evaluate_loc_desc): Use set_value_address.
1259 * ada-lang.c (coerce_unspec_val_to_type): Use set_value_address.
1260 (ada_value_primitive_packed_val): Likewise.
1261 (ensure_lval): Likewise.
1262 (thin_data_pntr): Use value_address.
1263 (desc_bounds): Likewise.
1264 (ada_value_primitive_packed_val): Likewise.
1265 (value_assign_to_component): Likewise.
1266 (ensure_lval): Likewise.
1267 (make_array_descriptor): Likewise.
1268 (ada_to_fixed_value): Likewise.
1269 (unwrap_value): Likewise.
1270 * value.c (deprecated_value_address_hack): Remove.
1271 (value_address): New function.
1272 (value_raw_address): Likewise.
1273 (set_value_address): Likewise.
1274 (value_fn_field): Use set_value_address.
1275 (value_from_contents_and_address): Likewise.
1276 (value_fn_field): Likewise.
1277 (allocate_value_lazy): Don't use VALUE_ADDRESS.
1278 (value_as_address): Use value_address.
1279 (value_static_field): Likewise.
1280 * valops.c (search_struct_field): Use set_value_address.
1281 (value_at): Likewise.
1282 (value_at_lazy): Likewise.
1283 (value_repeat): Likewise.
1284 (value_cast_structs): Use value_address.
1285 (value_cast): Likewise.
1286 (value_fetch_lazy): Likewise.
1287 (value_assign): Likewise.
1288 (value_repeat): Likewise.
1289 (address_of_variable): Likewise.
1290 (value_coerce_array): Likewise.
1291 (value_coerce_function): Likewise.
1292 (value_addr): Likewise.
1293 (search_struct_field): Likewise.
1294 (search_struct_method): Likewise.
1295 (find_method_list): Likewise.
1296 (value_struct_elt_for_reference): Likewise.
1297 (value_full_object): Likewise.
1298 * jv-valprint.c (java_value_print): Use set_value_address.
1299 * value.h (deprecated_value_address_hack): Remove.
1300 (VALUE_ADDRESS): Remove.
1301 (value_address): Declare.
1302 (value_raw_address): Declare.
1303 (set_value_address): Declare.
1305 2009-05-27 Tom Tromey <tromey@redhat.com>
1306 Thiago Jung Bauermann <bauerman@br.ibm.com>
1307 Phil Muldoon <pmuldoon@redhat.com>
1308 Paul Pluzhnikov <ppluzhnikov@google.com>
1310 * python/python.c (_initialize_python): Call
1311 gdbpy_initialize_types.
1312 (GdbMethods): Add "lookup_type".
1313 * python/python-value.c (value_object) <type>: New field.
1314 (valpy_dealloc): Decref type.
1315 (valpy_new): Initialize type.
1316 (valpy_get_type): New function.
1317 (value_to_value_object): Initialize type.
1318 (valpy_cast): New function.
1319 (value_object_getset): Add "type".
1320 (value_object_methods): Add "cast".
1321 * python/python-internal.h (type_to_type_object): Declare.
1322 (type_object_to_type): Likewise.
1323 (gdbpy_initialize_types): Likewise.
1324 (gdbpy_lookup_type): Declare.
1325 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-type.o.
1326 (SUBDIR_PYTHON_SRCS): Add python-type.c.
1327 (python-type.o): New target.
1328 * python/python-type.c: New file.
1330 2009-05-27 Tom Tromey <tromey@redhat.com>
1331 Thiago Jung Bauermann <bauerman@br.ibm.com>
1332 Phil Muldoon <pmuldoon@redhat.com>
1334 * python/python.c: Include objfiles.h, observer.h.
1335 (gdbpy_auto_load): New global.
1336 (gdbpy_current_objfile): Likewise.
1337 (GDBPY_AUTO_FILENAME): New define.
1338 (gdbpy_new_objfile): New function.
1339 (gdbpy_get_current_objfile): Likewise.
1340 (gdbpy_objfiles): Likewise.
1341 (_initialize_python): Add "maint set auto-load". Call
1342 gdbpy_initialize_objfile. Attach objfile observer.
1343 (GdbMethods): New methods current_objfile, objfiles.
1344 * python/python-objfile.c: New file.
1345 * python/python-internal.h (objfile_to_objfile_object): Declare.
1346 (objfpy_get_printers): Likewise.
1347 (gdbpy_initialize_objfile): Likewise.
1348 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-objfile.o.
1349 (SUBDIR_PYTHON_SRCS): Add python-objfile.c.
1350 (python-objfile.o): New target.
1352 2009-05-27 Pedro Alves <pedro@codesourcery.com>
1354 * infrun.c (follow_exec): Clear the stop_requested flag.
1355 * linux-nat.c (linux_handle_extended_wait) <PTRACE_EVENT_EXEC>:
1358 2009-05-27 Aleksandar Ristovski <aristovski@qnx.com>
1360 * nto-procfs.c (get_regset): Pass correct pointer.
1362 2009-05-26 Doug Evans <dje@google.com>
1364 * dwarf2read.c (follow_die_ref): Add comment.
1365 (dwarf2_mark_helper): Tweak comment.
1366 (dwarf2_mark): Move description to its proper place.
1368 2009-05-25 Pierre Muller <muller@ics.u-strasbg.fr>
1370 * procfs.c (procfs_wait): Add options parameter.
1372 2009-05-24 Doug Evans <dje@google.com>
1374 Global renaming of find_thread_pid to find_thread_ptid.
1375 * gdbthread.h (find_thread_ptid): Renamed from find_thread_pid.
1376 * thread.c (find_thread_ptid): Renamed from find_thread_pid.
1377 All callers updated.
1379 * infrun.c (follow_fork): Initialize new step_* locals
1380 to avoid "may be used uninitialized" warnings.
1382 2009-05-24 Pedro Alves <pedro@codesourcery.com>
1384 * inflow.c (copy_terminal_info): Deep copy `run_terminal'.
1386 2009-05-24 Pedro Alves <pedro@codesourcery.com>
1388 * gdbthread.h (struct thread_info): New `pending_follow' field.
1389 * thread.c (new_thread): New function.
1390 (add_thread_silent): Use it.
1391 * breakpoint.c (internal_breakpoint_number): New global, moved
1393 (create_internal_breakpoint): ... this.
1394 (clone_momentary_breakpoint): New.
1395 * breakpoint.h (clone_momentary_breakpoint): Declare.
1396 * infrun.c (nullify_last_target_wait_ptid): Move declaration
1398 (pending_follow): Delete.
1399 (follow_fork): Handle pending follow fork event here. Moved the
1400 preserving of thread stepping state here.
1401 (resume): Don't handle pending follow fork events here. Only
1402 install the inferior's terminal modes if we're about to resume it.
1403 (proceed): Handle possible pending follow fork events here.
1404 (init_wait_for_inferior): No need to clear pending_follow anymore,
1406 (handle_inferior_event): Adjust to per-thread `pending_follow'.
1407 Call `follow_fork' to handle following the fork. If the
1408 follow-fork is cancelled, stop stepping.
1409 * linux-nat.c (linux_child_follow_fork): Adjust to per-thread
1410 `pending_follow' events. Remove code that handled preserving the
1411 thread stepping state.
1412 * inf-ptrace.c (inf_ptrace_follow_fork): Ditto.
1413 * inf-ttrace.c (inf_ttrace_follow_fork): Ditto.
1415 2009-05-24 Pierre Muller <muller@ics.u-strasbg.fr>
1417 * symfile.c (add_shared_symbol_files_command): Remove
1418 prototype and function.
1419 (_initialize _symfile): Move "add-shared-symbol-files"
1420 command and "assf" alias.
1421 * windows-nat.c (_initialize_windows_nat): to here.
1422 Change "add-shared-symbol-files" to alias.
1424 * config/i386/cygwin.mh: Remove NAT_FILE.
1425 * config/i386/mingw.mh: Remove NAT_FILE.
1426 * config/i386/mingw64.mh: Remove NAT_FILE.
1427 * config/i386/nm-cygwin.h: Remove file.
1428 * config/i386/nm-cygwin64.h: Remove file.
1430 2009-05-24 Hui Zhu <teawater@gmail.com>
1432 * i386-linux-tdep.c (I386_LINUX_RECORD_SIZE_*,
1433 I386_LINUX_RECORD_IOCTL_*,
1434 I386_LINUX_RECORD_FCNTL_*) Removed.
1435 (i386_linux_init_abi): Change size of record from macros to
1438 2009-05-24 Hui Zhu <teawater@gmail.com>
1440 * i386-linux-tdep.c (i386_linux_init_abi): Remove size_char.
1441 * linux-record.c (record_linux_system_call): Ditto.
1442 * linux-record.h (linux_record_tdep): Ditto.
1444 2009-05-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1446 Replace the savestring calls by xstrdup calls where possible.
1447 * breakpoint.c (condition_command, set_raw_breakpoint)
1448 (create_catchpoint, update_breakpoint_locations): Replace the
1449 savestring calls by xstrdup calls where possible.
1450 * buildsym.c (start_subfile, patch_subfile_names, record_debugformat)
1451 (record_producer): Likewise.
1452 * coffread.c (coff_start_symtab, complete_symtab): Likewise.
1453 * corefile.c (set_gnutarget): Likewise.
1454 * dbxread.c (add_new_header_file): Likewise.
1455 * demangle.c (set_demangling_command, set_demangling_style): Likewise.
1456 * event-top.c (push_prompt, pop_prompt, command_line_handler)
1457 (set_async_prompt): Likewise.
1458 * infcmd.c (set_inferior_io_terminal, attach_command_post_wait):
1460 * language.c (set_language_command, _initialize_language): Likewise.
1461 * linespec.c (decode_line_2): Likewise.
1462 * rs6000-nat.c (add_vmap): Likewise.
1463 * top.c (set_prompt, init_history, init_main): Likewise.
1464 * tracepoint.c (stringify_collection_list): Likewise.
1465 * varobj.c (varobj_create): Remove variable expr_len. Replace the
1466 savestring calls by xstrdup calls where possible.
1467 (value_of_root, c_name_of_variable, c_describe_child): Replace the
1468 savestring calls by xstrdup calls where possible.
1469 * xcoffread.c (complete_symtab): Likewise.
1470 * cli/cli-script.c (build_command_line, define_command): Likewise.
1471 * cli/cli-setshow.c (do_setshow_command): Likewise.
1473 2009-05-23 Jan Kratochvil <jan.kratochvil@redhat.com>
1475 Remove already unreachable code.
1476 * varobj.c (varobj_get_handle): Fix comment when error is called.
1477 All callers updated.
1479 2009-05-23 Eli Zaretskii <eliz@gnu.org>
1481 * README (`configure' options): Document GDB-specific options to
1484 * symtab.c (skip_prologue_using_lineinfo): New function.
1485 (find_function_start_sal): Use it to get to the first line of
1486 function's body that has an entry in the lineinfo table.
1488 * symmisc.c (dump_symtab): Switch the current language to
1489 the language of the symtab we are dumping only if the symtab's
1490 language is neither language_auto nor language_unknown.
1492 * coffread.c (coff_symtab_read): Set language_minimal as the
1493 language for the "_globals_" pseudo-file.
1494 (process_coff_symbol): Set the symbol's language to the language
1497 2009-05-22 Pedro Alves <pedro@codesourcery.com>
1499 * target.h (struct section_table): Rename to ...
1500 (struct target_section): ... this.
1501 * exec.c: Adjust all references.
1502 * exec.h: Adjust all references.
1503 * nto-tdep.c: Adjust all references.
1504 * nto-tdep.h: Adjust all references.
1505 * ppc-linux-tdep.c: Adjust all references.
1506 * rs6000-nat.c: Adjust all references.
1507 * s390-tdep.c: Adjust all references.
1508 * solib-darwin.c: Adjust all references.
1509 * solib-frv.c: Adjust all references.
1510 * solib-irix.c: Adjust all references.
1511 * solib-null.c: Adjust all references.
1512 * solib-osf.c: Adjust all references.
1513 * solib-pa64.c: Adjust all references.
1514 * solib-som.c: Adjust all references.
1515 * solib-sunos.c: Adjust all references.
1516 * solib-svr4.c: Adjust all references.
1517 * solib-target.c: Adjust all references.
1518 * solib.c: Adjust all references.
1519 * solist.h: Adjust all references.
1520 * symfile.c: Adjust all references.
1521 * symfile.h: Adjust all references.
1522 * target.c: Adjust all references.
1524 2009-05-22 Hui Zhu <teawater@gmail.com>
1526 Add sys_fcntl argument interfaces to linux_record_tdep.
1528 * linux-record.h (linux_record_tdep): Add fcntl_F_GETLK,
1529 fcntl_F_GETLK64, fcntl_F_SETLK64 and fcntl_F_SETLKW64 to be
1531 * i386-linux-tdep.c (I386_LINUX_RECORD_FCNTL_F_GETLK,
1532 I386_LINUX_RECORD_FCNTL_F_GETLK64,
1533 I386_LINUX_RECORD_FCNTL_F_SETLK64,
1534 I386_LINUX_RECORD_FCNTL_F_SETLKW64): New macros. The values
1535 of I386 Linux sys_fcntl arguments.
1536 (i386_linux_init_abi): Set macros values to linux_record_tdep.
1537 * linux-record.c (record_linux_system_call): Change to use
1538 the interface in linux_record_tdep in sys_fcntl and
1541 * linux-record.c (record_linux_system_call): Fix the process
1542 record build error about type in CYGWIN.
1544 2009-05-22 Pedro Alves <pedro@codesourcery.com>
1546 * inflow.c (kill_command): Delete left over static declaration.
1548 2009-05-22 Pedro Alves <pedro@codesourcery.com>
1550 * bfd-target.c: Don't include gdb_assert.h or gdb_string.h.
1552 (struct section_closure): Delete.
1553 (add_to_section_table): Delete.
1554 (build_target_sections_from_bfd): Delete.
1555 (target_bfd_xfer_partial): Use section_table_xfer_memory_partial.
1556 (target_bfd_reopen): Use build_section_table.
1557 * exec.c (xfer_memory): Move most code except for overlay
1558 debugging support from here...
1559 (section_table_xfer_memory): ... to this new function.
1560 (section_table_xfer_memory_partial): New.
1561 * exec.h (section_table_xfer_memory_partial): Declare.
1562 * bfd-target.h (build_target_sections_from_bfd): Delete
1565 2009-05-22 Pedro Alves <pedro@codesourcery.com>
1567 * remote.c (compare_sections_command): Don't declare exec_bfd.
1568 * tracepoint.c: Include "gdbcore.h".
1569 (remote_set_transparent_ranges): Don't declare exec_bfd.
1571 2009-05-21 Pedro Alves <pedro@codesourcery.com>
1573 * aix-thread.c (init_aix_thread_ops): Whitespace.
1575 2009-05-21 Pedro Alves <pedro@codesourcery.com>
1577 * dec-thread.c (dec_thread_wait): Add options parameter. Use it
1578 to call the to_wait method in the target beneath.
1579 * remote-m32r-sdi.c (m32r_wait): Add options parameter.
1581 2009-05-21 Joel Brobecker <brobecker@adacore.com>
1583 * aix-thread.c (aix_thread_wait): Add options parameter. Use it
1584 to call the to_wait method in the target_beneath.
1586 2009-05-21 Pedro Alves <pedro@codesourcery.com>
1588 * linux-nat.c (linux_nat_terminal_inferior)
1589 (linux_nat_terminal_ours): Don't check sync_execution.
1590 * remote.c (remote_terminal_inferior, remote_terminal_ours):
1591 Don't check sync_execution. Update comments.
1592 * target.c (target_terminal_inferior): New.
1593 * target.h (target_terminal_inferior): Delete macro, and declare
1595 * event-top.c (async_disable_stdin): Make idempotent. Don't give
1596 the target the terminal here.
1597 * inflow.c (terminal_ours_1): Don't return early without setting
1600 2009-05-21 Pedro Alves <pedro@codesourcery.com>
1602 * target.h (TARGET_WNOHANG): New.
1603 * target.c (target_wait): Add `options' argument. Adjust.
1604 (struct target_ops) <to_wait>: Add `options' argument.
1605 (target_wait): Add `options' argument.
1606 * infrun.c (wait_for_inferior): Pass 0 as options to
1607 target_wait (blocking wait).
1608 (fetch_inferior_event): Pass TARGET_WNOHANG as options to
1610 * fork-child.c (startup_inferior): Pass 0 as options to
1611 target_wait (blocking wait).
1612 * linux-nat.c (linux_nat_create_inferior): Remove async masking.
1613 (linux_nat_wait_1): Add `target_options' argument. Use it instead
1614 of checking on target_can_async_p.
1615 (linux_nat_wait): Add `target_options' argument. Adjust.
1616 * remote.c (remote_wait_ns): Add `options' argument. Adjust to
1617 check on TARGET_WNOWAIT instead of checking on remote_is_async_p.
1618 (remote_wait_as): Add `options' argument. Adjust to check on
1619 TARGET_WNOWAIT instead of checking on remote_is_async_p. If doing
1620 a blocking wait, keep waiting until an interesting event comes
1622 (remote_wait): Add `options' argument. Don't loop here if the
1623 target is in async mode, and a blocking wait has been requested.
1625 * top.c (deprecated_target_wait_hook): Add `options' argument.
1626 * linux-thread-db.c (thread_db_wait): Add `options' argument, and
1627 pass it down to the layer beneath.
1628 * inf-ptrace.c (inf_ptrace_wait): Add `options' argument.
1629 * record.c (record_beneath_to_wait): Add `options' argument.
1630 (record_wait): Add `options' argument, and pass it down to the
1632 * bsd-uthread.c (bsd_uthread_wait): Add `options' argument.
1633 * darwin-nat.c (darwin_wait): Likewise.
1634 * defs.h (deprecated_target_wait_hook): Likewise.
1635 * gnu-nat.c (gnu_wait): Add `options' argument.
1636 * go32-nat.c (go32_wait): Likewise.
1637 * hpux-thread.c (hpux_thread_wait): Add `options' argument, and
1638 pass it down to the layer beneath.
1639 * inf-ttrace.c (inf_ttrace_wait): Add `options' argument.
1640 * monitor.c (monitor_wait): Likewise.
1641 * nto-procfs.c (procfs_wait): Likewise.
1642 * remote-mips.c (mips_wait): Add `options' argument.
1643 * remote-sim.c (gdbsim_wait): Likewise.
1644 * rs6000-nat.c (rs6000_wait): Add `options' argument.
1645 * sol-thread.c (sol_thread_wait): Add `options' argument, and pass
1646 it down to the layer beneath.
1647 * spu-linux-nat.c (spu_child_wait): Add `options' argument.
1648 * windows-nat.c (windows_wait): Likewise.
1649 * tui/tui-hooks.c (tui_target_wait_hook): Likewise. Adjust.
1651 2009-05-21 Pedro Alves <pedro@codesourcery.com>
1653 * mi/mi-interp.c (mi_on_resume): Account for whole process
1656 2009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
1658 * m2-exp.y (MAX_FUNC): Fix trailing UNOP_MAX.
1660 2009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
1662 * dwarf2read.c (set_cu_language): Recognize also DW_LANG_C99.
1664 2009-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
1666 Fix parsing DW_AT_const_value using DW_FORM_string.
1667 * dwarf2read.c (dwarf2_const_value <DW_FORM_string>): New.
1669 2009-05-20 Joel Brobecker <brobecker@adacore.com>
1671 * aix-thread.c (giter_count): Do not count the main thread.
1672 (giter_accum): Do not include the main thread.
1674 2009-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
1676 Remove the PROT parameter from openp.
1677 * source.c (openp): Remove the parameter PROT. Assertion check MODE.
1678 defs.h (openp): Update the prototype.
1679 Update all the openp callers.
1681 2009-05-19 Pedro Alves <pedro@codesourcery.com>
1683 * inflow.c (kill_command): Moved to infcmd.c.
1684 (_initialize_inflow): Don't add the "kill" command or clear
1686 * infcmd.c (kill_command): Moved here from inflow.c.
1687 (_initialize_infcmd): Add the "kill" command here.
1689 2009-05-19 Pedro Alves <pedro@codesourcery.com>
1691 * fork-child.c: Don't include frame.h. Include terminal.h.
1692 (fork_inferior): Call new_tty_postfork after forking adn adding
1693 the child to the inferior list.
1694 * inferior.h (new_tty_prefork, gdb_has_a_terminal): Don't declare
1696 * inflow.c (struct terminal_info): Remove const qualifier from
1697 `run_terminal' field.
1698 (inferior_thisrun_terminal): Tweak comment.
1699 (inflow_inferior_exit): Release the `run_terminal' field.
1700 (copy_terminal_info): New function.
1701 (new_tty_postfork): New function.
1702 * terminal.h (new_tty_prefork, new_tty, new_tty_postfork,
1703 (copy_terminal_info, gdb_has_a_terminal, gdb_setpgid): Declare.
1704 * inf-ptrace.c: Include terminal.h.
1705 (inf_ptrace_follow_fork): Copy the parent's terminal info to the
1707 * linux-nat.c: Include terminal.h.
1708 (linux_child_follow_fork): Copy the parent's terminal info to the
1710 * inf-ttrace.c: Include terminal.h.
1711 (inf_ttrace_follow_fork): Copy the parent's terminal info to the
1714 2009-05-19 Pedro Alves <pedro@codesourcery.com>
1716 * breakpoint.c (insert_breakpoints, breakpoint_init_inferior)
1717 (update_global_location_list): Use gdbarch_has_global_breakpoints
1718 instead of gdbarch_has_global_solist and
1719 target_supports_multi_process.
1720 * dicos-tdep.c (dicos_init_abi): Set
1721 gdbarch_has_global_breakpoints.
1722 * gdbarch.sh (has_global_solist): Update comment.
1723 (has_global_breakpoints): New.
1724 * remote.c (remote_start_remote): Use
1725 gdbarch_has_global_breakpoints instead of
1726 gdbarch_has_global_solist.
1727 * target.c (target_detach): Use gdbarch_has_global_breakpoints
1728 instead of gdbarch_has_global_solist.
1729 * infcmd.c (attach_command): Use gdbarch_has_global_solist instead
1730 of target_supports_multi_process.
1732 2009-05-18 Paul Pluzhnikov <ppluzhnikov@google.com>
1734 * objc-lang.c (find_methods): Plug a small memory leak.
1736 2009-05-18 Pedro Alves <pedro@codesourcery.com>
1738 * solib-svr4.c: Include observer.h.
1739 (debug_base, debug_loader_offset_p, debug_loader_offset)
1740 (debug_loader_name, main_lm_addr): Move these globals...
1741 (struct svr4_info): ... into this new structure.
1742 (svr4_info_p): New typedef.
1743 (svr4_info): New global.
1744 (get_svr4_info, remove_svr4_info, solib_svr4_inferior_exit): New
1746 (locate_base, solib_svr4_r_map, solib_svr4_r_brk)
1747 (solib_svr4_r_ldsomap): Add svr4_info argument. Adjust to
1749 (open_symbol_file_object): Adjust to per-inferior svr4.
1750 (svr4_default_sos, svr4_current_sos, svr4_fetch_objfile_link_map):
1752 (enable_break): Add svr4_info argument. Adjust to per-inferior
1754 (enable_break, svr4_solib_create_inferior_hook, svr4_clear_solib):
1755 Adjust to per-inferior svr4.
1756 (_initialize_svr4_solib): Install the solib_svr4_inferior_exit
1759 2009-05-18 Pedro Alves <pedro@codesourcery.com>
1761 * linux-nat.h (linux_proc_get_tgid): Declare.
1762 * linux-nat.c (linux_proc_get_tgid): New.
1763 * linux-thread-db.c (struct thread_db_info): New field
1764 `need_stale_parent_threads_check'.
1765 (add_thread_db_info): Set it.
1766 (find_new_threads_callback): Ignore stale fork parent threads.
1767 (thread_db_resume): New.
1768 (init_thread_db_ops): Install thread_db_resume.
1770 2009-05-18 Pedro Alves <pedro@codesourcery.com>
1772 * fork-child.c (fork_inferior): Only reset the thread list if this
1773 is the first inferior.
1774 (startup_inferior): If the target support multi-process, tell it
1775 to resume only the new process.
1776 * linux-nat.c (num_lwps): Delete global.
1777 (purge_lwp_list): New function.
1778 (num_lwps): New function.
1779 (add_lwp, delete_lwp): Adjust.
1781 (iterate_over_lwps): Add filter argument. Handle it.
1782 (linux_nat_attach): Remove FIXME note.
1783 (linux_nat_detach): Adjust to iterate over threads of the inferior
1784 we're detaching from. Adjust to num_lwps being a function. Don't
1785 assume the head of the lwp list is the main thread of the process
1786 we're detaching from. Don't destroy the LWP list.
1787 (resume_callback): Add debug output.
1788 (linux_nat_resume): Handle resuming a single inferior. Allow a
1789 wildcard resume in non-stop mode.
1790 (linux_handle_extended_wait): Don't assume inferior_ptid is the
1791 correct inferior of the parent LWP.
1792 (status_callback): Also check lp->waitstatus.
1793 (select_event_lwp): Add new filter parameter. Handle it.
1794 (linux_nat_filter_event): Adjust to num_lwps being a function.
1795 (linux_nat_wait_1): When adding the first lwp of the inferior, use
1796 an is_lwp check instead of checking for the number of lwps.
1797 (linux_nat_wait_1): Handle waiting for a specific tgid. Handle
1798 pending process exit statuses.
1799 (linux_nat_mourn_inferior): Don't destroy all the LWP info.
1800 Instead delete LWPs of the inferior that we're mourning. Don't
1801 unregister from the event loop here.
1802 (linux_nat_pid_to_str): Use `num_lwps'.
1803 (linux_nat_make_corefile_notes): Adjust to walk over lwps of a
1805 (linux_nat_is_async_p): Check if async was masked out.
1806 (linux_multi_process): New global.
1807 (linux_nat_supports_multi_process): New.
1808 (linux_nat_stop_lwp): Remove LWP filtering. It is done by the
1810 (linux_nat_stop): Adjust to make iterate_over_lwps itself do the
1812 (linux_nat_close): New.
1813 (linux_nat_add_target): Register linux_nat_close and
1814 linux_nat_supports_multi_process.
1815 * linux-nat.h (iterate_over_lwps): Add filter argument.
1816 * linux-thread-db.c (thread_db_handle): Delete.
1817 (proc_handle, thread_agent, td_init_p, td_ta_new_p)
1818 (td_ta_map_id2thr_p, td_ta_map_lwp2thr_p, td_ta_thr_iter_p)
1819 (td_ta_event_addr_p, td_ta_set_event_p, td_ta_event_getmsg_p)
1820 (td_thr_validate_p, td_thr_get_info_p, td_thr_event_enable_p)
1821 (td_thr_tls_get_addr_p, td_create_bp_addr, td_death_bp_addr): No
1822 longer globals, moved to...
1823 (struct thread_db_info): ... this new structure.
1824 (thread_db_list): New.
1825 (add_thread_db_info, get_thread_db_info, delete_thread_db_info):
1827 (have_threads_callback): Filter out threads of all inferiors but
1828 the one specified by the ARGS argument.
1829 (have_threads): Add ptid argument specifying the inferior we're
1830 interested in. Handle it.
1831 (struct thread_get_info_inout): New.
1832 (thread_get_info_callback, thread_from_lwp): Adjust to use it.
1833 (thread_db_attach_lwp): Check that inferior of the passed in
1834 thread is using thread-db. Adjust.
1835 (enable_thread_event): Remove thread_agent parameter. Instead,
1836 get it from the per-inferior thread-db info.
1837 (dladdr_to_soname): Move higher up.
1838 (enable_thread_event_reporting): Adjust to use per-inferior
1840 (try_thread_db_load_1): Replace `handle' parameter by a
1841 thread_db_info parameter. Adjust to use per-inferior thread-db
1843 (try_thread_db_load): Adjust to use per-inferior thread-db info.
1844 (thread_db_load, disable_thread_event_reporting): Ditto.
1845 (check_for_thread_db): Remove conditional reporting of which
1846 libthread_db is in use.
1847 (thread_db_new_objfile): Add comment about inferior_ptid.
1848 (attach_thread): Adjust to use per-inferior thread-db info.
1849 (thread_db_detach): Adjust to use per-inferior thread-db info.
1850 Remove thread event breakpoints of the current inferior. Only
1851 unpush the thread-db target if there are no more processes using
1853 (check_event): Adjust to use per-inferior thread-db info.
1854 (thread_db_wait): Adjust to use per-inferior thread-db info. Only
1855 unpush the thread-db target if there are no more processes using
1857 (thread_db_mourn_inferior): Adjust to use per-inferior thread-db
1858 info. Mark breakpoints of the current inferior out before
1859 deleting them. Only unpush the thread-db target if there are no
1860 more processes using it.
1861 (find_new_threads_callback): Adjust to use per-inferior thread_db
1863 (thread_db_find_new_threads_1): Add new ptid argument. Adjust to
1864 use per-inferior thread-db info.
1865 (thread_db_find_new_threads): Adjust to use per-inferior thread-db
1867 (thread_db_get_thread_local_address): Adjust.
1868 (thread_db_get_ada_task_ptid): Adjust.
1869 * inf-ptrace.c (inf_ptrace_mourn_inferior): Only unpush the target
1870 if there no more processes left to debug.
1871 * thread.c (set_running, set_executing): Handle resuming all
1872 threads of a single inferior.
1873 * mi/mi-interp.c (mi_output_running_pid): New.
1874 (mi_inferior_count): New.
1875 (mi_on_resume): For backwards compatibility, if resuming all
1876 threads of an inferior, and there is only one inferior, output
1879 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1881 * ada-lang.c (ada_find_any_type): Move check for primitive types ...
1882 (to_fixed_range_type): ... to here.
1884 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1886 * ada-lang.c (desc_data_type): Remove, replace by ...
1887 (desc_data_target_type): ... this.
1888 (thin_data_pntr): Use desc_data_target_type instead of desc_data_type.
1889 (ada_is_array_descriptor_type): Likewise.
1890 (ada_type_of_array): Likewise.
1891 (ada_coerce_to_simple_array_type): Likewise.
1892 (ada_array_element_type): Likewise.
1894 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1896 * ada-valprint.c (ada_val_print_1): Use val_print_string to print
1897 result of ada_vax_float_print_function inferior call.
1899 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1901 * ada-lang.c (ada_coerce_to_simple_array_type): Reimplement to
1902 avoid creating a dummy value.
1904 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1906 * p-valprint.c (pascal_val_print): Use extract_typed_address
1907 to extract reference value.
1909 2009-05-18 Ulrich Weigand <uweigand@de.ibm.com>
1911 * doublest.c (NAN): Remove unused define.
1912 (extract_floating_by_length, deprecated_extract_floating): Remove.
1913 (store_floating_by_length, deprecated_store_floating): Remove.
1914 (extract_typed_floating): Do not call extract_floating_by_length.
1915 (store_typed_floating): Do not call store_floating_by_length.
1916 (convert_typed_floating): Remove redundant assertions.
1917 * doublest.h (deprecated_extract_floating): Remove.
1918 (deprecated_store_floating): Remove.
1919 * sh64-tdep.c (sh64_register_convert_to_raw): Call
1920 extract_typed_floating instead of deprecated_extract_floating.
1922 2009-05-18 Jon Beniston <jon@beniston.com>
1924 * MAINTAINERS: Add lm32 target.
1925 * Makefile.in: Add lm32 dependencies.
1926 * NEWS: Indicate lm32 is a new target.
1927 * configure.tgt: Add lm32 targets.
1928 * lm32-tdep.c: New file.
1930 2009-05-18 Pedro Alves <pedro@codesourcery.com>
1932 * corelow.c (core_open): Flush the register cache before doing
1933 anything with registers.
1935 2009-05-18 Pedro Alves <pedro@codesourcery.com>
1937 * inflow.h (our_process_group): Remove declaration.
1938 (inferior_process_group): Delete global variable declaration.
1939 (inferior_process_group): New function declaration.
1940 * inflow.c: Include observer.h.
1941 (inferior_ttystate, our_ttystate, tflags_inferior, tflags_ours):
1943 (struct terminal_info): New struct.
1944 (our_terminal_info): New global.
1945 (inferior_process_group): New function.
1946 (inferior_thisrun_terminal): Extend description comment.
1947 (gdb_has_a_terminal): Adjust to write to our_terminal_info fields
1949 (terminal_init_inferior_with_pgrp): Adjust to per-inferior
1951 (terminal_inferior): Ditto.
1952 (terminal_ours_1): Ditto.
1953 (inflow_new_inferior, inflow_inferior_exit): New functions.
1954 (child_terminal_info): Adjust to per-inferior terminal settings.
1955 (osig_set): New global.
1956 (set_sigint_trap): Adjust to per-inferior terminal settings. Set
1957 or clear `osig_set' accordingly.
1958 (clear_sigint_trap): Check `osig_set' to decide wheater to restore
1959 SIGINT handler, instead of checking the current inferior (which
1961 (_initialize_inflow): Attach inflow_new_inferior and
1962 inflow_inferior_exit to the "new_inferior" and "inferior_exit"
1963 notifications, respectively.
1964 * inferior.h (struct terminal_info): Forward declare.
1965 (struct inferior): Add `terminal_info' field.
1966 * inferior.c (delete_inferior_1): Notify the inferior_exit
1967 observers before removing the inferior from the lists and deleting
1969 * inf-ptrace.c (inf_ptrace_stop): `inferior_process_group' is now
1970 a function instead of a variable. Adjust.
1971 * procfs.c (procfs_stop): Ditto.
1973 2009-05-17 Pedro Alves <pedro@codesourcery.com>
1975 * infrun.c (handle_inferior_event): When handling a
1976 TARGET_WAITKIND_FORKED, detach breakpoints from the fork child
1978 * linux-nat.c (linux_child_follow_fork): Only detach breakpoints
1979 from the child if vforking.
1980 * inf-ptrace.c (inf_ptrace_follow_fork): No need to detach
1981 breakpoints from the child here.
1983 2009-05-17 Pedro Alves <pedro@codesourcery.com>
1985 * infrun.c (pending_follow): Remove execd_pathname member.
1986 (resume): No longer handle TARGET_WAITKIND_EXECD pending follow.
1987 (handle_inferior_event): When handling a TARGET_WAITKIND_EXECD
1988 event, don't copy `execd_pathname' to pending_follow, use the
1989 event copy instead. Release `execd_pathname' once done with
1992 * infrun.c (pending_follow): Remove mention of exec events.
1994 2009-05-17 Hui Zhu <teawater@gmail.com>
1996 * i386-tdep.c (i386_process_record): Make it extern.
1997 (i386_gdbarch_init): Don't call set_gdbarch_process_record
1999 * i386-tdep.h (i386_process_record): Declare.
2000 * i386-linux-tdep.c (i386_linux_init_abi): Call
2001 set_gdbarch_process_record.
2003 2009-05-17 Vladimir Prus <vladimir@codesourcery.com>
2005 Always report varobj as changed when in_scope attribute changes.
2007 * varobj.c (install_new_value): If non-NULL-ness of value
2010 2009-05-15 Paul Pluzhnikov <ppluzhnikov@google.com>
2012 * NEWS: Mention set/show libthread-db-search-path.
2013 * gdb_thread_db.h (LIBTHREAD_DB_SEARCH_PATH): New define.
2014 (LIBTHREAD_DB_SO): Moved from linux-thread-db.c
2015 * linux-thread-db.c (libthread_db_search_path): New setting.
2016 (thread_db_handle): New variable (replaces using_thread_db).
2017 (try_thread_db_load_1): New function.
2018 (try_thread_db_load, thread_db_load_search): Likewise.
2019 (dladdr_to_soname): Likewise.
2020 (thread_db_load): Iterate over possibly multiple libthread_db's.
2021 (check_for_thread_db): Attempt to load new libthread_db.
2022 (thread_db_detach, thread_db_wait): Unload libthread_db.
2023 (thread_db_mourn_inferior): Likewise.
2024 (_initialize_thread_db): Add new libthread-db-search-path option.
2025 Defer loading of libthread_db to check_for_thread_db.
2026 * solib.c (libpthread_name_p): New function.
2027 (libpthread_solib_p): Call it.
2028 * solib.h (libpthread_name_p): New prototype.
2030 2009-05-15 Pierre Muller <muller@ics.u-strasbg.fr>
2032 * MAINTAINERS: Update my email address.
2034 2009-05-14 Paul Pluzhnikov <ppluzhnikov@google.com>
2036 * breakpoint.h: Add breakpoint_re_set_objfile prototype.
2037 * breakpoint.c (create_overlay_event_breakpoint): Renamed
2038 from create_overlay_event_breakpoint_1, old
2039 create_overlay_event_breakpoint deleted.
2040 (breakpoint_re_set_objfile): Don't rescan all objfiles
2042 (breakpoint_re_set): New function.
2043 * symfile.c (new_symfile_objfile): Call breakpoint_re_set_objfile
2044 instead of breakpoint_re_set.
2045 * objfiles.c (objfile_relocate): Likewise.
2047 2009-05-14 Joel Brobecker <brobecker@adacore.com>
2049 * gdbarch.sh: Add comment documenting the target_gdbarch global.
2050 gdbarch.h does NOT need to be regenerated as the corresponding
2051 change has already been made in a previous commit.
2053 2009-05-14 Pierre Muller <muller@ics.u-strasbg.fr>
2055 Remove all i386 debug register low level macros in config nm files.
2056 (I386_DR_LOW_SET_ADDR, I386_DR_LOW_RESET_ADDR): Remove.
2057 (I386_DR_LOW_GET_STATUS, I386_DR_LOW_SET_CONTROL): Remove.
2058 (I386_USE_GENERIC_WATCHPOIINTS): Remove.
2060 * i386-nat.h: New file (adapted from config/i386/nm-i386.h).
2061 (struct i386_dr_low_type): New type.
2062 (i386_dr_low): New global variable.
2063 * i386-nat.c (TARGET_HAS_DR_LEN_8): Update macro.
2064 (i386_insert_aligned_watchpoint): Replace i386 dr low macros by
2065 i386_dr_low struct variable fields.
2066 (i386_remove_aligned_watchpoint): Likewise.
2067 (i386_stopped_data_address): Likewise.
2068 (i386_stopped_by_hwbp): Likewise.
2069 (show_debug_regs_command_added): New static variable.
2070 (add_show_debug_regs_command): New static function.
2071 (i386_use_watchpoints): Call add_show_debug_regs_command if not done.
2072 (i386_set_debug_register_length): New function.
2073 (_initialize_i386_nat): Delete.
2075 * amd64-linux-nat.c: Include "i386-nat.h".
2076 (amd64_linux_dr_set_control): Change to static.
2077 (amd64_linux_dr_get_status): Change to static.
2078 (amd64_linux_dr_set_addr,amd64_linux_dr_reset_addr): Likewise.
2079 (_initialize_amd64_linux_nat): Set i386_dr_low variable fields.
2081 * go32-nat.c: Include "i386-nat.h".
2082 (go32_set_addr): Change to static.
2083 (go32_set_dr7): Change to static. Change arg type to unisgned long.
2084 (go32_get_dr6): Change to static. Change return type to unisnged long.
2085 (init_go32_ops): Set i386_dr_low variable fields.
2086 * i386-linux-nat.c: Include "i386-nat.h".
2087 (i386_linux_dr_set_control, i386_linux_dr_get_status): Change to static.
2088 (i386_linux_dr_set_addr, i386_linux_dr_reset_addr): Idem.
2089 (_initialize_i386_linux_nat): Set i386_dr_low variable fields.
2090 * i386bsd-nat.h: Declare functions used for
2091 i386_dr_low fields in i386fbsd-nat.c.
2092 * i386fbsd-nat.c: Include "i386-nat.h".
2093 (_initialize_i386fbsd_nat): Set i386_dr_low variable fields.
2094 * windows-nat.c: Include "i386-nat.h".
2095 (cygwin_set_dr, cygwin_get_dr6, cygwin_set_dr7): Add prototypes.
2097 (cygwin_get_dr6): Change return type to unisnged long.
2098 (cygwin_set_dr7): Change arg type to unisgned long.
2099 (init_windows_ops): Set i386_dr_low function fields.
2101 * amd64-windows-nat.c (_initialize_amd64_windows_nat): Call
2102 i386_set_debug_register_length.
2103 * i386-windows-nat.c (_initialize_i386_windows_nat): Likewise.
2105 * config/i386/nm-cygwin.h: Remove all I386_* macros.
2106 * config/i386/nm-cygwin64.h: Likewise.
2107 * config/i386/nm-fbsd.h: Likewise.
2108 * config/i386/nm-linux.h: Likewise.
2109 * config/i386/nm-i386.h: Remove completely.
2110 * config/i386/nm-go32.h: Remove completely.
2111 * config/i386/nm-linux64.h: Remove completely.
2112 * config/i386/go32.mh (NAT_FILE): Remove entry.
2113 * config/i386/linux64.h (NAT_FILE): Change to config/nm-linux.h.
2115 2009-05-14 Jon Beniston <jon@beniston.com>
2117 * MAINTAINERS: Add Jon Beniston to write after approval list.
2119 2009-05-13 Paul Pluzhnikov <ppluzhnikov@google.com>
2121 * objc-lang.c (objc_objfile_data): New variable.
2122 (find_methods): Skip objfiles without Obj-C methods.
2123 (_initialize_objc_lang): New function.
2125 2009-05-13 Joel Brobecker <brobecker@adacore.com>
2127 * c-lang.c (print_wchar): Remove unnecessary cast.
2129 2009-05-12 Jim Blandy <jimb@red-bean.com>
2131 * MAINTAINERS: Remove self as m32c target maintainer.
2133 2009-05-12 Pedro Alves <pedro@codesourcery.com>
2135 * cli/cli-decode.c (deprecated_add_set_cmd): Delete.
2136 * command.h (deprecated_add_set_cmd): Delete declaration.
2137 * gnu-nat.c (_initialize_gnu_nat): Replace 'maint gnu-debug' with
2138 'set debug gnu-nat' and 'show debug gnu-nat'.
2139 * i386-nat.c (_initialize_i386_nat): Replace 'maint
2140 show-debug-registers' with 'maint set show-debug-registers' and
2141 'maint show show-debug-registers'.
2142 * mips-linux-nat.c (_initialize_mips_linux_nat): Replace 'maint
2143 show-debug-registers' with 'maint set show-debug-registers' and
2144 'maint show show-debug-registers'.
2146 2009-05-12 Joel Brobecker <brobecker@adacore.com>
2148 * c-lang.c (print_wchar): Convert w into a gdb_wchar_t before
2149 pushing it on the output obstack.
2151 2009-05-11 Joel Brobecker <brobecker@adacore.com>
2153 Fix internal error on breaking at a multi-locations caller source line.
2154 * breakpoint.c (parse_breakpoint_sals): Set EXPLICIT_PC for the `break'
2155 command with no parameters.
2157 2009-05-11 Pedro Alves <pedro@codesourcery.com>
2159 * linux-nat.c (enum sigchld_state): Delete.
2160 (linux_nat_async_events_state): Delete.
2161 (struct waitpid_result): Delete.
2162 (waitpid_queue): Delete.
2163 (queued_waitpid_1): Delete.
2164 (async_file_flush): New.
2165 (queued_waitpid, push_waitpid): Delete.
2166 (async_file_mark): New.
2167 (drain_queued_events): Delete.
2168 (my_waitpid): Remove locally queued events handling.
2169 (linux_test_for_tracefork): Upjust.
2170 (linux_child_follow_fork): Ditto.
2171 (sync_sigchld_action): Delete.
2172 (blocked_mask): Reinstate.
2173 (async_sigchld_action): Rename to...
2174 (sigchld_action): ... this.
2175 (block_child_signals): New.
2176 (restore_child_signals_mask): New.
2177 (lin_lwp_attach_lwp): Adjust.
2178 (linux_nat_create_inferior): Ditto.
2179 (linux_nat_attach): Also use lp->status in async mode.
2180 (get_pending_status): Don't use queued_waitpid.
2181 (linux_nat_detach): Don't drain locally queued events.
2182 (linux_nat_resume): Allow pending wait statuses stored lp->status
2183 in async mode. If returning early due to a pending event,
2184 re-register the event source.
2185 (stop_wait_callback): Allow pending wait statuses stored
2186 lp->status in async mode.
2187 (pipe_to_local_event_queue, local_event_queue_to_pipe): Delete.
2188 (linux_nat_wait): Rename to ...
2189 (linux_nat_wait_1): ... this. Allow pending wait statuses stored
2190 lp->status in async mode. Always add WNOHANG to the waitpid
2191 options in async mode.
2192 (linux_nat_wait): New.
2193 (kill_callback): Don't drain locally queued events.
2194 (sigchld_handler): Rewrite.
2195 (linux_nat_is_async_p, linux_nat_can_async_p): Fix comments to
2196 refer to "set target-async".
2197 (linux_nat_async_mask): If in non-stop, and re-enabling async
2198 mode, re-register the target event source in the event loop.
2199 (linux_nat_event_pipe_pop, linux_nat_event_pipe_push)
2200 (get_pending_events, async_sigchld_handler)
2201 (linux_nat_async_events): Delete.
2202 (handle_target_event): New.
2203 (linux_nat_async_file_handler): Delete.
2204 (linux_async_pipe): New.
2205 (linux_nat_async): Only re-register in the event loop if not
2206 registered yet. Always notify the event-loop once if enabling the
2208 (linux_nat_stop_lwp): Rewrite to handle pending events stored in
2209 lp->status, not in the locally queued event list.
2210 (linux_nat_stop): Don't mask out async event handling.
2211 (linux_nat_setup_async): Delete.
2212 (_initialize_linux_nat): Adjust.
2213 (lin_thread_get_thread_signals): blocked_mask is global again.
2216 2009-05-11 Pierre Muller <muller@ics.u-strasbg.fr>
2218 Unify target macros.
2220 * target.h (STOPPED_BY_WATCHPOINT): Delete, replaced by ...
2221 (target_stoppped_by_watchpoint): New macro.
2222 (HAVE_STEPPABLE_WATCHPOINT): Delete, replaced by ...
2223 (target_have_steppable_watchpoint): New macro.
2224 (HAVE_CONTINUABLE_WATCHPOINT): Delete, replace by ...
2225 (target_have_continuable_watchpoint): New macro.
2226 (TARGET_CAN_USE_HARDWARE_WATCHPOINT):Delete, replaced by ...
2227 (target_can_use_hardware_watchpoint): New macro.
2228 (TARGET_REGION_OK_FOR_HW_WATCHPOINT):Delete, replaced by ...
2229 (target_region_ok_for_hw_watchpoint): New macro.
2231 * breakpoint.c (update_watchpoint): Use new macros.
2232 (bpstat_alloc): Likewise.
2233 (create_breakpoint): Likewise.
2234 (watch_command_1): Likewise.
2235 (can_use_hardware_watchpoint): Likewise.
2236 (do_enable_breakpoint): Likewise.
2237 * infrun.c (handle_inferior_event): Adapt to new macros.
2238 * mips-tdep.c (mips_gdbarch_init): Update comments.
2239 * procfs.c (procfs_set_watchpoint): Update comment.
2240 (procfs_insert_watchpoint): Adapt to new macros.
2241 * remote-m32r-sdi.c (m32r_stop):
2242 * remote-mips.c (mips_remove_breakpoint):
2243 * target.c (debug_to_region_ok_for_hw_watchpoint): Update to new macros.
2244 (debug_to_stopped_by_watchpoint): Likewise.
2247 2009-05-10 Pierre Muller <muller@ics.u-strasbg.fr>
2249 * src/gdb/target.h: Remove all tests for already defined
2250 macros. All macros defined here should not be set in config
2253 2009-05-08 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
2255 * ppc-linux-nat.c (have_ptrace_getsetregs): New variable.
2256 (have_ptrace_getsetfpregs): Likewise.
2257 fetch_all_gp_regs): New function.
2258 (fetch_gp_regs): New function.
2259 (fetch_all_fp_regs): Likewise.
2260 (fetch_fp_regs): New function.
2261 (fetch_ppc_registers): Using the new methods to fetch general-
2262 purpose and floating-pointer registers.
2263 (store_all_gp_regs): New function.
2264 (store_gp_regs): Likewise.
2265 (store_all_fp_regs): New function.
2266 (store_fp_regs): Likewise.
2267 (store_ppc_registers): Using the new methods to store general-
2268 purpose and floating-pointer registers.
2270 2009-05-08 Doug Evans <dje@google.com>
2272 * linux-nat.c (linux_xfer_siginfo): Delete unused locals lp, n.
2274 2009-05-07 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
2276 * MAINTAINERS (Write After Approval): Add self.
2278 2009-05-07 Joel Brobecker <brobecker@adacore.com>
2280 * gdbarch.h (target_gdbarch): Add comment documenting this global.
2282 2009-05-06 Joel Brobecker <brobecker@adacore.com>
2284 * acinclude.m4 (AM_ICONV): Prefer in-tree libiconv if present over
2286 * configure: Regenerate.
2288 2009-05-06 Joel Brobecker <brobecker@adacore.com>
2290 * utils.c: Add include of gdb_usleep.h.
2291 (defaulted_query): Detect false EOF conditions that happen
2292 on terminals opened with the O_NONBLOCK flag when there is
2295 2009-05-06 Pedro Alves <pedro@codesourcery.com>
2297 * inferior.c (add_inferior): Move observer_notify_new_inferior
2299 (add_inferior_silent): ... here.
2301 2009-05-06 Pierre Muller <muller@ics.u-strasbg.fr>
2302 Pedro Alves <pedro@codesourcery.com>
2304 * procfs.c (procfs_insert_watchpoint, procfs_remove_watchpoint)
2305 (procfs_region_ok_for_hw_watchpoint, procfs_use_watchpoints): New
2307 (procfs_stopped_by_watchpoint): Made static, ptid argument
2309 (_initialize_procfs): Register new watchpoint related target
2311 * config/i386/nm-i386sol2.h (TARGET_CAN_USE_HARDWARE_WATCHPOINT)
2312 (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT, STOPPED_BY_WATCHPOINT)
2313 (HAVE_CONTINUABLE_WATCHPOINT): Delete.
2314 (target_insert_watchpoint, target_remove_watchpoint): Delete.
2315 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
2317 * config/mips/nm-irix5.h (STOPPED_BY_WATCHPOINT)
2318 (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT): Delete.
2319 (target_insert_watchpoint, target_remove_watchpoint): Delete.
2320 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
2322 * config/sparc/nm-sol2.h (TARGET_REGION_SIZE_OK_FOR_HW_WATCHPOINT)
2323 (HAVE_CONTINUABLE_WATCHPOINT, STOPPED_BY_WATCHPOINT): Delete.
2324 (target_insert_watchpoint, target_remove_watchpoint): Delete.
2325 (procfs_stopped_by_watchpoint, procfs_set_watchpoint): Delete
2328 2009-05-06 Hui Zhu <teawater@gmail.com>
2330 * i386-tdep.c (i386_process_record): Change bzero to memset.
2332 2009-05-06 Hui Zhu <teawater@gmail.com>
2334 * NEWS: Add item for process record and replay.
2336 2009-05-05 Maxim Grigoriev <maxim2405@gmail.com>
2338 * xtensa-tdep.c (xtensa_frame_cache): Use pc instead of cache->pc.
2340 2009-05-05 Ulrich Weigand <uweigand@de.ibm.com>
2342 * inferior.h (read_pc, write_pc): Remove.
2343 * regcache.c (read_pc, write_pc): Remove.
2345 * infrun.c (displaced_step_fixup): Use regcache_read_pc instead
2347 (handle_inferior_event): Use regcache_read_pc instead of read_pc
2348 when determining value of stop_pc. Replace subsequent uses of
2349 read_pc by inspecting already-retrieved stop_pc value.
2350 (keep_going): Use regcache_read_pc instead of read_pc.
2352 * breakpoint.c (watchpoint_check): Use current frame architecture
2353 and PC instead of current_gdbarch and read_pc ().
2354 * tracepoint.c (set_traceframe_context): Replace PC argument
2355 with FRAME argument.
2356 (trace_start_command, finish_tfind_command): Update calls.
2357 (finish_tfind_command): Compare frame IDs to identify transitions
2359 (trace_find_pc_command): Use regcache_read_pc instead of read_pc.
2360 * rs6000-nat.c (exec_one_dummy_insn): Pass in regcache instead
2361 of gdbarch. Use regcache_read_pc and regcache_write_pc instead
2362 of read_pc and write_pc.
2363 (store_register): Make regcache argument non-const. Update call
2364 to exec_one_dummy_insn.
2366 * thread.c (switch_to_thread): Use regcache_read_pc instead of read_pc.
2367 * infcmd.c (post_create_inferior): Likewise.
2368 * solib-darwin.c (darwin_solib_create_inferior_hook): Likewise.
2369 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
2370 * solib-sunos.c (sunos_solib_create_inferior_hook): Likewise.
2371 * solib-svr4.c (enable_break, svr4_relocate_main_executable): Likewise.
2372 * linux-fork.c (fork_load_infrun_state): Likewise.
2373 * hppa-hpux-tdep.c (hppa_hpux_push_dummy_code): Likewise.
2374 * record.c (record_wait): Likewise.
2375 * procfs.c (procfs_wait): Likewise.
2376 * remote-mips.c (common_open, mips_wait): Likewise.
2377 * remote-m32r-sdi.c (m32r_resume): Likewise.
2379 * symfile.c (generic_load): Use regcache_write_pc instead of write_pc.
2380 * monitor.c (monitor_create_inferior, monitor_load): Likewise.
2381 * m32r-rom.c (m32r_load, m32r_upload_command): Likewise.
2382 * remote-m32r-sdi.c (m32r_create_inferior, m32r_load): Likewise.
2383 * remote-mips.c (mips_create_inferior, mips_load): Likewise.
2385 * solib-darwin.c: Include "regcache.h".
2386 * solib-pa64.c: Include "regcache.h".
2387 * solib-svr4.c: Include "regcache.h.".
2389 * symfile.c: Do not mention read_pc or write_pc in comments.
2390 * dink32-rom.c: Likewise.
2391 * m32r-rom.c: Likewise.
2392 * mips-tdep.c: Likewise.
2394 2009-05-05 Ulrich Weigand <uweigand@de.ibm.com>
2396 * fork-child.c (startup_inferior): Move setting stop_pc ...
2397 * infcmd.c (post_create_inferior): ... to here.
2399 2009-05-04 Michael Snyder <msnyder@vmware.com>
2401 * NEWS: Add item for reverse debugging commands.
2403 2009-05-04 Pedro Alves <pedro@codesourcery.com>
2405 * go32-nat.c (go32_stop): Delete.
2406 (go32_kill_inferior): Rewrite to only call go32_mourn_inferior.
2407 (go32_create_inferior): Don't call go32_stop or
2409 (go32_mourn_inferior): Inline go32_stop and go32_kill_inferior
2411 (init_go32_ops): Don't register go32_stop.
2413 2009-05-02 Eli Zaretskii <eliz@gnu.org>
2415 * dbxread.c (read_dbx_symtab): Avoid compiler warnings for
2418 * infcall.c (find_function_addr): Avoid compiler warnings for
2421 2009-05-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2423 * dictionary.c (dict_hashed_vector, dict_hashed_expandable_vector)
2424 (dict_linear_vector, dict_linear_expandable_vector): Fix a comment typo.
2426 2009-05-01 Doug Evans <dje@google.com>
2428 * linux-thread-db.c (thread_db_pid_to_str): Delete unused assignment
2431 2009-05-01 Eli Zaretskii <eliz@gnu.org>
2433 * record.c (_initialize_record): Reformat and clarify doc strings
2434 for stop-at-limit and insn-number-max.
2436 * go32-nat.c: Add comments about dirty secrets of DJGPP debugging.
2438 2009-05-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2440 Make specifiable the make_function_type type memory ownership.
2441 * gdbtypes.c (make_function_type): New parameter `objfile', use it
2442 explicitely instead of TYPE-initialized removed local variable
2443 `objfile'. Describe `objfile' it in the function comment.
2444 (lookup_function_type): Update make_function_type callers.
2445 * gdbtypes.h (make_function_type): Update the prototype.
2446 * jv-lang.c (java_link_class_type): Update make_function_type callers.
2447 * dwarf2read.c (read_subroutine_type): Likewise.
2448 * stabsread.c (read_type): Likewise.
2450 2009-05-01 Eli Zaretskii <eliz@gnu.org>
2452 * go32-nat.c (go32_pid_to_str): Call normal_pid_to_str instead of
2453 printing a bogus "Thread <main>".
2454 (go32_thread_alive): Don't return 1 for null_ptid.
2456 * i386-tdep.c (i386_go32_init_abi): Override the number of
2457 registers due to non-support of SSE.
2459 2009-04-30 Anthony Green <green@moxielogic.com>
2461 * configure.tgt: Link the moxie simulator in with gdb.
2463 2009-04-30 Paul Pluzhnikov <ppluzhnikov@google.com>
2465 * elfread.c (elf_symtab_read): Don't assume .data and .rodata
2468 2009-04-30 Hui Zhu <teawater@gmail.com>
2469 Michael Snyder <msnyder@vmware.com>
2471 I386 Linux process record and replay support.
2473 * i386-linux-tdep.c (i386_linux_record_tdep): New variable.
2474 This struct has the argument for the function
2475 "record_linux_system_call".
2476 (i386_linux_intx80_sysenter_record): New function. Parse the
2477 system call instruction and call function
2478 "record_linux_system_call" to record execute log.
2479 (i386_linux_init_abi): Initialize "i386_linux_record_tdep".
2480 Set "i386_linux_intx80_sysenter_record" to
2481 "i386_intx80_record" and "i386_sysenter_record".
2483 2009-04-30 Hui Zhu <teawater@gmail.com>
2484 Michael Snyder <msnyder@vmware.com>
2486 I386 architecture process record and replay support.
2488 * i386-tdep.c (PREFIX_REPZ, PREFIX_REPNZ, PREFIX_LOCK,
2489 PREFIX_DATA, PREFIX_ADDR): New macros. Help decode the i386
2491 (aflag, dflag, override, modrm, mod, reg, rm, ot,
2492 i386_record_pc): New variables. Ditto.
2493 (i386_record_modrm, i386_record_lea_modrm_addr,
2494 i386_record_lea_modrm): New functions. Ditto.
2495 (i386_process_record): New function. Parse the instruction in
2496 address "addr" and record the values of registers and memory
2497 that will be changed by this instruction.
2498 (i386_gdbarch_init): Set "i386_process_record" to GDBARCH
2499 "process_record" interface.
2500 * i386-tdep.h (gdbarch_tdep): New function pointers
2501 "i386_intx80_record" and "i386_sysenter_record" that point to
2502 the function that can record "intx80" and "sysenter" execute
2505 2009-04-30 Hui Zhu <teawater@gmail.com>
2506 Michael Snyder <msnyder@vmware.com>
2508 * infrun.c (use_displaced_stepping): Return false if process
2509 record and replay target is used.
2510 (proceed): Call function "record_not_record_set" if pocess
2511 record and replay target is used.
2513 2009-04-30 Hui Zhu <teawater@gmail.com>
2514 Michael Snyder <msnyder@vmware.com>
2516 Linux process record and replay support.
2518 * Makefile.in (ALLDEPFILES): Add linux-record.c.
2519 (ALL_TARGET_OBS): Add linux-record.o.
2520 * configure.tgt (x86_64-*-linux*): Add linux-record.o.
2521 (i[34567]86-*-linux*): Add linux-record.o.
2522 * linux-record.c, linux-record.h: New file.
2524 2009-04-30 Hui Zhu <teawater@gmail.com>
2525 Michael Snyder <msnyder@vmware.com>
2527 Process record and replay target.
2529 * Makefile.in (SFILES): Add record.c.
2530 (COMMON_OBS): Add record.o.
2531 * record.c, record.h: New file.
2533 2009-04-30 Hui Zhu <teawater@gmail.com>
2534 Michael Snyder <msnyder@vmware.com>
2536 * target.h (strata): New stratum "record_stratum".
2538 2009-04-30 Hui Zhu <teawater@gmail.com>
2539 Michael Snyder <msnyder@vmware.com>
2541 GDBARCH interface for process record and replay.
2543 * gdbarch.sh (process_record): This interface point to the
2544 function that records the inferior execute log.
2546 2009-04-29 Doug Evans <dje@google.com>
2548 * i386-nat.c (child_post_startup_inferior): Delete, unused.
2550 2009-04-29 Pedro Alves <pedro@codesourcery.com>
2552 * breakpoint.c (print_exception_catchpoint): Access `b' directly
2553 instead of `b->loc->owner'.
2554 (print_mention_exception_catchpoint): Ditto.
2556 2009-04-29 Jan Kratochvil <jan.kratochvil@redhat.com>
2558 * macrocmd.c (info_macro_command): Print -Dname=value if LINE is zero.
2560 2009-04-27 Tom Tromey <tromey@redhat.com>
2562 * c-exp.y (yylex): Handle '[' and ']' like '(' and ')'.
2564 2009-04-27 Jerome Guitton <guitton@adacore.com>
2566 * symtab.c (append_exact_match_to_sals): New function, extracted
2567 from expand_line_sal.
2568 (expand_line_sal): Use append_exact_match_to_sals to append exact
2569 matches. If none found, append all best items.
2571 2009-04-27 Jerome Guitton <guitton@adacore.com>
2573 * main.c (captured_main): Move gdbinit lookups after gdb_init.
2575 2009-04-27 Jan Kratochvil <jan.kratochvil@redhat.com>
2578 * dwarf2read.c (unsigned_int_compar, inherit_abstract_dies): New.
2579 (read_func_scope): Call inherit_abstract_dies.
2581 2009-04-25 Eli Zaretskii <eliz@gnu.org>
2583 * Makefile.in (ALLDEPFILES): Remove duplicate entries for
2584 sparc-sol2-nat.c and sparc-sol2-tdep.c.
2586 * stack.c (_initialize_stack) <disassemble-next-line>: Doc fix.
2588 2009-04-24 Pierre Muller <muller@ics.u-strasbg.fr>
2590 ARI change: Use "/* ARI: rule */" pattern.
2591 * utils.c: Update ARI patterns.
2592 * gdb_dirent.h: Likewise.
2594 2009-04-23 Anthony Green <green@moxielogic.com>
2596 * MAINTAINERS: Add moxie target.
2597 * configure.tgt: Add moxie-*-elf target.
2598 * moxie-tdep.c: New file.
2599 * moxie-tdep.h: New file.
2601 2009-04-23 Joel Brobecker <brobecker@adacore.com>
2603 * ada-lang.c: Remove an extra empty line. No code change.
2605 2009-04-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2607 Fix double free on error inserting the breakpoint instruction.
2608 * breakpoint.c (create_breakpoints): Move the
2609 update_global_location_list call to ...
2610 (break_command_really): ... here together with the second local call
2611 both unified after all the cleanups.
2613 2009-04-23 Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
2614 Tom Tromey <tromey@redhat.com>
2616 * configure, config.in: Regenerate.
2617 * configure.ac: Support for relocatable GDB datadir. Use
2618 GDB_AC_WITH_DIR. Always define TARGET_SYSTEM_ROOT_RELOCATABLE.
2619 * acinclude.m4 (GDB_AC_WITH_DIR): New defun.
2620 * top.c (init_main): Add "set data-directory".
2621 * defs.h (gdb_datadir): Declare.
2622 * main.c (gdb_datadir): New global.
2623 (captured_main): Initialize gdb_datadir. Use relocate_directory.
2624 (relocate_path): New function.
2625 (relocate_directory): Likewise.
2626 (get_init_files): Use relocate_path.
2627 (README): Mention --with-gdb-datadir.
2629 2009-04-23 Joel Brobecker <brobecker@adacore.com>
2631 * ada-tasks (task_command_1): Call target_find_new_threads.
2633 2009-04-23 Joel Brobecker <brobecker@adacore.com>
2635 * stack.c (do_gdb_disassembly): Print the exception message if an
2636 error was thrown while trying to perform the disassembly.
2638 2009-04-22 Jan Kratochvil <jan.kratochvil@redhat.com>
2640 * varobj.c (free_variable): Replace free_current_contents by xfree.
2642 2009-04-22 Kazu Hirata <kazu@codesourcery.com>
2644 * arm-linux-nat.c (fetch_register, store_register): Use
2645 ARM_CPSR_GREGNUM instead of ARM_CPSR_REGNUM.
2646 * arm-linux-tdep.c (arm_linux_supply_gregset,
2647 arm_linux_collect_gregset): Likewise.
2648 * arm-linux-tdep.h (ARM_CPSR_GREGNUM): New.
2649 * arm-tdep.h (ARM_CPSR_REGNUM): Remove.
2651 2009-04-22 Hui Zhu <teawater@gmail.com>
2653 * stack.c (_initialize_stack): Set the default of
2654 disassemble-next-line to off.
2656 2009-04-21 Tom Tromey <tromey@redhat.com>
2658 * acinclude.m4: Use AS_HELP_STRING, not AC_HELP_STRING.
2659 * configure.ac: Use AS_HELP_STRING, not AC_HELP_STRING.
2661 2009-04-21 Andreas Schwab <schwab@linux-m68k.org>
2663 * configure.ac: Add quotes to not lose brackets in help text.
2664 * configure: Rebuild.
2666 2009-04-21 Andreas Schwab <schwab@linux-m68k.org>
2668 * configure.ac: Don't postprocess Makefile in config.status.
2669 Substitute GDB_NM_FILE. Don't substitute nm_h.
2670 * Makefile.in (GDB_NM_FILE): Substitute.
2671 (TAGS): Use $(GDB_NM_FILE) instead of $(NAT_FILE).
2672 * configure: Regenerate.
2673 * gnulib/Makefile.in: Regenerate.
2675 2009-04-21 Joseph Myers <joseph@codesourcery.com>
2677 * configure.ac (--with-datarootdir, --with-docdir, --with-pdfdir,
2678 --with-htmldir): New.
2679 * configure: Regenerate.
2681 2009-04-21 Tom Tromey <tromey@redhat.com>
2683 * configure: Rebuild.
2684 * configure.ac: Use lower case for start of help strings. Clean
2685 up --with-sysroot help.
2687 2009-04-21 Tom Tromey <tromey@redhat.com>
2689 * configure: Rebuild.
2690 * acinclude.m4 (AM_ICONV): Use AC_HELP_STRING.
2691 * configure.ac: Use AC_HELP_STRING. Use upper case for variables
2694 2009-04-21 Pierre Muller <muller@ics.u-strasbg.fr>
2696 ARI fix: remove "%p".
2697 * ia64-tdep.c (ia64_frame_this_id): Use host_address_to_string function.
2698 (ia64_sigtramp_frame_this_id): Ditto.
2699 (ia64_libunwind_frame_this_id): Ditto.
2700 (ia64_libunwind_sigtramp_frame_this_id): Ditto.
2701 * symmisc.c (maintenance_info_psymtabs): Ditto.
2703 2009-04-21 Joseph Myers <joseph@codesourcery.com>
2705 * configure.ac (--with-relocated-sources): New.
2706 * configure, config.in: Regenerate.
2707 * source.c (add_substitute_path_rule): Remove static.
2708 * source.h (add_substitute_path_rule): Declare.
2709 * main.c: Include "source.h".
2710 (captured_main): Add substitution rule if RELOC_SRCDIR.
2712 2009-04-21 Pierre Muller <muller@ics.u-strasbg.fr>
2714 * gnu-nat.h (proc_debug): Add missing continuation line in macro.
2716 2009-04-20 David Daney <ddaney@caviumnetworks.com>
2718 * NEWS: Mention MIPS/Linux hardware watchpoint support.
2720 2009-04-20 David Daney <ddaney@caviumnetworks.com>
2722 * mips-linux-nat.c (command.h, gdbcmd.h, gdb_assert.h): New #includes.
2723 (maint_show_dr, super_close): New variables.
2724 (super_fetch_registers, super_store_registers): Make static.
2725 (PTRACE_GET_WATCH_REGS, PTRACE_SET_WATCH_REGS, W_BIT, R_BIT, I_BIT)
2726 (W_MASK, R_MASK, I_MASK, IRW_MASK, MAX_DEBUG_REGISTER): Define.
2727 (pt_watch_style): Define new enum.
2728 (mips32_watch_regs, mips64_watch_regs, pt_watch_regs, mips_watchpoint):
2730 (watch_readback_valid, watch_readback, current_watches, watch_mirror):
2732 (get_irw_mask, get_reg_mask, get_num_valid, get_watchlo)
2733 (set_watchlo, get_watchhi, set_watchhi, mips_show_dr)
2734 (mips_linux_read_watch_registers, mips_linux_can_use_hw_breakpoint)
2735 (mips_linux_stopped_by_watchpoint, mips_linux_stopped_data_address)
2736 (type_to_irw, fill_mask, try_one_watch)
2737 (mips_linux_region_ok_for_hw_watchpoint, write_watchpoint_regs)
2738 (mips_linux_new_thread, populate_regs_from_watches)
2739 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
2740 (mips_linux_close): New functions.
2741 (_initialize_mips_linux_nat): Register watchpoint functions with
2742 the target_ops. Add show-debug-regs maintenance command.
2744 2009-04-20 David Daney <ddaney@caviumnetworks.com>
2746 * infrun.c (handle_inferior_event): Move gegisters_changed call down.
2748 2009-04-19 Pedro Alves <pedro@codesourcery.com>
2750 * NEWS: Mention gdbserver support for x86 Windows CE.
2752 2009-04-19 Eli Zaretskii <eliz@gnu.org>
2754 * config/djgpp/fnchange.lst: Fix typos.
2756 Set default host and target charsets in the DJGPP port.
2758 * config/djgpp/config.sed (am_cv_langinfo_codeset)
2759 (bash_cv_langinfo_codeset, ac_cv_header_nl_types_h): Set to "yes"
2760 in all configure scripts that define ac_cv_env_CPP_value.
2762 * go32-nat.c (dos_codepage, nl_langinfo): New functions.
2765 * config/djgpp/nl_types.h: New file.
2767 * config/djgpp/langinfo.h: New file.
2769 * config/i386/go32.mh (MH_CFLAGS): Add $(srcdir)/config/djgpp.
2771 2009-04-18 Carlos O'Donell <carlos@codesourcery.com>
2773 * Makefile.in (MAKEHTML): Set to makeinfo --html.
2774 (MAKEHTMLFLAGS): Set to empty.
2776 2009-04-18 Eli Zaretskii <eliz@gnu.org>
2778 * NEWS: Mention all new set/show commands added since GDB 6.8 was
2781 * go32-nat.c (go32_sysinfo): Check if the call to
2782 __dpmi_get_capabilities fills the buffer with information, and
2783 don't use the buffer if not.
2785 2009-04-17 Tom Tromey <tromey@redhat.com>
2787 * charset.c (_initialize_charset): Add special case for "646".
2789 2009-04-17 Carlos O'Donell <carlos@codesourcery.com>
2791 * configure.ac: AC_SUBST datarootdir, docdir, htmldir, pdfdir.
2792 * configure: Regenerate.
2793 * Makefile.in: Set datarootdir, docdir, htmldir, and pdfdir from
2794 configure substitutions.
2795 (FLAGS_TO_PASS): Add datarootdir, docdir, and htmldir.
2797 2009-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
2799 ARI fix: Do not use %p, replace by call to host_address_to_string
2801 * darwin-nat.c (darwin_xfer_partial): Apply change.
2802 * gnu-nat.c (inf_continue, gnu_xfer_memory): Ditto.
2803 * gnu-nat.h (proc_debug): Ditto.
2804 * symmisc.c (maintenance_info_symtabs): Ditto.
2805 (maintenance_info_psymtabs): Ditto.
2806 * windows-nat.c (handle_load_dll): Ditto.
2807 (handle_unload_dll, info_w32_command, handle_exception): Ditto.
2808 * xtensa-tdep.c (xtensa_unwind_pc): Ditto.
2810 2009-04-17 Joseph Myers <joseph@codesourcery.com>
2812 * configure.tgt (i[34567]86-*-linux*): Use 64-bit configuration if
2813 --enable-64-bit-bfd.
2814 (sparc-*-linux*): Likewise.
2816 2009-04-17 Eli Zaretskii <eliz@gnu.org>
2818 * go32-nat.c (go32_sysinfo): Update list of Windows versions of
2821 2009-04-16 Pedro Alves <pedro@codesourcery.com>
2823 * remote.c (remote_query_attached): Fix pasto in packet_ok result
2826 2009-04-16 Joel Brobecker <brobecker@adacore.com>
2828 * procfs.c (solib_mappings_callback, find_memory_regions_callback):
2829 Revert the previous change. Might not be correct, actually.
2831 2009-04-16 Joel Brobecker <brobecker@adacore.com>
2833 * ada-lang.h (ada_adjust_exception_stop, ada_print_exception_stop)
2834 (ada_get_current_task, ada_print_exception_breakpoint_nontask)
2835 (ada_print_exception_breakpoint_task, ada_reset_thread_registers):
2836 Remove declaration. These are non-existent functions.
2838 2009-04-16 Joel Brobecker <brobecker@adacore.com>
2840 * procfs.c (solib_mappings_callback, find_memory_regions_callback):
2841 Fix a compilation warning on mips-irix due to casting from
2842 a pointer of different size.
2844 2009-04-16 Joel Brobecker <brobecker@adacore.com>
2846 * ada-lang.c (symtab_for_sym): Delete.
2847 (user_select_syms): Use sym->symtab instead of calling symtab_for_sym.
2849 2009-04-16 Joel Brobecker <brobecker@adacore.com>
2851 * ada-lang.c (extract_string): Delete.
2852 (ada_main_name): Reimplement using target_read_string instead of
2855 2009-04-16 Andreas Schwab <schwab@linux-m68k.org>
2857 * m68klinux-nat.c: Remove obsolete comment.
2858 (fetch_register, store_register): Don't call
2859 gdbarch_cannot_fetch_register or gdbarch_cannot_store_register,
2860 which are always nops here.
2862 2009-04-14 Tom Tromey <tromey@redhat.com>
2864 * c-lang.c (c_emit_char): Use INTERMEDIATE_ENCODING.
2865 (c_printstr): Likewise.
2866 * charset.c: Include gdb_wait.h.
2867 (make_wchar_iterator): Use INTERMEDIATE_ENCODING.
2868 (find_charset_names): Use pexecute. Handle libiconv's output.
2870 (_initialize_charset): Use xstrdup.
2871 * gdb_wchar.h: Check HAVE_BTOWC. Split PHONY_ICONV and wchar
2873 (INTERMEDIATE_ENCODING): New define.
2874 * configure, config.in: Rebuild.
2875 * configure.ac: Check for btowc.
2877 2009-04-15 Tom Tromey <tromey@redhat.com>
2879 * c-lang.c (evaluate_subexp_c): Correctly handle EVAL_SKIP.
2881 2009-04-15 Eli Zaretskii <eliz@gnu.org>
2883 * utils.c (parse_escape): Initialize target_char to pacify GCC.
2885 2009-04-14 Jan Kratochvil <jan.kratochvil@redhat.com>
2887 * c-lang.c (c_get_string): Fix xfree crash on a failed string read.
2889 2009-04-14 Pierre Muller <muller@ics.u-strasbg.fr>
2891 ARI fix: sprintf rule.
2892 * ada-exp.y (convert_char_literal): Replace sprintf by xsnprintf.
2893 * ada-lang.c (add_angle_brackets): Use xstrprintf.
2894 (ada_decode): Replace sprintf by xsnprintf.
2895 (find_old_style_renaming_symbol): Ditto.
2896 (ada_to_fixed_type_1, ada_enum_name): Ditto.
2899 2009-04-14 Joel Brobecker <brobecker@adacore.com>
2901 * target.c (target_mourn_inferior): Call bfd_cache_close_all
2902 after having executed the target mourn_inferior routine.
2904 2009-04-14 Eli Zaretskii <eliz@gnu.org>
2906 * config/djgpp/djconfig.sh (DEPDIR): Define to "_deps", if
2909 2009-04-13 David Daney <ddaney@caviumnetworks.com>
2911 * infrun.c (maybe_software_singlestep): New function.
2912 (resume): Call maybe_software_singlestep.
2913 (handle_inferior_event): Same.
2915 2009-04-13 Tom Tromey <tromey@redhat.com>
2917 * python/python-frame.c (frapy_richcompare): Return
2918 Py_NotImplemented, not an error. Handle Py_NE as well.
2920 2009-04-13 Eli Zaretskii <eliz@gnu.org>
2922 * charset.c (EILSEQ): Define if not defined by system headers.
2924 2009-04-11 Eli Zaretskii <eliz@gnu.org>
2926 * config/djgpp/config.sed: Tweak ac_config_files in intl/configure
2927 to be consistent with renaming config.intl.in into config_intl.in.
2929 * go32-nat.c (go32_attach, go32_detach): Fix prototypes to be
2930 consistent with the change from 2008-11-09.
2932 2009-04-10 Jan Kratochvil <jan.kratochvil@redhat.com>
2934 * gdbtypes.c: Remove excessive parentheses at the return keywords.
2935 * varobj.c (varobj_invalidate): Fix indentation.
2936 * varobj.c (varobj_invalidate): Fix formatting text width.
2938 2009-04-08 Vladimir Prus <vladimir@codesourcery.com>
2940 Implement -exec-jump.
2942 * mi/mi-cmds.h (mi_cmd_exec_jump): Declare.
2943 * mi/mi-main.c (mi_cmd_exec_jump): New.
2944 * mi/mi-cmds.c (mi_cmds): Register exec-jump.
2946 2009-04-07 Doug Evans <dje@google.com>
2948 * symfile.c (symbol_file_clear): Fix indentation.
2950 2009-04-06 Mark Kettenis <kettenis@gnu.org>
2952 * sparc64nbsd-nat.c (sparc64nbsd_supply_pcb): Fix comment.
2954 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
2956 * ppc-linux-nat.c (ppc_linux_target_wordsize): New function.
2957 (ppc_linux_auxv_parse): New function.
2958 (ppc_linux_read_description): Use ppc_linux_target_wordsize.
2959 (_initialize_ppc_linux_nat): Install ppc_linux_auxv_parse.
2961 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
2963 * spu-linux-nat.c (spu_bfd_open): Set filename of in-memory
2964 BFD to contents of SPU name note.
2965 (spu_symbol_file_add_from_memory): Call symbol_file_add_from_bfd
2966 with "from_tty" argument 1 instead of 0.
2968 2009-04-02 Jan Kratochvil <jan.kratochvil@redhat.com>
2971 (new_symbol <DW_TAG_variable> <!DW_AT_location> <DW_AT_external>):
2972 Create the symbol in local scope.
2973 * symtab.h (cu->list_in_scope <LOC_UNRESOLVED>): New comment part.
2975 2009-04-02 Keith Seitz <keiths@redhat.com>
2977 * stabsread.c (read_member_functions): GCC may emit an extra space
2978 at the end of the names "__base_ctor" and "__base_dtor"; so ignore
2979 whitespace when looking for these functions.
2981 2009-04-01 Joel Brobecker <brobecker@adacore.com>
2983 Change the default value for "set print frame-arguments" to scalars.
2985 * stack.c (print_frame_arguments): Set initial value to "scalars".
2987 2009-04-01 Aleksandar Ristovski <aristovski@qnx.com>
2989 * mips-tdep.c (mips_numeric_register_alieses): New definition.
2990 (mips_gdbarch_init): Add user registers from
2991 mips_numeric_register_aliases.
2993 2009-04-01 Joel Brobecker <brobecker@adacore.com>
2995 * linux-nat.c (linux_nat_filter_event): Minor comment reformatting.
2997 2009-04-01 Joel Brobecker <brobecker@adacore.com>
2999 * linux-nat.c (linux_nat_filter_events): Do not delete the lwp if
3000 this is the last one.
3002 2009-04-01 Pedro Alves <pedro@codesourcery.com>
3004 * remote.c (append_resumption): New.
3005 (remote_vcont_resume): Use it.
3007 2009-04-01 Joel Brobecker <brobecker@adacore.com>
3009 * windows-nat.c (+windows_get_ada_task_ptid): New function.
3010 (init_windows_ops): Set windows_ops.to_get_ada_task_ptid.
3012 2009-03-31 Daniel Jacobowitz <dan@codesourcery.com>
3013 Keith Seitz <keiths@redhat.com>
3014 Jan Kratochvil <jan.kratochvil@redhat.com>
3017 * Makefile.in (dbxread.o): Update.
3018 * dbxread.c (read_dbx_symtab): Use cp_canonicalize_string.
3019 * dwarf2read.c (GDB_FORM_cached_string): New.
3020 (read_partial_die): Use dwarf2_canonicalize_name.
3021 (dwarf2_linkage_name): Use dwarf2_name.
3022 (dwarf2_canonicalize_name): New.
3023 (dwarf2_name): Use dwarf2_canonicalize_name.
3024 (dwarf_form_name, dump_die): Handle GDB_FORM_cached_string.
3025 * stabsread.c (define_symbol, read_type): Use cp_canonicalize_string.
3026 * symtab.c (lookup_symbol_in_language): Canonicalize input before
3028 * cp-name-parser.y: operator() requires two parameters,
3029 according to libiberty.
3030 * minsyms.c (lookup_minimal_symbol): Canonicalize input
3034 2009-03-31 Joel Brobecker <brobecker@adacore.com>
3036 Provide support for (Ada) task-specific breakpoints.
3038 * ada-lang.h (ada_get_task_number): Add declaration.
3039 (breakpoint_ada_task_match): Delete declaration.
3040 * ada-tasks.c (ada_get_task_number): Make non-static.
3041 * breakpoint.h (struct breakpoint): Add field "task".
3042 * breakpoint.c (print_one_breakpoint_location): Add handling of
3043 task-specific breakpoints.
3044 (create_breakpoint, create_breakpoints, find_condition_and_thread):
3045 New parameter "task".
3046 (break_command_really): Update calls to find_condition_and_thread
3047 and create_breakpoints.
3048 (breakpoint_re_set_one): Update call to find_condition_and_thread.
3051 2009-03-31 Joel Brobecker <brobecker@adacore.com>
3053 * ada-tasks.c (short_task_info): Eliminate the "Running" task state.
3055 2009-03-31 Pedro Alves <pedro@codesourcery.com>
3057 * remote.c (remote_notice_new_inferior): Use ptid_is_pid. Check
3058 if the thread's ptid without a thread id field is in the list
3059 before calling thread_change_ptid.
3060 (extended_remote_attach_1): In non-stop mode, do not rely on
3061 querying the current thread, instead, query the thread list, and
3062 select the first thread of the process.
3063 * gdbthread.h (first_thread_of_process): Declare.
3064 * thread.c (first_thread_of_process): Define.
3066 2009-03-30 Stan Shebs <stan@codesourcery.com>
3068 Make tracepoints into a type of breakpoint.
3069 * breakpoint.h (enum bptype): Add bp_tracepoint.
3070 (struct breakpoint): Add fields step_count, pass_count, actions.
3071 (get_tracepoint, get_tracepoint_by_number): Declare.
3072 (all_tracepoints): Declare.
3073 * breakpoint.c: Include tracepoint.h, readline.h.
3074 (ALL_TRACEPOINTS): Move here from tracepoint.c.
3075 (tracepoint_count): Ditto.
3076 (should_be_inserted): GDB does not insert tracepoints itself.
3077 (print_it_typical): Add tracepoint case.
3078 (bpstat_what): Ditto.
3079 (print_one_breakpoint_location): Ditto, and add printing for
3080 pass count, step count, and action list.
3081 (user_settable_breakpoint): Add tracepoint case.
3082 (allocate_bp_location): Ditto.
3083 (set_breakpoint_location_function): Ditto.
3084 (disable_breakpoints_in_shlibs): Ditto.
3086 (break_command_really): Add argument traceflag, use to choose
3087 basic breakpoint type.
3088 (break_command_1): Pass extra argument.
3089 (set_breakpoint, handle_gnu_v3_exceptions): Ditto.
3090 (breakpoint_re_set_one): Add tracepoint case.
3091 (disable_command, enable_command): Ditto.
3092 (set_tracepoint_count): Move here from tracepoint.c.
3093 (trace_command): Move here from tracepoint.c and use
3094 break_command_really.
3095 (tracepoints_info): Move here from tracepoint.c and call
3097 (enable_trace_command): Move here from tracepoint.c and call
3099 (disable_trace_command): Move here from tracepoint.c and call
3101 (delete_trace_command): Move here from tracepoint.c and call
3103 (trace_pass_command): Move here from tracepoint.c.
3104 (get_tracepoint_by_number): Ditto.
3105 (tracepoint_save_command): Ditto.
3106 (get_tracepoint): New function.
3107 (all_tracepoints): New function.
3108 (_initialize_breakpoint): Move tracepoint init from tracepoint.c,
3109 deprecate "enable trace" and "disable trace" commands.
3110 * tracepoint.h (struct tracepoint): Remove.
3111 (tracepoint_chain): Remove decl.
3112 (deprecated_create_tracepoint_hook): Remove decl.
3113 (deprecated_delete_tracepoint_hook): Remove decl.
3114 (deprecated_modify_tracepoint_hook): Remove decl.
3115 (ALL_TRACEPOINTS, ALL_TRACEPOINTS_SAFE): Remove.
3116 (free_actions): Update signature.
3117 (validate_actionline): Update signature.
3118 (end_actions_pseudocommand): Declare.
3119 (while_stepping_pseudocommand): Declare.
3120 * tracepoint.c: Include breakpoint.h.
3121 (tracepoint_chain, tracepoint_count): Remove.
3122 (free_actions, make_cleanup_free_actions): Update signature.
3123 (trace_command, set_raw_tracepoint): Remove.
3124 (trace_mention): Remove.
3125 (tracepoints_info): Remove.
3126 (tracepoint_operation, map_args_over_tracepoints): Remove.
3127 (get_tracepoint_by_number): Remove.
3128 (enable_trace_command, disable_trace_command): Remove.
3129 (delete_trace_command, trace_pass_command): Remove.
3130 (trace_actions_command, read_actions): Update signature.
3131 (validate_actionline): Update signature, use bp loc.
3132 (encode_actions): Ditto.
3133 (download_tracepoint): New function, body of trace_start_command.
3134 (trace_start_command): Call it, use all_tracepoints.
3135 (tracepoint_save_command): Remove.
3136 (tracepoint_dump_command): Use get_tracepoint.
3137 (end_actions_pseudocommand): Make globally visible.
3138 (while_stepping_pseudocommand): Ditto.
3139 (_initialize_tracepoint): Move command definitions to breakpoint.c.
3141 2009-03-30 Thiago Jung Bauermann <bauerman@br.ibm.com>
3143 Expose frames to Python.
3144 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-frame.o.
3145 (SUBDIR_PYTHON_SRCS): Add python-frame.c.
3146 (python-frame.o): New target.
3147 * python/python-frame.c: New file.
3148 * python/python-internal.h (gdbpy_frames, gdbpy_newest_frame,
3149 gdbpy_frame_stop_reason_string, gdbpy_selected_frame,
3150 gdbpy_initialize_frames): New prototypes.
3151 * python/python.c (_initialize_python): Call gdbpy_initialize_frames.
3152 (GdbMethods): Add `selected_frame' and `frame_stop_reason_string'
3154 * stack.c (find_frame_funname): New function, factored out of
3156 (print_frame): Call find_frame_funname.
3157 * stack.h (find_frame_funname): Add prototype.
3159 2009-03-29 Thiago Jung Bauermann <bauerman@br.ibm.com>
3161 Remove unused value_object attribute `owned_by_gdb'.
3162 * python/python-value.c (value_object): Remove owned_by_gdb
3164 (valpy_dealloc): Remove reference to self->owned_by_gdb.
3165 (valpy_new): Likewise.
3166 (value_to_value_object): Likewise.
3168 2009-03-29 Thiago Jung Bauermann <bauerman@br.ibm.com>
3170 Change gdb.Value.address from a method to an attribute.
3171 * python/python-value.c (value_object): Add `address' element.
3172 (valpy_dealloc): Decrement reference to self->address if set.
3173 (valpy_new): Initialize val_obj->address.
3174 (valpy_address): Rename to ...
3175 (valpy_get_address): ... this. Change signature from method to
3176 attribute. Update self->address if not set.
3177 (value_to_value_object): Initialize val_obj->address.
3178 (value_object_getset): Add `address' element.
3179 (value_object_methods): Remove `address' element.
3181 2009-03-29 Andreas Schwab <schwab@linux-m68k.org>
3183 * observer.sh: Set LANG/LC_ALL to C, not c.
3185 2009-03-28 Kevin Buettner <kevinb@redhat.com>
3187 * mn10300-tdep.c (mn10300_gdbarch_init): For mn10300, by default,
3190 2009-03-28 Pedro Alves <pedro@codesourcery.com>
3192 * remote.c (remote_stop_ns): If multi-process extensions are off,
3193 and GDB is requesting the whole process to stop, sent "vCont;t",
3196 2009-03-28 Pedro Alves <pedro@codesourcery.com>
3198 * inf-loop.c (inferior_event_handler): Avoid calling is_running on
3201 2009-03-27 Eli Zaretskii <eliz@gnu.org>
3203 * config/djgpp/fnchange.lst: Update to fix ARI-reported problems.
3205 2009-03-26 Doug Evans <dje@google.com>
3207 * thread.c (do_restore_current_thread_cleanup): Redo test for
3208 whether to restore old->inferior_ptid.
3210 2009-03-26 Tom Tromey <tromey@redhat.com>
3212 * breakpoint.c (resolve_sal_pc): Preserve original line number
3213 when skipping prologue.
3215 2009-03-26 Doug Evans <dje@google.com>
3217 * thread.c (inferior_thread) Remove "extern" in definition.
3219 2009-03-26 Thiago Jung Bauermann <bauerman@br.ibm.com>
3221 Add gdb.Value.is_optimized_out attribute.
3222 * python/python-value.c (valpy_get_is_optimized_out): New
3224 (value_object_getset): New variable.
3225 (value_object_type): Initialize tp_getset element.
3227 2009-03-26 Joel Brobecker <brobecker@adacore.com>
3229 Recognize missing DW_AT_location as <value optimized out>.
3231 (new_symbol <DW_TAG_variable> <!DW_AT_location> <!DW_AT_external>):
3232 Call add_symbol_to_list.
3234 2009-03-25 Tom Tromey <tromey@redhat.com>
3236 * gdbtypes.h (CHECK_TYPEDEF): Don't yield a value.
3237 * stack.c (print_this_frame_argument_p): Use check_typedef.
3239 2009-03-25 Tom Tromey <tromey@redhat.com>
3241 * configure: Rebuild.
3242 * acinclude.m4 (AM_ICONV): Set am_cv_use_build_libiconv.
3243 Rearrange flags setting. Add comments.
3245 2009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
3247 * config/i386/nm-i386.h: Remove code within
3248 I386_WATCHPOINTS_IN_TARGET_VECTOR conditional.
3249 * config/i386/nm-cygwin.h: Remove I386_WATCHPOINTS_IN_TARGET_VECTOR
3251 * config/i386/nm-cygwin64.h: Ditto.
3252 * config/i386/nm-fbsd.h: Ditto.
3253 * config/i386/nm-go32.h: Ditto.
3254 * config/i386/nm-linux.h: Ditto.
3255 * config/i386/nm-linux64.h: Ditto.
3257 2009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
3259 ARI fix: "xasprintf" rule.
3260 * printcmd.c (sym_info): Replace xasprintf by xstrprintf.
3262 2009-03-25 Pedro Alves <pedro@codesourcery.com>
3264 * remote.c (remote_start_remote): In non-stop mode, call
3265 init_wait_for_inferior before adding threads and inferiors.
3267 2009-03-25 Joel Brobecker <brobecker@adacore.com>
3269 * breakpoint.c (breakpoint_thread_match): Split a large condition
3270 into several smaller conditions. No behavior change.
3272 2009-03-25 Pedro Alves <pedro@codesourcery.com>
3274 * infrun.c (infrun_thread_thread_exit): New.
3275 (_initialize_infrun): Attach it to the thread_exit observer.
3276 * thread.c (delete_thread_1): Always call the observer, passing it
3278 * mi/mi-interp.c (mi_thread_exit): Add "silent" parameter. If
3279 SILENT, return immediately.
3281 2009-03-25 Pedro Alves <pedro@codesourcery.com>
3283 * infrun.c (normal_stop): Use has_stack_frames instead of
3285 * mi/mi-main.c (mi_execute_command): Avoid calling inferior_thread
3286 when there is no thread selected.
3287 (mi_cmd_execute): Don't special case commands that can run without
3288 a valid selected thread.
3289 * top.c (execute_command): Don't special case commands that can
3290 run without a valid selected thread. Use has_stack_frames.
3291 * infcmd.c (ensure_valid_thread): New.
3292 (continue_1, step_1, jump_command, signal_command): Use it.
3293 (detach_command): Error out if there's no selected thread/inferior.
3294 * thread.c (print_thread_info): Allow having no thread selected.
3295 (switch_to_thread): Don't read the PC if there is no current thread.
3296 (do_restore_current_thread_cleanup): Don't record the current
3297 frame if there is no current thread.
3298 (make_cleanup_restore_current_thread): Don't read frame info if
3299 there is no selected thread.
3300 (_initialize_thread): Don't mark commands as
3301 "no_selected_thread_ok".
3302 * frame.c (get_current_frame): Error out if there is no valid
3304 (has_stack_frames): Return false if there is no valid
3306 * cli/cli-cmds.c (init_cli_cmds): Don't mark commands as
3307 "no_selected_thread_ok".
3308 * cli/cli-decode.c (set_cmd_no_selected_thread_ok)
3309 (get_cmd_no_selected_thread_ok): Delete.
3310 * cli/cli-decode.h (CMD_NO_SELECTED_THREAD_OK): Delete.
3311 (set_cmd_no_selected_thread_ok, get_cmd_no_selected_thread_ok):
3313 * stack.c (get_selected_block): Use has_stack_frames.
3315 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
3317 Fix size of FPSCR in Power 7 processors.
3318 * ppc-linux-nat.c (PPC_FEATURE_ARCH_2_05): Remove #define.
3319 (PPC_FEATURE_HAS_DFP): New #define.
3320 (ppc_linux_read_description): Check for DFP feature instead of
3321 ISA 2.05 to decide on size of the FPSCR.
3323 2009-03-25 Kevin Buettner <kevinb@redhat.com>
3325 * mn10300-tdep.c (trad-frame.h): Don't include.
3326 (prologue-value.h): Include.
3327 (mn10300_frame_unwind_cache, set_reg_offsets): Delete.
3328 (struct mn10300_prologue): Define.
3329 (push_reg, translate_rreg, check_for_saved): New functions.
3330 (mn10300_analyze_prologue): Rewrite, using prologue-value
3331 machinery. Handle more instructions than before. Permit
3332 instructions to occur in any order.
3333 (mn10300_skip_prologue): Find the extents of the function
3334 in question; mn10300_analyze_prologue no longer does this.
3335 (mn10300_analyze_frame_prologue): New function.
3336 (mn10300_frame_base): New function.
3337 (mn10300_frame_this_id): Rewrite, no longer using trad-frame
3339 (mn10300_frame_prev_register): Likewise.
3340 (mn10300_frame_base_address, mn10300_frame_base struct): Delete.
3341 (mn10300_unwind_pc, mn10300_unwind_sp): Rename `next_frame' to
3343 (mn10300_frame_unwind_init): Don't call frame_base_set_default().
3345 2009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
3347 Fix completer problem for filename completion on the first try.
3349 * gdb/completer.h (gdb_completion_word_break_characters): New function.
3350 * gdb/completer.c: Include gdb_assert.h.
3351 (complete_line_internal_reason): New enum.
3352 (complete_line_internal): Change last argument type to
3353 complete_line_internal_reason.
3354 Modify function to handle the different complete_line_internal_reason
3356 (complete_line): Adapt to change in complete_line_internal.
3357 (command_completer): Ditto.
3358 (gdb_completion_word_break_characters): Implement new function.
3359 * top.c (init_main): Set rl_completion_word_break_hook to
3360 gdb_completion_word_break_characters.
3363 2009-03-25 Pierre Muller <muller@ics.u-strasbg.fr>
3365 ARI fix: "strlen d_name" rule.
3366 * linux-nat.c (linux_nat_xfer_osdata): Use NAMELEN macro.
3369 2009-03-24 Tom Tromey <tromey@redhat.com>
3370 Pedro Alves <pedro@codesourcery.com>
3372 * configure, config.in: Rebuild.
3373 * configure.ac: Check for libiconvlist.
3374 * charset.c: Check HAVE_LIBICONVLIST.
3375 * acinclude.m4 (AM_ICONV): Don't subst LIBICONV, LIBICONV_INCLUDE,
3376 LIBICONV_LIBDIR. Update CPPFLAGS and LIBS.
3377 * Makefile.in (LIBICONV, LIBICONV_INCLUDE, LIBICONV_LIBDIR):
3379 (INTERNAL_CFLAGS_BASE): Update.
3380 (INTERNAL_LDFLAGS): Update.
3383 2009-03-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3385 * configure.ac: Initialize the variable $PREFER_CURSES.
3386 * configure: Regenerated.
3388 2009-03-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3390 * configure.ac: Enable $PREFER_CURSES even with default $ENABLE_TUI.
3391 * configure: Regenerated.
3393 2009-03-24 Pierre Muller <muller@ics.u-strasbg.fr>
3395 ARI fix: "strerror" rule.
3396 * darwin-nat.c (darwin_ptrace): Use safe_strerror.
3397 (darwin_stop_inferior, darwin_attach, darwin_detach): Ditto.
3399 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3401 * ada-exp.y (get_symbol_field_type): Make sure to resolve typedefs
3402 before looking up the fields inside our struct type.
3404 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3406 * ada-lang.c (resolve_subexp) [UNOP_QUAL]: Resolve typedefs before
3407 trying to resolve the type qualification.
3409 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3411 * ada-lang.c (ada_evaluate_subexp) [UNOP_IN_RANGE]: make sure
3412 we try to apply the attribute on the real type, rather than
3413 its associated typedef.
3415 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3417 * ada-lang.c (ada_evaluate_subexp) [OP_ATR_MODULUS]: Use check_typdef
3418 to make sure we try to get the modulus of the actual type, not the
3421 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3423 * ada-lang.c (ada_evaluate_subexp): [OP_ATR_FIRST, OP_ATR_LAST]
3424 [OP_ATR_LENGTH]: When using the attribute on a type, make sure
3425 to get the real type, not the associated typedef.
3427 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3429 * ada-lang.c (ada_get_field_index): Add handling of the case
3430 when TYPE is a typedef of a struct.
3432 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3434 Add gdb_usleep as a portable version of usleep based on gdb_select.
3435 * gdb_usleep.h, gdb_usleep.c: New files.
3436 * Makefile.in (SFILES): Add gdb_usleep.c.
3437 (HFILES_NO_SRCDIR): Add gdb_usleep.h.
3438 (COMMON_OBS): Add gdb_usleep.o.
3439 * ser-unix.c (hardwire_send_break): Replace call to gdb_select
3440 by call to gdb_usleep.
3442 2009-03-23 Joel Brobecker <brobecker@adacore.com>
3444 * buildsym.c (end_symtab): If we ignore the subfiles, then
3445 unlink the associated symtabs if they were already allocated.
3447 2009-03-23 Jerome Guitton <guitton@adacore.com>
3449 Provide a way to force building of GDB with libcurses.
3450 * configure.ac: Add --with-curses.
3451 * configure: Regenerated.
3453 2009-03-23 Tom Tromey <tromey@redhat.com>
3455 * dwarf2expr.c (execute_stack_op) <DW_OP_GNU_uninit>: Fix typo in
3458 2009-03-23 Paul Pluzhnikov <ppluzhnikov@google.com>
3460 * breakpoint.c (disable_breakpoints_in_unloaded_shlib): Use
3461 solib_contains_address_p instead of searching.
3463 2009-03-23 Tom Tromey <tromey@redhat.com>
3465 * charset.c (ICONV_CONST) <PHONY_ICONV>: Define.
3466 (iconv): Make 'inbuf' argument const.
3467 (convert_between_encodings): Use ICONV_CONST.
3468 (wchar_iterate): Likewise.
3470 2009-03-22 Christopher Faylor <me+cygwin@cgf.cx>
3472 * windows-nat.c (AdjustTokenPrivileges): Implement macro wraparound for
3473 dynamically loaded function.
3474 (LookupPrivilegeValueA): Ditto.
3475 (OpenProcessToken): Ditto.
3476 (AdjustTokenPrivileges): Rename and define placeholder for address of
3477 dynamically loaded function.
3478 (LookupPrivilegeValueA): Ditto.
3479 (OpenProcessToken): Ditto.
3480 (set_process_privilege): Remove check for loaded functions.
3481 (bad_OpenProcessToken): Define.
3482 (_initialize_loadable): Load token functions from advapi here, setting
3483 OpenProcessToken function to a dummy static function which always return
3484 error if OS doesn't support this functionality.
3486 2009-03-22 Nicolas Roche <roche@adacore.com>
3487 Christopher Faylor <me+cygwin@cgf.cx>
3489 * win32-nat.c (ctrl_c_handler): New function.
3490 (win32_wait): Register ctrl_c_handler as Ctrl-C handler if the inferior
3491 is run in a separate console.
3493 2009-03-22 Christopher Faylor <me+cygwin@cgf.cx>
3495 * windows-nat.c (DebugActiveProcessStop): Implement macro wraparound
3496 for dynamically loaded function.
3497 (DebugBreakProcess): Ditto.
3498 (DebugSetProcessKillOnExit): Ditto.
3499 (EnumProcessModules): Ditto.
3500 (GetModuleFileNameExA): Ditto.
3501 (GetModuleInformation): Ditto.
3502 (DebugActiveProcessStop): Rename and define placeholder for address of
3503 dynamically loaded function.
3504 (DebugBreakProcess): Ditto.
3505 (DebugSetProcessKillOnExit): Ditto.
3506 (EnumProcessModules): Ditto.
3507 (GetModuleFileNameExA): Ditto.
3508 (GetModuleInformation): Ditto.
3509 (psapi_loaded): Delete.
3510 (get_module_name): Don't check psapi_loaded, just rely on the fact that
3511 dynamically loaded functions will return failure if they weren't
3513 (has_detach_ability): Delete.
3514 (windows_attach): Remove call to has_detach_ability (). Just rely on
3515 functions being callable.
3516 (bad_DebugActiveProcessStop): Define.
3517 (bad_DebugBreakProcess): Ditto.
3518 (bad_DebugSetProcessKillOnExit): Ditto.
3519 (bad_EnumProcessModules): Ditto.
3520 (bad_GetModuleFileNameExA): Ditto.
3521 (bad_GetModuleInformation): Ditto.
3522 (_initialize_loadable): Rename from _initialize_psapi. Initialize all
3523 dynamic storage here, setting nonexistent functions to dummy static
3524 functions which always return error.
3526 2009-03-22 Pedro Alves <pedro@codesourcery.com>
3528 * mi/mi-interp.c (mi_interpreter_init): Attach mi_about_to_proceed
3529 to the about_to_proceed observer notification.
3530 (mi_about_to_proceed): New.
3531 (mi_on_resume): Only output ^running and the prompt here if the
3532 target was proceeded.
3533 * breakpoint.c (breakpoint_proceeded): New static.
3534 (breakpoint_about_to_proceed): New.
3535 (_initialize_breakpoints): Attach breakpoint_about_to_proceed to
3536 the about_to_proceed observer notification.
3537 * inferior.h (breakpoint_proceeded): Delete declaration.
3538 * infrun.c (clear_proceed_status): Don't set breakpoint_proceeded.
3539 Notify the about_to_proceed observers.
3540 (struct inferior_status): Delete breakpoint_proceeded member.
3541 (save_inferior_status): Don't save it.
3542 (restore_inferior_status): Don't restore it.
3543 * mi-main.h (mi_proceeded): Declare.
3544 * mi/mi-main.c (mi_cmd_execute): Clear mi_proceeded before running
3547 2009-03-22 Pedro Alves <pedro@codesourcery.com>
3549 * gdbthread.h (struct thread_info): Add in_infcall member.
3550 * infcall.c (run_inferior_call): Save, set and restore in_infcall.
3551 Remove reverences to suppress_resume_observer. Refresh
3552 `call_thread' after returning from `proceed'.
3553 * infcmd.c (suppress_resume_observer): Delete.
3554 * inferior.h (suppress_resume_observer): Delete declaration.
3555 * mi/mi-interp.c (mi_on_resume): Suppress output while calling an
3557 * thread.c (set_running): Remove references to
3558 suppress_resume_observer.
3559 * infrun.c (struct inferior_status): Add in_infcall member.
3560 (save_inferior_status): Save it.
3561 (restore_inferior_status): Restore it.
3563 2009-03-22 Pedro Alves <pedro@codesourcery.com>
3565 * infcall.c (run_inferior_call): Remove references to
3566 suppress_stop_observer.
3567 * infcmd.c (suppress_stop_observer): Delete.
3568 (finish_command_continuation): Remove NOTE. Don't clear
3569 suppress_stop_observer anymore.
3570 (finish_command_continuation_free_arg): Likewise.
3571 (finish_forward): Remove references to suppress_stop_observer.
3572 Call normal_stop observer if we haven't already.
3573 * inferior.h (suppress_stop_observer): Delete.
3574 * infrun.c (normal_stop): When deciding to suppress the
3575 normal_stop observer, check for proceed_to_finish instead of
3576 suppress_stop_observer.
3578 2009-03-22 Pedro Alves <pedro@codesourcery.com>
3580 * symfile.c (symfile_relocate_debug_section): Remove check for
3583 2009-03-21 Jan Kratochvil <jan.kratochvil@redhat.com>
3584 Jim Blandy <jimb@red-bean.com>
3585 Thiago Jung Bauermann <bauerman@br.ibm.com>
3586 Tom Tromey <tromey@redhat.com>
3588 Miscellaneous fixes to the Python code.
3589 * python/python-cmd.c (cmdpy_init): Accept keyword
3591 * python/python-value.c (valpy_string): Accept keyword
3593 (valpy_binop): Use `break' to exit from the TRY_CATCH block.
3594 Do not call value_to_value_object on NULL RES_VAL.
3595 (value_object_methods): Change `string' entry to also accept
3597 (convert_value_from_python): Return a copy of the value if obj is
3599 (value_object_methods): Mark the `string' method as accepting
3600 keywords, and show method "prototype" in the doc string.
3601 * python/python.c (get_parameter): Don't return inside a
3604 2009-03-20 Tom Tromey <tromey@redhat.com>
3606 Add support for convenience functions in Python.
3607 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-function.o.
3608 (SUBDIR_PYTHON_SRCS): Add python-function.c.
3609 (python-function.o): New target.
3610 * eval.c: Include "python/python.h" and <ctype.h>.
3611 (evaluate_subexp_standard): Handle values of type
3612 TYPE_CODE_INTERNAL_FUNCTION.
3613 * gdbtypes.h (type_code): Add TYPE_CODE_INTERNAL_FUNCTION.
3614 * parse.c (write_exp_string): Remove duplicate word in comment.
3615 * python/python-function.c: New file.
3616 * python/python-internal.h (gdbpy_initialize_functions): Add
3618 * python/python.c (_initialize_python): Call
3619 gdbpy_initialize_functions.
3620 * valprint.c (value_check_printable): Handle values of type
3621 TYPE_CODE_INTERNAL_FUNCTION.
3622 * value.c: Include "cli/cli-decode.h".
3623 (internal_function): New struct.
3624 (functionlist, internal_fn_type): New static variables.
3625 (lookup_only_internalvar,
3626 lookup_internalvar): Add const qualifier to name argument.
3627 (create_internalvar): Likewise. Initialize new field.
3628 (set_internal_var): Fix typo in comment. Don't allow assignment
3629 to canonical variable.
3630 (value_create_internal_function, value_internal_function_name,
3631 call_internal_function, function_command, function_destroyer,
3632 add_internal_function): New functions.
3633 (_initialize_values): Create `function' placeholder command.
3634 Initialize internal_fn_type.
3635 * value.h (lookup_only_internalvar, create_internalvar,
3636 lookup_internalvar): Add const qualifier to name argument.
3637 (internal_function_fn, add_internal_function, call_internal_function,
3638 value_internal_function_name): Add prototypes.
3639 (struct internalvar) <canonical>: New field.
3641 2009-03-20 Tom Tromey <tromey@redhat.com>
3643 * c-lang.c (evaluate_subexp_c): Call check_typedef.
3645 2009-03-20 Tom Tromey <tromey@redhat.com>
3646 Julian Brown <julian@codesourcery.com>
3648 PR i18n/7220, PR i18n/7821, PR exp/8815, PR exp/9103,
3649 PR i18n/9401, PR exp/9613:
3651 * value.h (value_typed_string): Declare.
3652 (val_print_string): Update.
3653 * valprint.h (print_char_chars): Update.
3654 * valprint.c (print_char_chars): Add type argument. Update.
3655 (val_print_string): Likewise.
3656 * valops.c (value_typed_string): New function.
3657 * utils.c (host_char_to_target): New function.
3658 (parse_escape): Use host_char_to_target, host_hex_value. Update.
3660 (no_control_char_error): Remove.
3661 * typeprint.c (print_type_scalar): Update.
3662 * scm-valprint.c (scm_scmval_print): Update.
3663 * scm-lang.h (scm_printchar, scm_printstr): Update.
3664 * scm-lang.c (scm_printchar): Add type argument.
3665 (scm_printstr): Likewise.
3666 * printcmd.c (print_formatted): Update.
3667 (print_scalar_formatted): Update.
3668 (printf_command) <wide_string_arg, wide_char_arg>: New constants.
3669 Handle '%lc' and '%ls'.
3670 * parser-defs.h (struct typed_stoken): New type.
3671 (struct stoken_vector): Likewise.
3672 (write_exp_string_vector): Declare.
3673 * parse.c (write_exp_string_vector): New function.
3674 * p-valprint.c (pascal_val_print): Update.
3675 * p-lang.h (is_pascal_string_type, pascal_printchar,
3676 pascal_printstr): Update.
3677 * p-lang.c (is_pascal_string_type): Remove 'char_size' argument.
3678 Add 'char_type' argument.
3679 (pascal_emit_char): Add type argument.
3680 (pascal_printchar): Likewise.
3681 (pascal_printstr): Likewise.
3682 * objc-lang.c (objc_emit_char): Add type argument.
3683 (objc_printchar): Likewise.
3684 (objc_printstr): Likewise.
3685 * macroexp.c (get_character_constant): Handle unicode characters.
3687 (get_string_literal): Handle unicode strings. Use
3689 * m2-valprint.c (print_unpacked_pointer): Update.
3690 (m2_print_array_contents): Update.
3691 (m2_val_print): Update.
3692 * m2-lang.c (m2_emit_char): Add type argument.
3693 (m2_printchar): Likewise.
3694 (m2_printstr): Likewise.
3695 * language.h (struct language_defn) <la_printchar>: Add type
3697 <la_printstr, la_emitchar>: Likewise.
3698 (LA_PRINT_CHAR): Likewise.
3699 (LA_PRINT_STRING): Likewise.
3700 (LA_EMIT_CHAR): Likewise.
3701 * language.c (unk_lang_emit_char): Add type argument.
3702 (unk_lang_printchar): Likewise.
3703 (unk_lang_printstr): Likewise.
3704 * jv-valprint.c (java_val_print): Update.
3705 * jv-lang.c (java_emit_char): Add type argument.
3706 * f-valprint.c (f_val_print): Update.
3707 * f-lang.c (f_emit_char): Add type argument.
3708 (f_printchar): Likewise.
3709 (f_printstr): Likewise.
3710 * expprint.c (print_subexp_standard): Update.
3711 * charset.h (target_wide_charset): Declare.
3712 (c_target_char_has_backslash_escape, c_parse_backslash,
3713 host_char_print_literally, host_char_to_target,
3714 target_char_to_host, target_char_to_control_char): Remove.
3715 (enum transliterations): New type.
3716 (convert_between_encodings): Declare.
3717 (HOST_ESCAPE_CHAR): New define.
3718 (host_letter_to_control_character, host_hex_value): Declare.
3719 (enum wchar_iterate_result): New enum.
3720 (struct wchar_iterator): Declare.
3721 (make_wchar_iterator, make_cleanup_wchar_iterator, wchar_iterator,
3722 wchar_push_back): Declare.
3723 * charset-list.h: New file.
3724 * c-valprint.c (textual_name): New function.
3725 (textual_element_type): Handle wide character types.
3726 (c_val_print): Pass original type to textual_element_type. Handle
3727 wide character types.
3728 (c_value_print): Use textual_element_type. Pass original type of
3730 * c-lang.h (enum c_string_type): New type.
3731 (c_printchar, c_printstr): Update.
3732 * c-lang.c (classify_type): New function.
3733 (print_wchar): Likewise.
3734 (c_emit_char): Add type argument. Handle wide characters.
3735 (c_printchar): Likewise.
3736 (c_printstr): Add type argument. Handle wide and multibyte
3738 (convert_ucn): New function.
3739 (emit_numeric_character): Likewise.
3740 (convert_octal): Likewise.
3741 (convert_hex): Likewise.
3742 (ADVANCE): New macro.
3743 (convert_escape): New function.
3744 (parse_one_string): Likewise.
3745 (evaluate_subexp_c): Likewise.
3746 (exp_descriptor_c): New global.
3747 (c_language_defn): Use exp_descriptor_c.
3748 (cplus_language_defn): Likewise.
3749 (asm_language_defn): Likewise.
3750 (minimal_language_defn): Likewise.
3751 (charset_for_string_type): New function.
3752 * c-exp.y (%union): Add 'svec' and 'tsval'.
3754 (exp): Add CHAR production.
3755 (string_exp): Rewrite.
3756 (exp) <string_exp>: Rewrite.
3757 (tempbuf): Now global.
3758 (tempbuf_init): New global.
3759 (parse_string_or_char): New function.
3760 (yylex) <tempbuf>: Now global.
3761 <tokptr, tempbufindex, tempbufsize, token_string, class_prefix>:
3763 Handle 'u', 'U', and 'L' prefixes. Call parse_string_or_char.
3764 (c_parse_escape): New function.
3765 * auxv.c (fprint_target_auxv): Update.
3766 * ada-valprint.c (ada_emit_char): Add type argument.
3767 (ada_printchar): Likewise.
3768 (ada_print_scalar): Update.
3769 (printstr): Add type argument. Update calls to ada_emit_char.
3770 (ada_printstr): Add type argument.
3771 (ada_val_print_array): Update.
3772 (ada_val_print_1): Likewise.
3773 * ada-lang.c (emit_char): Add type argument.
3774 * ada-lang.h (ada_emit_char, ada_printchar, ada_printstr): Add
3776 * gdb_locale.h: Include langinfo.h.
3777 * charset.c (_initialize_charset): Set default host charset from
3778 the locale. Don't register charsets. Add target-wide-charset
3779 commands. Call find_charset_names.
3780 (struct charset, struct translation): Remove.
3781 (GDB_DEFAULT_HOST_CHARSET): Remove.
3782 (GDB_DEFAULT_TARGET_WIDE_CHARSET): New define.
3783 (target_wide_charset_name): New global.
3784 (show_host_charset_name): Handle "auto".
3785 (show_target_wide_charset_name): New function.
3786 (host_charset_enum, target_charset_enum): Remove.
3787 (charset_enum): New global.
3788 (all_charsets, register_charset, lookup_charset, all_translations,
3789 register_translation, lookup_translation): Remove.
3790 (simple_charset, ascii_print_literally, ascii_to_control): Remove.
3791 (iso_8859_print_literally, iso_8859_to_control,
3792 iso_8859_family_charset): Remove.
3793 (ebcdic_print_literally, ebcdic_to_control,
3794 ebcdic_family_charset): Remove.
3795 (struct cached_iconv, check_iconv_cache, cached_iconv_convert,
3796 register_iconv_charsets): Remove.
3797 (target_wide_charset_be_name, target_wide_charset_le_name): New
3799 (identity_either_char_to_other): Remove.
3800 (set_be_le_names, validate): New functions.
3801 (backslashable, backslashed, represented): Remove.
3802 (default_c_target_char_has_backslash_escape): Remove.
3803 (default_c_parse_backslash, iconv_convert): Remove.
3804 (ascii_to_iso_8859_1_table, ascii_to_ebcdic_us_table,
3805 ascii_to_ibm1047_table, iso_8859_1_to_ascii_table,
3806 iso_8859_1_to_ebcdic_us_table, iso_8859_1_to_ibm1047_table,
3807 ebcdic_us_to_ascii_table, ebcdic_us_to_iso_8859_1_table,
3808 ebcdic_us_to_ibm1047_table, ibm1047_to_ascii_table,
3809 ibm1047_to_iso_8859_1_table, ibm1047_to_ebcdic_us_table): Remove.
3810 (table_convert_char, table_translation, simple_table_translation):
3812 (current_host_charset, current_target_charset,
3813 c_target_char_has_backslash_escape_func,
3814 c_target_char_has_backslash_escape_baton): Remove.
3815 (c_parse_backslash_func, c_parse_backslash_baton): Remove.
3816 (host_char_to_target_func, host_char_to_target_baton): Remove.
3817 (target_char_to_host_func, target_char_to_host_baton): Remove.
3818 (cached_iconv_host_to_target, cached_iconv_target_to_host):
3820 (lookup_charset_or_error, check_valid_host_charset): Remove.
3821 (set_host_and_target_charsets): Remove.
3822 (set_host_charset, set_target_charset): Remove.
3823 (set_host_charset_sfunc, set_target_charset_sfunc): Rewrite.
3824 (set_target_wide_charset_sfunc): New function.
3825 (show_charset): Print target wide character set.
3826 (host_charset, target_charset): Rewrite.
3827 (target_wide_charset): New function.
3828 (c_target_char_has_backslash_escape): Remove.
3829 (c_parse_backslash): Remove.
3830 (host_letter_to_control_character): New function.
3831 (host_char_print_literally): Remove.
3832 (host_hex_value): New function.
3833 (target_char_to_control_char): Remove.
3834 (cleanup_iconv): New function.
3835 (convert_between_encodings): New function.
3836 (target_char_to_host): Remove.
3837 (struct wchar_iterator): Define.
3838 (make_wchar_iterator, make_cleanup_wchar_iterator, wchar_iterator,
3839 wchar_push_back): New functions.
3840 (do_cleanup_iterator): New function.
3841 (char_ptr): New typedef.
3842 (charsets): New global.
3843 (add_one, find_charset_names): New functions.
3844 (default_charset_names): New global.
3845 (auto_host_charset_name): Likewise.
3846 * aclocal.m4, config.in, configure: Rebuild.
3847 * configure.ac: Call AM_LANGINFO_CODESET.
3848 (GDB_DEFAULT_HOST_CHARSET): Default to UTF-8.
3849 (AM_ICONV): Invoke earlier.
3850 * acinclude.m4: Include codeset.m4. Subst LIBICONV_INCLUDE and
3851 LIBICONV_LIBDIR. Check for libiconv in build tree.
3852 * Makefile.in (LIBICONV_LIBDIR, LIBICONV_INCLUDE): New macros.
3853 (INTERNAL_CFLAGS_BASE): Add LIBICONV_INCLUDE.
3854 (INTERNAL_LDFLAGS): Add LIBICONV_LIBDIR.
3855 * gdb_obstack.h (obstack_grow_wstr): New define.
3856 * gdb_wchar.h: New file.
3857 * defs.h: Include it.
3859 2009-03-20 Tom Tromey <tromey@redhat.com>
3860 Jan Kratochvil <jan.kratochvil@redhat.com>
3862 * dwarf2read.c (process_die): Handle DW_TAG_typedef.
3863 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Strip a single
3865 * ada-lang.c (decode_packed_array_type): Call CHECK_TYPEDEF on the
3867 * ada-typeprint.c (print_array_type): Do the NULL check
3870 2009-03-19 Tom Tromey <tromey@redhat.com>
3872 * utils.c (do_obstack_free): New function.
3873 (make_cleanup_obstack_free): Likewise.
3874 * defs.h (make_cleanup_obstack_free): Declare.
3876 2009-03-18 Doug Evans <dje@google.com>
3878 * linux-nat.c (linux_nat_find_memory_regions): Result of PIDGET is an
3879 int, not a long long.
3880 (linux_nat_info_proc_cmd): Store pid in long instead of long long.
3882 * expprint.c (dump_raw_expression): Print note if non-NULL.
3884 * printcmd.c (display_uses_solib_p): Redo loop, scan element list
3887 2009-03-18 Nathan Sidwell <nathan@codesourcery.com>
3889 * Makefile.in: Update license to GPLv3.
3890 * ada-exp.y: Update license to GPLv3.
3891 * ada-lex.l: Update license to GPLv3.
3892 * c-exp.y: Update license to GPLv3.
3893 * cp-name-parser.y: Update license to GPLv3.
3894 * darwin-nat-info.c: Update license to GPLv3.
3895 * f-exp.y: Update license to GPLv3.
3896 * gdb_thread_db.h: Update license to GPLv3.
3897 * hppanbsd-nat.c: Update license to GPLv3.
3898 * hppanbsd-tdep.c: Update license to GPLv3.
3899 * hppaobsd-tdep.c: Update license to GPLv3.
3900 * jv-exp.y: Update license to GPLv3.
3901 * m2-exp.y: Update license to GPLv3.
3902 * objc-exp.y: Update license to GPLv3.
3903 * p-exp.y: Update license to GPLv3.
3904 * reply_mig_hack.awk: Update license to GPLv3.
3905 * reverse.c: Update license to GPLv3.
3906 * xtensa-xtregs.c: Update license to GPLv3.
3908 2009-03-18 Pedro Alves <pedro@codesourcery.com>
3910 * remote.c (remote_close): Don't call generic_mourn_inferior.
3911 (remote_mourn_1): Call generic_mourn_inferior after closing the
3914 2009-03-18 Pedro Alves <pedro@codesourcery.com>
3916 * remote.c (remote_start_remote): Add missing call to
3917 init_wait_for_inferior in non-stop mode.
3919 2009-03-18 Pedro Alves <pedro@codesourcery.com>
3921 * breakpoint.c (bpstat_should_step): Only consider software
3922 watchpoints that have a location.
3924 2009-03-17 Joel Brobecker <brobecker@adacore.com>
3926 Add a target_ops parameter to the to_kill method in struct target_ops.
3928 * target.h (struct target_ops): Add a "target_ops *" parameter to
3930 (target_kill): Remove macro. Add declaration.
3931 * target.c (debug_to_kill): Delete, no longer necessary.
3932 (target_kill): New function.
3933 (update_current_target): Stop inheriting the to_kill method.
3934 Do not de_fault it to no_process either.
3935 (setup_target_debug): Do not set current_target.to_kill.
3936 * gnu-nat.c, go32-nat.c, hpux-thread.c, inf-ptrace.c, inf-ttrace.c,
3937 linux-nat.c, monitor.c, nto-procfs.c, procfs.c, remote-m32r-sdi.c,
3938 remote-mips.c, remote-sim.c, remote.c, windows-nat.c: Update
3941 2009-03-17 Doug Evans <dje@google.com>
3943 * amd64-linux-nat.c (si_timerid,si_overrun): Provide definition for
3944 glibc 2.3.2 and earlier.
3946 2009-03-17 Joel Brobecker <brobecker@adacore.com>
3948 * frame.c (get_prev_frame_1): Do not perform the inner_frame
3949 sanity check if this_frame is not NORMAL.
3950 (frame_id_inner): Update the description of this function.
3952 2009-03-17 Hui Zhu <teawater@gmail.com>
3954 * stack.c: Change the introduce of "disassemble-next-line".
3956 2009-03-17 Pedro Alves <pedro@codesourcery.com>
3958 * mi/mi-main.h (mi_print_timing_maybe): Add strict prototype,
3961 2009-03-17 Hui Zhu <teawater@gmail.com>
3963 * stack.c: Include valprint.h.
3964 (disassemble_next_line): New enum.
3965 (show_disassemble_next_line): New function. Show the current
3966 value of disassemble-next-line.
3967 (gdb_disassembly_stub_args): New struct for argument passing
3968 between function do_gdb_disassembly and function
3969 gdb_disassembly_stub.
3970 (gdb_disassembly_stub): New function. Helper for
3972 (do_gdb_disassembly): New function. Use TRY_CATCH to catch
3973 the exception from the gdb_disassembly because it will be
3974 broken by filter sometime.
3975 (print_frame_info): If disassemble-next-line is set to auto
3976 or on and doesn't have the line debug messages for $pc,
3977 output the next instruction.
3978 If disassemble-next-line is set to on and there is line debug
3979 messages, output assembly codes for next line.
3980 (_initialize_stack): Make the "set disassemble-next-line"
3981 command an auto-boolean command. Change its class to
3982 class_stack. Place it in the top level set list. Extend help
3983 to describe the auto mode.
3985 2009-03-17 Pedro Alves <pedro@codesourcery.com>
3987 * infrun.c (normal_stop): Don't overwrite old_chain.
3989 2009-03-16 Joel Brobecker <brobecker@adacore.com>
3991 * remote-mips.c (mips_load): Replace call to regcache_set_valid_p,
3992 which is undefined, by call to regcache_invalidate, which should
3993 do what the original author wanted to do.
3995 2009-03-16 Joel Brobecker <brobecker@adacore.com>
3997 * remote-mips.c (mips_mourn_inferior): Add missing ops parameter.
3998 (mips_create_inferior): Likewise.
4000 2009-03-16 Joel Brobecker <brobecker@adacore.com>
4002 * go32-nat.c (go32_create_inferior): Add missing ops parameter.
4004 2009-03-16 Joel Brobecker <brobecker@adacore.com>
4006 * darwin-nat.c (darwin_resume): Fix a compiler warning when
4007 building on x86_64-darwin.
4009 2009-03-16 Tristan Gingold <gingold@adacore.com>
4011 * configure.tgt: Add handling for x86_64-darwin.
4013 2009-03-16 Jan Kratochvil <jan.kratochvil@redhat.com>
4015 * auxv.c (fprint_target_auxv): New TAG for AT_RANDOM.
4017 2009-03-15 Joel Brobecker <brobecker@adacore.com>
4019 * aix-thread.c (aix_thread_thread_alive, aix_thread_pid_to_str):
4020 Use the ops parameter to get to the target beneath, rather than
4021 using the current_target global. Using the current_target global
4022 was an unintended accident.
4024 2009-03-15 Joel Brobecker <brobecker@adacore.com>
4026 Fix an error happening while loading symbols from a core file
4029 * rs6000-nat.c (xcoff_relocate_symtab): Use target_has_execution
4030 to detect whether we're debugging a core file or not.
4032 2009-03-15 Joel Brobecker <brobecker@adacore.com>
4034 Modernize the aix-thread later by getting rid of the base_target
4035 global. This brings back to life the AIX port which was otherwise
4036 crashing all the time.
4038 * aix-thread.c (base_target): Delete.
4039 (pd_enable): Do not set base_target.
4040 (aix_thread_attach): Use find_target_beneath instead of base_target.
4041 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
4042 (aix_thread_fetch_registers, aix_thread_store_registers),
4043 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
4044 (aix_thread_thread_alive, aix_thread_pid_to_str): Likewise.
4045 (aix_thread_kill): Delete. Does not seem necessary.
4046 (init_aix_thread_ops): Do not set aix_thread_ops.to_kill.
4048 2009-03-15 Jan Kratochvil <jan.kratochvil@redhat.com>
4050 * stack.c (return_command <retval_exp>): New variables retval_expr
4051 and old_chain. Inline parse_and_eval to initialize retval_expr. Check
4052 RETVAL_EXPR for UNOP_CAST and set RETURN_TYPE to the RETURN_VALUE type
4053 if RETURN_TYPE is NULL.
4055 2009-03-14 Pedro Alves <pedro@codesourcery.com>
4057 * remote.c (PACKET_qAttached): New.
4058 (remote_query_attached): New.
4059 (remote_add_inferior): Add new `attached' argument. Handle it.
4060 (remote_notice_new_inferior, remote_start_remote): Adjust to pass
4061 -1 to remote_add_inferior in new parameter.
4062 (extended_remote_attach_1): Adjust to pass 1 to
4063 remote_add_inferior in the new parameter.
4064 (extended_remote_create_inferior_1): Adjust to pass 0 to
4065 remote_add_inferior in the new parameter.
4066 (_initialize_remote): Add "set/show remote query-attached-packet"
4069 2009-03-13 Tom Tromey <tromey@redhat.com>
4071 * symtab.c (lookup_symbol_in_language): Use a cleanup.
4073 2009-03-13 Doug Evans <dje@google.com>
4075 * exceptions.h: Clean up some comments on catch_exceptions usage.
4076 * exceptions.c: Ditto. Plus mark catch_errors as superseded by
4079 2009-02-17 Joel Brobecker <brobecker@adacore.com>
4081 The following patch helps getting rid of a warning inside solib-som.c.
4083 * source.c (source_full_path_of): Constify parameter filename.
4084 * defs.h (source_full_path_of): Update declaration accordingly.
4086 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4088 * ada-lang.c (ada_evaluate_subexp): Merge case BINOP_REM and
4089 BINOP_MOD cases with the handling of case BINOP_DIV and BINOP_MUL.
4090 Remove useless op value checks when EVAL_AVOID_SIDE_EFFECTS.
4092 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4094 * ada-lang.c (ada_evaluate_subexp) <BINOP_DIV>: make sure to
4095 promote the operands when noside is EVAL_AVOID_SIDE_EFFECTS.
4097 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4099 * ada-tasks.c (ada_task_is_alive): Move up and make static.
4100 * ada-lang.h (ada_task_is_alive): Remove declaration.
4102 2009-03-12 Jerome Guitton <guitton@adacore.com>
4104 * ada-lang.c (ada_delta): Change the type of numerators and
4105 denominators to DOUBLEST, as they may not fit into a long.
4106 (scaling_factor): Ditto.
4108 2009-03-12 Jerome Guitton <guitton@adacore.com>
4110 * language.c (lang_bool_type): Set lai->bool_type_symbol to NULL.
4112 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4114 * ada-lang.c (ada_evaluate_subexp) [OP_VAR_VALUE]: For tagged
4115 types, if we are unable to determine the actual symbol type
4116 from its tag, then use the static approximation instead.
4118 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4120 Fix crash printing packed record with packed array.
4122 * ada-lang.c (ada_modulus_from_name): New function.
4123 (ada_modulus): In the case where the type length is bigger than
4124 the size of the type used to hold the bounds, try determining
4125 the modulus from the type name.
4126 (ada_value_primitive_packed_val): Fix bug in the computation of
4127 ntarg causing an out-of-buffer invalid access.
4129 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4131 Fix segfault when printing short_integer'last.
4133 * ada-lang.c (ada_find_any_type): Search in the primitive types
4134 if a symbol could not be found.
4136 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4138 * ada-tasks.c (task_states,long_task_states): Add new states
4139 Activating and Acceptor_Delay_Sleep. Update the description
4140 of state Acceptor_Sleep.
4142 2009-03-12 Jonas Maebe <jonas.maebe@elis.ugent.be> (obvious change)
4144 Fix a build failure on Darwin following some changes in
4145 the profile of some target_ops methods.
4147 * darwin-nat.c (darwin_kill_inferior): Add target_ops parameter
4149 (darwin_stop_inferior, darwin_detach): Likewise.
4151 2009-03-12 Vladimir Prus <vladimir@codesourcery.com>
4153 Include token in ^running notification for CLI commands.
4155 * mi/mi-main.c (mi_execute_command): Set current_token here.
4156 (mi_cmd_execute): Do not set current_token here.
4158 2009-03-12 Vladimir Prus <vladimir@codesourcery.com>
4162 * mi/mi-main.c (mi_print_timing_maybe): New.
4163 (captured_mi_execute_command): Simplify. Output timings to
4165 (mi_execute_async_cli_command): Do not print timings.
4166 * mi/mi-main.h (mi_print_timing_maybe): Declare.
4167 * mi/mi-interp.c (mi_on_normal_stop): Call mi_print_timing_maybe.
4169 2009-03-12 Jerome Guitton <guitton@adacore.com>
4171 * xcoffread.c (process_linenos): Check if the line in the
4172 include table refers to the main source file and, if so,
4173 add them to the main subfile.
4175 2009-03-12 Joel Brobecker <brobecker@adacore.com>
4177 Fix a build failure on AIX introduced after a change in the profile
4178 of some of the "methods" in the target_ops structure.
4179 * aix-thread.c: Add missing target_ops parameter throughout.
4181 Implement Ada task switching on AIX.
4182 * aix-thread.c (aix_thread_get_ada_task_ptid): New function.
4183 (init_aix_thread_ops): Set aix_thread_ops.to_get_ada_task_ptid.
4185 2009-03-11 Daniel Jacobowitz <dan@codesourcery.com>
4187 * breakpoint.c (bpstat_check_breakpoint_conditions): Use
4188 value_mark and value_free_to_mark.
4189 * objfiles.c (free_objfile): Call objfile_free_data before
4192 2009-03-10 Hui Zhu <teawater@gmail.com>
4194 * disasm.c (gdb_disassembly): Remove unused argument
4196 * disasm.h (gdb_disassembly): Ditto.
4197 * cli/cli-cmds.c (print_disassembly): Ditto.
4198 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Ditto.
4200 2009-03-09 Paul Pluzhnikov <ppluzhnikov@google.com>
4202 * solib.c (solib_contains_address_p): New function.
4203 (solib_name_from_address): Use it.
4204 * printcmd.c (display_uses_solib_p): Use it.
4205 * solib.h (solib_contains_address_p): Declare it.
4207 2009-03-09 Jan Kratochvil <jan.kratochvil@redhat.com>
4209 * varobj.c (free_variable): Call value_free.
4211 2009-03-09 Jan Kratochvil <jan.kratochvil@redhat.com>
4214 * dwarf2read.c (dwarf_decode_macros): New variable `at_commandline'.
4215 Move the variable `macinfo_type' out of the loop. Create a new
4216 processing pass before the current one to pre-create `current_file'.
4217 New complaint on misplaced zero/non-zero definitions/includes.
4218 Skip first DW_MACINFO_start_file with `at_commandline' set.
4220 2008-03-09 Vladimir Prus <vladimir@codesourcery.com>
4222 * solib.c (reload_shared_libraries): Give
4223 inferior a chance to reset solib breakpoint.
4226 2009-03-08 Christopher Faylor <me+cygwin@cgf.cx>
4228 * windows-nat.c (dr): Redefine to use largest possible integer which
4230 (cygwin_set_dr): Avoid coercion.
4232 2009-03-08 Oswald Buddenhagen <oswald.buddenhagen@trolltech.de>
4234 * windows-nat.c (windows_create_inferior): Implement --tty handling on
4237 2009-03-06 Paul Pluzhnikov <ppluzhnikov@google.com>
4239 Rename solib_address to solib_name_from_address.
4240 * breakpoint.c (insert_bp_location, disable_breakpoints_in_shlibs)
4241 (disable_breakpoints_in_unloaded_shlib): Update.
4242 * printcmd.c (display_uses_solib_p): Likewise.
4243 * stack.c (print_frame): Likewise.
4247 2009-03-05 Paul Pluzhnikov <ppluzhnikov@google.com>
4249 * printcmd.c (do_one_display): Reparse exp_string.
4250 (display_uses_solib_p): New function.
4251 (clear_dangling_display_expressions): New function.
4252 (_initialize_printcmd): Add observer.
4253 * solib.c (no_shared_libraries): Swap order of calls to
4254 clear_solib and objfile_purge_solibs.
4256 2009-03-05 Joel Brobecker <brobecker@adacore.com>
4258 Implement the target-specific part of Ada tasking support
4261 * dec-thread.c (dec_thread_get_ada_task_ptid): New function.
4262 (init_dec_thread_ops): Set the to_get_ada_task_ptid method.
4264 2009-03-05 Joel Brobecker <brobecker@adacore.com>
4266 Get rid of the global "base_target" and use "find_target_beneath"
4267 to find the underlying target.
4268 * dec-thread.c (base_target): Delete.
4269 (enable_dec_thread): Remove assignement to base_target.
4270 (dec_thread_detach, dec_thread_wait, dec_thread_wait)
4271 (dec_thread_fetch_registers, dec_thread_store_registers)
4272 (dec_thread_mourn_inferior, dec_thread_pid_to_str):
4273 Update the function profile if necessary.
4274 Use find_target_beneath to call the same method but from
4275 the underlying target, removing the need for "base_target".
4277 * dec-thread.c (dec_thread_get_regsets, dec_thread_set_regsets):
4278 Fix a copy/paste error in a few debug traces...
4280 * solib-osf.c (init_so): Use a simpler method for computing
4281 the size of lm_info structure. This also gets rid of warning
4282 emitted by the compiler.
4284 2009-03-05 Pedro Alves <pedro@codesourcery.com>
4286 * breakpoint.c (check_duplicates_for): Skip permanent breakpoints
4287 duplicates of permanent breakpoints.
4289 2009-03-04 Pedro Alves <pedro@codesourcery.com>
4291 * inferior.h (notice_new_inferior): Declare.
4292 * infcmd.c (notice_new_inferior): New.
4293 * remote.c (remote_add_inferior, remote_add_thread): New.
4294 (notice_new_inferiors): Rename to...
4295 (remote_notice_new_inferior): ... this. Add RUNNING argument.
4296 Use remote_add_thread instead of add_thread, passing it the
4297 RUNNING argument. Add an inferior with remote_add_inferior. If
4298 we just learned about an inferior, call notice_new_inferior.
4299 (record_currthread): Adjust.
4300 (remote_threads_info): Adjust to use remote_notice_new_inferior.
4301 (remote_start_remote, extended_remote_attach_1): Use
4302 remote_add_inferior.
4303 (process_stop_reply): Adjust. Call remote_notice_new_inferior
4304 after handling expedited registers and watchpoint state.
4305 (extended_remote_create_inferior_1): Use remote_add_inferior.
4307 2009-03-04 Aleksandar Ristovski <aristovski@qnx.com>
4309 * infcmd.c (registers_info): Remove register number case.
4311 2009-03-03 Pedro Alves <pedro@codesourcery.com>
4313 * top.c (quit_target): Check for target_has_execution before
4314 killing or detaching from inferiors.
4316 2009-03-02 Joel Brobecker <brobecker@adacore.com>
4318 Remove some unused routines.
4320 * ada-lang.c (is_suppressed_name, ada_suppress_symbol_printing):
4322 * ada-lang.c (ada_task_list_iterator_ftype)
4323 (iterate_over_live_ada_tasks): Delete.
4324 * ada-tasks.c (ada_get_environment_task, iterate_over_live_ada_tasks):
4327 2009-03-01 Doug Evans <dje@google.com>
4329 * symtab.c: Remove trailing whitespace throughout the file.
4330 (expand_line_sal): Fix some typos and whitespace.
4332 * Makefile.in (clean): rm -f $(DEPDIR)/*.
4334 * Makefile.in (GDB_CFLAGS): Add -I$(srcdir)/common.
4335 (init.c): signals/ -> common/.
4336 (signals.o): Update.
4337 * target.h (target_signal_to_string,target_signal_to_string)
4338 (target_signal_from_name,target_signal_to_host_p)
4339 (target_signal_from_host,target_signal_to_host): Move to ...
4340 * common/gdb_signals.h: ... here. New file.
4341 * common/signals.c: Moved here from signals/signals.c.
4342 #include gdb_signals.h, remove #include of target.h in gdb case.
4343 (target_signal_from_command,default_target_signal_to_host)
4344 (default_target_signal_from_host): Move inside #ifndef GDBSERVER.
4346 Include thread ID in target_wait debugging output.
4347 * infrun.c (print_target_wait_results): New function.
4348 (wait_for_inferior,fetch_inferior_event): Call it.
4350 2009-02-27 Pedro Alves <pedro@codesourcery.com>
4352 * gdb_proc_service.h (struct ps_prochandle): Replace pid_t field
4353 with a ptid_t field.
4354 * linux-thread-db.c (thread_get_info_callback): Build the ptid
4355 using the pid stored in proc_handle.ptid.
4356 (thread_from_lwp, thread_db_attach_lwp, enable_thread_event)
4357 (check_for_thread_db, thread_db_detach, check_event)
4358 (thread_db_mourn_inferior, find_new_threads_callback)
4359 (thread_db_find_new_threads_1): Adjust.
4360 * proc-service.c (ps_xfer_memory, ps_lgetregs, ps_lsetregs)
4361 (ps_lgetfpregs, ps_lsetfpregs, ps_getpid): Adjust.
4363 2009-02-27 Phil Muldoon <pmuldoon@redhat.com>
4365 * valprint.c (read_string): Rework clean-up logic. Use
4366 free_current_contents to clean-up buffer.
4368 2009-02-27 Andreas Schwab <schwab@linux-m68k.org>
4370 * MAINTAINERS: Update e-mail address.
4372 2009-02-26 Phil Muldoon <pmuldoon@redhat.com>
4374 * python/python-utils.c (python_string_to_unicode): Always return
4376 (python_string_to_target_string): Decrement transient python
4378 (python_string_to_host_string): Likewise.
4380 2007-02-26 Pedro Alves <pedro@codesourcery.com>
4382 * mips-linux-nat.c (mips64_linux_fetch_registers): Pass `ops' to
4383 call to super_fetch_registers.
4384 (mips64_linux_store_registers): Pass `ops' to call to
4385 super_store_registers.
4387 2009-02-25 Doug Evans <dje@google.com>
4389 * breakpoint.c (insert_bp_location): Add \n to overlay breakpoint
4392 * breakpoint.c (disable_breakpoints_in_shlibs): Delete local
4393 disabled_shlib_breaks, unused.
4395 * printcmd.c (build_address_symbolic): Fix comment.
4397 2009-02-25 Hui Zhu <teawater@gmail.com>
4399 * cli/cli-script.c (define_command): Add _() to query.
4400 * gnu-nat.c (inf_validate_task_sc): Ditto.
4401 * infcmd.c (kill_if_already_running): Ditto.
4402 (jump_command): Ditto.
4403 (attach_command): Ditto.
4404 * inflow.c (kill_command): Ditto.
4405 * infrun.c (handle_command): Ditto.
4406 * maint.c (maintenance_dump_me): Ditto.
4407 * memattr.c (mem_delete_command): Ditto.
4408 * monitor.c (monitor_interrupt_query): Ditto.
4409 * nto-procfs.c (interrupt_query): Ditto.
4410 * printcmd.c (undisplay_command): Ditto.
4411 * remote-mips.c (mips_kill): Ditto.
4412 * remote.c (interrupt_query): Ditto.
4413 * solib-irix.c (irix_open_symbol_file_object): Ditto.
4414 * solib-osf.c (osf_open_symbol_file_object): Ditto.
4415 * solib-pa64.c (pa64_open_symbol_file_object): Ditto.
4416 * solib-som.c (som_open_symbol_file_object): Ditto.
4417 * solib-svr4.c (open_symbol_file_object): Ditto.
4418 * symfile.c (symbol_file_add_with_addrs_or_offsets): Ditto.
4419 * target.c (kill_or_be_killed): Ditto.
4420 * tracepoint.c (delete_trace_command): Ditto.
4421 * top.c (quit_confirm): Add _() to s that will be used
4424 2009-02-24 Pierre Muller <muller@ics.u-strasbg.fr>
4426 Fix windows-nat.c compilation failure.
4428 * windows-nat.c (windows_thread_alive): Fix forward declaration.
4429 (get_windows_debug_event): Add ops parameter to call to windows_resume.
4431 2009-02-23 Pedro Alves <pedro@codesourcery.com>
4433 * remote-sim.c (gdbsim_resume): Add target_ops* argument.
4435 2009-02-23 Jay Krell <jay.krell@cornell.edu> (tiny change)
4437 * symtab.c (find_line_symtab): Initialize exact to avoid
4440 2009-02-23 Pedro Alves <pedro@codesourcery.com>
4442 * i386-linux-nat.c (i386_linux_fetch_inferior_registers): Pass
4443 `ops' to recursive call.
4445 2009-02-23 Pedro Alves <pedro@codesourcery.com>
4447 * corelow.c (get_core_registers): Adjust.
4448 (core_file_thread_alive): Rename to...
4449 (core_thread_alive): ... this.
4450 (core_pid_to_str): Try gdbarch_core_pid_to_str first.
4451 (init_core_ops): Adjust.
4452 (coreops_suppress_target): Delete.
4453 (_initialize_corelow): Unconditionally add core_ops.
4454 * procfs.c: Include "inf-child.h".
4455 (procfs_ops): Delete.
4456 (init_procfs_ops): Delete. Reimplement as...
4457 (procfs_target): ... this, inheriting from inf-child.
4458 (procfs_attach, procfs_detach, procfs_fetch_registers): Adjust.
4459 (procfs_prepare_to_store): Delete.
4460 (procfs_store_registers, procfs_resume): Adjust.
4461 (procfs_open): Delete.
4462 (procfs_suppress_run): Delete.
4463 (procfs_can_run): Delete.
4464 (procfs_mourn_inferior): Adjust.
4465 (procfs_init_inferior): Add target_ops parameter. Adjust.
4466 (procfs_create_inferior): Don't pass procfs_init_inferior to
4467 fork_inferior. Instead call it after fork_inferior returns.
4468 (procfs_find_new_threads): Adjust.
4469 (_initialize_procfs): Adjust to use procfs_target instead of
4471 * sol-thread.c (orig_core_ops, sol_core_ops): Delete.
4472 (lwp_to_thread): Use target_thread_alive.
4473 (sol_thread_open): Delete.
4474 (sol_thread_attach): Delete.
4475 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
4476 (sol_thread_fetch_registers, sol_thread_store_registers): Adjust
4477 to use find_target_beneath.
4478 (sol_thread_prepare_to_store, sol_thread_xfer_memory): Delete.
4479 (sol_thread_xfer_partial): Adjust to use find_target_beneath.
4480 (sol_thread_files_info, sol_thread_kill_inferior): Delete.
4481 (check_for_thread_db): New.
4482 (sol_thread_notice_signals, sol_thread_create_inferior): Delete.
4483 (sol_thread_new_objfile): Call check_for_thread_db.
4484 (sol_thread_mourn_inferior): Adjust to use find_target_beneath.
4485 (sol_thread_can_run): Delete.
4486 (sol_thread_alive): Adjust to use find_target_beneath.
4487 (sol_thread_stop): Delete.
4488 (rw_common): Use target_write_memory or target_read_memory.
4489 (ps_lgetregs, ps_lgetfpregs): Use target_fetch_registers.
4490 (ps_lsetregs, ps_lsetfpregs): Use target_store_registers.
4491 (solaris_pid_to_str): Remove check for libthread_db initialization
4493 (sol_find_new_threads): Remove check for libthread_db
4494 initialization failing, or for an invalid inferior_ptid. Adjust
4495 to use find_target_beneath.
4496 (sol_core_open, sol_core_close, sol_core_detach,
4497 sol_core_files_info, sol_find_memory_regions,
4498 sol_make_note_section, ignore): Delete.
4499 (init_sol_thread_ops): Make it a thread_stratum target. Remove
4500 unneeded callback settings.
4501 (init_sol_core_ops): Delete.
4502 (_initialize_sol_thread): No longer call init_sol_core_ops, set
4503 procfs_suppress_run, or hack with core_ops.
4505 * target.h (struct target_ops): Add a target_ops * parameter to
4506 to_resume, to_fetch_registers, to_store_registers, to_thread_alive
4507 and to_find_new_threads.
4508 (target_fetch_registers, target_store_registers)
4509 (target_thread_alive, target_find_new_threads): Redeclare as
4512 * target.c (update_current_target): Do not inherit or de_fault
4513 to_resume, to_fetch_registers, to_store_registers,
4514 to_thread_alive, to_find_new_threads.
4515 (target_resume): Adjust.
4516 (target_thread_alive, target_find_new_threads): New.
4517 (debug_to_resume, debug_to_fetch_registers): Delete.
4518 (target_fetch_registers): New.
4519 (debug_to_store_registers): Delete.
4520 (target_store_registers): New.
4521 (debug_to_thread_alive, debug_to_find_new_threads): Delete.
4522 (setup_target_debug): Adjust.
4524 * gdbcore.h (core_ops): Delete declaration.
4526 * inf-ptrace.c, linux-nat.c, remote.c, amd64-linux-nat.c,
4527 inf-child.c, linux-thread-db.c, bsd-uthread.c, inf-ttrace.c,
4528 i386-sol2-tdep.c, darwin-nat.c, gnu-nat.c, go32-nat.c,
4529 hpux-thread.c, i386-linux-nat.c, i386fbsd-nat.c, monitor.c,
4530 nto-procfs.c, remote-m32r-sdi.c, remote-mips.c, windows-nat.c,
4531 alphabsd-nat.c, amd64bsd-nat.c, arm-linux-nat.c, armnbsd-nat.c,
4532 bsd-kvm.c, hppa-hpux-nat.c, hppa-linux-nat.c, hppabsd-nat.c,
4533 hppanbsd-nat.c, i386-darwin-nat.c, i386bsd-nat.c,
4534 ia64-linux-nat.c, m32r-linux-nat.c, m68kbsd-nat.c,
4535 m68klinux-nat.c, m88kbsd-nat.c, mips-linux-nat.c,
4536 mips64obsd-nat.c, mipsnbsd-nat.c, ppc-linux-nat.c, ppcnbsd-nat.c,
4537 ppcobsd-nat.c, remote-sim.c, rs6000-nat.c, s390-nat.c,
4538 shnbsd-nat.c, sparc-nat.c, sparc-nat.h, spu-linux-nat.c,
4539 vaxbsd-nat.c, xtensa-linux-nat.c: Adjust to target_ops changes.
4541 * gdbarch.sh (core_pid_to_str): New gdbarch callback.
4542 * gdbarch.h, gdbarch.c: Regenerate.
4544 * sol2-tdep.c: Include "inferior.h".
4545 (sol2_core_pid_to_str): New.
4546 * sol2-tdep.h (sol2_core_pid_to_str): Declare.
4548 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Set it.
4549 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Set it.
4550 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Set it.
4551 * i386-sol2-tdep.c (i386_sol2_init_abi): Set it.
4553 2009-02-22 Doug Evans <dje@google.com>
4555 * exec.c (exec_file_attach): Fix comment.
4557 2009-02-22 Pedro Alves <pedro@codesourcery.com>
4559 Silence a few -Wmissing-prototypes warnings.
4562 * alpha-linux-tdep.c (alpha_linux_regset_from_core_section): Make
4564 * alpha-osf1-tdep.c (_initialize_alpha_osf1_tdep): Declare.
4565 * amd64fbsd-tdep.c (amd64fbsd_init_abi): Make it static.
4566 * amd64nbsd-tdep.c (_initialize_amd64nbsd_ndep): Rename to ...
4567 (_initialize_amd64nbsd_tdep): ... this.
4568 * arm-linux-tdep.c (arm_linux_software_single_step): Make it static.
4569 (_initialize_arm_linux_tdep): Declare.
4570 * armbsd-tdep.c (armbsd_fpreg_offset): Make it static.
4571 * armnbsd-tdep.c (_initialize_arm_netbsd_tdep): Declare.
4572 * armobsd-tdep.c (_initialize_armobsd_tdep): Declare.
4573 * avr-tdep.c (avr_return_value): Make it static.
4574 (avr_frame_unwind_cache): Ditto.
4575 * bsd-uthread.c (bsd_uthread_inferior_created): Ditto.
4576 (bsd_uthread_solib_loaded): Ditto.
4577 (bsd_uthread_solib_unloaded): Ditto.
4578 (bsd_uthread_target): Ditto.
4579 (_initialize_bsd_uthread): Declare.
4580 * cris-tdep.c (crisv32_single_step_through_delay): Make it static.
4581 (cris_frame_unwind_cache): Ditto.
4582 * frv-tdep.c (frv_return_value): Ditto.
4583 * h8300-tdep.c (h8300_use_struct_convention): Ditto.
4584 (h8300h_use_struct_convention): Ditto.
4585 * hppa-tdep.c (hppa_sign_extend, hppa_low_hppa_sign_extend):
4587 * hppa-tdep.h (hppa_low_sign_extend, hppa_sign_extend): Delete
4589 * hppabsd-tdep.c: Include hppabsd-tdep.h.
4590 (hppabsd_find_global_pointer): Make it static.
4591 * hppabsd-tdep.h: New.
4592 * hppanbsd-tdep.c: Include hppabsd-tdep.h.
4593 (hppabsd_init_abi): Remove declaration.
4594 (_initialize_hppabsd_tdep): Remove declaration.
4595 (_initialize_hppanbsd_tdep): Declare.
4596 * hppaobsd-tdep.c: Include hppabsd-tdep.h.
4597 (hppabsd_init_abi): Delete declaration.
4598 (hppaobsd_init_abi): Make it static.
4599 * i386-nto-tdep.c (_initialize_i386nto_tdep): Declare.
4600 * i386nbsd-tdep.c (_initialize_i386nbsd_tdep): Declare.
4601 * ia64-linux-tdep.c (_initialize_ia64_linux_tdep): Declare.
4602 * ia64-tdep.c (ia64_register_reggroup_p): Make it static.
4603 * iq2000-tdep.c (_initialize_iq2000_tdep): Declare.
4604 * m32c-tdep.c (m32c_register_reggroup_p): Make it static.
4605 (m32c_analyze_prologue, m32c_virtual_frame_pointer): Ditto.
4606 (_initialize_m32c_tdep): Declare.
4607 * m32r-rom.c (_initialize_m32r_rom): Declare.
4608 * m32r-tdep.c (m32r_skip_prologue): Make it static.
4609 (m32r_return_value): Ditto.
4610 * m68hc11-tdep.c (m68hc11_frame_unwind_cache): Make it static.
4611 (m68hc11_return_value): Ditto.
4612 * m68klinux-tdep.c (_initialize_m68k_linux_tdep): Declare.
4613 * m88k-tdep.c (m88k_frame_cache): Make it static.
4614 * mep-tdep.c (mep_gdb_print_insn): Ditto.
4615 (mep_return_value): Ditto.
4616 (_initialize_mep_tdep): Declare.
4617 * mips-irix-tdep.c (_initialize_mips_irix_tdep): Declare.
4618 * mips-linux-tdep.c (supply_64bit_reg): Make it static.
4619 (mips_linux_syscall_next_pc): Ditto.
4620 (_initialize_mips_linux_tdep): Declare.
4621 * mips-tdep.c (mips_single_step_through_delay): Make it static.
4622 * mipsnbsd-tdep.c (_initialize_mipsnbsd_tdep): Declare.
4623 * mn10300-linux-tdep.c (_initialize_mn10300_linux_tdep): Declare.
4624 * mn10300-tdep.c (_initialize_mn10300_tdep): Declare.
4625 * mt-tdep.c (_initialize_mt_tdep): Declare.
4626 * nbsd-tdep.c: Include nbsd-tdep.h.
4627 * nto-tdep.c (find_load_phdr): Make it static.
4628 (_initialize_nto_tdep): Declare.
4629 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Make it
4631 (_initialize_ppc_linux_tdep): Declare.
4632 * remote-m32r-sdi.c (m32r_can_use_hw_watchpoint)
4633 (m32r_insert_watchpoint, m32r_remove_watchpoint)
4634 (m32r_stopped_data_address, m32r_stopped_by_watchpoint): Make
4636 * rs6000-aix-tdep.c (_initialize_rs6000_aix_tdep): Declare.
4637 * rs6000-nat.c: Include xcoffread.h.
4638 (find_toc_address): Don't extern declare get_toc_offset. Adjust
4639 to call xcoff_get_to_offset.
4640 * rs6000-tdep.c (ppc_vsx_support_p, ppc_displaced_step_fixup)
4641 (rs6000_skip_main_prologue, rs6000_in_solib_return_trampoline)
4642 (rs6000_skip_trampoline_code): Make static.
4643 * s390-tdep.c (s390_regset_from_core_section): Ditto.
4644 * sh-tdep.c (sh_register_reggroup_p): Ditto.
4645 * shnbsd-tdep.c (shnbsd_regset_from_core_section): Ditto.
4646 (_initialize_shnbsd_tdep): Declare.
4647 * solib-frv.c (displacement_from_map): Make static.
4648 (_initialize_frv_solib): Declare.
4649 * solib-irix.c (fetch_lm_info): Make static.
4650 (_initialize_irix_solib): Declare.
4651 * solib-som.c: Include solib-som.h.
4652 (som_solib_select): Line break.
4653 * sparc-tdep.c (sparc_regset_from_core_section): Make static.
4654 * sparcnbsd-tdep.c (_initialize_sparnbsd_tdep): Rename to ...
4655 (_initialize_sparcnbsd_tdep): ... this.
4656 * spu-tdep.c (spu_software_single_step): Make it static.
4657 (_initialize_spu_tdep): Declare.
4658 * vax-tdep.c (vax_frame_cache): Make it static.
4659 * xcoffread.c: Include xcoffread.h.
4660 (get_toc_offset): Rename to ...
4661 (xcoff_get_toc_offset): ... this.
4662 (_initialize_xcoffread): Declare.
4664 * xtensa-linux-tdep.c (_initialize_xtensa_linux_tdep): Declare.
4665 * xtensa-tdep.c (xtensa_skip_prologue, xtensa_derive_tdep): Make
4667 (_initialize_xtensa_tdep): Declare.
4669 2008-02-21 Pedro Alves <pedro@codesorcery.com>
4671 Silence a few -Wmissing-prototypes warnings.
4674 * amd64-nat.c: Include "amd64-nat.h".
4675 * fork-child.c (_initialize_fork_child): Ditto.
4676 * gcore.c (_initialize_gcore): Ditto.
4677 * inf-ptrace.c: Include "inf-ptrace.h".
4678 (inf_ptrace_store_registers): Make it static.
4679 * linux-nat.c (linux_nat_terminal_ours): Make it static.
4680 (_initialize_linux_nat): Declare before definition.
4681 * linux-tdep.c: Include "linux-tdep.h".
4682 * linux-thread-db.c (_initialize_thread_db): Declare before
4684 * proc-service.c (_initialize_proc_service): Ditto.
4685 * remote.c (remote_send_printf): Make it static.
4686 * solib.c: Include "solib.h".
4687 * symfile-mem.c (_initialize_symfile_mem): Declare before
4689 * ada-lang.c (ada_la_decode, ada_match_name)
4690 (ada_suppress_symbol_printing, ada_is_array_type)
4691 (ada_value_ptr_subscript, ada_array_length)
4692 (ada_to_static_fixed_value): Make them static.
4693 (_initialize_ada_language): Declare before definition.
4694 * ada-tasks.c (ada_get_task_number, ada_get_environment_task)
4695 (ada_task_list_changed, ada_new_objfile_observer): Make them
4697 (_initialize_tasks): Declare before definition.
4698 * addrmap.c (_initialize_addrmap): Declare before definition.
4699 * auxv.c (default_auxv_parse): Make it static.
4700 * bfd-target.c (target_bfd_xfer_partial, target_bfd_xclose): Make
4702 * breakpoint.c (remove_sal): Add line break.
4703 (expand_line_sal_maybe): Make it static.
4704 * cp-name-parser.y: Include "cp-support.h".
4705 * cp-valprint.c (cp_find_class_member): Make it static.
4706 * eval.c (value_f90_subarray): Ditto.
4707 * exceptions.c (print_any_exception): Ditto.
4708 * findcmd.c (_initialize_mem_search): Declare before definition.
4709 * frame.c (frame_observer_target_changed): Make it static.
4710 * gnu-v3-abi.c (gnuv3_find_method_in): Make it static.
4711 * inf-child.c: Include "inf-child.h".
4712 * inferior.h (valid_inferior_id): Rename to ...
4713 (valid_gdb_inferior_id): ... this.
4714 * infrun.c (infrun_thread_stop_requested, siginfo_make_value):
4716 * jv-lang.c (java_language_arch_info): Make it static.
4717 * m2-typeprint.c (m2_get_discrete_bounds): Ditto.
4718 * osdata.c (info_osdata_command): Make it static.
4719 * regcache.c (regcache_observer_target_changed): Make it static.
4720 * reverse.c (_initialize_reverse): Declare before definition.
4721 * stabsread.c (cleanup_undefined_types_noname)
4722 (cleanup_undefined_types_1): Make them static.
4723 * symfile.c (place_section): Make it static.
4724 * symtab.c (find_pc_sect_psymtab_closer): Make it static.
4725 * target-descriptions.c (_initialize_target_descriptions): Declare
4727 * target.c (default_get_ada_task_ptid, find_default_can_async_p)
4728 (find_default_is_async_p, find_default_supports_non_stop): Make
4730 (target_supports_non_stop): Add prototype.
4731 (dummy_pid_to_str): Make it static.
4732 * utils.c (_initialize_utils): Declare before definition.
4733 * ada-exp.y (_initialize_ada_exp): Declare before definition.
4734 * solib-svr4.c (HAS_LM_DYNAMIC_FROM_LINK_MAP): Add a prototype.
4735 * target.h (struct target_ops): Add a prototype to the
4736 to_can_execute_reverse callback.
4737 * macroscope.c (_initialize_macroscope): Declare before definition.
4738 * cp-namespace.c (_initialize_cp_namespace): Declare before definition.
4739 * python/python.c (_initialize_python): Declare before definition.
4740 * tui/tui-command.c: Include "tui/tui-command.h".
4741 * tui/tui-data.c (init_content_element, init_win_info): Make them
4743 * tui/tui-disasm.c: Include "tui/tui-disasm.h".
4744 * tui/tui-interp.c (_initialize_tui_interp): Declare before
4746 * tui/tui-layout.c: Include "tui/tui-layout.h".
4747 (_initialize_tui_layout): Declare before definition.
4748 * tui/tui-regs.c: Include "tui/tui-regs.h".
4749 (tui_display_reg_element_at_line): Make it static.
4750 (_initialize_tui_regs): Declare before definition.
4751 * tui/tui-stack.c (_initialize_tui_stack): Declare before
4753 * tui/tui-win.c: Include "tui/tui-win.h".
4754 (_initialize_tui_win): Declare before definition.
4755 (tui_sigwinch_handler): Make it static. Wrap in ifdef SIGWINCH.
4756 * tui/tui-win.h (tui_sigwinch_handler): Delete declaration.
4757 (tui_get_cmd_list): Add a prototype.
4758 * tui/tui-windata.c: Include tui-windata.h.
4759 * tui/tui-wingeneral.c (box_win): Make it static.
4760 * cli/cli-logging.c (show_logging_command): Make it static.
4761 (_initialize_cli_logging): Declare before definition.
4762 * mi/mi-common.c (_initialize_gdb_mi_common): Declare before
4765 2009-02-20 Pierre Muller <muller@ics.u-strasbg.fr>
4767 Extend use of i386_use_watchpoints to all i386 native files
4768 using hardware watchpoints.
4769 * go32-nat.c (init_go32_ops): Call i386_use_watchpoints.
4770 * i386fbsd-nat.c (_initialize_i386fbsd_nat): Ditto.
4771 * windows-nat.c (init_windows_ops): Ditto.
4772 * config/i386/nm-cygwin.h: Define I386_WATCHPOINTS_IN_TARGET_VECTOR.
4773 * config/i386/nm-cygwin64.h: Ditto.
4774 * config/i386/nm-fbsd.h: Ditto.
4775 * config/i386/nm-go32.h: Ditto.
4777 2009-02-19 Joel Brobecker <brobecker@adacore.com>
4779 * ada-typeprint.c (ada_typedef_print): Remove. Unused.
4781 2009-02-18 Vladimir Prus <vladimir@codesourcery.com>
4783 * mi/mi-interp.c (mi_solib_loaded, mi_solib_unloaded): New.
4784 (mi_interpreter_init): Register the above.
4785 * solib.c (clear_solib): Notify solib unload.
4786 * breakpoint.c (disable_breakpoints_in_unloaded_shlib): Do not
4787 disable breakpoints on a.out targets.
4789 2009-02-17 Vladimir Prus <vladimir@codesourcery.com>
4791 * observer.c (observer_test_first_notification_function)
4792 (observer_test_second_notification_function)
4793 (observer_test_third_notification_function): Adjust prototype.
4795 2009-02-17 Pedro Alves <pedro@codesourcery.com>
4797 * Makefile.in (ALL_64_TARGET_OBS): Add amd64-dicos-tdep.o.
4798 (ALL_TARGET_OBS): Add dicos-tdep.o.
4799 (ALLDEPFILES): Add amd64-dicos-tdep.c and dicos-tdep.c.
4800 * configure.tgt (i[34567]86-*-dicos*): Add dicos-tdep.o to
4802 (x86_64-*-dicos*): Add dicos-tdep.o and amd64-dicos-tdep.o to
4804 * dicos-tdep.h, dicos-tdep.c: New.
4805 * amd64-dicos-tdep.c: New.
4806 * i386-dicos-tdep.c: Don't include solib.h, solib-target.h or
4807 inferior.h. Include dicos-tdep.h.
4808 (i386_dicos_init_abi): Call dicos_init_abi.
4809 (i386_dicos_bfd_has_symbol_p): Delete.
4810 (i386_dicos_osabi_sniffer): Use dicos_load_module_p.
4812 * NEWS: Mention x86-64 DICOS target support.
4814 2009-02-16 Doug Evans <dje@google.com>
4816 * amd64-tdep.c (amd64_skip_prefixes): Renamed from skip_prefixes.
4817 All callers updated.
4818 (amd64_get_insn_details): Handle more 3-byte opcode insns.
4819 (amd64_breakpoint_p): Delete.
4820 (amd64_displaced_step_fixup): When fixing up after stepping an int3,
4821 don't back up pc to the start of the int3.
4822 * i386-tdep.c: #include opcode/i386.h.
4823 (i386_skip_prefixes): New function.
4824 (i386_absolute_jmp_p): Constify argument.
4825 (i386_absolute_call_p,i386_ret_p,i386_call_p,i386_syscall_p): Ditto.
4826 (i386_breakpoint_p): Delete.
4827 (i386_displaced_step_fixup): Handle unnecessary or redundant prefixes.
4828 When fixing up after stepping an int3, don't back up pc to the start
4831 2009-02-16 Pedro Alves <pedro@codesourcery.com>
4833 * corelow.c (core_close): Don't hardcode the core's pid.
4834 (core_open): Find core threads before calling
4835 post_create_inferior.
4836 (add_to_thread_list, get_core_register_section): Take into account
4837 systems where the regset section names encode the pid of the
4840 * gdbarch.sh (core_reg_section_encodes_pid): New gdbarch setting.
4841 * gdbarch.h, gdbarch.c: Regenerate.
4843 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Set it.
4844 * i386-sol2-tdep.c (i386_sol2_init_abi): Set it.
4845 * sparc-sol2-tdep.c (sparc32_sol2_init_abi): Set it.
4846 * sparc64-sol2-tdep.c (sparc64_sol2_init_abi): Set it.
4848 2009-02-14 Vladimir Prus <vladimir@codesourcery.com>
4850 Include frame information for *stopped due to CLI commands.
4852 * ada-tasks.c (ada_normal_stop_observer): Adjust prototype.
4853 * infcmd.c (finish_command_continuation): Pass '1' for
4854 'print_frame' parameter to the observer.
4855 * infrun.c (normal_stop): Don't print mi-specific information
4856 here. Pass 'stop_print_frame' to the 'print_frame' parameter
4858 * mi/mi-interp.c (mi_on_normal_stop): Adjust prototype.
4859 If we need to print frame, and current uiout is not the MI one,
4862 2009-02-13 Pierre Muller <muller@ics.u-strasbg.fr>
4864 * xtensa-tdep.c (call0_analyze_prologue): Delete BSZ macro.
4865 Replace BSZ macro uses by XTENSA_ISA_BSZ macro.
4867 2009-02-12 Jan Kratochvil <jan.kratochvil@redhat.com>
4870 * dwarf2read.c (process_die <DW_TAG_module>, read_module)
4871 (scan_partial_symbols <DW_TAG_module>, add_partial_module): New.
4873 2009-02-11 Pierre Muller <muller@ics.u-strasbg.fr>
4875 * dwarf2read.c (read_base_type): Set code to TYPE_CODE_CHAR
4876 for DW_ATE_signed_char and DW_ATE_unsigned_char
4877 for pascal language.
4879 2009-02-11 Jim Meyering <meyering@redhat.com>
4880 Jan Kratochvil <jan.kratochvil@redhat.com>
4882 Avoid NULL dereference.
4883 * stack.c (return_command): Guard use of SYMBOL_TYPE (thisfun).
4884 New variable func_type.
4886 2009-02-11 Pedro Alves <pedro@codesourcery.com>
4888 * gdbarch.c: Regenerate.
4890 2009-02-10 Pierre Muller <muller@ics.u-strasbg.fr>
4892 * p-lang.c (is_pascal_string_type): Fix comment.
4893 Determine exact size of char elements for GPC
4895 (pascal_printstr): Handle char width of 2 or 4.
4896 * p-valprint.c (pascal_val_print): Handle char
4899 2009-02-07 Daniel Jacobowitz <dan@codesourcery.com>
4901 * dwarf2read.c (dwarf2_build_psymtabs_hard): Move lowpc and highpc
4902 inside the loop. Only call addrmap_set_empty if the compilation unit
4903 had DW_AT_high_pc and DW_AT_low_pc. Update call to
4904 scan_partial_symbols.
4905 (scan_partial_symbols): Take NEED_PC argument and pass it along with
4907 (add_partial_namespace): Take NEED_PC argument and pass it through.
4908 (add_partial_subprogram): Take NEED_PC argument. Update the addrmap
4911 2009-02-07 Pedro Alves <pedro@codesourcery.com>
4913 * NEWS: Mention inspecting extra signal information, $_siginfo,
4914 and the qXfer:siginfo:read and qXfer:siginfo:write packets.
4916 2009-02-07 Pedro Alves <pedro@codesourcery.com>
4918 * linux-nat.c (PTRACE_SETSIGINFO): Define if PTRACE_GETSIGINFO
4921 2009-02-06 Pedro Alves <pedro@codesourcery.com>
4923 * amd64-linux-nat.c (compat_int_t, compat_uptr_t, compat_time_t)
4924 (compat_timer_t, compat_clock_t, struct compat_timeval)
4925 (compat_sigval_t, compat_siginfo_t): New types.
4926 (cpt_si_pid, cpt_si_uid, cpt_si_timerid, cpt_si_overrun)
4927 (cpt_si_status, cpt_si_utime, cpt_si_stime, cpt_si_ptr)
4928 (cpt_si_addr, cpt_si_band, cpt_si_fd): New defines.
4929 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4930 (amd64_linux_siginfo_fixup): New.
4931 * linux-nat.c (linux_nat_siginfo_fixup): New.
4932 (siginfo_fixup): New.
4933 (linux_xfer_siginfo): Use siginfo_fixup to convert between the
4934 siginfo layout expected by ptrace and the siginfo layout of the
4936 (linux_nat_set_siginfo_fixup): New.
4937 * linux-nat.h (linux_nat_set_siginfo_fixup): Declare.
4939 2009-02-06 Pedro Alves <pedro@codesourcery.com>
4941 * target.h (enum target_object): Add new TARGET_OBJECT_SIGNAL_INFO.
4942 * infrun.c (siginfo_value_read, siginfo_value_write): New.
4943 (siginfo_value_funcs): New.
4944 (siginfo_make_value): New.
4945 (_initialize_infrun): Create the $_siginfo convenience variable.
4946 * gdbtypes.h (append_composite_type_field_aligned): Declare.
4947 * gdbtypes.c (append_composite_type_field): Rename to...
4948 (append_composite_type_field_aligned): ... this. Add ALIGNMENT
4949 argument. Handle it.
4950 (append_composite_type_field): Rewrite on top of
4951 append_composite_type_field_aligned.
4952 * value.h (internalvar_make_value): New typedef.
4953 (struct internalvar) <make_value>: New field.
4954 (create_internalvar_type_lazy): Declare.
4955 * value.c (create_internalvar): Clear make_value.
4956 (create_internalvar_type_lazy): New.
4957 (value_of_internalvar): If make_value is set use it.
4958 (preserve_values): Skip internal variables that don't have a
4960 * gdbarch.sh (get_siginfo_type): New.
4961 * gdbarch.h, gdbarch.c: Regenerate.
4963 * linux-tdep.h, linux-tdep.c: New.
4964 * amd64-linux-tdep.c: Include "linux-tdep.h".
4965 (amd64_linux_init_abi): Register linux_get_siginfo_type and
4966 linux_get_siginfo_mapper.
4967 * i386-linux-tdep.c: Include "linux-tdep.h".
4968 (i386_linux_init_abi): Register linux_get_siginfo_type and
4969 linux_get_siginfo_mapper.
4970 * arm-linux-tdep.c: Include "linux-tdep.h".
4971 (i386_linux_init_abi): Register linux_get_siginfo_type and
4972 linux_get_siginfo_mapper.
4974 * linux-nat.c (linux_xfer_siginfo): New.
4975 (linux_nat_xfer_partial): Handle TARGET_OBJECT_SIGNAL_INFO.
4976 * remote.c (PACKET_qXfer_siginfo_read)
4977 (PACKET_qXfer_siginfo_write): New.
4978 (feature remote_protocol_features): Add "qXfer:siginfo:read" and
4979 "qXfer:siginfo:write" features.
4980 (remote_xfer_partial): Handle TARGET_OBJECT_SIGNAL_INFO.
4981 (_initialize_remote): Add "set/show remote read-siginfo-object"
4982 and "set/show remote write-siginfo-object" commands.
4984 * Makefile.in (ALL_TARGET_OBS): Add linux-tdep.o.
4985 (HFILES_NO_SRCDIR): Add linux-tdep.h.
4986 (ALLDEPFILES): Add linux-tdep.c.
4988 * configure.tgt (arm*-*-linux* | arm*-*-uclinux*)
4989 (i[34567]86-*-linux*, x86_64-*-linux*): Add linux-tdep.o to
4992 2009-02-06 Jim Blandy <jimb@codesourcery.com>
4993 Daniel Jacobowitz <dan@codesourcery.com>
4994 Vladimir Prus <vladimir@codesourcery.com>
4995 Pedro Alves <pedro@codesourcery.com>
4997 * defs.h (enum lval_type): New value: lval_computed.
4998 * value.h (struct lval_funcs): New type.
4999 (allocate_computed_value, value_computed_funcs)
5000 (value_computed_closure): New declarations.
5001 * value.c (struct value): Add a structure to the location union
5002 for computed lvalues, containing 'funcs' and 'closure' members.
5003 (allocate_computed_value, value_computed_funcs)
5004 (value_computed_closure): New functions.
5005 (value_free): For computed lvalues, call the closure's
5006 'free_closure' function before freeing the value itself.
5007 (value_copy): If we're copying an lval_computed value, call the
5008 closure's 'copy_closure' function.
5009 (set_value_component_location): If the original value is a
5010 computed lvalue, then call the closure's 'copy_closure' function.
5011 (value_of_internalvar): If an internal variable's value is a
5012 computed lvalue, make retrieving its value produce an equivalent
5014 * valops.c (value_fetch_lazy): Unlazy computed lvalues by calling
5015 their read function.
5016 (value_assign): Assign to computed lvalues by calling their write
5019 2009-02-06 Pedro Alves <pedro@codesourcery.com>
5021 * linux-nat.c (linux_nat_wait): Adjust.
5022 (linux_nat_pid_to_str): Adjust. Remove call to thread_db_init.
5023 * linux-nat.h (thread_db_init): Delete declaration.
5024 * linux-thread-db.c (target_beneath): Delete.
5025 (thread_db_init): Delete.
5026 (thread_db_detach): Use find_target_beneath.
5027 (thread_db_wait): Adjust interface. Use find_target_beneath.
5028 (thread_db_mourn_inferior): Use find_target_beneath.
5029 (thread_db_can_async_p, thread_db_is_async_p, thread_db_async)
5030 (thread_db_async_mask): Delete.
5031 (thread_db_pid_to_str): Adjust interface. Use
5032 find_target_beneath.
5033 (thread_db_get_thread_local_address): Adjust interface. Use
5034 find_target_beneath.
5035 (init_thread_db_ops): Delete references to delete functions.
5036 * target.c (update_current_target): Don't inherit or default
5037 to_wait. Don't inherit to_pid_to_str and
5038 to_get_thread_local_address.
5039 (target_translate_tls_address): Look for a pushed target that
5040 implements to_get_thread_local_address, and use it instead of
5041 checking for target_get_thread_local_address_p.
5042 (target_wait, target_pid_to_str): Reimplement as functions.
5043 (dummy_pid_to_str): New.
5044 (init_dummy_target): Register it.
5045 (debug_to_wait): Delete.
5046 * target.h (struct target_ops): Make to_wait, to_pid_to_str and
5047 to_get_thread_local_address accept a pointer to struct target_ops.
5048 (target_wait): Delete macro, and declare as function.
5049 (target_pid_to_str): Likewise.
5050 (target_get_thread_local_address)
5051 (target_get_thread_local_address_p): Delete.
5052 (noprocess): Add NORETURN and ATTR_NORETURN tags.
5053 * inf-ptrace.c (inf_ptrace_wait): Adjust.
5054 (inf_ptrace_pid_to_str): New.
5055 (inf_ptrace_target): Use inf_ptrace_pid_to_str.
5056 * aix-thread.c (aix_thread_wait, aix_thread_pid_to_str): Adjust.
5057 * bsd-kvm.c (bsd_kvm_pid_to_str): Adjust.
5058 * bsd-uthread.c (bsd_uthread_wait, bsd_uthread_pid_to_str):
5060 * corelow.c (core_pid_to_str): Adjust.
5061 * darwin-nat.c (darwin_wait, darwin_pid_to_str): Adjust.
5062 * dec-thread.c (dec_thread_wait, dec_thread_pid_to_str): Adjust.
5063 * gnu-nat.c (gnu_wait, gnu_pid_to_str): Adjust.
5064 * go32-nat.c (go32_wait, go32_pid_to_str): Adjust.
5065 * hpux-thread.c (hpux_thread_wait): Adjust.
5066 * inf-ttrace.c (inf_ttrace_wait, inf_ttrace_pid_to_str): Adjust.
5067 * monitor.c (monitor_wait, monitor_pid_to_str): Adjust.
5068 * nto-procfs.c (procfs_wait, procfs_pid_to_str): Adjust.
5069 * procfs.c (procfs_pid_to_str): Adjust.
5070 * remote-m32r-sdi.c (m32r_wait, m32r_pid_to_str): Adjust.
5071 * remote-mips.c (mips_wait): Adjust.
5072 * remote-sim.c (gdbsim_wait, gdbsim_pid_to_str): Adjust.
5073 * remote.c (remote_wait, remote_pid_to_str)
5074 (remote_get_thread_local_address): Adjust.
5075 * rs6000-nat.c (rs6000_wait): Adjust.
5076 * sol-thread.c (procfs_pid_to_str): Adjust declaration.
5077 (sol_thread_wait, solaris_pid_to_str): Adjust.
5078 * spu-linux-nat.c (spu_child_wait): Adjust.
5079 * windows-nat.c (windows_wait, windows_pid_to_str): Adjust.
5081 2009-02-06 Tom Tromey <tromey@redhat.com>
5083 * Makefile.in (SUBDIR_PYTHON_OBS): Add python-cmd.o.
5084 (SUBDIR_PYTHON_SRCS): Add python-cmd.c.
5085 (python-cmd.o): New target.
5086 * cli/cli-decode.c (set_cmd_completer): Add self parameter to
5087 completer prototype.
5088 (add_cmd): Initialize destroyer member of cmd_list_element. Use
5089 make_symbol_completion_list_fn as completer.
5090 (delete_cmd): Call destroyer if one is set.
5091 * cli/cli-decode.h (cmd_list_element): Add cmd parameter to
5092 completer member. Add destroyer member.
5093 (set_cmd_completer): Add self parameter to
5094 completer prototype.
5095 * command.h (set_cmd_completer): Add cmd parameter to
5096 completer prototype.
5097 * completer.c (noop_completer, filename_completer,
5098 location_completer, expression_completer, command_completer): Adapt
5099 to new completer prototype.
5100 (complete_line_internal): Pass new parameter to completer function.
5101 * completer.h (noop_completer, filename_completer,
5102 location_completer, expression_completer, command_completer): Adapt
5103 prototypes to new completer prototype.
5104 * interps.c (interpreter_completer): Adapt to new completer
5106 * python/python-cmd.c: New file.
5107 * python/python-internal.h (gdbpy_initialize_commands): Add
5109 (gdbpy_doc_cst): Add forward declaration.
5110 * python/python.c (gdbpy_doc_cst): Declare.
5111 (_initialize_python): Call gdbpy_initialize_commands. Initialize
5113 * symtab.c (make_symbol_completion_list_fn): New function.
5114 * symtab.h (make_symbol_completion_list_fn): Add prototype.
5116 2009-02-06 Pedro Alves <pedro@codesourcery.com>
5118 * target.c (target_get_osdata): Check for equal or higher than
5119 process_stratum, not dummy_stratum.
5121 2009-02-06 Pedro Alves <pedro@codesourcery.com>
5123 * remote.c (extended_remote_can_run): Delete.
5124 (init_remote_ops): Don't register it.
5125 * target.c (target_get_osdata): Don't check for target_can_run.
5126 Instead any target that has already been pushed, otherwise
5127 fallback to the default run target.
5129 2009-02-06 Pedro Alves <pedro@codesourcery.com>
5131 * target.c (target_create_inferior, target_detach)
5132 (target_mourn_inferior, target_attach, target_close): Do target
5134 (debug_to_attach, debug_to_detach, debug_to_create_inferior)
5135 (debug_to_mourn_inferior, debug_to_close): Delete.
5136 (setup_target_debug): Adjust.
5138 2009-02-05 Pedro Alves <pedro@codesourcery.com>
5140 * target.h (target_stopped_data_address_p): Delete declaration,
5141 and don't define as macro.
5142 * target.c (target_stopped_data_address_p): Delete.
5144 2009-02-05 Thiago Jung Bauermann <bauerman@br.ibm.com>
5145 Tom Tromey <tromey@redhat.com>
5147 * python/python-utils.c (target_string_to_unicode): New function.
5148 * python/python-internal.h (target_string_to_unicode): New prototype.
5149 * python/python-value.c (valpy_string): New function.
5150 (value_object_methods): Add `string' entry.
5152 2009-02-05 Pedro Alves <pedro@codesourcery.com>
5154 * target.h (target_tid_to_str): Delete.
5155 * thread.c (print_thread_info, thread_apply_all_command)
5156 (thread_apply_command, thread_command, do_captured_thread_select):
5157 Use target_pid_to_str instead of target_tid_to_str.
5158 * linux-fork.c (delete_fork_command): Likewise.
5160 2009-02-05 Pedro Alves <pedro@codesourcery.com>
5162 * frame.c (has_stack_frames): Make public.
5163 (get_prev_frame): Don't allow a NULL this_frame anymore.
5164 * frame.h (has_stack_frames): Declare.
5165 * varobj.c (find_frame_addr_in_frame_chain): Don't ever pass NULL
5166 to get_prev_frame, instead start at get_current_frame.
5167 (varobj_create): Check has_stack_frames before getting any frame;
5168 eliminate one usage of deprecated_safe_get_selected_frame.
5170 2009-02-05 Tom Tromey <tromey@redhat.com>
5171 Thiago Jung Bauermann <bauerman@br.ibm.com>
5173 * python/python.c (GdbMethods): Move to bottom of file.
5174 (get_parameter, execute_gdb_command, gdbpy_write,
5175 gdbpy_flush): Remove forward declarations.
5176 (eval_python_from_control_command): Fix error checking of function
5177 PyRun_SimpleString. Fix error string.
5178 (python_command): Likewise.
5179 (execute_gdb_command): Added from_tty argument.
5181 2009-02-05 Thiago Jung Bauermann <bauerman@br.ibm.com>
5183 * language.h (language_dfn): Add la_get_string member.
5184 (LA_GET_STRING): New macro.
5185 (default_get_string): New prototype.
5186 * language.c (default_get_string): New function.
5187 (unknown_language_defn, auto_language_defn, local_language_defn): Use
5188 default_get_string for la_get_string.
5189 * c-lang.c (c_get_string): New function.
5190 (c_language_defn, cplus_language_defn, asm_language_defn): Use
5191 c_get_string for la_get_string.
5192 (minimal_language_defn): Likewise
5193 * ada-lang.c (ada_language_defn): Likewise.
5194 * f-lang.c (f_language_defn): Use default_get_string for
5196 * jv-lang.c (java_language_defn): Likewise.
5197 * m2-lang.c (m2_language_defn): Likewise.
5198 * objc-lang.c (objc_language_defn): Likewise.
5199 * p-lang.c (p_language_defn): Likewise.
5200 * scm-lang.c (scm_language_defn): Likewise.
5201 * typeprint.c (type_to_string): New function.
5202 * value.h (type_to_string): New prototype.
5203 * valprint.c (val_print_string): Factor out code for reading string
5204 from the inferior into its own function. Put 2 spaces after period
5206 (read_string): New function.
5207 * valprint.h (read_string): New prototype.
5209 2009-01-07 Pierre Muller <muller@ics.u-strasbg.fr>
5210 Tom Tromey <tromey@redhat.com>
5212 PR breakpoints/8079:
5213 * breakpoint.c (print_one_breakpoint): Use exp_string field
5214 to display expression of watchpoints.
5215 (mention): Likewise.
5216 (watch_command_1): Remove trailing whitespace from expression.
5217 * printcmd.c (struct display) <exp_string>: New field.
5218 (display_command): Set exp_string.
5219 (free_display): Free exp_string.
5220 (clear_displays): Use free_display.
5221 (do_one_display): Print exp_string.
5222 (display_info): Likewise.
5224 2009-02-04 Tom Tromey <tromey@redhat.com>
5225 Thiago Jung Bauermann <bauerman@br.ibm.com>
5226 Phil Muldoon <pmuldoon@redhat.com>
5228 * python/python-internal.h (gdbpy_get_value_from_history): Rename
5229 prototype to gdbpy_history.
5230 (gdbpy_is_string): Declare.
5231 (python_string_to_host_string): Declare.
5232 * python/python-utils.c (gdbpy_is_string): New function.
5233 (unicode_to_encoded_string): New function.
5234 (unicode_to_target_string): Use it.
5235 (python_string_to_host_string): New function.
5236 * python/python-value.c (valpy_address): New function.
5237 (convert_value_from_python): Use gdbpy_is_string. Change to throw
5238 Python exception instead of a GDB exception on error. Properly check
5240 (valpy_getitem): Convert field name to host string. Handle array
5241 accesses. Adapt to new behaviour of convert_value_from_python.
5242 (valpy_new): Adapt to new behaviour of convert_value_from_python.
5243 (enum valpy_opcode) <VALPY_LSH, VALPY_RSH, VALPY_BITAND,
5244 VALPY_BITXOR, VALPY_BITOR>: New constants.
5245 (valpy_binop): Update. Adapt to new behaviour of
5246 convert_value_from_python.
5247 (valpy_invert): New function.
5248 (valpy_lsh): Likewise.
5249 (valpy_rsh): Likewise.
5250 (valpy_and): Likewise.
5251 (valpy_or): Likewise.
5252 (valpy_xor): Likewise.
5253 (valpy_richcompare): Call convert_value_from_python instead of doing
5255 (is_intlike, valpy_int, valpy_long, valpy_float): New functions.
5256 (gdbpy_get_value_from_history): Rename
5257 function to gdbpy_history.
5258 (gdbpy_initialize_values): Don't set tp_new.
5259 (value_object_type): Add valpy_new.
5260 (value_object_methods): Add `address' entry.
5261 (value_object_as_number): Update for new methods.
5262 * python/python.c (GdbMethods): Rename entry from
5263 `get_value_from_history' to `history'.
5265 2009-02-04 Jerome Guitton <guitton@adacore.com>
5267 * ada-lang.c (ada_template_to_fixed_record_type_1): Check size
5268 of type to guard against a crash.
5270 2009-02-04 Jerome Guitton <guitton@adacore.com>
5272 * value.c (value_from_contents_and_address): Always return
5273 a lval_memory value, even if address is null.
5275 2009-02-04 Tristan Gingold <gingold@adacore.com>
5277 * i386-darwin-tdep.c (i386_darwin_sigcontext_addr): New function.
5278 (amd64_darwin_sigcontext_addr): Ditto.
5279 (darwin_dwarf_signal_frame_p): Ditto.
5280 (i386_darwin_init_abi): Handle signal frames, use the const for
5282 (x86_darwin_init_abi_64): Ditto.
5284 2009-02-04 Tristan Gingold <gingold@adacore.com>
5286 * i386-tdep.c (i386_sigtramp_p): Make it public.
5287 * i386-tdep.h (i386_sigtramp_p): Declare.
5289 2009-02-04 Tristan Gingold <gingold@adacore.com>
5291 * machoread.c (macho_symfile_read): Read minsymtab also from
5293 (macho_symfile_read): Try to read dwarf2 frame info from main
5294 object file, but not from OSO files.
5295 (macho_symfile_offsets): Update section names for latest BFD
5297 * i386-darwin-tdep.c (i386_darwin_init_abi): Call set_solib_ops.
5298 (x86_darwin_init_abi_64): Ditto.
5299 * solib-darwin.c: New file.
5300 * solib-darwin.h: New file.
5301 * configure.tgt: Add solib.o solib-darwin.o for Darwin.
5303 2009-02-04 Tristan Gingold <gingold@adacore.com>
5305 * solist.h (struct target_so_ops): Comment fallback behavior for
5308 2009-02-03 Tom Tromey <tromey@redhat.com>
5310 * completer.c (add_struct_fields): Check type_name against NULL
5313 2009-02-03 Joel Brobecker <brobecker@adacore.com>
5315 * MAINTAINERS: Update Elena's email address.
5317 2009-02-02 Joel Brobecker <brobecker@adacore.com>
5319 * breakpoint (update_watchpoint): Minor comment adjustment.
5321 2009-02-02 Tom Tromey <tromey@redhat.com>
5324 * completer.c (count_struct_fields): Count method names.
5325 (add_struct_fields): Add matching method names.
5327 2009-02-02 Doug Evans <dje@google.com>
5329 * configure.ac (gdbkt): Check both no_tcl/no_tk first, before
5330 doing any further tcl/tk configury. Don't configure gdbtk if
5331 tcl or tk check fails.
5332 * aclocal.m4: Regenerate.
5333 * configure: Regenerate.
5335 2009-02-02 Tom Tromey <tromey@redhat.com>
5338 * valops.c (find_overload_match): Follow typedefs before taking
5339 address of object argument.
5341 2009-02-01 Doug Evans <dje@google.com>
5343 * target.h (target_waitstatus_to_string): Declare.
5344 * target.c (target_waitstatus_to_string): New function. Copied from
5345 debug_to_wait. Add missing entries for TARGET_WAITKIND_SYSCALL_ENTRY,
5346 TARGET_WAITKIND_SYSCALL_RETURN, TARGET_WAITKIND_IGNORE,
5347 TARGET_WAITKIND_NO_HISTORY.
5348 (debug_to_wait): Call it.
5349 * infrun.c (wait_for_inferior): If debug_infrun, print result of
5351 (fetch_inferior_event): Ditto.
5353 2009-01-30 Tom Tromey <tromey@redhat.com>
5355 * Makefile.in (HFILES_NO_SRCDIR): Remove i386-cygwin-tdep.h.
5357 2009-01-30 Vladimir Prus <vladimir@codesourcery.com>
5360 * thread.c (do_captured_list_thread_ids): Report the current
5363 2009-01-30 Vladimir Prus <vladimir@codesourcery.com>
5365 * breakpoint.c (create_breakpoint, create_breakpoints)
5366 (break_command_really, set_breakpoint): New parameter enabled.
5367 (create_breakpoint, break_command_really): Make breakpoint
5368 disabled if so requested.
5369 * breakpoint.h (set_breakpoint): New parameter enabled.
5370 * mi/mi-cmd-break.c (mi_cmd_break_insert): Handle the -d option.
5372 2009-01-28 Doug Evans <dje@google.com>
5374 * amd64-tdep.h (amd64_displaced_step_copy_insn): Declare.
5375 (amd64_displaced_step_fixup): Declare.
5376 * amd64-tdep.c: #include opcode/i386.h, dis-asm.h.
5377 (amd64_arch_regmap): Move out of amd64_analyze_stack_align
5378 and make static global.
5379 (amd64_arch_regmap_len): New static global.
5380 (amd64_arch_reg_to_regnum): New function.
5381 (struct amd64_insn): New struct.
5382 (struct displaced_step_closure): New struct.
5383 (onebyte_has_modrm,twobyte_has_modrm): New static globals.
5384 (rex_prefix_p,skip_prefixes)
5385 (amd64_insn_length_fprintf,amd64_insn_length_init_dis)
5386 (amd64_insn_length,amd64_get_unused_input_int_reg)
5387 (amd64_get_insn_details,fixup_riprel,fixup_displaced_copy)
5388 (amd64_displaced_step_copy_insn)
5389 (amd64_absolute_jmp_p,amd64_absolute_call_p,amd64_ret_p)
5390 (amd64_call_p,amd64_breakpoint_p,amd64_syscall_p)
5391 (amd64_displaced_step_fixup): New functions.
5392 * amd64-linux-tdep.c: #include arch-utils.h.
5393 (amd64_linux_init_abi): Install displaced stepping support.
5395 2009-01-28 Daniel Jacobowitz <dan@codesourcery.com>
5396 Jerome Guitton <guitton@adacore.com>
5398 * configure, config.in: Regenerated.
5399 * configure.ac: Add --with-system-gdbinit.
5400 * main.c (get_init_files): New.
5401 (captured_main): Use get_init_files. Load system gdbinit before
5403 (print_gdb_help): Print location of init files.
5405 2009-01-28 Pedro Alves <pedro@codesourcery.com>
5407 * corefile.c (generic_search): Delete disabled code.
5408 * gdbcore.h (generic_search): Delete declaration.
5410 2009-01-26 Pedro Alves <pedro@codesourcery.com>
5412 * linux-nat.c (linux_child_follow_fork): Copy attach_flag from the
5413 parent to the child.
5414 * inf-ttrace.c (inf_ttrace_follow_fork): Likewise.
5415 * inf-ptrace.c (inf_ptrace_follow_fork): Likewise. Use
5416 remove_breakpoints to remove breakpoints from the parent.
5418 2009-01-26 Pedro Alves <pedro@codesourcery.com>
5420 PR backtrace/9458, PR backtrace/8864:
5421 * frame.c (create_new_frame): Update the frame's cached PC before
5422 finding its unwinder. Use frame_id_build to build the new frame's
5424 * stack.c (parse_frame_specification_1): Correct setting ``addrs''
5425 array values from the ``args'' array values.
5427 2009-01-26 Pedro Alves <pedro@codesourcery.com>
5429 * gdbtypes.c (alloc_type, alloc_type_instance, create_range_type)
5430 (create_array_type, create_set_type, init_flags_type)
5431 (copy_type_recursive): Replace pairs of calls to XALLOC and memset
5432 with a call to XZALLOC or XCALLOC, and pairs of calls to
5433 obstack_alloc and memset with a call to OBSTACK_ZALLOC.
5435 2009-01-26 Pedro Alves <pedro@codesourcery.com>
5437 Add "maint set|show internal-error|internal-warning quit|corefile
5438 ask|yes|no" commands.
5441 * utils.c (internal_problem_ask, internal_problem_yes)
5442 (internal_problem_no, internal_problem_modes): New.
5443 (struct internal_problem): Remove FIXME. Make should_quit and
5444 should_dump_core types to char *.
5445 (internal_vproblem, internal_error_problem)
5446 (internal_warning_problem): Adjust.
5447 (set_internal_problem_cmd, show_internal_problem_cmd): New dummy
5449 (add_internal_problem_command): New.
5450 (_initialize_utils): New.
5452 2009-01-25 Pedro Alves <pedro@codesourcery.com>
5454 * infcmd.c (program_info): Use paddress instead of casting stop_pc
5457 2009-01-24 Pedro Alves <pedro@codesourcery.com>
5459 * infrun.c (normal_stop): Don't call
5460 deprecated_update_frame_pc_hack.
5461 * frame.c (deprecated_update_frame_pc_hack)
5462 (deprecated_update_frame_base_hack): Delete, and ...
5463 (create_new_frame): ... inline here.
5464 * frame.h (deprecated_update_frame_pc_hack)
5465 (deprecated_update_frame_base_hack): Delete declarations.
5467 2009-01-23 Pedro Alves <pedro@codesourcery.com>
5469 * cli/cli-decode.c (add_setshow_zuinteger_cmd): New.
5470 * cli/cli-setshow.c (do_setshow_command): Handle it.
5471 * command.h (enum var_types): Add var_zuinteger.
5472 (add_setshow_zuinteger_cmd): Declare.
5474 * valprint.c (_initialize_valprint): Change the set input-radix
5475 and set output-radix commands to zuinteger type.
5477 2009-01-23 Pedro Alves <pedro@codesourcery.com>
5480 * infrun.c (normal_stop): Tag threads as stopped, and run the
5481 hook-stop before printing the stack frame.
5483 2009-01-22 Pedro Alves <pedro@codesourcery.com>
5486 * gnu-v3-abi.c (gnuv3_baseclass_offset): Call check_typedef on
5489 2009-01-20 Kazu Hirata <kazu@codesourcery.com>
5491 * gdb/procfs.c (info_mappings_callback): Cast map->pr_size to
5494 2009-01-20 Daniel Jacobowitz <dan@codesourcery.com>
5497 * infcmd.c (signal_command): Do not specify a resume PC.
5499 2009-01-19 Doug Evans <dje@google.com>
5501 * dummy-frame.c (dummy_frame): Replace regcache member with
5503 (dummy_frame_push): Replace caller_regcache arg with caller_state.
5504 All callers updated.
5505 (remove_dummy_frame,pop_dummy_frame,lookup_dummy_frame): New fns.
5506 (dummy_frame_pop): Rewrite. Verify requested frame is in the
5507 dummy frame stack. Restore program state.
5508 (cleanup_dummy_frames): Rewrite.
5509 (dummy_frame_sniffer): Update. Make static.
5510 * dummy-frame.h (regcache,frame_info): Delete forward decls.
5511 (inferior_thread_state): New forward decl.
5512 (dummy_frame_push): Update prototype.
5513 * frame.c (frame_pop): dummy_frame_pop now does all the work for
5515 * infcall.c (breakpoint_auto_delete_contents): Delete.
5516 (get_function_name,run_inferior_call): New fns.
5517 (call_function_by_hand): Simplify by moving some code to
5518 get_function_name, run_inferior_call. Inferior function call wrapped
5519 in TRY_CATCH so there's less need for cleanups and all exits from
5520 proceed are handled similarily. Detect program exit.
5521 Detect program stopping in a different thread.
5522 Make error messages more consistent.
5523 * inferior.h (inferior_thread_state): Declare (opaque type).
5524 (save_inferior_thread_state,restore_inferior_thread_state,
5525 make_cleanup_restore_inferior_thread_state,
5526 discard_inferior_thread_state, get_inferior_thread_state_regcache):
5528 (save_inferior_status): Update prototype.
5529 * infrun.c: (normal_stop): When stopped for the completion of an
5530 inferior function call, verify the expected stack frame kind.
5531 (inferior_thread_state): New struct.
5532 (save_inferior_thread_state,restore_inferior_thread_state,
5533 do_restore_inferior_thread_state_cleanup,
5534 make_cleanup_restore_inferior_thread_state,
5535 discard_inferior_thread_state,
5536 get_inferior_thread_state_regcache): New functions.
5537 (inferior_status): Move stop_signal, stop_pc, registers to
5538 inferior_thread_state. Remove restore_stack_info.
5539 (save_inferior_status): Remove arg restore_stack_info.
5540 All callers updated. Remove saving of state now saved by
5541 save_inferior_thread_state.
5542 (restore_inferior_status): Remove restoration of state now done by
5543 restore_inferior_thread_state.
5544 (discard_inferior_status): Remove freeing of registers, now done by
5545 discard_inferior_thread_state.
5547 2009-01-18 Pedro Alves <pedro@codesourcery.com>
5549 * tui/tui-disasm.c (tui_vertical_disassem_scroll): Scroll one line
5550 at a time, times NUM_TO_SCROLL.
5551 * tui/tui-winsource.c (tui_horizontal_source_scroll): Don't try to
5552 fetch the selected frame if there is no stack.
5554 2009-01-18 Pedro Alves <pedro@codesourcery.com>
5557 * gdbthread.h (finish_thread_state, finish_thread_state_cleanup):
5559 * thread.c (finish_thread_state, finish_thread_state_cleanup): New.
5560 * infrun.c (wait_for_inferior, fetch_inferior_event): If an error
5561 is thrown while handling an event, finish the thread state.
5562 (normal_stop): Use finish_thread_state cleanup.
5563 * infcmd.c (run_command_1): If an error is thrown while starting
5564 the inferior, finish the thread state.
5566 2009-01-18 Pedro Alves <pedro@codesourcery.com>
5568 * tui/tui-winsource.c (tui_update_breakpoint_info): In asm layout,
5569 skip breakpoints without a location (pending breakpoints).
5571 2009-01-18 Pedro Alves <pedro@codesourcery.com>
5574 * hppa-hpux-tdep.c (hppa_hpux_write_pc): Remove 'return'.
5576 2009-01-18 Nick Roberts <nickrob@snap.net.nz>
5578 * thread.c (thread_command): Move call to annotate_thread_changed
5580 (do_captured_thread_select): ... here, to avoid printing an
5581 annotation if the thread change generates an exception.
5583 2009-01-16 Joel Brobecker <brobecker@adacore.com>
5585 * NEWS: Document x86_64/MinGW as a new native configuration.
5587 2009-01-16 Joel Brobecker <brobecker@adacore.com>
5589 * NEWS: Move the documentation of "info os processes" to
5590 the appropriate section (documenting the new commands).
5592 2009-01-15 Doug Evans <dje@google.com>
5594 * target.h (target_signal_to_string): Make return type const char *.
5595 (target_signal_to_name): Ditto.
5596 (target_signal_from_name): Make arg const char *.
5597 * infrun.c (sig_print_info): Update.
5598 * signals/signals.c (signals): Make array and struct members const.
5599 (target_signal_to_string): Make return type const char *.
5600 (target_signal_to_name): Ditto.
5601 (target_signal_from_name): Make arg const char *.
5603 2009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
5604 Tristan Gingold <gingold@adacore.com>
5606 * solist.h (struct target_so_ops): New member bfd_open.
5607 (solib_find): Add prototype.
5608 (solib_bfd_fopen): Add prototype.
5609 * solib.c (solib_find, solib_bfd_fopen): New functions, extracted
5610 from solib_bfd_open.
5611 (solib_bfd_open): Use ops->bfd_open override if present. Call
5612 solib_find and solib_bfd_open otherwise.
5614 * objfiles.h (OBJF_KEEPBFD): New define.
5615 * objfiles.c (free_objfile): Do not close BFD if OBJF_KEEPBFD
5616 objfile flag is set.
5617 * solib.c (symbol_add_stub): Do not allocate second BFD for
5618 shared library; use OBJF_KEEPBFD flag on solib objfile.
5620 2009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
5622 * frame.c (get_frame_arch): Abort if called with NULL this_frame.
5624 2009-01-15 Ulrich Weigand <uweigand@de.ibm.com>
5626 * value.h (address_of_variable): Add prototype.
5627 (locate_var_value): Remove prototype.
5629 * findvar.c (read_var_value): Do not attempt to default frame
5631 (locate_var_value): Remove function.
5632 * valops.c (value_of_variable): Retrieve selected frame for
5633 symbols that require a frame when called with NULL block.
5634 * valops.c (address_of_variable): New function.
5636 * eval.c (evaluate_subexp_for_address): Call address_of_variable
5637 instead of calling locate_var_value.
5638 (evaluate_subexp_with_coercion): Likewise.
5640 2009-01-14 Daniel Jacobowitz <dan@codesourcery.com>
5642 * NEWS: Document "define" for prefixed commands.
5643 * cli/cli-cmds.c (show_user): Update calls to show_user_1. Call
5644 show_user_1 for prefix commands.
5645 * cli/cli-decode.c (help_cmd_list): Recurse for "help user-defined".
5646 * cli/cli-script.c (validate_comname): Rewrite to handle prefix
5647 commands. Return the containing command list.
5648 (define_command, document_command): Update to handle prefix commands.
5649 (show_user_1): Add prefix and name arguments. Handle prefix
5651 * cli/cli-script.h (show_user_1): Update prototype.
5653 2009-01-14 Kai Tietz <kai.tietz@onevision.com>
5655 * ser-mingw.c (console_select_thread): Add return to make
5657 (pipe_select_thread): Likewise.
5658 (file_select_thread): Likewise.
5660 2009-01-14 Pedro Alves <pedro@codesourcery.com>
5662 * mi/mi-main.c (mi_cmd_execute): Clean up parenthesis mess from
5665 2009-01-14 Pedro Alves <pedro@codesourcery.com>
5667 * remote.c (extended_remote_mourn_1): Invalidate our notion of
5668 current general thread.
5670 2009-01-14 Pedro Alves <pedro@codesourcery.com>
5672 * mi/mi-main.c (mi_cmd_execute): Also allow -list-thread-groups
5673 without a live selected thread.
5675 2009-01-14 Joel Brobecker <brobecker@adacore.com>
5677 Update the copyright notice of some of the files I missed
5678 in the previous copyright update.
5680 2009-01-14 Joel Brobecker <brobecker@adacore.com>
5682 * windows-nat.c (handle_unload_dll): Use %p to print the DLL
5683 base address instead of casting it to DWORD.
5685 2009-01-13 Ulrich Weigand <uweigand@de.ibm.com>
5687 * dwarf2loc.c (dwarf2_evaluate_loc_desc): Do not call get_frame_arch
5688 for NULL frame pointers.
5690 2009-01-13 Mark Kettenis <kettenis@gnu.org>
5692 * utils.c (host_address_to_string): Reimplement in a way that
5693 avoids the cast of the address to long.
5695 2009-01-13 Joel Brobecker <brobecker@adacore.com>
5697 * mdebugread.c (parse_symbol): Save the symbol private data
5698 using SYMBOL_VALUE_BYTES instead of SYMBOL_VALUE.
5699 (psymtab_to_symtab_1): Likewise.
5700 (parse_procedure): Declare variable "e" only in the scope
5701 where it is used. Extract the symbol private data using
5704 2009-01-13 Jim Blandy <jimb@codesourcery.com>
5706 Abstract out common code for copying value locations.
5708 * value.h (set_value_component_location): New declaration.
5709 * value.c (set_value_component_location): New function.
5710 (value_primitive_field): Use it.
5711 * valarith.c (value_subscript, value_subscripted_rvalue): Same.
5712 * valops.c (search_struct_field, value_slice): Same.
5713 * ada-lang.c (coerce_unspec_val_to_type)
5714 (ada_value_primitive_packed_val): Same.
5716 2009-01-13 Joel Brobecker <brobecker@adacore.com>
5718 * MAINTAINERS (GLOBAL MAINTAINERS): Add Tom Tromey.
5720 2009-01-12 Christopher Faylor <me+cygwin@cgf.cx>
5722 * amd64-windows-nat.c Rename gdb-specific win32_* to windows_*
5724 * i386-cygwin-tdep.c: Ditto.
5725 * i386-windows-nat.c: Ditto.
5726 * windows-nat.h: Ditto.
5727 * windows-tdep.c: Ditto.
5728 * windows-tdep.h: Ditto.
5729 * windows-nat.c: Ditto.
5730 (cygwin_load_start): Redefine as CORE_ADDR.
5731 (cygwin_load_end): Ditto.
5732 (windows_make_so): Coerce result of address arithmetic to uintptr_t
5733 before coercing to CORE_ADDR to avoid a compiler warning.
5734 (handle_exception): Define addr as CORE_ADDR and coerce
5735 ExceptionAddress to uintptr_t before assigining to avoid a compiler
5737 * config/djgpp/fnchange.lst: Add mappings for recently renamed windows
5740 2009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
5742 Fix linking with --enable-targets=all:
5743 * Makefile.in (ALL_TARGET_OBS): Add windows-tdep.o.
5744 (HFILES_NO_SRCDIR): Add windows-tdep.h.
5745 (ALLDEPFILES): Add windows-tdep.c.
5747 2009-01-11 Chris Faylor <me.gdb@cgf.cx>
5749 * win32-nat.h: Delete.
5750 * windows-nat.h: Rename from win32-nat.h.
5751 * win32-nat.c: Delete.
5752 * windows-nat.c: Rename from win32-nat.c.
5753 * win32-termcap.c: Delete.
5754 * windows-termcap.c: Rename from win32-termcap.c.
5755 * amd64-windows-nat.c: Handle rename from win32-nat.h -> windows-nat.h.
5756 * configure.ac: Handle rename from win32-termcap.c ->
5758 * configure: Regenerate.
5759 * gdb_curses.h: Change comment to reflect rename from win32-termcap.c
5760 -> windows-termcap.c.
5761 * i386-cygwin-tdep.c: Handle rename from win32-tdep.h ->
5763 * i386-windows-nat.c: Refect rename from win32-nat.h -> windows-nat.h.
5764 * windows-nat.c: Ditto. Also reflect rename from from win32-tdep.h ->
5766 (win32_make_so): Handle cygwin compiler warning due to change of
5767 load_addr from DWORD to LPVOID.
5768 (handle_load_dll): Use %p in format string to properly print address
5769 and avoid a compiler warning.
5770 (DEBUG_EXCEPTION_SIMPLE): Ditto.
5771 (handle_exception): Ditto.
5772 * windows-tdep.c: Handle rename from win32-tdep.h -> windows-tdep.h.
5773 * config/i386/cygwin.mh: Handle rename from win32-nat.o ->
5775 * config/i386/mingw.mh: Ditto.
5776 * config/i386/mingw64.mh: Ditto.
5778 2009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
5780 * f-typeprint.c (f_type_print_varspec_suffix): Convert the autovariable
5781 arrayprint_recurse_level to a parameter. Update all the callers. New
5782 comment at autovariables.
5784 2009-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
5786 * gdbtypes.c (make_qualified_type, replace_type): Reformat to the GNU
5789 2009-01-11 Joel Brobecker <brobecker@adacore.com>
5791 * target.c (target_xfer_partial): Use host_address_to_string to
5792 print the address of readbuf and writebuf. Cast the address of
5793 elements inside the myaddr buffer into intptr_t.
5794 (deprecated_debug_xfer_memory): Use paddress to print memaddr.
5795 Cast the address of elements inside the myaddr buffer into
5798 2009-01-11 Joel Brobecker <brobecker@adacore.com>
5800 * amd64-windows-nat.c, amd64-windows-tdep.c: New files.
5801 * config/i386/mingw64.mh, config/i386/nm-cygwin64.h: New files.
5802 * configure.host, configure.tgt: Add handling for x86_64/windows.
5803 * config/djgpp/fnchange.lst: Add entries for amd64-windows-nat.c
5804 and amd64-windows-tdep.c.
5806 2009-01-11 Joel Brobecker <brobecker@adacore.com>
5808 * win32-tdep.h, win32-tdep.c: New files.
5809 * i386-cygwin-tdep.h: Delete.
5810 * i386-cygwin-tdep.c: Include win32-tdep.h instead of
5812 (win32_xfer_shared_library): Delete. Moved to win32-tdep.c.
5813 * win32-nat.c: Likewise.
5814 * configure.tgt: Add win32-tdep.o to the list of target object
5815 files for i386-cygwin and i386-mingw targets.
5817 2009-01-11 Joel Brobecker <brobecker@adacore.com>
5819 * win32-nat.h: New file.
5820 * win32-nat.c (mappings): Initialize to NULL.
5821 (win32_set_context_register_offsets): New function.
5822 * i386-windows-nat.c: New file.
5823 (mappings): Moved here from win32-nat.c.
5824 (_initialize_i386_windows_nat): New function.
5825 * config/i386/mingw.mh (NATDEPFILES): Add i386-windows-nat.o.
5826 * config/i386/cygwin.mh (NATDEPFILES): Likewise.
5828 2009-01-09 Andreas Schwab <schwab@suse.de>
5830 * Makefile.in (init.c): Set LANG/LC_ALL to C, not c.
5832 2009-01-09 Daniel Jacobowitz <dan@codesourcery.com>
5834 * gdbtypes.c (append_composite_type_field): Correct the location of
5837 2009-01-09 Pedro Alves <pedro@codesourcery.com>
5839 * defs.h (deprecated_error_hook): Delete declaration.
5840 * interps.c (clear_interpreter_hooks): Adjust.
5841 * remote-sim.c (gdb_os_error): Don't try to call
5842 deprecated_error_hook. No need to call exit anymore.
5843 * top.c (deprecated_error_hook): Delete.
5845 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5847 * arch-utils.c (gdbarch_update_p): Use host_address_to_string
5848 to print the address of the gdbarch pointer.
5850 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5852 * gdbarch.sh: Fix all the compilation errors on amd64-windows
5853 due to casting a pointer to a long when printing a function
5854 address. Instead, use host_address_to_string to convert our
5855 address to a string.
5856 * gdbarch.c: Regenerate.
5858 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5860 * event-top.c (async_disconnect, async_stop_sig): use "raise"
5861 instead of "kill" to raise a signal.
5863 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5865 * win32-nat.c (get_module_name): Change the type of parameter
5866 "base_address" to LPVOID. Remove unnecessary cast.
5867 (struct lm_info): Change type of load_addr to LPVOID.
5868 (win32_make_so): Change the type of parameter "load_addr"
5869 to LPVOID. Remove some unnecessary casts.
5870 (handle_unload_dll): Change the type of "lpBaseOfDll" to LPVOID.
5871 (win32_xfer_shared_libraries): Add missing cast.
5873 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5875 * win32-nat.c (has_detach_ability, set_process_privilege):
5876 Cast the result of GetProcAddress to (void *) to avoid
5877 a compilation warning.
5879 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5881 * win32-nat.c (CONTEXT_EXTENDED_REGISTERS): Define to 0 if not
5884 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5886 * win32-nat.c (get_image_name, win32_xfer_memory): Fix type
5887 definition of local variable "done".
5888 (info_w32_command, handle_exception): Remove unnecessary cast.
5890 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5892 * win32-nat.c (kernel32_DebugSetProcessKillOnExit): Renames
5893 DebugSetProcessKillOnExit. Update all uses in this file.
5894 (kernel32_DebugActiveProcessStop): Renames DebugActiveProcessStop.
5895 Update all uses in this file.
5897 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5899 * win32-nat.c (do_initial_win32_stuff): Add new ops parameter,
5900 and use it when pushing the target.
5901 (win32_attach, win32_create_inferior): Update call to
5902 do_initial_win32_stuff.
5903 (win32_detach, win32_mourn_inferior): Use our ops parameter
5904 instead of the global win32_ops to unpush the target.
5906 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5908 * ser-mingw.c (ser_windows_open): Use proper type when casting
5909 in call to _open_osfhandle.
5911 2009-01-09 Kai Tietz <kai.tietz@onevision.com>
5913 * coff-pe-read.c (read_pe_exported_syms): Fix typo.
5915 2009-01-09 Joel Brobecker <brobecker@adacore.com>
5917 * CONTRIBUTE: Minor reformatting.
5919 2009-01-08 Kai Tietz <kai.tietz@onevision.com>
5921 * MAINTAINERS: Add myself to Write After Approval.
5922 * coff-pe-read.c (read_pe_exported_syms): Enable read of PE+
5925 2009-01-08 Nathan Froyd <froydnj@codesourcery.com>
5927 * remote-sim.c (gdb_os_error): Mark as a noreturn function.
5928 Call exit to make it obvious to GCC.
5930 2009-01-08 Tom Tromey <tromey@redhat.com>
5932 PR breakpoints/9350:
5933 * varobj.c (varobj_invalidate): Unconditionally free
5935 * symfile.c (syms_from_objfile): Free local_addr when returning
5937 * exec.c (exec_file_attach): Do cleanups before returning.
5938 (exec_file_command): Likewise.
5939 * corefile.c (reopen_exec_file): Do cleanups before returning.
5940 * breakpoint.c (insert_breakpoint_locations): Do cleanups before
5942 (do_vec_free): New function.
5943 (update_global_location_list): Make a cleanup for old_locations.
5944 Do cleanups before returning. Remove unused variable 'e'.
5945 (find_condition_and_thread): Free result of parsing the
5947 (print_it_typical): Do cleanups before returning.
5948 (breakpoint_re_set_one): Always free sals.sals.
5950 2009-01-08 Joel Brobecker <brobecker@adacore.com>
5951 Emi Suzuki <emi-suzuki@tjsys.co.jp>
5953 * breakpoint.c (do_enable_breakpoint): Use update_watchpoint for
5956 2009-01-07 Doug Evans <dje@google.com>
5958 * top.c (gdb_prompt_string): Delete, unused.
5960 2009-01-07 Pedro Alves <pedro@codesourcery.com>
5962 Delete ONE_PROCESS_WRITETEXT leftovers.
5964 * breakpoint.c (insert_bp_location): Delete process_warning
5966 (insert_breakpoint_locations): Adjust.
5967 (reattach_breakpoints): Adjust.
5968 * infrun.c (normal_stop): Drop "It might be running in another
5971 2009-01-07 Stan Shebs <stan@codesourcery.com>
5973 * config/pa/linux.mh (XDEPFILES): Remove.
5975 2009-01-07 Doug Evans <dje@google.com>
5977 * cli/cli-cmds.c (set_debug): Fix cut-n-paste error.
5979 2009-01-07 Jan Kratochvil <jan.kratochvil@redhat.com>
5981 * f-typeprint.c (f_type_print_base <TYPE_CODE_STRUCT>): Fix output
5982 spacing, a regression from 2008-04-22.
5984 2009-01-07 Joel Brobecker <brobecker@adacore.com>
5986 * utils.c (gdb_print_host_address): Adjust implementation to
5987 reuse host_address_to_string. Move comment explaining the conversion
5988 from host address to string from here...
5989 (host_address_to_string): ... to there.
5991 2009-01-07 Emi Suzuki <emi-suzuki@tjsys.co.jp>
5993 * MAINTAINERS: Add myself for write after approval privileges.
5995 2009-01-06 Tom Tromey <tromey@redhat.com>
5997 * value.c (set_internalvar): Use value_free, not xfree.
5999 2009-01-06 Jim Blandy <jimb@red-bean.com>
6001 Check return values of functions declared with warn_unused_result
6002 attribute in GLIBC 2.8.
6003 * cli/cli-cmds.c (pwd_command): Check return value from getcwd.
6004 * inflow.c (check_syscall): New function.
6005 (new_tty): Use check_syscall to check return values from open and dup.
6006 * linux-nat.c (linux_nat_info_proc_cmd): Check return value from fgets.
6007 * main.c (captured_main): Call cwd after setting up gdb_stderr;
6008 check for errors from getcwd.
6009 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Check return value from getcwd.
6010 * ui-file.c (stdio_file_write): Ignore return value from fwrite.
6011 (stdio_file_fputs): Same.
6012 * utils.c (internal_vproblem): abort if last-ditch error message
6015 * top.c (gdb_init): Don't set the current directory here; that's
6016 already been done in captured_main.
6018 2009-01-06 Sandra Loosemore <sandra@codesourcery.com>
6020 * ser-tcp.c: Adjust includes.
6021 (tcp_set_cmdlist, tcp_show_cmdlist): Declare.
6022 (tcp_auto_retry, tcp_retry_limit): Declare.
6023 (TIMEOUT): Remove, in favor of tcp_retry_limit.
6024 (POLL_INTERVAL): Increase to 5, in favor of backoff logic.
6025 (wait_for_connect): New function.
6026 (net_open): Use it. Add auto-retry logic.
6027 (set_tcp_cmd, show_tcp_cmd): New functions.
6028 (_initialize_ser_tcp): Initialize new "set/show tcp auto-retry"
6029 and "set/show tcp connect-timeout" commands.
6030 * NEWS: Document new commands.
6032 2009-01-05 Tom Tromey <tromey@redhat.com>
6034 * python/python-internal.h (Py_ssize_t): Define as int.
6036 2009-01-05 Jim Blandy <jimb@red-bean.com>
6038 * MAINTAINERS: Fix my e-mail address as steering committee member.
6040 2009-01-03 Joel Brobecker <brobecker@adacore.com>
6042 Updated copyright notices for most files.
6044 2009-01-03 Joel Brobecker <brobecker@adacore.com>
6046 * top.c (print_gdb_version): Update copyright year.
6048 2009-01-03 Joel Brobecker <brobecker@adacore.com>
6050 * config/djgpp/fnchange.lst: Add entry for ChangeLog-2008.
6052 2009-01-01 Pedro Alves <pedro@codesourcery.com>
6054 PR breakpoints/9681:
6055 * exceptions.h (enum errors): New error type, MEMORY_ERROR.
6056 * corefile.c (memory_error): Rewrite to throw a MEMORY_ERROR.
6057 * breakpoint.c (fetch_watchpoint_value): Ignore MEMORY_ERRORs, but
6058 retrow all other exceptions.
6060 For older changes see ChangeLog-2008.
6066 version-control: never