From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 30 09:10:59 2020 Received: (at 39258) by debbugs.gnu.org; 30 Apr 2020 13:10:59 +0000 Received: from localhost ([127.0.0.1]:45486 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jU8xu-0001C3-L2 for submit@debbugs.gnu.org; Thu, 30 Apr 2020 09:10:59 -0400 Received: from mail-qk1-f194.google.com ([209.85.222.194]:41883) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jU8xt-0001Br-Mn for 39258@debbugs.gnu.org; Thu, 30 Apr 2020 09:10:58 -0400 Received: by mail-qk1-f194.google.com with SMTP id n143so5548603qkn.8 for <39258@debbugs.gnu.org>; Thu, 30 Apr 2020 06:10:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=E5wfgat59i9DKwr5SUTbHiaFHWJ0ZNazTDKYHD/EA58=; b=YgJKZAr+ToRI1yVi7gPo2/zsJ6CrLciFRJJv5dbOlckCOwQmSNm/HNwTLyvbBopaQH LWuv5VERyx+WH+HClzWyVAdj2mnxBof800tyfkywzNlWB2Xm3b4K9N6SsGcJZ69tYGS7 nlDbs6+6o78/9UTTYB6KqlejsVf/WrIGVQ1Td4sypf7xv6ApEZ4zv6ax13NqwU2exvJl vOkw0ESkoR04K5ZaIY4UHY9aNgnGGlZF3CMks9q0a6VkrFfSgkSD9usPuvreMSvUdZkA ktQlG4rfn8PY6gL0sluZXBKnpeZyWfc3Lgrg4DKI8JK+oP3LQeYi1ssi6sfW6GnmkhBu DXHA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=E5wfgat59i9DKwr5SUTbHiaFHWJ0ZNazTDKYHD/EA58=; b=nLrRxKB9Lj6yCTlSPIGJecpNal+uG3dFqVxI3wZCz8xOX6P88RcqiDCEJlXNErDJth /ieVnbRpIatfQyMm2/Kxdu8qV/ASzTc89RcVOffIPIHHZP2/hE545qdIH0BuXMc11RlO fUoUUu4CNaFwZ7IV4iu0EMYFVhKv1Y4IigtQuRdC/JI4QXPpf2r9nA4OUT2+zD0ZnwQP /FD0oSep4wVNvw10B45U/C9ZQeDJI9k/bTyQ4dltynsJjTqwIMC3ONNwsACbKshS1Pue V4W0WM2P3HNtcdSAqi0A8mD+avI7IULyAaWZMC7/800FdYYr8+uEEDlqXpL53j/uTbTK 6jYw== X-Gm-Message-State: AGi0PuaXZjgfrPdOS/aYGh9FPCl5rNi73Rx2fpgWjmqHUYCrzQ1bhrcs nPNNizJewbx/ixxbkgEsucOVaBYorqrBS8/uxpk= X-Google-Smtp-Source: APiQypLQNFXr2Exbjf+yr8jxXdnmhQkX7IXfdpOnvgMOj7/K/35cf9VeRjZXKK19flw3kHNlMb+QAvd4xNwihKBiO0c= X-Received: by 2002:a05:620a:239:: with SMTP id u25mr3157286qkm.304.1588252252100; Thu, 30 Apr 2020 06:10:52 -0700 (PDT) MIME-Version: 1.0 References: <87lfmi2qod.fsf@gnu.org> In-Reply-To: <87lfmi2qod.fsf@gnu.org> From: zimoun Date: Thu, 30 Apr 2020 15:10:40 +0200 Message-ID: Subject: Re: benchmark search: default vs v2 vs v3 To: =?UTF-8?Q?Ludovic_Court=C3=A8s?= Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 39258 Cc: Arun Isaac , Pierre Neidhardt , 39258@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi Ludo, On Sun, 26 Apr 2020 at 17:49, Ludovic Court=C3=A8s wrote: > That=E2=80=99s only one criterion among others. I hear the argument that= 25s is > =E2=80=9Cnothing=E2=80=9D compared to the rest, but it=E2=80=99s really a= tradeoff. Like, if I > spent a day optimizing =E2=80=98guix pull=E2=80=99 and managed to save 25= s, I would find > it nice. :-) I am not sure to understand all what "guix pull" does. Does "guix pull" compile all the scheme files under 'gnu/'? Probably only recompiles the "new" files? I do not know if it makes sense, but I just note this difference: 1. Search without compiling of all files under 'gnu/packages/' 2. Compile all the files under 'gnu/packages/' then search 3. Search with only the file gnu/packages/emacs-xyz.scm not compiled (all the other files are compiled) 4. Compile the file above and then search 3b and 4b with gnu/packages/cobol.scm which is smaller than emacs-xyz.scm. Results: 1) 1m43.312s 2) 0m1.301s (but 9m51.801s compiling) 3) 0m6.526s 4) 0m1.389s (1m8.670s compiling) 3b) 0m0.921s 4b) 0m0.924s (0m1.884s compiling) Therefore, an option to reduce the time when pulling should to relax the "compilation" for 'gnu/packages/' and 'gnu/services'; something less optimized since the packages and services "just" need to be transformed into bytecode to improve IO when reading them. Perhaps I miss a point... And maybe, it is similar than what Andy Wingo is proposing in [1]. [1] https://lists.gnu.org/archive/html/guix-devel/2020-04/msg00444.html Cheers, simon --8<---------------cut here---------------start------------->8--- find gnu/packages -name "*.scm" -type f -exec touch {} \; time ./pre-inst-env guix search gmsh | recsel -C -p name ;;; note: source file /home/simon/src/guix/wk/tmp/gnu/packages/abduco.scm ;;; newer than compiled /home/simon/src/guix/wk/tmp/gnu/packages/abdu= co.go [...] ;;; note: source file /home/simon/src/guix/wk/tmp/gnu/packages/zwave.scm ;;; newer than compiled /home/simon/src/guix/wk/tmp/gnu/packages/zwav= e.go name: gmsh real 1m43.312s user 2m19.318s --8<---------------cut here---------------end--------------->8--- --8<---------------cut here---------------start------------->8--- find gnu/packages -name "*.scm" -type f -exec touch {} \; time make -j4 && time ./pre-inst-env guix search gmsh | recsel -C -p name make all-recursive make[1]: Entering directory '/home/simon/src/guix/wk/tmp' Making all in po/guix make[2]: Entering directory '/home/simon/src/guix/wk/tmp/po/guix' make[2]: Leaving directory '/home/simon/src/guix/wk/tmp/po/guix' Making all in po/packages make[2]: Entering directory '/home/simon/src/guix/wk/tmp/po/packages' make[2]: Leaving directory '/home/simon/src/guix/wk/tmp/po/packages' make[2]: Entering directory '/home/simon/src/guix/wk/tmp' Compiling Scheme modules... [ 0%] LOAD gnu/packages/abduco.scm ;;; note: source file ./gnu/packages/abduco.scm ;;; newer than compiled /home/simon/src/guix/wk/tmp/gnu/packages/abdu= co.go [...] [100%] GUILEC gnu/packages/zwave.go make[2]: Leaving directory '/home/simon/src/guix/wk/tmp' make[1]: Leaving directory '/home/simon/src/guix/wk/tmp' real 9m51.801s user 29m18.938s sys 0m5.822s name: gmsh real 0m1.301s user 0m1.266s sys 0m0.101s --8<---------------cut here---------------end--------------->8---