From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21452 invoked by alias); 5 Sep 2014 08:48:44 -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 21439 invoked by uid 89); 5 Sep 2014 08:48:44 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_SOFTFAIL autolearn=no version=3.3.2 X-HELO: mtaout22.012.net.il Received: from mtaout22.012.net.il (HELO mtaout22.012.net.il) (80.179.55.172) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 05 Sep 2014 08:48:42 +0000 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0NBF00K006TAWV00@a-mtaout22.012.net.il> for gdb-patches@sourceware.org; Fri, 05 Sep 2014 11:48:39 +0300 (IDT) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0NBF00K0F753EZ90@a-mtaout22.012.net.il>; Fri, 05 Sep 2014 11:48:39 +0300 (IDT) Date: Fri, 05 Sep 2014 08:48:00 -0000 From: Eli Zaretskii Subject: Re: [PATCH][PR guile/17247] Block SIGCHLD while initializing Guile In-reply-to: To: Doug Evans Cc: ludo@gnu.org, guile-devel@gnu.org, gdb-patches@sourceware.org Reply-to: Eli Zaretskii Message-id: <83a96ee9lk.fsf@gnu.org> References: <834mwsh2nu.fsf@gnu.org> <8338ccgj78.fsf@gnu.org> <87ppffabw8.fsf@gnu.org> <83y4u3flr2.fsf@gnu.org> <87r3zv71qy.fsf@gnu.org> <83vbp7fer3.fsf@gnu.org> <83iol6f3iy.fsf@gnu.org> X-IsSubscribed: yes X-SW-Source: 2014-09/txt/msg00139.txt.bz2 > From: Doug Evans > Cc: ludo@gnu.org, guile-devel@gnu.org, gdb-patches@sourceware.org > Date: Fri, 05 Sep 2014 01:26:28 -0700 > > we can't physically prevent [users] from starting threads. Of course we can: if Guile gives us a way to disable threads, any user extension that attempts to start a thread will simply fail. > We pretty much leave them that way already given the myriad > of things they can do to mess up gdb without threads. ?? The rest of GDB is compiled C code which users cannot change without recompiling. And it's a single-threaded code. And it's under our close scrutiny. So I see no problems here. > The python side of things is too silent on whether threads are supported > there. > https://sourceware.org/gdb/current/onlinedocs/gdb/Basic-Python.html#Basic-Python I simply don't know enough about Python to discuss this; I do know about Guile. If Python extensions can start threads, then the same considerations apply there. And if the Python side didn't disallow that until now, it doesn't sound like a good excuse to add insult to injury on the Guile side. > At any rate, the task at hand is getting gdb to work well with Guile, > regardless of whether the user starts any threads, > and that's the intent of the patch. If we disable threads, this patch is unneeded, as are all the future patches I envision that will have to deal with these issues. We kill the problem cleanly and once and for all. From where I stand, it's a no-brainer. > I am happy to make the default value of GC_MARKERS be 1 (regardless > of libgc version, and if not already set by the user) when initializing Guile, > that will disable libgc marker threads. That'd be fine with me, thanks.