bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#42966: 28.0.50; vc-dir: wrong backend


From: Dmitry Gutov
Subject: bug#42966: 28.0.50; vc-dir: wrong backend
Date: Sat, 17 Oct 2020 23:44:03 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

On 17.10.2020 10:13, Lars Ingebrigtsen wrote:
And here's the benching with the patch applied:

(benchmark-run 1000
   (vc-responsible-backend "/tmp/git-dir/dir1/dir2/hg-dir/bar"))
=> (0.375446369 10 0.07836344099999998)

(benchmark-run 100
   (vc-responsible-backend "/ssh:stories:/tmp/git-dir/dir1/dir2/hg-dir/bar"))
=> (3.485639896 110 1.00616348)

Er...  the local version is now faster?  Is a throw expensive, somehow?
Probably not very significant.

Is it possible that you didn't restart Emacs between the tests?

vc-git-root (at least) does some caching, which muddies the waters.

Or try this test, with both versions of code:

(benchmark-run 1000
  (progn (vc-file-clearprops FILE)
         (vc-responsible-backend FILE)))

But as expected, the tramp version is slower, because it does more
lookups remotely.  But not hugely.

By 23%? That's a bit more than I expected just by looking at vc-handled-backends, which has 9 elements. 1/9 => 11%.

I don't have a strong opinion on the remote performance, but we might want to ask Michael. Looking at the code, it seems to have forced him to unfortunate measures in the past (such as adding said caching to vc-git-root).





reply via email to

[Prev in Thread] Current Thread [Next in Thread]