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

Issue 796941 link

Starred by 3 users

Issue metadata

Status: Closed
Owner:
Closed: Dec 17
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug-Regression



Sign in to add a comment

Low millisecond resolution in performance profiler and performance.now()

Reported by gebacken...@gmail.com, Dec 21 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/63.0.3239.108 Safari/537.36

Steps to reproduce the problem:
1. Open a WebGL demo, e.g. http://madebyevan.com/webgl-water/
2. Open the performance profiler and start a record for a few seconds

What is the expected behavior?
Frame by frame execution times with precision down to a 100th millisecond.

What went wrong?
- Execution timings with only millisecond precision. 
- Many execution paths that were captured before aren't captured anymore. The profiler misses many things.
- Some functions are reported to take 1 or 2ms but I'm under the impression that this may be off by at least 50%, as if timings are simply rounded.

Did this work before? Yes unkown

Chrome version: 63.0.3239.108  Channel: stable
OS Version: 10.0
Flash Version: 

I'm experiencing this on a new PC with this setup:

OS: Windows 10
CPU: AMD Ryzen 1600
Browser: Version 63.0.3239.108

Until recently it worked with another System with windows 10, I can check it's chrome version as soon as I have access to it again.
 
chrome_performance_profiler.jpg
41.2 KB View Download
Related to https://bugs.chromium.org/p/chromium/issues/detail?id=158234
I created a new topic because the old one was discussed and flagged as fixed a while ago.
Labels: Needs-Bisect Needs-Triage-M63
Cc: krajshree@chromium.org
Labels: Triaged-ET Needs-Feedback
Tried testing the issue on Win-10 using chrome reported version #63.0.3239.108 and latest canary #65.0.3300.0.

Attached a screen cast for reference.

Following are the steps followed to reproduce the issue.
------------
1. Open a WebGL demo, e.g. http://madebyevan.com/webgl-water/
2. Open the performance profiler and start a record for a few seconds
3. Observed that Animation frame fired took more than 10 millisecond.

gebackene.ente@ - Could you please check the screen cast and please let us know if anything missed from our side. This will help us in further triaging of the issue.
If possible please provide a screen cast for better understanding of issue.

Thanks...!!
Attaching screen cast
796941.mp4
5.7 MB View Download

Comment 5 by woxxom@gmail.com, Dec 22 2017

Reporter, make sure "High resolution CPU profiling" is enabled in devtools options.
By default 1ms precision is used, while this option enables 0.1ms precision [1].

You can also try enabling an experimental tracing-based profiling:
1. open and enable chrome://flags/#enable-devtools-experiments
2. restart the browser and open devtools options
3. click "Experiments"
4. press "Shift" key 6 times (ignore and close any OS dialogs)
5. enable "Timeline: tracing based JS profiler"

  [1]: https://cs.chromium.org/chromium/src/third_party/WebKit/Source/devtools/front_end/timeline/TimelineController.js?l=174&rcl=2ff0a9383fb2be7c694408a6e30cf5b3aade8292

krajshree: Your screencast looks exactly like how I'm doing it.

I've attached a screencast from my own results, including the results of performance.now()

woxxom: "High resolution CPU profiling" is enabled. Same results with "Timeline: tracing based JS profiler" enabled.
WebGL Water - Google Chrome 22_12_2017 10_12_38.mp4
19.8 MB Download
Project Member

Comment 7 by sheriffbot@chromium.org, Dec 22 2017

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding requester "krajshree@chromium.org" to the cc list and removing "Needs-Feedback" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
chrome_version.jpg
246 KB View Download
I just checked it on my office PC where everything works as expected. 
Same OS (Windows 10), same Browser version (63.0.3239.108), just a different CPU (Intel i7-3770K). Performance profiler and performance.now() have sub-ms resolution on this system.

So it's only my work@home that suffers from ms resolution. 
Labels: -Needs-Bisect
Unable to reproduce the issue on Win-10 using chrome reported version #63.0.3239.108 and latest canary #65.0.3303.0.

Attached a screen shot for reference.

Could anyone from Platform>DevTools team please have a look into the issue as it is not reproducible from TE-end. Hence, removing the Needs-Bisect label. Please feel free to add the same if required.

Thanks...!!
796941.jpg
291 KB View Download

Comment 11 by caseq@chromium.org, Dec 28 2017

Components: -Platform>DevTools Platform>DevTools>Performance
Owner: alph@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 12 by w.fi...@gmail.com, Feb 21 2018

I have the same issue on the virtual machine with low performance.

Chrome version: 66.0.3347.0 , dev (puppeteer)
OS: Windows 10.0 (virtualized)
CPU: Intel Xeon E5-2690

Turning on the "Timeline: tracing based JS profiler" option has no effect. By the way, the "Idle" timing in the profiler is rounded to 0.1 ms.

Is there any way to workaround the rounding of performance.now() at least up to 0.1 ms? (flag, other method, etc.)
performance_now.png
89.1 KB View Download
profiler.png
183 KB View Download

Comment 13 by alph@chromium.org, Feb 21 2018

Labels: Needs-Feedback
It looks like you don't have "High resolution profiling" option turned on. Can you please confirm?

Please do no use tracing based JS profiler experiment. It'll likely break things.

Comment 14 by w.fi...@gmail.com, Feb 22 2018

"High resolution profiling" option is turned on.

Comment 15 by w.fi...@gmail.com, Feb 22 2018

I deployed the image of this OS (Hyper-V) on the local machine, where Chromium works correctly. There is the same problem - the timings are rounded to 1ms.
Update from my side: 
I'm also still experiencing this issue on chrome 64.0.3282.167, as well as canary 66.0.3352.0.
Status: Closed (was: Assigned)
Works just fine as of M-71. If the resolution is 1ms then the "High res profiling" option is likely turned off in the DevTools settings.

Closing it as not reproducible.
I have 0.1ms precision for performance.now() in chrome 71 now, which is better. The "High res profiling" option still doesn't change anything though.  

Sign in to add a comment