From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org)
	by finch.gentoo.org with esmtp (Exim 4.60)
	(envelope-from <gentoo-commits+bounces-384515-garchives=archives.gentoo.org@lists.gentoo.org>)
	id 1R7CrY-00029S-Kg
	for garchives@archives.gentoo.org; Fri, 23 Sep 2011 21:00:48 +0000
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id E3E40E0517;
	Fri, 23 Sep 2011 21:00:40 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	by pigeon.gentoo.org (Postfix) with ESMTP id ACA3EE0517
	for <gentoo-commits@lists.gentoo.org>; Fri, 23 Sep 2011 21:00:40 +0000 (UTC)
Received: from pelican.gentoo.org (unknown [66.219.59.40])
	(using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 19F211B4009
	for <gentoo-commits@lists.gentoo.org>; Fri, 23 Sep 2011 21:00:40 +0000 (UTC)
Received: from localhost.localdomain (localhost [127.0.0.1])
	by pelican.gentoo.org (Postfix) with ESMTP id 6D02B80042
	for <gentoo-commits@lists.gentoo.org>; Fri, 23 Sep 2011 21:00:39 +0000 (UTC)
From: "Zac Medico" <zmedico@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" <zmedico@gentoo.org>
Message-ID: <9e17de9a9cbd412760b761b4362175939fd4b13d.zmedico@gentoo>
Subject: [gentoo-commits] proj/portage:master commit in: bin/
X-VCS-Repository: proj/portage
X-VCS-Files: bin/portageq
X-VCS-Directories: bin/
X-VCS-Committer: zmedico
X-VCS-Committer-Name: Zac Medico
X-VCS-Revision: 9e17de9a9cbd412760b761b4362175939fd4b13d
Date: Fri, 23 Sep 2011 21:00:39 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: quoted-printable
X-Archives-Salt: 
X-Archives-Hash: 7c361b54dc63e9a24ee011bf7ae3be42

commit:     9e17de9a9cbd412760b761b4362175939fd4b13d
Author:     Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Fri Sep 23 21:00:26 2011 +0000
Commit:     Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Fri Sep 23 21:00:26 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a=
=3Dcommit;h=3D9e17de9a

portageq best_visible: use match-all-cpv-only

---
 bin/portageq |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/bin/portageq b/bin/portageq
index 3ae29d1..b416b66 100755
--- a/bin/portageq
+++ b/bin/portageq
@@ -464,7 +464,7 @@ def best_visible(argv):
 		portage.db[portage.settings["ROOT"]], None)
=20
 	if hasattr(db, "xmatch"):
-		cpv_list =3D db.xmatch("match-all", atom)
+		cpv_list =3D db.xmatch("match-all-cpv-only", atom)
 	else:
 		cpv_list =3D db.match(atom)
=20
@@ -472,7 +472,9 @@ def best_visible(argv):
 		# reversed, for descending order
 		cpv_list.reverse()
 		# verify match, since the atom may match the package
-		# for a given cpv from one repo but not another
+		# for a given cpv from one repo but not another, and
+		# we can use match-all-cpv-only to avoid redundant
+		# metadata access.
 		atom_set =3D InternalPackageSet(initial_atoms=3D(atom,))
=20
 		if atom.repo is None and hasattr(db, "getRepositories"):