On Wed, Mar 31, 2010 at 03:34:40PM +0200, YoBoY wrote: > After some tests, it appears that the glob function give us a constant > 50% improvement in speed, no real memory difference and a similar > quantity of disk access. > > A mechanism based on file_exists could give a better speed improvement > with a constant time response (more than 90% on a small directory) and > not depending on the number of files in the directories. > > Without considering my particular case of use on a nfs file system with > a meta directory containing more than 12000 files, passing to a glob is > a good choice. But we can do a better job by controlling exactly what we > want to delete without scanning an entire directory to find these files. I see. One sulution I could imagine would be to have a list of known metafiles and allow plugins to register their own types via an action event METAFILE_REGISTER which would be triggered in in metaFiles() maybe. But on the other hand, that sounds like a bit too much too me. Regards, Michael -- Michael Klier www: http://www.chimeric.de jabber: chi@xxxxxxxxxxxxxxxxxx key: http://downloads.chimeric.de/chi.asc key-id: 0x8308F551