[Top][All Lists]

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

Re: tramp no longer recognizes when remote files changed

From: Michael Albinus
Subject: Re: tramp no longer recognizes when remote files changed
Date: Sun, 29 Jul 2007 17:40:34 +0200
User-agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.1.50 (gnu/linux)

Richard Stallman <address@hidden> writes:

> What are the main occasions on which the cache is useful?

I've made a test: Run 1000x (file-attributes "/ssh:ford:/etc/hosts").
"ford" is another host in my LAN.

With enabled cache, it takes 1.821823 sec. Without cache, it takes
60.103737 sec. And it is a nearby host.

A simple (find-file "/ssh:ford:/etc/hosts") shows in the profiler the
following file name handler based functions:

expand-file-name                          127
file-exists-p                             42
file-attributes                           23
file-name-directory                       23
file-directory-p                          11
directory-file-name                       8
substitute-in-file-name                   7
file-name-nondirectory                    5
file-modes                                3
file-readable-p                           2
file-truename                             2
make-auto-save-file-name                  2
file-local-copy                           1
file-symlink-p                            1
file-writable-p                           1
insert-file-contents                      1
set-visited-file-modtime                  1

See f.e. the large number of `file-exists-p' calls. This is mainly due
to vc, there are repeated tests for existence of


> Having a parameter for users to set is not a very good solution.
> First let's look for a way to make Tramp do the right combination
> of things by default.  Michael, can you try?

Tramp flushes the cached data in `verify-visited-file-modtime' now. That
seems to be sufficient.

Sascha, could you, please, test it?

Best regards, Michael.

reply via email to

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