CPU Usage in task manager should be displayed with more precision |
|||
Issue descriptionChrome's task manager shows CPU time as a percentage of total available CPU time, as an integral percent. This means that on a 4-core/8-thread system a thread that runs continuously will show up as 12 percent (truncated from 12.5%). A thread that is 3% busy will show up as zero percent (truncated from .375%). One Chrome developer machines with 48 threads the behavior is even crazier - a 20% busy thread will show up as 0% busy (truncated from 0.4166%). Two solutions seem possible: 1) Change from percentage of total available CPU time to percentage of a core. This means that numbers would range from 0% to N*100% (so up to 800% on an eight-thread machine). This has the advantage of making numbers more comparable between machines with different numbers of threads, but would be a change in how the numbers are interpreted and would make all of the numbers bigger, and incompatible with task manager and process explorer. 2) Display more digits of precision. The Windows 10 task manager's Processes tab displays CPU usage to a tenth of a percent. Process Explorer from sysinternals displays to a hundredth of a percent. One hundredth of a percent would be ideal for many-core machines. I'd like to see option #2.
,
Aug 31 2016
It looks like CPU is already shown with one decimal digit on MacOS. #if defined(OS_MACOSX) // Match Activity Monitor's default refresh rate. const int64_t kRefreshTimeMS = 2000; // Activity Monitor shows %cpu with one decimal digit -- be consistent with // that. const char kCpuTextFormatString[] = "%.1f"; #else const int64_t kRefreshTimeMS = 1000; const char kCpuTextFormatString[] = "%.0f"; #endif // defined(OS_MACOSX)
,
Aug 31 2016
Note: Mac shows per-core values, so it's possible to see 100% CPU usage if a single tab goes into a busy loop. (I actually much prefer that to showing something like 2% to mean that one core is pegged, but I'm probably just used to it.)
,
Sep 2 2016
I'd love to have per-core values - I agree that they make much more sense. But, since Task Manager and Process Explorer on Windows both display per-system values I think we have to be consistent with that :-( I'd be happy to have somebody talk me out of that...
,
Sep 6 2016
Here is the prototype for showing %CPU with one decimal digit on all platforms. https://codereview.chromium.org/2314303002/diff/1/chrome/browser/ui/task_manager/task_manager_table_model.cc
,
Sep 28 2016
,
Sep 29 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b42085e1042ac37fd3c7928dc8050e69f42c5773 commit b42085e1042ac37fd3c7928dc8050e69f42c5773 Author: stanisc <stanisc@chromium.org> Date: Thu Sep 29 02:43:26 2016 Task Manager: format CPU usage with one decimal digit on all platforms This is a fairly trivial change that adds one decimal point to CPU usage precision on Windows and Linux. It is already displayed with that precision on Mac OS. BUG= 642515 Review-Url: https://codereview.chromium.org/2314303002 Cr-Commit-Position: refs/heads/master@{#421725} [modify] https://crrev.com/b42085e1042ac37fd3c7928dc8050e69f42c5773/chrome/browser/ui/task_manager/task_manager_table_model.cc
,
Oct 20 2016
|
|||
►
Sign in to add a comment |
|||
Comment 1 by stanisc@chromium.org
, Aug 30 2016