Commit Graph

75450 Commits

Author SHA1 Message Date
gdbadmin 4c06243903 *** empty log message *** 2012-12-18 00:00:03 +00:00
Alan Modra 614b686180 daily update 2012-12-17 23:00:08 +00:00
Doug Evans 4e3f5ae6b7 Enable accidentally commented out code. 2012-12-17 19:40:24 +00:00
Roland McGrath b3adb10f86 ld/testsuite/
* ld-elf/elf.exp (stack exec, stack size): Run for *-*-nacl* targets.
	* ld-i386/export-class.exp: Run for i?86-*-nacl* targets.
2012-12-17 19:32:52 +00:00
Roland McGrath adbcc655b4 bfd/
* elf32-arm.c (elf32_arm_size_stubs): Skip input BFDs that are
	not ARM ELF.
2012-12-17 19:13:07 +00:00
Jeff Johnston 68dad382d9 2012-12-17 Jeff Johnston <jjohnstn@redhat.com>
* COPYING.LIBGLOSS: Add license for bfin libgloss.
2012-12-17 17:46:09 +00:00
H.J. Lu 4cf0f7850b Remove the leading zero
* ld-elf/var1.d: Remove the leading zero.
2012-12-17 17:20:07 +00:00
Nick Clifton 5bf135a788 Add copyright notices 2012-12-17 16:56:12 +00:00
H.J. Lu 387894ff90 Update PR ld/14962 testcase 2012-12-17 15:37:40 +00:00
Tom Tromey e4acb24c9d * top.c (xgdb_verbose): Remove. 2012-12-17 15:11:56 +00:00
H.J. Lu 06fc0e2238 Add a testcase for PR ld/14962
PR ld/14962
	* ld-elf/var1.d: New file.
	* ld-elf/var1.s: Likewise.
	* ld-elf/var1.t: Likewise.
2012-12-17 14:53:35 +00:00
Joel Brobecker 8b93d60f22 lynx-low: Add debug trace when new thread is discovered.
gdb/gdbserver/ChangeLog:

        * lynx-low.c (lynx_wait_1): Add debug trace before adding
        new thread.
2012-12-17 11:17:12 +00:00
Joel Brobecker 037335a7a8 Add PTRACE_GETTRACESIG handling in ptrace_request_to_str
We use this ptrace request when handling SIGTRAP signals,
and without this change, the debug trances show:

    PTRACE (<unknown-request>, ...

This patch fixes this.

gdb/gdbserver/ChangeLog:

        * lynx-low.c (ptrace_request_to_str): Add handling for
        PTRACE_GETTRACESIG.
2012-12-17 11:13:52 +00:00
Joel Brobecker 52d4cbd805 Delete unused variable in lynx_attach.
gdb/gdbserver/ChangeLog:

        * lynx-low.c (lynx_attach): Delete variable new_process.
2012-12-17 11:03:00 +00:00
Joel Brobecker ab8f6ca9c6 remove unused variable in lynx_create_inferior.
gdb/gdbserver/ChangeLog:

        * lynx-low.c (lynx_create_inferior): Delete variable new_process.
2012-12-17 11:02:47 +00:00
Joel Brobecker 78cbc0240c lynx-low.c: PTRACE_GETTHREADLIST may not be defined.
LynxOS 178 does not define this macro.

gdb/gdbserver/ChangeLog:

        * lynx-low.c (ptrace_request_to_str): Do not handle
        PTRACE_GETTHREADLIST if this macro does not exist.
2012-12-17 10:51:29 +00:00
Alan Modra 4194268f43 PR ld/14962
* ldexp.h (struct ldexp_control): Add "assign_name".
	* ldexp.c (fold_name <NAME>): Compare and clear assign_name on match.
	(exp_fold_tree_1): Remove existing code testing for self assignment.
	Instead set and test expld.assign_name.
	* ldlang.c (scan_for_self_assignment): Delete.
	(print_assignment): Instead set and test expld.assign_name.
2012-12-17 00:16:49 +00:00
gdbadmin faa7371af5 *** empty log message *** 2012-12-17 00:00:33 +00:00
H.J. Lu ad1e85de41 Don't check IFUNC relocations in elf_*_check_relocs
* elf32-i386.c (elf_i386_check_relocs): Don't check IFUNC
	relocations here.
	* elf64-x86-64.c (elf_x86_64_check_relocs): Likewise.
2012-12-16 23:01:13 +00:00
Alan Modra b6eb2f8639 daily update 2012-12-16 23:00:07 +00:00
H.J. Lu 73bcf23385 Also check local IFUNC references
bfd/

	PR ld/14968
	* elf32-i386.c (elf_i386_adjust_dynamic_symbol): Also check
	local IFUNC references.
	* elf64-x86-64.c (elf_x86_64_adjust_dynamic_symbol): Likewise.

ld/testsuite/

	PR ld/14968
	* ld-ifunc/ifunc-18a-i386.d: New file.
	* ld-ifunc/ifunc-18a-x86-64.d: Likewise.
	* ld-ifunc/ifunc-18a.s: Likewise.
	* ld-ifunc/ifunc-18b-i386.d: Likewise.
	* ld-ifunc/ifunc-18b-x86-64.d: Likewise.
	* ld-ifunc/ifunc-18b.s: Likewise.
	* ld-ifunc/ifunc-19a-i386.d: Likewise.
	* ld-ifunc/ifunc-19a-x86-64.d: Likewise.
	* ld-ifunc/ifunc-19a.s: Likewise.
	* ld-ifunc/ifunc-19b-i386.d: Likewise.
	* ld-ifunc/ifunc-19b-x86-64.d: Likewise.
	* ld-ifunc/ifunc-19b.s: Likewise.
2012-12-16 20:31:08 +00:00
Jan Kratochvil 3d745be3fc gdb/
Code cleanup.
	* skip.c (skip_function_command, skip_file_command, skip_info): Remove
	unused forward declarations.
	(skip_file_command): Make variables symtab and filename targets const.
	Use proper 0 vs. NULL constant everywhere.
	(skip_function_command): Use proper 0 vs. NULL constant everywhere.
	Include empty line after declarations.  Use GNU spacing in a comment.
	Do not use strlen for end of string check.
	(skip_info): Use proper 0 vs. NULL constant everywhere.  Add column 5
	comments.
	(skip_enable_command, skip_disable_command, skip_delete_command)
	(add_skiplist_entry): Use proper 0 vs. NULL constant everywhere.
	(function_pc_is_marked_for_skip): Make variable filename target const.
	Use proper 0 vs. NULL constant everywhere.  Fix GNU non-compliant
	comment formatting.
	(skip_re_set): Add empty line after function comment.  Use proper 0 vs.
	NULL constant everywhere.  Include empty line after declarations.  Make
	variable symtab target const.  Do not use strlen for end of string
	check.

gdb/doc/
	* gdbint.texinfo (Coding Standards) (C Usage): New rule for 0 vs. NULL.
2012-12-16 19:00:04 +00:00
Jan Kratochvil b57a636e4b gdb/
Code cleanup.
	* breakpoint.c (clear_command): Remove variable sal_name_len and its
	initialization, remove it from the compare_filenames_for_search call.
	* dwarf2read.c (dw2_map_symtabs_matching_filename): Remove variable
	name_len and its initialization, remove it from the
	compare_filenames_for_search calls.
	* psymtab.c (partial_map_symtabs_matching_filename): Likewise.
	* symtab.c (compare_filenames_for_search): Remove the search_len
	parameter, update the function comment, new variable search_len
	initialized from SEARCH_NAME.
	(iterate_over_some_symtabs): Remove variable name_len and its
	initialization, remove it from the compare_filenames_for_search calls.
	* symtab.h (compare_filenames_for_search): Remove the search_len
	parameter,
2012-12-16 18:57:16 +00:00
Thomas Schwinge 2344b8da6e * configure.ac (ENABLE_GOLD): Consider *-*-gnu* targets ELF.
* configure: Regenerate.
2012-12-16 07:10:07 +00:00
Joel Brobecker 67c50e6ecc Makefile.in: Move ravenscar-thread.c from SFILES to ALLDEPFILES.
gdb/ChangeLog:

	* Makefile.in (SFILES): Move ravenscar-thread.c from here...
	(ALLDEPFILES): ... to there.
2012-12-16 04:46:40 +00:00
gdbadmin 0c7eb43794 *** empty log message *** 2012-12-16 00:00:33 +00:00
Alan Modra 987acc137d daily update 2012-12-15 23:00:05 +00:00
Joel Brobecker e924e903c6 Minor ChangeLog fix. 2012-12-15 14:44:56 +00:00
Joel Brobecker 5d21469858 Add missing backslash in configure.tgt gdb_target_ops (sparc-*-*)
I forgot to put a '\' when splitting the line in two.

gdb/ChangeLog:

        * configure.tgt (sparc-*-*): Add missing '\' in gdb_target_ops.
2012-12-15 14:34:20 +00:00
Joel Brobecker debb1f09a1 Add ravenscar-thread support for powerpc.
gdb/ChangeLog:

        * ppc-ravenscar-thread.h, ppc-ravenscar-thread.c: New files.
        * Makefile.in (ALL_TARGET_OBS): Add ppc-ravenscar-thread.o.
        (HFILES_NO_SRCDIR): Add ppc-ravenscar-thread.h.
        (ALLDEPFILES): Add ppc-ravenscar-thread.c.
        * configure.tgt: Add ravenscar-thread.o and ppc-ravenscar-thread.o
        to gdb_target_obs for every target that uses rs6000-tdep.o.
        * rs6000-tdep.c: #include "ppc-ravenscar-thread.h".
        (rs6000_gdbarch_init): Call register_e500_ravenscar_ops
        or register_ppc_ravenscar_ops.
2012-12-15 14:30:18 +00:00
Joel Brobecker c16998a76c change ravenscar_sparc prefixes into sparc_ravenscar...
... following the file renaming in the previous commit.

gdb/ChangeLog:

        * sparc-ravenscar-thread.h: SPARC_RAVENSCAR_THREAD_H renames
        RAVENSCAR_SPARC_THREAD_H.
        * sparc-ravenscar-thread.c: Rename all global entities
        whose name is uses "ravenscar_sparc" as the prefix to use
        "sparc_ravenscar" instead.
2012-12-15 14:29:31 +00:00
Joel Brobecker e6f9c00b64 Rename ravenscar-sparc-thread.[hc] into sparc-ravenscar-thread.[hc].
gdb/ChangeLog:

        * sparc-ravenscar-thread.h: Renames ravenscar-sparc-thread.h.
        * sparc-ravenscar-thread.c: Renames ravenscar-sparc-thread.c.
        Adjust sparc-ravenscar-thread.h #include.
        * sparc-tdep.c: Adjust sparc-ravenscar-thread.h #include
        accordingly.
        * Makefile.in: Replace ravenscar-sparc-thread with
        sparc-ravenscar-thread throughout.
        * configure.tgt: Likewise.
2012-12-15 14:29:00 +00:00
Joel Brobecker 7e35103a30 gdbarch-ification of ravenscar-thread support.
gdb/ChangeLog:

        * gdbarch.sh: Add "struct ravenscar_arch_ops" advance
        declaration.
        (ravenscar_ops): New gdbarch variable.
        * gdbarch.h, gdbarch.c: Regenerate.
        * ravenscar-thread.h (ravenscar_register_arch_ops): Delete.
        * ravenscar-thread.c (current_arch_ops): Delete.
        (ravenscar_fetch_registers): Get the ravenscar_arch_ops
        from the gdbarch.
        (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
        (ravenscar_inferior_created): Add gdbarch_ravenscar_ops check.
        (ravenscar_register_arch_ops): Delete.
        * ravenscar-sparc-thread.h: New file.
        * ravenscar-sparc-thread.c: #include "ravenscar-sparc-thread.h".
        (ravenscar_sparc_ops): Define value statically.
        (_initialize_ravenscar_sparc): Delete.
        (register_sparc_ravenscar_ops): New function.
        * sparc-tdep.c: #include "ravenscar-sparc-thread.h".
        (sparc32_gdbarch_init): Add call to register_sparc_ravenscar_ops.
        * Makefile.in (ALL_TARGET_OBS): Add ravenscar-thread.o and
        ravenscar-sparc-thread.o.
        (SFILES): Add ravenscar-thread.c.
        (HFILES_NO_SRCDIR): Add ravenscar-sparc-thread.h.
        (ALLDEPFILES): ravenscar-sparc-thread.c.
        * configure.tgt: Add ravenscar-thread.o and ravenscar-sparc-thread.o
        to gdb_target_obs
        for all the targets that use sparc-tdep.o.
2012-12-15 14:27:56 +00:00
Joel Brobecker 25abf4decf minor ravenscar-thread cleanup
The use of the ravenscar_open static global is unnecessary.
This patch removes it. It also removes some routines that
were created in association with the management of this global.

gdb/ChangeLog:

        * ravenscar-thread.c (ravenscar_is_open): Delete.
        (ravenscar_initialize): Move most of the code from here...
        (ravenscar_inferior_created): ... to there.  Invert logic.
        (ravenscar_close): Delete.
        (init_ravenscar_thread_ops): Remove setting of
        ravenscar_ops.to_close.
2012-12-15 14:27:13 +00:00
Joel Brobecker 3d6e24f050 Move init_entry_point_info to symfile.c and make it static.
gdb/ChangeLog:

        * objfiles.c (init_entry_point_info): Move function from here...
        * symfile.c (init_entry_point_info): ... to there.  Make static.
        * objfiles.h (objfiles.h): Delete declaration.
2012-12-15 13:11:18 +00:00
Joel Brobecker 36e4d0683b Fix NULL objfile's section_offsets dereference during symbol load.
gdb/ChangeLog:

        * symfile.c (syms_from_objfile_1): Renames syms_from_objfile.
        Remove call to init_entry_point_info.  Add OBJFILE's
        section_offsets and num_sections initialization.  Add note
        about entry info in the function documentation.
        (syms_from_objfile): New function.
        * coffread.c (coff_symfile_init): Remove call to
        init_entry_point_info.
        * machoread.c (macho_symfile_init): Likewise.
        * xcoffread.c(xcoff_symfile_init): Likewise.
2012-12-15 13:10:50 +00:00
Thomas Schwinge 6b00ac5ace Fix copy'n'paste-o. 2012-12-15 10:34:14 +00:00
Thomas Schwinge 9cc420b64c ld/testsuite/
* ld-elf/elf.exp (stack exec, stack size): Run for any GNU target.
	* ld-elf/maxpage3c.d: Run for any x86 GNU target.
	* ld-elf/maxpage4.d: Likewise.
	* ld-elf/maxpage5.d: Likewise.
	* ld-i386/export-class.exp: Likewise.
2012-12-15 10:28:17 +00:00
Yao Qi c9b6281a36 gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* remote-notif.c (_initialize_notif): Add new commands
	'set debug notification' and 'show debug notification'.
	* NEWS: Mention these new commands.
gdb/doc/
2012-12-15 Yao Qi  <yao@codesourcery.com>

	* gdb.texinfo (Debugging Output): Document 'set debug
	notification' and 'show debug notification'.
2012-12-15 04:06:40 +00:00
Yao Qi 722247f1cb gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* Makefile.in (REMOTE_OBS): Add "remote-notif.o".
	(SFILES): Add "remote-notif.c".
	(HFILES_NO_SRCDIR): Add "remote-notif.h" and "common/queue.h".
	* remote-notif.c: New.  Factored out from remote.c.
	* remote-notif.h: New.
	* remote.c: Include "remote-notif.h".
	(stop_reply_xmalloc, do_stop_reply_xfree):
	(remote_parse_stop_reply, remote_get_pending_stop_replies):
	(remote_async_get_pending_events_handler): Remove declarations.
	(remote_parse_stop_reply): Declare.
	(pending_stop_reply): Remove.
	(remote_async_get_pending_events_token): Move to
	remote-notif.c.
	(remote_close): Replace 'delete_async_event_handler' with
	remote_notif_unregister_async_event_handler.
	Don't call discard_pending_stop_replies.
	(remote_start_remote): Replace code with remote_notif_parse
	and remote_notif_get_pending_replies.
	(remote_open_1): Replace 'create_async_event_handler' with
	remote_notif_register_async_event_handler.
	(extended_remote_attach_1): Call remote_notif_parse and
	notif_stop_reply_push.
	(struct stop_reply) <next>: Remove.
	<base>: New field.
	Callers update.
	(stop_reply_queue): Change its type.
	(stop_reply_xmalloc, do_stop_reply_xfree): Remove.
	(remote_notif_remove_all): New.
	(discard_pending_stop_replies): Update.
	(remote_notif_stop_ack, stop_reply_dtr): New.
	(remote_notif_stop_alloc_event): New.
	(notif_client_stop): New variable.
	(stop_reply_match_ptid, stop_reply_match_ptid_and_ws: New.
	(queued_stop_reply, peek_stop_reply): Adjust.
	(remote_get_pending_stop_replies): Rename to
	remote_notif_get_pending_events.
	(handle_notification): Move to remote-notif.c.
	(remote_async_get_pending_events_handler): Likewise.
	(remote_wait_as): Adjust to call remote_notif_parse.
	Call 'getpkt_or_notif_sane' instead of 'getpkt_sane'.
	Return minus_one_ptid early if gets a notification.
	(remote_wait): Call QUEUE_is_empty (notif_reply_p).
	(_initialize_remote): Call QUEUE_alloc.  Update caller.
	(remote_resume): Call 'remote_notif_process' in all-stop mode.
	* remote.h: Include "remote-notif.h".
	(remote_notif_get_pending_replies): Declare.
2012-12-15 03:50:22 +00:00
Yao Qi 5f4cf0bb27 gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* remote.c (discard_pending_stop_replies): Update declaration.
	(remote_detach_1, extended_remote_mourn_1): Likewise.
	(discard_pending_stop_replies): Change parameter from PID to
	INF.
	(remote_close): Update caller.
	(_initialize_remote): Attach discard_pending_stop_replies to
	inferior_exit observer.
2012-12-15 03:34:03 +00:00
Yao Qi fee9eda9ee gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* remote.c (getpkt_or_notif_sane): Add one more argument in
	its declaration.
	(getpkt_or_notif_sane_1): Add one more argument.
	(getpkt_sane): Update caller.
	(getpkt_or_notif_sane): Likewise.  Update call
	togetpkt_or_notif_sane_1.
	(remote_wait_ns): Update caller.
2012-12-15 03:14:22 +00:00
Yao Qi 14a0047001 gdb/gdbserver/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* Makefile.in (OBS): Add notif.o.
	* notif.c, notif.h: New.
	* server.c: Include "notif.h".
	(struct vstop_notif) <next>: Remove.
	<base>: New field.
	(queue_stop_reply): Update.
	(push_event, send_next_stop_reply): Remove.
	(discard_queued_stop_replies): Update.
	(notif_stop): New variable.
	(handle_v_stopped): Remove.
	(handle_v_requests): Don't call handle_v_stopped.  Call
	handle_ack_notif instead.
	(queue_stop_reply_callback): Call notif_event_enque instead
	of queue_stop_reply.
	(handle_status): Don't call send_next_stop_reply, call
	notif_write_event instead.
	(kill_inferior_callback): Likewise.
	(detach_or_kill_inferior_callback): Likewise.
	(main): Call initialize_notif.
	(process_serial_event): Call QUEUE_is_empty.
	(handle_target_event): Call notif_push instead of push event.
	* server.h (push_event): Remove declaration.
2012-12-15 02:48:18 +00:00
Yao Qi dbb0cf06a3 gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>
	    Doug Evans  <dje@google.com>

	* common/queue.h: New.
2012-12-15 02:25:34 +00:00
Yao Qi f2a8bc8a74 2012-12-15 Yao Qi <yao@codesourcery.com>
* breakpoint.c (print_one_breakpoint_location): Display the
	state of 'installed' of each non-pending location of a tracepoint
	in both CLI and MI.
	(download_tracepoint_locations): Notify 'breakpoint-modified'
	observer if any tracepoint location is downloaded.
	* tracepoint.c (start_tracing): Likewise.
	(merge_uploaded_tracepoints): Record all modified
	tracepoints and notify 'breakpoint-modified' observer for them.

	* NEWS: Mention the change for CLI and MI.

gdb/doc:
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* gdb.texinfo (Listing Tracepoints): New item and example about
	'installed on target' output.
	Add more in the example about 'installed on target'.
	(GDB/MI Breakpoint Commands): Doc about 'installed field.

gdb/testsuite:
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* gdb.trace/mi-tracepoint-changed.exp (test_pending_resolved): Check
	'installed' field in '=breakpoint-modified'.
	(test_reconnect): Check 'installed' field in
	'=breakpoint-modified' and '=breakpoint-created'.

	* gdb.trace/actions.exp: Update test for 'installed' field.
	* gdb.trace/change-loc.exp (tracepoint_change_loc_1):
	(tracepoint_change_loc_2): Likewise.
	Check 'info tracepoint' display nothing else.
	* gdb.trace/deltrace.exp: Likewise.
	* gdb.trace/infotrace.exp: Likewise.
	* gdb.trace/mi-traceframe-changed.exp (test_tfind_remote):
	Likewise.
	* gdb.trace/passcount.exp: Likewise.
	* gdb.trace/tracecmd.exp: Likewise.
	* gdb.trace/while-stepping.exp: Likewise.
2012-12-15 02:19:21 +00:00
Cary Coutant 59965708ea gold/
* testsuite/Makefile.am (exception_separate_shared_12_test): Add
    	--no-as-needed flag.
    	(exception_separate_shared_12_test): Likewise.
    	(incremental_copy_test): Likewise.
    	* testsuite/Makefile.in: Regenerate.
2012-12-15 01:55:08 +00:00
Yao Qi 7ed2c99418 gdb/
2012-12-15  Yao Qi  <yao@codesourcery.com>

	* breakpoint.c (download_tracepoint_locations): Iterate over
	ALL_TRACEPOINTS first and then iterate over locations of
	each tracepoint.
2012-12-15 01:37:03 +00:00
Cary Coutant 2a77e2ab18 gold/
* dwp.cc (Dwp_output_file::add_cu_set): Check for duplicate CUs.
	(Dwp_output_file::Dwp_index::enter_set): Add assert.
2012-12-15 00:57:30 +00:00
gdbadmin fcb94e69be *** empty log message *** 2012-12-15 00:00:39 +00:00
Pierre Muller b25d79d436 * solib-target.c (solib_target_current_sos): Remove 'const'
qualifier from type of library_document local variable to be
	able to free it and avoid a memory leak.
	Use cleanup chain to avoid leak even if exceptino is generated.
2012-12-14 23:27:13 +00:00