From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 14740 invoked from network); 28 Jun 2021 22:58:32 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 28 Jun 2021 22:58:32 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1624921112; b=X58anVwIgsVKS2iGKxTJh94OHR6Jq6rOK66WTQIoy0YLNmFWiHa2/8t2hN20NcZX0Yb3A1YQUy Ifj78JnhGBnLeE4N/koj+hj6ZBoA3/MRltZvNr1iq3rDZyp1rXOPgHtXFUw+6LHiW9VtNU60vE KC8fVWuLgamL2+43/6gj5z+LKBgViJiOJdGerzcOy0wtZJ3ynvfynalRy0dPZR6Nw56P8KiuUz MXJ38ujCS9MSrz3mHUsRftl2mwuEbDKpD+4qS6Na/NdIrTaeOQecM81E/U2pyM+nfYN0B3ctll 5TS2gVLLuNPnEb9acCNpqq6t6lUfDZ6zCbTFf6D4JfT+OQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mx1.riseup.net) smtp.remote-ip=198.252.153.129; dkim=pass header.d=riseup.net header.s=squak header.a=rsa-sha256; dmarc=pass header.from=riseup.net; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1624921112; bh=Lze2Kydu7TeATDt7tObH5hwHVI6bLhsDES9INksx8OE=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:MIME-Version:References:In-Reply-To:Message-ID: Subject:Cc:To:From:Date:DKIM-Signature:DKIM-Signature; b=sJWNYZX4+sTcasKVLfDhuRIzj0qg3Y3bUA/pvz3Ij/u7SoRf3xvACsXmfg2IxQDesEzggbANWD tcYlbq+eoO2s4v/61PuISA/iI0HgOydTocRwk2lcg0ezxo/Jtn7G4hXclQf2Fnrx8p/1vz6nNz xpoG0PRB2W4H8VuRTnq0Dms9IzT+v1oh1eJsc9tsOjxCj0SJFm9lY/RMVbeOPbxZKffuF6iqd+ ld07993uLBKjd+Wm1uGu5+sUr6SHJ5kV1MUYVAfUSz0hqiBmkAinube2QfaIM2jWfPN9eMiPGY ef7B7vfjidhnjOE9XUrSwZoT2XOMX0qJeposdGdMFz+J5Q==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:MIME-Version:References: In-Reply-To:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=BR7l8WweuKA+e/ovEJsv4fKS1UapCtRfmAdNDWQ5xLM=; b=mQxYfHuFIPqyoFnTHR1M8sWsrw Wu87DXHkd7C85qNKc2+g/eWUtaV0XPw6IaCCYtMh5zUcyU1DqexGBVLv3I5BVTF3TtOLh9d/aPFq5 y8eoKZ9WKWcdbyYeRz8GIpFS3l8tWNGEHKBbqrv7pOusdRyzZNv3//LwzZTcCUT7+GU6C84BRi/7Y D4ndK7dLLpfWEnC6p7ZZaTVaTpmlEkeLxdhZFfE4DFMieut3d0+mHM5GKVnBDOiBLXt/rKnK7y/73 8jJuMuCW6Fd5TJybb8CC5FlI53ckxN3Q0yN8X1bf4obBsIrT59xrkb1A0NeRpu0WV2Jj/pOvOeWBD z4VAQaUg==; Received: from authenticated user by zero.zsh.org with local id 1ly0D1-00029N-Rr; Mon, 28 Jun 2021 22:58:31 +0000 Authentication-Results: zsh.org; iprev=pass (mx1.riseup.net) smtp.remote-ip=198.252.153.129; dkim=pass header.d=riseup.net header.s=squak header.a=rsa-sha256; dmarc=pass header.from=riseup.net; arc=none Received: from mx1.riseup.net ([198.252.153.129]:38976) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1ly0CT-0001lC-Ct; Mon, 28 Jun 2021 22:57:58 +0000 Received: from fews1.riseup.net (fews1-pn.riseup.net [10.0.1.83]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "*.riseup.net", Issuer "Sectigo RSA Domain Validation Secure Server CA" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4GDNHJ2pcFzDxmf; Mon, 28 Jun 2021 15:55:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1624920924; bh=Lze2Kydu7TeATDt7tObH5hwHVI6bLhsDES9INksx8OE=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=e+4CyQFGHgbITjjdOrQOaQ39C5Xp5liafqJ7Ot36meukd0Yrwug3ovbTJLbo+/jPk WgWpF2L4kpROkqT2fiKDZ0rCvN+knEdNFry7icUABB/AEu/80FM2ufeSRm3jgiqECh ZO36HD9nCyVWt5M0lUgtWwjf1BX0LgbFyyUoCKxY= X-Riseup-User-ID: 6BB0EC8C569884180FC964DC2DDC01BC9AD0DC760772FD4BF3BAD336AB4F73BA Received: from [127.0.0.1] (localhost [127.0.0.1]) by fews1.riseup.net (Postfix) with ESMTPSA id 4GDNHH5Tb1z5vNY; Mon, 28 Jun 2021 15:55:23 -0700 (PDT) Date: Mon, 28 Jun 2021 15:57:36 -0700 From: "Suraj N. Kurapati" To: Roman Perepelitsa Cc: Zsh hackers list Subject: Re: [PR] vcs_info-examples: optimize +vi-git-untracked() #76 Message-ID: <20210628155736.6982862a@ratham> In-Reply-To: References: <20210626230903.43ba5516@ratham> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/AbusKWjLXFM.n.Cqs7/pKf0"; protocol="application/pgp-signature"; micalg=pgp-sha512 X-Seq: 49134 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: --Sig_/AbusKWjLXFM.n.Cqs7/pKf0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Sun, 27 Jun 2021 15:03:17 +0200, Roman Perepelitsa wrote: > On Sun, Jun 27, 2021 at 8:07 AM Suraj N. Kurapati wrote: > > Speed up the prompt on large and/or deep working directories [...] =20 >=20 > Do you have an estimate of the speedup? Numbers from at least one > repository on one machine would be useful to see. I see a 4x speedup on a large Git-enabled home directory, as follows: $ time (git status --porcelain | wc -l) 212 0.01s user 0.02s system 0% cpu 9.021 total $ time (git status --porcelain | grep '??' &>/dev/null) 0.01s user 0.02s system 0% cpu 12.294 total $ time (git status --porcelain | grep -q '^?? ' 2>/dev/null) 0.01s user 0.01s system 0% cpu 3.097 total --Sig_/AbusKWjLXFM.n.Cqs7/pKf0 Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEExYVoYL7cegUJ4abW894Q++kwN+IFAmDaU+BfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEM1 ODU2ODYwQkVEQzdBMDUwOUUxQTZENkYzREUxMEZCRTkzMDM3RTIACgkQ894Q++kw N+KgaBAAh84bhTpiGRZ+D3mY0xMgfBecHd2VDFpJcmnHDpKzRKFKI+7J48B5lozv 158wXdsAc1sikZ69GL+aMRHd3lZnpubZnNVPy//4T3lb82DTigt6YcIDdnrm25mS rKu6pUveFrUzl+uhk7Jflqdhyfd/vqkvpkv3G5OBgz7rposAzOZjFOXgpS++P40q lhyfj3didbg8GkMkVjWWJdVa8lLMrKDp5htUyEmXDj+Sop8VBzq7Yo6gWoZNCr2W Wsk+tkpePW8UwDufTR6LOwxMK2WB7SJBmK649F7rPjDtehqmwFSyRYwjNfqQPGb2 1keQuVutDFbnesi3LaC8f19AxvQt5uoSJC0YB3ZgOZ0DJ2uxcKp5pr7zgdOrNdeq RRd45fOY7/9qLe0GxsUErMPV32XjCYcWV0rmsHiNfTCFY9pGex+fTGpc+EPV8ZT9 BU/XnMgUgstUHdigIv1pZtkx1clZWudj2++8Ayatu0hrfFq16gWP7CSMQnMQaQhg HMLTiNa0JZ+/H/V2YjJkIWiWvvtLFYU8uYzODuAjxbTyj7kZ/0ki4nJK6RieJqhc oEZcTGHJURMI5X7YHxDkBLN4cjMtfJydYoVRrVxsacl7tcll9qIHR4Zr0J5Hrd8h NP/LcCUKAMgKbSM3MvXUkN2gIHZHUIVDehULiuIIhcoLAm4Rabc= =+hHR -----END PGP SIGNATURE----- --Sig_/AbusKWjLXFM.n.Cqs7/pKf0--