From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59583) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yb7I6-0002XM-6N for qemu-devel@nongnu.org; Thu, 26 Mar 2015 08:53:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yb7I1-0004DX-7O for qemu-devel@nongnu.org; Thu, 26 Mar 2015 08:53:42 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39375) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yb7I1-0004DR-1e for qemu-devel@nongnu.org; Thu, 26 Mar 2015 08:53:37 -0400 Date: Thu, 26 Mar 2015 13:53:32 +0100 From: Kevin Wolf Message-ID: <20150326125332.GA3932@noname.redhat.com> References: <1427338992-27057-1-git-send-email-famz@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1427338992-27057-1-git-send-email-famz@redhat.com> Subject: Re: [Qemu-devel] [PATCH] configure: Add support for tcmalloc List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: Paolo Bonzini , qemu-devel@nongnu.org, Stefan Hajnoczi , Peter Maydell Am 26.03.2015 um 04:03 hat Fam Zheng geschrieben: > This adds "--enable-tcmalloc" and "--disable-tcmalloc" to allow linking > to libtcmalloc from gperftools. > > tcmalloc is a malloc implementation that works well with threads and is > fast, so it is good for performance. > > It is disabled by default, because the MALLOC_PERTURB_ flag we use in > tests doesn't work with tcmalloc. However we can enable tcmalloc > specific heap checker and profilers later. > > An IOPS gain can be observed with virtio-blk-dataplane, other parts of > QEMU will directly benefit from it as well: > > ========================================================== > glibc malloc > ---------------------------------------------------------- > rw bs iodepth bw iops latency > read 4k 1 150 38511 24 > ---------------------------------------------------------- > > ========================================================== > tcmalloc > ---------------------------------------------------------- > rw bs iodepth bw iops latency > read 4k 1 156 39969 23 > ---------------------------------------------------------- > > Signed-off-by: Fam Zheng > --- > configure | 24 ++++++++++++++++++++++++ > 1 file changed, 24 insertions(+) > > diff --git a/configure b/configure > index 589798e..03ba305 100755 > --- a/configure > +++ b/configure > @@ -336,6 +336,7 @@ libssh2="" > vhdx="" > quorum="" > numa="" > +tcmalloc="no" > > # parse CC options first > for opt do > @@ -1134,6 +1135,10 @@ for opt do > ;; > --enable-numa) numa="yes" > ;; > + --disable-tcmalloc) tcmalloc="no" > + ;; > + --enable-tcmalloc) tcmalloc="yes" > + ;; > *) > echo "ERROR: unknown option $opt" > echo "Try '$0 --help' for more information" > @@ -1407,6 +1412,8 @@ Advanced options (experts only): > --enable-quorum enable quorum block filter support > --disable-numa disable libnuma support > --enable-numa enable libnuma support > + --disable-tcmalloc disable tcmalloc support > + --enable-numa enable tcmalloc support Almost. :-) Kevin