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