aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2011-07-22merge from gccDJ Delorie8-19/+134
2011-07-222011-07-22 Phil Muldoon <pmuldoon@redhat.com>Phil Muldoon7-59/+170
* event-top.c (cli_command_loop): Use get_prompt, get_suffix, get_prefix. (display_gdb_prompt): Likewise. (change_annotation_level): Likewise. (push_prompt): Likewise. (pop_prompt): Likewise. (handle_stop_sig): Use get_prompt with a level. * top.c (command_loop): Use get_prompt with a level. (set_async_annotation_level): Use set_prompt with a level. (get_prefix): New function. (set_prefix): Ditto. (set_suffix): Ditto. (get_suffix): Ditto. (get_prompt): Accept a level argument. (set_prompt): Accept a level argument. Free old prompts. Set new_async_prompt if level is 0. (init_main): Use set_prompt with a level. Do not set new_async_prompt. * event-top.h (PROMPT, SUFFIX, PREFIX): Move to top.c * top.h: Declare set_suffix, get_suffix, set_prefix, get_prefix. Modify set_prompt, get_prompt to account for levels. * tui/tui-interp.c (tui_command_loop): Use get_prompt with a level * python/python.c (before_prompt_hook): Use set_prompt.
2011-07-22* gdb.threads/Makefile.in: Avoid globbing corethreads.expmatt rice2-1/+7
in mostlyclean rule. Add files ending in .core.
2011-07-22daily updateAlan Modra1-1/+1
2011-07-22*** empty log message ***gdbadmin1-1/+1
2011-07-212011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>Kwok Yeung49-1321/+1759
gdb/ * defs.h: Add guard against inclusion in gdbserver. (struct ptid, ptid_t): Move to common/ptid.h. (xfree, xzalloc, xasprintf, xvasprintf, xstrprintf, xstrvprintf, xsnprintf, internal_error): Move to common/common-utils.h. (nomem): Delete. * gdb_assert.h: Move into common/ sub-directory. * gdb_locale.h: Ditto. * gdb_dirent.h: Ditto. * inferior.h (minus_one_ptid, null_ptid, ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid): Move into common/ptid.h. * xml-support.c (xml_escape_text): Move into common/xml-utils.c. (gdb_xml_create_parser_and_cleanup_1, xml_fetch_context_from_file): Change nomem to malloc_failure. * xml-support.h (xml_escape_text): Move into common/xml-utils.h. * utils.c (nomem): Rename to malloc_failure. (xmalloc, xzalloc, xrealloc, xcalloc, xfree, xstrprintf, xasprintf, xvasprintf, xstrvprintf, xsnprintf): Move to common/common-utils.c. (gdb_buildargv): Change nomem to malloc_failure. * infrun.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid): Move into common/ptid.c. (initialize_infrun): Delete initialization of null_ptid and minus_one_ptid. * linux-nat.c (linux_nat_xfer_osdata): Defer to linux_common_xfer_osdata. * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c, common/ptid.c and common/buffer.c. (HFILES_NO_SRCDIR): Add common/common-utils.h, common/xml-utils.h, common/ptid.h, common/buffer.h and common/linux-osdata.h. (COMMON_OBS): Add xml-utils.o, common-utils.o, buffer.o and ptid.o. (common-utils.o, xml-utils.o, ptid.o, buffer.o, linux-osdata.o): New rules. * common/gdb_assert.h: New. * common/gdb_dirent.h: New. * common/gdb_locale.h: New. * common/buffer.c: New. * common/buffer.h: New. * common/ptid.c: New. * common/ptid.h: New. * common/xml-utils.c: New. * common/xml-utils.h: New. * common/common-utils.c: New. * common/common-utils.h: New. * common/linux-osdata.c: New. * common/linux-osdata.h: New. * config/alpha/alpha-linux.mh (NATDEPFILES): Add linux-osdata.o. * config/arm/linux.mh (NATDEPFILES): Ditto. * config/i386/linux.mh (NATDEPFILES): Ditto. * config/i386/linux64.mh (NATDEPFILES): Ditto. * config/ia64/linux.mh (NATDEPFILES): Ditto. * config/m32r/linux.mh (NATDEPFILES): Ditto. * config/m68k/linux.mh (NATDEPFILES): Ditto. * config/mips/linux.mh (NATDEPFILES): Ditto. * config/pa/linux.mh (NATDEPFILES): Ditto. * config/powerpc/linux.mh (NATDEPFILES): Ditto. * config/powerpc/ppc64-linux.mh (NATDEPFILES): Ditto. * config/s390/s390.mh (NATDEPFILES): Ditto. * config/sparc/linux.mh (NATDEPFILES): Ditto. * config/sparc/linux64.mh (NATDEPFILES): Ditto. * config/xtensa/linux.mh (NATDEPFILES): Ditto. gdbserver/ * linux-low.c (compare_ints, unique, list_threads, show_process, linux_core_of_thread): Delete. (linux_target_ops): Change linux_core_of_thread to linux_common_core_of_thread. (linux_qxfer_osdata): Defer to linux_common_xfer_osdata. * utils.c (malloc_failure): Change type of argument. (xmalloc, xrealloc, xcalloc, xsnprintf): Delete. * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c, common/linux-osdata.c, common/ptid.c and common/buffer.c. (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o. (IPA_OBJS): Add common-utils-ipa.o. (ptid_h, linux_osdata_h): New macros. (server_h): Add common/common-utils.h, common/xml-utils.h, common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and common/ptid.h. (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o): New rules. (linux-low.o): Add common/linux-osdata.h as a dependency. * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets. * configure.ac: Add AC_HEADER_DIRENT check. * config.in: Regenerate. * configure: Regenerate. * remote-utils.c (xml_escape_text): Delete. (buffer_grow, buffer_free, buffer_init, buffer_finish, buffer_xml_printf): Move to common/buffer.c. * server.c (main): Remove call to initialize_inferiors. * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid, ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text, internal_error, gdb_assert, gdb_assert_fail): Delete. (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish, buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to common/buffer.h. * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid, initialize_inferiors): Delete.
2011-07-21* NEWS: Add info macros and info definitions commands.matt rice2-0/+6
2011-07-21 2011-07-21 Phil Muldoon <pmuldoon@redhat.com>Phil Muldoon2-4/+13
* NEWS: Document Python prompt substitution hook.
2011-07-21PR macros/12999matt rice10-29/+439
* macrotab.h (macro_callback_fn): Add new arguments to callback. * macrotab.c (foreach_macro): Ditto. (foreach_macro_in_scope): Ditto. * macrocmd.c (print_macro_callback): New function. (info_macro_command): Move some code to print_macro_definition. (print_macro_definition): New function. (print_one_macro): Add new arguments to callback. testsuite/ * gdb.base/info-macros.c: New test sources. * gdb.base/info-macros.exp: New tests. docs/ * gdb.texinfo (Macros): Add info definitions and info macros commands. Update text and cindex entries for info macro command.
2011-07-212011-07-21 Phil Muldoon <pmuldoon@redhat.com>Phil Muldoon10-25/+258
Tom Tromey <tromey@redhat.com> * top.c (set_prompt): Rewrite to free previous prompt, free asynch_new_prompt and set both on new prompts. * event-top.c (display_gdb_prompt): Add prompt substitution logic. * python/python.c (before_prompt_hook): New function. 2011-07-21 Phil Muldoon <pmuldoon@redhat.com> * gdb.python/python.exp: Add prompt substitution tests. 2011-07-21 Phil Muldoon <pmuldoon@redhat.com> * observer.texi (GDB Observers): Add before_prompt observer. * gdb.texinfo (Basic Python): Add documentation for prompt substitution.
2011-07-21*** empty log message ***gdbadmin1-1/+1
2011-07-21daily updateAlan Modra1-1/+1
2011-07-20bfd/Jan Kratochvil3-2/+40
Fix false coff-go32-exe matches. * coff-i386.c (TARGET_SYM) <_bfd_check_format>: Conditionally use COFF_CHECK_FORMAT. * coff-stgo32.c (go32_check_format): New forward declaration. (COFF_CHECK_FORMAT): New defintion. (go32_check_format): New function.
2011-07-20* bfin-tdep.c (bfin_extract_return_value): Fix swappedmatt rice2-1/+6
arguments to store_unsigned_integer.
2011-07-20 * dwarf2read.c (process_enumeration_scope): Do not call new_symbolTom Tromey2-0/+31
in some declaration-only cases.
2011-07-20 PR symtab/12984:Tom Tromey2-118/+201
* dwarf2read.c (dwarf2_section_info_def): New typedef. (struct dwarf2_per_objfile) <types>: Change to a VEC. (struct dwarf2_per_cu_data) <from_debug_types>: Remove. <debug_type_section>: New field. (dwarf2_locate_sections): Push .debug_types sections onto VEC. (load_cu): Use appropriate section. (create_signatured_type_table_from_index): Add 'section' argument. (dwarf2_read_index): Only allow a single .debug_types section. (dw2_get_file_names): Use appropriate section. (read_type_comp_unit_head): Add 'section' argument. (create_debug_types_hash_table): Loop over all .debug_types sections. (init_cu_die_reader): Use appropriate section. (process_psymtab_comp_unit, load_partial_comp_unit) (load_full_comp_unit, read_die_and_children, find_partial_die) (lookup_die_type, determine_prefix, follow_die_offset): Update. (lookup_signatured_type_at_offset): Add 'section' argument. (read_signatured_type_at_offset): Add 'sect' argument. (read_signatured_type): Use appropriate section. (set_die_type, get_die_type_at_offset): Update. (dwarf2_per_objfile_free): Free all .debug_types sections, and VEC. (write_psymtabs_to_index): Don't allow index with more than one .debug_types section.
2011-07-202011-07-20 Pedro Alves <pedro@codesourcery.com>Pedro Alves2-4/+7
* tracepoint.c (tracepoint_look_up_symbols): Return upon the first symbol error.
2011-07-20daily updateAlan Modra1-1/+1
2011-07-20*** empty log message ***gdbadmin1-1/+1
2011-07-19gdb/Jan Kratochvil6-8/+77
Fix crash if referenced CU is aged out. * dwarf2loc.c (per_cu_dwarf_call): New variable back_to, use to for xfree of block.data. (indirect_pieced_value): New variable back_to, use to for xfree of baton.data. (dwarf2_compile_expr_to_ax): New variable back_to, use to for xfree of block.data. * dwarf2read.c (dwarf2_find_base_address): New prototype. (load_cu): New function from ... (dw2_do_instantiate_symtab): ... the code here ... (process_full_comp_unit): ... and here. (dwarf2_fetch_die_location_block): Call load_cu first. Call xmemdup on retval.data. gdb/testsuite/ Fix crash if referenced CU is aged out. * gdb.dwarf2/dw2-op-call.exp (maintenance set dwarf2 max-cache-age 0): New. * gdb.dwarf2/implptr.exp: Likewise.
2011-07-19gdb/Jan Kratochvil6-225/+290
* dwarf2loc.c (indirect_pieced_value): Use check_typedef for VALUE's type. gdb/testsuite/ * gdb.dwarf2/implptr.S: Rebuilt. * gdb.dwarf2/implptr.c (intp, intpp, intppp): New typedefs. (bar): Use them for j, k, l. * gdb.dwarf2/implptr.exp: New variable opts. Support runtest parameter COMPILE. (print j in implptr:bar): Update for the intp typedef. (print p[0].x in implptr:foo): Use more exact regex.
2011-07-19gdb/Gary Benson2-9/+48
* infrun.c (struct execution_control_state): New member stop_func_filled_in. (clear_stop_func, fill_in_stop_func): New functions. (handle_inferior_event): Call clear_stop_func rather than manipulating the execution control state directly. Call fill_in_stop_func lazily as required rather than directly calling find_pc_partial_function in all cases.
2011-07-19*** empty log message ***gdbadmin1-1/+1
2011-07-19daily updateAlan Modra1-1/+1
2011-07-18 * dwarf2read.c (read_subrange_type): Use attr_form_is_block whenTom Tromey2-2/+7
checking for variable-sized array.
2011-07-18 * gdb.cp/static-method.exp: Add missing single quote.Tom Tromey2-1/+5
2011-07-18Fix a typo in doc/c-i386.texi.H.J. Lu2-1/+5
2011-07-18 H.J. Lu <hongjiu.lu@intel.com> * doc/c-i386.texi: Fix a typo.
2011-07-18 toplevel:Rainer Orth4-3/+11
* configure: Regenerate. config: * elf.m4 (target_elf): Remove *-netware*.
2011-07-18gdb/Jean-Charles Delay1-0/+1
* MAINTAINERS (Write After Approval): Add myself to the list.
2011-07-18gdb/Jean-Charles Delay3-2/+96
* varobj.h (varobj_languages): Add vlang_ada definition to the list of supported languages. * varobj.c: Add top definitions and basic implementation of the following callbacks: ada_number_of_children, ada_name_of_variable, ada_name_of_child, ada_path_expr_of_child, ada_value_of_root, ada_value_of_child, ada_type_of_child, ada_value_of_variable. (languages): Register Ada-specific callbacks. (variable_language): Add the Ada case in the language setter switch.
2011-07-18 gdb/testsuite/Yao Qi9-0/+54
* gdb.base/async-shell.exp: Skip test if displaced stepping is not supported. * gdb.mi/mi-nonstop-exit.exp: Likewise. * gdb.mi/mi-nonstop.exp: Likewise. * gdb.mi/mi-ns-stale-regcache.exp: Likewise. * gdb.mi/mi-nsintrall.exp: Likewise. * gdb.mi/mi-nsmoribund.exp: Likewise. * gdb.mi/mi-nsthrexec.exp: Likewise. * gdb.python/py-evthreads.exp: Likewise.
2011-07-18*** empty log message ***gdbadmin1-1/+1
2011-07-18daily updateAlan Modra1-1/+1
2011-07-17gdb/Jan Kratochvil2-1/+11
* remote-mips.c (pmon_download): Fix ignored return value GCC warning.
2011-07-17daily updateAlan Modra1-1/+1
2011-07-17*** empty log message ***gdbadmin1-1/+1
2011-07-16Implement ld --print-output-format.Roland McGrath6-2/+32
2011-07-16daily updateAlan Modra1-1/+1
2011-07-16*** empty log message ***gdbadmin1-1/+1
2011-07-15 * options.h (class General_options): Add --print-output-format.Ian Lance Taylor8-6/+138
Move -EL next to -EB, for better --help output. * target-select.cc: Include <cstdio>, "options.h", and "parameters.h". (Target_selector::do_target_bfd_name): New function. (print_output_format): New function. * target-select.h (class Target_selector): Update declarations. (Target_selector::target_bfd_name): New function. (print_output_format): Declare. * main.cc: Include "target-select.h". (main): Handle --print-output-format. * gold.cc: Include "target-select.h". (queue_initial_tasks): Handle --print-output-format when there are no input files. * parameters.cc (parameters_force_valid_target): Give a better error message if -EB/-EL does not match target. * freebsd.h (Target_selector_freebsd::do_target_bfd_name): New function.
2011-07-15gdb/Jan Kratochvil5-78/+127
Code cleanup. * dwarf2-frame.c (dwarf2_frame_ctx_funcs): New. (execute_stack_op): Use dwarf2_frame_ctx_funcs * dwarf2expr.c (dwarf_get_base_type): Access get_base_type via funcs. (execute_stack_op): Access read_reg, get_frame_base, read_mem, get_frame_cfa, get_tls_address and dwarf_call via funcs. * dwarf2expr.h (struct dwarf_expr_context): New forward declaration. (struct dwarf_expr_context_funcs): New, move here methods from ... (struct dwarf_expr_context): ... here. New fields funcs. * dwarf2loc.c (dwarf_expr_dwarf_call): Access get_frame_pc via funcs. (dwarf_expr_ctx_funcs): New. (dwarf2_evaluate_loc_desc_full): Use dwarf_expr_ctx_funcs. (needs_frame_dwarf_call): Access get_frame_pc via funcs. (needs_frame_ctx_funcs): New. (dwarf2_loc_desc_needs_frame): Use needs_frame_ctx_funcs.
2011-07-15gdb/testsuite/Jan Kratochvil2-22/+18
Code cleanup. * gdb.cp/namespace.exp (xfail_class_types): New variable. Initialize it. Substitute it instead of test_compiler_info everywhere.
2011-07-15 * i386.cc (class Output_data_plt_i386): Add layout_ field.Ian Lance Taylor4-13/+55
(Output_data_plt_i386::Output_data_plt_i386): Initialize layout_. (Output_data_plt_i386::do_write): Write address of .dynamic section to first entry in .got.plt section. * x86_64.cc (class Output_data_plt_x86_64): Add layout_ field. (Output_data_plt_x86_64::Output_data_plt_x86_64) [both versions]: Initialize layout_. (Output_data_plt_x86_64::do_write): Write address of .dynamic section to first entry in .got.plt section. * layout.h (Layout::dynamic_section): New function.
2011-07-152011-07-15 Fawzi Mohamed <fawzi.mohamed@nokia.com>Fawzi Mohamed2-0/+5
* MAINTAINERS (Write After Approval): Add myself to the list.
2011-07-152011-07-15 Fawzi Mohamed <fawzi.mohamed@nokia.com>Fawzi Mohamed2-16/+94
* dwarf2-frame.c (decode_frame_entry, decode_frame_entry_1): Ensure that CIE pointer of an FDE really points to a CIE .
2011-07-15 * gdb.base/type-opaque.exp: Use gdb_load_shlibs. Run test onUlrich Weigand2-6/+6
remote targets as well.
2011-07-15 * lib/gdb.exp (gdb_compile_shlib_pthreads): New helper.Ulrich Weigand3-41/+45
* gdb.threads/tls-shared.exp: Use it. Call gdb_load_shlibs.
2011-07-15 * lib/gdb.exp (gdb_compile): Specify rpath if the *target* isUlrich Weigand2-2/+18
a remote machine, not the host. (gdb_compile_shlib): Set soname if target is remote.
2011-07-15include/Alan Modra5-99/+110
* bfdlink.h (struct bfd_link_info): Use ENUM_BITFIELD for strip, discard, common_skip_ar_symbols, unresolved_syms_in_objects, and unresolved_syms_in_shared_libs fields. Move emit_note_gnu_build_id out of bitfields. Reorder bitfields. bfd/ * configure.in: Bump version. * configure: Regenerate.
2011-07-152011-07-15 Hui Zhu <teawater@gmail.com>Hui Zhu2-0/+5
* remote.c (remote_get_trace_status): Add comments.