From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 94935 invoked by alias); 24 Nov 2015 00:54:10 -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 94785 invoked by uid 89); 24 Nov 2015 00:54:10 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.6 required=5.0 tests=AWL,BAYES_80,KAM_LAZY_DOMAIN_SECURITY autolearn=no version=3.3.2 X-HELO: m0.truegem.net Received: from m0.truegem.net (HELO m0.truegem.net) (69.55.228.47) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Tue, 24 Nov 2015 00:54:08 +0000 Received: (from daemon@localhost) by m0.truegem.net (8.12.11/8.12.11) id tAO0s7c1021929 for ; Mon, 23 Nov 2015 16:54:07 -0800 (PST) (envelope-from mark@maxrnd.com) Received: from 76-217-5-154.lightspeed.irvnca.sbcglobal.net(76.217.5.154), claiming to be "[192.168.1.100]" via SMTP by m0.truegem.net, id smtpdg7ZdzG; Mon Nov 23 16:54:00 2015 Subject: Re: Cygwin multithreading performance References: <564E3017.90205@maxrnd.com> <5650379B.4030405@maxrnd.com> <20151121105301.GE2755@calimero.vinschen.de> <5652C402.7040006@maxrnd.com> <24780-1448274431-7444@sneakemail.com> To: cygwin@cygwin.com From: Mark Geisert Message-ID: <5653B52B.5000804@maxrnd.com> Date: Tue, 24 Nov 2015 01:05:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:42.0) Gecko/20100101 Firefox/42.0 SeaMonkey/2.39 MIME-Version: 1.0 In-Reply-To: <24780-1448274431-7444@sneakemail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2015-11/txt/msg00378.txt.bz2 John Hein wrote: > 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. Indeed; thanks for the reminder. Somehow I hadn't followed that thread. ..mark -- 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