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