* arm-tdep.c (arm_find_mapping_symbol): New function, from
[binutils-gdb.git] / gdb / ChangeLog
1 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
2
3 * arm-tdep.c (arm_find_mapping_symbol): New function, from
4 arm_pc_is_thumb.
5 (arm_pc_is_thumb): Use arm_find_mapping_symbol.
6 (extend_buffer_earlier): New function.
7 (MAX_IT_BLOCK_PREFIX, IT_SCAN_THRESHOLD): New constants.
8 (arm_adjust_breakpoint_address): New function.
9 (arm_gdbarch_init): Register arm_adjust_breakpoint_address.
10
11 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
12
13 * arm-linux-tdep.c (arm_linux_thumb2_be_breakpoint)
14 (arm_linux_thumb2_le_breakpoint): New constants.
15 (arm_linux_init_abi): Set thumb2_breakpoint and
16 thumb2_breakpoint_size.
17 * arm-tdep.c (thumb_insn_size, thumb_advance_itstate): New functions.
18 (thumb_get_next_pc): Add a comment. Rename IT to ITSTATE.
19 Implement support for single stepping through IT blocks if
20 a 32-bit Thumb breakpoint instruction is available.
21 (arm_breakpoint_from_pc): If a 32-bit Thumb breakpoint instruction
22 is available, use it when needed.
23 (arm_remote_breakpoint_from_pc): New function.
24 (arm_gdbarch_init): Register arm_remote_breakpoint_from_pc.
25 * arm-tdep.h (struct gdbarch_tdep): Correct thumb_breakpoint
26 comment. Add thumb2_breakpoint and thumb2_breakpoint_size.
27
28 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
29
30 * arch-utils.c (default_remote_breakpoint_from_pc): New function.
31 * arch-utils.h (default_remote_breakpoint_from_pc): Declare.
32 * gdbarch.c, gdbarch.h: Regenerated.
33 * gdbarch.sh (remote_breakpoint_from_pc): New architecture method.
34 * remote.c (remote_insert_breakpoint, remote_insert_hw_breakpoint): Use
35 gdbarch_remote_breakpoint_from_pc.
36
37 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
38
39 * infrun.c (prepare_to_proceed): Handle other signals which might
40 match a breakpoint.
41 (handle_inferior_event): Move the check for unusual breakpoint
42 signals earlier.
43
44 2010-01-29 Paul Hilfinger <hilfinger@adacore.com>
45
46 amd64 - function returning record with field straddling 2 registers.
47 * amd64-tdep.c (amd_classify_aggregate): Handle the case of
48 a record of length <= 16 in which a field straddles the two
49 eightbytes.
50
51 2010-01-29 Joel Brobecker <brobecker@adacore.com>
52
53 Implement return values on amd64-windows.
54 * amd64-windows-tdep.c: #include gdbcore.h and regcache.h.
55 (amd64_windows_return_value): New function.
56 (amd64_windows_init_abi): Call set_gdbarch_return_value with
57 amd64_windows_return_value.
58
59 2010-01-29 Joel Brobecker <brobecker@adacore.com>
60
61 amd64-windows: 32 bytes allocated on stack by caller for integer
62 parameter registers.
63 * i386-tdep.h (struct gdbarch_tdep): Add new field
64 integer_param_regs_saved_in_caller_frame.
65 * amd64-windows-tdep.c (amd64_windows_init_abi): Set
66 tdep->integer_param_regs_saved_in_caller_frame to 1.
67 * amd64-tdep.c (amd64_push_dummy_call): Allocate some memory on
68 stack if tdep->integer_param_regs_saved_in_caller_frame is set.
69
70 2010-01-29 Joel Brobecker <brobecker@adacore.com>
71
72 amd64-windows: memory args passed by pointer during function calls.
73 * i386-tdep.h (gdbarch_tdep): Add field memory_args_by_pointer.
74 * amd64-tdep.c (amd64_push_arguments): Add handling of architectures
75 where tdep->memory_args_by_pointer is non-zero.
76 * amd64-windows-tdep.c (amd64_windows_init_abi): Set
77 tdep->memory_args_by_pointer to 1.
78
79 2010-01-29 Joel Brobecker <brobecker@adacore.com>
80
81 amd64-windows: Integer parameters in function calls.
82 * i386-tdep.h (enum amd64_reg_class): New, moved here from
83 amd64-tdep.c.
84 (struct gdbarch_tdep): Add fields call_dummy_num_integer_regs,
85 call_dummy_integer_regs, and classify.
86 * amd64-tdep.h (amd64_classify): Add declaration.
87 * amd64-tdep.c (amd64_dummy_call_integer_regs): New static constant.
88 (amd64_reg_class): Delete, moved to i386-tdep.h.
89 (amd64_classify): Make non-static. Move declaration to amd64-tdep.h.
90 Replace call to amd64_classify by call to tdep->classify.
91 (amd64_push_arguments): Get the list of registers to use for
92 passing integer parameters from the gdbarch tdep structure,
93 rather than using a hardcoded one. Replace calls to amd64_classify
94 by calls to tdep->classify.
95 (amd64_push_dummy_call): Get the register number used for
96 the "hidden" argument from tdep->call_dummy_integer_regs.
97 (amd64_init_abi): Initialize tdep->call_dummy_num_integer_regs
98 and tdep->call_dummy_integer_regs. Set tdep->classify.
99 * amd64-windows-tdep.c: Add include of gdbtypes.h.
100 (amd64_windows_dummy_call_integer_regs): New static global.
101 (amd64_windows_classify): New function.
102 (amd64_windows_init_abi): Initialize tdep->call_dummy_num_integer_regs
103 tdep->call_dummy_integer_regs and tdep->classify.
104
105 2010-01-28 Daniel Jacobowitz <dan@codesourcery.com>
106
107 * regcache.c (regcache_xmalloc): Add aspace argument. Use it
108 for the new regcache. All callers updated.
109 (regcache_cpy, regcache_cpy_no_passthrough): Do not set aspace here.
110 (get_thread_arch_regcache): Do not set aspace here.
111 * regcache.h (regcache_xmalloc): Update declaration.
112
113 * frame.c, infcall.c, ppc-linux-tdep.c: Calls to
114 regcache_xmalloc updated.
115
116 2010-01-28 Joel Brobecker <brobecker@adacore.com>
117
118 Another -Wunused-function error in procfs.c (sparc-solaris)
119 * procfs.c (insert_dbx_link_breakpoint): Delete declaration. Move up.
120 Only define if SYS_syssgi is defined.
121 (remove_dbx_link_breakpoint): Delete declaration. Move up.
122 (dbx_link_addr, insert_dbx_link_bpt_in_file)
123 (insert_dbx_link_bpt_in_region): Move up. Only define if SYS_syssgi
124 is itself defined.
125
126 2010-01-27 Christopher Faylor <me+cygwin@cgf.cx>
127
128 * windows-nat.c (windows_initialization_done): New variable.
129 (get_windows_debug_event): Issue error when process dies before
130 completely initializing.
131 (do_initial_windows_stuff): Set flag to indicate when we are done with
132 the initial steps of attaching to the child.
133
134 2010-01-27 Jan Kratochvil <jan.kratochvil@redhat.com>
135
136 * symtab.h (struct symbol <symtab>): New comment on NULL values.
137
138 2010-01-27 Doug Evans <dje@google.com>
139
140 * solib-svr4.c (solib_break_names): Add __dl_rtld_db_dlactivity.
141
142 * breakpoint.c (bpstat_stop_status): Delete useless code.
143
144 2010-01-27 Jan Kratochvil <jan.kratochvil@redhat.com>
145
146 * printcmd.c (display_uses_solib_p): Remove variable section. Access
147 objfile via SYMBOL_SYMTAB.
148
149 2010-01-26 Tom Tromey <tromey@redhat.com>
150
151 PR exp/7643:
152 * eval.c (evaluate_subexp_for_address) <UNOP_IND>: Call
153 coerce_array on result.
154
155 2010-01-26 Sami Wagiaalla <swagiaal@redhat.com>
156
157 * cp-namespace.c (cp_lookup_symbol_namespace): Added
158 search_parent argument.
159 (cp_add_using): Initialize 'searched' field.
160 (reset_directive_searched): New function.
161 * cp-support.h: Add 'searched' field to using_direct struct.
162 (cp_lookup_symbol_imports): Ditto.
163 * cp-namespace.c (cp_lookup_symbol_imports): Ditto.
164 Perform recursive search.
165 Implement non parent search.
166 * valops.c (value_maybe_namespace_elt): Updated.
167
168 2010-01-26 Sami Wagiaalla <swagiaal@redhat.com>
169
170 PR gdb/10929:
171 * dwarf2read.c (read_lexical_block_scope): Create blocks for
172 scopes which contain using directives even if they contain no
173 declarations.
174 * symtab.c (lookup_symbol_aux): Pass lowest level block to
175 la_lookup_symbol_nonlocal.
176 * cp-namespace.c (cp_lookup_symbol_nonlocal): call
177 cp_lookup_symbol_namespace.
178 (cp_lookup_symbol_namespace): Perform an import lookup at every
179 block level.
180 (cp_lookup_symbol_imports): New function.
181 (cp_lookup_symbol_in_namespace): New function.
182
183 2010-01-25 Tom Tromey <tromey@redhat.com>
184
185 PR gdb/11049:
186 * c-valprint.c (c_val_print): Fix test of extract_unsigned_integer
187 result.
188
189 2010-01-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
190
191 * configure.ac: Only use host_os part when disabling TUI on osf.
192 Use test to check variables, prefix strings with x.
193 * configure: Regenerate.
194
195 * solib-osf.c (osf_current_sos): Initialize tail.
196
197 2010-01-25 gingold <gingold@adacore.com>
198
199 * windows-nat.c (windows_continue): Use %x to print thread id.
200 (get_windows_debug_event): Ditto.
201
202 2010-01-22 Tom Tromey <tromey@redhat.com>
203
204 PR symtab/11199:
205 * dwarf2read.c (quirk_gcc_member_function_pointer): Change return
206 type and arguments. Use smash_to_methodptr_type.
207 (read_structure_type): Call quirk_gcc_member_function_pointer
208 later.
209 * gdbtypes.h (smash_to_methodptr_type): Declare.
210 * gdbtypes.c (smash_to_methodptr_type): New function.
211 (lookup_methodptr_type): Use it.
212
213 2010-01-21 Tom Tromey <tromey@redhat.com>
214
215 PR symtab/11198:
216 * symtab.h (lookup_minimal_symbol_and_objfile): Declare.
217 * minsyms.c (lookup_minimal_symbol_and_objfile): New function.
218 * glibc-tdep.c (find_minsym_and_objfile): Remove.
219 (glibc_skip_solib_resolver): Use
220 lookup_minimal_symbol_and_objfile.
221
222 2010-01-21 Kai Tietz <kai.tietz@onevision.com>
223
224 * inflow.c (check_syscall): Guard by #if clause for GO32 and
225 WIN32 targets.
226
227 2010-01-20 Tom Tromey <tromey@redhat.com>
228
229 PR backtrace/10770:
230 * valarith.c (value_binop): Handle BINOP_GTR, BINOP_LEQ, and
231 BINOP_GEQ. Handle BINOP_NOTEQUAL in the signed case.
232 * dwarf2expr.c (new_dwarf_expr_context): Allocate
233 dwarf_stack_values, not CORE_ADDRs.
234 (execute_stack_op): Change DW_OP_div and comparison operators to
235 use signed operands.
236
237 2010-01-20 Vladimir Prus <vladimir@codesourcery.com>
238
239 Per-inferior args and tty and environment.
240
241 * infcmd.c (inferior_args): Rename to ...
242 (inferior_args_scratch): ... this.
243 (inferior_io_terminal): Rename to ...
244 (inferior_io_terminal_scratch): ... this.
245 (inferior_argc, inferior_argv): Remove.
246 (set_inferior_io_terminal, get_inferior_io_terminal): Store
247 inside current_inferior().
248 (set_inferior_tty_command, show_inferior_tty_command): New.
249 (get_inferior_args, set_inferior_args): Store inside
250 current_inferior().
251 (notice_args_set): Likewise and rename to...
252 (set_args_command): ... this.
253 (set_inferior_args_vector): Likewise.
254 (notice_args_read): Rename to...
255 (show_args_command): ...new.
256 (tty_command): Remove.
257 (run_command_1): Don't free old args, as they are freed by
258 set_inferior_arg now.
259 (run_no_args_command): Likewise.
260 (inferior_environ): Remove.
261 (run_command_1): Use environment of the current inferior.
262 (environment_info, set_environment_command)
263 (unset_environment_command, path_info, path_command): Likewise.
264 (_initialize_infcmd): Adjust for function and variable renames.
265 Do not init inferior_environ.
266 * inferior.h (set_inferior_arg): Adjust prototype.
267 (struct inferior): New fields args, argc, argv, terminal, environment.
268 (inferior_environ): Remove declaration.
269 * inferior.c (free_inferior): Free new fields.
270 (add_inferior_silent): Initialize 'environment' field.
271 * main.c (captured_main): Set arguments only after the initial
272 inferior has been created. Set set_inferior_io_terminal,
273 not tty_command.
274 * mi/mi-main.c (mi_cmd_env_path): Use environment of the current
275 inferior.
276 (_initialize_mi_cmd_env): Adjust for disappearance of global
277 inferior_environ.
278 * solib.c (solib_find): Use environment of the current inferior.
279
280 2010-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
281
282 * varobj.c (varobj_add_child, install_dynamic_child): Wrap into #if
283 HAVE_PYTHON.
284 (instantiate_pretty_printer): Move HAVE_PYTHON outside of the function.
285
286 2010-01-20 Joel Brobecker <brobecker@adacore.com>
287
288 Get rid of ada-lang.c:function_name_from_pc.
289 * ada-lang.c: Add "stack.h" #include.
290 (function_name_from_pc): Delete.
291 (is_known_support_routine): Replace call to function_name_from_pc
292 by call to find_frame_funname.
293 (ada_unhandled_exception_name_addr_from_raise): Likewise.
294
295 2010-01-19 Tom Tromey <tromey@redhat.com>
296
297 PR c++/11026:
298 * dwarf2read.c (read_partial_die): Allocate partial DIE's name on
299 objfile obstack.
300
301 2010-01-19 Tom Tromey <tromey@redhat.com>
302
303 * top.c (stop_sig, float_handler, do_nothing): Remove.
304
305 2010-01-19 Jan Kratochvil <jan.kratochvil@redhat.com>
306
307 * breakpoint.c (watchpoint_check): Check the call
308 gdbarch_in_function_epilogue_p before calling frame_find_by_id.
309 Extend the comment.
310 * config/djgpp/fnchange.lst: Add translations for
311 watchpoint-cond-gone.exp, watchpoint-cond-gone.c and
312 watchpoint-cond-gone-stripped.c.
313
314 2010-01-19 Tom Tromey <tromey@redhat.com>
315
316 PR c++/8000:
317 * dwarf2read.c (partial_die_parent_scope): Put enumeration type
318 into parent scope, and enumerator into grandparent scope.
319
320 2010-01-19 Joel Brobecker <brobecker@adacore.com>
321
322 * NEWS: Add entry for "set/show ada trust-PAD-over-XVS" commands.
323
324 2010-01-19 Joel Brobecker <brobecker@adacore.com>
325
326 * configure.host: Make x86_64-*-solaris2.1[0-9]* an alias of
327 i[34567]86-*-solaris2.1[0-9]*.
328 * configure.tgt: Likewise.
329
330 2010-01-19 Joel Brobecker <brobecker@adacore.com>
331
332 * NEWS: Document the source command enhancement allowing it
333 to load Python scripts. Document the "set/show script-extension"
334 commands.
335
336 2010-01-19 Joel Brobecker <brobecker@adacore.com>
337
338 Add -Wunused-function to compile flags.
339 * configure.ac: Add -Wunused-function to build_warnings.
340 * configure: Regenerate.
341
342 2010-01-19 Joel Brobecker <brobecker@adacore.com>
343
344 "delete" ada-lex.c:input function, not used.
345 * ada-lex.l: #define YY_NO_INPUT.
346
347 2010-01-19 Joel Brobecker <brobecker@adacore.com>
348
349 Delete free_named_symtabs and associated cleanup.
350 * symfile.h (free_named_symtabs): Delete declaration.
351 * symfile.c: Remove some commented out code (clear_symtab_users_once).
352 (cashier_psymtab): Comment function out.
353 Delete declaration.
354 (free_named_symtabs): Delete.
355 * coffread.c (coff_end_symtab): Remove call to free_named_symtabs.
356 * dbxread.c (end_psymtab): Likewise.
357 * dwarf2read.c (process_psymtab_comp_unit): Ditto.
358 * exec.c (exec_close_1): Ditto.
359 * xcoffread.c (xcoff_end_psymtab): Likewise.
360
361 2010-01-19 Joel Brobecker <brobecker@adacore.com>
362
363 * stack.c (print_block_frame_labels): Comment function out.
364
365 2010-01-19 Joel Brobecker <brobecker@adacore.com>
366
367 Delete unused or undefined functions.
368 * breakpoint.c (ep_parse_optional_filename): Delete.
369 * dcache.c (dcache_write_line): Remove declaration.
370 * infrun.c (build_infrun): Remove declaration.
371 * tracepoint.c (tracepoint_save_command): Remove declaration.
372 * linux-nat.c (init_lwp_list): Delete. No longer used.
373 * event-loop.c (check_async_signal_handlers): Delete declaration.
374 * infrun.c (init_execution_control_state): Delete.
375 (proceed): Update comment to avoid mentioning
376 init_execution_control_state.
377 * target.c (kill_or_be_killed, nosupport_runtime): Delete.
378 * ada-lang.c (ada_to_static_fixed_value): Delete.
379 * scm-lang.c (evaluate_subexp_scm): Delete declaration.
380 * cp-namespace.c (cp_copy_usings): Delete.
381 * xml-syscall.c (xml_number_of_syscalls): Delete.
382 * progspace.c (find_program_space_by_num): Delete.
383 * inflow.c (handle_sigio): Delete declaration.
384 * hppa-tdep.c (hppa_alignof): Delete.
385 * mipsnbsd-tdep.c (mipsnbsd_sigtramp_offset)
386 (mipsnbsd_core_osabi_sniffer): Delete.
387
388 2010-01-18 Tom Tromey <tromey@redhat.com>
389
390 PR c++/9680:
391 * c-exp.y (REINTERPRET_CAST, DYNAMIC_CAST, STATIC_CAST)
392 (CONST_CAST): New tokens.
393 (exp): Add new productions.
394 (ident_tokens): Add const_cast, dynamic_cast, static_cast, and
395 reinterpret_cast.
396 (is_cast_operator): New function.
397 (yylex): Handle cast operators specially.
398 * eval.c (evaluate_subexp_standard) <UNOP_DYNAMIC_CAST,
399 UNOP_REINTERPRET_CAST>: New cases.
400 * expprint.c (print_subexp_standard): Likewise.
401 (op_name_standard): Likewise.
402 (dump_subexp_body_standard): Likewise.
403 * parse.c (operator_length_standard): Likewise.
404 * expression.h (enum exp_opcode): New constants UNOP_DYNAMIC_CAST,
405 UNOP_REINTERPRET_CAST.
406 * gdbtypes.c (class_types_same_p): New function.
407 (is_ancestor): Use it.
408 (is_public_ancestor): New function.
409 (is_unique_ancestor_worker): Likewise.
410 (is_unique_ancestor): Likewise.
411 * gdbtypes.h (class_types_same_p, is_public_ancestor)
412 (is_unique_ancestor): Declare.
413 * valops.c (value_reinterpret_cast): New function.
414 (dynamic_cast_check_1): Likewise.
415 (dynamic_cast_check_2): Likewise.
416 (value_dynamic_cast): Likewise.
417 * value.h (value_reinterpret_cast, value_dynamic_cast): Declare.
418
419 2010-01-18 Joel Brobecker <brobecker@adacore.com>
420
421 Fix build failure when building without Python support.
422 * python/python.c: Always include exceptions.h, even when HAVE_PYTHON
423 is not defined.
424
425 2010-01-18 Joel Brobecker <brobecker@adacore.com>
426
427 Use XVS field type instead of doing a parallel lookup.
428 * ada-lang.c (ada_get_base_type): Follow the XVS field type
429 if it is a reference type instead of doing a type lookup using
430 the XVS field name.
431
432 2010-01-18 Joel Brobecker <brobecker@adacore.com>
433
434 Trust PAD types instead of using PAD___XVS.
435 * ada-lang.c (trust_pad_over_xvs): New static variable.
436 (ada_is_aligner_type): If !trust_pad_over_xvs and there is a
437 parallel XVS type, follow the XVS type instead of the PAD type.
438 (unwrap_value): Make sure that there is no parallel XVE type
439 before returning the value as is.
440 (set_ada_list, show_ada_list): New static variables.
441 (set_ada_command, show_ada_command): New functions.
442 (_initialize_ada_language): Add new "set/show ada" prefix commands.
443 Add new "set/show ada trust-PAD-over-XVS" setting.
444
445 2010-01-18 Tom Tromey <tromey@redhat.com>
446 Thiago Jung Bauermann <bauerman@br.ibm.com>
447
448 Allow "source" to load python scripts.
449 * exceptions.h (enum errors): Add UNSUPPORTED_ERROR.
450 * python/python.c (source_python_script): New function.
451 * python/python.h (source_python_script): Add declaration.
452 * cli/cli-cmds.c: #include exceptions.h and python/python.h.
453 (script_ext_off, script_ext_soft, script_ext_strict)
454 (script_ext_enums, script_ext_mode): New static constants.
455 (show_script_ext_mode, find_and_open_script): New functions.
456 (source_script): Enhance to handle Python scripts.
457 (init_cli_cmds): Add set/show script-extension commands.
458
459 2010-01-16 Stan Shebs <stan@codesourcery.com>
460
461 * tracepoint.h (struct trace_status): Use unsigned long long
462 instead of size_t.
463 * tracepoint.c (trace_status_command): Fix printf directive.
464 (trace_save_command): Check fwrite returns, fix printf directive.
465 (trace_filename): New global.
466 (tfile_open): Set it, check read returns.
467 (tfile_close): Free trace_filename.
468 (tfile_get_traceframe_address): Check read returns.
469 (tfile_trace_find): Ditto.
470 (tfile_fetch_registers): Ditto.
471 (tfile_xfer_partial): Ditto.
472 (tfile_get_trace_state_variable_value): Ditto.
473
474 2010-01-15 Stan Shebs <stan@codesourcery.com>
475
476 Add trace file support.
477 * tracepoint.h (enum trace_stop_reason): New enum.
478 (struct trace_status): New struct.
479 (parse_trace_status): Declare.
480 (struct uploaded_tp): Move here from remote.c,
481 add fields for actions.
482 (struct uploaded_tsv): New struct.
483 * tracepoint.c (tfile_ops): New target vector.
484 (trace_fd): New global.
485 (tfile_open): New function.
486 (tfile_close): New function.
487 (tfile_files_info): New function.
488 (tfile_get_trace_status): New function.
489 (tfile_get_traceframe_address): New function.
490 (tfile_trace_find): New function.
491 (tfile_fetch_registers): New function.
492 (tfile_xfer_partial): New function.
493 (tfile_get_trace_state_variable_value): New function.
494 (init_tfile_ops): New function.
495 (_initialize_tracepoint): Call it, add tfile target.
496 (trace_status): New global.
497 (current_trace_status): New function.
498 (trace_running_p): Remove, change all users to get from
499 current_trace_status()->running.
500 (get_trace_status): Remove.
501 (trace_status_command): Call target_get_trace_status directly,
502 report more detail including tracing stop reasons.
503 (trace_find_command): Always allow tfind on a file.
504 (trace_find_pc_command): Ditto.
505 (trace_find_tracepoint_command): Ditto.
506 (trace_find_line_command): Ditto.
507 (trace_find_range_command): Ditto.
508 (trace_find_outside_command): Ditto.
509 (trace_frames_offset, cur_offset): Declare as off_t.
510 (trace_regblock_size): Rename from reg_size, update users.
511 (parse_trace_status): New function.
512 (tfile_interp_line): New function.
513 (disconnect_or_stop_tracing): Ensure current trace
514 status before asking what to do.
515 (stop_reason_names): New global.
516 (trace_save_command): New command.
517 (get_uploaded_tp): Move here from remote.c.
518 (find_matching_tracepoint): Ditto.
519 (merge_uploaded_tracepoints): New function.
520 (parse_trace_status): Use stop_reason_names.
521 (_initialize_tracepoint): Define tsave command.
522 * target.h (target_ops): New fields to_save_trace_data,
523 to_upload_tracepoints, to_upload_trace_state_variables,
524 to_get_raw_trace_data, change to_get_trace_status
525 to take a pointer to a status struct.
526 (target_save_trace_data): New macro.
527 (target_upload_tracepoints): New macro.
528 (target_upload_trace_state_variables): New macro.
529 (target_get_raw_trace_data): New macro.
530 * target.c (update_current_target): Add new methods, change
531 signature of to_get_trace_status.
532 * remote.c (hex2bin): Make globally visible.
533 (bin2hex): Ditto.
534 (remote_download_trace_state_variable): Download name also.
535 (remote_get_trace_status): Update parameter, use
536 parse_trace_status.
537 (remote_save_trace_data): New function.
538 (remote_upload_tracepoints): New function.
539 (remote_upload_trace_state_variables): New function.
540 (remote_get_raw_trace_data): New function.
541 (remote_start_remote): Use them.
542 (_initialize_remote_ops): Add operations.
543 * ax-gdb.c: Include breakpoint.h.
544 * breakpoint.c (create_tracepoint_from_upload): Use
545 break_command_really, return tracepoint, warn about unimplemented
546 parts.
547 * NEWS: Mention trace file addition.
548
549 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
550
551 Fix compilation warning on gcc-3.4.
552 * exec.c (print_section_info): Move the `displacement' variable
553 initialization to its declaration.
554
555 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
556
557 * gdb-gdb.py (StructMainTypePrettyPrinter): Fix TYPE_CODE_RANGE
558 comparison.
559
560 2010-01-15 Eric Botcazou <botcazou@adacore.com>
561
562 "info tasks" broken by typedefs in ATCB type definitions.
563 * ada-lang.c (ada_template_to_fixed_record_type_1): Add call to
564 ada_check_typedef before retrieving the length of the type for
565 regular fields.
566
567 2010-01-15 Joel Brobecker <brobecker@adacore.com>
568
569 Do not use name-based lookup for unconstrained packed arrays.
570 * ada-lang.c (find_parallel_type_by_descriptive_type):
571 Limit the fallback to name-based lookups to the case where
572 the type is a constrained packed array.
573
574 2010-01-15 Joel Brobecker <brobecker@adacore.com>
575
576 Enhance gdb-gdb.py to handle main_type.type_specific.
577 * gdb-gdb.py: Print the type-specific part of struct main_type.
578
579 2010-01-15 Jan Kratochvil <jan.kratochvil@redhat.com>
580
581 * configure.ac (AC_CHECK_FUNCS): Check for setrlimit and getrlimit.
582 * configure: Regenerate.
583 * config.in: Regenerate.
584 * utils.c: Include sys/resource.h.
585 (dump_core, can_dump_core): New.
586 (internal_vproblem): Update the comment. Check can_dump_core while
587 setting dump_core_p. Replace two abort calls by dump_core calls.
588
589 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
590 Eli Zaretskii <eliz@gnu.org>
591
592 * NEWS: Document the PIE support.
593
594 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
595
596 * linux-tdep.c: Remove includes gdbcore.h, observer.h and elf-bfd.h.
597 (check_is_pie_binary, _initialize_linux_tdep): Remove.
598
599 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
600
601 * solib-svr4.c (svr4_exec_displacement): New comment for entry_point.
602 Replace exec_entry_point call by bfd_get_start_address.
603
604 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
605
606 Support Valgrind attachments broken by the PIE support.
607 * auxv.c: Include gdbcore.h.
608 (procfs_xfer_auxv): Make static. Reduce its comment. Drop its
609 parameters ops, object and annex. Remove their assertions.
610 (ld_so_xfer_auxv, memory_xfer_auxv): New function.
611 * auxv.h (procfs_xfer_auxv): Remove comment. Rename to ...
612 (memory_xfer_auxv): ... here.
613 * linux-nat.c (linux_xfer_partial): Rename procfs_xfer_auxv to
614 memory_xfer_auxv.
615 * procfs.c (procfs_xfer_partial): Likewise.
616 * solib-svr4.c (svr4_relocate_main_executable): New prototype.
617 (svr4_special_symbol_handling): Call svr4_relocate_main_executable.
618 (svr4_solib_create_inferior_hook): Conditionalize the
619 svr4_relocate_main_executable call.
620
621 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
622
623 * solib-svr4.c (scan_dyntag): Remove variable dyn_addr. New variable
624 target_section. Find SECT in current_target_sections, gdb_assert it.
625 (elf_lookup_lib_symbol): Pass the binary file if given symfile_objfile.
626 New variable abfd.
627 * symtab.c (lookup_objfile_from_block): Return the binary file instead
628 of separate debug info file.
629
630 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
631
632 Support PIEs with no symfile_objfile.
633 * exec.c (print_section_info <abfd == exec_bfd>): Relocate Entry point.
634 * solib-svr4.c (svr4_relocate_main_executable <exec_bfd>): New block.
635
636 2010-01-14 Jan Kratochvil <jan.kratochvil@redhat.com>
637
638 * solib-svr4.c (svr4_relocate_main_executable): Move the static exec
639 code part to ...
640 (svr4_static_exec_displacement): ... a new function.
641 (svr4_exec_displacement): New function.
642 (svr4_relocate_main_executable): Call svr4_exec_displacement. Allocate
643 new_offsets using alloca now. Remove variable old_chain and changed.
644 Call objfile_relocate unconditionally now.
645
646 2010-01-14 Doug Evans <dje@google.com>
647
648 * gdbtypes.c (arch_flags_type): Fix comment.
649 * gdbtypes.h (arch_composite_type): Fix comment.
650
651 2009-01-14 Tristan Gingold <gingold@adacore.com>
652
653 * machoread.c (macho_add_oso_symfile): Add symfile_flags parameter.
654 Call xstrdup for abfd->filename. Pass symfile_flags and objfile flags
655 to symbol_file_add_from_bfd. Add OSO as separate objfile.
656 (macho_oso_symfile): Add symfile_flags parameter. Pass it to
657 macho_add_oso_symfile.
658 (macho_symfile_read): Pass symfile_flags to macho_oso_symfile.
659
660 2010-01-14 Joel Brobecker <brobecker@adacore.com>
661
662 Tru64: Dead threads are never deleted.
663 * dec-thread.c (dec_thread_ptid_is_alive): New function.
664 (dec_thread_count_gdb_threads): Fix counter increment.
665 (dec_thread_add_gdb_thread): Fix *listp increment.
666 (resync_thread_list): Fix bug in deletion of dead threads that
667 caused all threads to be deleted, instead of just the dead ones.
668
669 2010-01-13 Phil Muldoon <pmuldoon@redhat.com>
670
671 PR python/10705
672
673 * python/python-internal.h: Add lazy_string_object_type
674 definition.
675 (create_lazy_string_object, gdbpy_initialize_lazy_string)
676 (gdbpy_is_lazystring, gdbpy_extract_lazy_string): Define.
677 * python/py-value.c (valpy_lazy_string): New function.
678 (convert_value_from_python): Add lazy string conversion.
679 * python/py-prettyprint.c (pretty_print_one_value): Check if
680 return is also a lazy string.
681 (print_string_repr): Add lazy string printing branch.
682 (print_children): Likewise.
683 * python/py-lazy-string.c: New file. Implement lazy strings.
684 * python/python.c (_initialize_python): Call
685 gdbpy_initialize_lazy_string.
686 * varobj.c (value_get_print_value): Add lazy string printing
687 branch. Account for encoding.
688 * c-lang.c (c_printstr): Account for new encoding argument. If
689 encoding is NULL, find encoding suited for type, otherwise use
690 user encoding.
691 * language.h (language_defn): Add encoding argument.
692 (LA_PRINT_STRING): Likewise.
693 * language.c (unk_lang_printstr): Update to reflect new encoding
694 argument to language_defn.
695 * ada-lang.h (ada_printstr): Likewise.
696 * c-lang.h (c_printstr): Likewise.
697 * p-lang.h (pascal_printstr);
698 * f-lang.c (f_printstr): Likewise.
699 * m2-lang.c (m2_printstr): Likewise.
700 * objc-lang.c (objc_printstr): Likewise.
701 * p-lang.c (pascal_printstr): Likewise.
702 * scm-lang.c (scm_printstr): Likewise.
703 * c-valprint.c (c_val_print): Update LA_PRINT_STRING call for
704 encoding argument.
705 * ada-valprint.c (ada_printstr): Likewise.
706 * f-valprint.c (f_val_print): Likewise
707 * m2-valprint.c (m2_val_print): Likewise.
708 * p-valprint.c (pascal_val_print): Likewise.
709 * expprint.c (print_subexp_standard): Likewise.
710 * valprint.c (val_print_string): Likewise.
711 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-lazy-string.
712 (SUBDIR_PYTHON_SRCS): Likewise.
713 (py-lazy-string.o): New rule.
714
715 2010-01-13 Doug Evans <dje@google.com>
716
717 * mi/mi-main.c (list_available_thread_groups): Avoid "may be used
718 uninitialized" warning from gcc on local `tree'.
719
720 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
721
722 Implement core awareness.
723
724 * bcache.c (compare_ints): Remove
725 (print_percentage): Use compare_positive_ints.
726 * defs.h (compare_positive_ints): Declare.
727 * linux-nat.h (struct lin_lwp): New field core.
728 (linux_nat_core_of_thread_1): Declare.
729 * linux-nat.c (add_lwp): Init the 'core' field.
730 (linux_nat_wait_1): Record the core.
731 (linux_nat_core_of_thread_1, linux_nat_core_of_thread): New.
732 (linux_nat_add_target): Register the above.
733 * linux-thread-db.c (update_thread_core): New.
734 (thread_db_find_new_threads): Update core information for
735 every thread.
736 * remote.c (struct private_thread_info): New.
737 (free_private_thread_info, demand_private_info): New.
738 (PACKET_qXfer_threads, use_osdata_threads): New.
739 (struct thread_item, threads_parsing_context
740 (start_thread, end_thread, thread_attributes)
741 (thread_children, threads_children, threads_elements): New.
742 (remote_threads_info): Try qXfer:threads before anything
743 else.
744 (remote_protocol_packets): Register qXfer:threads.
745 (remote_open_1): Init use_osdata_threads.
746 (struct stop_reply): New field 'core'.
747 (remote_parse_stop_reply): Parse core number.
748 (process_stop_reply): Record core number.
749 (remote_xfer_partial): Handle qXfer:threads.
750 (remote_core_of_thread): New.
751 (init_remote_ops): Register remote_core_of_thread.
752 (_initialize_remote): Register qXfer:read.
753 * target.c (target_core_of_thread): New
754 * target.h (enum target_object): New value TARGET_OBJECT_THREADS.
755 (struct target_ops): New field to_core_of_threads.
756 (target_core_of_thread): Declare.
757 * gdbthread.h (struct thread_info): New field private_dtor.
758 * thread.c (print_thread_info): Report the core.
759 * ui-out.c (MAX_UI_OUT_LEVELS): Increase.
760 * utils.c (compare_positive_ints): New.
761 * features/threads.dtd: New.
762 * mi/mi-interp.c (mi_on_normal_stop): Report the core.
763 * mi/mi-main.c (struct collect_cores_data, collect_cores)
764 (do_nothing, free_vector_of_osdata_items)
765 (splay_tree_int_comparator, free_splay_tree): New.
766 (print_one_inferior_data): Implemented printing of selected
767 inferiors. Collect and print cores.
768 (output_cores): New.
769 (mi_cmd_list_thread_groups): Support --recurse. Permit specifying
770 thread groups together with --available.
771
772 2010-01-12 Jan Kratochvil <jan.kratochvil@redhat.com>
773
774 * configure: Regenerate (for _STRUCTURED_PROC).
775
776 2010-01-12 Joel Brobecker <brobecker@adacore.com>
777
778 Delete dead function.
779 * ada-lang.c (extract_string): Delete. No longer used.
780
781 2010-01-12 Joel Brobecker <brobecker@adacore.com>
782
783 Fix -Wunused warning in dec-thread.c.
784 * dec-thread.c (dec_thread_count_gdb_threads)
785 (dec_thread_add_gdb_thread): Prevent -Wunused warning.
786
787 2010-01-12 Joel Brobecker <brobecker@adacore.com>
788
789 * ada-valprint.c (ada_print_floating): Remove trailing space.
790
791 2010-01-12 Joel Brobecker <brobecker@adacore.com>
792
793 Add support for DW_AT_GNAT_descriptive_type.
794 * gdbtypes.h (enum type_specific_kind): New enum.
795 (struct main_type) [type_specific_field]: New component.
796 [type_specific]: Add new component "gnat_stuff".
797 (struct gnat_aux_type): New type.
798 (INIT_CPLUS_SPECIFIC): Also set TYPE_SPECIFIC_FIELD (type).
799 (HAVE_CPLUS_STRUCT): Also check TYPE_SPECIFIC_FIELD (type).
800 (gnat_aux_default, allocate_gnat_aux_type): Add declaration.
801 (INIT_GNAT_SPECIFIC, ALLOCATE_GNAT_AUX_TYPE, HAVE_GNAT_AUX_INFO)
802 (TYPE_SPECIFIC_FIELD): New macros.
803 (TYPE_CPLUS_SPECIFIC): Return cplus_struct_default if the given
804 type does not hold any cplus-specific data.
805 (TYPE_RAW_CPLUS_SPECIFIC): New macro.
806 (TYPE_GNAT_SPECIFIC, TYPE_DESCRIPTIVE_TYPE): New macros.
807 (TYPE_IS_OPAQUE): Use HAVE_CPLUS_STRUCT to check if type has
808 cplus-specific data.
809 * gdbtypes.c (allocate_cplus_struct_type): Minor stylistic rewrite.
810 Set new component TYPE_SPECIFIC_FIELD (type).
811 (gnat_aux_default): New constant.
812 (allocate_gnat_aux_type): New function.
813 (init_type): Add initialization the type-specific stuff for
814 TYPE_CODE_FLT and TYPE_CODE_FUNC types.
815 (print_gnat_stuff): New function.
816 (recursive_dump_type): Use HAVE_CPLUS_STRUCT to check for cplus-
817 specific data. Adjust code that prints the contents of the
818 type-specific union using the TYPE_SPECIFIC_FIELD value.
819 * dwarf2read.c (dwarf2_attach_fields_to_type): Do not allocate
820 the type cplus stuff for Ada types.
821 (dwarf2_add_member_fn, dwarf2_attach_fn_fields_to_type):
822 Error out if these routines are called with an Ada type.
823 (read_structure_type, read_array_type, read_subrange_type):
824 Add call to set_descriptive_type.
825 (set_die_type): Initialize the gnat-specific data if necessary.
826 (need_gnat_info, die_descriptive_type, set_descriptive_type):
827 New functions.
828 * ada-lang.c (decode_constrained_packed_array_type): Use
829 decode_constrained_packed_array_type instead of doing a standard
830 lookup to locate a parallel type.
831 (find_parallel_type_by_descriptive_type): New function.
832 (ada_find_parallel_type_with_name): New function.
833 (ada_find_parallel_type): Reimplement using
834 ada_find_parallel_type_with_name.
835 * ada-valprint.c (print_field_values): Use HAVE_CPLUS_STRUCT
836 to check if type has a cplus stuff.
837 * linespec.c (total_number_of_methods): Likewise.
838 * mdebugread.c (new_type): Likewise.
839
840 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
841
842 * NEWS: Document the 0b binary number prefix parsing.
843
844 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
845
846 * objfiles.c (objfile_relocate1): Change the return type to int.
847 Describe the new return value. Return non-zero if data changed.
848 (objfile_relocate): New variable changed. Set it. Call
849 breakpoint_re_set depending on CHANGED.
850
851 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
852
853 Implement binary numbers parsing.
854 * c-exp.y (parse_number): New case 'b' and 'B'.
855
856 2010-01-11 Jan Kratochvil <jan.kratochvil@redhat.com>
857 Tristan Gingold <gingold@adacore.com>
858
859 * solib.c (info_sharedlibrary_command): Replace
860 objfile_has_partial_symbols and objfile_has_full_symbols calls by
861 objfile_has_symbols.
862
863 2010-01-10 Joel Brobecker <brobecker@adacore.com>
864
865 * NEWS: Document the improvements made to the mips-irix port.
866
867 2010-01-09 Joel Brobecker <brobecker@adacore.com>
868
869 Fix the documentation of valprint.c:value_print.
870 * valprint.c (value_print): Update the function description to
871 mention that the syntax of the output follows the current_language,
872 not necessarily C.
873
874 2010-01-09 Jan Kratochvil <jan.kratochvil@redhat.com>
875
876 Fix displacement of separate debug info files.
877 * objfiles.c (objfile_relocate): Rename to ...
878 (objfile_relocate1): ... here and make it static. Extend the comment.
879 (objfile_relocate): New function.
880 * solib-spu.c (spu_relocate_main_executable): Explicitly check if
881 SYMFILE_OBJFILE is NULL. Remove variables objfile and old_chain.
882 Remove following of SEPARATE_DEBUG_OBJFILE. new_offsets is now
883 allocated using alloca.
884 * symfile.c (copy_section_addr_info): Remove.
885 (build_section_addr_info_from_objfile): Make it global. New variables
886 addr_bit and mask, use them.
887 * symfile.h (build_section_addr_info_from_objfile): New prototype.
888 (copy_section_addr_info): Remove.
889
890 2010-01-09 Joel Brobecker <brobecker@adacore.com>
891
892 Signal unwinder for mips-irix N32.
893 * mips-irix-tdep.c: #include mips-tdep.h, trad-frame.h, and
894 tramp-frame.h.
895 (SIGTRAMP_FRAME_SIZE, SIGCONTEXT_PC_OFF, SIGCONTEXT_REGS_OFF)
896 (SIGCONTEXT_FPREGS_OFF, SIGCONTEXT_FPCSR_OFF, SIGCONTEXT_HI_OFF)
897 (SIGCONTEXT_LO_OFF): New macros.
898 (mips_irix_n32_tramp_frame_init): New function.
899 (mips_irix_n32_tramp_frame): New static constant.
900 (mips_irix_init_abi): Prepend the mips_irix_n32_tramp_frame unwinder.
901
902 2010-01-09 Joel Brobecker <brobecker@adacore.com>
903
904 Breakpoint in shared library does not work on mips-irix.
905 * procfs.c: #include "observer.h".
906 (procfs_inferior_created): New function, moving here the code
907 which unsets the syssgi syscall-exit notifications.
908 (procfs_create_inferior): Remove the code which unsets the syssgi
909 syscall-exit notifications. It is too early to do this here.
910 (_initialize_procfs): Attach the procfs_inferior_created observer.
911
912 2010-01-09 Joel Brobecker <brobecker@adacore.com>
913
914 Wrong return convention for arrays (mips-irix).
915 * mips-tdep.c (mips_n32n64_return_value): Arrays whose size is
916 128 bits or smaller are returned the same way as structs
917 and unions of the the same size.
918
919 2010-01-09 Joel Brobecker <brobecker@adacore.com>
920
921 Cannot set the PC on mips-irix.
922 * irix5-nat.c (fill_gregset): Check regno against the raw PC
923 register number, no the cooked one.
924
925 2010-01-09 Joel Brobecker <brobecker@adacore.com>
926
927 Error while loading core file on mips-irix.
928 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing
929 if debugging from a core file.
930
931 2010-01-09 Joel Brobecker <brobecker@adacore.com>
932
933 GDB hangs when attaching to process on mips-irix.
934 * solib-irix.c (irix_solib_create_inferior_hook): Do nothing if
935 attaching to a process.
936
937 2010-01-09 Joel Brobecker <brobecker@adacore.com>
938
939 Use the correct breakpoint instruction on mips-irix.
940 * mips-tdep.c (mips_breakpoint_from_pc): Add new static variable
941 containing the correct breakpoint instruction to use on mips-irix.
942 Use it when the osabi is GDB_OSABI_IRIX.
943
944 2010-01-09 Joel Brobecker <brobecker@adacore.com>
945
946 -Wunused warning in procfs.c (mips-irix only).
947 * procfs.c (gdb_praddset, gdb_prdelset): New macros. Use them
948 throughout instead of using praddset and prdelset respectively.
949
950 2010-01-09 Joel Brobecker <brobecker@adacore.com>
951
952 GDB crash while stepping into function.
953 * infrun.c (handle_inferior_event): Refetch the current frame
954 after handling what.main_action, in case that pointer became
955 dangling.
956
957 2010-01-09 Joel Brobecker <brobecker@adacore.com>
958
959 Fix build failure of solaris-hosted cross debuggers.
960 * ada-valprint.c, parse.c: Include defs.h before including ctype.h.
961
962 2010-01-09 Daniel Gutson <dgutson@codesourcery.com>
963
964 Fix build failure on sparc-solaris.
965 * procfs.c: (procfs_do_thread_registers) Use elfcore_write_lwpstatus.
966
967 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
968
969 Move some symfile code into subroutines.
970 * symfile.h (relative_addr_info_to_section_offsets)
971 (addr_info_make_relative): New prototypes.
972 * symfile.c (default_symfile_offsets): Move a part to ...
973 (relative_addr_info_to_section_offsets): ... this new function.
974 (default_symfile_offsets): Call it.
975 (syms_from_objfile <!mainline && addrs && addrs->other[0].name>): Move
976 this part to ...
977 (addr_info_make_relative): ... this new function.
978
979 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
980
981 Add from_tty to solib_create_inferior_hook.
982 * infcmd.c (post_create_inferior): Move solib_add after
983 solib_create_inferior_hook. Pass from_tty to
984 solib_create_inferior_hook. Call solib_add and SOLIB_ADD with
985 0 from_tty and comment why.
986 * infrun.c (follow_exec): Pass from_tty solib_create_inferior_hook as 0.
987 * linux-nat.c (linux_child_follow_fork): Likewise.
988 * nto-procfs.c (procfs_post_attach, procfs_create_inferior): Likewise.
989 * solib-darwin.c (darwin_solib_create_inferior_hook): New parameter
990 from_tty.
991 * solib-frv.c (frv_solib_create_inferior_hook): Likewise.
992 * solib-irix.c (irix_solib_create_inferior_hook): Likewise.
993 * solib-null.c (null_solib_create_inferior_hook): Likewise.
994 * solib-osf.c (osf_solib_create_inferior_hook): Likewise.
995 * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
996 * solib-som.c (som_solib_create_inferior_hook): Likewise.
997 * solib-spu.c (spu_solib_create_inferior_hook): New parameter from_tty.
998 Pass it to svr4_so_ops.solib_create_inferior_hook.
999 * solib-sunos.c (sunos_solib_create_inferior_hook): New parameter
1000 from_tty.
1001 * solib-svr4.c (enable_break): New parameter from_tty. Pass it to
1002 solib_add.
1003 (svr4_solib_create_inferior_hook): New parameter from_tty. Pass it to
1004 enable_break.
1005 * solib-target.c (solib_target_solib_create_inferior_hook): New
1006 parameter from_tty.
1007 * solib.c (solib_create_inferior_hook): New parameter from_tty. Pass
1008 it to ops->solib_create_inferior_hook.
1009 (reload_shared_libraries): Pass from_tty to solib_create_inferior_hook.
1010 Move solib_add after solib_create_inferior_hook, call it now with
1011 from_tty as 0. New comment there.
1012 * solib.h (solib_create_inferior_hook): New parameter from_tty.
1013 * solist.h (struct target_so_ops <solib_create_inferior_hook>):
1014 Likewise.
1015
1016 2010-01-08 Vladimir Prus <vladimir@codesourcery.com>
1017
1018 Fix multiexec race.
1019 * infrun.c (handle_inferior_event): Use get_thread_regcache
1020 with events ptid, not get_current_regcache.
1021
1022 2009-01-08 Joel Brobecker <brobecker@adacore.com>
1023
1024 GDB crash with empty executable name (MinGW).
1025 * source.c (openp): Add assert that parameter string is not NULL.
1026 if parameter string is an empty string, then return with a failure
1027 immediately.
1028
1029 2009-01-08 Joel Brobecker <brobecker@adacore.com>
1030
1031 Get rid of support for VAX Floats.
1032 * ada-lang.h (ada_is_vax_floating_type, ada_vax_float_type_suffix)
1033 (ada_vax_float_print_function): Delete.
1034 * ada-lang.c (ada_is_vax_floating_type, ada_vax_float_type_suffix)
1035 (ada_vax_float_print_function): Delete.
1036 * ada-typeprint.c (print_vax_floating_point_type): Delete.
1037 (ada_print_type): Remove support for VAX floats.
1038 * ada-valprint.c (ada_val_print_1): Remove support for VAX floats.
1039
1040 2010-01-08 Jan Kratochvil <jan.kratochvil@redhat.com>
1041
1042 * stabsread.c (read_args): Handle zero arguments.
1043
1044 2009-01-08 Joel Brobecker <brobecker@adacore.com>
1045
1046 Cannot find in-tree libiconv.a after reconfigure.
1047 * acinclude.m4 (AM_ICONV): If we find an in-tree libiconv.a
1048 that we can use, then cache the path to this archive.
1049 * configure: Regenerate.
1050
1051 2010-01-07 Stan Shebs <stan@codesourcery.com>
1052
1053 Make tracepoint operations go through target vector.
1054 * target.h (enum trace_find_type): New enum.
1055 (struct target_ops): New fields to_trace_init,
1056 to_download_tracepoint, to_download_trace_state_variable,
1057 to_trace_set_readonly_regions, to_trace_start, to_get_trace_status,
1058 to_trace_stop, to_trace_find, to_get_trace_state_variable_value,
1059 to_set_disconnected_tracing.
1060 (target_trace_init): New macro.
1061 (target_download_tracepoint): New macro.
1062 (target_download_trace_state_variable): New macro.
1063 (target_trace_start): New macro.
1064 (target_trace_set_readonly_regions): New macro.
1065 (target_get_trace_status): New macro.
1066 (target_trace_stop): New macro.
1067 (target_trace_find): New macro.
1068 (target_get_trace_state_variable_value): New macro.
1069 (target_set_disconnected_tracing): New macro.
1070 * target.c (update_current_target): Inherit and set defaults for
1071 tracepoint operations.
1072 * tracepoint.c (default_collect): Make globally visible.
1073 (target_is_remote): Remove, along with all calls.
1074 (tvariables_info): Call target_get_trace_state_variable_value.
1075 (remote_set_transparent_ranges): Remove.
1076 (trace_start_command): Call target_trace_init,
1077 target_download_tracepoint, etc.
1078 (download_tracepoint): Remove.
1079 (trace_stop_command): Simplify.
1080 (stop_tracing): Call target_trace_stop.
1081 (get_trace_status): Call target_get_trace_status.
1082 (trace_status_command): Add case for targets that cannot trace.
1083 (finish_tfind_command): Change to take numerical arguments, call
1084 target_trace_find.
1085 (trace_find_command): Update call to finish_tfind_command.
1086 (trace_find_pc_command): Ditto.
1087 (trace_find_tracepoint_command): Ditto.
1088 (trace_find_line_command): Ditto.
1089 (trace_find_range_command): Ditto.
1090 (trace_find_outside_command): Ditto.
1091 (set_disconnected_tracing_value): Call
1092 target_set_disconnected_tracing.
1093 * remote.c: Add protocol encoding bits from tracepoint.c.
1094 (trace_error): Move from tracepoint.c.
1095 (remote_get_noisy_reply): Ditto.
1096 (free_actions_list_cleanup_wrapper): Ditto.
1097 (free_actions_list): Ditto.
1098 (remote_trace_init): New function.
1099 (remote_download_tracepoint): New function.
1100 (remote_download_trace_state_variable): New function.
1101 (remote_trace_set_readonly_regions): New function.
1102 (remote_trace_start): New function.
1103 (remote_get_trace_status): New function.
1104 (remote_trace_stop): New function.
1105 (remote_trace_find): New function.
1106 (remote_download_trace_state_variable): New function.
1107 (remote_set_disconnected_tracing): New function.
1108 (init_remote_ops): Add tracepoint operations.
1109
1110 * tracepoint.c (trace_dump_command): Don't decr_pc_after_break.
1111
1112 2010-01-07 Tristan Gingold <gingold@adacore.com>
1113
1114 * symfile.c (build_section_addr_info_from_objfile): New function.
1115 (symbol_file_add_separate): Don't use offsets from objfile but
1116 built an addr info.
1117
1118 2010-01-06 Stan Shebs <stan@codesourcery.com>
1119
1120 Support disconnected tracing.
1121 * infcmd.c (detach_command): Ask whether to stop tracing.
1122 * cli/cli-cmds.c (quit_command): Ditto.
1123 * breakpoint.h (struct breakpoint): New field number_on_target.
1124 * breakpoint.c (create_tracepoint_from_upload): New function.
1125 (get_tracepoint_by_number_on_target): New function.
1126 * remote.c (struct remote): New field disconnected_tracing.
1127 (remote_disconnected_tracing_feature): New function.
1128 (remote_protocol_features): Add DisconnectedTracing.
1129 (struct uploaded_tp): New struct.
1130 (uploaded_tps): New global.
1131 (get_uploaded_tp): New function.
1132 (find_matching_tracepoint): New function.
1133 (remote_get_tracing_state): New function.
1134 (remote_start_remote): Call it.
1135 * tracepoint.c (disconnected_tracing): New global.
1136 (trace_start_command): Initialize number_on_target.
1137 (stop_tracing): New function, split out from...
1138 (trace_stop_command): Call stop_tracing.
1139 (get_trace_status): New function, split out from...
1140 (trace_status_command): Call get_trace_status, add info on
1141 disconnection behavior.
1142 (disconnect_or_stop_tracing): New function.
1143 (finish_tfind_command): Translate from number on target.
1144 (trace_find_tracepoint_command): Translate to number on target.
1145 (send_disconnected_tracing_value): New function.
1146 (set_disconnected_tracing): New function.
1147 (_initialize_tracepoint): Add disconnected-tracing variable.
1148 * NEWS: Mention disconnected tracing.
1149
1150 2010-01-06 Tristan Gingold <gingold@adacore.com>
1151
1152 * symtab.c (lookup_global_symbol_from_objfile): Rename objfile
1153 parameter to main_objfile. Iterate on all separate debug objfiles.
1154 * symfile.h (symbol_file_add_separate)
1155 (find_separate_debug_file_by_debuglink): Remove parameter names.
1156 * symfile.c (symbol_file_add_separate): Use add_separate_objfile.
1157 (reread_symbols): Use free_objfile_separate_debug.
1158 * objfiles.h (struct objfile): Add separate_debug_objfile_link.
1159 Adjust comment.
1160 (objfile_separate_debug_iterate, add_separate_debug_objfile)
1161 (free_objfile_separate_debug): New prototypes.
1162 * objfiles.c (objfile_separate_debug_iterate): New function.
1163 (add_separate_debug_objfile, free_objfile_separate_debug): New
1164 functions.
1165 (free_objfile): Use free_objfile_separate_debug. Adjust for
1166 multiple separate debug objfile.
1167 (objfile_has_symbols): Adjust comment. Iterate on all separate
1168 debug objfiles.
1169 * minsyms.c (lookup_minimal_symbol): Adjust for multiple separate
1170 debug objfile.
1171 (lookup_minimal_symbol_text): Ditto.
1172 (lookup_minimal_symbol_by_pc_name): Ditto.
1173 (lookup_minimal_symbol_solib_trampoline): Ditto.
1174 (lookup_minimal_symbol_by_pc_section_1): Iterate on all separate
1175 debug objfiles.
1176
1177 2010-01-05 Stan Shebs <stan@codesourcery.com>
1178
1179 Add fast tracepoints.
1180 * arch-utils.h (default_fast_tracepoint_valid_at): Declare.
1181 * arch-utils.c (default_fast_tracepoint_valid_at): New function.
1182 * breakpoint.h (enum bptype): Add bp_fast_tracepoint.
1183 * breakpoint.c (tracepoint_type): New function.
1184 (ALL_TRACEPOINTS): Use it.
1185 (should_be_inserted): Ditto.
1186 (bpstat_check_location): Ditto.
1187 (print_one_breakpoint_location): Ditto.
1188 (user_settable_breakpoint): Ditto.
1189 (set_breakpoint_location_function): Ditto.
1190 (disable_breakpoints_in_shlibs): Ditto.
1191 (delete_trace_command): Ditto.
1192 (print_it_typical): Add bp_fast_tracepoint case.
1193 (bpstat_what): Ditto.
1194 (print_one_breakpoint_location): Ditto.
1195 (allocate_bp_location): Ditto.
1196 (mention): Ditto.
1197 (breakpoint_re_set_one): Ditto.
1198 (disable_command): Ditto.
1199 (enable_command): Ditto.
1200 (check_fast_tracepoint_sals): New function.
1201 (break_command_really): Call it.
1202 (ftrace_command): New function.
1203 (_initialize_breakpoint): Add ftrace command.
1204 * gdbarch.sh (fast_tracepoint_valid_at): New.
1205 * gdbarch.h, gdbarch.c: Regenerate.
1206 * i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
1207 (i386_gdbarch_init): Use it.
1208 * remote.c (struct remote_state): New field fast_tracepoints.
1209 (PACKET_FastTracepoints): New packet config type.
1210 (remote_fast_tracepoint_feature): New function.
1211 (remote_protocol_features): Add FastTracepoints.
1212 (remote_supports_fast_tracepoints): New function.
1213 (_initialize_remote): Add FastTracepoints.
1214 * tracepoint.c (download_tracepoint): Add fast tracepoint option.
1215 * NEWS: Mention fast tracepoints.
1216
1217 2010-01-06 Joel Brobecker <brobecker@adacore.com>
1218
1219 * gdb-gdb.py: New file.
1220
1221 2010-01-05 Michael Snyder <msnyder@vmware.com>
1222
1223 * infrun.c (handle_inferior_event): Fix typo in comment.
1224
1225 2010-01-05 Jan Kratochvil <jan.kratochvil@redhat.com>
1226
1227 * symfile.c (syms_from_objfile): Remove the !MAINLINE conditional.
1228
1229 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
1230
1231 * features/Makefile (WHICH): Add s390-linux32, s390-linux64,
1232 and s390x-linux64.
1233 (s390-linux32-expedite): Define.
1234 (s390-linux64-expedite): Define.
1235 (s390x-linux64-expedite): Define.
1236 * features/s390-acr.xml: New file.
1237 * features/s390-fpr.xml: New file.
1238 * features/s390-core32.xml: New file.
1239 * features/s390-core64.xml: New file.
1240 * features/s390x-core64.xml: New file.
1241 * features/s390-linux32.xml: New file.
1242 * features/s390-linux64.xml: New file.
1243 * features/s390x-linux64.xml: New file.
1244 * features/s390-linux32.c: New generated file.
1245 * features/s390-linux64.c: New generated file.
1246 * features/s390x-linux64.c: New generated file.
1247
1248 * regformats/s390-linux32.dat: New generated file.
1249 * regformats/s390-linux64.dat: New generated file.
1250 * regformats/s390x-linux64.dat: New generated file.
1251 * regformats/reg-s390.dat: Remove.
1252 * regformats/reg-s390x.dat: Remove.
1253
1254 * s390-nat.c: Include "auxv.h" and <elf.h>.
1255 (HWCAP_S390_HIGH_GPRS): Define if undefined.
1256 (s390_target_wordsize): New function.
1257 (s390_auxv_parse): Likewise.
1258 (s390_get_hwcap): Likewise.
1259 (s390_read_description): Likewise.
1260 (_initialize_s390_nat): Install s390_auxv_parse and
1261 s390_read_description.
1262
1263 * s390-tdep.c: Include "features/s390-linux32.c",
1264 "features/s390-linux64.c", and "features/s390x-linux64.c".
1265 (struct gdbarch_tdep): Add gpr_full_regnum, pc_regnum, and cc_regnum.
1266 (s390_register_call_saved): New function.
1267 (s390_register_name): Remove.
1268 (s390_register_type): Remove.
1269 (s390_dwarf_regmap): Add lower half GPR pseudo DWARF CFI regnums.
1270 (s390_dwarf_reg_to_regnum): Remap GPR regnums to full GPRs.
1271 (s390_adjust_frame_regnum): Remap GPR regnums to lower halves for CFI.
1272 (s390_pseudo_register_name): New function.
1273 (s390_pseudo_register_type): New function.
1274 (s390_pseudo_register_read): Handle both 32-bit and 64-bit cases.
1275 Handle full GPR pesudos and varying pseudo register numbers.
1276 (s390_pseudo_register_write): Likewise
1277 (s390x_pseudo_register_read): Remove.
1278 (s390x_pseudo_register_write): Likewise.
1279 (s390_register_group): Remove.
1280 (s390_pseudo_register_group): New function.
1281 (s390_regmap_gregset): Add GPR upper halves.
1282 (s390x_regmap_gregset): Likewise.
1283 (s390_regmap_fpregset): Likewise.
1284 (s390_regmap_upper): New global variable.
1285 (s390_upper_regset): New global variable.
1286 (s390_upper_regset_sections): New global variable.
1287 (s390_regset_from_core_section): Handle GPR upper halves.
1288 (s390_core_read_description): New function.
1289 (s390_prologue_frame_unwind_cache): Set up ABI call-saved/clobbered
1290 register information. Handle varying pseudo register numbers.
1291 (s390_backchain_frame_unwind_cache): Likewise.
1292 (s390_frame_prev_register): Unwind full GPRs to show lower halves.
1293 (s390_stub_frame_unwind_cache): Handle varying pseudo register numbers.
1294 (s390_sigtramp_frame_unwind_cache): Unwind PSWM and PSWA as well as
1295 PC and CC pseudos. Unwind upper halves and full GPRs as appropriate.
1296 Handle varying pseudo register numbers.
1297 (s390_unwind_pc): Handle varying pseudo register numbers.
1298 (s390_dwarf2_prev_register): New function.
1299 (s390_dwarf2_frame_init_reg): Set up ABI call-saved/clobbered
1300 register information. Handle varying pseudo register numbers.
1301 Install s390_dwarf2_prev_register to unwind full GPRs.
1302 (s390_gdbarch_init): Handle target descriptions. Assign varying
1303 pseudo register numbers. Install s390_adjust_frame_regnum.
1304 (_initialize_s390_tdep): Initialize target descriptions.
1305
1306 * s390-tdep.h (S390_R0_UPPER_REGNUM .. S390_R15_UPPER_REGNUM): Define.
1307 (S390_NUM_REGS): Redefine to include upper half registers.
1308 (S390_PC_REGNUM, S390_CC_REGNUM): Remove.
1309 (S390_NUM_PSEUDO_REGS, S390_NUM_TOTAL_REGS): Likewise.
1310 (tdesc_s390_linux32): Add declaration.
1311 (tdesc_s390_linux64): Likewise.
1312 (tdesc_s390x_linux64): Likewise.
1313
1314 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
1315
1316 * regset.h (struct core_regset_section): Add HUMAN_NAME.
1317 * i386-linux-tdep.c (i386_linux_regset_sections): Fill in HUMAN_NAME.
1318 * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections): Likewise.
1319 (ppc_linux_vmx_regset_sections): Likewise.
1320 (ppc_linux_fp_regset_sections): Likewise.
1321
1322 * corelow.c (get_core_register_section): Constify arguments.
1323 (get_core_registers): Use gdbarch_core_regset_sections instead
1324 of hard-coded platform-specific register section names.
1325
1326 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
1327
1328 * dwarf2loc.c (read_pieced_value): If a piece occupies part of
1329 a register, assume the least-significant part is used.
1330 (write_pieced_value): Likewise.
1331
1332 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
1333
1334 * printcmd.c: Include "arch-utils.h".
1335 (do_one_display): Re-parse expression if current architecture changed.
1336
1337 2010-01-03 Jan Kratochvil <jan.kratochvil@redhat.com>
1338 Joel Brobecker <brobecker@adacore.com>
1339
1340 * gdbtypes.c (check_typedef): New comment on type length.
1341 * value.c (allocate_value_lazy): Remove the unused atype variable. New
1342 comment on type length.
1343 (value_primitive_field): Keep the original TYPE value, new comment.
1344
1345 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1346
1347 * cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
1348 p_start. Change != comparisons to > and < comparisons.
1349
1350 2010-01-01 Jan Kratochvil <jan.kratochvil@redhat.com>
1351
1352 * cli/cli-script.c (process_next_line): Check P2 overrun.
1353
1354 2009-01-01 Joel Brobecker <brobecker@adacore.com>
1355
1356 Update the copyright hearder to add year 2010 for most GDB files.
1357
1358 2009-01-01 Joel Brobecker <brobecker@adacore.com>
1359
1360 Fix build failure in inf-ptrace.c.
1361 * inf-ptrace.c (inf_ptrace_follow_fork): Fix typo.
1362
1363 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1364
1365 * top.c (print_gdb_version): Update copyright year.
1366
1367 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1368
1369 Fix break *FUN'address thread NUM.
1370 * ada-lex.l (task): Expand rule to also match the thread keyword.
1371
1372 2010-01-01 Joel Brobecker <brobecker@adacore.com>
1373
1374 Fix break *FUN'address task NUM.
1375 * ada-lex.l (task): New rule.
1376 * ada-lang.c (valid_task_id): Make sure the Ada task list has
1377 been built before using it.
1378
1379 For older changes see ChangeLog-2009.
1380 \f
1381 Local Variables:
1382 mode: change-log
1383 left-margin: 8
1384 fill-column: 74
1385 version-control: never
1386 coding: utf-8
1387 End: