From owner-freebsd-current@FreeBSD.ORG Mon Dec 12 01:51:27 2005 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7626416A41F for ; Mon, 12 Dec 2005 01:51:27 +0000 (GMT) (envelope-from jasone@canonware.com) Received: from lh.synack.net (lh.synack.net [204.152.188.37]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0A4B143D5A for ; Mon, 12 Dec 2005 01:51:27 +0000 (GMT) (envelope-from jasone@canonware.com) Received: by lh.synack.net (Postfix, from userid 100) id E431E5E48C4; Sun, 11 Dec 2005 17:51:26 -0800 (PST) Received: from [192.168.168.203] (moscow-cuda-gen2-68-64-60-20.losaca.adelphia.net [68.64.60.20]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by lh.synack.net (Postfix) with ESMTP id 42B385E48C4; Sun, 11 Dec 2005 17:51:26 -0800 (PST) In-Reply-To: <439CC5DA.3080103@elischer.org> References: <0B746373-8C29-4ADF-9218-311AE08F3834@canonware.com> <7318D807-9086-4817-A40B-50D6960880FB@canonware.com> <12CA5E15-D006-441D-A24C-1BCD1A69D740@canonware.com> <439CC5DA.3080103@elischer.org> Mime-Version: 1.0 (Apple Message framework v746.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Jason Evans Date: Sun, 11 Dec 2005 17:47:57 -0800 To: Julian Elischer X-Mailer: Apple Mail (2.746.2) X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on lh.synack.net X-Spam-Level: * X-Spam-Status: No, score=1.8 required=5.0 tests=RCVD_IN_NJABL_DUL, RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 Cc: current@freebsd.org Subject: Re: New libc malloc patch X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 01:51:27 -0000 On Dec 11, 2005, at 4:35 PM, Julian Elischer wrote: > I may have missed it but some benchmark numbers could be good. I haven't posted any benchmark numbers, but that is a reasonable request. Here's a summary of what I've seen so far. For single-threaded apps, phkmalloc and jemalloc exhibit very similar performance for all of the benchmarks I've run. Neither is a clear winner over the other from what I've seen. Kris Kennaway already posted some multi-threaded microbenchmark results. My tests have yielded similar results to his. It would be very informative to run benchmarks with real world multithreaded apps. bind9 (built with threading support) would be a great candidate, but thus far I haven't gotten a chance to use the machines that Robert Watson uses for such tests. > Is there no way to make it an option for a while? > that would get good testing AND a fallback for people. Unfortunately, there are some low level issues that make the two malloc implementations incompatible, and they both need access to libc internals in order to work correctly in a multi-threaded program. The way I have been comparing the two implementations is via chroot installations. It might be possible to make the two compatible (would require extra coding), but since both of them need to be part of libc, we would need a way of building separate libc libraries for the two mallocs. This all seems uglier than it's worth to me. Maybe there's another way... Jason