Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Investigate glob() speed #273

Closed
peterebden opened this issue Feb 8, 2018 · 1 comment
Closed

Investigate glob() speed #273

peterebden opened this issue Feb 8, 2018 · 1 comment

Comments

@peterebden
Copy link
Member

Suggestion from alandonovan:

FYI: in my own experiments I have found that glob is crucial to performance, and that you can do much better by avoiding filepath.Walk and even os.Readdir and doing the recursion yourself directly over the Linux or Darwin getdents system call, which gives you the name and isdir bit of every entry in an entire directory each file in a single system call.

I've not looked at optimising it in any detail, but if we can make it faster that would be cool. The returned values probably still need to be deterministic though (since srcs preserve their original order - we could also change that but I'm sure we rely on that somewhere).

@dgryski
Copy link

dgryski commented Feb 21, 2018

Upstream issue is golang/go#16399

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants