|
From: | Markus Schiltknecht |
Subject: | Re: [Monotone-devel] slow update/status on NFS |
Date: | Wed, 23 May 2007 15:36:14 +0200 |
User-agent: | Icedove 1.5.0.10 (X11/20070329) |
Hi, Richard Levitte wrote:
Have a time_t that gets initialised when stat() is used, then compare it with the result of time() at any use,
To really reduce memory consumption, you'd have to compare *all* cached stat results and throw away expired ones.
and if the difference is larger than NNN seconds, do a new stat() first. getting the output of time() should be a fairly cheap operation.
Agreed, but the above is not quite that cheap.
I can't really say if this is really needed, since most paths should be fairly short-lived objects...
That, and for the sake of simplicity, I'd rather like to bind the cached status to the lifetime of the any_path object.
Regards Markus
[Prev in Thread] | Current Thread | [Next in Thread] |