From owner-freebsd-threads@FreeBSD.ORG Mon Apr 11 11:02:24 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F1A8B16A4CF for ; Mon, 11 Apr 2005 11:02:23 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id C9A9643D48 for ; Mon, 11 Apr 2005 11:02:23 +0000 (GMT) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (peter@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3BB2NIJ088351 for ; Mon, 11 Apr 2005 11:02:23 GMT (envelope-from owner-bugmaster@freebsd.org) Received: (from peter@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j3BB2NL3088345 for freebsd-threads@freebsd.org; Mon, 11 Apr 2005 11:02:23 GMT (envelope-from owner-bugmaster@freebsd.org) Date: Mon, 11 Apr 2005 11:02:23 GMT Message-Id: <200504111102.j3BB2NL3088345@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: peter set sender to owner-bugmaster@freebsd.org using -f From: FreeBSD bugmaster To: freebsd-threads@FreeBSD.org Subject: Current problem reports assigned to you X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2005 11:02:24 -0000 Current FreeBSD problem reports Critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2004/04/22] threads/65883threads libkse's sigwait does not work after fork o [2005/01/26] threads/76690threads fork hang in child for (-lc_r & -lthr) 2 problems total. Serious problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2000/07/18] kern/20016 threads pthreads: Cannot set scheduling timer/Can o [2000/08/26] kern/20861 threads libc_r does not honor socket timeouts o [2001/01/20] threads/24472threads libc_r does not honor SO_SNDTIMEO/SO_RCVT o [2001/01/25] threads/24632threads libc_r delicate deviation from libc in ha o [2001/01/25] kern/24641 threads pthread_rwlock_rdlock can deadlock o [2001/11/26] bin/32295 threads pthread dont dequeue signals o [2002/02/01] threads/34536threads accept() blocks other threads o [2002/05/25] kern/38549 threads the procces compiled whith pthread stoppe o [2002/06/27] threads/39922threads [PATCH?] Threaded applications executed w o [2002/08/04] kern/41331 threads Pthread library open sets O_NONBLOCK flag o [2003/03/02] threads/48856threads Setting SIGCHLD to SIG_IGN still leaves z o [2003/03/10] threads/49087threads Signals lost in programs linked with libc o [2003/05/08] threads/51949threads thread in accept cannot be cancelled s [2004/03/15] kern/64313 threads FreeBSD (OpenBSD) pthread implicit set/un o [2004/08/26] threads/70975threads unexpected and unreliable behaviour when o [2004/09/14] threads/71725threads Mysql Crashes frequently giving Sock Erro o [2004/10/05] threads/72353threads Assertion fails in /usr/src/lib/libpthrea o [2004/10/07] threads/72429threads threads blocked in stdio (fgets, etc) are o [2004/10/21] threads/72953threads fork() unblocks blocked signals w/o PTHRE o [2004/11/25] threads/74370threads Cannot get lwp 0 registers in gdb o [2004/12/19] threads/75273threads FBSD 5.3 libpthread (KSE) bug o [2004/12/21] threads/75374threads pthread_kill() ignores SA_SIGINFO flag o [2005/01/04] threads/75795threads applications linked with -lc_r can't clos o [2005/01/26] threads/76694threads fork cause hang in dup()/close() function o [2005/03/10] threads/78660threads Java hangs unkillably in STOP state after o [2005/04/08] threads/79683threads svctcp_create() fails if multiple threads 26 problems total. Non-critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2000/05/26] kern/18824 threads gethostbyname is not thread safe o [2000/06/13] kern/19247 threads uthread_sigaction.c does not do anything o [2000/10/21] kern/22190 threads A threaded read(2) from a socketpair(2) f o [2001/09/09] threads/30464threads pthread mutex attributes -- pshared o [2002/05/02] threads/37676threads libc_r: msgsnd(), msgrcv(), pread(), pwri s [2002/07/16] threads/40671threads pthread_cancel doesn't remove thread from o [2004/07/13] threads/69020threads pthreads library leaks _gc_mutex o [2004/09/21] threads/71966threads Mlnet Core Dumped : Fatal error '_pq_inse o [2004/11/21] threads/74180threads KSE problem. Applications those riched ma o [2005/01/20] threads/76513threads libpthread is not working o [2005/02/01] threads/76938threads include/unistd.h: ttyname_r prototype mis o [2005/04/04] threads/79526threads A memory leak in pthread_rwlock_init() 12 problems total. From owner-freebsd-threads@FreeBSD.ORG Mon Apr 11 12:10:36 2005 Return-Path: Delivered-To: freebsd-threads@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 19C6A16A4CE for ; Mon, 11 Apr 2005 12:10:36 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id E1D3543D1F for ; Mon, 11 Apr 2005 12:10:35 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3BCAZCs002871 for ; Mon, 11 Apr 2005 12:10:35 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j3BCAZmU002870; Mon, 11 Apr 2005 12:10:35 GMT (envelope-from gnats) Date: Mon, 11 Apr 2005 12:10:35 GMT Message-Id: <200504111210.j3BCAZmU002870@freefall.freebsd.org> To: freebsd-threads@FreeBSD.org From: Marc Olzheim Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Marc Olzheim List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2005 12:10:36 -0000 The following reply was made to PR threads/76690; it has been noted by GNATS. From: Marc Olzheim To: freebsd-gnats-submit@FreeBSD.org, lse@CryptoPro.ru Cc: Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) Date: Mon, 11 Apr 2005 14:03:01 +0200 Confirmed to be b0rken on FreeBSD 4.11's libc_r as well. :-/ Marc From owner-freebsd-threads@FreeBSD.ORG Mon Apr 11 12:26:18 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 688C316A4CF; Mon, 11 Apr 2005 12:26:18 +0000 (GMT) Received: from mailhost.stack.nl (vaak.stack.nl [131.155.140.140]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9136643D2D; Mon, 11 Apr 2005 12:26:17 +0000 (GMT) (envelope-from marcolz@stack.nl) Received: from hammer.stack.nl (hammer.stack.nl [IPv6:2001:610:1108:5010::153]) by mailhost.stack.nl (Postfix) with ESMTP id 821F51F039; Mon, 11 Apr 2005 14:26:16 +0200 (CEST) Received: by hammer.stack.nl (Postfix, from userid 333) id 55539613F; Mon, 11 Apr 2005 14:26:16 +0200 (CEST) Date: Mon, 11 Apr 2005 14:26:16 +0200 From: Marc Olzheim To: Max Fomitchev Message-ID: <20050411122616.GA34699@stack.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Operating-System: FreeBSD hammer.stack.nl 5.4-STABLE FreeBSD 5.4-STABLE X-URL: http://www.stack.nl/~marcolz/ User-Agent: Mutt/1.5.9i cc: freebsd-gnats-submit@freebsd.org cc: freebsd-threads@freebsd.org Subject: Re: threads/65883: libkse's sigwait does not work after fork X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2005 12:26:18 -0000 This was fixed a long time ago. I suppose this can be closed ? Marc From owner-freebsd-threads@FreeBSD.ORG Mon Apr 11 12:30:32 2005 Return-Path: Delivered-To: freebsd-threads@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 54D9216A4CE for ; Mon, 11 Apr 2005 12:30:32 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2806943D39 for ; Mon, 11 Apr 2005 12:30:32 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3BCUWAn003354 for ; Mon, 11 Apr 2005 12:30:32 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j3BCUVPZ003351; Mon, 11 Apr 2005 12:30:31 GMT (envelope-from gnats) Date: Mon, 11 Apr 2005 12:30:31 GMT Message-Id: <200504111230.j3BCUVPZ003351@freefall.freebsd.org> To: freebsd-threads@FreeBSD.org From: Marc Olzheim Subject: Re: threads/65883: libkse's sigwait does not work after fork X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Marc Olzheim List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2005 12:30:32 -0000 The following reply was made to PR threads/65883; it has been noted by GNATS. From: Marc Olzheim To: Max Fomitchev Cc: freebsd-gnats-submit@freebsd.org, freebsd-threads@freebsd.org Subject: Re: threads/65883: libkse's sigwait does not work after fork Date: Mon, 11 Apr 2005 14:26:16 +0200 This was fixed a long time ago. I suppose this can be closed ? Marc From owner-freebsd-threads@FreeBSD.ORG Mon Apr 11 23:05:35 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0DB2516A4CE for ; Mon, 11 Apr 2005 23:05:35 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id D26E643D1F; Mon, 11 Apr 2005 23:05:34 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from [127.0.0.1] (davidxu@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3BN5Xuf085694; Mon, 11 Apr 2005 23:05:34 GMT (envelope-from davidxu@freebsd.org) Message-ID: <425B02BB.5060904@freebsd.org> Date: Tue, 12 Apr 2005 07:05:31 +0800 From: David Xu User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.5) Gecko/20050306 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Marc Olzheim References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> In-Reply-To: <200504111210.j3BCAZmU002870@freefall.freebsd.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2005 23:05:35 -0000 Marc Olzheim wrote: >The following reply was made to PR threads/76690; it has been noted by GNATS. > >From: Marc Olzheim >To: freebsd-gnats-submit@FreeBSD.org, lse@CryptoPro.ru >Cc: >Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) >Date: Mon, 11 Apr 2005 14:03:01 +0200 > > Confirmed to be b0rken on FreeBSD 4.11's libc_r as well. :-/ > > Marc > > > This is no longer true for libthr, I can not close the PR because it also reports libc_r problem. David Xu From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 07:12:22 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C060B16A4CE; Tue, 12 Apr 2005 07:12:22 +0000 (GMT) Received: from mailhost.stack.nl (vaak.stack.nl [131.155.140.140]) by mx1.FreeBSD.org (Postfix) with ESMTP id B34E343D53; Tue, 12 Apr 2005 07:12:21 +0000 (GMT) (envelope-from marcolz@stack.nl) Received: from hammer.stack.nl (hammer.stack.nl [IPv6:2001:610:1108:5010::153]) by mailhost.stack.nl (Postfix) with ESMTP id A9C641F1FF; Tue, 12 Apr 2005 09:12:20 +0200 (CEST) Received: by hammer.stack.nl (Postfix, from userid 333) id 888216250; Tue, 12 Apr 2005 09:12:20 +0200 (CEST) Date: Tue, 12 Apr 2005 09:12:20 +0200 From: Marc Olzheim To: David Xu Message-ID: <20050412071220.GA17393@stack.nl> References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="opJtzjQTFsWo+cga" Content-Disposition: inline In-Reply-To: <425B02BB.5060904@freebsd.org> X-Operating-System: FreeBSD hammer.stack.nl 5.4-STABLE FreeBSD 5.4-STABLE X-URL: http://www.stack.nl/~marcolz/ User-Agent: Mutt/1.5.9i cc: Marc Olzheim cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 07:12:23 -0000 --opJtzjQTFsWo+cga Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Apr 12, 2005 at 07:05:31AM +0800, David Xu wrote: > >Confirmed to be b0rken on FreeBSD 4.11's libc_r as well. :-/ > > > >Marc > > > This is no longer true for libthr, I can not close the PR > because it also reports libc_r problem. I know, I didn't ask for it to be closed. :-) Is there any info on where the bug could be ? I could take a look at it... Marc --opJtzjQTFsWo+cga Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (FreeBSD) iD8DBQFCW3TUezjnobFOgrERArUuAKCb3Z0H171YzrJcaweq0z5qBS+q2gCgkHDL dT34N1RyNJROgqqW/VHyLIU= =wPzq -----END PGP SIGNATURE----- --opJtzjQTFsWo+cga-- From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 08:19:11 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F125D16A4CE; Tue, 12 Apr 2005 08:19:11 +0000 (GMT) Received: from mail.emict.com (brig.emict.com [212.90.172.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7DB9043D45; Tue, 12 Apr 2005 08:19:10 +0000 (GMT) (envelope-from andrit@ukr.net) Received: from [10.0.0.232] (unknown [10.0.0.232]) by mail.emict.com (Postfix) with ESMTP id 397462EB52; Tue, 12 Apr 2005 11:19:04 +0300 (EEST) From: Andriy Tkachuk Organization: eMICT To: freebsd-threads@freebsd.org Date: Tue, 12 Apr 2005 11:19:03 +0300 User-Agent: KMail/1.7 References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> <20050412071220.GA17393@stack.nl> In-Reply-To: <20050412071220.GA17393@stack.nl> MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-u" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200504121119.03985.andrit@ukr.net> cc: Marc Olzheim cc: David Xu Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 08:19:12 -0000 http://lists.freebsd.org/pipermail/freebsd-threads/2005-March/002935.html try this patch. On Tuesday 12 April 2005 10:12, Marc Olzheim wrote: > On Tue, Apr 12, 2005 at 07:05:31AM +0800, David Xu wrote: > > >Confirmed to be b0rken on FreeBSD 4.11's libc_r as well. :-/ > > > > > >Marc > > > > This is no longer true for libthr, I can not close the PR > > because it also reports libc_r problem. > > I know, I didn't ask for it to be closed. :-) > Is there any info on where the bug could be ? I could take a look at > it... > > Marc From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 08:26:53 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 60E9F16A4CE for ; Tue, 12 Apr 2005 08:26:53 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 480CF43D46; Tue, 12 Apr 2005 08:26:53 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from [127.0.0.1] (davidxu@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3C8Qnox084860; Tue, 12 Apr 2005 08:26:50 GMT (envelope-from davidxu@freebsd.org) Message-ID: <425B866C.4010609@freebsd.org> Date: Tue, 12 Apr 2005 16:27:24 +0800 From: David Xu User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.6) Gecko/20050319 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Marc Olzheim References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> <20050412071220.GA17393@stack.nl> In-Reply-To: <20050412071220.GA17393@stack.nl> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 08:26:53 -0000 Marc Olzheim wrote: >On Tue, Apr 12, 2005 at 07:05:31AM +0800, David Xu wrote: > > >>>Confirmed to be b0rken on FreeBSD 4.11's libc_r as well. :-/ >>> >>>Marc >>> >>> >>> >>This is no longer true for libthr, I can not close the PR >>because it also reports libc_r problem. >> >> > >I know, I didn't ask for it to be closed. :-) >Is there any info on where the bug could be ? I could take a look at >it... > >Marc > > You have to fix it in uthread_fork.c, lock __malloc_lock over __sys_fork() call. but why libc_r ? it is depreciated. David Xu From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 08:30:00 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3E32D16A4CE; Tue, 12 Apr 2005 08:30:00 +0000 (GMT) Received: from mailhost.stack.nl (vaak.stack.nl [131.155.140.140]) by mx1.FreeBSD.org (Postfix) with ESMTP id EC0D143D45; Tue, 12 Apr 2005 08:29:59 +0000 (GMT) (envelope-from marcolz@stack.nl) Received: from hammer.stack.nl (hammer.stack.nl [IPv6:2001:610:1108:5010::153]) by mailhost.stack.nl (Postfix) with ESMTP id 55A531F1AA; Tue, 12 Apr 2005 10:29:59 +0200 (CEST) Received: by hammer.stack.nl (Postfix, from userid 333) id 418976377; Tue, 12 Apr 2005 10:29:59 +0200 (CEST) Date: Tue, 12 Apr 2005 10:29:59 +0200 From: Marc Olzheim To: David Xu Message-ID: <20050412082959.GA17607@stack.nl> References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> <20050412071220.GA17393@stack.nl> <425B866C.4010609@freebsd.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="y0ulUmNC+osPPQO6" Content-Disposition: inline In-Reply-To: <425B866C.4010609@freebsd.org> X-Operating-System: FreeBSD hammer.stack.nl 5.4-STABLE FreeBSD 5.4-STABLE X-URL: http://www.stack.nl/~marcolz/ User-Agent: Mutt/1.5.9i cc: Marc Olzheim cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 08:30:00 -0000 --y0ulUmNC+osPPQO6 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Apr 12, 2005 at 04:27:24PM +0800, David Xu wrote: > You have to fix it in uthread_fork.c, lock __malloc_lock over=20 > __sys_fork() call. > but why libc_r ? it is depreciated. Than drop support for it and remove it from base (move it to ports ?), or fix it... Besides from that: It's the only threading library available in FreeBSD 4.x, so I'd rather have it fixed. :-) Marc --y0ulUmNC+osPPQO6 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (FreeBSD) iD8DBQFCW4cGezjnobFOgrERAgjGAKCeN2odDGt+p6RUIAJLIpfzNNP+DACggdc3 lmVCGAe49eVqfnyU6Az+HVk= =x+Oc -----END PGP SIGNATURE----- --y0ulUmNC+osPPQO6-- From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 08:36:58 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0DC0D16A4CE for ; Tue, 12 Apr 2005 08:36:58 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id E6EFE43D39; Tue, 12 Apr 2005 08:36:57 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from [127.0.0.1] (davidxu@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3C8as8a086543; Tue, 12 Apr 2005 08:36:55 GMT (envelope-from davidxu@freebsd.org) Message-ID: <425B88C9.1000902@freebsd.org> Date: Tue, 12 Apr 2005 16:37:29 +0800 From: David Xu User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.6) Gecko/20050319 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Marc Olzheim References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> <20050412071220.GA17393@stack.nl> <425B866C.4010609@freebsd.org> <20050412082959.GA17607@stack.nl> In-Reply-To: <20050412082959.GA17607@stack.nl> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 08:36:58 -0000 Marc Olzheim wrote: >On Tue, Apr 12, 2005 at 04:27:24PM +0800, David Xu wrote: > > >>You have to fix it in uthread_fork.c, lock __malloc_lock over >>__sys_fork() call. >>but why libc_r ? it is depreciated. >> >> > >Than drop support for it and remove it from base (move it to ports ?), >or fix it... Besides from that: It's the only threading library >available in FreeBSD 4.x, so I'd rather have it fixed. :-) > >Marc > > 6.0-Release is the time to drop its support and move it to ports. :) David From owner-freebsd-threads@FreeBSD.ORG Tue Apr 12 20:43:46 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8467D16A4CE; Tue, 12 Apr 2005 20:43:46 +0000 (GMT) Received: from rwcrmhc13.comcast.net (rwcrmhc13.comcast.net [204.127.198.39]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4C07A43D39; Tue, 12 Apr 2005 20:43:46 +0000 (GMT) (envelope-from rodrigc@crodrigues.org) Received: from h00609772adf0.ne.client2.attbi.com ([66.30.114.143]) by comcast.net (rwcrmhc13) with ESMTP id <2005041220434401500grsjje>; Tue, 12 Apr 2005 20:43:45 +0000 Received: from h00609772adf0.ne.client2.attbi.com (localhost.127.in-addr.arpa [127.0.0.1])j3CKhctB004298; Tue, 12 Apr 2005 16:43:39 -0400 (EDT) (envelope-from rodrigc@h00609772adf0.ne.client2.attbi.com) Received: (from rodrigc@localhost)j3CKhcaq004297; Tue, 12 Apr 2005 16:43:38 -0400 (EDT) (envelope-from rodrigc) Date: Tue, 12 Apr 2005 16:43:37 -0400 From: Craig Rodrigues To: David Xu Message-ID: <20050412204337.GA4277@crodrigues.org> References: <200504111210.j3BCAZmU002870@freefall.freebsd.org> <425B02BB.5060904@freebsd.org> <20050412071220.GA17393@stack.nl> <425B866C.4010609@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <425B866C.4010609@freebsd.org> User-Agent: Mutt/1.5.9i cc: freebsd-threads@freebsd.org Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Apr 2005 20:43:46 -0000 On Tue, Apr 12, 2005 at 04:27:24PM +0800, David Xu wrote: > You have to fix it in uthread_fork.c, lock __malloc_lock over > __sys_fork() call. > but why libc_r ? it is depreciated. I know that many us don't like libc_r, ;), but has re@ made an official announcement about deprecating it? Until that happens, then libc_r will still remain in the tree, and people will use (and complain about) it. > 6.0-Release is the time to drop its support and move it to ports. :) Sounds good to me.....has re@ agreed to it? The sooner we can remove old crufty threading libraries from FreeBSD, the happier many of us will be! -- Craig Rodrigues rodrigc@crodrigues.org From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 12:38:13 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CF4B416A4CE; Wed, 13 Apr 2005 12:38:13 +0000 (GMT) Received: from zxy.spb.ru (zxy.spb.ru [194.58.105.35]) by mx1.FreeBSD.org (Postfix) with ESMTP id 809BA43D5D; Wed, 13 Apr 2005 12:38:13 +0000 (GMT) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.44 (FreeBSD)) id 1DLh8G-000LTY-5Z; Wed, 13 Apr 2005 16:38:12 +0400 Date: Wed, 13 Apr 2005 16:38:12 +0400 From: Slawa Olhovchenkov To: David Xu Message-ID: <20050413123811.GZ90506@zxy.spb.ru> References: <200504051228.j35CS55V094556@freefall.freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200504051228.j35CS55V094556@freefall.freebsd.org> User-Agent: Mutt/1.5.7i X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false cc: freebsd-threads@FreeBSD.org Subject: Re: threads/74856: dig/host broken w/ libthr X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 12:38:13 -0000 On Tue, Apr 05, 2005 at 12:28:05PM +0000, David Xu wrote: > Synopsis: dig/host broken w/ libthr > > State-Changed-From-To: open->closed > State-Changed-By: davidxu > State-Changed-When: Tue Apr 5 12:25:57 GMT 2005 > State-Changed-Why: > Can not reproduce in -CURRENT with newest libthr. > > http://www.freebsd.org/cgi/query-pr.cgi?pr=74856 Confirmed. Thanks! From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 20:46:38 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6D2F716A4CE; Wed, 13 Apr 2005 20:46:38 +0000 (GMT) Received: from silver.he.iki.fi (helenius.fi [193.64.42.241]) by mx1.FreeBSD.org (Postfix) with ESMTP id 365BA43D2F; Wed, 13 Apr 2005 20:46:37 +0000 (GMT) (envelope-from pete@he.iki.fi) Received: from [193.64.42.134] (h86.vuokselantie10.fi [193.64.42.134]) by silver.he.iki.fi (8.13.1/8.11.4) with ESMTP id j3DKkZnt067973; Wed, 13 Apr 2005 23:46:36 +0300 (EEST) (envelope-from pete@he.iki.fi) Message-ID: <425D8546.2050306@he.iki.fi> Date: Wed, 13 Apr 2005 23:47:02 +0300 From: Petri Helenius User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-threads@freebsd.org, phk@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 20:46:38 -0000 Is somebody already working on thread-optimizing malloc to have less contention, avoid false sharing issues, etc.? Pete From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 20:48:21 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 30B5216A4CE for ; Wed, 13 Apr 2005 20:48:21 +0000 (GMT) Received: from critter.freebsd.dk (f170.freebsd.dk [212.242.86.170]) by mx1.FreeBSD.org (Postfix) with ESMTP id B36F343D5E for ; Wed, 13 Apr 2005 20:48:19 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.13.3/8.13.1) with ESMTP id j3DKmIq1022335; Wed, 13 Apr 2005 22:48:18 +0200 (CEST) (envelope-from phk@critter.freebsd.dk) To: Petri Helenius From: "Poul-Henning Kamp" In-Reply-To: Your message of "Wed, 13 Apr 2005 23:47:02 +0300." <425D8546.2050306@he.iki.fi> Date: Wed, 13 Apr 2005 22:48:18 +0200 Message-ID: <22334.1113425298@critter.freebsd.dk> Sender: phk@critter.freebsd.dk cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 20:48:21 -0000 In message <425D8546.2050306@he.iki.fi>, Petri Helenius writes: > >Is somebody already working on thread-optimizing malloc to have less >contention, avoid false sharing issues, etc.? I'm not aware of any active work. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 21:31:31 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AE5DA16A4CE; Wed, 13 Apr 2005 21:31:31 +0000 (GMT) Received: from sccrmhc12.comcast.net (sccrmhc12.comcast.net [204.127.202.56]) by mx1.FreeBSD.org (Postfix) with ESMTP id EC65543D5A; Wed, 13 Apr 2005 21:31:30 +0000 (GMT) (envelope-from rodrigc@crodrigues.org) Received: from h00609772adf0.ne.client2.attbi.com ([66.30.114.143]) by comcast.net (sccrmhc12) with ESMTP id <2005041321312901200kjlime>; Wed, 13 Apr 2005 21:31:29 +0000 Received: from h00609772adf0.ne.client2.attbi.com (localhost.127.in-addr.arpa [127.0.0.1])j3DLVCPi010003; Wed, 13 Apr 2005 17:31:12 -0400 (EDT) (envelope-from rodrigc@h00609772adf0.ne.client2.attbi.com) Received: (from rodrigc@localhost)j3DLUnuO010002; Wed, 13 Apr 2005 17:30:49 -0400 (EDT) (envelope-from rodrigc) Date: Wed, 13 Apr 2005 17:30:38 -0400 From: Craig Rodrigues To: Petri Helenius Message-ID: <20050413213038.GA9991@crodrigues.org> References: <425D8546.2050306@he.iki.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <425D8546.2050306@he.iki.fi> User-Agent: Mutt/1.5.9i cc: phk@freebsd.org cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 21:31:31 -0000 On Wed, Apr 13, 2005 at 11:47:02PM +0300, Petri Helenius wrote: > > Is somebody already working on thread-optimizing malloc to have less > contention, avoid false sharing issues, etc.? Niall Douglas mentioned that FreeBSD might want to look at ptmalloc2 which is used in Linux: http://lists.freebsd.org/pipermail/freebsd-threads/2005-February/002848.html but I don't know if anyone is actively looking at this for FreeBSD. -- Craig Rodrigues rodrigc@crodrigues.org From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 22:41:53 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BAFB316A4CE for ; Wed, 13 Apr 2005 22:41:53 +0000 (GMT) Received: from bute.st-andrews.ac.uk (bute.st-and.ac.uk [138.251.12.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 338DA43D5D for ; Wed, 13 Apr 2005 22:41:52 +0000 (GMT) (envelope-from s_sourceforge@nedprod.com) Received: from kate (res04-ned6.res.st-and.ac.uk [138.251.234.67]) by bute.st-andrews.ac.uk (8.9.1a/8.9.1) with SMTP id XAA06796; Wed, 13 Apr 2005 23:36:51 +0100 (BST) From: "Niall Douglas" To: freebsd-threads@freebsd.org Date: Wed, 13 Apr 2005 23:41:19 +0100 MIME-Version: 1.0 Message-ID: <425DAE1F.5558.EDA8BD7@localhost> Priority: normal In-reply-to: <20050413213038.GA9991@crodrigues.org> References: <425D8546.2050306@he.iki.fi> X-mailer: Pegasus Mail for Windows (4.21c) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Content-Transfer-Encoding: 7BIT Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 22:41:53 -0000 On 13 Apr 2005 at 17:30, Craig Rodrigues wrote: > On Wed, Apr 13, 2005 at 11:47:02PM +0300, Petri Helenius wrote: > > > > Is somebody already working on thread-optimizing malloc to have less > > contention, avoid false sharing issues, etc.? > > Niall Douglas mentioned that FreeBSD might want to look at ptmalloc2 > which is used in Linux: > > http://lists.freebsd.org/pipermail/freebsd-threads/2005-February/00284 > 8.html > > but I don't know if anyone is actively looking at this for FreeBSD. I've already ported ptmalloc2 to FreeBSD. The performance increase is steller to put it mildly, even with FreeBSD's poor multithreading performance. You're talking ten or more times faster in heavily multithreaded code :) http://www.nedprod.com/programs/Win32/ptmalloc2/index.html All it requires is someone to merge it with FreeBSD's libc. The licence is LGPL but the original ptmalloc2 is BSD-like. You almost certainly could replicate the glibc changes and thus maintain the BSD license in very little time. Cheers, Niall From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 22:52:40 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5BC3016A4CE for ; Wed, 13 Apr 2005 22:52:40 +0000 (GMT) Received: from pinus.cc.fer.hr (pinus.cc.fer.hr [161.53.73.18]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5641143D4C for ; Wed, 13 Apr 2005 22:52:39 +0000 (GMT) (envelope-from ivoras@fer.hr) Received: from [161.53.72.113] (lara.cc.fer.hr [161.53.72.113]) by pinus.cc.fer.hr (8.12.2/8.12.2) with ESMTP id j3DMrDB2023590; Thu, 14 Apr 2005 00:53:13 +0200 (MEST) Message-ID: <425DA2B0.5060504@fer.hr> Date: Thu, 14 Apr 2005 00:52:32 +0200 From: Ivan Voras User-Agent: Mozilla Thunderbird 1.0 (X11/20041213) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Niall Douglas References: <425D8546.2050306@he.iki.fi> <425DAE1F.5558.EDA8BD7@localhost> In-Reply-To: <425DAE1F.5558.EDA8BD7@localhost> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 22:52:40 -0000 Niall Douglas wrote: > I've already ported ptmalloc2 to FreeBSD. The performance increase is > steller to put it mildly, even with FreeBSD's poor multithreading > performance. You're talking ten or more times faster in heavily > multithreaded code :) No, don't do that - with this in current and the new libthr, when someone tries to benchmark mysql it will run so fast that time itself will start running backwards! From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 23:13:15 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C915B16A4CE for ; Wed, 13 Apr 2005 23:13:15 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id AE8CE43D55; Wed, 13 Apr 2005 23:13:15 +0000 (GMT) (envelope-from davidxu@freebsd.org) Received: from [127.0.0.1] (davidxu@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3DNDEbq029322; Wed, 13 Apr 2005 23:13:15 GMT (envelope-from davidxu@freebsd.org) Message-ID: <425DA78E.2050701@freebsd.org> Date: Thu, 14 Apr 2005 07:13:18 +0800 From: David Xu User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.7.5) Gecko/20050402 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Niall Douglas References: <425D8546.2050306@he.iki.fi> <425DAE1F.5558.EDA8BD7@localhost> In-Reply-To: <425DAE1F.5558.EDA8BD7@localhost> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 23:13:15 -0000 Niall Douglas wrote: >I've already ported ptmalloc2 to FreeBSD. The performance increase is >steller to put it mildly, even with FreeBSD's poor multithreading >performance. You're talking ten or more times faster in heavily >multithreaded code :) > > > Poor multithreading performance? I don't know what library you are talking about. I admit that malloc/free is the main bottleneck in userland, a SMP-aware and CPU locality allocator is welcome. >http://www.nedprod.com/programs/Win32/ptmalloc2/index.html > >All it requires is someone to merge it with FreeBSD's libc. The >licence is LGPL but the original ptmalloc2 is BSD-like. You almost >certainly could replicate the glibc changes and thus maintain the BSD >license in very little time. > >Cheers, >Niall > > > From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 23:14:46 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BB31516A4CF for ; Wed, 13 Apr 2005 23:14:46 +0000 (GMT) Received: from bute.st-andrews.ac.uk (bute.st-and.ac.uk [138.251.12.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id B1E4343D48 for ; Wed, 13 Apr 2005 23:14:45 +0000 (GMT) (envelope-from s_sourceforge@nedprod.com) Received: from kate (res04-ned6.res.st-and.ac.uk [138.251.234.67]) by bute.st-andrews.ac.uk (8.9.1a/8.9.1) with SMTP id AAA08400 for ; Thu, 14 Apr 2005 00:09:45 +0100 (BST) From: "Niall Douglas" To: freebsd-threads@freebsd.org Date: Thu, 14 Apr 2005 00:14:14 +0100 MIME-Version: 1.0 Message-ID: <425DB5D6.27535.EF8ACBB@localhost> Priority: normal In-reply-to: <425DA2B0.5060504@fer.hr> References: <425DAE1F.5558.EDA8BD7@localhost> X-mailer: Pegasus Mail for Windows (4.21c) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Content-Transfer-Encoding: 7BIT Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 23:14:46 -0000 On 14 Apr 2005 at 0:52, Ivan Voras wrote: > Niall Douglas wrote: > > > I've already ported ptmalloc2 to FreeBSD. The performance increase > > is steller to put it mildly, even with FreeBSD's poor multithreading > > performance. You're talking ten or more times faster in heavily > > multithreaded code :) > > > > No, don't do that - with this in current and the new libthr, when > someone tries to benchmark mysql it will run so fast that time itself > will start running backwards! > > Well even with ptmalloc2, my code runs at about eight times slower than on Linux :(. FreeBSD threads implementation still has a long way to go. Cheers, Niall From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 23:20:27 2005 Return-Path: Delivered-To: freebsd-threads@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6056E16A4CE for ; Wed, 13 Apr 2005 23:20:27 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2837143D2F for ; Wed, 13 Apr 2005 23:20:27 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j3DNKR4U029556 for ; Wed, 13 Apr 2005 23:20:27 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j3DNKRJ5029553; Wed, 13 Apr 2005 23:20:27 GMT (envelope-from gnats) Resent-Date: Wed, 13 Apr 2005 23:20:27 GMT Resent-Message-Id: <200504132320.j3DNKRJ5029553@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-threads@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Dmitrij Tejblum Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 345C716A4CE for ; Wed, 13 Apr 2005 23:11:05 +0000 (GMT) Received: from walrus-t.yandex.ru (walrus-t.yandex.ru [213.180.206.233]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4DB1D43D2D for ; Wed, 13 Apr 2005 23:11:04 +0000 (GMT) (envelope-from tejblum@walrus-t.yandex.ru) Received: from walrus-t.yandex.ru (localhost [127.0.0.1]) by walrus-t.yandex.ru (8.13.3/8.13.3) with ESMTP id j3DNB3Ds001478 for ; Thu, 14 Apr 2005 03:11:03 +0400 (MSD) (envelope-from tejblum@walrus-t.yandex.ru) Received: (from tejblum@localhost) by walrus-t.yandex.ru (8.13.3/8.13.3/Submit) id j3DNAxif001464; Thu, 14 Apr 2005 03:10:59 +0400 (MSD) (envelope-from tejblum) Message-Id: <200504132310.j3DNAxif001464@walrus-t.yandex.ru> Date: Thu, 14 Apr 2005 03:10:59 +0400 (MSD) From: Dmitrij Tejblum To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: threads/79887: [patch] freopen() isn't thread-safe X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Dmitrij Tejblum List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 23:20:27 -0000 >Number: 79887 >Category: threads >Synopsis: [patch] freopen() isn't thread-safe >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-threads >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Apr 13 23:20:26 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Dmitrij Tejblum >Release: FreeBSD 5.4-STABLE i386 >Organization: >Environment: >Description: The freopen() function (1) open the new file, (2) close the old file (3) dup2() the newly opened file to the file descriptor (wantfd) previously held by the old file. (As comments says, "Various C library routines assume stderr is always fd STDERR_FILENO"). So, between step (2) and step (3) the wantfd file descriptor is closed, and if another thread open a file it make take the wantfd descriptor. Then, after the dup2() call in step (3) above, a mess will happen. >How-To-Repeat: >Fix: Don't close the old file descriptor, the dup2() call will do the job. Index: freopen.c =================================================================== RCS file: /home/ncvs/src/lib/libc/stdio/freopen.c,v retrieving revision 1.13 diff -u -r1.13 freopen.c --- freopen.c 22 May 2004 15:19:41 -0000 1.13 +++ freopen.c 13 Apr 2005 22:56:48 -0000 @@ -155,14 +155,6 @@ /* Get a new descriptor to refer to the new file. */ f = _open(file, oflags, DEFFILEMODE); - if (f < 0 && isopen) { - /* If out of fd's close the old one and try again. */ - if (errno == ENFILE || errno == EMFILE) { - (void) (*fp->_close)(fp->_cookie); - isopen = 0; - f = _open(file, oflags, DEFFILEMODE); - } - } sverrno = errno; finish: @@ -171,8 +163,6 @@ * keep fp->_base: it may be the wrong size. This loses the effect * of any setbuffer calls, but stdio has always done this before. */ - if (isopen) - (void) (*fp->_close)(fp->_cookie); if (fp->_flags & __SMBF) free((char *)fp->_bf._base); fp->_w = 0; @@ -191,6 +181,8 @@ memset(&fp->_extra->mbstate, 0, sizeof(mbstate_t)); if (f < 0) { /* did not get it after all */ + if (isopen) + (void) (*fp->_close)(fp->_cookie); fp->_flags = 0; /* set it free */ errno = sverrno; /* restore in case _close clobbered */ FUNLOCKFILE(fp); @@ -202,10 +194,13 @@ * to maintain the descriptor. Various C library routines (perror) * assume stderr is always fd STDERR_FILENO, even if being freopen'd. */ - if (wantfd >= 0 && f != wantfd) { + if (wantfd >= 0) { if (_dup2(f, wantfd) >= 0) { (void)_close(f); f = wantfd; + } else { + if (isopen) + (void) (*fp->_close)(fp->_cookie); } } >Release-Note: >Audit-Trail: >Unformatted: From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 23:41:57 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4E96E16A4CE for ; Wed, 13 Apr 2005 23:41:57 +0000 (GMT) Received: from bute.st-andrews.ac.uk (bute.st-and.ac.uk [138.251.12.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7D93243D53 for ; Wed, 13 Apr 2005 23:41:56 +0000 (GMT) (envelope-from s_sourceforge@nedprod.com) Received: from kate (res04-ned6.res.st-and.ac.uk [138.251.234.67]) by bute.st-andrews.ac.uk (8.9.1a/8.9.1) with SMTP id AAA09436 for ; Thu, 14 Apr 2005 00:36:56 +0100 (BST) From: "Niall Douglas" To: freebsd-threads@freebsd.org Date: Thu, 14 Apr 2005 00:41:25 +0100 MIME-Version: 1.0 Message-ID: <425DBC35.18797.F118E6C@localhost> Priority: normal In-reply-to: <425DA78E.2050701@freebsd.org> References: <425DAE1F.5558.EDA8BD7@localhost> X-mailer: Pegasus Mail for Windows (4.21c) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Content-Transfer-Encoding: 7BIT Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 23:41:57 -0000 On 14 Apr 2005 at 7:13, David Xu wrote: > >I've already ported ptmalloc2 to FreeBSD. The performance increase is > > steller to put it mildly, even with FreeBSD's poor multithreading > >performance. You're talking ten or more times faster in heavily > >multithreaded code :) > > Poor multithreading performance? I don't know what library you are > talking about. I admit that malloc/free is the main bottleneck in > userland, a SMP-aware and CPU locality allocator is welcome. KSE threads, FreeBSD v5.3. It's a mixture of process and system threads. As I mentioned in a previous post, it's eight times slower than Linux. See http://www.nedprod.com/Tn/ (scroll down to the screenshots). Cheers, Niall From owner-freebsd-threads@FreeBSD.ORG Wed Apr 13 23:54:51 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2EFA216A4CE for ; Wed, 13 Apr 2005 23:54:51 +0000 (GMT) Received: from pinus.cc.fer.hr (pinus.cc.fer.hr [161.53.73.18]) by mx1.FreeBSD.org (Postfix) with ESMTP id 54D6B43D49 for ; Wed, 13 Apr 2005 23:54:50 +0000 (GMT) (envelope-from ivoras@fer.hr) Received: from [161.53.72.113] (lara.cc.fer.hr [161.53.72.113]) by pinus.cc.fer.hr (8.12.2/8.12.2) with ESMTP id j3DNtOB2012403; Thu, 14 Apr 2005 01:55:24 +0200 (MEST) Message-ID: <425DB142.7010905@fer.hr> Date: Thu, 14 Apr 2005 01:54:42 +0200 From: Ivan Voras User-Agent: Mozilla Thunderbird 1.0 (X11/20041213) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Niall Douglas References: <425DAE1F.5558.EDA8BD7@localhost> <425DBC35.18797.F118E6C@localhost> In-Reply-To: <425DBC35.18797.F118E6C@localhost> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Apr 2005 23:54:51 -0000 Niall Douglas wrote: > KSE threads, FreeBSD v5.3. It's a mixture of process and system > threads. As I mentioned in a previous post, it's eight times slower > than Linux. See http://www.nedprod.com/Tn/ (scroll down to the > screenshots). Did you test on a "real" FreeBSD & Linux hardware (not VMWare)? Because VMWare **greatly** pessimizes low-level operations that depend on atomic/bus locks, CMPXCHG & similar operations that are used in synchronization, context switches & multithreading, and IO operations are also very very slow compared to real hardware. It simply cannot be used to do benchmarks on (except if you're benchmarking vmware, not the guest system :) ) From owner-freebsd-threads@FreeBSD.ORG Thu Apr 14 04:01:12 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 046E416A4CE for ; Thu, 14 Apr 2005 04:01:12 +0000 (GMT) Received: from pimout4-ext.prodigy.net (pimout4-ext.prodigy.net [207.115.63.98]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6562043D2F for ; Thu, 14 Apr 2005 04:01:09 +0000 (GMT) (envelope-from julian@elischer.org) Received: from [192.168.2.2] (adsl-68-124-205-128.dsl.snfc21.pacbell.net [68.124.205.128])j3E40w5K177282; Thu, 14 Apr 2005 00:01:08 -0400 Message-ID: <425DEAF8.7040601@elischer.org> Date: Wed, 13 Apr 2005 21:00:56 -0700 From: Julian Elischer User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.5) Gecko/20050214 X-Accept-Language: en, hu MIME-Version: 1.0 To: Niall Douglas References: <425DAE1F.5558.EDA8BD7@localhost> <425DBC35.18797.F118E6C@localhost> In-Reply-To: <425DBC35.18797.F118E6C@localhost> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Apr 2005 04:01:12 -0000 Niall Douglas wrote: > On 14 Apr 2005 at 7:13, David Xu wrote: > > >>>I've already ported ptmalloc2 to FreeBSD. The performance increase is >>>steller to put it mildly, even with FreeBSD's poor multithreading >>>performance. You're talking ten or more times faster in heavily >>>multithreaded code :) >> >>Poor multithreading performance? I don't know what library you are >>talking about. I admit that malloc/free is the main bottleneck in >>userland, a SMP-aware and CPU locality allocator is welcome. > > > KSE threads, FreeBSD v5.3. It's a mixture of process and system > threads. As I mentioned in a previous post, it's eight times slower > than Linux. See http://www.nedprod.com/Tn/ (scroll down to the > screenshots). did you compile the FreeBSD kernel with the required changes for running under vmware? Vmware REALLY SUCKS when it comes to emulating the exact instructions we use for kernel locks and mutexes. You'd get maybe an order of magnitude difference through this under some situations. I forget the exact options but they'll be in the list archives. also make sure it's a Uniprocessor kernel. > > Cheers, > Niall > > > > _______________________________________________ > freebsd-threads@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-threads > To unsubscribe, send any mail to "freebsd-threads-unsubscribe@freebsd.org" From owner-freebsd-threads@FreeBSD.ORG Thu Apr 14 09:38:45 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 678A116A4CE for ; Thu, 14 Apr 2005 09:38:45 +0000 (GMT) Received: from bute.st-andrews.ac.uk (bute.st-and.ac.uk [138.251.12.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 837F843D62 for ; Thu, 14 Apr 2005 09:38:44 +0000 (GMT) (envelope-from s_sourceforge@nedprod.com) Received: from kate (res04-ned6.res.st-and.ac.uk [138.251.234.67]) by bute.st-andrews.ac.uk (8.9.1a/8.9.1) with SMTP id KAA27223 for ; Thu, 14 Apr 2005 10:33:38 +0100 (BST) From: "Niall Douglas" To: freebsd-threads@freebsd.org Date: Thu, 14 Apr 2005 10:38:08 +0100 MIME-Version: 1.0 Message-ID: <425E4810.7553.1133DEA0@localhost> Priority: normal In-reply-to: <425DB142.7010905@fer.hr> References: <425DBC35.18797.F118E6C@localhost> X-mailer: Pegasus Mail for Windows (4.21c) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Content-Transfer-Encoding: 7BIT Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Apr 2005 09:38:45 -0000 On 14 Apr 2005 at 1:54, Ivan Voras wrote: > > KSE threads, FreeBSD v5.3. It's a mixture of process and system > > threads. As I mentioned in a previous post, it's eight times slower > > than Linux. See http://www.nedprod.com/Tn/ (scroll down to the > > screenshots). > > Did you test on a "real" FreeBSD & Linux hardware (not VMWare)? > Because VMWare **greatly** pessimizes low-level operations that depend > on atomic/bus locks, CMPXCHG & similar operations that are used in > synchronization, context switches & multithreading, and IO operations > are also very very slow compared to real hardware. It simply cannot be > used to do benchmarks on (except if you're benchmarking vmware, not > the guest system :) ) VMWare should penalise Linux and FreeBSD equally in this area, actually Linux even more as it doesn't have a CMPXCHG exemption from kernel builds and Fedora Linux has more daemons etc. running by default. Julian Elischer wrote: > did you compile the FreeBSD kernel with the required changes for running > under vmware? Yes. It's a custom build made go as fast as I could make it. Interestingly, v5.3 was about half the speed of v5.2.1. > Vmware REALLY SUCKS when it comes to emulating the exact instructions we > use for kernel locks and mutexes. You'd get maybe an order of magnitude > difference through this under some situations. > > I forget the exact options but they'll be in the list archives. > also make sure it's a Uniprocessor kernel. It's also a uniprocessor kernel. I finally have a native 64 bit platform which I just bought, I'm just waiting on the release of v5.4. I'll post benchmarks here when I know, but I'm still expecting an order of magnitude difference. FreeBSD just feels a lot slower when doing multithreaded tasks despite being faster for multiprocess work. It's as one would expect with the added complexity of a M:N threading model which hasn't been optimised yet. Either way, ptmalloc2 is many times faster than the libc memory allocator. It's over sixty times faster than the win32 default allocator under four threads, so one would expect at least a similar speed up. I would expect a six to twelve times speed up for real world code. Cheers, Niall From owner-freebsd-threads@FreeBSD.ORG Thu Apr 14 16:27:12 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A35FA16A4CE for ; Thu, 14 Apr 2005 16:27:12 +0000 (GMT) Received: from bute.st-andrews.ac.uk (bute.st-and.ac.uk [138.251.12.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id CC1F943D4C for ; Thu, 14 Apr 2005 16:27:11 +0000 (GMT) (envelope-from s_sourceforge@nedprod.com) Received: from kate (res04-ned6.res.st-and.ac.uk [138.251.234.67]) by bute.st-andrews.ac.uk (8.9.1a/8.9.1) with SMTP id RAA06409 for ; Thu, 14 Apr 2005 17:22:09 +0100 (BST) From: "Niall Douglas" To: freebsd-threads@freebsd.org Date: Thu, 14 Apr 2005 17:26:40 +0100 MIME-Version: 1.0 Message-ID: <425EA7D0.20279.12A9E357@localhost> Priority: normal In-reply-to: <425E4B01.2020104@fer.hr> References: <425E4810.7553.1133DEA0@localhost> X-mailer: Pegasus Mail for Windows (4.21c) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Content-Transfer-Encoding: 7BIT Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Apr 2005 16:27:12 -0000 On 14 Apr 2005 at 12:50, Ivan Voras wrote: > > I finally have a native 64 bit platform which I just bought, I'm > > just waiting on the release of v5.4. I'll post benchmarks here when > > I know, but I'm still expecting an order of magnitude difference. > > For performance reasons, RELENG_5_4 in the current state will be the > same as 5.4-RELEASE[1] - no way re@ would allow serious commits to it > :) If you're planning doing benchmarks on real hardware (not vmware), > which would be most interesting, you might as well start doing it now > (or do the linux part now, do preliminary 5.4, and update to > 5.4-release when it's ready, maybe repeat benchmarks) My university does not permit use of CVS or CVSup (firewalled), so I'll be waiting for the release. > Also, to avoid flames, you might want to run the results through > ministat (/usr/src/tools/tools/ministat) :) Useful. > [1] : You might need to exclude debugging facilities from kernel - > witness & invariants mostly, and do 'ln -fs jrz /etc/malloc.conf' Noted. Cheers, Niall From owner-freebsd-threads@FreeBSD.ORG Thu Apr 14 16:30:04 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 064B616A4CE for ; Thu, 14 Apr 2005 16:30:04 +0000 (GMT) Received: from silver.he.iki.fi (helenius.fi [193.64.42.241]) by mx1.FreeBSD.org (Postfix) with ESMTP id C168843D2D for ; Thu, 14 Apr 2005 16:30:02 +0000 (GMT) (envelope-from pete@he.iki.fi) Received: from [193.64.42.134] (h86.vuokselantie10.fi [193.64.42.134]) by silver.he.iki.fi (8.13.1/8.11.4) with ESMTP id j3EGU1tc076935; Thu, 14 Apr 2005 19:30:01 +0300 (EEST) (envelope-from pete@he.iki.fi) Message-ID: <425E9AA4.2040707@he.iki.fi> Date: Thu, 14 Apr 2005 19:30:28 +0300 From: Petri Helenius User-Agent: Mozilla Thunderbird 1.0.2 (Windows/20050317) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Niall Douglas References: <425E4810.7553.1133DEA0@localhost> <425EA7D0.20279.12A9E357@localhost> In-Reply-To: <425EA7D0.20279.12A9E357@localhost> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Apr 2005 16:30:04 -0000 Niall Douglas wrote: >My university does not permit use of CVS or CVSup (firewalled), so >I'll be waiting for the release. > > > cvsup works fine over ssh tunnel. (in passive mode) Pete From owner-freebsd-threads@FreeBSD.ORG Thu Apr 14 17:12:19 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 09A1416A4CE for ; Thu, 14 Apr 2005 17:12:19 +0000 (GMT) Received: from mail.vicor-nb.com (bigwoop.vicor-nb.com [208.206.78.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 47A1143D5D for ; Thu, 14 Apr 2005 17:12:18 +0000 (GMT) (envelope-from julian@elischer.org) Received: from [208.206.78.97] (julian.vicor-nb.com [208.206.78.97]) by mail.vicor-nb.com (Postfix) with ESMTP id 0D8E67A424; Thu, 14 Apr 2005 10:12:18 -0700 (PDT) Message-ID: <425DC638.30801@elischer.org> Date: Wed, 13 Apr 2005 18:24:08 -0700 From: Julian Elischer User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.5) Gecko/20050218 X-Accept-Language: en, hu MIME-Version: 1.0 To: Niall Douglas References: <425DBC35.18797.F118E6C@localhost> <425E4810.7553.1133DEA0@localhost> In-Reply-To: <425E4810.7553.1133DEA0@localhost> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit cc: freebsd-threads@freebsd.org Subject: Re: thread aware malloc X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Apr 2005 17:12:19 -0000 Niall Douglas wrote: >On 14 Apr 2005 at 1:54, Ivan Voras wrote: > > > >>>KSE threads, FreeBSD v5.3. It's a mixture of process and system >>>threads. As I mentioned in a previous post, it's eight times slower >>>than Linux. See http://www.nedprod.com/Tn/ (scroll down to the >>>screenshots). >>> >>> >>Did you test on a "real" FreeBSD & Linux hardware (not VMWare)? >>Because VMWare **greatly** pessimizes low-level operations that depend >>on atomic/bus locks, CMPXCHG & similar operations that are used in >>synchronization, context switches & multithreading, and IO operations >>are also very very slow compared to real hardware. It simply cannot be >>used to do benchmarks on (except if you're benchmarking vmware, not >>the guest system :) ) >> >> > >VMWare should penalise Linux and FreeBSD equally in this area, >actually Linux even more as it doesn't have a CMPXCHG exemption from >kernel builds and Fedora Linux has more daemons etc. running by >default. > >Julian Elischer wrote: > > > >>did you compile the FreeBSD kernel with the required changes for running >>under vmware? >> >> > >Yes. It's a custom build made go as fast as I could make it. > >Interestingly, v5.3 was about half the speed of v5.2.1. > > > >>Vmware REALLY SUCKS when it comes to emulating the exact instructions we >>use for kernel locks and mutexes. You'd get maybe an order of magnitude >>difference through this under some situations. >> >>I forget the exact options but they'll be in the list archives. >>also make sure it's a Uniprocessor kernel. >> >> > >It's also a uniprocessor kernel. > >I finally have a native 64 bit platform which I just bought, I'm just >waiting on the release of v5.4. I'll post benchmarks here when I >know, but I'm still expecting an order of magnitude difference. >FreeBSD just feels a lot slower when doing multithreaded tasks >despite being faster for multiprocess work. It's as one would expect >with the added complexity of a M:N threading model which hasn't been >optimised yet. > > make sure you try libthr too. >Either way, ptmalloc2 is many times faster than the libc memory >allocator. It's over sixty times faster than the win32 default >allocator under four threads, so one would expect at least a similar >speed up. I would expect a six to twelve times speed up for real >world code. > >Cheers, >Niall > > > >_______________________________________________ >freebsd-threads@freebsd.org mailing list >http://lists.freebsd.org/mailman/listinfo/freebsd-threads >To unsubscribe, send any mail to "freebsd-threads-unsubscribe@freebsd.org" > > From owner-freebsd-threads@FreeBSD.ORG Fri Apr 15 15:00:05 2005 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9EA1B16A4CE for ; Fri, 15 Apr 2005 15:00:05 +0000 (GMT) Received: from mxsf41.cluster1.charter.net (mxsf41.cluster1.charter.net [209.225.28.173]) by mx1.FreeBSD.org (Postfix) with ESMTP id 06A9043D1F for ; Fri, 15 Apr 2005 15:00:05 +0000 (GMT) (envelope-from archie@dellroad.org) Received: from mxip07.cluster1.charter.net (mxip07a.cluster1.charter.net [209.225.28.137])j3FF03bb019924 for ; Fri, 15 Apr 2005 11:00:03 -0400 Received: from cable-68-113-94-164.mtv.al.charter.com (HELO InterJet.dellroad.org) (68.113.94.164) by mxip07.cluster1.charter.net with ESMTP; 15 Apr 2005 11:00:03 -0400 X-Ironport-AV: i="3.92,105,1112587200"; d="scan'208"; a="856074270:sNHT18644772" Received: from arch20m.dellroad.org (arch20m.dellroad.org [10.2.2.20]) by InterJet.dellroad.org (8.9.1a/8.9.1) with ESMTP id JAA14001 for ; Fri, 15 Apr 2005 09:52:24 -0500 (CDT) Received: from [127.0.0.1] (localhost [127.0.0.1])j3FEqNBe007168 for ; Fri, 15 Apr 2005 09:52:24 -0500 (CDT) (envelope-from archie@dellroad.org) Message-ID: <425FD527.1000102@dellroad.org> Date: Fri, 15 Apr 2005 09:52:23 -0500 From: Archie Cobbs User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.3) Gecko/20041129 X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-threads@freebsd.org Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Bug with pthread_getspecific() and signals X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Apr 2005 15:00:05 -0000 On FreeBSD 4.9 I'm seeing a bug where pthread_getspecific() sometimes returns the wrong value when invoked from within a signal handler. ISTR this bug was fixed in a later version of FreeBSD. However, I can't seem to find any reference to the bug, any information about when it was fixed, etc. (FreeBSD's mailing list search ability doesn't help much). If anyone knows any more details about this bug I'd appreciate knowing any more details. Thanks, -Archie __________________________________________________________________________ Archie Cobbs * CTO, Awarix * http://www.awarix.com