From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= Subject: Re: SHA256 performance with Guile 2.2 vs. Guile 3.0 Date: Wed, 08 Jan 2020 22:20:58 +0100 Message-ID: <87ftgpejb9.fsf@gnu.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:37579) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ipIlE-0000BZ-FW for guix-devel@gnu.org; Wed, 08 Jan 2020 16:21:06 -0500 In-Reply-To: (Brendan Tildesley's message of "Sat, 4 Jan 2020 17:21:42 +1100") 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-mx.org@gnu.org Sender: "Guix-devel" To: Brendan Tildesley Cc: guix-devel Hi, Brendan Tildesley skribis: >> Still far from the libgcrypt implementation in C + asm, but hey! > > Actually guix hash is still a lot slower than using the sha256sum cli > tool. For me 7x faster for the guile tarball, and 4x faster for a > 700MiB file. Maybe because guile opens a file with it's ports and > feeds it to libgcrypt. If guix is heavy relying on hashing files > stored in the filesystem, maybe it would be better to directly use > sha256sum or perhaps libgcrypt has a function do open a file and hash > it on it's own? We=E2=80=99d need to look at the specifics, but given that =E2=80=9Cguix ha= sh guile-2.2.6.tar.xz=E2=80=9D takes less than 0.1s, the timing difference you= see between =E2=80=9Cguix hash=E2=80=9D and =E2=80=9Csha256sum=E2=80=9D is like= ly due to the startup time of the =E2=80=9Cguix=E2=80=9D command. Ludo=E2=80=99.