From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32625 invoked by alias); 14 Dec 2007 19:55:55 -0000 Received: (qmail 32616 invoked by uid 22791); 14 Dec 2007 19:55:54 -0000 X-Spam-Check-By: sourceware.org Received: from sibelius.xs4all.nl (HELO brahms.sibelius.xs4all.nl) (82.92.89.47) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 14 Dec 2007 19:55:50 +0000 Received: from brahms.sibelius.xs4all.nl (kettenis@localhost.sibelius.xs4all.nl [127.0.0.1]) by brahms.sibelius.xs4all.nl (8.14.1/8.14.0) with ESMTP id lBEJsTbq006387; Fri, 14 Dec 2007 20:54:29 +0100 (CET) Received: (from kettenis@localhost) by brahms.sibelius.xs4all.nl (8.14.1/8.14.1/Submit) id lBEJsSIZ006435; Fri, 14 Dec 2007 20:54:28 +0100 (CET) Date: Fri, 14 Dec 2007 20:37:00 -0000 Message-Id: <200712141954.lBEJsSIZ006435@brahms.sibelius.xs4all.nl> From: Mark Kettenis To: vladimir@codesourcery.com CC: gdb-patches@sources.redhat.com In-reply-to: <200712142240.20597.vladimir@codesourcery.com> (message from Vladimir Prus on Fri, 14 Dec 2007 22:40:20 +0300) Subject: Re: [RFA] Inform about new thread in a single place. References: <200712142009.08263.vladimir@codesourcery.com> <200712142207.19754.vladimir@codesourcery.com> <200712141920.lBEJKVI1027649@brahms.sibelius.xs4all.nl> <200712142240.20597.vladimir@codesourcery.com> 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: 2007-12/txt/msg00196.txt.bz2 > From: Vladimir Prus > Date: Fri, 14 Dec 2007 22:40:20 +0300 > > > > What about me adding 'add_thread_silent' function that will > > > not print any message, and using it in bds-uthread.c? > > > > That'd be acceptable to me. I'm not absolutely true that none of the > > modules you mention above don't need this, but we can fix those when > > we notice the problem. > > Here's the revised patch. OK? I don't think so. Look at the output from debugging a threaded program and ask yourself if you really have that many new threads ;) Also, this makes some platforms now print the message, where it didn't before (for example on win32). Please make sure you get approval from the relevant maintainers for any changed behaviour. Cheers, Mark > * thread.c (add_thread_silent): Renamed > from add_thread. > (add_thread): Announce new thread. > * gdbthread.h (add_thread_silent): Declare. > * inf-ttrace.c (inf_ttrace_wait): Don't > inform about new thread, as add_thread is always > called too, and will take care of that. > * infrun.c (handle_inferior_event): Likewise. > * procfs.c (procfs_wait): Likewise. > * remote.c (remote_currthread): Likewise. > * sol-thread.c (sol_thread_wait): Likewise. > * win32-nat.c (get_win32_debug_event): Likewise. > * gdb/linux-nat.c (lin_lwp_attach_lwp): Likewise. > * linux-thread-db.c (attach_thread): Don't inform > about new thread. This is called only from > linux-thread-db.c:attach_thread, which will take care.