From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id MD3pNW3g8GAEVgEAgWs5BA (envelope-from ) for ; Fri, 16 Jul 2021 03:27:09 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id +ESgMW3g8GBoGgAA1q6Kng (envelope-from ) for ; Fri, 16 Jul 2021 01:27:09 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 4EEDF1EB24 for ; Fri, 16 Jul 2021 03:27:09 +0200 (CEST) Received: from localhost ([::1]:45022 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m4CdA-0001z7-8r for larch@yhetil.org; Thu, 15 Jul 2021 21:27:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:42504) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m4Cd4-0001ys-2T for guix-patches@gnu.org; Thu, 15 Jul 2021 21:27:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:38564) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m4Cd3-0004sK-PJ for guix-patches@gnu.org; Thu, 15 Jul 2021 21:27:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m4Cd3-0003Z5-Mj for guix-patches@gnu.org; Thu, 15 Jul 2021 21:27:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#30053] [PATCH 1/3] Improve appearance of tabular output. Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 16 Jul 2021 01:27:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 30053 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Sarah Morgensen Cc: 30053@debbugs.gnu.org, Ludovic =?UTF-8?Q?Court=C3=A8s?= , Steve Sprang , Roel Janssen Received: via spool by 30053-submit@debbugs.gnu.org id=B30053.162639876813641 (code B ref 30053); Fri, 16 Jul 2021 01:27:01 +0000 Received: (at 30053) by debbugs.gnu.org; 16 Jul 2021 01:26:08 +0000 Received: from localhost ([127.0.0.1]:50110 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m4CcB-0003Xw-LZ for submit@debbugs.gnu.org; Thu, 15 Jul 2021 21:26:07 -0400 Received: from mail-qk1-f181.google.com ([209.85.222.181]:41594) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m4Cc7-0003XQ-Hs for 30053@debbugs.gnu.org; Thu, 15 Jul 2021 21:26:05 -0400 Received: by mail-qk1-f181.google.com with SMTP id s6so7159843qkc.8 for <30053@debbugs.gnu.org>; Thu, 15 Jul 2021 18:26:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=lQ40BDqA+JhPdqxuIsoVDDXv4QiA9zNC1Nju482KEuw=; b=OFpReHKW1q2i9qceqw7KYdL4LFXWUdDQsThzLRM0o1MTkQLQMY2UJJzj1gOoSU0tBl 2ulFQHLCMMwK1Bbh3SaelE23TdaHoOZRwZ9mOrszQ4EvOFxQcKyof2GNAHTtDYqtPtmg 2Lfxow2Ng0KHZ/14yES+1eLskJzcWKir7MdmKkCaINOm9XWs64NLfkm7uuBktFS/QeKk Z46p/K0/RLYJ0e8ixhVCL/Lsjm7m3oqc+2UCg+4BnEyrfx5gFUrA/W4znqfVoEHILZLs B/8xX5DZ0TAsj1GSQYChlHAfWXJsjvF+6+WNRbdW8rWTYWAglHKrt4Fj8K0QKayAu28O 2JZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=lQ40BDqA+JhPdqxuIsoVDDXv4QiA9zNC1Nju482KEuw=; b=j+TusytxnuAQg/MOHoz36uFJJvXYdnyZOVtKkjrVGjoozT8lsZGBR1WaEIVAygNMsx hqoDIUNlF7W/G7NIjODmoqEM1rwSui6eju7J5dVuI5EUg1VgyTBj9mV929jppF4so/sQ 7DyMq3J4/LPEL6HBY7b9+mitci2nuZuFR7fERhUMz3hL6EfS/q8yvPfDUGTOadSWEqvm 6ciKvVwbY2EhAHqHvamxm2/NL/WqqAjrrHca31mNH0GAWXrN9FkOV/6rHulOAScueEs5 y45gJQjxJJKaIiBtDOeigq+GMdx9qCIM86Op1ylcJHliVsZS/8dfutsJhDE/+ZG4nBQM CMiA== X-Gm-Message-State: AOAM530E9NvyPtt+vKVkFn0K/fITdRS5SgUnEf37gM1ImE00yM/7VhM4 KgAK2LGbl/8NTDMMPHoilCY= X-Google-Smtp-Source: ABdhPJyFloY43JZjL2el2F5R0SJPGZwDH6WKa4JBXYedyH33X+vEGj8u7hrtQ6k0N/gBzjpqu04NZQ== X-Received: by 2002:a37:62d1:: with SMTP id w200mr7053390qkb.11.1626398758088; Thu, 15 Jul 2021 18:25:58 -0700 (PDT) Received: from hurd (dsl-159-138.b2b2c.ca. [66.158.159.138]) by smtp.gmail.com with ESMTPSA id a19sm2586852qtb.54.2021.07.15.18.25.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Jul 2021 18:25:57 -0700 (PDT) From: Maxim Cournoyer References: <878td4nksy.fsf@gnu.org> <87fu7b2old.fsf@gnu.org> <87zi5d6g8f.fsf@gnu.org> <87im1cnnjb.fsf_-_@gmail.com> <861r7zjkrl.fsf_-_@mgsn.dev> Date: Thu, 15 Jul 2021 21:25:56 -0400 In-Reply-To: <861r7zjkrl.fsf_-_@mgsn.dev> (Sarah Morgensen's message of "Thu, 15 Jul 2021 15:05:18 -0700") Message-ID: <87eebznj6j.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1626398829; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=lQ40BDqA+JhPdqxuIsoVDDXv4QiA9zNC1Nju482KEuw=; b=WOzGwuS/Be6awFnuiZpSlDw9GguOTH6fFy/bUNVzTM1gPfCPaBLXHt7icUSQvjmjKMKQG6 xBq/dDNoe8WSqnONYIA6Zx/gUeCrokzesYZASn4HldChqzFcYGu6zqwgabm5ZAYbv7oLra J5JiXIlW1qYpe/iQZ9hp/RDVxnATTTeH4S6n8XfHHeipN3DIgHf8ogQ/mtb4ZbhB5l28DS JBPA24J5oW4Nr7cIb7iy0tfIKp9Zf7DCEbbypcEjBdbMLlc/Wjmn6ySO+8EZbj3bn7IJx1 4fbsNHqkGC8/CNMZ2kuRbWUKoPIdUay94J2UV/5JZ57N7u+JWSrppiuMwNjhEQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1626398829; a=rsa-sha256; cv=none; b=DVLI0qPbwaJHwaf9BaWNCSAfGlniqfJuqhoLP+0XV4jDCzZuyw0ZopuGbQaxWr6KTqLU1T CstT3nrKPRMUoGcFHCiJYGS/asd9feCQ7xeLDVsG1w4ucai9uCoz/4YM/wwGNp5F1I+ZMJ Jqn0Ki1XJbAAdKUKGmcpcRDSCFztYsC33Zdpqykyg+8B2Wm4nUYZz4nArfiu56pUrH/SA4 9Kvy/KlrQJKoeaHJzMvArahDOUIdybHgesblqllan5ftt69vtuIQiYWQcfJ/QYDk6FM7G3 0Z+6Q6LtRiKMV3ttuOkueQS6TRxyzyHmtC1TPssX/QDKqezLnbv05ccMCln+LA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=OFpReHKW; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: 0.20 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20161025 header.b=OFpReHKW; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: 4EEDF1EB24 X-Spam-Score: 0.20 X-Migadu-Scanner: scn0.migadu.com X-TUID: +sXk3sODgk24 Hello, Sarah Morgensen writes: > Hi Maxim, > > Maxim Cournoyer writes: > >> [...] >> --- >> Sample count: 567 >> Total time: 20.913633405 seconds (12.747006885 seconds in GC) >> >> Without the change 'guix package -A' runs in about 2 seconds. With the >> change it runs in about 12 seconds here. > > I cannot replicate this. Without the patch on master (7e0da2f): > > $ time ./pre-inst-env guix package -A > /dev/null > > real 0m5.473s > user 0m6.698s > sys 0m0.094s > > > And with the patch: > > $ time ./pre-inst-env guix package -A > /dev/null > > real 0m5.778s > user 0m6.862s > sys 0m0.061s I tested on a different machine after tweakwing the code slightly today, and the results were not as bad as those I reported earlier. Buffering the output helped a lot. > Perhaps there's something else going on there? I'm on x86-64, if that's > useful. > >> Danny's suggestion to use 'guix package -A | columns -t' works too, but >> it's not convenient nor discoverable. > > Definitely agree, though in my opinion neither that nor this *really* > make `guix package --list-installed` pretty. I'm sure I could put > together an alias but it goes a long way toward making Guix look > polished to have it built-in. Thanks for sharing your opinion! I ended up pushing it to the repo a bit earlier today; after I found it was running acceptably fast and set an upper limit to the maximum column width so that the output would remain compact enough. You should have it available to try on your next 'guix pull', if you haven't already :-). Thanks, Maxim