Doug Evans [Tue, 10 Jul 2012 20:28:32 +0000 (20:28 +0000)]
PR gdb/13498
* dwarf2read.c (dwarf2_per_objfile): New members n_type_unit_groups,
all_type_unit_groups, type_unit_groups, tu_stats.
(dwarf2_per_cu_data): Move "imported_symtabs" into new union "s".
All uses updated. Add type_unit_group to union "s".
(type_unit_group): New struct.
(IS_TYPE_UNIT_GROUP): New macro.
(abbrev_table): Delete unused member "section".
(dw2_do_instantiate_symtab): Early exit if type_unit_group.
(dw2_get_cu): Assert not used with type_unit_group.
(dw2_get_primary_cu): New function.
(dw2_build_type_unit_groups_reader): New function.
(dw2_build_type_unit_groups): New function.
(dw2_get_file_names): Assert not called on type units.
(dw2_map_symtabs_matching_filename): Call dw2_build_type_unit_groups.
Redo loop to iterate over type unit groups instead of type units.
(dw2_expand_symtabs_matching, dw2_map_symbol_filenames): Ditto.
(read_abbrev_offset): New function.
(init_cutu_and_read_dies): New arg "abbrev_table". All callers
updated.
(create_partial_symtab): New function.
(process_psymtab_comp_unit_reader): Assert not used with type units.
Call create_partial_symtab.
(process_psymtab_type_unit): Delete.
(hash_type_unit_group, eq_type_unit_group): New functions.
(allocate_type_unit_groups_table): New function.
(NO_STMT_LIST_TYPE_UNIT_PSYMTAB): New macro.
(NO_STMT_LIST_TYPE_UNIT_PSYMTAB_SIZE): New macro.
(create_type_unit_group, get_type_unit_group): New functions.
(tu_abbrev_offset): New struct.
(sort_tu_by_abbrev_offset): New function.
(add_type_unit_group_to_table): New function.
(build_type_unit_groups): New function.
(build_type_psymtabs_reader): New function.
(build_type_psymtab_dependencies): New function.
(build_type_psymtabs): Rewrite.
(scan_partial_symbols): Flag an error if a DW_TAG_imported_unit
is seen in a type unit.
(process_queue): Move symtab expansion debugging printfs here.
Call process_full_type_unit for type units.
(compute_symtab_includes): Assert not called for type units.
(process_cu_includes): Don't call compute_symtab_includes for
type units.
(process_full_type_unit): New function.
(process_imported_unit_die): Flag an error if called for type units.
(handle_DW_AT_stmt_list): Delete arg "want_line_info". All callers
updated. Assert not called for type units.
(read_file_scope): Call dwarf2_start_symtab.
(setup_type_unit_groups): New function.
(read_type_unit_scope): Rewrite.
(abbrev_table_read_table): Initialize abbrev_table->offset.
(abbrev_table_free_cleanup): New function.
(dwarf2_start_symtab): New function.
(load_full_type_unit): Assert not called for type unit groups.
Doug Evans [Tue, 10 Jul 2012 20:20:15 +0000 (20:20 +0000)]
* buildsym.c (finish_block_internal): New arg "expandable".
All callers updated.
(start_symtab): Move most contents to ...
(restart_symtab): ... here. New function.
(reset_symtab_globals): New function.
(end_symtab_1): Renamed from end_symtab. New arg "expandable".
Call reset_symtab_globals.
(end_symtab, end_expandable_symtab): New functions.
(set_missing_symtab, augment_type_symtab): New functions.
* buildsym.h (end_expandable_symtab): Declare.
(augment_type_symtab, restart_symtab): Declare.
Doug Evans [Tue, 10 Jul 2012 20:17:30 +0000 (20:17 +0000)]
* psympriv.h (struct partial_symtab): New member "anonymous".
* psymtab.c (partial_map_symtabs_matching_filename): Ignore
anonymous psymtabs.
(read_psymtabs_with_filename): Ditto.
(map_symbol_filenames_psymtab, psymtab_to_fullname): Ditto.
(expand_symtabs_matching_via_partial): Ditto.
(dump_psymtab): Update.
Doug Evans [Tue, 10 Jul 2012 20:12:49 +0000 (20:12 +0000)]
* dictionary.c (dict_add_pending): New function.
* dictionary.h (dict_add_pending): Declare.
Tom Tromey [Tue, 10 Jul 2012 15:32:52 +0000 (15:32 +0000)]
* gdb.mi/dw2-ref-missing-frame.exp: Use standard_testfile,
standard_output_file.
* gdb.mi/gdb2549.exp: Use standard_testfile.
* gdb.mi/gdb669.exp: Use standard_testfile.
* gdb.mi/gdb701.exp: Use standard_testfile.
* gdb.mi/gdb792.exp: Use standard_testfile.
* gdb.mi/mi-async.exp: Use standard_testfile.
* gdb.mi/mi-basics.exp: Use standard_testfile.
* gdb.mi/mi-break.exp: Use standard_testfile.
* gdb.mi/mi-cli.exp: Use standard_testfile.
* gdb.mi/mi-console.exp: Use standard_testfile.
* gdb.mi/mi-disassemble.exp: Use standard_testfile.
* gdb.mi/mi-eval.exp: Use standard_testfile.
* gdb.mi/mi-file-transfer.exp: Use standard_testfile.
* gdb.mi/mi-file.exp: Use standard_testfile.
* gdb.mi/mi-inheritance-syntax-error.exp: Use standard_testfile.
* gdb.mi/mi-logging.exp: Use standard_testfile.
* gdb.mi/mi-nonstop-exit.exp: Use standard_testfile.
* gdb.mi/mi-nonstop.exp: Use standard_testfile.
* gdb.mi/mi-ns-stale-regcache.exp: Use standard_testfile.
* gdb.mi/mi-nsintrall.exp: Use standard_testfile.
* gdb.mi/mi-nsmoribund.exp: Use standard_testfile.
* gdb.mi/mi-nsthrexec.exp: Use standard_testfile.
* gdb.mi/mi-pending.exp: Use standard_testfile,
standard_output_file.
* gdb.mi/mi-pthreads.exp: Use standard_testfile.
* gdb.mi/mi-read-memory.exp: Use standard_testfile.
* gdb.mi/mi-regs.exp: Use standard_testfile.
* gdb.mi/mi-return.exp: Use standard_testfile.
* gdb.mi/mi-reverse.exp: Use standard_testfile.
* gdb.mi/mi-simplerun.exp: Use standard_testfile.
* gdb.mi/mi-solib.exp: Use standard_testfile,
standard_output_file.
* gdb.mi/mi-stack.exp: Use standard_testfile.
* gdb.mi/mi-stepi.exp: Use standard_testfile.
* gdb.mi/mi-stepn.exp: Use standard_testfile.
* gdb.mi/mi-syn-frame.exp: Use standard_testfile.
* gdb.mi/mi-until.exp: Use standard_testfile.
* gdb.mi/mi-var-block.exp: Use standard_testfile.
* gdb.mi/mi-var-child-f.exp: Use standard_testfile.
* gdb.mi/mi-var-child.exp: Use standard_testfile.
* gdb.mi/mi-var-cmd.exp: Use standard_testfile.
* gdb.mi/mi-var-cp.exp: Use standard_testfile.
* gdb.mi/mi-var-display.exp: Use standard_testfile.
* gdb.mi/mi-var-invalidate.exp: Use standard_testfile,
standard_output_file.
* gdb.mi/mi-var-rtti.exp: Use standard_testfile.
* gdb.mi/mi-watch-nonstop.exp: Use standard_testfile.
* gdb.mi/mi-watch.exp: Use standard_testfile.
* gdb.mi/mi2-amd64-entry-value.exp: Use standard_testfile.
* gdb.mi/mi2-basics.exp: Use standard_testfile.
* gdb.mi/mi2-break.exp: Use standard_testfile.
* gdb.mi/mi2-cli.exp: Use standard_testfile.
* gdb.mi/mi2-console.exp: Use standard_testfile.
* gdb.mi/mi2-disassemble.exp: Use standard_testfile.
* gdb.mi/mi2-eval.exp: Use standard_testfile.
* gdb.mi/mi2-file.exp: Use standard_testfile.
* gdb.mi/mi2-pthreads.exp: Use standard_testfile.
* gdb.mi/mi2-read-memory.exp: Use standard_testfile.
* gdb.mi/mi2-regs.exp: Use standard_testfile.
* gdb.mi/mi2-return.exp: Use standard_testfile.
* gdb.mi/mi2-simplerun.exp: Use standard_testfile.
* gdb.mi/mi2-stack.exp: Use standard_testfile.
* gdb.mi/mi2-stepi.exp: Use standard_testfile.
* gdb.mi/mi2-syn-frame.exp: Use standard_testfile.
* gdb.mi/mi2-until.exp: Use standard_testfile.
* gdb.mi/mi2-var-block.exp: Use standard_testfile.
* gdb.mi/mi2-var-child.exp: Use standard_testfile.
* gdb.mi/mi2-var-cmd.exp: Use standard_testfile.
* gdb.mi/mi2-var-display.exp: Use standard_testfile.
* gdb.mi/mi2-watch.exp: Use standard_testfile.
Tom Tromey [Tue, 10 Jul 2012 15:18:18 +0000 (15:18 +0000)]
* gdb.cp/abstract-origin.exp: Use standard_testfile.
* gdb.cp/ambiguous.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/annota2.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/annota3.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/anon-ns.exp: Use standard_testfile.
* gdb.cp/anon-struct.exp: Use standard_testfile.
* gdb.cp/anon-union.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/arg-reference.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/bool.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/breakpoint.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/bs15503.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/call-c.exp: Use standard_testfile, clean_restart,
standard_output_file.
* gdb.cp/casts.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/class2.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/classes.exp: Use standard_testfile, prepare_for_testing.
(test_static_members): Update.
* gdb.cp/cmpd-minsyms.exp: Use standard_testfile.
* gdb.cp/converts.exp: Use standard_testfile.
* gdb.cp/cp-relocate.exp: Use standard_testfile.
* gdb.cp/cpcompletion.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/cpexprs.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/cplabel.exp: Use standard_testfile.
* gdb.cp/cplusfuncs.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/ctti.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/derivation.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/destrprint.exp: Use standard_testfile.
* gdb.cp/dispcxx.exp: Use standard_testfile.
* gdb.cp/exception.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/expand-psymtabs-cxx.exp: Use standard_testfile.
* gdb.cp/extern-c.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/formatted-ref.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/fpointer.exp: Use standard_testfile.
* gdb.cp/gdb1355.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/gdb2384.exp: Use standard_testfile, clean_restart,
standard_output_file.
* gdb.cp/gdb2495.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/hang.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/infcall-dlopen.exp: Use standard_testfile,
standard_output_file.
* gdb.cp/inherit.exp: Use standard_testfile, prepare_for_testing.
(do_tests): Update.
* gdb.cp/koenig.exp: Use standard_testfile.
* gdb.cp/local.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/m-data.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/m-static.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/mb-ctor.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/mb-inline.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/mb-templates.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/member-ptr.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/meth-typedefs.exp: Use standard_testfile.
* gdb.cp/method.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/method2.exp: Use standard_testfile.
* gdb.cp/minsym-fallback.exp: Use standard_testfile,
standard_output_file.
* gdb.cp/misc.exp: Use standard_testfile, prepare_for_testing.
(do_tests): Update.
* gdb.cp/namespace-enum.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/namespace-nested-import.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/namespace.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/nextoverthrow.exp: Use standard_testfile.
* gdb.cp/no-dmgl-verbose.exp: Use standard_testfile.
* gdb.cp/nsdecl.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/nsimport.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/nsnested.exp: Use standard_testfile.
* gdb.cp/nsnoimports.exp: Use standard_testfile.
* gdb.cp/nsrecurs.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/nsstress.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/nsusing.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/operator.exp: Use standard_testfile.
* gdb.cp/oranking.exp: Use standard_testfile.
* gdb.cp/overload-const.exp: Use standard_testfile.
* gdb.cp/overload.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/ovldbreak.exp: Use standard_testfile.
* gdb.cp/ovsrch.exp: Use standard_testfile.
* gdb.cp/paren-type.exp: Use standard_testfile.
* gdb.cp/pass-by-ref.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/pr-1023.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/pr-1210.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/pr-574.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/pr10687.exp: Use standard_testfile, clean_restart.
* gdb.cp/pr10728.exp: Use standard_testfile,
standard_output_file.
* gdb.cp/pr12028.exp: Use standard_testfile.
* gdb.cp/pr9067.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/pr9167.exp: Use standard_testfile.
* gdb.cp/pr9631.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/printmethod.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/psmang.exp: Use standard_testfile, clean_restart.
* gdb.cp/psymtab-parameter.exp: Use standard_testfile.
* gdb.cp/ptype-cv-cp.exp: Use standard_testfile.
* gdb.cp/re-set-overloaded.exp: Use standard_testfile,
standard_output_file.
* gdb.cp/readnow-language.exp: Use standard_testfile.
* gdb.cp/ref-params.exp: Use standard_testfile, build_executable.
(gdb_start_again): Use clean_restart.
* gdb.cp/ref-types.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/rtti.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/shadow.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/smartp.exp: Use standard_testfile.
* gdb.cp/static-method.exp: Use standard_testfile.
* gdb.cp/static-print-quit.exp: Use standard_testfile.
* gdb.cp/temargs.exp: Use standard_testfile.
* gdb.cp/templates.exp: Use standard_testfile,
prepare_for_testing.
(do_tests): Update.
* gdb.cp/try_catch.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/typedef-operator.exp: Use standard_testfile.
* gdb.cp/userdef.exp: Use standard_testfile, prepare_for_testing.
* gdb.cp/virtbase.exp: Use standard_testfile,
prepare_for_testing.
* gdb.cp/virtfunc.exp: Use standard_testfile,
prepare_for_testing.
(do_tests): Update.
* gdb.cp/virtfunc2.exp: Use standard_testfile,
prepare_for_testing.
Ian Lance Taylor [Tue, 10 Jul 2012 14:54:29 +0000 (14:54 +0000)]
PR gold/14309
* configure.ac: Test whether std::tr1::hash<off_t> works.
* gold.h: Add a specialization for std::tr1::hash<off_t> if
needed.
* output.h (class Output_fill): Add virtual destructor.
* configure, config.in: Rebuild.
Tom Tromey [Tue, 10 Jul 2012 14:41:16 +0000 (14:41 +0000)]
* lib/gdb.exp (standard_testfile): Unset output variables from
earlier invocations.
H.J. Lu [Tue, 10 Jul 2012 06:50:57 +0000 (06:50 +0000)]
Add SORT_NONE and don't sort sort .init/.fini sections
ld/
PR ld/14156
* NEWS: Mention SORT_NONE.
* ld.h (sort_type): Add by_none.
* ld.texinfo: Document SORT_NONE.
* ldgram.y: Handle SORT_NONE.
* ldlang.c (update_wild_statements): Handle by_none. Don't
sort .init/.fini sections.
* ldlex.l: Add SORT_NONE.
ld/testsuite/
PR ld/14156
* ld-elf/fini0.s: New file.
* ld-elf/fini1.s: Likewise.
* ld-elf/fini2.s: Likewise.
* ld-elf/fini3.s: Likewise.
* ld-elf/finin.s: Likewise.
* ld-elf/foo0.s: Likewise.
* ld-elf/foo1.s: Likewise.
* ld-elf/foo2.s: Likewise.
* ld-elf/foo3.s: Likewise.
* ld-elf/foon.s: Likewise.
* ld-elf/init0.s: Likewise.
* ld-elf/init1.s: Likewise.
* ld-elf/init2.s: Likewise.
* ld-elf/init3.s: Likewise.
* ld-elf/initn.s: Likewise.
* ld-elf/pr14156a.d: Likewise.
* ld-elf/pr14156b.d: Likewise.
* ld-elf/pr14156c.d: Likewise.
* ld-elf/pr14156c.t: Likewise.
H.J. Lu [Tue, 10 Jul 2012 04:51:53 +0000 (04:51 +0000)]
Add testcases for PR ld/14323
PR ld/14323
* ld-elf/pr14323-1.c: New.
* ld-elf/pr14323-2.c: Likewise.
* ld-elf/shared.exp (build_tests): Add libpr14323-2.so.
(run_tests): Add pr14323.
Doug Evans [Tue, 10 Jul 2012 03:49:25 +0000 (03:49 +0000)]
* buildsym.c (start_subfile): Remove unnecessary check for
name == NULL.
Doug Evans [Tue, 10 Jul 2012 01:10:25 +0000 (01:10 +0000)]
* psymtab.c (allocate_psymtab): Use host_address_to_string.
Doug Evans [Tue, 10 Jul 2012 01:05:06 +0000 (01:05 +0000)]
* dwarf2read.c (load_full_type_unit): Simplify.
gdbadmin [Tue, 10 Jul 2012 00:00:33 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Tue, 10 Jul 2012 00:00:03 +0000 (00:00 +0000)]
daily update
Doug Evans [Mon, 9 Jul 2012 20:27:53 +0000 (20:27 +0000)]
* dwarf2read.c (dwarf2_per_objfile): Change type of all_type_units
to struct signatured_type **. All uses updated.
Yao Qi [Mon, 9 Jul 2012 18:28:17 +0000 (18:28 +0000)]
gdb/testsuite:
* gdb.mi/gdb2549.exp: Remove -DFAKEARGV from compilation flags.
* gdb.mi/mi-async.exp, gdb.mi/mi-basics.exp: Likewise.
* gdb.mi/mi-break.exp, gdb.mi/mi-cli.exp: Likewise.
* gdb.mi/mi-console.exp, gdb.mi/mi-disassemble.exp: Likewise.
* gdb.mi/mi-eval.exp, gdb.mi/mi-file.exp: Likewise.
* gdb.mi/mi-read-memory.exp, gdb.mi/mi-regs.exp: Likewise.
* gdb.mi/mi-return.exp, gdb.mi/mi-reverse.exp: Likewise.
* gdb.mi/mi-simplerun.exp, gdb.mi/mi-stack.exp: Likewise.
* gdb.mi/mi-stepi.exp, gdb.mi/mi-syn-frame.exp: Likewise.
* gdb.mi/mi-until.exp, gdb.mi/mi-var-block.exp: Likewise.
* gdb.mi/mi-var-child.exp, gdb.mi/mi-var-cmd.exp: Likewise.
* gdb.mi/mi-var-display.exp: Likewise.
* gdb.mi/mi-var-invalidate.exp: Likewise.
* gdb.mi/mi-watch.exp, gdb.mi/mi2-basics.exp: Likewise.
* gdb.mi/mi2-break.exp, gdb.mi/mi2-cli.exp: Likewise.
* gdb.mi/mi2-console.exp: Likewise.
* gdb.mi/mi2-disassemble.exp: Likewise.
* gdb.mi/mi2-eval.exp, gdb.mi/mi2-file.exp: Likewise.
* gdb.mi/mi2-read-memory.exp: Likewise.
* gdb.mi/mi2-regs.exp, gdb.mi/mi2-return.exp: Likewise.
* gdb.mi/mi2-simplerun.exp: Likewise.
* gdb.mi/mi2-stack.exp, gdb.mi/mi2-stepi.exp: Likewise.
* gdb.mi/mi2-syn-frame.exp: Likewise.
* gdb.mi/mi2-until.exp, gdb.mi/mi2-var-block.exp: Likewise.
* gdb.mi/mi2-var-child.exp, gdb.mi/mi2-var-cmd.exp: Likewise.
* gdb.mi/mi2-var-display.exp, gdb.mi/mi2-watch.exp: Likewise.
Doug Evans [Mon, 9 Jul 2012 18:21:31 +0000 (18:21 +0000)]
* dwarf2read.c (dwarf2_attr_no_follow): Delete unused arg "cu".
All callers updated.
Tom Tromey [Mon, 9 Jul 2012 14:20:52 +0000 (14:20 +0000)]
* c-exp.y (check_parameter_typelist): New function.
(parameter_typelist): Call it.
* eval.c (make_params): Handle '(void)' case.
* gdbtypes.c (lookup_function_type_with_arguments): Handle
'(void)' case.
testsuite
* gdb.base/whatis.exp: Add error checks for improper 'void' uses.
* gdb.base/callfuncs.exp: Add cast-based test.
* gdb.base/callfuncs.c (voidfunc): New function.
Alan Modra [Mon, 9 Jul 2012 08:17:34 +0000 (08:17 +0000)]
PR ld/14323
* elflink.c (elf_sort_symbol): Sort by size too.
(elf_link_add_object_symbols <weakdefs>): Simplify binary search.
Do not depend on ordering of symbol aliases. Match largest size.
Alan Modra [Mon, 9 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
gdbadmin [Mon, 9 Jul 2012 00:00:02 +0000 (00:00 +0000)]
*** empty log message ***
Doug Evans [Sun, 8 Jul 2012 22:34:59 +0000 (22:34 +0000)]
* gdb.dwarf2/dw4-sig-type-unused.S: Fix typo.
gdbadmin [Sun, 8 Jul 2012 00:00:36 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Sun, 8 Jul 2012 00:00:06 +0000 (00:00 +0000)]
daily update
Jan Kratochvil [Sat, 7 Jul 2012 12:13:57 +0000 (12:13 +0000)]
gdb/
* common/linux-ptrace.c: Include gdb_assert.h.
<__i386__> (linux_ptrace_test_ret_to_nx_instr): New declaration.
<__i386__>: Include sys/reg.h, sys/mman.h, signal.h, sys/wait.h and
stdint.h.
(linux_ptrace_test_ret_to_nx, linux_ptrace_init_warnings): New
functions.
* common/linux-ptrace.h (linux_ptrace_init_warnings): New declarations.
* linux-nat.c (linux_child_post_attach)
(linux_child_post_startup_inferior): Call linux_ptrace_init_warnings.
gdb/gdbserver/
* gdbserver/linux-low.c (initialize_low): Call
linux_ptrace_init_warnings.
Jan Kratochvil [Sat, 7 Jul 2012 12:11:31 +0000 (12:11 +0000)]
gdb/
* linux-thread-db.c (thread_db_find_new_threads_silently): Do not apply
nptl <2.7 bug workaround for core files.
Jan Kratochvil [Sat, 7 Jul 2012 12:10:14 +0000 (12:10 +0000)]
gdb/testsuite/
Fix XFAIL compatibility with old i386 systems.
* gdb.base/stale-infcall.exp (test system longjmp tracking support):
Check also 'Cannot insert breakpoint 0'.
Alan Modra [Sat, 7 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
gdbadmin [Sat, 7 Jul 2012 00:00:03 +0000 (00:00 +0000)]
*** empty log message ***
Jan Kratochvil [Fri, 6 Jul 2012 16:52:20 +0000 (16:52 +0000)]
gdb/
* linux-nat.c (resume_lwp, linux_nat_resume): Remove LP->SIGINFO
clearing.
(save_siginfo): Remove.
(stop_wait_callback, linux_nat_filter_event): Remove the save_siginfo
call.
(resume_stopped_resumed_lwps): Remove LP->SIGINFO clearing.
(linux_nat_get_siginfo): Use PTRACE_GETSIGINFO.
* linux-nat.h (struct lwp_info): Remove field siginfo.
Jan Kratochvil [Fri, 6 Jul 2012 16:49:43 +0000 (16:49 +0000)]
gdb/
Code cleanup for the next patch.
* arm-linux-nat.c (arm_linux_stopped_data_address): Change variable
siginfo_p to siginfo, update its users incl. the linux_nat_get_siginfo
call for it.
* ia64-linux-nat.c (ia64_linux_stopped_data_address): Likewise.
(ia64_linux_stopped_data_address):
* linux-nat.c (linux_nat_get_siginfo): Add parameter siginfo, change
the return value.
* linux-nat.h (linux_nat_get_siginfo): Likewise.
* ppc-linux-nat.c (ppc_linux_stopped_data_address): Change variable
siginfo_p to siginfo, update its users incl. the linux_nat_get_siginfo
call for it.
Jan Kratochvil [Fri, 6 Jul 2012 15:51:40 +0000 (15:51 +0000)]
gdb/
PR 14321
* findcmd.c (parse_find_args): New variable pattern_buf_size_need.
Increase buffer sizes to 2x we need, not just 2x of the previous size.
gdb/testsuite/
PR 14321
* gdb.base/find.exp
(find int64_search_buf, +64/8*100, int64_search_buf): New test.
Tom Tromey [Fri, 6 Jul 2012 14:48:48 +0000 (14:48 +0000)]
* c-exp.y (DOTDOTDOT): New token.
(func_mod, exp): Use parameter_typelist.
(parameter_typelist): New production.
(tokentab3): Add "..." token.
* eval.c (make_params): Handle varargs.
* gdbtypes.c (lookup_function_type_with_arguments): Handle
varargs.
testsuite
* gdb.base/whatis.exp: Add test.
Tom Tromey [Fri, 6 Jul 2012 14:47:00 +0000 (14:47 +0000)]
PR exp/9608:
* c-exp.y (%union) <tvec>: Change type.
(func_mod): Now uses <tvec> type.
(exp): Update for tvec change.
(direct_abs_decl): Push the typelist.
(func_mod): Return a typelist.
(nonempty_typelist): Update for tvec change.
* gdbtypes.c (lookup_function_type_with_arguments): New function.
* gdbtypes.h (lookup_function_type_with_arguments): Declare.
* parse.c (pop_type_list): New function.
(push_typelist): New function.
(follow_types): Handle tp_function_with_arguments.
* parser-defs.h (type_ptr): New typedef. Define a VEC.
(enum type_pieces) <tp_function_with_arguments>: New constant.
(union type_stack_elt) <typelist_val>: New field.
(push_typelist): Declare.
testsuite
* gdb.base/whatis.exp: Add regression test.
Tom Tromey [Fri, 6 Jul 2012 14:44:22 +0000 (14:44 +0000)]
* c-exp.y (%union) <type_stack>: New field.
(abs_decl, direct_abs_decl): Use <type_stack> type. Update.
(ptr_operator_ts): New production.
(ptype): Update.
* parse.c (type_stack_reserve): New function.
(check_type_stack_depth): Use it.
(pop_type_stack, append_type_stack, push_type_stack)
(get_type_stack, type_stack_cleanup): New functions.
(follow_types): Handle tp_type_stack.
(_initialize_parse): Simplify initialization.
* parser-defs.h (enum type_pieces) <tp_type_stack>: New
constant.
(union type_stack_elt) <stack_val>: New field.
(get_type_stack, append_type_stack, push_type_stack)
(type_stack_cleanup): Declare.
testsuite
* gdb.base/whatis.exp: Add tests.
Tom Tromey [Fri, 6 Jul 2012 14:42:09 +0000 (14:42 +0000)]
* parser-defs.h (type_stack, type_stack_size, type_stack_depth):
Remove.
(struct type_stack): New.
* parse.c (type_stack, type_stack_size, type_stack_depth):
Remove.
(type_stack): New global.
(parse_exp_in_context, check_type_stack_depth)
(insert_into_type_stack, insert_type, push_type, push_type_int)
(insert_type_address_space, pop_type, pop_type_int)
(_initialize_parse): Update.
Tom Tromey [Fri, 6 Jul 2012 14:40:30 +0000 (14:40 +0000)]
* c-exp.y (func_mod, direct_abs_decl, abs_decl, ptr_operator):
Remove %type.
Maciej W. Rozycki [Fri, 6 Jul 2012 14:20:22 +0000 (14:20 +0000)]
* mips.h: Fix a typo in description.
Siddhesh Poyarekar [Fri, 6 Jul 2012 05:46:04 +0000 (05:46 +0000)]
* c-lang.c (c_printstr): Remove ununsed variable WIDTH.
Siddhesh Poyarekar [Fri, 6 Jul 2012 05:36:07 +0000 (05:36 +0000)]
* cp-valprint.c (cp_print_value): Replace potentially unsafe
alloca with xmalloc/xfree.
Siddhesh Poyarekar [Fri, 6 Jul 2012 03:54:22 +0000 (03:54 +0000)]
* MAINTAINERS (Write After Approval): Add myself to the list.
Doug Evans [Fri, 6 Jul 2012 00:01:11 +0000 (00:01 +0000)]
* dwarf2read.c (dw2_expand_symtabs_matching): Fix typo.
gdbadmin [Fri, 6 Jul 2012 00:00:33 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Fri, 6 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
Sean Keys [Thu, 5 Jul 2012 19:37:52 +0000 (19:37 +0000)]
gas/config/
* tc-xgate.c: Revised assembler so that operands
are collected before the addressing mode is
determined.
include/opcode/
* xgate.h: Changed the format string for mode
XGATE_OP_DYA_MON.
opcodes/
* xgate-dis.c: Removed an IF statement that will
always be false due to overlapping operand masks.
* xgate-opc.c: Corrected 'com' opcode entry and
fixed spacing.
Thomas Schwinge [Thu, 5 Jul 2012 08:28:22 +0000 (08:28 +0000)]
Typo fix.
Thomas Schwinge [Thu, 5 Jul 2012 08:18:43 +0000 (08:18 +0000)]
opcodes/
* mips-dis: Remove gratuitous newline.
Hui Zhu [Thu, 5 Jul 2012 01:08:24 +0000 (01:08 +0000)]
2012-07-05 Hui Zhu <hui_zhu@mentor.com>
* gdb.texinfo (Maintenance Commands): Change help for "maint agent"
and "maint agent-eval".
Hui Zhu [Thu, 5 Jul 2012 01:03:01 +0000 (01:03 +0000)]
2012-07-05 Hui Zhu <hui_zhu@mentor.com>
* ax-gdb.c (cli/cli-utils.h): New include.
(linespec.h): Ditto.
(agent_eval_command_one): New function.
(agent_command_1): Ditto.
(agent_command): Call function agent_command_1.
(agent_eval_command): Ditto.
(_initialize_ax_gdb): Change help for "maint agent"
and "maint agent-eval".
Hui Zhu [Thu, 5 Jul 2012 01:00:43 +0000 (01:00 +0000)]
2012-07-05 Hui Zhu <hui_zhu@mentor.com>
* breakpoint.c (check_for_argument): Move to file cli/cli-utils.c.
* cli/cli-utils.c (check_for_argument): New function.
* cli/cli-utils.h (check_for_argument): Ditto.
gdbadmin [Thu, 5 Jul 2012 00:00:32 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Thu, 5 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
H.J. Lu [Wed, 4 Jul 2012 20:49:56 +0000 (20:49 +0000)]
Mention x32 ABI support in NEWS
* NEWS: Mention x32 ABI support.
H.J. Lu [Wed, 4 Jul 2012 20:46:20 +0000 (20:46 +0000)]
Add sp_regnum_from_eax/pc_regnum_from_eax to i386 gdbarch_tdep
* amd64-tdep.c (amd64_x32_init_abi): Set sp_regnum_from_eax to
AMD64_RSP_REGNUM and pc_regnum_from_eax to AMD64_RIP_REGNUM.
* i386-tdep.c (i386_gdbarch_init): Initialize sp_regnum_from_eax
and pc_regnum_from_eax to -1. Update SP regnum from
sp_regnum_from_eax and PC regnum from pc_regnum_from_eax if
needed.
* i386-tdep.h (gdbarch_tdep): Add sp_regnum_from_eax and
pc_regnum_from_eax.
Jan Kratochvil [Wed, 4 Jul 2012 14:57:23 +0000 (14:57 +0000)]
gdb/testsuite/
PR 12649
* gdb.base/dprintf.exp (Set dprintf style to agent): Add missing
gdb_test_multiple $gdb_prompt terminator.
Pedro Alves [Wed, 4 Jul 2012 11:28:04 +0000 (11:28 +0000)]
2012-07-04 Pedro Alves <palves@redhat.com>
* gdb.mi/mi-reverse.exp: Use supports_reverse and
supports_process_record.
Pedro Alves [Wed, 4 Jul 2012 10:48:32 +0000 (10:48 +0000)]
2012-07-04 Pedro Alves <palves@redhat.com>
* gdb.ada/packed_tagged/comp_bug.adb: Convert to unix text line
endings.
* gdb.mi/mi-reverse.exp: Convert to unix text line endings.
H.J. Lu [Wed, 4 Jul 2012 00:29:52 +0000 (00:29 +0000)]
Check number of sections overflow
* elf.c (assign_section_numbers): Check if number of sections
>= SHN_LORESERVE.
* elfcode.h (elf_object_p): Likewise.
gdbadmin [Wed, 4 Jul 2012 00:00:33 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Wed, 4 Jul 2012 00:00:05 +0000 (00:00 +0000)]
daily update
Stan Shebs [Tue, 3 Jul 2012 23:17:13 +0000 (23:17 +0000)]
* gdb.base/info-os.c (main): Retry resource acquisition until an
available one is found.
* gdb.base/info-os.exp: Collect resource keys from the program
and use them in matching.
Jan Kratochvil [Tue, 3 Jul 2012 20:09:49 +0000 (20:09 +0000)]
gdb/
Fix 'warning: parameter has incomplete type' with gcc-3.4.6.
* dwarf2expr.h: Include gdbtypes.h.
(enum call_site_parameter_kind, union call_site_parameter_u): Remove
these forward declarations.
(cu_offset, sect_offset): Move these ...
* gdbtypes.h: Remove include dwarf2expr.h.
(cu_offset, sect_offset): ... here.
Nick Clifton [Tue, 3 Jul 2012 16:25:17 +0000 (16:25 +0000)]
* archive.c (bsd_write_armap): Catch attempts to create an archive
with indicies bigger than 4Gb.
(coff_write_armap): Likewise.
* readelf.c (process_archive): Display member indicies when
dumping index.
Eli Zaretskii [Tue, 3 Jul 2012 16:22:42 +0000 (16:22 +0000)]
gdb.texinfo: Separate the index into 2 indices, cp and fn, to
avoid file-name clashes between Index.html and index.html on
case-insensitive filesystems. See the discussion starting in
http://sourceware.org/ml/gdb-patches/2012-06/msg00457.html for the
details of the problem.
(Top): Update the master menu for the above.
(Concept Index, Command and Variable Index): New nodes, instead of
the old "Index" node that was deleted. All cross-references
updated.
H.J. Lu [Tue, 3 Jul 2012 16:06:34 +0000 (16:06 +0000)]
Don't compress empty debug section
2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/14319
* elf.c (_bfd_elf_make_section_from_shdr): Don't compress empty
debug section.
2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/14319
* binutils-all/compress.exp: Test compress empty debug sections.
* binutils-all/dw2-empty.S: New file.
H.J. Lu [Tue, 3 Jul 2012 14:53:56 +0000 (14:53 +0000)]
Support x32 sigtramp
* amd64-linux-tdep.c (linux_sigtramp_code): Renamed to ...
(amd64_linux_sigtramp_code): This.
(amd64_x32_linux_sigtramp_code): New.
(LINUX_SIGTRAMP_LEN): Updated.
(amd64_linux_sigtramp_start): Check x32 sigtramp.
H.J. Lu [Tue, 3 Jul 2012 14:44:35 +0000 (14:44 +0000)]
Properly handle indirect symbols
2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
PR ld/3351
* elflink.c (_bfd_elf_update_dynamic_flags): New.
(_bfd_elf_merge_symbol): Update both real and indirect symbol
dynamic flags.
(_bfd_elf_add_default_symbol): Make the real symbol dynamic if
the indirect symbol is defined in a shared library.
(elf_link_add_object_symbols): Likewise. If the indirect
symbol has been forced local, don't make the real symbol
dynamic.
(elf_link_check_versioned_symbol): Check indirect symbol.
(elf_link_output_extsym): Use real symbol definition when
reporting indirect symbol error. Check version info for
dynamic versioned symbol.
2012-07-03 H.J. Lu <hongjiu.lu@intel.com>
PR ld/3351
* ld-elf/indirect.exp: New file.
* ld-elf/indirect1a.c: Likewise.
* ld-elf/indirect1b.c: Likewise.
* ld-elf/indirect1c.c: Likewise.
* ld-elf/indirect2.c: Likewise.
* ld-elf/indirect3.out: Likewise.
* ld-elf/indirect3a.c: Likewise.
* ld-elf/indirect3b.c: Likewise.
* ld-elf/indirect3c.c: Likewise.
* ld-elf/indirect4.out: Likewise.
* ld-elf/indirect4a.c: Likewise.
* ld-elf/indirect4b.c: Likewise.
* ld-elf/indirect4c.c: Likewise.
Alan Modra [Tue, 3 Jul 2012 05:47:35 +0000 (05:47 +0000)]
PR ld/14207
* elf.c (assign_file_positions_for_load_sections): Remove assertions
that only PT_LOAD headers include file header and section headers.
(assign_file_positions_for_non_load_sections): Similarly don't
assert PT_GNU_RELRO header does not include file and section headers.
Compare first section vma rather than PT_LOAD p_vaddr against
relro_start when looking for PT_LOAD covering PT_GNU_RELRO. Replace
abort with assertion.
Alan Modra [Tue, 3 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
gdbadmin [Tue, 3 Jul 2012 00:00:02 +0000 (00:00 +0000)]
*** empty log message ***
Jan Kratochvil [Mon, 2 Jul 2012 20:39:13 +0000 (20:39 +0000)]
gdb/
* linux-thread-db.c (thread_db_new_objfile): Fix comment typos.
Plus add in an already checked in file:
(thread_db_new_objfile): Exclude debug files.
Jan Kratochvil [Mon, 2 Jul 2012 20:31:09 +0000 (20:31 +0000)]
gdb/
* config.in: Regenerate.
* configure: Regenerate.
* configure.ac: Remove check for gnu/libc-version.h.
* linux-thread-db.c <HAVE_GNU_LIBC_VERSION_H>: Remove include of
gnu/libc-version.h.
(enable_thread_event_reporting) <HAVE_GNU_LIBC_VERSION_H>: Remove
variables libc_version, libc_major and libc_minor. Replace sscanf by
inferior_has_bug. Extend the comment.
Jan Kratochvil [Mon, 2 Jul 2012 20:28:38 +0000 (20:28 +0000)]
gdb/
* linux-thread-db.c (inferior_has_bug): New function.
(thread_db_find_new_threads_silently): Return boolean as checked by
inferior_has_bug, describe it in the comments.
(try_thread_db_load_1): Move call to thread_db_find_new_threads_silently
earlier. Abort the initialization if it returned non-zero.
(thread_db_find_new_threads_2): Preinitialize ERR. Check errors also
if UNTIL_NO_NEW,
gdb/testsuite/
* gdb.threads/gcore-thread.exp: Remove variable libthread_db_seen.
Wrap the test into loop for corefile and core0file.
Jan Kratochvil [Mon, 2 Jul 2012 20:10:48 +0000 (20:10 +0000)]
gdb/testsuite/
* gdb.dwarf2/fission-reread.S: Change # comments to /* */ comments.
Jan Kratochvil [Mon, 2 Jul 2012 20:09:26 +0000 (20:09 +0000)]
gdb/testsuite/
* gdb.dwarf2/fission-reread.S: Remove .section attributes.
Change CU pointer size to 4 bytes, adjust .8byte to .4byte. Remove
.note.GNU-stack.
Doug Evans [Mon, 2 Jul 2012 20:02:39 +0000 (20:02 +0000)]
* dwarf2read.c (maybe_queue_comp_unit): Move definition next to others
related to queue management.
Roland McGrath [Mon, 2 Jul 2012 18:20:31 +0000 (18:20 +0000)]
ld/testsuite/
* ld/testsuite/ld-i386/tlsbin-nacl.rd: Update for symbol table changes.
* ld/testsuite/ld-i386/tlsbindesc-nacl.rd: Likewise.
* ld/testsuite/ld-i386/tlsdesc-nacl.rd: Likewise.
* ld/testsuite/ld-i386/tlsgdesc-nacl.rd: Likewise.
* ld/testsuite/ld-i386/tlsnopic-nacl.rd: Likewise.
* ld/testsuite/ld-i386/tlspic-nacl.rd: Likewise.
* ld/testsuite/ld-x86-64/tlsbin-nacl.rd: Likewise.
* ld/testsuite/ld-x86-64/tlsbindesc-nacl.rd: Likewise.
* ld/testsuite/ld-x86-64/tlsdesc-nacl.rd: Likewise.
* ld/testsuite/ld-x86-64/tlsgdesc-nacl.rd: Likewise.
* ld/testsuite/ld-x86-64/tlspic-nacl.rd: Likewise.
Doug Evans [Mon, 2 Jul 2012 18:13:41 +0000 (18:13 +0000)]
* dwarf2read.c (create_debug_types_hash_table): Use "debug dwarf2-read"
instead of "debug dwarf2-die" in debugging printfs.
(create_debug_info_hash_table_reader): Ditto.
(create_debug_info_hash_table): Ditto.
(init_dwo_file): Ditto.
(init_cutu_and_read_dies): Add debugging printf.
(init_cutu_and_read_dies_no_follow): Ditto.
(process_psymtab_comp_unit_reader): Ditto.
Roland McGrath [Mon, 2 Jul 2012 18:12:28 +0000 (18:12 +0000)]
gas/testsuite/
* gas/i386/rep-suffix.s: Add 'rep nop' case.
* gas/i386/x86-64-rep-suffix.s: Likewise.
* gas/i386/rep-suffix.d: Updated.
* gas/i386/x86-64-rep-suffix.d: Likewise.
* gas/i386/ilp32/x86-64-rep-suffix.d: Likewise.
opcodes/
* i386-opc.tbl: Add RepPrefixOk to nop.
* i386-tbl.h: Regenerate.
Sergio Durigan Junior [Mon, 2 Jul 2012 17:53:19 +0000 (17:53 +0000)]
gdb/testsuite:
2012-07-02 Sergio Durigan Junior <sergiodj@redhat.com>
* gdb.base/help.exp (help b, help br, help bre, help brea, help
break): Include help message for the new `-probe' and `-probe-stap'
options.
Doug Evans [Mon, 2 Jul 2012 17:37:35 +0000 (17:37 +0000)]
(gdb_no_commands_at_breakpoint): Tweak previous patch for win64 where
sizeof (long) < sizeof (void*).
Doug Evans [Mon, 2 Jul 2012 17:11:36 +0000 (17:11 +0000)]
* mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
pointer to int.
H.J. Lu [Mon, 2 Jul 2012 17:06:52 +0000 (17:06 +0000)]
Fix ChangeLog entry
H.J. Lu [Mon, 2 Jul 2012 17:04:51 +0000 (17:04 +0000)]
Move rep tests for bsf/bsr/ret to rep-suffix
* gas/i386/i386.exp: Don't run rep-bsf nor rep-ret.
* gas/i386/rep-bsf.d: Removed.
* gas/i386/rep-bsf.s: Likewise.
* gas/i386/rep-ret.d: Likewise.
* gas/i386/rep-ret.s: Likewise.
* gas/i386/rep-suffix.d: Updated.
* gas/i386/x86-64-rep-suffix.d: Likewise.
* gas/i386/ilp32/x86-64-rep-suffix.d: Likewise.
* gas/i386/rep-suffix.s: Add tests for bsf, bsr and ret.
* i386/x86-64-rep-suffix.s: Likewise.
H.J. Lu [Mon, 2 Jul 2012 16:29:07 +0000 (16:29 +0000)]
Replace __end_SECNAME with __stop_SECNAME
* ld.texinfo: Replace __end_SECNAME with __stop_SECNAME.
Stan Shebs [Mon, 2 Jul 2012 15:29:39 +0000 (15:29 +0000)]
Add target-side support for dynamic printf.
* NEWS: Mention the additional style.
* breakpoint.h (struct bp_target_info): New fields tcommands, persist.
(struct bp_location): New field cmd_bytecode.
* breakpoint.c: Include format.h.
(disconnected_dprintf): New global.
(parse_cmd_to_aexpr): New function.
(build_target_command_list): New function.
(insert_bp_location): Call it.
(remove_breakpoints_pid): Skip dprintf breakpoints.
(print_one_breakpoint_location): Ditto.
(dprintf_style_agent): New global.
(dprintf_style_enums): Add dprintf_style_agent.
(update_dprintf_command_list): Add agent case.
(agent_printf_command): New function.
(_initialize_breakpoint): Add new commands.
* common/ax.def (printf): New bytecode.
* ax.h (ax_string): Declare.
* ax-gdb.h (gen_printf): Declare.
* ax-gdb.c: Include cli-utils.h, format.h.
(gen_printf): New function.
(maint_agent_print_command): New function.
(_initialize_ax_gdb): Add maint agent-printf command.
* ax-general.c (ax_string): New function.
(ax_print): Add printf disassembly.
* Makefile.in (SFILES): Add format.c
(COMMON_OBS): Add format.o.
* common/format.h: New file.
* common/format.c: New file.
* printcmd.c: Include format.h.
(ui_printf): Call parse_format_string.
* remote.c (remote_state): New field breakpoint_commands.
(PACKET_BreakpointCommands): New enum.
(remote_breakpoint_commands_feature): New function.
(remote_protocol_features): Add new BreakpointCommands entry.
(remote_can_run_breakpoint_commands): New function.
(remote_add_target_side_commands): New function.
(remote_insert_breakpoint): Call it.
(remote_insert_hw_breakpoint): Ditto.
(_initialize_remote): Add new packet configuration for
target-side breakpoint commands.
* target.h (struct target_ops): New field
to_can_run_breakpoint_commands.
(target_can_run_breakpoint_commands): New macro.
* target.c (update_current_target): Handle
to_can_run_breakpoint_commands.
[gdbserver]
* Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
(ax.o): Add it to build rule.
(ax-ipa.o): Ditto.
(OBS): Add format.o.
(IPA_OBS): Add format.o.
* server.c (handle_query): Claim support for breakpoint commands.
(process_point_options): Add command case.
(process_serial_event): Leave running if there are printfs in
effect.
* mem-break.h (any_persistent_commands): Declare.
(add_breakpoint_commands): Declare.
(gdb_no_commands_at_breakpoint): Declare.
(run_breakpoint_commands): Declare.
* mem-break.c (struct point_command_list): New struct.
(struct breakpoint): New field command_list.
(any_persistent_commands): New function.
(add_commands_to_breakpoint): New function.
(add_breakpoint_commands): New function.
(gdb_no_commands_at_breakpoint): New function.
(run_breakpoint_commands): New function.
* linux-low.c (linux_wait_1): Test for and run breakpoint commands
locally.
* ax.c: Include format.h.
(ax_printf): New function.
(gdb_eval_agent_expr): Add printf opcode.
[doc]
* gdb.texinfo (Dynamic Printf): Mention agent style and
disconnected dprintf.
(Maintenance Commands): Describe maint agent-printf.
(General Query Packets): Mention BreakpointCommands feature.
(Packets): Document commands extension to Z0 packet.
* agentexpr.texi (Bytecode Descriptions): Document printf
bytecode.
[testsuite]
* gdb.base/dprintf.exp: Add agent style tests.
H.J. Lu [Mon, 2 Jul 2012 14:40:19 +0000 (14:40 +0000)]
Add a test for weak alias
* ld-elf/data2.c: New file.
* ld-elf/weakdef1.c: Likewise.
* ld-elf/shared.exp: Add tests for libdata2 and weakdef1.
Tom Tromey [Mon, 2 Jul 2012 14:35:33 +0000 (14:35 +0000)]
* dwarf.c: Include gdb-index.h.
(display_gdb_index): Handle version 7.
Jan Kratochvil [Mon, 2 Jul 2012 12:06:56 +0000 (12:06 +0000)]
gdb/testsuite/
* gdb.base/stale-infcall.c (infcall): New label test-next.
(main): New labels test-pass and test-fail.
* gdb.base/stale-infcall.exp: Continue to test-next. Put breakpoint
$test_fail_bpnum to test-fail.
(test system longjmp tracking support): New test.
Delete $test_fail_bpnum.
* lib/gdb.exp (gdb_continue_to_breakpoint): Accept also Temporary
breakpoint.
Jan Kratochvil [Mon, 2 Jul 2012 12:05:01 +0000 (12:05 +0000)]
gdb/
Execute -ix and -iex only after system and user gdbinit files.
* main.c (captured_main): Move CMDARG_INIT_FILE and CMDARG_INIT_COMMAND
processing down after gdbinit files.
gdb/doc/
* gdb.texinfo (File Options): Change -ix and -iex commands that apply
only after gdbinit files.
(Startup): Move -iex and -iex commands down after gdbinit files.
Jan Kratochvil [Mon, 2 Jul 2012 11:52:39 +0000 (11:52 +0000)]
gdb/
Add fnmatch-gnu module.
* gnulib/Makefile.in (aclocal_m4_deps): Add new files and remove one.
* gnulib/configure.ac (AC_INIT): Use now import/memmem.c.
* gnulib/aclocal.m4: Regenerate.
* gnulib/config.in: Regenerate.
* gnulib/configure: Regenerate.
* gnulib/import/dummy.c: Remove.
* gnulib/import/Makefile.am: Regenerate.
* gnulib/import/Makefile.in: Likewise.
* gnulib/import/m4/gnulib-cache.m4: Likewise.
* gnulib/import/m4/gnulib-comp.m4: Likewise.
* gnulib/import/alloca.c: New file.
* gnulib/import/alloca.in.h: Likewise.
* gnulib/import/config.charset: Likewise.
* gnulib/import/fnmatch.c: Likewise.
* gnulib/import/fnmatch.in.h: Likewise.
* gnulib/import/fnmatch_loop.c: Likewise.
* gnulib/import/localcharset.c: Likewise.
* gnulib/import/localcharset.h: Likewise.
* gnulib/import/m4/alloca.m4: Likewise.
* gnulib/import/m4/codeset.m4: Likewise.
* gnulib/import/m4/configmake.m4: Likewise.
* gnulib/import/m4/fcntl-o.m4: Likewise.
* gnulib/import/m4/fnmatch.m4: Likewise.
* gnulib/import/m4/glibc21.m4: Likewise.
* gnulib/import/m4/localcharset.m4: Likewise.
* gnulib/import/m4/locale-fr.m4: Likewise.
* gnulib/import/m4/locale-ja.m4: Likewise.
* gnulib/import/m4/locale-zh.m4: Likewise.
* gnulib/import/m4/mbrtowc.m4: Likewise.
* gnulib/import/m4/mbsinit.m4: Likewise.
* gnulib/import/m4/mbsrtowcs.m4: Likewise.
* gnulib/import/m4/mbstate_t.m4: Likewise.
* gnulib/import/m4/stdbool.m4: Likewise.
* gnulib/import/m4/wchar_h.m4: Likewise.
* gnulib/import/m4/wctype_h.m4: Likewise.
* gnulib/import/m4/wint_t.m4: Likewise.
* gnulib/import/mbrtowc.c: Likewise.
* gnulib/import/mbsinit.c: Likewise.
* gnulib/import/mbsrtowcs-impl.h: Likewise.
* gnulib/import/mbsrtowcs-state.c: Likewise.
* gnulib/import/mbsrtowcs.c: Likewise.
* gnulib/import/ref-add.sin: Likewise.
* gnulib/import/ref-del.sin: Likewise.
* gnulib/import/stdbool.in.h: Likewise.
* gnulib/import/streq.h: Likewise.
* gnulib/import/strnlen1.c: Likewise.
* gnulib/import/strnlen1.h: Likewise.
* gnulib/import/verify.h: Likewise.
* gnulib/import/wchar.in.h: Likewise.
* gnulib/import/wctype.in.h: Likewise.
Jan Kratochvil [Mon, 2 Jul 2012 10:57:34 +0000 (10:57 +0000)]
gdb/
Support shell wildcards for 'set auto-load safe-path'.
* auto-load.c: Include fnmatch.h.
(filename_is_in_dir): Rename to ...
(filename_is_in_pattern_1, filename_is_in_pattern): ... here and split
it. Update function comment. Rename dir_len to pattern_len. New
variables filename_len, pattern and filename. Add more DEBUG_AUTO_LOAD
messages. Use gdb_filename_fnmatch.
(filename_is_in_auto_load_safe_path_vec): Rename variable dir to
pattern.
(_initialize_auto_load): Extend the "set auto-load safe-path" help text.
* defs.h (gdb_filename_fnmatch): New declaration.
* utils.c: Include fnmatch.h.
(gdb_filename_fnmatch): New function.
gdb/doc/
* gdb.texinfo (Auto-loading safe path): Note the shell wildcard
possibility.
Nick Clifton [Mon, 2 Jul 2012 07:35:06 +0000 (07:35 +0000)]
* write.c (fixup_segment): Only perform the subtraction of an
fx_subsy symbol if MD_APPLY_SYM_VALUE allows it and the symbol is
properly defined.
* config/tc-msp430.h (MD_APPLY_SYM_VALUE): Define.
Sergio Durigan Junior [Mon, 2 Jul 2012 03:36:04 +0000 (03:36 +0000)]
2012-07-02 Sergio Durigan Junior <sergiodj@redhat.com>
* breakpoint.c (BREAK_ARGS_HELP): Include help message for the new
`-probe' and `-probe-stap' options.
Alan Modra [Mon, 2 Jul 2012 03:02:45 +0000 (03:02 +0000)]
* elf32-m32c.c (m32c_elf_check_relocs): Use bfd_make_section
"anyway" variant when creating .plt.
(m32c_elf_relax_plt_section): Remove redundant test and unused param.
(m32c_elf_relax_section): Test SEC_LINKER_CREATED before calling
m32c_elf_relax_plt_section.
* elfxx-mips.c (mips_elf_create_got_section): Use make anyway variant
when creating .got and .got.plt.
(_bfd_mips_elf_final_link): Likewise for .rtproc, and use
bfd_get_linker_section.
* sunos.c: Similarly throughout.
gdbadmin [Mon, 2 Jul 2012 00:00:33 +0000 (00:00 +0000)]
*** empty log message ***
Alan Modra [Mon, 2 Jul 2012 00:00:04 +0000 (00:00 +0000)]
daily update
Yao Qi [Sun, 1 Jul 2012 10:37:04 +0000 (10:37 +0000)]
gdb:
* breakpoint.c: Removed always_inserted_auto, always_inserted_on,
always_inserted_off, and always_inserted_enums.
Change always_inserted_mode's type to 'enum auto_boolean'.
(show_always_inserted_mode, breakpoint_always_inserted_mode): Update
callers.
(_initialize_breakpoint): Call add_setshow_auto_boolean_cmd instead
of add_setshow_enum_cmd.
* infrun.c: Remove can_use_displaced_stepping_auto,
can_use_displaced_stepping_on, can_use_displaced_stepping_off, and
can_use_displaced_stepping_enum.
Change can_use_displaced_stepping's type to 'enum auto_boolean'.
(show_can_use_displaced_stepping, use_displaced_stepping): Update callers.
(_initialize_infrun): Call add_setshow_auto_boolean_cmd instead of
add_setshow_enum_cmd.
Andreas Schwab [Sun, 1 Jul 2012 08:23:13 +0000 (08:23 +0000)]
* elf.c (_bfd_elf_make_section_from_shdr): Fix typo in error
message.