From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25541 invoked by alias); 8 Aug 2008 01:40:46 -0000 Received: (qmail 25532 invoked by uid 22791); 8 Aug 2008 01:40:46 -0000 X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.4) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 08 Aug 2008 01:40:11 +0000 Received: (qmail 32751 invoked from network); 8 Aug 2008 01:40:09 -0000 Received: from unknown (HELO orlando.local) (pedro@127.0.0.2) by mail.codesourcery.com with ESMTPA; 8 Aug 2008 01:40:09 -0000 From: Pedro Alves To: gdb-patches@sourceware.org Subject: [7/7] Adjust the SPU linux native target Date: Fri, 08 Aug 2008 01:40:00 -0000 User-Agent: KMail/1.9.9 MIME-Version: 1.0 Content-Type: Multipart/Mixed; boundary="Boundary-00=_iQ6mIK4DSKPX01R" Message-Id: <200808080240.50260.pedro@codesourcery.com> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-08/txt/msg00176.txt.bz2 --Boundary-00=_iQ6mIK4DSKPX01R Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Content-length: 391 Now that the fork_inferior takes care of adding the main thread for the target_create_inferior case, and inf_ptrace_attach adds it for the target_attach case, the SPU target, which extends the ptrace target should no longer add it. Unfortunatelly, I have no means to test this. Ulrich, does this look OK? You only need patches 1, 2 and this one for the SPU changes. OK? -- Pedro Alves --Boundary-00=_iQ6mIK4DSKPX01R Content-Type: text/x-diff; charset="utf-8"; name="007-spu.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="007-spu.diff" Content-length: 1045 2008-08-08 Pedro Alves * spu-linux-nat.c (spu_child_post_startup_inferior) (spu_child_post_attach): Don't add the main thread here. --- gdb/spu-linux-nat.c | 4 ---- 1 file changed, 4 deletions(-) Index: src/gdb/spu-linux-nat.c =================================================================== --- src.orig/gdb/spu-linux-nat.c 2008-07-29 11:29:27.000000000 +0100 +++ src/gdb/spu-linux-nat.c 2008-07-29 11:31:12.000000000 +0100 @@ -376,8 +376,6 @@ spu_child_post_startup_inferior (ptid_t ptrace (PT_SYSCALL, tid, (PTRACE_TYPE_ARG3) 0, 0); waitpid (tid, NULL, __WALL | __WNOTHREAD); } - - add_thread_silent (ptid); } /* Override the post_attach routine to try load the SPE executable @@ -397,8 +395,6 @@ spu_child_post_attach (int pid) waitpid (pid, NULL, __WALL | __WNOTHREAD); } - add_thread_silent (inferior_ptid); - /* If the user has not provided an executable file, try to extract the image from inside the target process. */ if (!get_exec_file (0)) --Boundary-00=_iQ6mIK4DSKPX01R--