emacs-devel
[Top][All Lists]
Advanced

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

Re: Slow access to files using UNC path


From: Stefan
Subject: Re: Slow access to files using UNC path
Date: Wed, 08 Sep 2004 07:55:51 -0400
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3.50 (darwin)

>> + (defvar vc-hostname-fs-path-re "\\`\\([\\/][\\/]\\|/net/\\|/afs/\\)"
>> +   "Regex variable used to avoid determining whether file is under vc-arch
>> + or vc-mcvs. The default regexp prevents the determination of type of vc for
>> + folders in UNC, net and afs. This speeds up opening of files by not trying 
>> to
>> + determine whether file is under vc. This can be modified by user to match 
>> a 
>> + different path or paths")

> In Emacs, a 'path' is something like load-path, and we never use the
> term 'path' for a directory name or file name.

Sorry 'bout that.

> IMO, a better name would be something like `vc-ignore-file-re'.

I disagree and I also disagree with the proposed docstring.
We should document what the variable is meant for, not how it's used.
It's meant for filenames which are interpreted by the system as hostnames.

VC uses this variable to avoid looking up non-exitent host names.

> folders in UNC, net and afs. This speeds up opening of files by not trying to
> determine whether file is under vc.

This makes it sound like it's always slow to determine whether a file is
under VC or not, whereas it's normally not the case.  It's only the case for
those special cases which we try to eliminate with this variable: the case
where the filename is used as a hostname and can thus lead to inordinate
waits (timeouts and stuff like that).

> BTW, I don't understand why this is specific for vc-arch and vc-mcvs ?

It's not, but since only VC uses it as of now, it seems to make sense to
only add it in vc-hooks.el.  When some other package finds a use for such
a thing, we can move it (and maybe change it along the way: it may turn out
that something slightly different will be needed at that point).


        Stefan


PS: As for the patch, it still misses the two other places (in the same
file) where we do the same thing again.




reply via email to

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