New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 687424 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Feb 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Mac
Pri: 3
Type: Bug



Sign in to add a comment

Add comments about Task Manager's idle wakeups calculation

Project Member Reported by shrike@chromium.org, Feb 1 2017

Issue description

For MacOS and Linux, the final line of ProcessMetrics::CalculateIdleWakeupsPerSecond() is

  return (wakeups_delta_for_ms + time_delta / 2) / time_delta;

The time_delta / 2 does not make sense except as a fudge, but even then it doesn't have the right units to be mixed with wakeups_delta_for_ms.

 
Summary: Add comments about Task Manager's idle wakeups calculation (was: Task Manager's idle wakeups calculation is wrong)
The calculation is correct, just not obvious. Adding some comments will help future investigators.

Project Member

Comment 2 by bugdroid1@chromium.org, Feb 3 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/36fa3dee1690ef5561ee86c653fc9b56fcba73e1

commit 36fa3dee1690ef5561ee86c653fc9b56fcba73e1
Author: shrike <shrike@chromium.org>
Date: Fri Feb 03 00:05:35 2017

Add comments explaining Task Manager idle wakeups computation.

Adds some comments that would have been helpful to me as I traced the code to understand it. I think they will be helpful to future readers of the code.

BUG= 687424 

Review-Url: https://codereview.chromium.org/2667023004
Cr-Commit-Position: refs/heads/master@{#447890}

[modify] https://crrev.com/36fa3dee1690ef5561ee86c653fc9b56fcba73e1/base/process/process_metrics.cc
[modify] https://crrev.com/36fa3dee1690ef5561ee86c653fc9b56fcba73e1/base/process/process_metrics_mac.cc

Comment 3 by shrike@chromium.org, Feb 24 2017

Status: Fixed (was: Started)

Sign in to add a comment