bug-findutils
[Top][All Lists]
Advanced

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

Re: Faster way to prune directory?


From: Bernhard Voelker
Subject: Re: Faster way to prune directory?
Date: Thu, 16 Apr 2015 17:37:48 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

On 04/16/2015 04:51 PM, Peng Yu wrote:
  real    0m0.340s

real 0m2.455s

Oops, I misread the numbers in your first mail.
On my home machine, the example with /usr/bin/test just takes
about half a second while it takes ~5 seconds on your host.
I now checked on a different system, and it took ~2.5 seconds
there.  The difference is that the fast machine has *much*
more RAM and therefore the directory entries are cached more
effectively there.

Therefore, I assume that whatever you try with a second find
process or whatever, you'll still hit the same RAM and file
system limitations you are hitting now.

The only way out could probably be avoiding exec()s at all
by adding a new syntax like "-stat '{}/.findignore'" to find
... which somehow looks nasty and calls for other problems
like races.

After all, I assume that you want to do something with find's
final output like grep, md5sum, cp etc., so the processing of
find itself may be the smaller part of the processing anyway?

Have a nice day,
Berny



reply via email to

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