Mobile/Powersaving/Wakeups/Debugging: Difference between revisions

no edit summary
No edit summary
 
(2 intermediate revisions by the same user not shown)
Line 11: Line 11:
* Slightly underreports when compared to powertop. The reason is that each call to a wakeup-related function (like NotifyCondVar) can potentially lead to more than 1 wakeup. In other words, powertop measures absolute wakeups, the tool measures 'logical' wakeups. The two are proportional, so lowering one will lower the other. The ratio is something like 1:1.5.
* Slightly underreports when compared to powertop. The reason is that each call to a wakeup-related function (like NotifyCondVar) can potentially lead to more than 1 wakeup. In other words, powertop measures absolute wakeups, the tool measures 'logical' wakeups. The two are proportional, so lowering one will lower the other. The ratio is something like 1:1.5.


=== Various Wakeups of Note ===
=== Old Approaches to Finding Wakeups ===
 
* Sleep for 0 time in timer thread (2/3 of our wakeups!) - {{bug|596373}}
* IdleService (1/5) - {{bug|584660}}
* nsEventStateManager (1/5) - {{bug|594838}}
* nsHttpHandler (1/10?)
 
=== Old Approach to Finding Wakeups ===


Another approach to finding wakeups is to add some debug prints to the relevant NSPR functions, which are PR_WaitCondVar (in nsprpub/pr/src/pthreads) and so forth, e.g.
Another approach to finding wakeups is to add some debug prints to the relevant NSPR functions, which are PR_WaitCondVar (in nsprpub/pr/src/pthreads) and so forth, e.g.
213

edits