From owner-svn-src-all@FreeBSD.ORG Mon Feb 9 16:41:51 2015 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5B969DC0; Mon, 9 Feb 2015 16:41:51 +0000 (UTC) Received: from st11p02mm-asmtp001.mac.com (st11p02mm-asmtp001.mac.com [17.172.220.236]) (using TLSv1.2 with cipher DHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2DB13B5A; Mon, 9 Feb 2015 16:41:50 +0000 (UTC) Received: from fukuyama.hsd1.ca.comcast.net (unknown [73.162.13.215]) by st11p02mm-asmtp001.mac.com (Oracle Communications Messaging Server 7.0.5.35.0 64bit (built Dec 4 2014)) with ESMTPSA id <0NJI00DFGJPIBE40@st11p02mm-asmtp001.mac.com>; Mon, 09 Feb 2015 16:41:45 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.13.68,1.0.33,0.0.0000 definitions=2015-02-09_02:2015-02-09,2015-02-08,1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1412110000 definitions=main-1502090169 Content-type: text/plain; charset=us-ascii MIME-version: 1.0 (Mac OS X Mail 8.2 \(2070.6\)) Subject: Re: svn commit: r278433 - in head: . contrib/xz contrib/xz/src/common contrib/xz/src/liblzma contrib/xz/src/liblzma/api contrib/xz/src/liblzma/api/lzma contrib/xz/src/liblzma/check contrib/xz/src/liblz... From: Rui Paulo In-reply-to: <46013627.EoFa6fsn0l@ralph.baldwin.cx> Date: Mon, 09 Feb 2015 08:41:42 -0800 Content-transfer-encoding: quoted-printable Message-id: <663179A3-95DD-4BC2-B645-1187CCF0DAA3@me.com> References: <201502090620.t196KZSk040702@svn.freebsd.org> <46013627.EoFa6fsn0l@ralph.baldwin.cx> To: John Baldwin X-Mailer: Apple Mail (2.2070.6) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Rui Paulo X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Feb 2015 16:41:51 -0000 On Feb 9, 2015, at 08:16, John Baldwin wrote: >=20 > On Monday, February 09, 2015 06:20:35 AM Rui Paulo wrote: >> Author: rpaulo >> Date: Mon Feb 9 06:20:34 2015 >> New Revision: 278433 >> URL: https://svnweb.freebsd.org/changeset/base/278433 >>=20 >> Log: >> Merge xz 5.2.0. >>=20 >> This brings support for multi-threaded compression. This brings = close >> N times faster compression where N is the number of CPU cores. >> Because of this, liblzma now depends on libthr. >>=20 >> Soon libarchive will be modified to use the new lzma API. >>=20 >> Thanks to antoine@ for the exp-run. >=20 > It looks like this uses hw.ncpu to determine the number of cores. Can = you=20 > make this cpuset friendly by querying the current process's CPU mask = and=20 > counting the cores it contains instead? >=20 > Somethign like: >=20 > cpuset_t set; >=20 > cpuset_getaffinity(CPU_LEVEL_WHICH, CPU_WHICH_PID, -1, &set, = sizeof(set)); >=20 > (I have a CPU_COUNT() macro I should commit that will then let you = do:) >=20 > ncpus =3D CPU_COUNT(&set); Yes, makes sense. I'll wait for CPU_COUNT(). -- Rui Paulo