2010-04-08 Hui Zhu <teawater@gmail.com>
[platform/upstream/binutils.git] / gdb / ChangeLog
1 2010-04-08  Hui Zhu  <teawater@gmail.com>
2
3         * i386-tdep.c (i386_process_record): Add support for insn
4         rdtsc.
5
6 2010-04-07  Doug Evans  <dje@google.com>
7
8         * python/python.c (source_python_script): Use ensure_python_env
9         to prepare environment for script.
10
11 2010-04-07  H.J. Lu  <hongjiu.lu@intel.com>
12
13         * amd64-linux-nat.c: Include "regset.h", "elf/common.h",
14         <sys/uio.h> and "i386-xstate.h".
15         (PTRACE_GETREGSET): New.
16         (PTRACE_SETREGSET): Likewise.
17         (have_ptrace_getregset): Likewise.
18         (amd64_linux_gregset64_reg_offset): Include 16 upper YMM
19         registers.
20         (amd64_linux_gregset32_reg_offset): Include 8 upper YMM
21         registers.
22         (amd64_linux_fetch_inferior_registers): Support PTRACE_GETFPREGS.
23         (amd64_linux_store_inferior_registers): Likewise.
24         (amd64_linux_read_description): Check and enable AVX target
25         descriptions.
26
27         * amd64-linux-tdep.c: Include "regset.h", "i386-linux-tdep.h"
28         and "features/i386/amd64-avx-linux.c".
29         (amd64_linux_regset_sections): New.
30         (amd64_linux_core_read_description): Check and enable AVX
31         target description.
32         (amd64_linux_init_abi): Set xsave_xcr0_offset.  Call
33         set_gdbarch_core_regset_sections.
34         (_initialize_amd64_linux_tdep): Call
35         initialize_tdesc_amd64_avx_linux.
36
37         * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM): Replace
38         AMD64_MXCSR_REGNUM with AMD64_YMM15H_REGNUM.
39         (tdesc_amd64_avx_linux): New.
40         (amd64_linux_update_xstateregset): Likewise.
41
42         * amd64-tdep.c: Include "features/i386/amd64-avx.c".
43         (amd64_ymm_names): New.
44         (amd64_ymmh_names): Likewise.
45         (amd64_register_name): Likewise.
46         (amd64_supply_xstateregset): Likewise.
47         (amd64_collect_xstateregset): Likewise.
48         (amd64_supply_xsave): Likewise.
49         (amd64_collect_xsave): Likewise.
50         (AMD64_NUM_REGS): Removed.
51         (amd64_dwarf_reg_to_regnum): Return %ymmN register number for
52         %xmmN if AVX is available.
53         (amd64_pseudo_register_name): Support pseudo YMM registers.
54         (amd64_regset_from_core_section): Support .reg-xstate section.
55         (amd64_init_abi): Set ymmh_register_names, num_ymm_regs
56         and ymm0h_regnum.  Call set_gdbarch_register_name.
57         (amd64_init_abi): Call initialize_tdesc_amd64_avx.
58
59         * amd64-tdep.h (amd64_regnum): Add AMD64_YMM0H_REGNUM and
60         AMD64_YMM15H_REGNUM.
61         (AMD64_NUM_REGS): New.
62         (amd64_supply_xsave): Likewise.
63         (amd64_collect_xsave): Likewise.
64         (amd64_register_name): Removed.
65         (amd64_register_type): Likewise.
66
67 2010-04-07  H.J. Lu  <hongjiu.lu@intel.com>
68
69         * i387-tdep.c: Include "i386-xstate.h".
70         (XSAVE_XSTATE_BV_ADDR): New.
71         (xsave_avxh_offset): Likewise.
72         (XSAVE_AVXH_ADDR): Likewise.
73         (i387_supply_xsave): Likewise.
74         (i387_collect_xsave): Likewise.
75
76         * i387-tdep.h (I387_NUM_YMM_REGS): New.
77         (I387_YMM0H_REGNUM): Likewise.
78         (I387_YMMENDH_REGNUM): Likewise.
79         (i387_supply_xsave): Likewise.
80         (i387_collect_xsave): Likewise.
81
82 2010-04-07  H.J. Lu  <hongjiu.lu@intel.com>
83
84         * i386-linux-nat.c: Include "regset.h", "elf/common.h",
85         <sys/uio.h> and "i386-xstate.h".
86         (PTRACE_GETREGSET): New.
87         (PTRACE_SETREGSET): Likewise.
88         (fetch_xstateregs): Likewise.
89         (store_xstateregs): Likewise.
90         (GETXSTATEREGS_SUPPLIES): Likewise.
91         (regmap): Include 8 upper YMM registers.
92         (i386_linux_fetch_inferior_registers): Support XSAVE extended
93         state.
94         (i386_linux_store_inferior_registers): Likewise.
95         (i386_linux_read_description): Check and enable AVX target
96         descriptions.
97
98         * i386-linux-tdep.c: Include "regset.h", "i387-tdep.h",
99         "i386-xstate.h" and "features/i386/i386-avx-linux.c".
100         (i386_linux_regset_sections): Add ".reg-xstate".
101         (i386_linux_gregset_reg_offset): Include 8 upper YMM registers.
102         (i386_linux_core_read_xcr0): New.
103         (i386_linux_core_read_description): Check and enable AVX target
104         description.
105         (i386_linux_init_abi): Set xsave_xcr0_offset.
106         (_initialize_i386_linux_tdep): Call
107         initialize_tdesc_i386_avx_linux.
108
109         * i386-linux-tdep.h (I386_LINUX_ORIG_EAX_REGNUM): Replace
110         I386_SSE_NUM_REGS with I386_AVX_NUM_REGS.
111         (i386_linux_core_read_xcr0): New.
112         (tdesc_i386_avx_linux): Likewise.
113         (I386_LINUX_XSAVE_XCR0_OFFSET): Likewise.
114
115         * i386-tdep.c: Include "i386-xstate.h" and
116         "features/i386/i386-avx.c".
117         (i386_ymm_names): New.
118         (i386_ymmh_names): Likewise.
119         (i386_ymmh_regnum_p): Likewise.
120         (i386_ymm_regnum_p): Likewise.
121         (i386_xmm_regnum_p): Likewise.
122         (i386_register_name): Likewise.
123         (i386_ymm_type): Likewise.
124         (i386_supply_xstateregset): Likewise.
125         (i386_collect_xstateregset): Likewise.
126         (i386_sse_regnum_p): Removed.
127         (i386_pseudo_register_name): Support pseudo YMM registers.
128         (i386_pseudo_register_type): Likewise.
129         (i386_pseudo_register_read): Likewise.
130         (i386_pseudo_register_write): Likewise.
131         (i386_dbx_reg_to_regnum): Return %ymmN register number for
132         %xmmN if AVX is available.
133         (i386_regset_from_core_section): Support .reg-xstate section.
134         (i386_register_reggroup_p): Supper upper YMM and YMM registers.
135         (i386_process_record): Replace i386_sse_regnum_p with
136         i386_xmm_regnum_p.
137         (i386_validate_tdesc_p): Support org.gnu.gdb.i386.avx feature.
138         Set ymmh_register_names, num_ymm_regs, ymm0h_regnum and xcr0.
139         (i386_gdbarch_init): Set xstateregset.  Set xsave_xcr0_offset. 
140         Call set_gdbarch_register_name.  Replace I386_SSE_NUM_REGS with
141         I386_AVX_NUM_REGS.  Set ymmh_register_names, ymm0h_regnum and
142         num_ymm_regs.  Add num_ymm_regs to set_gdbarch_num_pseudo_regs.
143         Set ymm0_regnum.
144         (_initialize_i386_tdep): Call initialize_tdesc_i386_avx.
145
146         * i386-tdep.h (gdbarch_tdep): Add xstateregset, ymm0_regnum,
147         xcr0, xsave_xcr0_offset, ymm0h_regnum, ymmh_register_names and
148         i386_ymm_type.
149         (i386_regnum): Add I386_YMM0H_REGNUM, and I386_YMM7H_REGNUM.
150         (I386_AVX_NUM_REGS): New.
151         (i386_xmm_regnum_p): Likewise.
152         (i386_ymm_regnum_p): Likewise.
153         (i386_ymmh_regnum_p): Likewise.
154
155         * common/i386-xstate.h: New.
156
157 2010-04-07  H.J. Lu  <hongjiu.lu@intel.com>
158
159         * config/djgpp/fnchange.lst: Add x86 AVX XML files.
160
161         * features/Makefile (WHICH): Add i386/i386-avx,
162         i386/i386-avx-linux, i386/x86-64-avx and i386/x86-64-avx-linux.
163         (i386/i386-avx-expedite): New.
164         (i386/i386-avx-linux-expedite): Likewise.
165         (i386/x86-64-avx-expedite):Likewise.
166         (i386/x86-64-avx-linux-expedite): Likewise.
167         ($(outdir)/i386/i386-avx.dat): New dependency.
168         ($(outdir)/i386/i386-avx-linux.dat): Likewise.
169         ($(outdir)/i386/x86-avx-64.dat): Likewise.
170         ($(outdir)/i386/x86-64-avx-linux.dat): Likewise.
171
172         * features/i386/32bit-avx.xml: New.
173         * features/i386/64bit-avx.xml: Likewise.
174         * features/i386/i386-avx-linux.c: Likewise.
175         * features/i386/i386-avx-linux.xml: Likewise.
176         * features/i386/i386-avx.c: Likewise.
177         * features/i386/i386-avx.xml: Likewise.
178         * features/i386/x86-64-avx-linux.c: Likewise.
179         * features/i386/x86-64-avx-linux.xml: Likewise.
180         * features/i386/x86-64-avx.c: Likewise.
181         * features/i386/x86-64-avx.xml: Likewise.
182         * regformats/i386/i386-avx-linux.dat: Likewise.
183         * regformats/i386/i386-avx.dat: Likewise.
184         * regformats/i386/x86-64-avx-linux.dat: Likewise.
185         * regformats/i386/x86-64-avx.dat: Likewise.
186
187 2010-04-07  Doug Evans  <dje@google.com>
188
189         * top.c (source_file_name): Make const char *.
190         * top.h (source_file_name): Update.
191         * cli/cli-script.c (source_cleanup_lines_args): Make old_file
192         const char *.
193         (script_from_file): Change `file' arg to const char *.
194         * cli/cli-script.h (script_from_file): Update.
195
196 2010-04-06  Doug Evans  <dje@google.com>
197
198         * cli/cli-cmds.c (source_command): Run cleanups.
199
200 2010-04-06  Stan Shebs  <stan@codesourcery.com>
201
202         * defs.h (char_ptr): Move typedef here from...
203         * ada-lang.c (char_ptr): Remove.
204         * charset.c (char_ptr): Remove.
205         * tracepoint.h (struct uploaded_string): Remove.
206         (struct uploaded_tp): Use vectors for string arrays.
207         * tracepoint.c (trace_save): Use vectors of actions.
208         (parse_tracepoint_definition): Ditto.
209         (get_uploaded_tp): Clear vectors.
210         * breakpoint.c (create_tracepoint_from_upload): Use vectors.
211         (next_cmd): Change to an int.
212         (read_next_cmd): Use vector of command strings.
213
214 2010-04-06  Doug Evans  <dje@google.com>
215
216         * top.h (source_script, cd_command): Delete.
217         * main.c: #include "cli/cli-cmds.h"
218
219 2010-04-06  Kevin Buettner  <kevinb@redhat.com>
220
221         * m32c-tdep.c (make_types): When calling `arch_type', pass size of
222         type in bytes, not bits.
223
224 2010-04-06  Pierre Muller  <muller@ics.u-strasbg.fr>
225
226         * stabsread.c (define_symbol): Add support for char
227         and string constants.
228
229 2010-04-06  Pierre Muller  <muller@ics.u-strasbg.fr>
230
231         Remove remaining "%ll" uses.
232         * go32-nat.c (go32_pte_for_address): Replace "0x%llx" using
233         hex_string call.
234         * rs6000-nat.c (rs6000_ptrace64): Idem.
235         * solib-pa64.c (pa64_current_sos): Idem.
236         * solib-spu.c (spu_current_sos): Idem.
237         * linux-nat.c (linux_nat_find_memory_regions): Replace "%lld" using
238         plongest call.
239         * nto-procfs.c (procfs_meminfo): Replace "0x%016llx" using
240         phex (VAR, 8) call.
241         * sh64-tdep.c (sh64_show_media_regs): Idem.
242
243 2010-04-05  Stan Shebs  <stan@codesourcery.com>
244
245         * tracepoint.c: Include gdbcore.h.
246         (tfile_xfer_partial): Return partial results, also try reading
247         from executable.
248         (tfile_has_all_memory): New function.
249         (init_tfile_ops): Use it.
250
251 2010-04-05  Sergio Durigan Junior  <sergiodj@redhat.com>
252
253         PR gdb/10736:
254         * xml-syscall.c (my_gdb_datadir): New variable to keep track of
255         the changes in data-directory.
256         (init_sysinfo): Reload the syscall XML file if the data-directory
257         has changed.
258
259 2010-04-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
260
261         Code cleanup.
262         * breakpoint.c (bpstat_stop_status): Use bpstat_causes_stop.
263
264 2010-04-04  Stan Shebs  <stan@codesourcery.com>
265             Nathan Sidwell  <nathan@codesourcery.com>
266
267         * breakpoint.c (breakpoint_1): Add filter argument, return number of
268         breakpoints printed.
269         (is_hardware_watchpoint): Make argument const.
270         (is_watchpoint): Ditto.
271         (is_tracepoint): Merge of tracepoint_type and breakpoint_is_tracepoint,
272         use it everywhere.
273         (breakpoints_info): Pass NULL to breakpoint_1.
274         (maintenance_info_breakpoints): Ditto.
275         (watchpoints_info): New function.
276         (tracepoints_info): Use breakpoint_1 filter.
277         (set_ignore_count): Warn that tracepoint ignore count will be ignored.
278         (_initialize_breakpoint): Make "info watchpoints" its own command.
279         * breakpoint.h (is_tracepoint): Rename from breakpoint_is_tracepoint.
280         * mi/mi-cmd-break.c (mi_cmd_break_commands): Use is_tracepoint.
281
282 2010-04-04  Stan Shebs  <stan@codesourcery.com>
283
284         * tracepoint.c (tfile_fetch_registers): Add fallback case.
285
286 2010-04-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
287
288         * infcmd.c (run_command_1): Call proceed with regcache_read_pc address.
289         * config/djgpp/fnchange.lst: Add translation for break-entry.exp.
290
291 2010-04-04  Jan Kratochvil  <jan.kratochvil@redhat.com>
292
293         * breakpoint.c (bpstat_find_step_resume_breakpoint): Remove.
294         * breakpoint.h (bpstat_find_step_resume_breakpoint): Remove.
295
296 2010-04-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
297
298         * dwarf2read.c (read_namespace_type): Use common "return set_die_type"
299         code form.
300
301 2010-04-02  Hui Zhu  <teawater@gmail.com>
302
303         * i386-tdep.c (OT_DQUAD): New enum.
304         (i386_process_record): Add code for MMX, 3DNow!, SSE, SSE2,
305         SSE3, SSSE3 and SSE4.
306
307 2010-04-02  Hui Zhu  <teawater@gmail.com>
308
309         * i386-tdep.c (i386_record_lea_modrm_addr): Remove useless
310         "*addr = 0".
311
312 2010-04-02  Pedro Alves  <pedro@codesourcery.com>
313
314         * tracepoint.c (trace_dump_actions): New, factored out from
315         trace_dump_command, and adjusted to recurse into while-stepping's
316         action list.
317         (trace_dump_command): Use it.
318
319 2010-04-02  Pedro Alves  <pedro@codesourcery.com>
320
321         * breakpoint.h (struct counted_command_line): Moved definition to
322         breakpoint.c, and forward declare.
323         (breakpoint_commands): Declare.
324         * breakpoint.c (struct counted_command_line): Moved here.
325         (breakpoint_commands): New.
326         * tracepoint.c (encode_actions): Use breakpoint_commands.
327         * remote.c (remote_download_tracepoint): Ditto.
328
329 2010-04-01  H.J. Lu  <hongjiu.lu@intel.com>
330
331         * remote.c (remote_parse_stop_reply): Use hex_string instead
332         of phex_nz for error.
333
334 2010-04-01  Stan Shebs  <stan@codesourcery.com>
335             Nathan Sidwell  <nathan@codesourcery.com>
336
337         * tracepoint.h (enum actionline_type): Remove.
338         (validate_actionline): Change return to void.
339         * tracepoint.c (report_agent_reqs_errors): New function.
340         (validate_actionline): Call it, change return to void, report errors
341         more consistently.
342         (collect_symbol): Call report_agent_reqs_errors.
343         (encode_actions_1): Ditto.
344         (encode_actions): Don't expect a result from validate_actionline.
345
346 2010-04-01  Stan Shebs  <stan@codesourcery.com>
347
348         * tracepoint.c (trace_start_command): Confirm if trace is running.
349         (trace_stop_command): Error if trace not running.
350
351 2010-04-01  H.J. Lu  <hongjiu.lu@intel.com>
352
353         * amd64-tdep.c (amd64_byte_names): Add "ah", "bh", "ch", "dh".
354         (AMD64_NUM_LOWER_BYTE_REGS): New.
355         (amd64_pseudo_register_read): Handle "ah", "bh", "ch", "dh".
356         (amd64_pseudo_register_write): Likewise.
357         (amd64_init_abi): Set num_byte_regs to 20.
358
359 2010-04-01  Pedro Alves  <pedro@codesourcery.com>
360
361         * breakpoint.c (multi_start, multi_end, last_was_multi): Delete.
362         (prev_breakpoint_count): New.
363         (set_breakpoint_count): Adjust.
364         (rbreak_start_breakpoint_count): New.
365         (start_rbreak_breakpoints): Adjust.
366         (end_rbreak_breakpoints): Adjust.
367         (struct commands_info) <arg>: New field.
368         (do_map_commands_command): Tweak output to include breakpoint spec
369         range.
370         (commands_command_1): Adjust.  Avoid setting an xfree cleanup if
371         ARG was empty on entry.  Set INFO's arg.
372         (create_breakpoint): Adjust.
373
374         * NEWS: Clarify `commands' changes.
375
376 2010-04-01  Pedro Alves  <pedro@codesourcery.com>
377
378         * tracepoint.c: Include stack.h.
379         (struct add_local_symbols_data): New.
380         (do_collect_symbol): New.
381         (add_local_symbols): Rewrite using iterate_over_block_arg_vars and
382         iterate_over_block_local_vars.
383         * stack.c (print_block_frame_locals): Rewrite as ...
384         (iterate_over_block_locals): ... this.  Take a callback function
385         pointer and generic data pointer, and call that instead of
386         print_variable_and_value.
387         (struct print_variable_and_value_data): New.
388         (do_print_variable_and_value): New.
389         (iterate_over_block_local_vars): New, abstracted out from
390         print_frame_local_vars.
391         (print_frame_local_vars): Rewrite using
392         iterate_over_block_local_vars.
393         (iterate_over_block_arg_vars): New, abstracted out from
394         print_frame_arg_vars.
395         (print_frame_arg_vars): Rewrite using iterate_over_block_arg_vars.
396         * stack.h (iterate_over_block_arg_local_vars_cb): New typedef.
397         (iterate_over_block_arg_vars, iterate_over_block_local_vars): Declare.
398
399 2010-03-31  Richard Earnshaw  <rearnsha@arm.com>
400
401         * arm-tdep.c (thumb_get_next_pc_raw): Correctly detect TBH
402         instructions.  Use the PC+4 if the base of the TBB or TBH is the 
403         PC register.
404
405 2010-03-31  Jan Kratochvil  <jan.kratochvil@redhat.com>
406
407         Fix crash on reading wrong function declaration DWARF.
408         * dwarf2read.c (read_subroutine_type): New variable void_type.
409         Pre-fill all TYPE_FIELD_TYPEs.  Move nparams and iparams initialization
410         more close to their use.
411
412 2010-03-31  Stan Shebs  <stan@codesourcery.com>
413
414         * breakpoint.c (tracepoint_save_command): Include variables,
415         conditionals, tracepoint types, and default-collect.
416         * tracepoint.c (save_trace_state_variables): New function.
417         * tracepoint.h (save_trace_state_variables): Declare it.
418
419 2010-03-31  Pierre Muller  <muller@ics.u-strasbg.fr>
420
421         * src/gdb/remote.c (end_thread): ARI fix: Use xstrdup instead of
422         strdup.
423
424 2010-03-30  Keith Seitz  <keiths@redhat.com>
425
426         * c-typeprint.c (c_type_print_args): Don't print "void"
427         for java, regardless of whether it is TYPE_PROTOTYPED.
428         Use the passed-in language instead of current_language.
429         (c_type_print_varspec_suffix): Use current_language instead
430         of assuming language_c.
431         * jv-typeprint.c (java_type_print_base): (bz 9320) Strip off
432         any return type specifier from the physname.
433
434 2010-03-30  Pedro Alves  <pedro@codesourcery.com>
435
436         * tui/tui-interp.c (tui_is_toplevel): New.
437         (tui_init): Set it.
438         (tui_allowed_p): New.
439         * tui/tui.c (tui_enable): Check if the TUI is allowed before
440         enabling it.
441         * tui/tui.h (tui_allowed_p): Declare.
442
443 2010-03-30  Ozkan Sezer  <sezeroz@gmail.com>
444
445         * serial.h: Include winsock2.h before windows.h.
446
447 2010-03-30  H.J. Lu  <hongjiu.lu@intel.com>
448
449         * NEWS: Mention xmlRegisters= in qSupported packet.
450
451         * i386-tdep.c: Include "remote.h".
452         (_initialize_i386_tdep): Call register_remote_support_xml.
453
454         * remote.c (remote_support_xml): New.
455         (register_remote_support_xml): Likewise.
456         (remote_query_supported_append): Likewise.
457         (remote_query_supported): Support remote_support_xml.
458
459         * remote.h (register_remote_support_xml): New.
460
461 2010-03-29  Stan Shebs  <stan@codesourcery.com>
462
463         * tracepoint.c (trace_find_line_command): Remove dead code.
464
465         * tracepoint.h (struct uploaded_string): New struct.
466         (struct uploaded_tp): New fields for source strings.
467         * breakpoint.c (this_utp, next_cmd): New globals.
468         (read_uploaded_action): New function.
469         (create_tracepoint_from_upload): Fill in more parts
470         of a tracepoint.
471         * tracepoint.c (encode_source_string): New function.
472         (trace_save): Write out source strings, fix error checks.
473         (parse_tracepoint_definition): Add source string parsing.
474         * remote.c (PACKET_TracepointSource): New packet type.
475         (remote_download_command_source): New function.
476         (remote_download_tracepoint): Download source pieces also.
477         (_initialize_remote): Add packet config command.
478
479         * tracepoint.c (collect_symbol): Send LOC_UNRESOLVED symbols to
480         expression handler.
481
482         * tracepoint.c (start_tracing): Check tracepoints before sending
483         commands to target, don't start if all tracepoints disabled.
484
485 2010-03-28  Pedro Alves  <pedro@codesourcery.com>
486
487         * cli/cli-script.c (process_next_line): Handle 'stepping'.
488
489 2010-03-26  Stan Shebs  <stan@codesourcery.com>
490
491         * tracepoint.c (disconnect_or_stop_tracing): Get out of tfind mode.
492
493 2010-03-26  Tom Tromey  <tromey@redhat.com>
494
495         * breakpoint.c (commands_command_1): Duplicate 'arg'.
496
497 2010-03-26  Ulrich Weigand  <uweigand@de.ibm.com>
498
499         * breakpoint.c (expand_line_sal_maybe): Always call skip_prologue_sal.
500         (skip_prologue_sal): Remove local definition.
501         (resolve_sal_pc): Remove now unnecessary code.
502         * linespec.c (minsym_found): Call skip_prologue_sal.
503         * symtab.c (find_function_start_pc): Remove.
504         (find_function_start_sal): Extract prologue skipping into ...
505         (skip_prologue_sal): ... this new function.  Handle code both
506         with and without debug info.  Respect SAL's explicit_pc and
507         explicit_line flags.  Inline old find_function_start_pc.
508         * symtab.h (find_function_start_pc): Remove.
509         (skip_prologue_sal): Add prototype.
510
511 2010-03-26  Ulrich Weigand  <uweigand@de.ibm.com>
512
513         * dwarf2read.c (read_func_scope): Also scan specification DIEs
514         for DW_TAG_imported_module children.
515
516 2010-03-26  Ulrich Weigand  <uweigand@de.ibm.com>
517
518         * dwarf2read.c (dwarf2_name): Work around GCC bugzilla debug/41828 by
519         ignoring spurious DW_AT_name attributes for unnamed structs or unions.
520         * completer.c (add_struct_fields): Fix inverted logic.
521
522 2010-03-26  Ulrich Weigand  <uweigand@de.ibm.com>
523
524         * breakpoint.c (bpstat_clear_actions): Reset bs->commands_left.
525
526 2010-03-26  Pedro Alves  <pedro@codesourcery.com>
527
528         * tracepoint.c (current_trace_status): Don't make sure error_desc
529         is non-NULL here.
530         (parse_trace_status): Release a previous error_desc string, and
531         set it to NULL by default.  If stop reason is tracepoint_error,
532         make sure error_desc is not left NULL.
533
534 2010-03-26  Pedro Alves  <pedro@codesourcery.com>
535
536         * tracepoint.c (trace_save): Remove X from tracepoint error
537         description.
538
539 2010-03-26  Pedro Alves  <pedro@codesourcery.com>
540
541         * tracepoint.c (parse_trace_status): Don't allow plain strings in
542         the terror description.  Don't expect an X prefix.
543
544 2010-03-25  Stan Shebs  <stan@codesourcery.com>
545
546         * tracepoint.h (trace_stop_reason): Add tracepoint_error.
547         (struct trace_status): New field error_desc.
548         * tracepoint.c (stop_reason_names): Add terror.
549         (current_trace_status): Ensure non-NULL error description.
550         (trace_status_command): Add error report.
551         (trace_status_mi): Ditto.
552         (trace_save): Add special case for error description.
553         (parse_trace_status): Add case for errors.
554
555 2010-03-25  Keith Seitz  <keiths@redhat.com>
556
557         * dwarf2read.c (read_subroutine_type): If the compilation unit
558         language is Java, mark any formal parameter named "this" as
559         artificial (GCC/43521).
560         (dwarf2_name): Add special handling for Java constructors.
561
562 2010-03-25  Tom Tromey  <tromey@redhat.com>
563
564         PR gdb/11327, PR gdb/11328, PR breakpoints/11368:
565         * infrun.c (handle_inferior_event): Change initialization of
566         stop_stack_dummy.
567         (handle_inferior_event): Change assignment to stop_stack_dummy.
568         (normal_stop): Update use of stop_stack_dummy.
569         (struct inferior_status) <stop_stack_dummy>: Change type.
570         * inferior.h (stop_stack_dummy): Update.
571         * infcmd.c (stop_stack_dummy): Change type.
572         * infcall.c (cleanup_delete_std_terminate_breakpoint): New
573         function.
574         (call_function_by_hand): Call set_std_terminate_breakpoint.
575         Rewrite std::terminate handling.
576         * breakpoint.h (enum bptype) <bp_std_terminate,
577         bp_std_terminate_master>: New.
578         (enum stop_stack_kind): New.
579         (struct bpstat_what) <call_dummy>: Change type.
580         (set_std_terminate_breakpoint, delete_std_terminate_breakpoint):
581         Declare.
582         * breakpoint.c (create_std_terminate_master_breakpoint): New
583         function.
584         (update_breakpoints_after_exec): Handle bp_std_terminate_master.
585         Call create_std_terminate_master_breakpoint.
586         (print_it_typical): Handle new breakpoint kinds.
587         (bpstat_stop_status): Handle bp_std_terminate_master.
588         (bpstat_what): Correctly set call_dummy field.  Handle
589         bp_std_terminate_master and bp_std_terminate.
590         (print_one_breakpoint_location): Update.
591         (allocate_bp_location): Update.
592         (set_std_terminate_breakpoint): New function.
593         (delete_std_terminate_breakpoint): Likewise.
594         (create_thread_event_breakpoint): Update.
595         (delete_command): Update.
596         (breakpoint_re_set_one): Update.
597         (breakpoint_re_set): Call create_std_terminate_master_breakpoint.
598
599 2010-03-25  Jan Kratochvil  <jan.kratochvil@redhat.com>
600
601         * symfile.c (build_section_addr_info_from_bfd): New.
602         (build_section_addr_info_from_objfile): Base it on
603         build_section_addr_info_from_bfd.
604         (addrs_section_compar, addrs_section_sort): New.
605         (addr_info_make_relative): New variables my_cleanup, abfd_addrs,
606         addrs_sorted, abfd_addrs_sorted and addrs_to_abfd_addrs.  Build
607         addrs_to_abfd_addrs.  Use it for recalculating ADDRS.
608
609 2010-03-24  Michael Snyder  <msnyder@localhost.localdomain>
610
611         * elfread.c (find_separate_debug_file_by_buildid): 
612         Remove unused local variable.
613
614 2010-03-24  Tom Tromey  <tromey@redhat.com>
615
616         PR breakpoints/9352:
617         * NEWS: Mention changes to `commands' and `rbreak'.
618         * symtab.c (do_end_rbreak_breakpoints): New function.
619         (rbreak_command): Call start_rbreak_breakpoints; arrange to call
620         end_rbreak_breakpoints.
621         * breakpoint.c (breakpoint_count, tracepoint_count): Now static.
622         (set_breakpoint_count): Likewise.  Clear last_was_multi.
623         (multi_start, multi_end, last_was_multi): New globals.
624         (start_rbreak_breakpoints, end_rbreak_breakpoints): New
625         functions.
626         (struct commands_info): New
627         (do_map_commands_command): New function.
628         (commands_command_1): New function.
629         (commands_command): Use it.
630         (commands_from_control_command): Likewise.
631         (do_delete_breakpoint): New function.
632         (delete_command): Use it.
633         (map_breakpoint_numbers): Add 'data' argument.  Pass to callback.
634         (do_map_disable_breakpoint): New function.
635         (disable_command): Use it.
636         (do_map_enable_breakpoint): New function.
637         (enable_command): Use it.
638         (enable_once_breakpoint): Add argument.
639         (enable_once_command): Update.
640         (enable_delete_breakpoint): Add argument.
641         (enable_delete_command): Update.
642         (break_command_really): Set last_was_multi when needed.
643         (check_tracepoint_command): Fix formatting.
644         (validate_commands_for_breakpoint): New function.
645         (breakpoint_set_commands): Use it.
646         (tracepoint_save_command): Update.
647         * breakpoint.h (start_rbreak_breakpoints, end_rbreak_breakpoints):
648         Declare.
649
650 2010-03-24  Tom Tromey  <tromey@redhat.com>
651
652         * breakpoint.h (struct counted_command_line): New struct.
653         (struct breakpoint) <commands>: Change type.
654         (struct bpstats) <commands>: Change type.
655         <commands_left>: New field.
656         * breakpoint.c (alloc_counted_command_line): New function.
657         (incref_counted_command_line): Likewise.
658         (decref_counted_command_line): Likewise.
659         (do_cleanup_counted_command_line): Likewise.
660         (make_cleanup_decref_counted_command_line): Likewise.
661         (breakpoint_set_commands): Use decref_counted_command_line and
662         alloc_counted_command_line.
663         (commands_command): Don't error if breakpoint commands are
664         executing.
665         (commands_from_control_command): Likewise.
666         (bpstat_free): Update.
667         (bpstat_copy): Likewise.
668         (bpstat_clear_actions): Likewise.
669         (bpstat_do_actions_1): Likewise.
670         (bpstat_stop_status): Likewise.
671         (print_one_breakpoint_location): Likewise.
672         (delete_breakpoint): Likewise.
673         (bpstat_alloc): Initialize new field.
674         (tracepoint_save_command): Update.
675         * tracepoint.c (encode_actions): Update.
676         (trace_dump_command): Update.
677
678 2010-03-24  Daniel Jacobowitz  <dan@codesourcery.com>
679
680         * dwarf2-frame.c (dwarf2_frame_find_quirks): Use producer_is_realview.
681         * dwarf2read.c (load_full_comp_unit): Read DW_AT_producer.
682         (read_structure_type): For RealView, set TYPE_STUB on structures with
683         no byte size and no children.
684         (read_subroutine_type): Mark functions as prototyped by default.
685         * symtab.c (producer_is_realview): New function.
686         * symtab.h (expand_line_sal): Fix declaration formatting.
687         (producer_is_realview): Declare.
688
689 2010-03-24  Daniel Jacobowitz  <dan@codesourcery.com>
690
691         * arm-tdep.c (skip_prologue_function): New function.
692         (submask, bit, bits, sbits, BranchDest): Move higher in the file.
693         (thumb_analyze_prologue): Document return value.  Recognize more
694         Thumb instructions, skippable calls, and some Thumb-2 instructions.
695         Add debug output.
696         (arm_skip_prologue): Remove call dummy check.  Check the prologue
697         for non-GNU compilers.
698         (arm_instruction_changes_pc): New function.
699         (arm_analyze_prologue): New function, broken out from
700         arm_scan_prologue.  Recognize more ARM instructions and skippable
701         calls.  Update comments.  Handle NULL cache.  Return the address
702         of the first unrecognized instruction.  Do not skip past other
703         instructions which change control flow.  Add debug output.
704         (arm_scan_prologue): Use arm_analyze_prologue.
705         (ARM_PC_32): Delete.
706         (shifted_reg_val): Simplify ARM_PC_32 check.
707
708 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
709
710         * tracepoint.c (tvariables_info_1): Actually compute
711         the number of rows in the result.
712
713 2010-03-24  Pedro Alves  <pedro@codesourcery.com>
714
715         * remote.c (crc32): Constify `buf' parameter.
716         (remote_verify_memory): New, abstracted out from...
717         (compare_sections_command): ... this.  Remove hardcoded target
718         checks.
719         (init_remote_ops): Install remote_verify_memory.
720         * target.c (target_verify_memory): New.
721         * target.h (struct target_ops) <to_verify_memory>: New field.
722         (target_verify_memory): Declare.
723
724 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
725
726         Implement -trace-save.
727
728         * mi-cmds.h (mi_cmds_trace_save): Declare.
729         * mi-cmds.c (mi_cmds): Register -trace-save.
730         * mi/mi-main.c (mi_cmd_trace_save): New.
731         * remote.c (remote_save_trace_data): Take const parameter.
732         * target.h (struct target_ops::to_save_trace_data): Take
733         const parameter.
734         * target.c (update_current_target): Adjust to the above.
735         * tracepoint.c (trave_save): New, extracted from
736         (trace_save_command): ...this.
737         (tfile_trace_find): Remove message that is unnecessary now
738         that 'tfind' reports found frame.
739         * tracepoint.h (trace_save): Declare.
740
741 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
742
743         Implement -trace-find.
744
745         * mi/mi-cmds.c (mi_cmds): Register -trace-find.
746         * mi/mi-cmds.h (mi_cmd_trace_find): Declare.
747         * mi/mi-main.c (mi_cmd_trace_find): New.
748         * target.h (struct target_ops): Document to_trace_find.
749         * tracepoint.h (tfind_1): Declare.
750         * tracepoint.c (finish_tfind_command): Rename to...
751         (tfind_1): ...this.
752         * remote.c (remote_trace_find): Return -1 if target say
753         there's no frame.  Improve error diagnostics.
754
755 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
756
757         -trace-define-variable and -trace-list-variables.
758
759         * tracepoint.c (create_trace_state_variable): Make
760         private copy of name, as opposed to assuming the
761         pointer lives forever.
762         (tvariables_info_1): New.
763         (tvariables_info): Use the above.
764         * tracepoint.h (create_trace_state_variable, tvariables_info_1):
765         Declare.
766         * mi/mi-cmds.c (mi_cmds): Register -trace-define-variable
767         and -trace-list-variables.
768         * mi/mi-cmds.h (mi_cmd_trace_define_variable)
769         (mi_cmd_trace_list_variables): New.
770         * mi/mi-main.c (mi_cmd_trace_define_variable)
771         (mi_cmd_trace_list_variables): New.
772
773 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
774
775         Implement -break-passcount.
776
777         * mi/mi-cmd-break.c (mi_cmd_break_passcount): New.
778         * mi/mi-cmds.c (mi_cmds): Register -break-passcount.
779         * mi/mi-cmds.h (mi_cmd_break_passcount): Declare.
780
781 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
782
783         -trace-start/-trace-end/-trace-status.
784
785         * mi/mi-cmds.c (mi_cmds): Register -trace-start, -trace-status
786         and -trace-stop.
787         * mi/mi-cmds.h (mi_cmd_trace_start, mi_cmd_trace_status)
788         (mi_cmd_trace_stop): Declare.
789         * mi/mi-main.c (mi_cmd_trace_start, mi_cmd_trace_status)
790         (mi_cmd_trace_stop): New.
791         * tracepoint.c (start_tracing): New, extracted from...
792         (trace_start_command): ...this.
793         (trace_status_mi): New.
794         * tracepoint.h (struct trace_status): Document
795         stopping_tracepoint.
796         (start_tracing, stop_tracing, trace_status_mi): Declare.
797
798 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
799
800         Implement creating tracepoints with -break-insert.
801
802         * mi/mi-cmd-break.c (mi_cmd_break_insert): Handle -a
803         to mean that tracepoint should be created.
804
805 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
806
807         * breakpoint.c (check_no_tracepoint_commands): Use
808         current spelling of 'teval'.
809
810 2010-03-24  Vladimir Prus  <vladimir@codesourcery.com>
811
812         Unify actions and commands
813
814         * defs.h (read_command_lines, read_command_lines_1): New
815         parameters validator and closure.
816         * tracepoint.h (struct action_line): Remove.
817         * breakpoint.h (struct breakpoint): Remove the 'actions'
818         field.
819         * defs.h (enum command_control_type): New value
820         while_stepping_control.
821         (struct command_line): Add comments.
822         * breakpoint.c (breakoint_is_tracepoint): New.
823         (breakpoint_set_commands): For tracepoints,
824         verify the commands are permissible.
825         (check_tracepoint_commands): New.
826         (commands_command): Require that each new line is validated using
827         check_tracepoint_command, if we set commands for a tracepoint.
828         (create_tracepoint_from_upload): Likewise.
829         (print_one_breakpoint_location): Remove the code to print
830         actions specifically.
831         (tracepoint_save_command): Relay to print_command_lines.
832         * cli/cli-script.c (process_next_line): New parameters validator
833         and closure. Handle 'while-stepping'. Call validator if not null.
834         (read_command_lines, read_command_lines1): Likewise.
835         (recurse_read_control_structure): New parameters validator and
836         closure. Handle while_stepping_control.
837         (print_command_lines): Handle while-stepping.
838         (get_command_line, define_command, document_command): Adjust.
839         * remote.c (remote_download_tracepoint): Adjust.
840         * tracepoint.c (make_cleanup_free_actions, read_actions)
841         (free_actions, do_free_actions_cleanup): Remove.
842         (trace_actions_command): Use read_command_lines.
843         (validate_actionline): Use error in one place.
844         (encode_actions_1): New, extracted from...
845         (encode_actions): ...this. Also use cleanups for exception
846         safety.
847         (trace_dump_command): Adjust.
848         * mi/mi-cmd-break (mi_cmd_break_commands): Validate commands if
849         it's tracepoint.
850
851 2010-03-23  Mike Frysinger  <vapier@gentoo.org>
852
853         * Makefile.in (OPCODES_CFLAGS): Add -I$(OPCODES_SRC)/..
854
855 2010-03-22  Stan Shebs  <stan@codesourcery.com>
856
857         * value.c (value_static_field): Be lazy about the field's value.
858
859 2010-03-22  Reid Kleckner  <reid@kleckner.net>
860
861         PR gdb/11094
862         * breakpoint.c (disable_breakpoints_in_unloaded_shlib): Add
863         bp_jit_event.
864         (disable_breakpoints_in_shlibs): Likewise.
865
866 2010-03-22  Ulrich Weigand  <uweigand@de.ibm.com>
867
868         * dwarf2read.c (partial_die_parent_scope): Work around buggy
869         GCC 4.1 debug info generation (GCC PR c++/28460).
870         (determine_prefix): Likewise.
871
872 2010-03-20  Daniel Jacobowitz  <dan@codesourcery.com>
873
874         * tui/tui-disasm.c (tui_get_begin_asm_address): Default to
875         get_current_arch.
876         * tui/tui-layout.c (extract_display_start_addr): Likewise.
877
878 2010-03-19  Stan Shebs  <stan@codesourcery.com>
879
880         * ax-gdb.c (gen_fetch): Handle bool.
881         (gen_usual_unary): Ditto.
882         (gen_cast): Ditto.
883         (gen_equal): New function.
884         (gen_less): New function.
885         (gen_expr_binop_rest): Call them, also return integer type from
886         logical operations.
887         (gen_expr): Ditto.
888
889 2010-03-19  Tom Tromey  <tromey@redhat.com>
890
891         * jv-lang.c (jv_dynamics_objfile_data_key)
892         (jv_type_objfile_data_key): New globals.
893         (class_symtab): Move earlier.
894         (jv_per_objfile_free): New function.
895         (get_dynamics_objfile): Call set_objfile_data.  Add 'gdbarch'
896         parameter.
897         Remove ancient #if 1.
898         (add_class_symbol): Remove redundant declaration.
899         (java_lookup_class): Use alloc_type, not alloc_type_arch.
900         (java_link_class_type): Mark as static.  Update.
901         (jv_clear_object_type): New function.
902         (set_java_object_type): Likewise.
903         (get_java_object_type): Use set_java_object_type.
904         (is_object_type): Likewise.
905         (_initialize_java_language): Register new objfile keys.
906         (get_java_class_symtab): Add 'gdbarch' parameter.
907         (add_class_symtab_symbol): Update.
908         (type_from_class): Update.
909
910 2010-03-19  Stan Shebs  <stan@codesourcery.com>
911
912         * ax-general.c (ax_const_l): Fix a sizing bug. 
913
914 2010-03-18  Joel Brobecker  <brobecker@adacore.com>
915
916         GDB 7.1 released.
917
918 2010-03-18  Stan Shebs  <stan@codesourcery.com>
919             Pedro Alves  <pedro@codesourcery.com>
920
921         * target.h (struct target_ops): New method
922         to_set_circular_trace_buffer.
923         (target_set_circular_trace_buffer): New macro.
924         * target.c (update_current_target): Add
925         to_set_circular_trace_buffer, fix to_set_disconnected_tracing
926         default behavior.
927         * remote.c (remote_set_circular_trace_buffer): New function.
928         (init_remote_ops): Add it to vector.
929         * tracepoint.h (struct trace_status): New field traceframes_created,
930         change buffer_size and buffer_free to int.
931         * tracepoint.c (circular_trace_buffer): New global.
932         (start_tracing): Send values of disconnected tracing and circular
933         trace buffer settings.
934         (set_circular_trace_buffer): New function.
935         (parse_trace_state): Handle total space and frames created.
936         (trace_status_command): Display total space and total frames
937         created.
938         (trace_save): Write out new status values.
939         (parse_trace_status): Set traceframe_count, traceframes_created,
940         buffer_free and buffer_size to -1 by default.
941         (_initialize_tracepoint): New setshow for circular-trace-buffer.
942         * NEWS: Mention the circular trace buffer option.
943
944 2010-03-18  Tom Tromey  <tromey@redhat.com>
945
946         * infcmd.c (finish_command_continuation): Wrap print_return_value
947         in TRY_CATCH.
948
949 2010-03-18  Joel Brobecker  <brobecker@adacore.com>
950
951         * dwarf2read.c (add_partial_subprogram): Make sure the subprogram
952         DIE has a name before creating the associated partial symbol.
953         (read_func_scope): Emit a complaint if the subprogram does not
954         have a name or when we can't extract the subprogram PC bounds.
955
956 2010-03-18  Ulrich Weigand  <uweigand@de.ibm.com>
957
958         * mi/mi-main.c (mi_cmd_list_thread_groups): Use get_current_arch
959         instead of selected frame architecture.
960
961 2010-03-18  Pedro Alves  <pedro@codesourcery.com>
962
963         * infcmd.c (until_command): Use ERROR_NO_INFERIOR.  Ensure there's
964         a valid selected thread, and that it is not running.
965         (advance_command): Ditto.
966         (finish_command): Ditto.
967
968 2010-03-17 Stan Shebs  <stan@codesourcery.com>
969
970         * ax-gdb.c (require_rvalue): Disallow non-scalars.
971
972         * infcall.c: Include tracepoint.h.
973         (call_function_by_hand): Disallow calls in tfind mode.
974         * infcmd.c: Include tracepoint.h.
975         (ensure_not_tfind_mode): New function.
976         (continue_1): Call it.
977         (step_1) Ditto.
978         (jump_command): Ditto.
979         (signal_command): Ditto.
980         (advance_command): Ditto.
981         (until_command): Ditto.
982         (finish_command): Ditto.
983         * tracepoint.h (disconnect_or_stop_tracing): Declare.
984
985         * ax-gdb.h (struct axs_value): New field optimized_out.
986         (gen_trace_for_var): Add gdbarch argument.
987         * ax-gdb.c (gen_trace_static_fields): New function.
988         (gen_traced_pop): Call it, add gdbarch argument.
989         (gen_trace_for_expr): Update call to it.
990         (gen_trace_for_var): Ditto, and report optimized-out variables.
991         (gen_struct_ref_recursive): Check for optimized-out value.
992         (gen_struct_elt_for_reference): Ditto.
993         (gen_static_field): Pass gdbarch instead of expression, assume
994         optimization if field not found.
995         (gen_var_ref): Set the optimized_out flag.
996         (gen_expr): Error on optimized-out variable.
997         * tracepoint.c (collect_symbol): Handle struct-valued vars as
998         expressions, skip optimized-out variables with computed locations.
999         * dwarf2loc.c (dwarf2_tracepoint_var_ref): Flag instead of
1000         erroring out if location expression missing.
1001         (loclist_tracepoint_var_ref): Don't error out here.
1002
1003 2010-03-17  Tom Tromey  <tromey@redhat.com>
1004
1005         * dwarf2read.c (dwarf2_get_section_info): Handle case where no
1006         DWARF data is available.
1007
1008 2010-03-17  Daniel Jacobowitz  <dan@codesourcery.com>
1009
1010         * symfile.c (generic_load): Reset breakpoints after loading.
1011
1012 2010-03-17  Tom Tromey  <tromey@redhat.com>
1013
1014         * linux-nat.c (linux_nat_detach): Check debug_linux_nat.
1015
1016 2010-03-17  Jan Kratochvil  <jan.kratochvil@redhat.com>
1017
1018         * spu-tdep.c (spu_catch_start): Replace set_breakpoint call with the
1019         create_breakpoint call, adjust the parameters.
1020
1021 2010-03-16  Jan Kratochvil  <jan.kratochvil@redhat.com>
1022             Chandru <chandru@in.ibm.com>
1023
1024         * dwarf2read.c (read_subrange_type): Set TYPE_HIGH_BOUND_UNDEFINED.
1025         * valarith.c (value_subscripted_rvalue): Suppress error if
1026         TYPE_ARRAY_UPPER_BOUND_IS_UNDEFINED.
1027
1028 2010-03-16  Holger Hans Peter Freyther  <zecke@selfish.org>
1029
1030         * linux-record.c (record_linux_msghdr): Remove unintended semicolons.
1031
1032 2010-03-16  Joel Brobecker  <brobecker@adacore.com>
1033
1034         * ada-tasks.c (task_command_1): Check that the task ptid is valid
1035         before doing the associated thread switch.
1036
1037 2010-03-16  Daniel Jacobowitz  <dan@codesourcery.com>
1038
1039         * MAINTAINERS: Update my email address.
1040
1041 2010-03-16  Vladimir Prus  <vladimir@codesourcery.com>
1042
1043         Simplify MI breakpoint setting.
1044
1045         * breakpoint.c (break_command_really): Make nonstatic and
1046         rename to...
1047         (create_breakpoint): ...this. Rename prior function by this name
1048         to...
1049         (create_breakpoint_sal): ...this.
1050         (create_breakpoints): Rename to...
1051         (create_breakpoints_sal): ...this.
1052         (set_breakpoint): Remove.
1053         * breakpoint.h: Adjust to above changes.
1054         * mi/mi-cmd-break.c (mi_cmd_break_insert): Simplify.
1055
1056 2010-03-15 Stan Shebs  <stan@codesourcery.com>
1057
1058         * ax-gdb.c: Include cp-support.h.
1059         (find_field): Remove.
1060         (gen_primitive_field): New function.
1061         (gen_struct_ref_recursive): New function.
1062         (gen_struct_ref): Rewrite to call gen_struct_ref_recursive instead
1063         of find_field.
1064         (gen_static_field): New function.
1065         (gen_struct_elt_for_reference): New.
1066         (gen_namespace_elt): New.
1067         (gen_maybe_namespace_elt): New.
1068         (gen_aggregate_elt_ref): New.
1069         (gen_expr): Add OP_SCOPE, display opcode name in error message.
1070
1071 2010-03-15  Tom Tromey  <tromey@redhat.com>
1072
1073         * dwarf2read.c (die_needs_namespace): Also return 0 for
1074         DW_TAG_subprogram.
1075
1076 2010-03-15  Sami Wagiaalla  <swagiaal@redhat.com>
1077
1078         PR c++/7936:
1079         * cp-support.h: Added char *declaration element to using_direct
1080         data struct.
1081         (cp_add_using): Added char *declaration argument.
1082         (cp_add_using_directive): Ditto.
1083         (cp_lookup_symbol_imports): made extern.
1084         * cp-namespace.c: Updated with the above changes.
1085         * dwarf2read.c (read_import_statement): Ditto.
1086         (read_namespace): Ditto.
1087         (read_import_statement): Support import declarations.
1088         * cp-namespace.c (cp_lookup_symbol_imports): Check for imported
1089         declarations.
1090         Added support for 'declaration_only' search.
1091         (cp_lookup_symbol_namespace): Attempt to search for the name as
1092         is before consideration of imports.
1093         * symtab.c (lookup_symbol_aux_local): Added a 'declaration_only'
1094         search at every block level search.
1095         Now takes language argument.
1096         (lookup_symbol_aux): Updated.
1097
1098 2010-03-15  Tom Tromey  <tromey@redhat.com>
1099
1100         * c-exp.y (name_not_typename): Add 'operator' clause.
1101
1102 2010-03-15  Ralf Corsepius  <ralf.corsepius@rtems.org>  (tiny change)
1103
1104         * configure.ac: Exit if ${gdb_target_obs}" is not set.
1105         * configure: Regenerate.
1106
1107 2010-03-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
1108
1109         * symfile.c (addr_info_make_relative): Ignore also missing ".dynbss"
1110         and ".sdynbss".  Update the comment.
1111
1112 2010-03-15  Jie Zhang  <jie@codesourcery.com>
1113
1114         * MAINTAINERS: Update my email address.
1115
1116 2010-03-14  Daniel Jacobowitz  <dan@codesourcery.com>
1117
1118         * gdbtypes.h (TYPE_IS_OPAQUE): Correct HAVE_CPLUS_STRUCT check.
1119
1120 2010-03-14  Daniel Jacobowitz  <dan@codesourcery.com>
1121
1122         * charset.c [USE_WIN32API]: Include <windows.h>.
1123          (_initialize_charset): Correct type of w32_host_default_charset.
1124
1125 2010-03-14  Pedro Alves  <pedro@codesourcery.com>
1126
1127         * infrun.c (ptid_match): Don't assert that PTID is not a pid ptid.
1128
1129 2010-03-12  Tom Tromey  <tromey@redhat.com>
1130
1131         PR c++/9708:
1132         * dwarf2read.c (die_needs_namespace) <DW_TAG_variable>: A variable
1133         in a lexical block does not need a namespace.
1134         (new_symbol) <DW_TAG_variable>: Put extern variables on
1135         list_in_scope in all cases.
1136
1137 2010-03-12 Stan Shebs  <stan@codesourcery.com>
1138
1139         * ax-gdb.c (gen_expr): Add shift expressions.
1140         (gen_expr_binop_rest): Ditto.
1141
1142 2010-03-12  Sami Wagiaalla  <swagiaal@redhat.com>
1143
1144         * buildsym.c (finish_block): Reset using_directives pointer
1145         after block initialization.
1146
1147 2010-03-12  H.J. Lu  <hongjiu.lu@intel.com>
1148
1149         * amd64-tdep.c (amd64_word_names): Replace "sp" with "".
1150         * i386-tdep.c (i386_word_names): Likewise.
1151
1152 2010-03-12  Pedro Alves  <pedro@codesourcery.com>
1153
1154         * target.c (memory_xfer_partial): Don't use the stack cache if
1155         inspecting trace frames.
1156         * tracepoint.c (finish_tfind_command): Invalidate the target
1157         dcache.
1158
1159 2010-03-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
1160
1161         * solib-svr4.c (LM_ADDR_CHECK) <info_verbose>: Use printf_unfiltered
1162         for the PIC displacement, print also the displacement value.
1163         (svr4_exec_displacement):  Print DISPLACEMENT if INFO_VERBOSE.
1164
1165 2010-03-10  Kevin Buettner  <kevinb@redhat.com>
1166
1167         * remote-mips.c (close_ports, mips_initialize_cleanups)
1168         (mips_exit_cleanups, mips_send_command, mips_open, pmon_open)
1169         (ddb_open, lsi_open, mips_remove_breakpoint, mips_remove_watchpoint)
1170         (mips_stopped_by_watchpoint, send_srec, pmon_checkset)
1171         (pmon_make_fastrec, pmon_check_ack, mips_expect_download)
1172         (pmon_check_entry_address, pmon_check_total, pmon_end_download)
1173         (pmon_download, pmon_load_fast, _initialize_remote_mips): Add
1174         comments describing each of these functions.
1175         (mips_enter_debug, mips_exit_debug, common_open)
1176         (mips_signal_from_protocol, pmon_makeb64, pmon_zeroset): Add
1177         blank line after the comment describing the function.
1178
1179 2010-03-10  Jan Kratochvil  <jan.kratochvil@redhat.com>
1180
1181         * solib-svr4.c (svr4_exec_displacement): Return now success, new
1182         parameter displacementp.  Update comment.
1183         (svr4_relocate_main_executable): Return if non-zero SECTION_OFFSETS
1184         element exists.  Return if svr4_exec_displacement was not successful.
1185         Update comment.
1186
1187 2010-03-10  Jan Kratochvil  <jan.kratochvil@redhat.com>
1188             Daniel Jacobowitz  <dan@codesourcery.com>
1189
1190         * solib-svr4.c (read_program_header): Support type == -1 to read
1191         all program headers.
1192         (read_program_headers_from_bfd): New function.
1193         (svr4_static_exec_displacement): Remove and move the comment ...
1194         (svr4_exec_displacement): ... here.  Remove variable found.  New
1195         variable displacement.  Check also DYNAMIC.  Verify DISPLACEMENT
1196         alignment for ELF targets.  Compare target vs. exec_bfd PHDRs for ELF
1197         targets using read_program_headers_from_bfd.  Remove the call of
1198         svr4_static_exec_displacement.
1199
1200 2010-03-10  Tom Tromey  <tromey@redhat.com>
1201
1202         * dwarf2read.c (struct pubnames_header): Remove.
1203         (_PUBNAMES_HEADER): Remove.
1204         (_ACTUAL_PUBNAMES_HEADER_SIZE): Remove.
1205         (struct aranges_header): Remove.
1206         (_ARANGES_HEADER, _ACTUAL_ARANGES_HEADER_SIZE): Remove.
1207         (struct dwarf2_per_objfile) <pubnames, aranges>: Remove.
1208         (PUBNAMES_SECTION): Remove.
1209         (ARANGES_SECTION): Remove.
1210         (dwarf2_locate_sections): Don't handle pubnames or aranges.
1211         (dwarf2_build_psymtabs): Remove dead code.
1212         (dwarf2_build_psymtabs_easy): Remove.
1213
1214 2010-03-10  Tom Tromey  <tromey@redhat.com>
1215
1216         * elfread.c (elf_symfile_read): Don't call
1217         dwarf2_build_frame_info.
1218         * dwarf2read.c (struct dwarf2_section_info) <readin>: New field.
1219         (struct dwarf2_per_objfile) <objfile>: New field.
1220         (dwarf2_has_info): Now idempotent.  Set objfile field.
1221         (dwarf2_read_section): Check and set readin field.  Call
1222         posix_madvise.
1223         (dwarf2_build_psymtabs): Don't read all sections.
1224         (read_type_comp_unit_head): Read types section.
1225         (create_debug_types_hash_table): Likewise.
1226         (init_cu_die_reader): Add asserts.
1227         (process_type_comp_unit): Add assert.
1228         (dwarf2_build_psymtabs_hard): Read info section.
1229         (load_partial_comp_unit): Add assert.
1230         (create_all_comp_units): Read info section.
1231         (load_full_comp_unit): Likewise.
1232         (dwarf2_ranges_read): Read ranges section.
1233         (dwarf2_record_block_ranges): Add assert.
1234         (dwarf2_read_abbrevs): Read abbrev section.
1235         (read_indirect_string): Read str section.
1236         (dwarf_decode_line_header): Read line section.
1237         (read_signatured_type_at_offset): Read types section.
1238         (dwarf_decode_macros): Read macinfo section.
1239         (dwarf2_symbol_mark_computed): Read loc section.
1240         * dwarf2-frame.c (dwarf2_frame_find_fde): Call
1241         dwarf2_build_frame_info.
1242         (dwarf2_build_frame_info): Unconditionally set
1243         dwarf2_frame_objfile_data on the objfile.
1244         * configure.ac: Check for posix_madvise.
1245         * config.in, configure: Rebuild.
1246
1247 2010-03-10  Tom Tromey  <tromey@redhat.com>
1248
1249         * xcoffread.c (xcoff_start_psymtab): Update.
1250         (xcoff_end_psymtab): Update.
1251         * psymtab.c (allocate_psymtab): Remove dead code.
1252         * psympriv.h (struct partial_symtab) <read_symtab_private>: Now
1253         void*.
1254         * mdebugread.c (parse_partial_symbols): Update.
1255         (new_psymtab): Likewise.
1256         * dwarf2read.c (process_psymtab_comp_unit): Update.
1257         (psymtab_to_symtab_1): Update.
1258         * dbxread.c (start_psymtab): Update.
1259         (end_psymtab): Likewise.
1260
1261 2010-03-10  Tom Tromey  <tromey@redhat.com>
1262
1263         * xcoffread.c: Include psymtab.h.
1264         (xcoff_sym_fns): Update.
1265         * symtab.h (struct partial_symbol): Remove.
1266         (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.
1267         (struct partial_symtab): Remove.
1268         (PSYMTAB_TO_SYMTAB): Remove.
1269         (lookup_partial_symbol, lookup_partial_symtab, find_pc_psymtab)
1270         (find_pc_sect_psymtab): Remove.
1271         (find_pc_sect_symtab_via_partial): Declare.
1272         (find_pc_psymtab, find_pc_sect_psymbol, psymtab_to_symtab)
1273         (find_main_psymtab): Remove.
1274         (find_main_filename): Declare.
1275         (fixup_psymbol_section): Remove.
1276         (fixup_section): Declare.
1277         * symtab.c: Include psymtab.h.
1278         (lookup_symtab): Use lookup_symtab method.
1279         (lookup_partial_symtab): Remove.
1280         (find_pc_sect_psymtab_closer): Remove.
1281         (find_pc_sect_psymtab): Remove.
1282         (find_pc_sect_symtab_via_partial): New function.
1283         (find_pc_psymtab, find_pc_sect_psymbol, find_pc_psymbol): Remove.
1284         (fixup_section): No longer static.
1285         (fixup_psymbol_section): Remove.
1286         (lookup_symbol_aux): Use lookup_symbol_aux_quick.
1287         (lookup_global_symbol_from_objfile): Likewise.
1288         (lookup_symbol_aux_psymtabs): Remove.
1289         (lookup_symbol_aux_quick): New function.
1290         (lookup_symbol_global): Use lookup_symbol_aux_quick.
1291         (lookup_partial_symbol): Remove.
1292         (basic_lookup_transparent_type_quick): New function.
1293         (basic_lookup_transparent_type): Use it.
1294         (find_main_psymtab): Remove.
1295         (find_main_filename): New function.
1296         (find_pc_sect_symtab): Use find_pc_sect_symtab method.
1297         (find_line_symtab): Use expand_symtabs_with_filename method.
1298         (output_partial_symbol_filename): New function.
1299         (sources_info): Use map_partial_symbol_filenames.
1300         (struct search_symbols_data): New type.
1301         (search_symbols_file_matches): New function.
1302         (search_symbols_name_matches): Likewise.
1303         (search_symbols): Use expand_symtabs_matching method.
1304         (struct add_name_data): Rename from add_macro_name_data.
1305         (add_macro_name): Update.
1306         (add_partial_symbol_name): New function.
1307         (default_make_symbol_completion_list): Use
1308         map_partial_symbol_names.
1309         (struct add_partial_symbol_name): New type.
1310         (maybe_add_partial_symtab_filename): New function.
1311         (make_source_files_completion_list): Use
1312         map_partial_symbol_filenames.
1313         (expand_line_sal): Use expand_symtabs_with_filename method.
1314         * symmisc.c: Include psymtab.h.
1315         (print_objfile_statistics): Use print_stats method.
1316         (dump_objfile): Use dump method.
1317         (dump_psymtab, maintenance_print_psymbols)
1318         (maintenance_info_psymtabs, maintenance_check_symtabs)
1319         (extend_psymbol_list): Remove.
1320         * symfile.h (struct quick_symbol_functions): New struct.
1321         (struct sym_fns) <qf>: New field.
1322         (sort_pst_symbols): Remove.
1323         (increment_reading_symtab): Declare.
1324         * symfile.c: Include psymtab.h.
1325         (compare_psymbols, sort_pst_symbols): Remove.
1326         (psymtab_to_symtab): Remove.
1327         (increment_reading_symtab): New function.
1328         (symbol_file_add_with_addrs_or_offsets): Use expand_all_symtabs
1329         method.
1330         (set_initial_language): Use find_main_filename.
1331         (allocate_psymtab, discard_psymtab, cashier_psymtab): Remove.
1332         (free_named_symtabs): Remove unused code.
1333         (start_psymtab_common, add_psymbol_to_bcache)
1334         (append_psymbol_to_list, add_psymbol_to_list, init_psymbol_list):
1335         Remove.
1336         * stack.c: Include psymtab.h, symfile.h.
1337         (backtrace_command_1): Use find_pc_sect_symtab_via_partial.
1338         * source.h (psymtab_to_fullname): Don't declare.
1339         * source.c: Include psymtab.h.
1340         (select_source_symtab): Use find_last_source_symtab method.
1341         (forget_cached_source_info): Use forget_cached_source_info
1342         method.
1343         (find_and_open_source): No longer static.
1344         (psymtab_to_fullname): Remove.
1345         * somread.c: Include psymtab.h.
1346         (som_sym_fns): Update.
1347         * psympriv.h: New file.
1348         * psymtab.h: New file.
1349         * psymtab.c: New file.
1350         * objfiles.h: (ALL_OBJFILE_PSYMTABS): Remove.
1351         (ALL_PSYMTABS, ALL_PSPACE_PSYMTABS): Likewise.
1352         * objfiles.c: Include psymtab.h.
1353         (objfile_relocate1): Use relocate method.
1354         (objfile_has_partial_symbols): Use has_symbols method.
1355         * mipsread.c: Include psymtab.h.
1356         (ecoff_sym_fns): Update.
1357         * mi/mi-cmd-file.c: Include psymtab.h.
1358         (print_partial_file_name): New function.
1359         (mi_cmd_file_list_exec_source_files): Use
1360         map_partial_symbol_filenames.
1361         * mdebugread.c: Include psympriv.h.
1362         * machoread.c: Include psympriv.h.
1363         (macho_sym_fns): Update.
1364         * m2-exp.y (yylex): Use lookup_symtab.
1365         * elfread.c: Include psympriv.h.
1366         (elf_sym_fns): Update.
1367         * dwarf2read.c: Include psympriv.h.
1368         * dbxread.c: Include psympriv.h.
1369         (aout_sym_fns): Update.
1370         * cp-support.c: Include psymtab.h.
1371         (read_in_psymtabs): Remove.
1372         (make_symbol_overload_list_qualified): Use
1373         expand_symtabs_for_function method.
1374         * coffread.c: Include psympriv.h.
1375         (coff_sym_fns): Update.
1376         * blockframe.c: Include psymtab.h.
1377         (find_pc_partial_function): Use find_pc_sect_symtab method.
1378         * ada-lang.h (ada_update_initial_language): Update.
1379         * ada-lang.c: Include psymtab.h.
1380         (ada_update_initial_language): Remove 'main_pst' argument.
1381         (ada_lookup_partial_symbol): Remove.
1382         (struct ada_psym_data): New type.
1383         (ada_add_psyms): New function.
1384         (ada_add_non_local_symbols): Use map_ada_symtabs method.
1385         (struct add_partial_datum): New type.
1386         (ada_add_partial_symbol_completions): New function.
1387         (ada_make_symbol_completion_list): Use map_partial_symbol_names.
1388         (ada_exception_support_info_sniffer): Update.
1389         * Makefile.in (SFILES): Add psymtab.c.
1390         (COMMON_OBS): Add psymtab.o.
1391         (HFILES_NO_SRCDIR): Add psymtab.h, psympriv.h.
1392
1393 2010-03-10  Pierre Muller  <muller@ics.u-strasbg.fr>
1394
1395         * remote-fileio.c (cygwin_conv_path): Define macro for old cygwin API.
1396
1397 2010-03-10  Sami Wagiaalla  <swagiaal@redhat.com>
1398
1399         PR C++/11236:
1400         * cp-namespace.c (cp_add_using): Deleted.
1401         (cp_add_using_directive): Use obstack allocations.
1402         Merged the function cp_add_using into this one.
1403         Added 'struct obstack *' argument.
1404         (cp_scan_for_anonymous_namespaces): Updated.
1405         * cp-support.h: Updated.
1406         * dwarf2read.c (read_import_statement): Updated.
1407         (read_namespace): Updated.
1408
1409 2010-03-10  Pierre Muller  <muller@ics.u-strasbg.fr>
1410
1411         * windows-nat.c (cygwin_conv_path): Remove old macro.
1412
1413 2010-03-10  Pedro Alves  <pedro@codesourcery.com>
1414
1415         * breakpoint.c (condition_command): Handle watchpoint conditions.
1416         (is_hardware_watchpoint): Add comment.
1417         (is_watchpoint): New.
1418         (update_watchpoint): Don't reparse the watchpoint's condition
1419         unless necessary.
1420         (WP_IGNORE): New.
1421         (watchpoint_check): Use it.
1422         (bpstat_check_watchpoint): Handle it.
1423         (bpstat_check_breakpoint_conditions): Evaluate watchpoint local
1424         conditions in a frame where it makes sense.
1425         (watch_command_1): Store the innermost block of the condition
1426         expression.
1427         (delete_breakpoint): Delete the watchpoint condition expression.
1428         * breakpoint.h (struct bp_location) <cond>: Update comment.
1429         (struct breakpoint): New field `cond_exp_valid_block'.
1430
1431 2010-03-09  Joel Brobecker  <brobecker@adacore.com>
1432
1433         Adjust handling of Ada DIEs after dwarf2_physname patch.
1434         * dwarf2read.c (dwarf2_compute_name): Add handling of Ada DIEs.
1435
1436 2010-03-09  Christopher Faylor  <me+cygwin@cgf.cx>
1437             Pierre Muller  <muller@ics.u-strasbg.fr>
1438
1439         * windows-nat.c (cygwin_conv_path): Redefine to properly convert
1440         from/to posix/win32.
1441         (windows_make_so): Use non-Cygwin 1.7 specific function.
1442         (windows_create_inferior): Make sure that cygallargs points to
1443         original args in non Cygwin 1.7. case.
1444
1445 2010-03-09  Michael Snyder  <msnyder@vmware.com>
1446
1447         * i386-tdep.c (i386_record_lea_modrm_addr): Use extract_signed_int
1448         after target_read_memory to get host byte order.
1449         (i386_process_record): Ditto.
1450
1451 2010-03-09  Keith Seitz  <keiths@redhat.com>
1452
1453         Based on work from Daniel Jacobowitz  <dan@codesourcery.com>
1454         * c-typeprint.c (cp_type_print_method_args): For non-static methods,
1455         print out const or volatile qualifiers, too.
1456         (c_type_print_args): Add parameters show_artificial and language.
1457         Skip artificial parameters when requested.
1458         Use the appropriate language printer.
1459         (c_type_print_varspec): Tell c_type_print_args to skip artificial
1460         parameters and pass language_c.
1461         * dwarf2read.c (die_list): New file global.
1462         (struct partial_die_info): Update comments for name field.
1463         (pdi_needs_namespace): Renamed to ...
1464         (die_needs_namespace): ... this. Rewrite.
1465         (dwarf2_linkage_name): Remove.
1466         (add_partial_symbol): Do not predicate the call to
1467         partial_die_full_name based on pdi_needs_namespace.
1468         Remove call to cp_check_possible_namespace_symbols and associated
1469         outdated comments.
1470         (guess_structure_name): Do not inspect child subprogram DIEs.
1471         (dwarf2_fullname): Update comments.
1472         Use die_needs_namespace to assist in computing the name.
1473         (read_func_scope): Use dwarf2_name to get the DIE's name.
1474         Use dwarf2_physname to get the "linkage name" of the DIE.
1475         (dwarf2_add_member_field): Use dwarf2_physname instead of
1476         dwarf2_linkage_name.
1477         (read_structure_type): For structs and classes, set TYPE_NAME, too.
1478         (determine_class): Remove.
1479         (read_partial_die): Ignore DW_AT_MIPS_linkage_name for all languages
1480         except Ada.
1481         (new_symbol): Unconditionally call dwarf2_name.
1482         Compute the "linkage name" using dwarf2_physname.
1483         Use dwarf2_name instead of dwarf2_full_name for enumerator DIEs.
1484         When determining to scan for anonymous C++ namespaces, ignore
1485         the linkage name.
1486         (dwarf2_physname): New function.
1487         (dwarf2_full_name): Move content to new function and call
1488         that.
1489         (dwarf2_compute_name): "New" function.
1490         (_initialize_dwarf2_read): Initialize die_list.
1491         * gnu-v3-eabi.c (gnu_v3_find_method_in): Remove unused variable
1492         physname.
1493         (gnu_v3_print_method_ptr): Use the physname for virtual methods
1494         without a demangled name.
1495         Print out type information for non-virtual methods.
1496         * linespec.c (decode_line_1): Force ANY string using "::" (or
1497         "." for java) to use decode_compound, and clean up any stray quoting.
1498         If we found a file symtab, re-evaluate whether the remainder is_quoted.
1499         (decode_compound): Stop consuming at an open parenthesis.
1500         Keep template parameters.
1501         Keep any overload information.
1502         Keep keywords like "const".
1503         Remove paren_pointer.
1504         Move is_quoted check from set_flags to here.
1505         Remove #if 0 code from 2000. Ten years is long enough.
1506         (find_method): Before comparing symbol names, canonicalize the string
1507         from the user.
1508         If a specific overload is requested, find it. Otherwise throw an error.
1509         (find_method_overload_end): New function.
1510         (set_flags): Remove.
1511         (decode_compound): Assume that parentheses are matched.
1512         It's a lot easier.
1513         * symtab.c (symbol_find_demangled_name): Add DMGL_VERBOSE flag
1514         to cplus_demangle.
1515         * linespec.c (decode_line_1): Keep important keywords like
1516         "const" and "volatile".
1517         * symtab.h (SYMBOL_CPLUS_DEMANGLED_NAME): Remove.
1518         * typeprint.h (c_type_print_args): Add declaration.
1519         * ui-file.c (do_ui_file_obsavestring): New function.
1520         (ui_file_obsavestring): New function.
1521         * ui-file.h (ui_file_obsavestring): Add declaration.
1522         * valops.c (find_overload_match): Resolve the object to
1523         a non-pointer type.
1524         If the object is a data member, search the object for the member
1525         and return with staticp set.
1526         Use SYMBOL_NATURAL_NAME instead of SYMBOL_CPLUS_DEMANGLED_NAME.
1527         Do not attempt to extract a function name from non-function types.
1528         If the extracted function name and the original name are the same,
1529         we don't have a C++ method.
1530
1531         From Jan Kratochvil  <jan.kratochvil@redhat.com>:    
1532         * dwarf2read.c (new_symbol <DW_TAG_enumerator>): Call dwarf2_full_name.
1533
1534         * ada-lang.c (ada_lookup_symbol): Remove linkage_name parameters
1535         and arguments from symbol lookups.
1536         * ax-gdb.c (gen_expr): Likewise.
1537         * cp-namespace.c (cp_lookup_symbol_nonlocal, lookup_namespace_scope,
1538         cp_lookup_symbol_namespace, lookup_symbol_file, lookup_nested_type,
1539         lookup_possible_namespace_symbol): Likewise.
1540         * cp-support.c (read_in_psymtabs): Likewise.
1541         * cp-support.h (cp_lookup_symbol_nonlocal): Likewise.
1542         * language.h (la_lookup_symbol_nonlocal): Likewise.
1543         * scm-valprint.c (scm_inferior_print): Likewise.
1544         * solib-darwin.c (darwin_relocate_section_addresses): Likewise.
1545         * solib-svr.c (elf_lookup_lib): Likewise.
1546         * solib.c (show_auto_solib_add): Likewise.
1547         * solist.h (lookup_lib_global, solib_global_lookup): Likewise.
1548         * symmisc.c (maintenance_check_symtabs): Likewise.
1549         * symtab.c (lookup_symbol_in_language, lookup_symbol_aux,
1550         lookup_symbol_aux_local, lookup_symbol_aux_block,
1551         lookup_symbol_from_objfile, lookup_symbol_aux_symtabs,
1552         lookup_symbol_aux_psymtabs,basic_lookup_symbol_nonlocal,
1553         lookup_symbol_static, lookup_symbol_global, symbol_matches_domain,
1554         basic_lookup_transparent_type, find_main_psymtab,
1555         lookup_block_symbol): Likewise.
1556         * symtab.h (basic_lookp_symbol_nonlocal, lookup_symbol_static,
1557         lookup_symbol_global, lookup_symbol_aux_block,
1558         lookup_symbol_partial_symbol, lookup_block_symbol,
1559         lookup_global_symbol, value_maybe_namespace_elt): Likewise.
1560
1561 2010-03-09  Pierre Muller  <muller@ics.u-strasbg.fr>
1562
1563         * python/python-internal.h: Include symtab.h.
1564
1565 2010-03-09  Joel Brobecker  <brobecker@adacore.com>
1566             Pierre Muller  <muller@ics.u-strasbg.fr>
1567
1568         * p-lang.c (is_pascal_string_type): Remove unneeded parentheses.
1569         * p-valprint.c (pascal_val_print): Remove undeed block and fix
1570         indentation.
1571
1572 2010-03-08  Tom Tromey  <tromey@redhat.com>
1573
1574         * breakpoint.c (breakpoint_1): Add "QUIT".
1575
1576 2010-03-08  Daniel Jacobowitz  <dan@codesourcery.com>
1577             Pedro Alves  <pedro@codesourcery.com>
1578
1579         * solib.c (solib_find): Replace extension if
1580         solib_symbols_extension is set in the target gdbarch.
1581         * arm-symbian-tdep.c (arm_symbian_init_abi): Set
1582         solib_symbols_extension to "sym".
1583         * gdbarch.sh (solib_symbols_extension): New variable.
1584         (pstring): New function.
1585         * gdbarch.h, gdbarch.c: Regenerate.
1586
1587 2010-03-08  Tom Tromey  <tromey@redhat.com>
1588
1589         PR cli/9591:
1590         * NEWS: Update.
1591         * utils.c: Include main.h.
1592         (fputs_maybe_filtered): Don't paginate if `batch_flag'.
1593         (defaulted_query): Use default answer if `batch_flag'.
1594         * main.h (batch_flag): Declare.
1595         * main.c (batch_flag): New global.
1596         (captured_main): Remove 'batch'.  Update.
1597
1598 2010-03-08  Kevin Buettner  <kevinb@redhat.com>
1599
1600         From Richard Sandiford, Martin M. Hunt, Corinna Vinschen,
1601         and Kevin Buettner:
1602
1603         * remote-mips.c (rockhopper_ops): New target_ops struct.
1604         (MON_ROCKHOPPER): New mips_monitor_type.
1605         (read_hex_value): New function.
1606         (mips_request): Send 8-byte values with a 'T' packet.  Read the
1607         packet argument as a string and use read_hex_value to parse it.  
1608         (mips_exit_debug): Wait for response when using MON_ROCKHOPPER.
1609         (rockhopper_open): New function.
1610         (mips_wait): Read the PC, FP and SP fields as strings.  Use
1611         read_hex_value to parse them and mips_set_register to commit them.
1612         (mips_set_register): New function.
1613         (mips_fetch_registers): Do not cast register value to "unsigned"
1614         when reading a MON_ROCKHOPPER 't' packet.  Use mips_set_register.
1615         (mips_store_registers): Use a 'T' packet to set registers when
1616         using MON_ROCKHOPPER.
1617         (pmon_end_download): Don't run initEther if using MON_ROCKHOPPER
1618         and expect the total to be printed before the entry address.
1619         (_initialize_remote_mips): Initialize and add rockhopper_ops.
1620
1621 2010-03-08  Kevin Buettner  <kevinb@redhat.com>
1622
1623         * remote-mips.c (mips_fetch_word): Add new parameter, `valp'.
1624         Change return value to int.  Store value fetched in location
1625         addressed by `val'.  Use function's return value as success
1626         or failure indicator.  Adjust all callers.
1627
1628 2010-03-08  Pierre Muller  <muller@ics.u-strasbg.fr>
1629
1630         * p-lang.c (is_pascal_string_type): Check that TYPE arg is non NULL.
1631
1632 2010-03-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
1633             Hui Zhu  <teawater@gmail.com>
1634
1635         * record.c (record_open_1): Check tmp_to_stopped_by_watchpoint and
1636         tmp_to_stopped_data_address.
1637         (record_open): Reset tmp_to_stopped_by_watchpoint and
1638         tmp_to_stopped_data_address.
1639         * target.c (init_dummy_target): Add to_stopped_by_watchpoint and
1640         to_stopped_data_address.
1641
1642 2010-03-08  Hui Zhu  <teawater@gmail.com>
1643
1644         * i386-tdep.c (i386_process_record): Initialize regnum.
1645
1646 2010-03-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
1647
1648         * symfile.c (addr_info_make_relative): New variable sect_name, use it.
1649         Do not warn on ".gnu.liblist" and ".gnu.conflict".
1650
1651 2010-03-08  Joel Brobecker  <brobecker@adacore.com>
1652
1653         Memory error when reading wrong core file.
1654         * solib-svr4.c (solib_svr4_r_map): catch and print all exception
1655         errors while reading the inferior memory, and return zero if
1656         an exception was raised.
1657
1658 2010-03-07  Michael Snyder  <msnyder@vmware.com>
1659
1660         * record.c (record_restore): Rename tmpu8 to rectype.
1661
1662         * i386-tdep.c (i386_record_lea_modrm_addr): Rename local variables
1663         tmpu8, tmpi16, tmpi32, tmpulongest to addr8, addr16, addr32, addr64.
1664
1665         (i386_record_push): Rename local tmpulongest to addr.
1666
1667         (i386_process_record): Rename local tmpulongest to addr.
1668
1669         Rename local variables tmpu16, tmpu32, tmpu64 to addr16, addr32,
1670         addr64.
1671
1672         Rename local variable tmpu8 to opcode8 and regnum.
1673
1674 2010-03-07  Joel Brobecker  <brobecker@adacore.com>
1675
1676         * remote.c (remote_get_ada_task_ptid): New function.
1677         (init_remote_ops): Set remote_ops.to_get_ada_task_ptid.
1678
1679 2010-03-06  Christopher Faylor  <me+cygwin@cgf.cx>
1680
1681         * windows-nat.c: Reorganize #ifdef __CYGWIN__ considerations into one
1682         block.  Define helper macros to reduce ifdefs in code.
1683         (get_module_name): Use cygwin_buf_t for buffer and __PMAX for buffer
1684         size.  Call unadorned GetModuleFileNameEx rather than
1685         GetModuleFileNameEx*.
1686         (windows_make_so): Use __PMAX to denote maximum buffer size and
1687         cygwin_buf_t for buffer type.  Use GetSystemDirectory{W,A} as
1688         appropriate.
1689         (get_image_name): Use __PMAX to denote maximum buffer size.
1690         (handle_load_dll): Likewise.
1691         (windows_pid_to_exec_file): Likewise.
1692         (windows_create_inferior): Add many accommodations for older Cygwin and
1693         non-Cygwin.
1694         (bad_GetModuleFileNameExW): Control inclusion of this function based on
1695         __USEWIDE conditional.
1696         (bad_GetModuleFileNameExA): Likewise.
1697         (_initialize_loadable): Just use real function names without the dyn_
1698         part since they are defined earlier.
1699
1700 2010-03-05  Corinna Vinschen  <vinschen@redhat.com>
1701             Tom Tromey  <tromey@redhat.com>
1702
1703         * utils.c (host_char_to_target): Add 'gdbarch' argument.
1704         (parse_escape): Likewise.
1705         * python/py-utils.c (unicode_to_target_string): Update.
1706         (unicode_to_target_python_string): Update.
1707         (target_string_to_unicode): Update.
1708         * printcmd.c (printf_command): Update.
1709         * p-exp.y (yylex): Update.
1710         * objc-exp.y (yylex): Update.
1711         * mi/mi-parse.c: Include charset.h.
1712         (mi_parse_escape): New function.
1713         (mi_parse_argv): Use it.
1714         * jv-exp.y (yylex): Update.
1715         * i386-cygwin-tdep.c (i386_cygwin_auto_wide_charset): New
1716         function.
1717         (i386_cygwin_init_abi): Call set_gdbarch_auto_wide_charset.
1718         * gdbarch.sh (auto_charset, auto_wide_charset): New.
1719         * gdbarch.c: Rebuild.
1720         * gdbarch.h: Rebuild.
1721         * defs.h (parse_escape): Update.
1722         * cli/cli-setshow.c: Include arch-utils.h.
1723         (do_setshow_command): Update.
1724         * cli/cli-cmds.c (echo_command): Update.
1725         * charset.h (target_charset, target_wide_charset): Update.
1726         * charset.c: Include arch-utils.h.
1727         (target_charset_name): Default to "auto".
1728         (target_wide_charset_name): Likewise.
1729         (show_target_charset_name): Handle "auto".
1730         (show_target_wide_charset_name): Likewise.
1731         (be_le_arch): New global.
1732         (set_be_le_names): Add 'gdbarch' argument.
1733         (validate): Likewise.  Don't call set_be_le_names.
1734         (set_charset_sfunc, set_host_charset_sfunc)
1735         (set_target_charset_sfunc, set_target_wide_charset_sfunc):
1736         Update.
1737         (target_charset): Add 'gdbarch' argument.
1738         (target_wide_charset): Likewise.  Remove 'byte_order' argument.
1739         (auto_target_charset_name): New global.
1740         (default_auto_charset, default_auto_wide_charset): New functions.
1741         (_initialize_charset): Set auto_target_charset_name.  Allow "auto"
1742         for target charsets.  Copy result of nl_langinfo.  Use GetACP if
1743         USE_WIN32API.
1744         * c-lang.c (charset_for_string_type): Add 'gdbarch' argument,
1745         remove 'byte_order' argument.  Update.
1746         (classify_type): Likewise.
1747         (c_emit_char): Update.
1748         (c_printchar): Update.
1749         (c_printstr): Update.
1750         (c_get_string): Update.
1751         (evaluate_subexp_c): Update.
1752         * arch-utils.h (default_auto_charset, default_auto_wide_charset):
1753         Declare.
1754         * python/python.c (gdbpy_target_charset): New function.
1755         (gdbpy_target_wide_charset): Likewise.
1756         (GdbMethods): Update.
1757         * NEWS: Update.
1758
1759 2010-03-05  Ulrich Weigand  <uweigand@de.ibm.com>
1760
1761         * symfile.c (build_section_addr_info_from_objfile): Do not mask
1762         off high address bits.
1763
1764 2010-03-05  Ulrich Weigand  <uweigand@de.ibm.com>
1765
1766         * python/py-lazy-string.c (gdbpy_extract_lazy_string): Extract
1767         address as UnsignedLongLong, not LongLong.
1768
1769 2010-03-05  Kevin Buettner  <kevinb@redhat.com>
1770             Pedro Alves  <pedro@codesourcery.com>
1771
1772         * remote-mips.c (gdbthread.h): Include.
1773         (remote_mips_ptid): Declare.
1774         (mips_error): Only mourn the inferior when inferior_ptid is non-null.
1775         (common_open): Set inferior_ptid, add it as an inferior, and
1776         as a thread too.  Delete FIXME comment regarding start_remote().
1777         (mips_close): Invoke generic_mourn_inferior().
1778         (mips_kill): Make sure that target_mourn_inferior is invoked.
1779         (mips_mourn_inferior): Don't invoke generic_mourn_inferior, as
1780         it's now invoked from mips_close().
1781         (mips_load): Don't null out inferior_ptid.  Don't call
1782         clear_symtab_users().
1783         (mips_thread_alive, mips_pid_to_str): New functions.
1784         (_initialize_remote_mips): Initialize remote_mips_ptid.  Initialize
1785         to_thread_alive and to_pid_to_str operations.
1786
1787 2010-03-04  Tom Tromey  <tromey@redhat.com>
1788
1789         * dwarf2read.c (skip_one_die) <DW_FORM_ref_addr>: Use offset size
1790         in DWARF 3 and later.
1791         (read_attribute_value) <DW_FORM_ref_addr>: Likewise.
1792
1793 2010-03-04  Keith Seitz  <keiths@redhat.com>
1794
1795         * linespec.c (decode_line_1): Update comments for is_quote_enclosed.
1796         If the filename portion of the linespec was quoted, recheck the
1797         remainder for additional quoting.
1798         (locate_first_half): Skip over completer chars, too.
1799
1800 2010-03-04  Tom Tromey  <tromey@redhat.com>
1801
1802         * printcmd.c (printf_command): Pass dummy argument to
1803         printf_filtered.
1804
1805 2010-03-04  Doug Evans  <dje@google.com>
1806
1807         * arm-tdep.c (arm_make_stub_cache): Delete unused locals reg,
1808         unwound_fp.
1809
1810         * arm-tdep.c (arm_stub_unwind_sniffer): Add comment.
1811
1812 2010-03-04  Pedro Alves  <pedro@codesourcery.com>
1813
1814         * breakpoint.c (update_watchpoint): Create a sentinel location if
1815         the software watchpoint isn't watching any memory.
1816         (breakpoint_address_bits): Skip dummy software watchpoint locations.
1817
1818 2010-03-04  Pedro Alves  <pedro@codesourcery.com>
1819
1820         * utils.c (fputs_maybe_filtered): Check if there's already a top
1821         level interpreter before dereferencing it.  If there isn't one,
1822         don't paginate either.
1823
1824 2010-03-04  Matthew Gretton-Dann  <matthew.gretton-dann@arm.com>
1825
1826         * arm-tdep.c (arm_pc_is_thumb): Add heuristic that tries to get
1827         the state right when single stepping.
1828         (arm_get_next_pc_raw, thumb_get_next_pc_raw): New functions.
1829         Get the next PC along with the instruction state.
1830         (thumb_get_next_pc): Remove.
1831         (arm_get_next_pc): Modified to use arm_get_next_pc_raw.
1832
1833 2010-03-04  Hui Zhu  <teawater@gmail.com>
1834
1835         * i386-tdep.c (i386_process_record): Change "addr" to "tmpu64".
1836
1837 2010-03-03  Pedro Alves  <pedro@codesourcery.com>
1838
1839         * utils.c (fputs_maybe_filtered): Always disable pagination if the
1840         top level interpreter is MI.
1841
1842 2010-03-03 Stan Shebs  <stan@codesourcery.com>
1843
1844         * remote.c (remote_download_tracepoint): Iterate over locations.
1845         * tracepoint.c (validate_actionline): Ditto.
1846         (encode_actions): Add location argument.
1847         (trace_dump_command): Check all locations to see if stepping
1848         frame.
1849
1850 2010-03-03  H.J. Lu  <hongjiu.lu@intel.com>
1851             Eli Zaretskii  <eliz@gnu.org>
1852
1853         * NEWS: Add X86 general purpose registers section.
1854
1855 2010-03-03  Tom Tromey  <tromey@redhat.com>
1856
1857         PR mi/11098:
1858         * varobj.c (install_new_value): Handle case where new print_value
1859         is NULL.
1860
1861 2010-03-03  Dainis Jonitis  <jonitis@gmail.com>
1862
1863         PR gdb/11345:
1864         * printcmd.c (printf_command): Print end of format string using
1865         printf_filtered.
1866
1867 2010-03-02  Tom Tromey  <tromey@redhat.com>
1868
1869         * mi/mi-cmd-break.c (mi_read_next_line): Add missing 'void'.
1870         * defs.h (read_command_lines_1): Add missing 'void'.
1871         * cli/cli-script.c (recurse_read_control_structure): Add missing
1872         'void'.
1873         (read_next_line): Likewise.
1874         (read_command_lines_1): Likewise.
1875
1876 2010-03-02  Ulrich Weigand  <uweigand@de.ibm.com>
1877
1878         * spu-tdep.c (spu_analyze_prologue): Track instruction to
1879         store backchain as part of prologue.
1880
1881 2010-03-02  Daniel Jacobowitz  <dan@codesourcery.com>
1882
1883         * progspace.c (update_address_spaces): Update inferior address spaces
1884         also.
1885
1886 2010-03-02  Doug Evans  <dje@google.com>
1887
1888         * dwarf2read.c (add_partial_subprogram): Add missing baseaddr to
1889         lowpc,highpc args to addrmap_set_empty.
1890
1891 2010-03-02  H.J. Lu  <hongjiu.lu@intel.com>
1892
1893         * amd64-tdep.c (amd64_byte_names): New.
1894         (amd64_word_names): Likewise.
1895         (amd64_dword_names): Likewise.
1896         (amd64_pseudo_register_name): Likewise.
1897         (amd64_pseudo_register_read): Likewise.
1898         (amd64_pseudo_register_write): Likewise.
1899         (amd64_init_abi): Set num_byte_regs, num_word_regs, num_dword_regs
1900         and num_mmx_regs.  Call set_gdbarch_pseudo_register_read,
1901         set_gdbarch_pseudo_register_write and
1902         set_tdesc_pseudo_register_name.  Don't call
1903         set_gdbarch_num_pseudo_regs.  Don't set mm0_regnum.
1904
1905         * i386-tdep.c (i386_num_mmx_regs): Removed.
1906         (i386_num_pseudo_regs): Likewise.
1907         (i386_byte_names): New.
1908         (i386_word_names): Likewise.
1909         (i386_byte_regnum_p): Likewise.
1910         (i386_word_regnum_p): Likewise.
1911         (i386_mmx_regnum_p): Updated.
1912         (i386_pseudo_register_name): Make it global.  Handle byte and
1913         word pseudo-registers.
1914         (i386_pseudo_register_read): Likewise.
1915         (i386_pseudo_register_write): Likewise.
1916         (i386_pseudo_register_type): Handle byte, word and dword
1917         pseudo-registers
1918         (i386_register_reggroup_p): Don't include pseudo
1919         registers, except for MXX, in any register groups.  Don't
1920         include pseudo byte, word, dword registers in general_reggroup.
1921         (i386_gdbarch_init): Set num_byte_regs, num_word_regs,
1922         num_dword_regs, al_regnum, ax_regnum and eax_regnum.  Put MMX
1923         pseudo-registers after word pseudo-registers.  Call
1924         set_gdbarch_num_pseudo_regs after calling gdbarch_init_osabi.
1925
1926         * i386-tdep.h (gdbarch_tdep): Add num_mmx_regs, num_byte_regs,
1927         al_regnum, num_word_regs, ax_regnum, num_dword_regs and
1928         eax_regnum.
1929         (i386_byte_regnum_p): New.
1930         (i386_word_regnum_p): Likewise.
1931         (i386_dword_regnum_p): Likewise.
1932         (i386_pseudo_register_name): Likewise.
1933         (i386_pseudo_register_read): Likewise.
1934         (i386_pseudo_register_write): Likewise.
1935
1936 2010-03-01  H.J. Lu  <hongjiu.lu@intel.com>
1937
1938         * target-descriptions.c (tdesc_type): Remove
1939         TDESC_TYPE_I386_EFLAGS and TDESC_TYPE_I386_MXCSR.
1940         (tdesc_predefined_types): Likewise.
1941         (tdesc_gdb_type): Likewise.  Pass NULL to append_flags_type_flag
1942         if flag name is empty.
1943         (maint_print_c_tdesc_cmd): Handle TDESC_TYPE_FLAGS.
1944
1945         * features/i386/32bit-core.xml: Define i386_eflags.
1946         * features/i386/64bit-core.xml: Likewise.
1947
1948         * features/i386/32bit-sse.xml: Define i386_mxcsr.
1949         * features/i386/64bit-sse.xml: Likewise.
1950
1951         * features/i386/amd64-linux.c: Regenerated.
1952         * features/i386/amd64.c: Likewise.
1953         * features/i386/i386-linux.c: Likewise.
1954         * features/i386/i386.c: Likewise.
1955
1956 2010-03-01  Daniel Jacobowitz  <dan@codesourcery.com>
1957
1958         * gdbtypes.c (append_composite_type_field_raw): New.
1959         (append_composite_type_field_aligned): Use the new function.
1960         * gdbtypes.h (append_composite_type_field_raw): Declare.
1961         * target-descriptions.c (struct tdesc_type_field): Add start and end.
1962         (struct tdesc_type_flag): New type.
1963         (struct tdesc_type): Add TDESC_TYPE_STRUCT and TDESC_TYPE_FLAGS to
1964         kind.  Add size to u.u.  Add u.f for flags.
1965         (tdesc_gdb_type): Handle TDESC_TYPE_STRUCT and TDESC_TYPE_FLAGS.
1966         (tdesc_free_type): Likewise.
1967         (tdesc_create_struct, tdesc_set_struct_size, tdesc_create_flags): New.
1968         (tdesc_add_field): Handle TDESC_TYPE_STRUCT.
1969         (tdesc_add_bitfield, tdesc_add_flag): New.
1970         * target-descriptions.h (tdesc_create_struct, tdesc_set_struct_size)
1971         (tdesc_create_flags, tdesc_add_bitfield, tdesc_add_flag): Declare.
1972         * xml-tdesc.c (struct tdesc_parsing_data): Rename current_union to
1973         current_type.  Add current_type_size and current_type_is_flags.
1974         (tdesc_start_union): Clear the new fields.
1975         (tdesc_start_struct, tdesc_start_flags): New.
1976         (tdesc_start_field): Handle struct fields, including bitfields.
1977         (field_attributes): Make type optional.  Add start and end.
1978         (union_children): Rename to struct_union_children.
1979         (union_attributes): Rename to struct_union_attributes.  Add optional
1980         size.
1981         (flags_attributes): New.
1982         (feature_children): Add struct and flags.
1983         * features/gdb-target.dtd: Add flags and struct to features.
1984         Make field type optional.  Add field start and end.
1985
1986 2010-03-01  H.J. Lu  <hongjiu.lu@intel.com>
1987
1988         * amd64-linux-nat.c (AMD64_LINUX_USER64_CS): New.
1989         (amd64_linux_read_description): Likewise.
1990         (_initialize_amd64_linux_nat): Set to_read_description to
1991         amd64_linux_read_description.
1992
1993         * amd64-linux-tdep.c: Include "features/i386/amd64-linux.c".
1994         (amd64_linux_register_name): Removed.
1995         (amd64_linux_register_type): Likewise.
1996         (amd64_linux_core_read_description): New.
1997         (amd64_linux_init_abi): Set target description to
1998         tdesc_amd64_linux if needed.  Support orig_rax in target
1999         description.  Don't call set_gdbarch_register_name nor
2000         set_gdbarch_register_type.  Call
2001         set_gdbarch_core_read_description.
2002         (_initialize_amd64_linux_tdep): Call
2003         initialize_tdesc_amd64_linux.
2004
2005         * amd64-linux-tdep.h (tdesc_amd64_linux): New.
2006
2007         * amd64-tdep.c:  Include "features/i386/amd64.c".
2008         (amd64_register_names): Removed.
2009         (amd64_register_name): Likewise.
2010         (amd64_register_type): Likewise.
2011         (amd64_init_abi):  Set num_core_regs and register_names.  Set
2012         target description to tdesc_amd64 if needed.  Don't call 
2013         set_gdbarch_register_name nor set_gdbarch_register_type.
2014         (_initialize_amd64_tdep): New.
2015
2016         * i386-linux-nat.c (i386_linux_read_description): New.
2017         (_initialize_i386_linux_nat): Set to_read_description to
2018         i386_linux_read_description.
2019
2020         * i386-linux-tdep.c: Include "features/i386/i386-linux.c".
2021         (i386_linux_register_name): Removed.
2022         (i386_linux_core_read_description): New.
2023         (i386_linux_read_description): Likewise.
2024         (i386_linux_init_abi): Don't call set_gdbarch_register_name.
2025         Set target description to tdesc_i386_linux if needed.  Support
2026         orig_eax.  Set register_reggroup_p.  Call
2027         set_gdbarch_core_read_description.
2028         (_initialize_i386_linux_tdep): Call initialize_tdesc_i386_linux.
2029
2030         * i386-linux-tdep.h (tdesc_i386_linux): New.
2031
2032         * i386-nto-tdep.c (i386nto_regset_id): Replace I386_NUM_FREGS
2033         with I387_NUM_REGS.
2034
2035         * i386-tdep.c: Include "features/i386/i386.c".
2036         (i386_register_names): Make it const.
2037         (i386_mmx_names): Likewise.
2038         (i386_num_register_names): Removed.
2039         (i386_register_name): Likewise.
2040         (i386_eflags_type): Likewise.
2041         (i386_mxcsr_type): Likewise.
2042         (i386_sse_type): Likewise.
2043         (i386_register_type): Likewise.
2044         (i387_ext_type): Call tdesc_find_type instead of arch_float_type.
2045         (i386_pseudo_register_name): New.
2046         (i386_pseudo_register_type): Likewise.
2047         (i386_mmx_type): Make it static.
2048         (i386_gdbarch_init): Check arch.  Replace I386_NUM_FREGS with
2049         I387_NUM_REGS.  Set num_core_regs and register_names.  Don't
2050         call set_gdbarch_register_name nor set_gdbarch_register_type.
2051         Set register_reggroup_p.  Set target description to tdesc_i386
2052         if needed.  Call set_tdesc_pseudo_register_type,
2053         set_tdesc_pseudo_register_name and tdesc_use_registers.
2054         (_initialize_i386_tdep): Call initialize_tdesc_i386.
2055         initialize_tdesc_x86_64.
2056
2057         * i386-tdep.h (gdbarch_tdep): Remove i386_eflags_type,
2058         i386_mxcsr_type and i386_sse_type.  Add num_core_regs,
2059         register_names, tdesc and register_reggroup_p.
2060         (I386_NUM_FREGS): Removed.
2061         (i386_eflags_type): Likewise.
2062         (i386_mxcsr_type): Likewise.
2063         (i386_mmx_type): Likewise.
2064         (i386_sse_type): Likewise.
2065         (i386_register_name): Likewise.
2066         (i386_regnum): Add I386_MXCSR_REGNUM.
2067         (I386_SSE_NUM_REGS): Defined with I386_MXCSR_REGNUM.
2068
2069         * i387-tdep.h (I387_NUM_REGS): New.
2070
2071         * regformats/i386/i386-linux.dat: Generated.
2072         * regformats/i386/i386.dat: Likewise.
2073         * regformats/i386/amd64-linux.dat: Likewise.
2074         * regformats/i386/amd64.dat: Likewise.
2075
2076         * regformats/reg-i386-linux.dat: Removed.
2077         * regformats/reg-i386.dat: Likewise.
2078         * regformats/reg-x86-64-linux.dat: Likewise.
2079         * regformats/reg-x86-64.dat: Likewise.
2080
2081 2010-03-01  Corinna Vinschen  <vinschen@redhat.com>
2082
2083         * remote-fileio.c (remote_fileio_func_rename): Use Cygwin 1.7
2084         cygwin_conv_path API rather than the deprecated
2085         cygwin_conv_to_full_posix_path.
2086         * windows-nat.c:
2087         (GetModuleFileNameExA): Undefine for Cygwin.
2088         (GetModuleFileNameExW): Define for Cygwin.
2089         (get_module_name): Change size of pathbuf to PATH_MAX for Cygwin.
2090         Call GetModuleFileNameExW and convert path to POSIX using
2091         cygwin_conv_path.
2092         (windows_make_so): Always define p.  Drop unused variable m.
2093         Don't use Win32 functions to check file existance, rather use
2094         access on Cygwin.  Fetch system directory using GetSystemDirectoryW.
2095         Use canonicalize_file_name to get full path.
2096         (get_image_name): Use wcstombs, rather than WideCharToMultiByte
2097         to convert Unicode pathname to multibyte on Cygwin.  Otherwise,
2098         use correct target buffer size in call to WideCharToMultiByte.
2099         (handle_load_dll): Change size of dll_buf to PATH_MAX for Cygwin.
2100         (windows_pid_to_exec_file): Change size of path to PATH_MAX for Cygwin.
2101         (windows_create_inferior): Convert all paths and arguments to wchar_t
2102         and use CreateProcessW on Cygwin.
2103         (_initialize_windows_nat): Disable DOS-style path warning on Cygwin.
2104         (bad_GetModuleFileNameExA): Undefine for Cygwin.
2105         (bad_GetModuleFileNameExW): Define for Cygwin.
2106         (_initialize_loadable): Load GetModuleFileNameExW into
2107         dyn_GetModuleFileNameExW on Cygwin.  Don't load ANSI function on Cygwin.
2108
2109 2010-02-28  Phil Muldoon  <pmuldoon@redhat.com>
2110
2111         PR python/11036
2112         * python/py-frame.c (frapy_read_var): Add block argument and logic
2113         to cope with user provided blocks.
2114
2115 2010-02-28  Jan Kratochvil  <jan.kratochvil@redhat.com>
2116
2117         * infcall.c (call_function_by_hand): Remove gdb_assert on sp and old_sp.
2118         New comment.
2119
2120 2010-02-28  Corinna Vinschen  <vinschen@redhat.com>
2121
2122         * Makefile.in (SUBDIR_MI_OBS): Move mi-common.o from here...
2123         (COMMON_OBS): ... to here since it's used unconditionally.
2124         (SUBDIR_MI_SRCS): Move mi/mi-common.c from here...
2125         (SFILES): To here.
2126
2127 2010-02-26  David Daney  <ddaney@caviumnetworks.com>
2128
2129         * mips-linux-tdep.c: Update struct sigframe comments.
2130         (SIGFRAME_CODE_OFFSET): Delete macro.
2131         (mips_linux_o32_sigframe_init): Calculate sigcontext_base using
2132         this_frame's sp.
2133         (mips_linux_n32n64_sigframe_init): Same.
2134
2135 2010-02-26  Kevin Buettner  <kevinb@redhat.com>
2136
2137         * remote-mips.c (mips_load): Don't use pseudo-register when
2138         invalidating regcache.
2139
2140 2010-02-26  Daniel Jacobowitz  <dan@codesourcery.com>
2141
2142         * arm-tdep.c (thumb_get_next_pc): Correct conditional branch opcode.
2143
2144 2010-02-26  Pedro Alves  <pedro@codesourcery.com>
2145
2146         * NEWS: Add "New targets" section, and mention ARM Symbian
2147         support.
2148
2149 2010-02-26  Ulrich Weigand  <uweigand@de.ibm.com>
2150
2151         * dwarf2loc.c (struct piece_closure): Remove ARCH member,
2152         add ADDR_SIZE member.
2153         (allocate_piece_closure): Update.
2154         (copy_pieced_value_closure): Likewise.
2155         (dwarf2_evaluate_loc_desc): Likewise.
2156         (read_pieced_value): Use DWARF address size instead of
2157         GDB's gdbarch_addr_bit as size of values on the DWARF stack.
2158
2159 2010-02-26  Phil Muldoon  <pmuldoon@redhat.com>
2160             Tom Tromey  <tromey@redhat.com>
2161
2162         * python/py-type.c (typy_lookup_typename): Add in block argument.
2163         If provided restrict lookup to specified blocks.
2164         (gdbpy_lookup_type): Likewise.
2165         (typy_lookup_type): Likewise.
2166
2167 2010-02-25  Daniel Jacobowitz  <dan@codesourcery.com>
2168  
2169         Symbian config
2170
2171         gdb/
2172         * arm-symbian-tdep.c: New.
2173         * configure.tgt (arm*-*-symbianelf*): New target.
2174         (*-*-symbianelf*): New OS.
2175         * osabi.c (gdb_osabi_names): Add Symbian.
2176         * defs.h (gdb_osabi): Add GDB_OSABI_SYMBIAN.
2177         * Makefile.in (ALL_TARGET_OBJS): Add arm-symbian-tdep.o.
2178         (ALLDEPFILES): Add arm-symbian-tdep.c.
2179
2180 2010-02-25  Daniel Jacobowitz  <dan@codesourcery.com>
2181
2182         * symfile.c (find_lowest_section): Include SEC_ALLOC sections.
2183
2184 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2185
2186         * mi/mi-main.c (mi_cmd_execute): Fix typo.
2187
2188 2010-02-24  Phil Muldoon  <pmuldoon@redhat.com>
2189             Tom Tromey  <tromey@redhat.com>
2190             Thiago Jung Bauermann  <bauerman@br.ibm.com>
2191
2192         * python/python.c (_initialize_python): Call
2193         gdbpy_initialize_symtabs, gdbpy_initialize_symbols and
2194         gdbpy_initialize_blocks.
2195         * python/python-internal.h: Declare struct symbol, block and
2196         symtab_and_line.  Declare block_object_type and
2197         symbol_object_type
2198         (gdbpy_lookup_symbol gdbpy_block_for_pc)
2199         (symtab_and_line_to_sal_object, symtab_to_symtab_object)
2200         (symbol_to_symbol_object,  block_to_block_object)
2201         (gdbpy_initialize_symtabs,gdbpy_initialize_symbols)
2202         (gdbpy_initialize_blocks ): Declare.
2203         * python/py-frame.c (frapy_block, frapy_function, frapy_find_sal)
2204         (frapy_select): Add methods.
2205         (frapy_read_var): Add symbol branch.
2206         * Makefile.in (SUBDIR_PYTHON_OBS): Add py-symbol, py-symtab,
2207         py-block.
2208         (SUBDIR_PYTHON_SRCS): Likewise.
2209         (py-symbol.o): New rule.
2210         (py-symtab.o): Likewise.
2211         (py-block.o): Likewise.
2212         * python/py-symbol.c: New file.
2213         * python/py-symtab.c: Likewise.
2214         * python/py-block.c: Likewise.
2215
2216 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2217
2218         PR gdb/11321
2219
2220         * inferior.h (prepare_for_detach): Declare.
2221         (struct inferior) <detaching>: New field.
2222         * infrun.c (prepare_for_detach): New.
2223         (handle_inferior_event) <random signal>: Don't stop if detaching.
2224         * target.c (target_detach): Call prepare_for_detach.
2225
2226 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2227
2228         Per-process displaced stepping queue.
2229
2230         * infrun.c (displaced_step_ptid, displaced_step_request_queue)
2231         (displaced_step_gdbarch, displaced_step_closure,
2232         (displaced_step_original, displaced_step_copy): Move globals to
2233         this...
2234         (struct displaced_step_inferior_state): ... new structure.
2235         (displaced_step_inferior_states): New global.
2236         (get_displaced_stepping_state, add_displaced_stepping_state)
2237         (remove_displaced_stepping_state, infrun_inferior_exit): New
2238         functions.
2239         (displaced_step_clear): Add displaced_step_inferior_state
2240         parameter, and adjust to handle it.
2241         (displaced_step_clear_cleanup): Parameter is now a
2242         displaced_step_inferior_state.  Adjust.
2243         (displaced_step_prepare): Adjust.
2244         (displaced_step_fixup, displaced_step_fixup)
2245         (infrun_thread_ptid_changed, resume): Adjust.
2246         (init_wait_for_inferior): Don't call displaced_step_clear.
2247         (infrun_thread_stop_requested): Rewrite.
2248         (_initialize_infrun): Install infrun_inferior_exit as
2249         inferior_exit observer.
2250
2251 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2252
2253         * inferior.h (ptid_match): Declare.
2254         * infrun.c (ptid_match): New.
2255         * remote.c (queued_stop_reply): Rewrite and use ptid_match.
2256         (handle_notification): Add debug output.
2257         * linux-nat.c (ptid_match): Delete.
2258
2259 2010-02-24  David S. Miller  <davem@davemloft.net>
2260
2261         * gdb_ptrace.h (PT_SYSCALL): If PTRACE_SYSCALL is available, use it.
2262         * syscalls/sparc-linux.xml: New.
2263         * syscalls/sparc64-linux.xml: New.
2264         * Makefile.in (XML_SYSCALL_FILES): Add new syscall XML files.
2265         * sparc-linux-tdep.c (XML_SYSCALL_FILENAME_SPARC32): Define.
2266         (sparc32_linux_get_syscall_number): New function.
2267         (sparc32_linux_init_abi): Set syscall XML file name and hook up
2268         syscall number fetcher.
2269         * sparc64-linux-tdep.c (XML_SYSCALL_FILENAME_SPARC64): Define.
2270         (sparc64_linux_get_syscall_number): New function.
2271         (sparc64_linux_init_abi): Set syscall XML file name and hook up
2272         syscall number fetcher.
2273
2274 2010-02-24  Vladimir Prus  <vladimir@codesourcery.com>
2275
2276         Multiexec MI
2277
2278         * breakpoint.c (clear_syscall_counts): Take struct inferior*.
2279         * inferior.c (add_inferior_silent): Notify inferior_added
2280         observer.
2281         (delete_inferior_1): Notify inferior_removed observer.
2282         (exit_inferior_1): Pass inferior, not pid, to observer.
2283         (inferior_appeared): Likewise.
2284         (add_inferior_with_spaces): New.
2285         (add_inferior_command): Use the above.
2286         * inferior.h (delete_inferior_1, add_inferior_with_spaces):
2287         Declare.
2288
2289         * inflow.c (inflow_inferior_exit): Likewise.
2290         * jit.c (jit_inferior_exit_hook): Likewise.
2291
2292         * mi/mi-cmds.c (mi_cmds): Register add-inferior and
2293         remove-inferior.
2294         * mi/mi-cmds.h (mi_cmd_add_inferior, mi_cmd_remove_inferior): New.
2295         * mi/mi-interp.c (mi_inferior_added, mi_inferior_removed): New.
2296         (report_initial_inferior): New.
2297         (mi_inferior_removed): Register the above. Make sure
2298         inferior_added observer is called on the first inferior.
2299         (mi_new_thread, mi_thread_exit): Thread group is now identified by
2300         inferior number, not pid.
2301         (mi_solib_loaded, mi_solib_unloaded): Report which inferiors are
2302         affected.
2303         * mi/mi-main.c (current_context): New.
2304         (proceed_thread_callback): Use typed closure.
2305         Proceed everything if pid is 0. Most implementation split into
2306         (proceed_thread): ... this.
2307         (run_one_inferior): New.
2308         (mi_cmd_exec_continue, mi_cmd_exec_interrupt, mi_cmd_exec_run):
2309         Adjust for multiexec behaviour.
2310         (mi_cmd_add_inferior, mi_cmd_remove_inferior): New.
2311         (mi_cmd_execute): Handle the 'thread-group' option here.
2312         Do some extra checks.
2313         * mi-parse.c (mi_parse): Handle the --all and --thread-group
2314         options.
2315         * mi-parse.h (struct mi_parse): New fields all and thread_group.
2316
2317 2010-02-24  Vladimir Prus  <vladimir@codesourcery.com>
2318
2319         Make -exec-run a proper MI commands.
2320
2321         * mi/mi-cmds.h (mi_cmd_exec_run): Declare.
2322         * mi/mi-cmds.c (mi_cmds): Adjust.
2323         * mi/mi-main.c (mi_cmd_exec_run): New.
2324
2325 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2326             Stan Shebs  <stan@codesourcery.com>
2327
2328         * tracepoint.h (set_traceframe_number)
2329         (cleanup_restore_current_traceframe): Declare.
2330         * tracepoint.c (set_traceframe_number): New.
2331         (struct current_traceframe_cleanup): New.
2332         (do_restore_current_traceframe_cleanup)
2333         (restore_current_traceframe_cleanup_dtor)
2334         (make_cleanup_restore_current_traceframe): New.
2335         * infrun.c: Include tracepoint.h.
2336         (fetch_inferior_event): Switch out and in of tfind mode.
2337
2338 2010-02-24  Pedro Alves  <pedro@codesourcery.com>
2339
2340         * breakpoint.c (breakpoint_init_inferior): Also delete
2341         bp_shlib_event breakpoints.
2342         * solib-frv.c (enable_break): Remove call to
2343         remove_solib_event_breakpoints.
2344         * solib-svr4.c (enable_break): Ditto.
2345         * solib-darwin.c (darwin_solib_create_inferior_hook): Ditto.
2346         * solib-pa64.c (pa64_solib_create_inferior_hook): Ditto.
2347         * solib-som.c (som_solib_create_inferior_hook): Ditto.
2348         * solib-spu.c (spu_enable_break): Ditto.
2349
2350 2010-02-23  Harald Koenig  <H.Koenig@science-computing.de>
2351
2352         * c-exp.y (token_and_value): s/union YYSTYPE/YYSTYPE.
2353
2354 2010-02-23  Harald Koenig  <H.Koenig@science-computing.de>
2355
2356         * varobj.c (varobj_update): Avoid non-constants in initializers.
2357
2358 2010-02-23  Tom Tromey  <tromey@redhat.com>
2359
2360         * dwarf2loc.c (read_pieced_value) <DWARF_VALUE_STACK>: Correctly
2361         handle big-endian values.
2362         (dwarf2_evaluate_loc_desc) <DWARF_VALUE_STACK>: Likewise.
2363
2364 2010-02-22  Pedro Alves  <pedro@codesourcery.com>
2365
2366         PR9605
2367
2368         gdb/
2369         * breakpoint.c (insert_bp_location): If inserting the read
2370         watchpoint failed, fallback to an access watchpoint.
2371         (bpstat_check_watchpoint): Stop for read watchpoint triggers even
2372         if the value changed, if not watching the same memory for writes.
2373         (watchpoint_locations_match): Add comment.
2374         (update_global_location_list): Copy the location's watchpoint type.
2375         * i386-nat.c (i386_length_and_rw_bits): It's an internal error to
2376         handle read watchpoints here.
2377         (i386_insert_watchpoint): Read watchpoints aren't supported.
2378         * remote.c (remote_insert_watchpoint): Return 1 for unsupported
2379         packets.
2380         * target.h (target_insert_watchpoint): Update description.
2381
2382 2010-02-19  Tom Tromey  <tromey@redhat.com>
2383
2384         * p-typeprint.c (pascal_type_print_varspec_prefix): Update.
2385         * m2-typeprint.c (m2_print_type): Update.
2386         * gdbtypes.c (recursive_dump_type): Update.
2387         (copy_type_recursive): Update.
2388         * c-typeprint.c (c_type_print_varspec_prefix): Update.
2389         (c_type_print_base): Update.
2390         * gdbtypes.h (TYPE_CODE_TEMPLATE, TYPE_CODE_TEMPLATE_ARG):
2391         Remove.
2392         (struct cplus_struct_type) <ntemplate_args>: Remove.
2393         <struct template_arg>: Remove.
2394         <is_dynamic>: Move earlier.
2395         (TYPE_TEMPLATE_ARGS): Remove.
2396         (TYPE_NTEMPLATE_ARGS): Remove.
2397         (TYPE_TEMPLATE_ARG): Remove.
2398
2399 2010-02-19  Tom Tromey  <tromey@redhat.com>
2400
2401         PR c++/8693, PR c++/9496:
2402         * cp-namespace.c (cp_lookup_nested_type): Handle TYPE_CODE_UNION.
2403         * c-exp.y (lex_one_token): Rename from yylex.  Don't call
2404         write_dollar_variable.  Don't try to classify NAME tokens.
2405         (token_and_value): New type.
2406         (token_fifo, popping, name_obstack): New globals.
2407         (classify_name): New function.
2408         (classify_inner_name): Likewise.
2409         (yylex): Likewise.
2410         (VARIABLE): Now has type sval.
2411         (exp : VARIABLE): Call write_dollar_variable.
2412         (qualified_name): Use TYPENAME, not typebase.  Add production for
2413         multiple "::" instances.
2414         (variable): Use name_not_typename.
2415         (qualified_type): Remove.
2416         (typebase): Update.
2417
2418 2010-02-19  Jan Kratochvil  <jan.kratochvil@redhat.com>
2419
2420         * symfile.c (addr_info_make_relative): Extend comment.  Move SECT to
2421         a more inner block.  Initialize ADDR by LOWER_OFFSET only if it was
2422         found by bfd_get_section_by_name.
2423         * symfile.h (struct section_addr_info) <sectindex>: New comment.
2424
2425 2010-02-19  Joel Brobecker  <brobecker@adacore.com>
2426
2427         * NEWS: Add new "[...] since 7.1" section.  Rename the "[...] since
2428         7.0 section" into "Changes in 7.1".
2429
2430 2010-02-19  Joel Brobecker  <brobecker@adacore.com>
2431
2432         GDB 7.1 branch created (branch timestamp: 2010-02-18 20:00 UTC)
2433         * version.in: Bump version to 7.1.50.20100219-cvs.
2434
2435 2010-02-18  Harald Koenig  <H.Koenig@science-computing.de>
2436
2437         * mi/mi-main.c (mi_cmd_exec_jump): Drop unneeded `return'.
2438         * symfile.c (symfile_map_offsets_to_segments): Fix assertion.
2439
2440 2010-02-17  Tom Tromey  <tromey@redhat.com>
2441
2442         * NEWS: Add Python API Improvements section.
2443
2444 2010-02-18  Daniel Jacobowitz  <dan@codesourcery.com>
2445
2446         * NEWS: Correct typo.
2447
2448 2010-02-17  Tom Tromey  <tromey@redhat.com>
2449
2450         * objfiles.c (gdb_bfd_ref): Handle abfd==NULL.
2451
2452 2010-02-17  Jan Kratochvil  <jan.kratochvil@redhat.com>
2453
2454         * symfile.c (build_section_addr_info_from_objfile): Include sections
2455         only if they are SEC_ALLOC or SEC_LOAD.
2456
2457 2010-02-17  H.J. Lu  <hongjiu.lu@intel.com>
2458
2459         PR shlibs/11293
2460         * solib-svr4.c (enable_break): Check size of CORE_ADDR instead
2461         of ULONGEST for address size.
2462
2463 2010-02-17  Tom Tromey  <tromey@redhat.com>
2464
2465         * NEWS: Add C++ improvements section.
2466
2467 2010-02-17  Ulrich Weigand  <uweigand@de.ibm.com>
2468
2469         * python/python-internal.h [!WITH_THREAD] (PyGILState_Release,
2470         PyThreadState_Swap): Avoid "statement with no effect" warning.
2471
2472 2010-02-17  Jan Kratochvil  <jan.kratochvil@redhat.com>
2473
2474         * solib-svr4.c (enable_break <target_auxv_search>): New variable
2475         addr_bit.  Adjust LOAD_ADDR sign for cross-arch inferiors.
2476
2477 2010-02-17  Tristan Gingold  <gingold@adacore.com>
2478             Petr Hluzín <petr.hluzin@gmail.com>
2479
2480         * avr-tdep.c (avr_scan_prologue): Convert an if statement to a
2481         gdb_assert.  Fix info->size for SIG prologue.
2482
2483 2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
2484
2485         * infcmd.c (show_inferior_tty_command): Check for NULL.
2486         Correct output message.
2487
2488 2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
2489
2490         * linespec.c (decode_line_1): Handle FILE:FUNCTION even if
2491         FUNCTION contains parentheses.  Improve removal of a trailing
2492         single quote.
2493
2494 2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
2495
2496         * gcore.c (do_bfd_delete_cleanup): New function.
2497         (gcore_command): Use it.  Discard the cleanup after success.
2498         (gcore_copy_callback): Delete dead code.
2499
2500 2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
2501
2502         * symfile.c (addr_info_make_relative): Always use
2503         find_lowest_section.
2504
2505 2010-02-16  Sami Wagiaalla <swagiaal@redhat.com>
2506
2507         * NEWS: Added entry for namespace fixes.
2508
2509 2010-02-15  Tom Tromey  <tromey@redhat.com>
2510
2511         * dwarf2read.c (guess_structure_name): Allocate name on the
2512         objfile obstack.
2513
2514 2010-02-15  Tom Tromey  <tromey@redhat.com>
2515
2516         * c-typeprint.c (c_type_print_base): Reverse order of test.
2517
2518 2010-02-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
2519
2520         * solib-svr4.c (LM_ADDR_CHECK): New variable minpagesize.  Optionally
2521         initialize it from ELF BFD.  Extend the prelink condition by it.
2522
2523 2010-02-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
2524
2525         * defs.h (parse_pid_to_attach): New.
2526         * utils.c (parse_pid_to_attach): New.
2527         * darwin-nat.c (darwin_attach): Replace ARGS parsing by parse_pid.
2528         * gnu-nat.c (gnu_attach): Likewise.
2529         * nto-procfs.c (procfs_attach): Likewise.
2530         * procfs.c (procfs_attach): Likewise.
2531         * windows-nat.c (windows_attach): Likewise.
2532         * inf-ptrace.c (inf_ptrace_attach): Likewise.  Remove variable dummy.
2533         * inf-ttrace.c (inf_ttrace_attach): Likewise.
2534         * remote.c (extended_remote_attach_1): Likewise.  New comment on getpid
2535         check.
2536
2537 2010-02-14  Masaki Muranaka  <monaka@monami-software.com>
2538
2539         * MAINTAINERS: Add myself for write after approval privileges.
2540
2541 2010-02-13  Jan Kratochvil  <jan.kratochvil@redhat.com>
2542
2543         * solib-svr4.c: (LM_ADDR_CHECK): Move variable align to a more inner
2544         block.
2545
2546 2010-02-13  Jan Kratochvil  <jan.kratochvil@redhat.com>
2547
2548         * solib-svr4.c: (LM_ADDR_CHECK): Print successful prelink adjustment
2549         only if INFO_VERBOSE.
2550
2551 2010-02-12  Tomas Holmberg <th@virtutech.com>
2552
2553         * mi/mi-main.c: Added the --reverse flag to the following MI
2554         commands: exec-continue, exec-finish, exec-next, exec-step,
2555         exec-next-instruction, exec-step-instruction. This is to
2556         support reverse execution over the MI interface to gdb.
2557
2558 2010-02-12  Pedro Alves  <pedro@codesourcery.com>
2559
2560         * tracepoint.c (_initialize_tracepoint): Specify that the address
2561         range of `tfind outsize' is exclusive, and that the address range
2562         of `tfind range' is inclusive, in the commands' help strings.
2563
2564 2010-02-12  Joel Brobecker  <brobecker@adacore.com>
2565
2566         Spurious "dll not found" error messages on x64-windows.
2567         * windows-nat.c: Add include of complaints.h.
2568         (handle_unload_dll): Change dll-not-found error into a complaint.
2569
2570 2010-02-12  Pedro Alves  <pedro@codesourcery.com>
2571
2572         * breakpoint.c (allocate_bp_location): Use bp_loc_other for
2573         bp_tracepoint and bp_fast_tracepoint, not
2574         bp_loc_software_breakpoint.
2575         (update_global_location_list): Tracepoints are never duplicates of
2576         anything.
2577
2578 2010-02-12  Pedro Alves  <pedro@codesourcery.com>
2579
2580         * breakpoint.c (break_command_really): Change return type to int.
2581         Return false if no breakpoint was created, true otherwise.
2582         (trace_command): Don't set the tracepoint count if no tracepoint
2583         was created.
2584         (ftrace_command): Ditto.
2585         (create_tracepoint_from_upload): Bail out if the tracepoint wasn't
2586         created in the breakpoints table.
2587
2588 2010-02-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
2589             Ulrich Weigand  <uweigand@de.ibm.com>
2590
2591         * solib-svr4.c (LM_ADDR_CHECK): New comment on PPC-aware condition.
2592
2593 2010-02-11  Pedro Alves  <pedro@codesourcery.com>
2594
2595         * ax-gdb.c (gen_exp_binop_rest) [BINOP_SUBSCRIPT]: Error out if
2596         the offset value isn't of integral type.
2597
2598 2010-02-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
2599
2600         * breakpoint.c (delete_breakpoint) <bpt->related_breakpoint != NULL>:
2601         New.
2602
2603 2010-02-11  Pedro Alves  <pedro@codesourcery.com>
2604
2605         * ax-gdb.c (gen_exp_binop_rest) [BINOP_SUBSCRIPT]: Error out on
2606         non-subscriptable types.
2607         * valarith.c (binop_types_user_defined_p): New, abstracted out
2608         from ...
2609         (binop_user_defined_p): ... this.
2610         * value.h (binop_types_user_defined_p): Declare.
2611
2612 2010-02-11  Pedro Alves  <pedro@codesourcery.com>
2613
2614         * tracepoint.c (tfile_open): Remove spurious discard_cleanups.
2615         Merge uploaded TSVs before merging uploaded tracepoints.
2616
2617 2010-02-11  Pedro Alves  <pedro@codesourcery.com>
2618
2619         * ax-gdb.c (gen_deref): Don't allow dereferencing void pointers.
2620
2621 2010-02-11  Vladimir Prus  <vladimir@codesourcery.com>
2622
2623         * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals): Add extra
2624         whitespace character after a dot in comment.
2625         (mi_cmd_stack_list_arguments, mi_cmd_stack_list_variables):
2626         Likewise.
2627         (list_args_or_locals): For the 'all' (that is
2628         -stack-list-variables) case, always output list of tuples.
2629         Output 'arg' field if variable is argument.
2630
2631 2010-02-10  Tom Tromey  <tromey@redhat.com>
2632
2633         * parser-defs.h (parser_debug): Declare.
2634         * parse.c (_initialize_parse): Install "debug parser" set/show
2635         command.
2636         (parser_debug): New global.
2637         (show_parserdebug): New function.
2638         * c-exp.y (c_parse): Set yydebug.
2639
2640 2010-02-10  H.J. Lu  <hongjiu.lu@intel.com>
2641
2642         * target-descriptions.c (tdesc_type): Add TDESC_TYPE_I387_EXT,
2643         TDESC_TYPE_I386_EFLAGS and TDESC_TYPE_I386_MXCSR.
2644         (tdesc_predefined_types): Add i387_ext, i386_eflags and
2645         i386_mxcsr.
2646         (tdesc_find_type): New.
2647         (tdesc_gdb_type): Use tdesc_find_type.  Handle TDESC_TYPE_I387_EXT,
2648         TDESC_TYPE_I386_EFLAGS and TDESC_TYPE_I386_MXCSR.
2649
2650         * target-descriptions.h (tdesc_find_type): New.
2651
2652 2010-02-10  Michael Snyder  <msnyder@vmware.com>
2653
2654         * gdb-gdb.py: Comment fix.
2655
2656 2010-02-09  Tristan Gingold  <gingold@adacore.com>
2657
2658         * machoread.c (macho_symfile_relocate): New function.
2659         (macho_sym_fns): Use macho_symfile_relocate instead of
2660         default_symfile_relocate.
2661         (macho_oso_data): New type.
2662         (current_oso): New variable.
2663         (macho_add_oso_symfile): Do not compute section_addr_info, but
2664         instead set vma of sections.
2665         Do not set SYMFILE_VERBOSE to call symbol_file_add_from_bfd.
2666         Set and clear current_oso.
2667
2668 2010-02-09  Joel Brobecker  <brobecker@adacore.com>
2669
2670         Wrong type description for tagged type parameter.
2671         * ada-lang.c (ada_evaluate_subexp) [OP_VAR_VALUE]: When noside is
2672         EVAL_AVOID_SIDE_EFFECTS, also handle the case when type is a
2673         reference to a tagged type.
2674
2675 2010-02-09  Tristan Gingold  <gingold@adacore.com>
2676
2677         * objfiles.c (objfile_separate_debug_iterate): Do not iterate on
2678         brothers of the parent.
2679
2680 2010-02-08  Tom Tromey  <tromey@redhat.com>
2681
2682         PR c++/8017:
2683         * value.h: Update.
2684         * valops.c (search_struct_field): Make 'name' const.
2685         (search_struct_method): Likewise.
2686         (find_method_list): Make 'method' const.
2687         (value_struct_elt): Make 'name' and 'err' const.
2688         (value_find_oload_method_list): Make 'method' const.
2689         (find_overload_match): Make 'name' const.
2690         * eval.c (evaluate_subexp_standard): New locals function,
2691         function_name.
2692         <OP_FUNCALL>: Handle OP_SCOPE specially.
2693
2694 2010-02-08  Ulrich Weigand  <uweigand@de.ibm.com>
2695
2696         * infrun.c (handle_inferior_event): Do not look up regcache
2697         for exited processes.
2698
2699 Mon Feb  8 13:17:10 2010  Chris Moller  <moller@mollerware.com>
2700
2701         PR gdb/10728
2702         * valarith.c (value_ptrdiff): Added a test for a zero type length,
2703         warn if found, and assume length = 1. 
2704
2705 2010-02-08  Chris Moller  <cmoller@redhat.com>
2706
2707         PR gdb/9067
2708         * cp-valprint.c (cp_print_value_fields) Fix use of obstacks.
2709         cp_print_static_field)  Fix use of obstacks.
2710         
2711 2010-02-08  Pedro Alves  <pedro@codesourcery.com>
2712
2713         * linux-nat.c (linux_nat_resume): In non-stop, also only tag
2714         resumed LWPs as resumed.
2715         (linux_nat_wait_1): If there's no resumed LWP in the set of LWPs
2716         we're waiting for, bail out with TARGET_WAITKIND_IGNORE, instead
2717         of throwing an internal error.  If an LWP of a process we're not
2718         waiting for reports a signal, don't force collecting a SIGSTOP,
2719         and if it was breakpoint hit in non-stop mode, cancel it.  Don't
2720         go through all LWPs cancelling breakpoints in non-stop mode.
2721         (resume_stopped_resumed_lwps): New.
2722         (linux_nat_wait): Use it.
2723
2724 2010-02-07  H.J. Lu  <hongjiu.lu@intel.com>
2725
2726         * features/Makefile (WHICH): Add i386/i386, i386/i386-linux,
2727         i386/amd64 and i386/amd64-linux.
2728         (i386/i386-expedite): New.
2729         (i386/i386-linux-expedite): Likewise.
2730         (i386/amd64-expedite):Likewise.
2731         (i386/amd64-linux-expedite): Likewise.
2732         ($(outdir)/i386/i386-linux.dat): Likewise.
2733         ($(outdir)/i386/amd64.dat): Likewise.
2734         ($(outdir)/i386/amd64-linux.dat): Likewise.
2735
2736         * features/i386/32bit-core.xml: New.
2737         * features/i386/32bit-linux.xml: Likewise.
2738         * features/i386/32bit-sse.xml: Likewise.
2739         * features/i386/64bit-core.xml: Likewise.
2740         * features/i386/64bit-linux.xml: Likewise.
2741         * features/i386/64bit-sse.xml: Likewise.
2742         * features/i386/i386-linux.xml: Likewise.
2743         * features/i386/i386.xml: Likewise.
2744         * features/i386/amd64-linux.xml: Likewise.
2745         * features/i386/amd64.xml: Likewise.
2746         * features/i386/i386-linux.c: Likewise.
2747         * features/i386/i386.c: Likewise.
2748         * features/i386/amd64-linux.c: Likewise.
2749         * features/i386/amd64.c: Likewise.
2750
2751 2010-02-05  Sami Wagiaalla  <swagiaal@redhat.com>
2752
2753         PR c++/7935:
2754         * cp-support.h: Added char* alias element to using_direct data
2755         struct.
2756         (cp_add_using): Added char* alias argument.
2757         (cp_add_using_directive): Ditto.
2758         * cp-namespace.c: Updated with the above changes.
2759         (cp_lookup_symbol_imports): Check for aliases.
2760         * dwarf2read.c (read_import_statement): Figure out local alias
2761         for the import and pass it on to cp_add_using.
2762         (read_namespace): Pass alias argument to cp_add_using.
2763
2764 2010-02-05  Hui Zhu  <teawater@gmail.com>
2765
2766         * defs.h (gdb_bfd_errmsg): New extern.
2767         * exec.c (exec_file_attach): Change bfd_errmsg to
2768         gdb_bfd_errmsg.
2769         * utils.c (AMBIGUOUS_MESS1): New macro.
2770         (AMBIGUOUS_MESS2): New macro.
2771         (gdb_bfd_errmsg): New function.
2772
2773 2010-02-04  Doug Evans  <dje@google.com>
2774
2775         * solib-svr4.c (enable_break): Add comment.
2776
2777 2010-02-04  Anthony Green  <green@moxielogic.com>
2778
2779         * moxie-tdep.c (moxie_analyze_prologue): Fail protocol analysis
2780         gracefully.
2781
2782 2010-02-04  Tom Tromey  <tromey@redhat.com>
2783
2784         * valops.c (search_struct_field): Account for
2785         value_embedded_offset.  Fix check for virtual base past the end of
2786         the object.  Use value_copy when making a slice of the value.
2787
2788 2010-02-04  H.J. Lu  <hongjiu.lu@intel.com>
2789
2790         PR tui/9622
2791         * tui/tui-interp.c (tui_init): Call tui_initialize_readline
2792         only if gdb_stdout is a tty.
2793
2794 2010-02-04  H.J. Lu  <hongjiu.lu@intel.com>
2795
2796         * target-descriptions.c: Include "osabi.h".
2797         (maint_print_c_tdesc_cmd): Generate set_tdesc_osabi for valid
2798         OSABI.
2799
2800 2010-02-04  Tristan Gingold  <gingold@adacore.com>
2801
2802         * machoread.c (macho_add_oso): Renamed to macho_register_oso.
2803         (macho_symtab_read): Adjust calls to macho_add_oso.
2804         (macho_oso_symfile): Renamed to macho_symfile_read_all_oso.
2805         (macho_symfile_read): Adjust call to macho_oso_symfile.
2806         (macho_new_init): Move this function after declarations.
2807         (macho_symfile_init): Ditto.
2808         * darwin-nat-info.c (darwin_lib_gdb_ports): Remove.
2809         * darwin-nat.c (darwin_lookup_task): Remove unused prototype.
2810
2811 2010-02-04  Vladimir Prus  <vladimir@codesourcery.com>
2812
2813         Include MI command in remotelog.
2814
2815         * mi/mi-main.c (mi_execute_command): Call target_log_command.
2816
2817 2010-02-03  H.J. Lu  <hongjiu.lu@intel.com>
2818
2819         * remote.c (remote_state): Remove gdbarch.
2820         (init_remote_state): Don't set gdbarch.
2821         (remote_query_supported): Pass target_gdbarch instead of
2822         rs->gdbarch to gdbarch_qsupported.
2823
2824 2010-02-03  H.J. Lu  <hongjiu.lu@intel.com>
2825
2826         * gdbarch.sh: Add qsupported.
2827
2828         * gdbarch.c: Regenerated.
2829         * gdbarch.h: Likewise.
2830
2831         * remote.c (remote_state): Add gdbarch.
2832         (init_remote_state): Set gdbarch.
2833         (remote_query_supported): Support gdbarch_qsupported.
2834
2835 2010-02-03  Daniel Jacobowitz  <dan@codesourcery.com>
2836
2837         * amd64fbsd-nat.c (amd64fbsd_supply_pcb): Also check for
2838         __FreeBSD_kernel_version.
2839
2840 2010-02-03  Tristan Gingold  <gingold@adacore.com>
2841
2842         * symfile.h (struct sym_fns): Add sym_relocate field.
2843         (default_symfile_relocate): New prototype.
2844         (symfile_relocate_debug_section): First argument is now an objfile.
2845         * symfile.c (default_symfile_relocate): Rename from
2846         symfile_relocate_debug_section, first argument is now an objfile.
2847         (symfile_relocate_debug_section): New function.
2848         * coffread.c (coff_sym_fns): Set sym_relocate field.
2849         * somread.c (som_sym_fns): Ditto.
2850         * mipsread.c (ecoff_sym_fns): Ditto.
2851         * machoread.c (macho_sym_fns): Ditto.
2852         * elfread.c (elf_sym_fns): Ditto.
2853         * dwarf2read.c (dwarf2_read_section): Ditto.
2854         * xcoffread.c (xcoff_sym_fns): Ditto.
2855         * dbxread.c (aout_sym_fns): Ditto.
2856         (dbx_psymtab_to_symtab): Adjust call to symfile_relocate_debug_section.
2857         (elfstab_build_psymtabs): Ditto.
2858
2859 2010-02-03  H.J. Lu  <hongjiu.lu@intel.com>
2860
2861         * defs.h (MAX_REGISTER_SIZE): Increase to 32.
2862
2863 2010-02-02  Tom Tromey  <tromey@redhat.com>
2864
2865         * valops.c (value_cast_structs): Try downcasting using the RTTI
2866         type.
2867
2868 2010-02-02  Tom Tromey  <tromey@redhat.com>
2869
2870         * gnu-v2-abi.c: Don't include gnu-v2-abi.h.
2871         (gnuv2_baseclass_offset): Now static.
2872         * Makefile.in (HFILES_NO_SRCDIR): Remove gnu-v2-abi.h.
2873         * gnu-v2-abi.h: Remove.
2874
2875 2010-02-02  Tom Tromey  <tromey@redhat.com>
2876
2877         * m2-typeprint.c (m2_record_fields): Don't use
2878         TYPE_DECLARED_TYPE.
2879         * gdbtypes.h (TYPE_DECLARED_CLASS): New macro.
2880         (struct main_type) <flag_declared_class>: New field.
2881         (struct cplus_struct_type) <declared_type>: Remove.
2882         <ntemplate_args>: Move earlier.
2883         (DECLARED_TYPE_CLASS, DECLARED_TYPE_UNION, DECLARED_TYPE_STRUCT)
2884         (DECLARED_TYPE_TEMPLATE): Remove.
2885         (TYPE_DECLARED_TYPE): Remove.
2886         * gdbtypes.c (lookup_union): Don't use TYPE_DECLARED_TYPE.
2887         * dwarf2read.c (read_structure_type): Set TYPE_DECLARED_CLASS.
2888         * c-typeprint.c (c_type_print_base): Use TYPE_DECLARED_CLASS, not
2889         TYPE_DECLARED_TYPE.
2890
2891 2010-02-02  Tom Tromey  <tromey@redhat.com>
2892
2893         PR c++/11226, PR c++/9629, PR c++/9688, PR c++/8890:
2894         * valops.c (search_struct_field): Compute nbases after calling
2895         CHECK_TYPEDEF.
2896         (check_field): Call CHECK_TYPEDEF.
2897         * cp-valprint.c (cp_print_value): Pass correct address to
2898         baseclass_offset.  Fix check for virtual base past the end of the
2899         object.  Don't offset address passed to cp_print_value_fields or
2900         apply_val_pretty_printer.
2901         (cp_print_value_fields): Fix call to val_print.
2902         (cp_print_value_fields_rtti): New function.
2903         * c-valprint.c (c_val_print): Use cp_print_value_fields_rtti.
2904         * p-valprint.c (pascal_object_print_value_fields): Fix call to
2905         val_print.
2906         * python/py-prettyprint.c (apply_val_pretty_printer): Add embedded
2907         offset to address.
2908         * language.h (struct language_defn) <la_val_print>: Document.
2909         * c-lang.h (cp_print_value_fields_rtti): Declare.
2910
2911 2010-02-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
2912
2913         PR libc/11214:
2914         * linux-low.c (linux_tracefork_child) [!(__UCLIBC__ && HAS_NOMMU)]: New.
2915         (linux_test_for_tracefork): Move `stack' into [__UCLIBC__ && HAS_NOMMU].
2916         (linux_test_for_tracefork) [!(__UCLIBC__ && HAS_NOMMU)]: New.
2917
2918 2010-02-01  Michael Matz  <matz@suse.de>
2919             Daniel Jacobowitz  <dan@codesourcery.com>
2920
2921         * i386-tdep.c (i386_frame_cache): Assume valid anonymous
2922         functions use a frame pointer.
2923
2924 2010-02-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
2925
2926         * solib-svr4.c (scan_dyntag): New variable dyn_addr.  Replace gdb_assert
2927         by a conditional setting DYN_ADDR.  Use DYN_ADDR.
2928         * config/djgpp/fnchange.lst: Add translations for
2929         symbol-without-target_section.exp and symbol-without-target_section.c.
2930
2931 2010-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
2932
2933         * gdbarch.sh: Set LANG and LC_ALL to C, not c.
2934         (remote_breakpoint_for_pc): Correct invalid_p check.
2935         * gdbarch.c: Regenerated.
2936
2937 2010-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
2938
2939         * arm-tdep.c (arm_find_mapping_symbol): New function, from
2940         arm_pc_is_thumb.
2941         (arm_pc_is_thumb): Use arm_find_mapping_symbol.
2942         (extend_buffer_earlier): New function.
2943         (MAX_IT_BLOCK_PREFIX, IT_SCAN_THRESHOLD): New constants.
2944         (arm_adjust_breakpoint_address): New function.
2945         (arm_gdbarch_init): Register arm_adjust_breakpoint_address.
2946
2947 2010-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
2948
2949         * arm-linux-tdep.c (arm_linux_thumb2_be_breakpoint)
2950         (arm_linux_thumb2_le_breakpoint): New constants.
2951         (arm_linux_init_abi): Set thumb2_breakpoint and
2952         thumb2_breakpoint_size.
2953         * arm-tdep.c (thumb_insn_size, thumb_advance_itstate): New functions.
2954         (thumb_get_next_pc): Add a comment.  Rename IT to ITSTATE.
2955         Implement support for single stepping through IT blocks if
2956         a 32-bit Thumb breakpoint instruction is available.
2957         (arm_breakpoint_from_pc): If a 32-bit Thumb breakpoint instruction
2958         is available, use it when needed.
2959         (arm_remote_breakpoint_from_pc): New function.
2960         (arm_gdbarch_init): Register arm_remote_breakpoint_from_pc.
2961         * arm-tdep.h (struct gdbarch_tdep): Correct thumb_breakpoint
2962         comment.  Add thumb2_breakpoint and thumb2_breakpoint_size.
2963
2964 2010-02-01  Daniel Jacobowitz  <dan@codesourcery.com>
2965
2966         * arch-utils.c (default_remote_breakpoint_from_pc): New function.
2967         * arch-utils.h (default_remote_breakpoint_from_pc): Declare.
2968         * gdbarch.c, gdbarch.h: Regenerated.
2969         * gdbarch.sh (remote_breakpoint_from_pc): New architecture method.
2970         * remote.c (remote_insert_breakpoint, remote_insert_hw_breakpoint): Use
2971         gdbarch_remote_breakpoint_from_pc.
2972
2973 2010-01-29  Daniel Jacobowitz  <dan@codesourcery.com>
2974
2975         * infrun.c (prepare_to_proceed): Handle other signals which might
2976         match a breakpoint.
2977         (handle_inferior_event): Move the check for unusual breakpoint
2978         signals earlier.
2979
2980 2010-01-29  Paul Hilfinger  <hilfinger@adacore.com>
2981
2982         amd64 - function returning record with field straddling 2 registers.
2983         * amd64-tdep.c (amd_classify_aggregate): Handle the case of
2984         a record of length <= 16 in which a field straddles the two
2985         eightbytes.
2986
2987 2010-01-29  Joel Brobecker  <brobecker@adacore.com>
2988
2989         Implement return values on amd64-windows.
2990         * amd64-windows-tdep.c: #include gdbcore.h and regcache.h.
2991         (amd64_windows_return_value): New function.
2992         (amd64_windows_init_abi): Call set_gdbarch_return_value with
2993         amd64_windows_return_value.
2994
2995 2010-01-29  Joel Brobecker  <brobecker@adacore.com>
2996
2997         amd64-windows: 32 bytes allocated on stack by caller for integer
2998         parameter registers.
2999         * i386-tdep.h (struct gdbarch_tdep): Add new field
3000         integer_param_regs_saved_in_caller_frame.
3001         * amd64-windows-tdep.c (amd64_windows_init_abi): Set
3002         tdep->integer_param_regs_saved_in_caller_frame to 1.
3003         * amd64-tdep.c (amd64_push_dummy_call): Allocate some memory on
3004         stack if tdep->integer_param_regs_saved_in_caller_frame is set.
3005
3006 2010-01-29  Joel Brobecker  <brobecker@adacore.com>
3007
3008         amd64-windows: memory args passed by pointer during function calls.
3009         * i386-tdep.h (gdbarch_tdep): Add field memory_args_by_pointer.
3010         * amd64-tdep.c (amd64_push_arguments): Add handling of architectures
3011         where tdep->memory_args_by_pointer is non-zero.
3012         * amd64-windows-tdep.c (amd64_windows_init_abi): Set
3013         tdep->memory_args_by_pointer to 1.
3014
3015 2010-01-29  Joel Brobecker  <brobecker@adacore.com>
3016
3017         amd64-windows: Integer parameters in function calls.
3018         * i386-tdep.h (enum amd64_reg_class): New, moved here from
3019         amd64-tdep.c.
3020         (struct gdbarch_tdep): Add fields call_dummy_num_integer_regs,
3021         call_dummy_integer_regs, and classify.
3022         * amd64-tdep.h (amd64_classify): Add declaration.
3023         * amd64-tdep.c (amd64_dummy_call_integer_regs): New static constant.
3024         (amd64_reg_class): Delete, moved to i386-tdep.h.
3025         (amd64_classify): Make non-static.  Move declaration to amd64-tdep.h.
3026         Replace call to amd64_classify by call to tdep->classify.
3027         (amd64_push_arguments): Get the list of registers to use for
3028         passing integer parameters from the gdbarch tdep structure,
3029         rather than using a hardcoded one.  Replace calls to amd64_classify
3030         by calls to tdep->classify.
3031         (amd64_push_dummy_call): Get the register number used for
3032         the "hidden" argument from tdep->call_dummy_integer_regs.
3033         (amd64_init_abi): Initialize tdep->call_dummy_num_integer_regs
3034         and tdep->call_dummy_integer_regs.  Set tdep->classify.
3035         * amd64-windows-tdep.c: Add include of gdbtypes.h.
3036         (amd64_windows_dummy_call_integer_regs): New static global.
3037         (amd64_windows_classify): New function.
3038         (amd64_windows_init_abi): Initialize tdep->call_dummy_num_integer_regs
3039         tdep->call_dummy_integer_regs and tdep->classify.
3040
3041 2010-01-28  Daniel Jacobowitz  <dan@codesourcery.com>
3042
3043         * regcache.c (regcache_xmalloc): Add aspace argument.  Use it
3044         for the new regcache.  All callers updated.
3045         (regcache_cpy, regcache_cpy_no_passthrough): Do not set aspace here.
3046         (get_thread_arch_regcache): Do not set aspace here.
3047         * regcache.h (regcache_xmalloc): Update declaration.
3048
3049         * frame.c, infcall.c, ppc-linux-tdep.c: Calls to
3050         regcache_xmalloc updated.
3051
3052 2010-01-28  Joel Brobecker  <brobecker@adacore.com>
3053
3054         Another -Wunused-function error in procfs.c (sparc-solaris)
3055         * procfs.c (insert_dbx_link_breakpoint): Delete declaration.  Move up.
3056         Only define if SYS_syssgi is defined.
3057         (remove_dbx_link_breakpoint): Delete declaration.  Move up.
3058         (dbx_link_addr, insert_dbx_link_bpt_in_file)
3059         (insert_dbx_link_bpt_in_region): Move up.  Only define if SYS_syssgi
3060         is itself defined.
3061
3062 2010-01-27  Christopher Faylor  <me+cygwin@cgf.cx>
3063
3064         * windows-nat.c (windows_initialization_done): New variable.
3065         (get_windows_debug_event): Issue error when process dies before
3066         completely initializing.
3067         (do_initial_windows_stuff): Set flag to indicate when we are done with
3068         the initial steps of attaching to the child.
3069
3070 2010-01-27  Jan Kratochvil  <jan.kratochvil@redhat.com>
3071
3072         * symtab.h (struct symbol <symtab>): New comment on NULL values.
3073
3074 2010-01-27  Doug Evans  <dje@google.com>
3075
3076         * solib-svr4.c (solib_break_names): Add __dl_rtld_db_dlactivity.
3077
3078         * breakpoint.c (bpstat_stop_status): Delete useless code.
3079
3080 2010-01-27  Jan Kratochvil  <jan.kratochvil@redhat.com>
3081
3082         * printcmd.c (display_uses_solib_p): Remove variable section.  Access
3083         objfile via SYMBOL_SYMTAB.
3084
3085 2010-01-26  Tom Tromey  <tromey@redhat.com>
3086
3087         PR exp/7643:
3088         * eval.c (evaluate_subexp_for_address) <UNOP_IND>: Call
3089         coerce_array on result.
3090
3091 2010-01-26  Sami Wagiaalla  <swagiaal@redhat.com>
3092
3093         * cp-namespace.c (cp_lookup_symbol_namespace): Added
3094         search_parent argument.
3095         (cp_add_using): Initialize 'searched' field.
3096         (reset_directive_searched): New function.
3097         * cp-support.h: Add 'searched' field to using_direct struct.
3098         (cp_lookup_symbol_imports): Ditto.
3099         * cp-namespace.c (cp_lookup_symbol_imports): Ditto.
3100         Perform recursive search.
3101         Implement non parent search.
3102         * valops.c (value_maybe_namespace_elt): Updated.
3103
3104 2010-01-26  Sami Wagiaalla  <swagiaal@redhat.com>
3105
3106         PR gdb/10929:
3107         * dwarf2read.c (read_lexical_block_scope): Create blocks for
3108         scopes which contain using directives even if they contain no
3109         declarations.
3110         * symtab.c (lookup_symbol_aux): Pass lowest level block to
3111         la_lookup_symbol_nonlocal.
3112         * cp-namespace.c (cp_lookup_symbol_nonlocal): call
3113         cp_lookup_symbol_namespace.
3114         (cp_lookup_symbol_namespace): Perform an import lookup at every
3115         block level.
3116         (cp_lookup_symbol_imports): New function.
3117         (cp_lookup_symbol_in_namespace): New function.
3118
3119 2010-01-25  Tom Tromey  <tromey@redhat.com>
3120
3121         PR gdb/11049:
3122         * c-valprint.c (c_val_print): Fix test of extract_unsigned_integer
3123         result.
3124
3125 2010-01-25  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
3126
3127         * configure.ac: Only use host_os part when disabling TUI on osf.
3128         Use test to check variables, prefix strings with x.
3129         * configure: Regenerate.
3130
3131         * solib-osf.c (osf_current_sos): Initialize tail.
3132
3133 2010-01-25  gingold  <gingold@adacore.com>
3134
3135         * windows-nat.c (windows_continue): Use %x to print thread id.
3136         (get_windows_debug_event): Ditto.
3137
3138 2010-01-22  Tom Tromey  <tromey@redhat.com>
3139
3140         PR symtab/11199:
3141         * dwarf2read.c (quirk_gcc_member_function_pointer): Change return
3142         type and arguments.  Use smash_to_methodptr_type.
3143         (read_structure_type): Call quirk_gcc_member_function_pointer
3144         later.
3145         * gdbtypes.h (smash_to_methodptr_type): Declare.
3146         * gdbtypes.c (smash_to_methodptr_type): New function.
3147         (lookup_methodptr_type): Use it.
3148
3149 2010-01-21  Tom Tromey  <tromey@redhat.com>
3150
3151         PR symtab/11198:
3152         * symtab.h (lookup_minimal_symbol_and_objfile): Declare.
3153         * minsyms.c (lookup_minimal_symbol_and_objfile): New function.
3154         * glibc-tdep.c (find_minsym_and_objfile): Remove.
3155         (glibc_skip_solib_resolver): Use
3156         lookup_minimal_symbol_and_objfile.
3157
3158 2010-01-21  Kai Tietz  <kai.tietz@onevision.com>
3159
3160         * inflow.c (check_syscall): Guard by #if clause for GO32 and
3161         WIN32 targets.
3162
3163 2010-01-20  Tom Tromey  <tromey@redhat.com>
3164
3165         PR backtrace/10770:
3166         * valarith.c (value_binop): Handle BINOP_GTR, BINOP_LEQ, and
3167         BINOP_GEQ.  Handle BINOP_NOTEQUAL in the signed case.
3168         * dwarf2expr.c (new_dwarf_expr_context): Allocate
3169         dwarf_stack_values, not CORE_ADDRs.
3170         (execute_stack_op): Change DW_OP_div and comparison operators to
3171         use signed operands.
3172
3173 2010-01-20  Vladimir Prus  <vladimir@codesourcery.com>
3174
3175         Per-inferior args and tty and environment.
3176
3177         * infcmd.c (inferior_args): Rename to ...
3178         (inferior_args_scratch): ... this.
3179         (inferior_io_terminal): Rename to ...
3180         (inferior_io_terminal_scratch): ... this.
3181         (inferior_argc, inferior_argv): Remove.
3182         (set_inferior_io_terminal, get_inferior_io_terminal): Store
3183         inside current_inferior().
3184         (set_inferior_tty_command, show_inferior_tty_command): New.
3185         (get_inferior_args, set_inferior_args): Store inside
3186         current_inferior().
3187         (notice_args_set): Likewise and rename to...
3188         (set_args_command): ... this.
3189         (set_inferior_args_vector): Likewise.
3190         (notice_args_read): Rename to...
3191         (show_args_command): ...new.
3192         (tty_command): Remove.
3193         (run_command_1): Don't free old args, as they are freed by
3194         set_inferior_arg now.
3195         (run_no_args_command): Likewise.
3196         (inferior_environ): Remove.
3197         (run_command_1): Use environment of the current inferior.
3198         (environment_info, set_environment_command)
3199         (unset_environment_command, path_info, path_command): Likewise.
3200         (_initialize_infcmd): Adjust for function and variable renames.
3201         Do not init inferior_environ.
3202         * inferior.h (set_inferior_arg): Adjust prototype.
3203         (struct inferior): New fields args, argc, argv, terminal, environment.
3204         (inferior_environ): Remove declaration.
3205         * inferior.c (free_inferior): Free new fields.
3206         (add_inferior_silent): Initialize 'environment' field.
3207         * main.c (captured_main): Set arguments only after the initial
3208         inferior has been created.  Set set_inferior_io_terminal,
3209         not tty_command.
3210         * mi/mi-main.c (mi_cmd_env_path): Use environment of the current
3211         inferior.
3212         (_initialize_mi_cmd_env): Adjust for disappearance of global
3213         inferior_environ.
3214         * solib.c (solib_find): Use environment of the current inferior.
3215
3216 2010-01-20  Jan Kratochvil  <jan.kratochvil@redhat.com>
3217
3218         * varobj.c (varobj_add_child, install_dynamic_child): Wrap into #if
3219         HAVE_PYTHON.
3220         (instantiate_pretty_printer): Move HAVE_PYTHON outside of the function.
3221
3222 2010-01-20  Joel Brobecker  <brobecker@adacore.com>
3223
3224         Get rid of ada-lang.c:function_name_from_pc.
3225         * ada-lang.c: Add "stack.h" #include.
3226         (function_name_from_pc): Delete.
3227         (is_known_support_routine): Replace call to function_name_from_pc
3228         by call to find_frame_funname.
3229         (ada_unhandled_exception_name_addr_from_raise): Likewise.
3230
3231 2010-01-19  Tom Tromey  <tromey@redhat.com>
3232
3233         PR c++/11026:
3234         * dwarf2read.c (read_partial_die): Allocate partial DIE's name on
3235         objfile obstack.
3236
3237 2010-01-19  Tom Tromey  <tromey@redhat.com>
3238
3239         * top.c (stop_sig, float_handler, do_nothing): Remove.
3240
3241 2010-01-19  Jan Kratochvil  <jan.kratochvil@redhat.com>
3242
3243         * breakpoint.c (watchpoint_check): Check the call
3244         gdbarch_in_function_epilogue_p before calling frame_find_by_id.
3245         Extend the comment.
3246         * config/djgpp/fnchange.lst: Add translations for 
3247         watchpoint-cond-gone.exp, watchpoint-cond-gone.c and
3248         watchpoint-cond-gone-stripped.c.
3249
3250 2010-01-19  Tom Tromey  <tromey@redhat.com>
3251
3252         PR c++/8000:
3253         * dwarf2read.c (partial_die_parent_scope): Put enumeration type
3254         into parent scope, and enumerator into grandparent scope.
3255
3256 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3257
3258         * NEWS: Add entry for "set/show ada trust-PAD-over-XVS" commands.
3259
3260 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3261
3262         * configure.host: Make x86_64-*-solaris2.1[0-9]* an alias of
3263         i[34567]86-*-solaris2.1[0-9]*.
3264         * configure.tgt: Likewise.
3265
3266 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3267
3268         * NEWS: Document the source command enhancement allowing it
3269         to load Python scripts. Document the "set/show script-extension"
3270         commands.
3271
3272 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3273
3274         Add -Wunused-function to compile flags.
3275         * configure.ac: Add -Wunused-function to build_warnings.
3276         * configure: Regenerate.
3277
3278 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3279
3280         "delete" ada-lex.c:input function, not used.
3281         * ada-lex.l: #define YY_NO_INPUT.
3282
3283 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3284
3285         Delete free_named_symtabs and associated cleanup.
3286         * symfile.h (free_named_symtabs): Delete declaration.
3287         * symfile.c: Remove some commented out code (clear_symtab_users_once).
3288         (cashier_psymtab): Comment function out.
3289         Delete declaration.
3290         (free_named_symtabs): Delete.
3291         * coffread.c (coff_end_symtab): Remove call to free_named_symtabs.
3292         * dbxread.c (end_psymtab): Likewise.
3293         * dwarf2read.c (process_psymtab_comp_unit): Ditto.
3294         * exec.c (exec_close_1): Ditto.
3295         * xcoffread.c (xcoff_end_psymtab): Likewise.
3296
3297 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3298
3299         * stack.c (print_block_frame_labels): Comment function out.
3300
3301 2010-01-19  Joel Brobecker  <brobecker@adacore.com>
3302
3303         Delete unused or undefined functions.
3304         * breakpoint.c (ep_parse_optional_filename): Delete.
3305         * dcache.c (dcache_write_line): Remove declaration.
3306         * infrun.c (build_infrun): Remove declaration.
3307         * tracepoint.c (tracepoint_save_command): Remove declaration.
3308         * linux-nat.c (init_lwp_list): Delete. No longer used.
3309         * event-loop.c (check_async_signal_handlers): Delete declaration.
3310         * infrun.c (init_execution_control_state): Delete.
3311         (proceed): Update comment to avoid mentioning
3312         init_execution_control_state.
3313         * target.c (kill_or_be_killed, nosupport_runtime): Delete.
3314         * ada-lang.c (ada_to_static_fixed_value): Delete.
3315         * scm-lang.c (evaluate_subexp_scm): Delete declaration.
3316         * cp-namespace.c (cp_copy_usings): Delete.
3317         * xml-syscall.c (xml_number_of_syscalls): Delete.
3318         * progspace.c (find_program_space_by_num): Delete.
3319         * inflow.c (handle_sigio): Delete declaration.
3320         * hppa-tdep.c (hppa_alignof): Delete.
3321         * mipsnbsd-tdep.c (mipsnbsd_sigtramp_offset)
3322         (mipsnbsd_core_osabi_sniffer): Delete.
3323
3324 2010-01-18  Tom Tromey  <tromey@redhat.com>
3325
3326         PR c++/9680:
3327         * c-exp.y (REINTERPRET_CAST, DYNAMIC_CAST, STATIC_CAST)
3328         (CONST_CAST): New tokens.
3329         (exp): Add new productions.
3330         (ident_tokens): Add const_cast, dynamic_cast, static_cast, and
3331         reinterpret_cast.
3332         (is_cast_operator): New function.
3333         (yylex): Handle cast operators specially.
3334         * eval.c (evaluate_subexp_standard) <UNOP_DYNAMIC_CAST,
3335         UNOP_REINTERPRET_CAST>: New cases.
3336         * expprint.c (print_subexp_standard): Likewise.
3337         (op_name_standard): Likewise.
3338         (dump_subexp_body_standard): Likewise.
3339         * parse.c (operator_length_standard): Likewise.
3340         * expression.h (enum exp_opcode): New constants UNOP_DYNAMIC_CAST,
3341         UNOP_REINTERPRET_CAST.
3342         * gdbtypes.c (class_types_same_p): New function.
3343         (is_ancestor): Use it.
3344         (is_public_ancestor): New function.
3345         (is_unique_ancestor_worker): Likewise.
3346         (is_unique_ancestor): Likewise.
3347         * gdbtypes.h (class_types_same_p, is_public_ancestor)
3348         (is_unique_ancestor): Declare.
3349         * valops.c (value_reinterpret_cast): New function.
3350         (dynamic_cast_check_1): Likewise.
3351         (dynamic_cast_check_2): Likewise.
3352         (value_dynamic_cast): Likewise.
3353         * value.h (value_reinterpret_cast, value_dynamic_cast): Declare.
3354
3355 2010-01-18  Joel Brobecker  <brobecker@adacore.com>
3356
3357         Fix build failure when building without Python support.
3358         * python/python.c: Always include exceptions.h, even when HAVE_PYTHON
3359         is not defined.
3360
3361 2010-01-18  Joel Brobecker  <brobecker@adacore.com>
3362
3363         Use XVS field type instead of doing a parallel lookup.
3364         * ada-lang.c (ada_get_base_type): Follow the XVS field type
3365         if it is a reference type instead of doing a type lookup using
3366         the XVS field name.
3367
3368 2010-01-18  Joel Brobecker  <brobecker@adacore.com>
3369
3370         Trust PAD types instead of using PAD___XVS.
3371         * ada-lang.c (trust_pad_over_xvs): New static variable.
3372         (ada_is_aligner_type): If !trust_pad_over_xvs and there is a
3373         parallel XVS type, follow the XVS type instead of the PAD type.
3374         (unwrap_value): Make sure that there is no parallel XVE type
3375         before returning the value as is.
3376         (set_ada_list, show_ada_list): New static variables.
3377         (set_ada_command, show_ada_command): New functions.
3378         (_initialize_ada_language): Add new "set/show ada" prefix commands.
3379         Add new "set/show ada trust-PAD-over-XVS" setting.
3380
3381 2010-01-18  Tom Tromey  <tromey@redhat.com>
3382             Thiago Jung Bauermann  <bauerman@br.ibm.com>
3383
3384         Allow "source" to load python scripts.
3385         * exceptions.h (enum errors): Add UNSUPPORTED_ERROR.
3386         * python/python.c (source_python_script): New function.
3387         * python/python.h (source_python_script): Add declaration.
3388         * cli/cli-cmds.c: #include exceptions.h and python/python.h.
3389         (script_ext_off, script_ext_soft, script_ext_strict)
3390         (script_ext_enums, script_ext_mode): New static constants.
3391         (show_script_ext_mode, find_and_open_script): New functions.
3392         (source_script): Enhance to handle Python scripts.
3393         (init_cli_cmds): Add set/show script-extension commands.
3394
3395 2010-01-16  Stan Shebs  <stan@codesourcery.com>
3396
3397         * tracepoint.h (struct trace_status): Use unsigned long long
3398         instead of size_t.
3399         * tracepoint.c (trace_status_command): Fix printf directive.
3400         (trace_save_command): Check fwrite returns, fix printf directive.
3401         (trace_filename): New global.
3402         (tfile_open): Set it, check read returns.
3403         (tfile_close): Free trace_filename.
3404         (tfile_get_traceframe_address): Check read returns.
3405         (tfile_trace_find): Ditto.
3406         (tfile_fetch_registers): Ditto.
3407         (tfile_xfer_partial): Ditto.
3408         (tfile_get_trace_state_variable_value): Ditto.
3409
3410 2010-01-15  Stan Shebs  <stan@codesourcery.com>
3411
3412         Add trace file support.
3413         * tracepoint.h (enum trace_stop_reason): New enum.
3414         (struct trace_status): New struct.
3415         (parse_trace_status): Declare.
3416         (struct uploaded_tp): Move here from remote.c,
3417         add fields for actions.
3418         (struct uploaded_tsv): New struct.
3419         * tracepoint.c (tfile_ops): New target vector.
3420         (trace_fd): New global.
3421         (tfile_open): New function.
3422         (tfile_close): New function.
3423         (tfile_files_info): New function.
3424         (tfile_get_trace_status): New function.
3425         (tfile_get_traceframe_address): New function.
3426         (tfile_trace_find): New function.
3427         (tfile_fetch_registers): New function.
3428         (tfile_xfer_partial): New function.
3429         (tfile_get_trace_state_variable_value): New function.
3430         (init_tfile_ops): New function.
3431         (_initialize_tracepoint): Call it, add tfile target.
3432         (trace_status): New global.
3433         (current_trace_status): New function.
3434         (trace_running_p): Remove, change all users to get from
3435         current_trace_status()->running.
3436         (get_trace_status): Remove.
3437         (trace_status_command): Call target_get_trace_status directly,
3438         report more detail including tracing stop reasons.
3439         (trace_find_command): Always allow tfind on a file.
3440         (trace_find_pc_command): Ditto.
3441         (trace_find_tracepoint_command): Ditto.
3442         (trace_find_line_command): Ditto.
3443         (trace_find_range_command): Ditto.
3444         (trace_find_outside_command): Ditto.
3445         (trace_frames_offset, cur_offset): Declare as off_t.
3446         (trace_regblock_size): Rename from reg_size, update users.
3447         (parse_trace_status): New function.
3448         (tfile_interp_line): New function.
3449         (disconnect_or_stop_tracing): Ensure current trace
3450         status before asking what to do.
3451         (stop_reason_names): New global.
3452         (trace_save_command): New command.
3453         (get_uploaded_tp): Move here from remote.c.
3454         (find_matching_tracepoint): Ditto.
3455         (merge_uploaded_tracepoints): New function.
3456         (parse_trace_status): Use stop_reason_names.
3457         (_initialize_tracepoint): Define tsave command.
3458         * target.h (target_ops): New fields to_save_trace_data,
3459         to_upload_tracepoints, to_upload_trace_state_variables,
3460         to_get_raw_trace_data, change to_get_trace_status
3461         to take a pointer to a status struct.
3462         (target_save_trace_data): New macro.
3463         (target_upload_tracepoints): New macro.
3464         (target_upload_trace_state_variables): New macro.
3465         (target_get_raw_trace_data): New macro.
3466         * target.c (update_current_target): Add new methods, change
3467         signature of to_get_trace_status.
3468         * remote.c (hex2bin): Make globally visible.
3469         (bin2hex): Ditto.
3470         (remote_download_trace_state_variable): Download name also.
3471         (remote_get_trace_status): Update parameter, use
3472         parse_trace_status.
3473         (remote_save_trace_data): New function.
3474         (remote_upload_tracepoints): New function.
3475         (remote_upload_trace_state_variables): New function.
3476         (remote_get_raw_trace_data): New function.
3477         (remote_start_remote): Use them.
3478         (_initialize_remote_ops): Add operations.
3479         * ax-gdb.c: Include breakpoint.h.
3480         * breakpoint.c (create_tracepoint_from_upload): Use
3481         break_command_really, return tracepoint, warn about unimplemented
3482         parts.
3483         * NEWS: Mention trace file addition.
3484
3485 2010-01-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
3486
3487         Fix compilation warning on gcc-3.4.
3488         * exec.c (print_section_info): Move the `displacement' variable
3489         initialization to its declaration.
3490
3491 2010-01-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
3492
3493         * gdb-gdb.py (StructMainTypePrettyPrinter): Fix TYPE_CODE_RANGE
3494         comparison.
3495
3496 2010-01-15  Eric Botcazou  <botcazou@adacore.com>
3497
3498         "info tasks" broken by typedefs in ATCB type definitions.
3499         * ada-lang.c (ada_template_to_fixed_record_type_1): Add call to
3500         ada_check_typedef before retrieving the length of the type for
3501         regular fields.
3502
3503 2010-01-15  Joel Brobecker  <brobecker@adacore.com>
3504
3505         Do not use name-based lookup for unconstrained packed arrays.
3506         * ada-lang.c (find_parallel_type_by_descriptive_type):
3507         Limit the fallback to name-based lookups to the case where
3508         the type is a constrained packed array.
3509
3510 2010-01-15  Joel Brobecker  <brobecker@adacore.com>
3511
3512         Enhance gdb-gdb.py to handle main_type.type_specific.
3513         * gdb-gdb.py: Print the type-specific part of struct main_type.
3514
3515 2010-01-15  Jan Kratochvil  <jan.kratochvil@redhat.com>
3516
3517         * configure.ac (AC_CHECK_FUNCS): Check for setrlimit and getrlimit.
3518         * configure: Regenerate.
3519         * config.in: Regenerate.
3520         * utils.c: Include sys/resource.h.
3521         (dump_core, can_dump_core): New.
3522         (internal_vproblem): Update the comment.  Check can_dump_core while
3523         setting dump_core_p.  Replace two abort calls by dump_core calls.
3524
3525 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3526             Eli Zaretskii  <eliz@gnu.org>
3527
3528         * NEWS: Document the PIE support.
3529
3530 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3531
3532         * linux-tdep.c: Remove includes gdbcore.h, observer.h and elf-bfd.h.
3533         (check_is_pie_binary, _initialize_linux_tdep): Remove.
3534
3535 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3536
3537         * solib-svr4.c (svr4_exec_displacement): New comment for entry_point.
3538         Replace exec_entry_point call by bfd_get_start_address.
3539
3540 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3541
3542         Support Valgrind attachments broken by the PIE support.
3543         * auxv.c: Include gdbcore.h.
3544         (procfs_xfer_auxv): Make static.  Reduce its comment.  Drop its
3545         parameters ops, object and annex.  Remove their assertions.
3546         (ld_so_xfer_auxv, memory_xfer_auxv): New function.
3547         * auxv.h (procfs_xfer_auxv): Remove comment.  Rename to ...
3548         (memory_xfer_auxv): ... here.
3549         * linux-nat.c (linux_xfer_partial): Rename procfs_xfer_auxv to
3550         memory_xfer_auxv.
3551         * procfs.c (procfs_xfer_partial): Likewise.
3552         * solib-svr4.c (svr4_relocate_main_executable): New prototype.
3553         (svr4_special_symbol_handling): Call svr4_relocate_main_executable.
3554         (svr4_solib_create_inferior_hook): Conditionalize the
3555         svr4_relocate_main_executable call.
3556
3557 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3558
3559         * solib-svr4.c (scan_dyntag): Remove variable dyn_addr.  New variable
3560         target_section.  Find SECT in current_target_sections, gdb_assert it.
3561         (elf_lookup_lib_symbol): Pass the binary file if given symfile_objfile.
3562         New variable abfd.
3563         * symtab.c (lookup_objfile_from_block): Return the binary file instead
3564         of separate debug info file.
3565
3566 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3567
3568         Support PIEs with no symfile_objfile.
3569         * exec.c (print_section_info <abfd == exec_bfd>): Relocate Entry point.
3570         * solib-svr4.c (svr4_relocate_main_executable <exec_bfd>): New block.
3571
3572 2010-01-14  Jan Kratochvil  <jan.kratochvil@redhat.com>
3573
3574         * solib-svr4.c (svr4_relocate_main_executable): Move the static exec
3575         code part to ...
3576         (svr4_static_exec_displacement): ... a new function.
3577         (svr4_exec_displacement): New function.
3578         (svr4_relocate_main_executable): Call svr4_exec_displacement.  Allocate
3579         new_offsets using alloca now.  Remove variable old_chain and changed.
3580         Call objfile_relocate unconditionally now.
3581
3582 2010-01-14  Doug Evans  <dje@google.com>
3583
3584         * gdbtypes.c (arch_flags_type): Fix comment.
3585         * gdbtypes.h (arch_composite_type): Fix comment.
3586
3587 2009-01-14  Tristan Gingold  <gingold@adacore.com>
3588
3589         * machoread.c (macho_add_oso_symfile): Add symfile_flags parameter.
3590         Call xstrdup for abfd->filename.  Pass symfile_flags and objfile flags
3591         to symbol_file_add_from_bfd.  Add OSO as separate objfile.
3592         (macho_oso_symfile): Add symfile_flags parameter.  Pass it to
3593         macho_add_oso_symfile.
3594         (macho_symfile_read): Pass symfile_flags to macho_oso_symfile.
3595
3596 2010-01-14  Joel Brobecker  <brobecker@adacore.com>
3597
3598         Tru64: Dead threads are never deleted.
3599         * dec-thread.c (dec_thread_ptid_is_alive): New function.
3600         (dec_thread_count_gdb_threads): Fix counter increment.
3601         (dec_thread_add_gdb_thread): Fix *listp increment.
3602         (resync_thread_list): Fix bug in deletion of dead threads that
3603         caused all threads to be deleted, instead of just the dead ones.
3604
3605 2010-01-13  Phil Muldoon  <pmuldoon@redhat.com>
3606
3607         PR python/10705
3608
3609         * python/python-internal.h: Add lazy_string_object_type
3610         definition.
3611         (create_lazy_string_object, gdbpy_initialize_lazy_string)
3612         (gdbpy_is_lazystring, gdbpy_extract_lazy_string): Define.
3613         * python/py-value.c (valpy_lazy_string): New function.
3614         (convert_value_from_python): Add lazy string conversion.
3615         * python/py-prettyprint.c (pretty_print_one_value): Check if
3616         return is also a lazy string.
3617         (print_string_repr): Add lazy string printing branch.
3618         (print_children): Likewise.
3619         * python/py-lazy-string.c: New file. Implement lazy strings.
3620         * python/python.c (_initialize_python): Call
3621         gdbpy_initialize_lazy_string.
3622         * varobj.c (value_get_print_value): Add lazy string printing
3623         branch.  Account for encoding.
3624         * c-lang.c (c_printstr): Account for new encoding argument.  If
3625         encoding is NULL, find encoding suited for type, otherwise use
3626         user encoding.
3627         * language.h (language_defn): Add encoding argument.
3628         (LA_PRINT_STRING): Likewise.
3629         * language.c (unk_lang_printstr): Update to reflect new encoding
3630         argument to language_defn.
3631         * ada-lang.h (ada_printstr): Likewise.
3632         * c-lang.h (c_printstr): Likewise.
3633         * p-lang.h (pascal_printstr);
3634         * f-lang.c (f_printstr): Likewise.
3635         * m2-lang.c (m2_printstr): Likewise.
3636         * objc-lang.c (objc_printstr): Likewise.
3637         * p-lang.c (pascal_printstr): Likewise.
3638         * scm-lang.c (scm_printstr): Likewise.
3639         * c-valprint.c (c_val_print): Update LA_PRINT_STRING call for
3640         encoding argument.
3641         * ada-valprint.c (ada_printstr): Likewise.
3642         * f-valprint.c (f_val_print): Likewise
3643         * m2-valprint.c (m2_val_print): Likewise.
3644         * p-valprint.c (pascal_val_print): Likewise.
3645         * expprint.c (print_subexp_standard): Likewise.
3646         * valprint.c (val_print_string): Likewise.
3647         * Makefile.in (SUBDIR_PYTHON_OBS): Add py-lazy-string.
3648         (SUBDIR_PYTHON_SRCS): Likewise.
3649         (py-lazy-string.o): New rule.
3650
3651 2010-01-13  Doug Evans  <dje@google.com>
3652
3653         * mi/mi-main.c (list_available_thread_groups): Avoid "may be used
3654         uninitialized" warning from gcc on local `tree'.
3655
3656 2010-01-13  Vladimir Prus  <vladimir@codesourcery.com>
3657
3658         Implement core awareness.
3659
3660         * bcache.c (compare_ints): Remove
3661         (print_percentage): Use compare_positive_ints.
3662         * defs.h (compare_positive_ints): Declare.
3663         * linux-nat.h (struct lin_lwp): New field core.
3664         (linux_nat_core_of_thread_1): Declare.
3665         * linux-nat.c (add_lwp): Init the 'core' field.
3666         (linux_nat_wait_1): Record the core.
3667         (linux_nat_core_of_thread_1, linux_nat_core_of_thread): New.
3668         (linux_nat_add_target): Register the above.
3669         * linux-thread-db.c (update_thread_core): New.
3670         (thread_db_find_new_threads): Update core information for
3671         every thread.
3672         * remote.c (struct private_thread_info): New.
3673         (free_private_thread_info, demand_private_info): New.
3674         (PACKET_qXfer_threads, use_osdata_threads): New.
3675         (struct thread_item, threads_parsing_context
3676         (start_thread, end_thread, thread_attributes)
3677         (thread_children, threads_children, threads_elements): New.
3678         (remote_threads_info): Try qXfer:threads before anything
3679         else.
3680         (remote_protocol_packets): Register qXfer:threads.
3681         (remote_open_1): Init use_osdata_threads.
3682         (struct stop_reply): New field 'core'.
3683         (remote_parse_stop_reply): Parse core number.
3684         (process_stop_reply): Record core number.
3685         (remote_xfer_partial): Handle qXfer:threads.
3686         (remote_core_of_thread): New.
3687         (init_remote_ops): Register remote_core_of_thread.
3688         (_initialize_remote): Register qXfer:read.
3689         * target.c (target_core_of_thread): New
3690         * target.h (enum target_object): New value TARGET_OBJECT_THREADS.
3691         (struct target_ops): New field to_core_of_threads.
3692         (target_core_of_thread): Declare.
3693         * gdbthread.h (struct thread_info): New field private_dtor.
3694         * thread.c (print_thread_info): Report the core.
3695         * ui-out.c (MAX_UI_OUT_LEVELS): Increase.
3696         * utils.c (compare_positive_ints): New.
3697         * features/threads.dtd: New.
3698         * mi/mi-interp.c (mi_on_normal_stop): Report the core.
3699         * mi/mi-main.c (struct collect_cores_data, collect_cores)
3700         (do_nothing, free_vector_of_osdata_items)
3701         (splay_tree_int_comparator, free_splay_tree): New.
3702         (print_one_inferior_data): Implemented printing of selected
3703         inferiors.  Collect and print cores.
3704         (output_cores): New.
3705         (mi_cmd_list_thread_groups): Support --recurse.  Permit specifying
3706         thread groups together with --available.
3707
3708 2010-01-12  Jan Kratochvil  <jan.kratochvil@redhat.com>
3709
3710         * configure: Regenerate (for _STRUCTURED_PROC).
3711
3712 2010-01-12  Joel Brobecker  <brobecker@adacore.com>
3713
3714         Delete dead function.
3715         * ada-lang.c (extract_string): Delete.  No longer used.
3716
3717 2010-01-12  Joel Brobecker  <brobecker@adacore.com>
3718
3719         Fix -Wunused warning in dec-thread.c.
3720         * dec-thread.c (dec_thread_count_gdb_threads)
3721         (dec_thread_add_gdb_thread): Prevent -Wunused warning.
3722
3723 2010-01-12  Joel Brobecker  <brobecker@adacore.com>
3724
3725         * ada-valprint.c (ada_print_floating): Remove trailing space.
3726
3727 2010-01-12  Joel Brobecker  <brobecker@adacore.com>
3728
3729         Add support for DW_AT_GNAT_descriptive_type.
3730         * gdbtypes.h (enum type_specific_kind): New enum.
3731         (struct main_type) [type_specific_field]: New component.
3732         [type_specific]: Add new component "gnat_stuff".
3733         (struct gnat_aux_type): New type.
3734         (INIT_CPLUS_SPECIFIC): Also set TYPE_SPECIFIC_FIELD (type).
3735         (HAVE_CPLUS_STRUCT): Also check TYPE_SPECIFIC_FIELD (type).
3736         (gnat_aux_default, allocate_gnat_aux_type): Add declaration.
3737         (INIT_GNAT_SPECIFIC, ALLOCATE_GNAT_AUX_TYPE, HAVE_GNAT_AUX_INFO)
3738         (TYPE_SPECIFIC_FIELD): New macros.
3739         (TYPE_CPLUS_SPECIFIC): Return cplus_struct_default if the given
3740         type does not hold any cplus-specific data.
3741         (TYPE_RAW_CPLUS_SPECIFIC): New macro.
3742         (TYPE_GNAT_SPECIFIC, TYPE_DESCRIPTIVE_TYPE): New macros.
3743         (TYPE_IS_OPAQUE): Use HAVE_CPLUS_STRUCT to check if type has
3744         cplus-specific data.
3745         * gdbtypes.c (allocate_cplus_struct_type): Minor stylistic rewrite.
3746         Set new component TYPE_SPECIFIC_FIELD (type).
3747         (gnat_aux_default): New constant.
3748         (allocate_gnat_aux_type): New function.
3749         (init_type): Add initialization the type-specific stuff for
3750         TYPE_CODE_FLT and TYPE_CODE_FUNC types.
3751         (print_gnat_stuff): New function.
3752         (recursive_dump_type): Use HAVE_CPLUS_STRUCT to check for cplus-
3753         specific data.  Adjust code that prints the contents of the
3754         type-specific union using the TYPE_SPECIFIC_FIELD value.
3755         * dwarf2read.c (dwarf2_attach_fields_to_type): Do not allocate
3756         the type cplus stuff for Ada types.
3757         (dwarf2_add_member_fn, dwarf2_attach_fn_fields_to_type):
3758         Error out if these routines are called with an Ada type.
3759         (read_structure_type, read_array_type, read_subrange_type):
3760         Add call to set_descriptive_type.
3761         (set_die_type): Initialize the gnat-specific data if necessary.
3762         (need_gnat_info, die_descriptive_type, set_descriptive_type):
3763         New functions.
3764         * ada-lang.c (decode_constrained_packed_array_type): Use
3765         decode_constrained_packed_array_type instead of doing a standard
3766         lookup to locate a parallel type.
3767         (find_parallel_type_by_descriptive_type): New function.
3768         (ada_find_parallel_type_with_name): New function.
3769         (ada_find_parallel_type): Reimplement using
3770         ada_find_parallel_type_with_name.
3771         * ada-valprint.c (print_field_values): Use HAVE_CPLUS_STRUCT
3772         to check if type has a cplus stuff.
3773         * linespec.c (total_number_of_methods): Likewise.
3774         * mdebugread.c (new_type): Likewise.
3775
3776 2010-01-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
3777
3778         * NEWS: Document the 0b binary number prefix parsing.
3779
3780 2010-01-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
3781
3782         * objfiles.c (objfile_relocate1): Change the return type to int.
3783         Describe the new return value.  Return non-zero if data changed.
3784         (objfile_relocate): New variable changed.  Set it.  Call
3785         breakpoint_re_set depending on CHANGED.
3786
3787 2010-01-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
3788
3789         Implement binary numbers parsing.
3790         * c-exp.y (parse_number): New case 'b' and 'B'.
3791
3792 2010-01-11  Jan Kratochvil  <jan.kratochvil@redhat.com>
3793             Tristan Gingold  <gingold@adacore.com>
3794
3795         * solib.c (info_sharedlibrary_command): Replace
3796         objfile_has_partial_symbols and objfile_has_full_symbols calls by
3797         objfile_has_symbols.
3798
3799 2010-01-10  Joel Brobecker  <brobecker@adacore.com>
3800
3801         * NEWS: Document the improvements made to the mips-irix port.
3802
3803 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3804
3805         Fix the documentation of valprint.c:value_print.
3806         * valprint.c (value_print): Update the function description to
3807         mention that the syntax of the output follows the current_language,
3808         not necessarily C.
3809
3810 2010-01-09  Jan Kratochvil  <jan.kratochvil@redhat.com>
3811
3812         Fix displacement of separate debug info files.
3813         * objfiles.c (objfile_relocate): Rename to ...
3814         (objfile_relocate1): ... here and make it static.  Extend the comment.
3815         (objfile_relocate): New function.
3816         * solib-spu.c (spu_relocate_main_executable): Explicitly check if
3817         SYMFILE_OBJFILE is NULL.  Remove variables objfile and old_chain.
3818         Remove following of SEPARATE_DEBUG_OBJFILE.  new_offsets is now
3819         allocated using alloca.
3820         * symfile.c (copy_section_addr_info): Remove.
3821         (build_section_addr_info_from_objfile): Make it global.  New variables
3822         addr_bit and mask, use them.
3823         * symfile.h (build_section_addr_info_from_objfile): New prototype.
3824         (copy_section_addr_info): Remove.
3825
3826 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3827
3828         Signal unwinder for mips-irix N32.
3829         * mips-irix-tdep.c: #include mips-tdep.h, trad-frame.h, and
3830         tramp-frame.h.
3831         (SIGTRAMP_FRAME_SIZE, SIGCONTEXT_PC_OFF, SIGCONTEXT_REGS_OFF)
3832         (SIGCONTEXT_FPREGS_OFF, SIGCONTEXT_FPCSR_OFF, SIGCONTEXT_HI_OFF)
3833         (SIGCONTEXT_LO_OFF): New macros. 
3834         (mips_irix_n32_tramp_frame_init): New function. 
3835         (mips_irix_n32_tramp_frame): New static constant.
3836         (mips_irix_init_abi): Prepend the mips_irix_n32_tramp_frame unwinder.
3837
3838 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3839
3840         Breakpoint in shared library does not work on mips-irix.
3841         * procfs.c: #include "observer.h".
3842         (procfs_inferior_created): New function, moving here the code
3843         which unsets the syssgi syscall-exit notifications.
3844         (procfs_create_inferior): Remove the code which unsets the syssgi
3845         syscall-exit notifications. It is too early to do this here.
3846         (_initialize_procfs): Attach the procfs_inferior_created observer.
3847
3848 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3849
3850         Wrong return convention for arrays (mips-irix).
3851         * mips-tdep.c (mips_n32n64_return_value): Arrays whose size is
3852         128 bits or smaller are returned the same way as structs
3853         and unions of the the same size.
3854
3855 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3856
3857         Cannot set the PC on mips-irix.
3858         * irix5-nat.c (fill_gregset): Check regno against the raw PC
3859         register number, no the cooked one.
3860
3861 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3862
3863         Error while loading core file on mips-irix.
3864         * solib-irix.c (irix_solib_create_inferior_hook): Do nothing
3865         if debugging from a core file.
3866
3867 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3868
3869         GDB hangs when attaching to process on mips-irix.
3870         * solib-irix.c (irix_solib_create_inferior_hook): Do nothing if
3871         attaching to a process.
3872
3873 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3874
3875         Use the correct breakpoint instruction on mips-irix.
3876         * mips-tdep.c (mips_breakpoint_from_pc): Add new static variable
3877         containing the correct breakpoint instruction to use on mips-irix.
3878         Use it when the osabi is GDB_OSABI_IRIX.
3879
3880 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3881
3882         -Wunused warning in procfs.c (mips-irix only).
3883         * procfs.c (gdb_praddset, gdb_prdelset): New macros.  Use them
3884         throughout instead of using praddset and prdelset respectively.
3885
3886 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3887
3888         GDB crash while stepping into function.
3889         * infrun.c (handle_inferior_event): Refetch the current frame
3890         after handling what.main_action, in case that pointer became
3891         dangling.
3892
3893 2010-01-09  Joel Brobecker  <brobecker@adacore.com>
3894
3895         Fix build failure of solaris-hosted cross debuggers.
3896         * ada-valprint.c, parse.c: Include defs.h before including ctype.h.
3897
3898 2010-01-09  Daniel Gutson  <dgutson@codesourcery.com>
3899
3900         Fix build failure on sparc-solaris.
3901         * procfs.c: (procfs_do_thread_registers) Use elfcore_write_lwpstatus.
3902
3903 2010-01-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
3904
3905         Move some symfile code into subroutines.
3906         * symfile.h (relative_addr_info_to_section_offsets)
3907         (addr_info_make_relative): New prototypes.
3908         * symfile.c (default_symfile_offsets): Move a part to ...
3909         (relative_addr_info_to_section_offsets): ... this new function.
3910         (default_symfile_offsets): Call it.
3911         (syms_from_objfile <!mainline && addrs && addrs->other[0].name>): Move
3912         this part to ...
3913         (addr_info_make_relative): ... this new function.
3914
3915 2010-01-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
3916
3917         Add from_tty to solib_create_inferior_hook.
3918         * infcmd.c (post_create_inferior): Move solib_add after
3919         solib_create_inferior_hook.  Pass from_tty to
3920         solib_create_inferior_hook.  Call solib_add and SOLIB_ADD with
3921         0 from_tty and comment why.
3922         * infrun.c (follow_exec): Pass from_tty solib_create_inferior_hook as 0.
3923         * linux-nat.c (linux_child_follow_fork): Likewise.
3924         * nto-procfs.c (procfs_post_attach, procfs_create_inferior): Likewise.
3925         * solib-darwin.c (darwin_solib_create_inferior_hook): New parameter
3926         from_tty.
3927         * solib-frv.c (frv_solib_create_inferior_hook): Likewise.
3928         * solib-irix.c (irix_solib_create_inferior_hook): Likewise.
3929         * solib-null.c (null_solib_create_inferior_hook): Likewise.
3930         * solib-osf.c (osf_solib_create_inferior_hook): Likewise.
3931         * solib-pa64.c (pa64_solib_create_inferior_hook): Likewise.
3932         * solib-som.c (som_solib_create_inferior_hook): Likewise.
3933         * solib-spu.c (spu_solib_create_inferior_hook): New parameter from_tty.
3934         Pass it to svr4_so_ops.solib_create_inferior_hook.
3935         * solib-sunos.c (sunos_solib_create_inferior_hook): New parameter
3936         from_tty.
3937         * solib-svr4.c (enable_break): New parameter from_tty.  Pass it to
3938         solib_add.
3939         (svr4_solib_create_inferior_hook): New parameter from_tty.  Pass it to
3940         enable_break.
3941         * solib-target.c (solib_target_solib_create_inferior_hook): New
3942         parameter from_tty.
3943         * solib.c (solib_create_inferior_hook): New parameter from_tty.  Pass
3944         it to ops->solib_create_inferior_hook.
3945         (reload_shared_libraries): Pass from_tty to solib_create_inferior_hook.
3946         Move solib_add after solib_create_inferior_hook, call it now with
3947         from_tty as 0.  New comment there.
3948         * solib.h (solib_create_inferior_hook): New parameter from_tty.
3949         * solist.h (struct target_so_ops <solib_create_inferior_hook>):
3950         Likewise.
3951
3952 2010-01-08  Vladimir Prus  <vladimir@codesourcery.com>
3953
3954         Fix multiexec race.
3955         * infrun.c (handle_inferior_event): Use get_thread_regcache
3956         with events ptid, not get_current_regcache.
3957
3958 2009-01-08  Joel Brobecker  <brobecker@adacore.com>
3959
3960         GDB crash with empty executable name (MinGW).
3961         * source.c (openp): Add assert that parameter string is not NULL.
3962         if parameter string is an empty string, then return with a failure
3963         immediately.
3964
3965 2009-01-08  Joel Brobecker  <brobecker@adacore.com>
3966
3967         Get rid of support for VAX Floats.
3968         * ada-lang.h (ada_is_vax_floating_type, ada_vax_float_type_suffix)
3969         (ada_vax_float_print_function): Delete.
3970         * ada-lang.c (ada_is_vax_floating_type, ada_vax_float_type_suffix)
3971         (ada_vax_float_print_function): Delete.
3972         * ada-typeprint.c (print_vax_floating_point_type): Delete.
3973         (ada_print_type): Remove support for VAX floats.
3974         * ada-valprint.c (ada_val_print_1): Remove support for VAX floats.
3975
3976 2010-01-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
3977
3978         * stabsread.c (read_args): Handle zero arguments.
3979
3980 2009-01-08  Joel Brobecker  <brobecker@adacore.com>
3981
3982         Cannot find in-tree libiconv.a after reconfigure.
3983         * acinclude.m4 (AM_ICONV): If we find an in-tree libiconv.a
3984         that we can use, then cache the path to this archive.
3985         * configure: Regenerate.
3986
3987 2010-01-07  Stan Shebs  <stan@codesourcery.com>
3988
3989         Make tracepoint operations go through target vector.
3990         * target.h (enum trace_find_type): New enum.
3991         (struct target_ops): New fields to_trace_init,
3992         to_download_tracepoint, to_download_trace_state_variable,
3993         to_trace_set_readonly_regions, to_trace_start, to_get_trace_status,
3994         to_trace_stop, to_trace_find, to_get_trace_state_variable_value,
3995         to_set_disconnected_tracing.
3996         (target_trace_init): New macro.
3997         (target_download_tracepoint): New macro.
3998         (target_download_trace_state_variable): New macro.
3999         (target_trace_start): New macro.
4000         (target_trace_set_readonly_regions): New macro.
4001         (target_get_trace_status): New macro.
4002         (target_trace_stop): New macro.
4003         (target_trace_find): New macro.
4004         (target_get_trace_state_variable_value): New macro.
4005         (target_set_disconnected_tracing): New macro.
4006         * target.c (update_current_target): Inherit and set defaults for
4007         tracepoint operations.
4008         * tracepoint.c (default_collect): Make globally visible.
4009         (target_is_remote): Remove, along with all calls.
4010         (tvariables_info): Call target_get_trace_state_variable_value.
4011         (remote_set_transparent_ranges): Remove.
4012         (trace_start_command): Call target_trace_init,
4013         target_download_tracepoint, etc.
4014         (download_tracepoint): Remove.
4015         (trace_stop_command): Simplify.
4016         (stop_tracing): Call target_trace_stop.
4017         (get_trace_status): Call target_get_trace_status.
4018         (trace_status_command): Add case for targets that cannot trace.
4019         (finish_tfind_command): Change to take numerical arguments, call
4020         target_trace_find.
4021         (trace_find_command): Update call to finish_tfind_command.
4022         (trace_find_pc_command): Ditto.
4023         (trace_find_tracepoint_command): Ditto.
4024         (trace_find_line_command): Ditto.
4025         (trace_find_range_command): Ditto.
4026         (trace_find_outside_command): Ditto.
4027         (set_disconnected_tracing_value): Call
4028         target_set_disconnected_tracing.
4029         * remote.c: Add protocol encoding bits from tracepoint.c.
4030         (trace_error): Move from tracepoint.c.
4031         (remote_get_noisy_reply): Ditto.
4032         (free_actions_list_cleanup_wrapper): Ditto.
4033         (free_actions_list): Ditto.
4034         (remote_trace_init): New function.
4035         (remote_download_tracepoint): New function.
4036         (remote_download_trace_state_variable): New function.
4037         (remote_trace_set_readonly_regions): New function.
4038         (remote_trace_start): New function.
4039         (remote_get_trace_status): New function.
4040         (remote_trace_stop): New function.
4041         (remote_trace_find): New function.
4042         (remote_download_trace_state_variable): New function.
4043         (remote_set_disconnected_tracing): New function.
4044         (init_remote_ops): Add tracepoint operations.
4045
4046         * tracepoint.c (trace_dump_command): Don't decr_pc_after_break.
4047
4048 2010-01-07  Tristan Gingold  <gingold@adacore.com>
4049
4050         * symfile.c (build_section_addr_info_from_objfile): New function.
4051         (symbol_file_add_separate): Don't use offsets from objfile but
4052         built an addr info.
4053
4054 2010-01-06  Stan Shebs  <stan@codesourcery.com>
4055
4056         Support disconnected tracing.
4057         * infcmd.c (detach_command): Ask whether to stop tracing.
4058         * cli/cli-cmds.c (quit_command): Ditto.
4059         * breakpoint.h (struct breakpoint): New field number_on_target.
4060         * breakpoint.c (create_tracepoint_from_upload): New function.
4061         (get_tracepoint_by_number_on_target): New function.
4062         * remote.c (struct remote): New field disconnected_tracing.
4063         (remote_disconnected_tracing_feature): New function.
4064         (remote_protocol_features): Add DisconnectedTracing.
4065         (struct uploaded_tp): New struct.
4066         (uploaded_tps): New global.
4067         (get_uploaded_tp): New function.
4068         (find_matching_tracepoint): New function.
4069         (remote_get_tracing_state): New function.
4070         (remote_start_remote): Call it.
4071         * tracepoint.c (disconnected_tracing): New global.
4072         (trace_start_command): Initialize number_on_target.
4073         (stop_tracing): New function, split out from...
4074         (trace_stop_command): Call stop_tracing.
4075         (get_trace_status): New function, split out from...
4076         (trace_status_command): Call get_trace_status, add info on
4077         disconnection behavior.
4078         (disconnect_or_stop_tracing): New function.
4079         (finish_tfind_command): Translate from number on target.
4080         (trace_find_tracepoint_command): Translate to number on target.
4081         (send_disconnected_tracing_value): New function.
4082         (set_disconnected_tracing): New function.
4083         (_initialize_tracepoint): Add disconnected-tracing variable.
4084         * NEWS: Mention disconnected tracing.
4085
4086 2010-01-06  Tristan Gingold  <gingold@adacore.com>
4087
4088         * symtab.c (lookup_global_symbol_from_objfile): Rename objfile
4089         parameter to main_objfile.  Iterate on all separate debug objfiles.
4090         * symfile.h (symbol_file_add_separate)
4091         (find_separate_debug_file_by_debuglink): Remove parameter names.
4092         * symfile.c (symbol_file_add_separate): Use add_separate_objfile.
4093         (reread_symbols): Use free_objfile_separate_debug.
4094         * objfiles.h (struct objfile): Add separate_debug_objfile_link.
4095         Adjust comment.
4096         (objfile_separate_debug_iterate, add_separate_debug_objfile)
4097         (free_objfile_separate_debug): New prototypes.
4098         * objfiles.c (objfile_separate_debug_iterate): New function.
4099         (add_separate_debug_objfile, free_objfile_separate_debug): New
4100         functions.
4101         (free_objfile): Use free_objfile_separate_debug.  Adjust for
4102         multiple separate debug objfile.
4103         (objfile_has_symbols): Adjust comment.  Iterate on all separate
4104         debug objfiles.
4105         * minsyms.c (lookup_minimal_symbol): Adjust for multiple separate
4106         debug objfile.
4107         (lookup_minimal_symbol_text): Ditto.
4108         (lookup_minimal_symbol_by_pc_name): Ditto.
4109         (lookup_minimal_symbol_solib_trampoline): Ditto.
4110         (lookup_minimal_symbol_by_pc_section_1): Iterate on all separate
4111         debug objfiles.
4112
4113 2010-01-05  Stan Shebs  <stan@codesourcery.com>
4114
4115         Add fast tracepoints.
4116         * arch-utils.h (default_fast_tracepoint_valid_at): Declare.
4117         * arch-utils.c (default_fast_tracepoint_valid_at): New function.
4118         * breakpoint.h (enum bptype): Add bp_fast_tracepoint.
4119         * breakpoint.c (tracepoint_type): New function.
4120         (ALL_TRACEPOINTS): Use it.
4121         (should_be_inserted): Ditto.
4122         (bpstat_check_location): Ditto.
4123         (print_one_breakpoint_location): Ditto.
4124         (user_settable_breakpoint): Ditto.
4125         (set_breakpoint_location_function): Ditto.
4126         (disable_breakpoints_in_shlibs): Ditto.
4127         (delete_trace_command): Ditto.
4128         (print_it_typical): Add bp_fast_tracepoint case.
4129         (bpstat_what): Ditto.
4130         (print_one_breakpoint_location): Ditto.
4131         (allocate_bp_location): Ditto.
4132         (mention): Ditto.
4133         (breakpoint_re_set_one): Ditto.
4134         (disable_command): Ditto.
4135         (enable_command): Ditto.
4136         (check_fast_tracepoint_sals): New function.
4137         (break_command_really): Call it.
4138         (ftrace_command): New function.
4139         (_initialize_breakpoint): Add ftrace command.
4140         * gdbarch.sh (fast_tracepoint_valid_at): New.
4141         * gdbarch.h, gdbarch.c: Regenerate.
4142         * i386-tdep.c (i386_fast_tracepoint_valid_at): New function.
4143         (i386_gdbarch_init): Use it.
4144         * remote.c (struct remote_state): New field fast_tracepoints.
4145         (PACKET_FastTracepoints): New packet config type.
4146         (remote_fast_tracepoint_feature): New function.
4147         (remote_protocol_features): Add FastTracepoints.
4148         (remote_supports_fast_tracepoints): New function.
4149         (_initialize_remote): Add FastTracepoints.
4150         * tracepoint.c (download_tracepoint): Add fast tracepoint option.
4151         * NEWS: Mention fast tracepoints.
4152
4153 2010-01-06  Joel Brobecker  <brobecker@adacore.com>
4154
4155         * gdb-gdb.py: New file.
4156
4157 2010-01-05  Michael Snyder  <msnyder@vmware.com>
4158
4159         * infrun.c (handle_inferior_event): Fix typo in comment.
4160
4161 2010-01-05  Jan Kratochvil  <jan.kratochvil@redhat.com>
4162
4163         * symfile.c (syms_from_objfile): Remove the !MAINLINE conditional.
4164
4165 2010-01-04  Ulrich Weigand  <uweigand@de.ibm.com>
4166
4167         * features/Makefile (WHICH): Add s390-linux32, s390-linux64,
4168         and s390x-linux64.
4169         (s390-linux32-expedite): Define.
4170         (s390-linux64-expedite): Define.
4171         (s390x-linux64-expedite): Define.
4172         * features/s390-acr.xml: New file.
4173         * features/s390-fpr.xml: New file.
4174         * features/s390-core32.xml: New file.
4175         * features/s390-core64.xml: New file.
4176         * features/s390x-core64.xml: New file.
4177         * features/s390-linux32.xml: New file.
4178         * features/s390-linux64.xml: New file.
4179         * features/s390x-linux64.xml: New file.
4180         * features/s390-linux32.c: New generated file.
4181         * features/s390-linux64.c: New generated file.
4182         * features/s390x-linux64.c: New generated file.
4183
4184         * regformats/s390-linux32.dat: New generated file.
4185         * regformats/s390-linux64.dat: New generated file.
4186         * regformats/s390x-linux64.dat: New generated file.
4187         * regformats/reg-s390.dat: Remove.
4188         * regformats/reg-s390x.dat: Remove.
4189
4190         * s390-nat.c: Include "auxv.h" and <elf.h>.
4191         (HWCAP_S390_HIGH_GPRS): Define if undefined.
4192         (s390_target_wordsize): New function.
4193         (s390_auxv_parse): Likewise.
4194         (s390_get_hwcap): Likewise.
4195         (s390_read_description): Likewise.
4196         (_initialize_s390_nat): Install s390_auxv_parse and
4197         s390_read_description.
4198
4199         * s390-tdep.c: Include "features/s390-linux32.c",
4200         "features/s390-linux64.c", and "features/s390x-linux64.c".
4201         (struct gdbarch_tdep): Add gpr_full_regnum, pc_regnum, and cc_regnum.
4202         (s390_register_call_saved): New function.
4203         (s390_register_name): Remove.
4204         (s390_register_type): Remove.
4205         (s390_dwarf_regmap): Add lower half GPR pseudo DWARF CFI regnums.
4206         (s390_dwarf_reg_to_regnum): Remap GPR regnums to full GPRs.
4207         (s390_adjust_frame_regnum): Remap GPR regnums to lower halves for CFI.
4208         (s390_pseudo_register_name): New function.
4209         (s390_pseudo_register_type): New function.
4210         (s390_pseudo_register_read): Handle both 32-bit and 64-bit cases.
4211         Handle full GPR pesudos and varying pseudo register numbers.
4212         (s390_pseudo_register_write): Likewise
4213         (s390x_pseudo_register_read): Remove.
4214         (s390x_pseudo_register_write): Likewise.
4215         (s390_register_group): Remove.
4216         (s390_pseudo_register_group): New function.
4217         (s390_regmap_gregset): Add GPR upper halves.
4218         (s390x_regmap_gregset): Likewise.
4219         (s390_regmap_fpregset): Likewise.
4220         (s390_regmap_upper): New global variable.
4221         (s390_upper_regset): New global variable.
4222         (s390_upper_regset_sections): New global variable.
4223         (s390_regset_from_core_section): Handle GPR upper halves.
4224         (s390_core_read_description): New function.
4225         (s390_prologue_frame_unwind_cache): Set up ABI call-saved/clobbered
4226         register information.  Handle varying pseudo register numbers.
4227         (s390_backchain_frame_unwind_cache): Likewise.
4228         (s390_frame_prev_register): Unwind full GPRs to show lower halves.
4229         (s390_stub_frame_unwind_cache): Handle varying pseudo register numbers.
4230         (s390_sigtramp_frame_unwind_cache): Unwind PSWM and PSWA as well as
4231         PC and CC pseudos.  Unwind upper halves and full GPRs as appropriate.
4232         Handle varying pseudo register numbers.
4233         (s390_unwind_pc): Handle varying pseudo register numbers.
4234         (s390_dwarf2_prev_register): New function.
4235         (s390_dwarf2_frame_init_reg): Set up ABI call-saved/clobbered
4236         register information.  Handle varying pseudo register numbers.
4237         Install s390_dwarf2_prev_register to unwind full GPRs.
4238         (s390_gdbarch_init): Handle target descriptions.  Assign varying
4239         pseudo register numbers.  Install s390_adjust_frame_regnum.
4240         (_initialize_s390_tdep): Initialize target descriptions.
4241
4242         * s390-tdep.h (S390_R0_UPPER_REGNUM .. S390_R15_UPPER_REGNUM): Define.
4243         (S390_NUM_REGS): Redefine to include upper half registers.
4244         (S390_PC_REGNUM, S390_CC_REGNUM): Remove.
4245         (S390_NUM_PSEUDO_REGS, S390_NUM_TOTAL_REGS): Likewise.
4246         (tdesc_s390_linux32): Add declaration.
4247         (tdesc_s390_linux64): Likewise.
4248         (tdesc_s390x_linux64): Likewise.
4249
4250 2010-01-04  Ulrich Weigand  <uweigand@de.ibm.com>
4251
4252         * regset.h (struct core_regset_section): Add HUMAN_NAME.
4253         * i386-linux-tdep.c (i386_linux_regset_sections): Fill in HUMAN_NAME.
4254         * ppc-linux-tdep.c (ppc_linux_vsx_regset_sections): Likewise.
4255         (ppc_linux_vmx_regset_sections): Likewise.
4256         (ppc_linux_fp_regset_sections): Likewise.
4257
4258         * corelow.c (get_core_register_section): Constify arguments.
4259         (get_core_registers): Use gdbarch_core_regset_sections instead
4260         of hard-coded platform-specific register section names.
4261
4262 2010-01-04  Ulrich Weigand  <uweigand@de.ibm.com>
4263
4264         * dwarf2loc.c (read_pieced_value): If a piece occupies part of
4265         a register, assume the least-significant part is used.
4266         (write_pieced_value): Likewise.
4267
4268 2010-01-04  Ulrich Weigand  <uweigand@de.ibm.com>
4269
4270         * printcmd.c: Include "arch-utils.h".
4271         (do_one_display): Re-parse expression if current architecture changed.
4272
4273 2010-01-03  Jan Kratochvil  <jan.kratochvil@redhat.com>
4274             Joel Brobecker  <brobecker@adacore.com>
4275
4276         * gdbtypes.c (check_typedef): New comment on type length.
4277         * value.c (allocate_value_lazy): Remove the unused atype variable.  New
4278         comment on type length.
4279         (value_primitive_field): Keep the original TYPE value, new comment.
4280
4281 2010-01-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
4282
4283         * cli/cli-script.c (process_next_line): Rename p1 as p_end and p2 as
4284         p_start.  Change != comparisons to > and < comparisons.
4285
4286 2010-01-01  Jan Kratochvil  <jan.kratochvil@redhat.com>
4287
4288         * cli/cli-script.c (process_next_line): Check P2 overrun.
4289
4290 2009-01-01  Joel Brobecker  <brobecker@adacore.com>
4291
4292         Update the copyright hearder to add year 2010 for most GDB files.
4293
4294 2009-01-01  Joel Brobecker  <brobecker@adacore.com>
4295
4296         Fix build failure in inf-ptrace.c.
4297         * inf-ptrace.c (inf_ptrace_follow_fork): Fix typo.
4298
4299 2010-01-01  Joel Brobecker  <brobecker@adacore.com>
4300
4301         * top.c (print_gdb_version): Update copyright year.
4302
4303 2010-01-01  Joel Brobecker  <brobecker@adacore.com>
4304
4305         Fix break *FUN'address thread NUM.
4306         * ada-lex.l (task): Expand rule to also match the thread keyword.
4307
4308 2010-01-01  Joel Brobecker  <brobecker@adacore.com>
4309
4310         Fix break *FUN'address task NUM.
4311         * ada-lex.l (task): New rule.
4312         * ada-lang.c (valid_task_id): Make sure the Ada task list has
4313         been built before using it.
4314
4315 For older changes see ChangeLog-2009.
4316 \f
4317 Local Variables:
4318 mode: change-log
4319 left-margin: 8
4320 fill-column: 74
4321 version-control: never
4322 coding: utf-8
4323 End: