From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12629 invoked by alias); 31 Jan 2012 08:18:54 -0000 Received: (qmail 12617 invoked by uid 22791); 31 Jan 2012 08:18:51 -0000 X-SWARE-Spam-Status: No, hits=-1.4 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 31 Jan 2012 08:18:38 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1Rs8vF-0005z3-HY from Yao_Qi@mentor.com for gdb-patches@sourceware.org; Tue, 31 Jan 2012 00:18:37 -0800 Received: from SVR-ORW-FEM-04.mgc.mentorg.com ([147.34.97.41]) by svr-orw-fem-01.mgc.mentorg.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Tue, 31 Jan 2012 00:18:37 -0800 Received: from [127.0.0.1] (147.34.91.1) by svr-orw-fem-04.mgc.mentorg.com (147.34.97.41) with Microsoft SMTP Server id 14.1.289.1; Tue, 31 Jan 2012 00:18:36 -0800 Message-ID: <4F27A3DC.4010502@codesourcery.com> Date: Tue, 31 Jan 2012 08:22:00 -0000 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:9.0) Gecko/20111220 Thunderbird/9.0 MIME-Version: 1.0 To: Hui Zhu CC: Subject: Re: [PATCH] Fix error when gdb connect to a stub that tracepoint is running[0/2] References: <4F274C2C.7090107@mentor.com> In-Reply-To: <4F274C2C.7090107@mentor.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit 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: 2012-01/txt/msg01010.txt.bz2 On 01/31/2012 10:04 AM, Hui Zhu wrote: > (gdb) info tracepoints > Num Type Disp Enb Address What > 1 tracepoint keep y 0x0000000000400557 in main at 1.c:15 > collect $reg > (gdb) set disconnected-tracing on > (gdb) tstart > (gdb) disconnect > Trace is running and will continue after detach; detach anyway? (y or n) y > Ending remote debugging. > (gdb) target remote localhost:1234 > Remote debugging using localhost:1234 > Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols > found)...done. > Loaded symbols for /lib64/ld-linux-x86-64.so.2 > Error in re-setting breakpoint 1: Target returns error code '01'. > Target returns error code '01'. > (gdb) disconnect > You can't do that when your target is `exec' > (gdb) quit > gdb ./a.out > (gdb) target remote localhost:1234 > Remote debugging using localhost:1234 > Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols > found)...done. > Loaded symbols for /lib64/ld-linux-x86-64.so.2 > 0x00007ffff7ddcaf0 in ?? () from /lib64/ld-linux-x86-64.so.2 > Trace is already running on the target. > Tracepoint 1 at 0x400557: file 1.c, line 15. > Target returns error code '01'. > Yes, this is a bug. It is better if we can convert these steps into a .exp test case :). -- Yao (齐尧)