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,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 16166 invoked from network); 14 Nov 2022 05:17:41 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 14 Nov 2022 05:17:41 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1668403061; b=pA4AlhuENiiT9K7b3Y7/pbrMNsLtQQ2ElypIjSFT8TtQEXSdAFZf7SePurGOrP2bM8B+63eo4y 6z+CTpb2Ea6Vhj6S45ZeOQf6dnd2UvF1DtA4Zb3mAC5mB7NTDyV4HKtMQf6pJ+xI0dZd/vRvup zPcJ/LA6rT0uuksXfg+Gg2HjNZaH1frLaYsTYsVOSze39/w+j8AY+QKhpw4W9bYAGBa4gGSjaq asiEphQ3zZs+jW1IGg8YAUErtQQN1/o1X77xlOqTp7Ez31a4lODSypn6G0NxxSQNPNTvxxYefi 2x/2Fj28bTGWcVU0UdbwmTnTX5kbKBX6htw2FsKJnGjqog==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-ed1-f42.google.com) smtp.remote-ip=209.85.208.42; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1668403061; bh=4LZY2tWeCO20yQYTQgyrRiXbTF9hyCvjwaJqgofY3WU=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:Cc:To:Subject: Message-ID:Date:From:References:In-Reply-To:MIME-Version:DKIM-Signature: DKIM-Signature; b=EELncAQdC+yzjHBpiAjU6lzUk2QOEprSJeuzpm5l+xbxEWqei+wjyqFR/5q4Q7zdre1Rukqh/T U6Fi600bzoRCByEP9czR818gBLf9Kxat/9uETaIRODb9rDeb6pqJfeazVBDgcUOa2FqJpqlBQG SzLmneL1JrhT37mn0GVWT9+xbUhAC8aLcD10zo+K2t2+pNgpcat2y2keOnOqSJV+JWAXQi+0iC hSjEJFP7lhn89wB5/ddaXiE4XY/ERXPRY+ZR703w0do4oJz1bgDHPR9n1qNMvPTcQkbeMwMCyM wX9LdVaxEc9j/LcweW8Jt1B6MksPK/yj01dETSbRARD/SQ==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Transfer-Encoding: Content-Type:Cc:To:Subject:Message-ID:Date:From:References:In-Reply-To: MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=zN8CSdhrNu3ffTY6bawjecTu7kVLDAh157+dpqqP2qA=; b=gOQVpG/tV4dFn7DVPaParuKgp3 pjyfdc75QzuVynDZKEYJ4HDhB11mQggV5rjvkFdFGfaf3/aLJfAF1P0MUL5xXEmDHJAdXxxSNOjVR KsepItsmavZEbu+1XhxDjH0cDFn391kru/mR14ShXqa7Eae2aCruVj6cFuay27LmG46zXwFKux6A9 2F8YqUdyrszl52Gb+0fepjtSGBlucDzEHSjvHMJ6vPTgWCJUErk76W4c05Y5ZtWPMwdh7QNBmLeVb c31Il7Oy/QvzlskUXEhh2jB8ufOcjQeo+JuS/rojM39BSb9x1CeTuH4mUsmHCS49KBH21Kx6Pb5W5 ok0rYzJw==; Received: by zero.zsh.org with local id 1ouRqm-000Aa6-3J; Mon, 14 Nov 2022 05:17:40 +0000 Authentication-Results: zsh.org; iprev=pass (mail-ed1-f42.google.com) smtp.remote-ip=209.85.208.42; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-ed1-f42.google.com ([209.85.208.42]:35360) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1ouRqB-000ADb-VX; Mon, 14 Nov 2022 05:17:04 +0000 Received: by mail-ed1-f42.google.com with SMTP id x2so15701618edd.2 for ; Sun, 13 Nov 2022 21:17:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=zN8CSdhrNu3ffTY6bawjecTu7kVLDAh157+dpqqP2qA=; b=jEzxgZ7S9pE4vD7Q000QDPCFLI82zWa69Itv++YNUHesrwSIShsfD9jcw5fYR39M7C yMkWLS7NqQ7lFPFs5YGSIGKZoZwmNmFd0QKr7iBKqmqlIz1q0icNrI4P2u75+H7Q9owp BUwTwX/jKDMVKb/SJiFxkh5pKhJ91o+XodsVh0SJLUNh0D9XTaZllVbjC447fmGiq93I j5w5bNVXBWmjPGo+2U109FZ3ViN0B4WyoWqldk4Ln8lNTbfzpiTwjiwX8Bj55Q3FEsAi bTeI1St4woTUke3VWJuMOOE+id/8WW1qIRjNer6EHPlN1xl+jyZuh19gZdVHRlwnpj4v BjnQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=zN8CSdhrNu3ffTY6bawjecTu7kVLDAh157+dpqqP2qA=; b=3kWzM5kUTE+ZJDDoPczPol5oN9kJoY+SbU05tSAS85rUpQHaUvpuehvyhvGaAR2vLO PSUgxJN0+cyypHfLm0mG/NsRF7Gw+0KfA90jsgrvmtKfmyNtpZ1yRco+UgmeUBb6eZeA /G+unSV1k9X9nmfi6pAqdK1u2+lRd8bitsHzzmwmXWXyhxH/MJdpgkFhlnKtnq5quAYx Bzp6qZKXZBKDGCvh3gW+776F+SlhUXwXZCLdB/LFxbC/QC067U3B7etUAmhPpz0kqTx/ EACRx6AHmVvT/ZOal+8aHrSAI6h0Q3kvfx7om/ys9wyG/EyEWl0nXemopzCV6rcO0fwm 32mw== X-Gm-Message-State: ANoB5pn/NQzuRrDH7GmcvhSGMqW7g+jrr4EnU/unyC4jx/PZFX+XKLG/ OBoigjF3UA3pdFzx9si7CUSVCX5gVXIJQIiR7blyqyBD X-Google-Smtp-Source: AA0mqf4+lyvDlNuekvvgpvbP67ClcPVVAr5gVSK9ch5B58r8y72LgrzjEGepRSKxli+3E4bA8Fqe/RLLK3kH4WMhJiw= X-Received: by 2002:a50:ed96:0:b0:464:6485:419b with SMTP id h22-20020a50ed96000000b004646485419bmr10132893edr.382.1668403023419; Sun, 13 Nov 2022 21:17:03 -0800 (PST) MIME-Version: 1.0 Received: by 2002:a17:906:2508:b0:7a6:9215:51b7 with HTTP; Sun, 13 Nov 2022 21:17:02 -0800 (PST) In-Reply-To: References: <20221101030429.38029-1-pete@jpgrayson.net> <20221111114928.GF27622@tarpaulin.shahaf.local2> <603fd1b9-1b11-4729-99cb-19e1c4ef8b37@app.fastmail.com> <20221113043040.GG27622@tarpaulin.shahaf.local2> From: Mikael Magnusson Date: Mon, 14 Nov 2022 06:17:02 +0100 Message-ID: Subject: Re: [PATCH] Remove StGit patch detection from vcs_info To: Peter Grayson Cc: Daniel Shahaf , zsh-workers@zsh.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Seq: 50963 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: On 11/14/22, Peter Grayson wrote: > On Sat, Nov 12, 2022, at 11:30 PM, Daniel Shahaf wrote: >> Peter Grayson wrote on Sat, Nov 12, 2022 at 09:46:02 -0500: >>> On Fri, Nov 11, 2022, at 6:49 AM, Daniel Shahaf wrote: >>> > [re #2]: It sounds like StGit 2.x support can be implemented at the >>> > cost >>> > of one fork(2) for those who don't use StGit and under a microsecond >>> > for >>> > those who do. That doesn't sound like a deal breaker at all. >>> >>> Running `stg series` with StGit 2.0 takes about 12ms in my environment. >>> StGit 1.5 it is about 32ms. Not a microsecond, but perhaps acceptable >>> nonetheless. >>> >> >> To be clear, are these figures the duration of the =C2=ABstg series >> --noprefix --applied=C2=BB invocation? > > Yes. > >> What's the impact on people who don't have stg(1) installed, or who have >> stg(1) installed but are currently in a worktree that doesn't use StGit? >> I.e., are those figures immediately after `git init`, or in a worktree >> that has a StGit patch stack, or? > > Without stg(1) installed, the cost would be however long it takes zsh to > determine that the executable is not available in $path, which is > ostensibly very fast (microseconds?). > > If stg(1) is installed, but run in a repo with a branch that has not been > initialized with `stg init`, it's still about 12ms. Almost all that time > is taken just to initialize a libgit2 Repository structure, which is > used to interrogate the object database to determine whether a StGit > stack is initialized. fwiw, vcs_info lets you configure which vcs systems it looks for, whether or not you have them installed. eg, I use: zstyle ':vcs_info:*:*' enable git hg svn although these days i could surely set that to just git... --=20 Mikael Magnusson