From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12835 invoked by alias); 15 May 2014 15:53:38 -0000 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 Received: (qmail 12821 invoked by uid 89); 15 May 2014 15:53:38 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 15 May 2014 15:53:37 +0000 Received: from svr-orw-fem-01.mgc.mentorg.com ([147.34.98.93]) by relay1.mentorg.com with esmtp id 1WkxyP-0000QN-Sq from Luis_Gustavo@mentor.com ; Thu, 15 May 2014 08:53:33 -0700 Received: from NA1-MAIL.mgc.mentorg.com ([147.34.98.181]) by svr-orw-fem-01.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Thu, 15 May 2014 08:53:33 -0700 Received: from [172.30.4.64] ([172.30.4.64]) by NA1-MAIL.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 15 May 2014 08:53:33 -0700 Message-ID: <5374E2ED.6050802@codesourcery.com> Date: Thu, 15 May 2014 15:53:00 -0000 From: Luis Machado Reply-To: lgustavo@codesourcery.com User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: David Taylor CC: "gdb-patches@sourceware.org" Subject: Re: gdb.texinfo patch References: <10463.1400167510@usendtaylorx2l> <5374DE29.3010606@codesourcery.com> <10665.1400168921@usendtaylorx2l> In-Reply-To: <10665.1400168921@usendtaylorx2l> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2014-05/txt/msg00245.txt.bz2 On 05/15/2014 12:48 PM, David Taylor wrote: > Luis Machado wrote: > >> On 05/15/2014 12:25 PM, David Taylor wrote: >>> In writing a new stub (to replace our old stub), I have discovered what >>> I believe to be the rule for how GDB chooses which thread to stop during >>> the initial connection. Knowing this sooner would have saved my some >>> grief. Hoping to help the next person avoid that same grief, here's a >>> patch (as a unified diff against gdb/doc/gdb.texinfo of GDB 7.7) to >>> document it. > > [...] > >> Does GDB always want to stop the thread, even when "may-interrupt" is=20 >> set to "off"? > > I wasn't aware of that variable, so I don't know. It will require some > investigation. Certainly with non-stop mode turned on and may-interrupt > at the default value, it stops it. > Yeah. Unfortunately it is another one of those obscure settings. :-) Given we have this option, it may be worth mentioning it in the piece you are patching, just for the sake of completeness. Otherwise folks may think GDB will always stop the threads when connecting. It will stop most of the time anyway, since it is the default after all. Luis