From mboxrd@z Thu Jan 1 00:00:00 1970 From: zimoun Subject: Re: guix package --search slow ? Date: Wed, 15 May 2019 16:23:40 +0200 Message-ID: References: <87o9447pul.fsf@elephly.net> <87r28zu9hs.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([209.51.188.92]:59824) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hQup0-0003HC-5Y for guix-devel@gnu.org; Wed, 15 May 2019 10:23:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hQuoz-0003yz-8d for guix-devel@gnu.org; Wed, 15 May 2019 10:23:54 -0400 Received: from mail-qk1-x72e.google.com ([2607:f8b0:4864:20::72e]:33882) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hQuoz-0003xU-2W for guix-devel@gnu.org; Wed, 15 May 2019 10:23:53 -0400 Received: by mail-qk1-x72e.google.com with SMTP id j20so96193qke.1 for ; Wed, 15 May 2019 07:23:53 -0700 (PDT) In-Reply-To: <87r28zu9hs.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Guix Devel Hi, On Wed, 15 May 2019 at 15:34, Ludovic Court=C3=A8s wrote: > > For the record, commit 94aeec0aef03ab44e41bfc3e77c3b623cb3d607c, shortly > before 1.0, make =E2=80=98guix search=E2=80=99 faster (as in less CPU usa= ge.) Six time faster the commit message claims ;-) Awesome how only 2 lines change things. > The cold-cache timings are worse for Guix, which ends up doing a lot of > I/O to traverse all these .scm files; APT only has to go through a > couple of files I guess. Hum? I do not know how APT (say the `aptitude` implementation) works. I suppose that `aptitude update` pulls then hashes somehow a database/cache= . I mean reduce the I/O with all these scattered .scm files should improve the timings. > The warm-cache timings are comparable though, which I think is good. > :-) Yes! :-) However, because the first search is slow, the final feeling is that `guix search` is slow. :-( > We could probably improve the cold-cache timings by adding synopses and > descriptions to the package cache that =E2=80=98guix pull=E2=80=99 builds= in > ~/.config/guix/current/lib/guix/package.cache, but that would also make > that cache bigger. Not sure if it=E2=80=99s worth it. Hum? and why not use SQLite for this file? All the best, simon