[Yum-devel] [PATCH] Call repo.__hash__() less.
james at fedoraproject.org
Thu Jan 28 23:23:35 UTC 2010
On Thu, 2010-01-28 at 23:48 +0200, Ville Skyttä wrote:
> On my (typicalish) Fedora 11 box, brings down number of those calls in
> a check-update run from ~146k to ~27k and speeds it up by ~7%.
What about just changing Repository.__hash__ to something like:
if self.__cached_hash is None:
self.__cached_hash = hash(self.id)
...with the obvious "self.__cached_hash = None" in __init__?
More information about the Yum-devel