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

[Windows] speed up process_iter() #2444

Merged
merged 11 commits into from
Oct 17, 2024
Merged

[Windows] speed up process_iter() #2444

merged 11 commits into from
Oct 17, 2024

Conversation

giampaolo
Copy link
Owner

@giampaolo giampaolo commented Sep 30, 2024

Summary

Description

This is based on #2366 (comment). On Windows, we now determine process unique identity by using process' fast create time method. This has more chances to fail with AccessDenied for ADMIN owned processes, but it shouldn't matter because if we have no rights to get process ctime we'll also have no rights to accidentally kill() the wrong process PID anyway. This should drastically speedup process_iter() when used for retrieving process info one time instead of in a loop (e.g. htop like apps).

@giampaolo giampaolo merged commit 567438c into master Oct 17, 2024
25 of 30 checks passed
@giampaolo giampaolo deleted the win-fast-create-time branch October 17, 2024 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Windows] process_iter() is 10x slower when running from non-admin account
1 participant