-
Notifications
You must be signed in to change notification settings - Fork 712
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
Merge common parts of process walker and connection walker #1011
Comments
I read over the code and don't see any obvious common parts between the two walkers: While both do Am I missing something? |
probe/process/walker_linux.go calls ReadDirNames but it actually doesn't care about the names and only reports the number of files:
I don't think that would change the performances much, but we could try. |
With readdirnames.go, I ran 2000 iterations over
The code takes a couple of assumptions on procfs:
That's a 28% gain on my laptop with 340 processes running. It's better than I thought. I don't know how much it would help Scope (Scope does not do that many iterations over /cc @ekimekim |
After #961 they are both going through
/proc/PID/fd/*
. See #812 (comment)The text was updated successfully, but these errors were encountered: