From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25878 invoked by alias); 8 Jul 2008 08:27:53 -0000 Received: (qmail 25870 invoked by uid 22791); 8 Jul 2008 08:27:53 -0000 X-Spam-Check-By: sourceware.org Received: from f183.mail.ru (HELO f183.mail.ru) (194.67.57.216) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 08 Jul 2008 08:27:26 +0000 Received: from mail by f183.mail.ru with local id 1KG8Xg-000FJj-00 for gdb@sourceware.org; Tue, 08 Jul 2008 12:27:20 +0400 Received: from [212.92.145.7] by win.mail.ru with HTTP; Tue, 08 Jul 2008 12:27:20 +0400 From: Dmitry Smirnov To: gdb@sourceware.org Subject: =?koi8-r?Q?Re=3A_How_to_catch_GDB_crash?= Mime-Version: 1.0 X-Mailer: mPOP Web-Mail 2.19 Date: Tue, 08 Jul 2008 08:27:00 -0000 References: <200807071700.38268.pedro_alves@portugalmail.pt> In-Reply-To: <200807071700.38268.pedro_alves@portugalmail.pt> Reply-To: Dmitry Smirnov Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 8bit Message-Id: X-Spam: Not detected X-Mras: OK X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2008-07/txt/msg00053.txt.bz2 Thanks, Most likely I've found the root cause: mi_on_resume() does not flush raw_stdout. I've added "gdb_flush (raw_stdout)" at the end of this function and everything seems to work fine. Also, I've found a solution for Eclipse problem when it unable to work correctly after this "^running". On my mind it does not related to GDB (and to delayed "^running" :-) ), so I have no problems with GDB at this moment. M-m-m, there is just one weird and minor observation: just after "target remote:12345" executed, Eclipse shows two identical threads: Thread[0] and Thread[1]. They are stopped at the same address. After I issued "-exec-continue" and GDB hits the breakpoint, Eclipse shows just one thread: Thread[1] with a correct call stack. Perhaps, I will have some time to debug it and get back if this is related to GDB. Thanks! Dmitry -----Original Message----- From: Pedro Alves To: gdb@sourceware.org, Dmitry Smirnov Date: Mon, 7 Jul 2008 17:00:37 +0100 Subject: Re: How to catch GDB crash > > A Monday 07 July 2008 16:47:26, Dmitry Smirnov wrote: > > Perhaps, "info threads" is fixed. But since both "info threads" and > > "running" problems were [most probably] caused by the "main thread > > registering" fix, maybe it is better to investigate "^running" problem > > before submission? What if they are connected? ;-) > > I seriously doubt they are connected. The code to output "^running" > has nothing to do with having threads or not. > > > I have to say, that my goal is not just report issues, I would like to help > > fixing them. > > Welcome on board! We need all the help we can get. > > > Unfortunately, I do not have much time to learn GDB, so I'm > > just asking for hints: what can I do to discover the root cause. > > The best way is to do a binary search on the CVS HEAD sources, to > find the patch that caused your issue. > > > For > > example, who is responding "^running"? What functions/files should I debug > > to figure out the problem? > > Grepping for "^running" should get you there. > > See here, your issue was most likelly introduced by this: > http://sourceware.org/ml/gdb-patches/2008-06/msg00247.html > > -- > Pedro Alves >