-
Notifications
You must be signed in to change notification settings - Fork 105
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
Needs to do actual CPU usage profiling #8
Comments
That's a great idea, but wouldn't the simpler solution be to check if the call stack ends with a syscall? |
Not sure I understand what you mean. Do you mean that a human being should just check if the stack ends in a Windows system call in order to manually compute CPU usage, or that VS could be enhanced so that it assumes that all Windows system calls are blockers or use zero CPU? Don't some system calls actually use CPU, at least System CPU? If VS could have a default list of the presumed blockers, whether they're all system calls or just certain ones like "NtWaitForMultipleObjects", it might still need them to be editable for special situations.... |
Yes, as an option.
Yes, though I think non-blocking syscalls with exit very quickly, so even if you ignore samples ending with a syscall, you should still get a lot of samples ending with code that will invoke the syscall. |
I am using VerySleepy regularly and a while ago I also thought that measuring CPU time was more relevant than measuring real time. But I realized this is not necessarily true. |
Maybe I'm missing something, but as I understand it, VS takes almost-continuous snapshots of the stack in all/some of the threads in a Windows process. This is extremely helpful, but it doesn't directly indicate which functions are actually responsible for CPU usage, since some of the functions at the bottom of the stack block.
But there are a small, fixed number of functions that block in the Windows libraries. Why can't VS have a list of them, perhaps extensible by the user? The blockers would be interpreted as using zero CPU. Then, VS would be able to declare that any stack trace that doesn't end in a blocker is using CPU, and actually list the functions and their CPU usage....
The text was updated successfully, but these errors were encountered: