From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 127932 invoked by alias); 23 Nov 2015 10:27:17 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 127923 invoked by uid 89); 23 Nov 2015 10:27:16 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=2.5 required=5.0 tests=AWL,BAYES_80,HK_RANDOM_ENVFROM,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 X-HELO: sneak2.sneakemail.com Received: from sneak2.sneakemail.com (HELO sneak2.sneakemail.com) (38.113.6.65) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with SMTP; Mon, 23 Nov 2015 10:27:15 +0000 Received: (qmail 25529 invoked from network); 23 Nov 2015 10:27:11 -0000 Received: from unknown (HELO localhost.localdomain) (192.168.0.2) by sneak2.sneakemail.com with SMTP; 23 Nov 2015 10:27:11 -0000 Received: from 206.168.13.214 by mail.sneakemail.com with SMTP; 23 Nov 2015 10:27:11 -0000 Received: (sneakemail censored 24780-1448274431-7444 #2); 23 Nov 2015 10:27:11 -0000 Received: (sneakemail censored 24780-1448274431-7444 #1); 23 Nov 2015 10:27:11 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <24780-1448274431-7444@sneakemail.com> Date: Mon, 23 Nov 2015 10:27:00 -0000 From: "John Hein" <3fbmqnhaz4@snkmail.com> To: cygwin@cygwin.com Subject: Re: Cygwin multithreading performance In-Reply-To: <5652C402.7040006@maxrnd.com> References: <564E3017.90205@maxrnd.com> <5650379B.4030405@maxrnd.com> <20151121105301.GE2755@calimero.vinschen.de> <5652C402.7040006@maxrnd.com> X-SW-Source: 2015-11/txt/msg00340.txt.bz2 Mark Geisert wrote at 23:45 -0800 on Nov 22, 2015: > Corinna Vinschen wrote: > > On Nov 21 01:21, Mark Geisert wrote: > [...] so I wonder if there's > >> some unintentional serialization going on somewhere, but I don't know yet > >> how I could verify that theory. > > > > If I'm allowed to make an educated guess, the big serializer in Cygwin > > are probably the calls to malloc, calloc, realloc, free. We desperately > > need a new malloc implementation better suited to multi-threading. > > That's very helpful to know. I'd want to first make sure the heavy lock > activity I'm seeing in the traces really is due to malloc() and friends > but I couldn't help a speculative search online for multithread-safe > malloc(). These turned up: > tcmalloc - part of google-perftools, requires libunwind, evidently > not yet ported to Windows AFAICT, > nedmalloc - http://www.nedprod.com/programs/portable/nedmalloc/ > ptmalloc - http://www.malloc.de/ > > The latter two are based on Doug Lea's dlmalloc which is also the basis > of Cygwin's malloc() functions. As I understand it, ptmalloc in one > form or another has been part of glibc on Linux for some time. > > So there may be a solution in sight if we need to go that direction. Of > course, SHTDI as usual :). > > ...mark Someone recently mentioned on this list they were working on porting jemalloc. That would be a good choice. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple