Received: (at 24126) by debbugs.gnu.org; 18 Aug 2021 14:40:11 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Aug 18 10:40:11 2021 Received: from localhost ([127.0.0.1]:57194 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1mGMji-0002gn-SQ for submit <at> debbugs.gnu.org; Wed, 18 Aug 2021 10:40:11 -0400 Received: from quimby.gnus.org ([95.216.78.240]:38934) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <larsi@HIDDEN>) id 1mGMjg-0002gS-Gg for 24126 <at> debbugs.gnu.org; Wed, 18 Aug 2021 10:40:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=P79wTR7LskDfzrCXFNQPPQIyNOEd5ynjSWLj5nX6sT8=; b=tZJOzMbj3nDFQU9IXTqNhLaAoB KKfbOV7zXB5h7b5tRxJKY6CLwi4pOBOxdr7nriFDbBcOQpE6Fcxnr2VjWH1l9RBns7SvkA2EJo6N2 LevqGDNl6LmY7SovFX7qt6NqHm8Z3VlEl3ZNd9KcOfF+GTZzh3cwLVrpms2YWtHGrTW8=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <larsi@HIDDEN>) id 1mGMjW-0000tL-9u; Wed, 18 Aug 2021 16:40:02 +0200 From: Lars Ingebrigtsen <larsi@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#24126: vc-hg-state can be extremely slow References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> <803901e8-fb81-82c1-647f-007bbbf7caf7@HIDDEN> <87a6linb4x.fsf@HIDDEN> <5a178cc6-a628-64c5-b0c5-e8d7c09cd7a2@HIDDEN> Date: Wed, 18 Aug 2021 16:39:57 +0200 In-Reply-To: <5a178cc6-a628-64c5-b0c5-e8d7c09cd7a2@HIDDEN> (Dmitry Gutov's message of "Tue, 17 Aug 2021 03:14:13 +0300") Message-ID: <87eeaqbyv6.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Dmitry Gutov <dgutov@HIDDEN> writes: > I think that only happens once per root per Emacs session (after that > the directory's backend is cached). Yup. If I instrument the function and then do a vc-root-diff in a fresh Emacs session, I get the expected backtrace: Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 24126 Cc: 24126 <at> debbugs.gnu.org, Jonathan Kotta <jpkotta@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Dmitry Gutov <dgutov@HIDDEN> writes: > I think that only happens once per root per Emacs session (after that > the directory's backend is cached). Yup. If I instrument the function and then do a vc-root-diff in a fresh Emacs session, I get the expected backtrace: Debugger entered--entering a function: * vc-hg-state("/tmp/hg/") apply(vc-hg-state "/tmp/hg/") vc-call-backend(Hg state "/tmp/hg/") vc-state-refresh("/tmp/hg/" Hg) vc-state("/tmp/hg/" Hg) vc-hg-registered("/tmp/hg/") apply(vc-hg-registered "/tmp/hg/") vc-call-backend(Hg registered "/tmp/hg/") #f(compiled-function (b) #<bytecode -0x1056748a7cc3b17d>)(Hg) mapc(#f(compiled-function (b) #<bytecode -0x1056748a7cc3b17d>) (RCS CVS SVN SCCS SRC Bzr Git Hg)) vc-registered("/tmp/hg/") vc-backend("/tmp/hg/") vc-working-revision("/tmp/hg/") vc-root-diff(nil) eval((vc-root-diff nil) t) eval-expression((vc-root-diff nil) nil nil 127) funcall-interactively(eval-expression (vc-root-diff nil) nil nil 127) call-interactively(eval-expression nil nil) command-execute(eval-expression) -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at 24126) by debbugs.gnu.org; 17 Aug 2021 00:14:23 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Aug 16 20:14:23 2021 Received: from localhost ([127.0.0.1]:51157 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1mFmkJ-0003Ga-E5 for submit <at> debbugs.gnu.org; Mon, 16 Aug 2021 20:14:23 -0400 Received: from mail-wm1-f51.google.com ([209.85.128.51]:40658) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1mFmkH-0003GN-Nq for 24126 <at> debbugs.gnu.org; Mon, 16 Aug 2021 20:14:22 -0400 Received: by mail-wm1-f51.google.com with SMTP id x2-20020a1c7c02000000b002e6f1f69a1eso611192wmc.5 for <24126 <at> debbugs.gnu.org>; Mon, 16 Aug 2021 17:14:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=CIZY7N0yZqXRRv4ISyfV0g7tfFSiiyau3vTICyBKDYs=; b=E00INPfbOFIcwqQdGu6jbxJ1vvkRwdT+H3pselBEYjSvgSdHTYwhF1fqbPtMUwq7bf jvdCXeKZPJVfUuOguw3ksrGEtEWAXThoyWnmbUJ4yNvZz43hCANCID9gFt2l0Us/RbtT U8qFbsHVcIfAnsCtnLAEXtVn2naNAfM/aMjYvcQiEHlOsvdi/xMwVq697am86XQ44Koz 1d52wDkpYOSnf0oYeMmruFfJkz7vHtFAQMEUPuXVfAgU060jN11fgY1VTmDGlWvxZBtd QCZEObJpMsNZPc0K7LO+Nq2ldKhVXysfeEK6WLLWd83ymfSV44C6lc+PTI+8wax1cSzl JJxQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:subject:to:cc:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=CIZY7N0yZqXRRv4ISyfV0g7tfFSiiyau3vTICyBKDYs=; b=Y2Wy21I6fDtfbsGymfun63jBo3ojN3UJ+j4Ai8u2MqmRkxoPKusalqshw0OgQrSUQF XpeKSPpsMPqED6suA2efksuJM8wkiSSispIz4rkgSuCyZAhUq7qirCkg0gCXO3V1qCUh WemLR1H0psKSo3tSsFMljU8NsB1gMLGO+64YwYFrbOixFT62ByXlXl0Ue8b43uft4Iyh uPlV7cSS0LJsq+dELQI4KoTX8b0vybfIWt6014EztqQPa+/hRWjNe9Ck49jrjPH5VQOD C2iEHrhN2wex0ioNs5dlEgvTr1D28kFUKk9nE/tOQEqvZUEDAcg60RnSZTUkm3v+VaF9 zDIw== X-Gm-Message-State: AOAM532wAbD/gsMTmVxJN/a9bKLXF5pEPcqPdESCvPDCQV3RMcs19p9Q AVc4sGIuXlzU546We6nTvB8E7NAIYgk= X-Google-Smtp-Source: ABdhPJzc+eIw6yNBpxilNTaIZ4M5/nsOLJ39+C1xNbW5gI1VFlF19d54MbDxC06abxiY3Pfel48v3Q== X-Received: by 2002:a7b:cf12:: with SMTP id l18mr601258wmg.130.1629159255951; Mon, 16 Aug 2021 17:14:15 -0700 (PDT) Received: from [192.168.0.6] ([46.251.119.176]) by smtp.googlemail.com with ESMTPSA id z7sm304905wmi.4.2021.08.16.17.14.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 16 Aug 2021 17:14:15 -0700 (PDT) Subject: Re: bug#24126: vc-hg-state can be extremely slow To: Lars Ingebrigtsen <larsi@HIDDEN> References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> <803901e8-fb81-82c1-647f-007bbbf7caf7@HIDDEN> <87a6linb4x.fsf@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <5a178cc6-a628-64c5-b0c5-e8d7c09cd7a2@HIDDEN> Date: Tue, 17 Aug 2021 03:14:13 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <87a6linb4x.fsf@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.4 (/) X-Debbugs-Envelope-To: 24126 Cc: 24126 <at> debbugs.gnu.org, Jonathan Kotta <jpkotta@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.6 (/) On 15.08.2021 15:30, Lars Ingebrigtsen wrote: > This was five years ago -- I tried reproducing this by instrumenting > `vg-hg-state' in a hg-covered directory, and that function was not > called when doing vc-root-diff there. I think that only happens once per root per Emacs session (after that the directory's backend is cached). > So has this been fixed in the intervening years? Probably not. It's not too slow here in the project I've tried it with, but it doesn't have many ignored files (which was the situation in the report).
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at 24126) by debbugs.gnu.org; 15 Aug 2021 12:30:37 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Sun Aug 15 08:30:37 2021 Received: from localhost ([127.0.0.1]:46026 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1mFFHh-0003nO-2O for submit <at> debbugs.gnu.org; Sun, 15 Aug 2021 08:30:37 -0400 Received: from quimby.gnus.org ([95.216.78.240]:58680) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <larsi@HIDDEN>) id 1mFFHc-0003eS-Mu for 24126 <at> debbugs.gnu.org; Sun, 15 Aug 2021 08:30:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=1tyF180rJpesxjqLdVnIZN2d0557OUTY/IsaFysQm8c=; b=tTHe1JK50jJuDwaCUcwBkDyIYv xLQ2o9NJtx/0S1LPexEjcMCMcEtn4Cr7m83AshZZ/i50WZJ8IIRL8IebsFhk0dxRZm/x2Lm3X2B/0 HnnNfKfvOzke1aQnGbgnQ/kwa83aG8qvhWcCVIIu5x2xz6bFEQhhs6SRUxhp1ikOnPFA=; Received: from [84.212.220.105] (helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from <larsi@HIDDEN>) id 1mFFHS-000098-Hp; Sun, 15 Aug 2021 14:30:26 +0200 From: Lars Ingebrigtsen <larsi@HIDDEN> To: Dmitry Gutov <dgutov@HIDDEN> Subject: Re: bug#24126: vc-hg-state can be extremely slow References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> <803901e8-fb81-82c1-647f-007bbbf7caf7@HIDDEN> Date: Sun, 15 Aug 2021 14:30:22 +0200 In-Reply-To: <803901e8-fb81-82c1-647f-007bbbf7caf7@HIDDEN> (Dmitry Gutov's message of "Tue, 2 Aug 2016 19:19:30 +0300") Message-ID: <87a6linb4x.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Dmitry Gutov <dgutov@HIDDEN> writes: >> In the case of `vc-root-diff` at least, it's passing in a directory; the >> command is essentially `hg status -A ./`, and the CWD is indeed the repo >> root. I did this by running `vc-root-diff` fr [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 24126 Cc: 24126 <at> debbugs.gnu.org, Jonathan Kotta <jpkotta@HIDDEN> X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -3.3 (---) Dmitry Gutov <dgutov@HIDDEN> writes: >> In the case of `vc-root-diff` at least, it's passing in a directory; the >> command is essentially `hg status -A ./`, and the CWD is indeed the repo >> root. I did this by running `vc-root-diff` from a dired buffer visiting >> the repo root. > > OK, thanks. The chain of calls looks like this: > > vc-hg-state("~/vc/mozilla-central/") > vc-hg-registered("~/vc/mozilla-central/") > apply(vc-hg-registered "~/vc/mozilla-central/") > vc-call-backend(Hg registered "~/vc/mozilla-central/") > vc-registered("~/vc/mozilla-central/") > vc-backend("~/vc/mozilla-central/") > vc-working-revision("~/vc/mozilla-central/") > vc-root-diff(nil t) This was five years ago -- I tried reproducing this by instrumenting `vg-hg-state' in a hg-covered directory, and that function was not called when doing vc-root-diff there. So has this been fixed in the intervening years? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at 24126) by debbugs.gnu.org; 2 Aug 2016 16:19:40 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Aug 02 12:19:40 2016 Received: from localhost ([127.0.0.1]:53817 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1bUcPs-0005XI-Ki for submit <at> debbugs.gnu.org; Tue, 02 Aug 2016 12:19:40 -0400 Received: from mail-lf0-f53.google.com ([209.85.215.53]:34063) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1bUcPr-0005X5-5f for 24126 <at> debbugs.gnu.org; Tue, 02 Aug 2016 12:19:39 -0400 Received: by mail-lf0-f53.google.com with SMTP id l69so142082962lfg.1 for <24126 <at> debbugs.gnu.org>; Tue, 02 Aug 2016 09:19:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=NqvFvNwCNeJiLR0Q2oXtatEojmrukT0FEHtRZXGp1uw=; b=AktP9PG4no3tNC8dfArOTqkIF+T2S87HRw0YtzG8rxtpQKUsdd85hvrkqSLqKsIj5d fpKwSPhdZmyPcdjaUIrc/eefMGxJ6C6vied3lB5mwEBd0Aja19CfnYG/e0PlTRjBehEE 5ZYu5w2sCAjZVX8W9r/84GZEQCFUH7IoxV9fdYBognp8FBHO0asIVwpOPN0uESdfj/N0 d4pKrUL2ON5kQQRc5QTjCM1dVVB4vHIXIMzWIvc9eP0mcOwrCou/0HmbLZzkexhvAnvw htmib6fpwMOazg6jq3AToTuyNeU6JEcrjbvhThB9fUizIYi2awuxqTxaZT7uoZc08zKz vz3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:to:references:cc:from:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=NqvFvNwCNeJiLR0Q2oXtatEojmrukT0FEHtRZXGp1uw=; b=hzud18OBXvQ3W51L6BdGVAwk3v9bvl5zBIL5ijn3NqTdKcpAigPyqKxK+MoP+8wVxU GeG6nlypvILfhxjwydyr9uK9y2rkonySsmHj/wHgVDd48TfeOelDd/xr/Db893oPihUw YD3z1m4KCd+3tm9aEAHDPVsg/8ed55AXJg2wGIC36U0JrFMUweZK98825ashU2YNAPIR DmToG3Ih527cbSWCX33lmYGXPUZ6IXajbjdZcJle8Ay9x31ET6M2VSJxgOPPaBlHHsGg vMGuvr+oKymDpK5MHW6O4jGd8PxePiZj0Q821ov8sUPAXrnJdy6ccBdhd37/z0Pcsf6A WxJQ== X-Gm-Message-State: AEkooutwPJ+/owSDbIDfUn3Fx0I1e8Kc5jciyHTa9d77PLLBlyrfmO/mJzGtc8OBxxSf3g== X-Received: by 10.46.71.69 with SMTP id u66mr18771449lja.14.1470154773093; Tue, 02 Aug 2016 09:19:33 -0700 (PDT) Received: from [192.168.1.190] ([178.252.127.239]) by smtp.googlemail.com with ESMTPSA id g11sm616421lji.25.2016.08.02.09.19.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 Aug 2016 09:19:32 -0700 (PDT) Subject: Re: bug#24126: vc-hg-state can be extremely slow To: Jonathan Kotta <jpkotta@HIDDEN> References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <803901e8-fb81-82c1-647f-007bbbf7caf7@HIDDEN> Date: Tue, 2 Aug 2016 19:19:30 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:47.0) Gecko/20100101 Thunderbird/47.0 MIME-Version: 1.0 In-Reply-To: <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.1 (/) X-Debbugs-Envelope-To: 24126 Cc: 24126 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.1 (/) On 08/02/2016 06:57 PM, Jonathan Kotta wrote: > In the case of `vc-root-diff` at least, it's passing in a directory; the > command is essentially `hg status -A ./`, and the CWD is indeed the repo > root. I did this by running `vc-root-diff` from a dired buffer visiting > the repo root. OK, thanks. The chain of calls looks like this: vc-hg-state("~/vc/mozilla-central/") vc-hg-registered("~/vc/mozilla-central/") apply(vc-hg-registered "~/vc/mozilla-central/") vc-call-backend(Hg registered "~/vc/mozilla-central/") vc-registered("~/vc/mozilla-central/") vc-backend("~/vc/mozilla-central/") vc-working-revision("~/vc/mozilla-central/") vc-root-diff(nil t) Maybe vc-hg-registered shouldn't delegate to vc-hg-state, and call 'hg status' on its own without '-A'.
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at 24126) by debbugs.gnu.org; 2 Aug 2016 15:58:21 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Aug 02 11:58:21 2016 Received: from localhost ([127.0.0.1]:53791 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1bUc5F-00050b-JB for submit <at> debbugs.gnu.org; Tue, 02 Aug 2016 11:58:21 -0400 Received: from mail-pf0-f173.google.com ([209.85.192.173]:35853) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <jpkotta@HIDDEN>) id 1bUc5E-00050N-7H for 24126 <at> debbugs.gnu.org; Tue, 02 Aug 2016 11:58:20 -0400 Received: by mail-pf0-f173.google.com with SMTP id h186so67529879pfg.3 for <24126 <at> debbugs.gnu.org>; Tue, 02 Aug 2016 08:58:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=YY0rudtg9Oh4MhqU+/azTbR8d6STvsmK4L5wZSDjNWg=; b=JtqE6DMGborWNuwUis6JFtrYfwvipVA19P8apg0uhP5NhgPG/OOgEGDnyXU+cxoQuw Pmbs9oIYiR4KAwE0dy4klDkzbfQzMtpbayKiNx/uvSxRiGZdiapb9zcDsX1ihAUo3WXS gMWntP11ftn7swRKrYc9DnFem+kKxM0XUDiAya61w2gEd3xGOOKDuqkeiN6eizgYfjFt /YxBlHrhnpGQ31VgN00FnBPKfCSFENzPEfclBRcybEUQK24dF++KSguif+xgKQ1WaK0D uq676il5eOCUBrEPlcEdQMbMNn3qGlNpCWltFL3j0vhx7fqMjnCGYjrsMBYl9SBnX0Bt pB6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=YY0rudtg9Oh4MhqU+/azTbR8d6STvsmK4L5wZSDjNWg=; b=cE81lVTn+mk7EQ21ORLO10mb25fEblvXDG7swAqDwfWhkwEldCQ6Ba1AmUg7w84uKz gT0LgE4IjQZmR/i59TeEPtoLojVGvxkDFM/DBPugfpPmQU70ikTntS8j9vdx6cpGPoeQ fjz5Ohgvhw4rU6nFT0iCfQ4qIgS4TsCNKoGlDHi33eQg7XInGZ2IID78W8Zt5pKh71PW voLCUWaazDxUPaoxuIeBJFeXyixiOV6C3bPcz9Ci9zLGJI8FdC8x/mrVB02q2SwSRSbc KFFXmuQyUvL4ztBdT6uRs3eeojTEBYsAxMsUZKPnew6skwPmq2/RI5XLocv6caDe5lD8 cdaQ== X-Gm-Message-State: AEkoouvCzev7hRpGauwjaI3qXTF3zUHuk8bsPuZBxyqCS1fVd2+ecWoD4V6s6IbTwGmucAmZzvZ9X+3YMrrrbw== X-Received: by 10.98.102.79 with SMTP id a76mr107200111pfc.75.1470153494213; Tue, 02 Aug 2016 08:58:14 -0700 (PDT) MIME-Version: 1.0 Received: by 10.66.249.231 with HTTP; Tue, 2 Aug 2016 08:57:33 -0700 (PDT) In-Reply-To: <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> From: Jonathan Kotta <jpkotta@HIDDEN> Date: Tue, 2 Aug 2016 10:57:33 -0500 Message-ID: <CALDneavS7QoF+YtiW=2DvOn95KdAi3WQcz-cOdSwxXgxnWn1AA@HIDDEN> Subject: Re: bug#24126: vc-hg-state can be extremely slow To: Dmitry Gutov <dgutov@HIDDEN> Content-Type: multipart/alternative; boundary=001a113ab046c9b922053918c894 X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 24126 Cc: 24126 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.7 (/) --001a113ab046c9b922053918c894 Content-Type: text/plain; charset=UTF-8 On Tue, Aug 2, 2016 at 8:32 AM, Dmitry Gutov <dgutov@HIDDEN> wrote: > On 08/01/2016 09:40 PM, Jonathan Kotta wrote: > >> Emacs uses `hg status -A` in vc-hg-state, which in turn is used in many >> vc commands (e.g. vc-root-diff). The "-A" option makes mercurial look >> at all files under the directory, even the ignored ones. If there are a >> lot of ignored files, this will be very slow. >> > > Why does it do that? We're passing a specific file name to it. > In the case of `vc-root-diff` at least, it's passing in a directory; the command is essentially `hg status -A ./`, and the CWD is indeed the repo root. I did this by running `vc-root-diff` from a dired buffer visiting the repo root. -- Thanks, Jonathan Kotta Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law. --001a113ab046c9b922053918c894 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><br><div class=3D"gmail_extra"><br><div class=3D"gmail_quo= te">On Tue, Aug 2, 2016 at 8:32 AM, Dmitry Gutov <span dir=3D"ltr"><<a h= ref=3D"mailto:dgutov@HIDDEN" target=3D"_blank">dgutov@HIDDEN</a>><= /span> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8= ex;border-left:1px #ccc solid;padding-left:1ex"><span class=3D"">On 08/01/2= 016 09:40 PM, Jonathan Kotta wrote:<br> <blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p= x #ccc solid;padding-left:1ex"> Emacs uses `hg status -A` in vc-hg-state, which in turn is used in many<br> vc commands (e.g. vc-root-diff).=C2=A0 The "-A" option makes merc= urial look<br> at all files under the directory, even the ignored ones.=C2=A0 If there are= a<br> lot of ignored files, this will be very slow.<br> </blockquote> <br></span> Why does it do that? We're passing a specific file name to it.<br></blo= ckquote><div><br></div><div>In the case of `vc-root-diff` at least, it'= s passing in a directory; the command is essentially `hg status -A ./`, and= the CWD is indeed the repo root.=C2=A0 I did this by running `vc-root-diff= ` from a dired buffer visiting the repo root.</div><div><br></div></div>-- = <br><div class=3D"gmail_signature" data-smartmail=3D"gmail_signature"><div = dir=3D"ltr">Thanks,<br><br>Jonathan Kotta<br><br>Hofstadter's Law:<br>= =C2=A0 =C2=A0 It always takes longer than you expect, even<br>=C2=A0 =C2=A0= when you take into account Hofstadter's Law.</div></div> </div></div> --001a113ab046c9b922053918c894--
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at 24126) by debbugs.gnu.org; 2 Aug 2016 13:32:48 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Aug 02 09:32:48 2016 Received: from localhost ([127.0.0.1]:53447 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1bUZoO-0001cd-1u for submit <at> debbugs.gnu.org; Tue, 02 Aug 2016 09:32:48 -0400 Received: from mail-lf0-f47.google.com ([209.85.215.47]:35143) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <raaahh@HIDDEN>) id 1bUZoL-0001cP-SN for 24126 <at> debbugs.gnu.org; Tue, 02 Aug 2016 09:32:46 -0400 Received: by mail-lf0-f47.google.com with SMTP id f93so138578411lfi.2 for <24126 <at> debbugs.gnu.org>; Tue, 02 Aug 2016 06:32:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:subject:to:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=mZzd5bTNMDvSDrL8PqVWyxFOua1GFbW9y5Y/OPxlA1I=; b=vsjkF4mCgUW/VXIvJxm3y6r4AQgS9sOAzochAIdMc3Rr9w5r9ibB2raTPmH0JaKK05 KxnsGfN1IZ17W0s1pOJPGrHScCK6Xb1muPNTgOUl1so/+xirIIBxQFCEF5d41Bfk0mGA kzUE/RCvq410ewZeX7mIROypEZsL2/iHXJgdV1rtQ3ipFagvKUbh9xFoSyJAb0FkCPJY bnUhMyklFbJvUqlIea00s4sUPZKNheXHgasnGyr9ZdAChBv7WhGIHWouUs6PawRQoUTN mDYg1qMhIu8rgL6gsKBeH1uQmYSBVXNx2dYnLhc6dkAtnUw0o/APmTPMhxP0K5QdbpKI kKAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:to:references:from:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=mZzd5bTNMDvSDrL8PqVWyxFOua1GFbW9y5Y/OPxlA1I=; b=D2HZKFJQC9MTQ0AE3mvyK596qlib7e4L1U1mXHkY6NpcMiigsloK19yH2s6Edv9dMr OTDFH5kpyHj9Tz56TW2ua094UZODrHWykVTdFwyZ/nBadAZUO/yjyYY1hzPcYKPyBQCU Wi4VDSeGmljyXdO6LrAdx1sFXFqe4HtIDYp1/N6o2/34vF3XCbpQpaeXgUjuZaJPGuLp DrBlc5v+7zIu0sz1WRpg2SlNlHXZkzggB5b/y5yHBSd1u+p0sDxSrnfls7Y4LYENB8YM 6mjkq0CD18ZlFImdg8NQBb71uAE1YumVO7xFBiL7oAaM9gGCTBq6eeofj/h0kLRCOufx GSMA== X-Gm-Message-State: AEkoouuUQ8ra0Fdob3GyKNz6Bz3IocwHbcwxooj1BCaU93oKI8FXqu1oZS8oQfaiQKjj7g== X-Received: by 10.25.38.207 with SMTP id m198mr21271738lfm.201.1470144759614; Tue, 02 Aug 2016 06:32:39 -0700 (PDT) Received: from [192.168.1.190] ([178.252.127.243]) by smtp.googlemail.com with ESMTPSA id k63sm501279lfe.48.2016.08.02.06.32.38 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 02 Aug 2016 06:32:38 -0700 (PDT) Subject: Re: bug#24126: vc-hg-state can be extremely slow To: Jonathan Kotta <jpkotta@HIDDEN>, 24126 <at> debbugs.gnu.org References: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> From: Dmitry Gutov <dgutov@HIDDEN> Message-ID: <932b12d0-6081-99c4-91f7-ed00f42462f2@HIDDEN> Date: Tue, 2 Aug 2016 16:32:37 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:47.0) Gecko/20100101 Thunderbird/47.0 MIME-Version: 1.0 In-Reply-To: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -0.1 (/) X-Debbugs-Envelope-To: 24126 X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.1 (/) On 08/01/2016 09:40 PM, Jonathan Kotta wrote: > Emacs uses `hg status -A` in vc-hg-state, which in turn is used in many > vc commands (e.g. vc-root-diff). The "-A" option makes mercurial look > at all files under the directory, even the ignored ones. If there are a > lot of ignored files, this will be very slow. Why does it do that? We're passing a specific file name to it. > As an example, I have a repo that's 38MB / 300 files when freshly > checked out, and 34GB / 1.2M files when the build finishes (if you're > curious, it's a yocto project). Without clearing the disk cache, `hg > stat -A > /dev/null` takes 28s; What about 'hg status -A file/name > /dev/null'? > vg-git-state does not have this problem; currently it behaves like `hg > status`, i.e. honoring the ignore rules. There is actually a FIXME > comment regarding this functionality, noting that `git ls-files -i -o > --exclude-standard` is the equivalent to `hg status -A`; this takes over > 400s (I got sick of waiting). The FIXME is outdated, we'll do it by parsing 'git status --porcelain'. Does 'git status --ignored --porcelain -- file/name' take a lot of time for you as well? > I'm guessing VC has some sort of assumption that vc-x-state will return > all files. vc-x-state returns the state of a single file.
bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 1 Aug 2016 18:41:30 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Mon Aug 01 14:41:30 2016 Received: from localhost ([127.0.0.1]:53158 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1bUI9a-0005ZL-Fx for submit <at> debbugs.gnu.org; Mon, 01 Aug 2016 14:41:30 -0400 Received: from eggs.gnu.org ([208.118.235.92]:53929) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <jpkotta@HIDDEN>) id 1bUI9Y-0005Z4-7H for submit <at> debbugs.gnu.org; Mon, 01 Aug 2016 14:41:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <jpkotta@HIDDEN>) id 1bUI9R-0007US-Or for submit <at> debbugs.gnu.org; Mon, 01 Aug 2016 14:41:22 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:39784) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <jpkotta@HIDDEN>) id 1bUI9R-0007UN-LY for submit <at> debbugs.gnu.org; Mon, 01 Aug 2016 14:41:21 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44900) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <jpkotta@HIDDEN>) id 1bUI9P-0002RH-6i for bug-gnu-emacs@HIDDEN; Mon, 01 Aug 2016 14:41:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <jpkotta@HIDDEN>) id 1bUI9O-0007U7-6E for bug-gnu-emacs@HIDDEN; Mon, 01 Aug 2016 14:41:19 -0400 Received: from mail-pf0-x231.google.com ([2607:f8b0:400e:c00::231]:34656) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from <jpkotta@HIDDEN>) id 1bUI9N-0007U2-RI for bug-gnu-emacs@HIDDEN; Mon, 01 Aug 2016 14:41:18 -0400 Received: by mail-pf0-x231.google.com with SMTP id p64so57884550pfb.1 for <bug-gnu-emacs@HIDDEN>; Mon, 01 Aug 2016 11:41:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to; bh=iNw5z4CMox7reLDFWdpSpI+njm6m6ZfQ3zVILI/aeWk=; b=Esozb9fdSOpSizsUhHpHm8Q2FTH3SCy265sVL62IiJ3AraVjI9CSJIZ6M2P8/o2XJk Bli6kxqwmPsT1KgEvUrJOzH25+rSkWdXZf+lwpQB0D/b4nlUI4EZpLYmH8idCIvIbljm f2s7xtFQjl3JuhfK9mPXKQrRNvlVfEacNXbEWp5YdRrzBSRjd7e6FGNb/JjFcd1ejM13 xq+f+L4DqsvkAtsfDX0LnmVve+A4xdtQ2sv9htqgC6fBPRQjVVhusrQQhdnqg59SeJWf /lQUv1NdeV+25XlUiiNiL+t0dzSEn3fhog8WKPHfNQDJy7856FEcmRXWPJrVoQbf9EYp az2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=iNw5z4CMox7reLDFWdpSpI+njm6m6ZfQ3zVILI/aeWk=; b=Jjc0TjHjFOKstfyY7ASrXH+MEutPSA6cklbk/3ntyzFGRs0ldvqr6fZv1WRgsqeNyk 7JCRVAT0prSOL4NoqD2n05tT55Idh76tYA9ofAHax0P7t9pZfzYsj81/czwyFKKLmExV aeyoFsBELXkB8bqatKenJZxODxYzHGhfUoobUjn+HbUTqiH8EpOzgugZuX0yDALjqMaX JyRgw6LuCGr3BSNeM2yLoyd+zA1wx4DYycTUP1x1uYtkTaR3Yoql/ArFuXX8Hjcx9bQr fGrH5yEP1bELXSMrp3P9HXQmY8J8MoNpwxPAns8X77qA5iwc7FZtiRDoc0dqNP1sgUjU vT3Q== X-Gm-Message-State: AEkooutHwgO5FG4piRkyoXlaj9KYB+ieN77BTMnq8+alMkpczN24VyJcnBuV81voV8Zi0uz88d1ORQtjPTE28A== X-Received: by 10.98.102.79 with SMTP id a76mr98444341pfc.75.1470076876439; Mon, 01 Aug 2016 11:41:16 -0700 (PDT) MIME-Version: 1.0 Received: by 10.66.249.231 with HTTP; Mon, 1 Aug 2016 11:40:36 -0700 (PDT) From: Jonathan Kotta <jpkotta@HIDDEN> Date: Mon, 1 Aug 2016 13:40:36 -0500 Message-ID: <CALDneatyn3CMNnY+DUXe2+hyv_igyEQ1aJVgCL+9CO_RPG11rg@HIDDEN> Subject: vc-hg-state can be extremely slow To: bug-gnu-emacs@HIDDEN Content-Type: multipart/alternative; boundary=001a113ab0460348a8053906f219 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -4.0 (----) --001a113ab0460348a8053906f219 Content-Type: text/plain; charset=UTF-8 Emacs uses `hg status -A` in vc-hg-state, which in turn is used in many vc commands (e.g. vc-root-diff). The "-A" option makes mercurial look at all files under the directory, even the ignored ones. If there are a lot of ignored files, this will be very slow. As an example, I have a repo that's 38MB / 300 files when freshly checked out, and 34GB / 1.2M files when the build finishes (if you're curious, it's a yocto project). Without clearing the disk cache, `hg stat -A > /dev/null` takes 28s; it's far longer if the disk cache isn't warmed up or the output is actually used. `hg status` takes about 90ms. vg-git-state does not have this problem; currently it behaves like `hg status`, i.e. honoring the ignore rules. There is actually a FIXME comment regarding this functionality, noting that `git ls-files -i -o --exclude-standard` is the equivalent to `hg status -A`; this takes over 400s (I got sick of waiting). I'm guessing VC has some sort of assumption that vc-x-state will return all files. Maybe the command could bailout after taking too long and use `hg status`. Maybe the command options could be configurable. Personally, I'd prefer just dropping the "-A", because I've never used it and I don't really see why you'd want to get ignored files by default; this is my current solution. I'm using Emacs 24.5.1. I've tested Emacs 25.1.1 and it still has the issue; though vc-hg-state has changed, it still uses "-A" and is still very slow on my repo. -- Thanks, Jonathan Kotta Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law. --001a113ab0460348a8053906f219 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>Emacs uses `hg status -A` in vc-hg-state, which in tu= rn is used in many vc commands (e.g. vc-root-diff).=C2=A0 The "-A"= ; option makes mercurial look at all files under the directory, even the ig= nored ones.=C2=A0 If there are a lot of ignored files, this will be very sl= ow. =C2=A0</div><div><br></div><div>As an example, I have a repo that's= 38MB / 300 files when freshly checked out, and 34GB / 1.2M files when the = build finishes (if you're curious, it's a yocto project).=C2=A0 Wit= hout clearing the disk cache, `hg stat -A > /dev/null` takes 28s; it'= ;s far longer if the disk cache isn't warmed up or the output is actual= ly used. =C2=A0`hg status` takes about 90ms. =C2=A0</div><div><br></div><di= v>vg-git-state does not have this problem; currently it behaves like `hg st= atus`, i.e. honoring the ignore rules. =C2=A0 There is actually a FIXME com= ment regarding this functionality, noting that `git ls-files -i -o --exclud= e-standard` is the equivalent to `hg status -A`; this takes over 400s (I go= t sick of waiting).</div><div><br></div><div>I'm guessing VC has some s= ort of assumption that vc-x-state will return all files.=C2=A0 Maybe the co= mmand could bailout after taking too long and use `hg status`.=C2=A0 Maybe = the command options could be configurable.=C2=A0 Personally, I'd prefer= just dropping the "-A", because I've never used it and I don= 't really see why you'd want to get ignored files by default; this = is my current solution.</div><div><br></div><div>I'm using Emacs 24.5.1= .=C2=A0 I've tested Emacs 25.1.1 and it still has the issue; though vc-= hg-state has changed, it still uses "-A" and is still very slow o= n my repo.<br clear=3D"all"><div><br></div>-- <br><div><div dir=3D"ltr">Tha= nks,<br><br>Jonathan Kotta<br><br>Hofstadter's Law:<br>=C2=A0 =C2=A0 It= always takes longer than you expect, even<br>=C2=A0 =C2=A0 when you take i= nto account Hofstadter's Law.</div></div> </div></div> --001a113ab0460348a8053906f219--
Jonathan Kotta <jpkotta@HIDDEN>
:bug-gnu-emacs@HIDDEN
.
Full text available.bug-gnu-emacs@HIDDEN
:bug#24126
; Package emacs
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.