--- Begin Message ---
Subject: |
Use fdopendir, fstatat and readlinkat, for efficiency. |
Date: |
Thu, 24 Jan 2013 00:26:50 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 |
Attached is a patch that can greatly improve the performance of
directory-files-and-attributes, which I'd like to install
into the trunk. The key idea is to use fstatat
instead of lstat; this reduces directory-reading
from an O(ND) to an O(N) operation, where N is the number
of directory entries and D is the length of
the directory's name.
This patch works on POSIXish hosts, but it'll no doubt
need a few changes to the MS-Windows makefiles to compile
fdopendir.c, fstatat.c, openat-die.c, save-cwd.c, openat-proc.c,
or whatever subset of these is needed on MS-Windows.
I'll CC: this to Eli to give him a heads-up.
This patch is relative to trunk bzr 111595.
fdopendir.txt
Description: Text document
--- End Message ---
--- Begin Message ---
Subject: |
Re: bug#13539: Use fdopendir, fstatat and readlinkat, for efficiency. |
Date: |
Thu, 31 Jan 2013 22:42:04 -0800 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2 |
On 01/30/2013 09:27 AM, Eli Zaretskii wrote:
> Works for me, thanks.
OK, pushed into the trunk as bzr 111646,
and marking this bug as done.
--- End Message ---