mbalabash / estimo

Evaluates how long a browser will execute your javascript code

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use RTI instead of real time

ai opened this issue · comments

There is a great idea to not track time, but track a CU ticks during JS execution

https://docs.google.com/presentation/d/1DutTpZ8p8K6JytEvNK1bJuvEIU3uMdhswwuZawdpuH0/edit#slide=id.g56184bbff6_0_93

Time is an unstable value, but CPU ticks will be always the same. Then we will multiple ticks with some factor to get the real time. It will make the time stable and usable as a limit. I will be an awesome feature.

According @aslushnikov idea https://twitter.com/aslushnikov/status/1121816765518897152?s=19

Related to #4

@aslushnikov I can’t find in Tracium doc a way to get RTI. Can you help me?

@ai upstream changes to Chromium aren't landed yet - are you building Chromium on your own?

@aslushnikov got it 😩. Any ETA when it will be in upstream? Or it is just an experimental branch?

Any ETA when it will be in upstream?

@ai no ETA unfortunately

Or it is just an experimental branch?

No, it's not experimental. This patch is already LGTM'ed by one of the Chromium OWNERs, one more review is pending. Once all approves are cleared and comments are addressed, it'll land to the Chromium master branch.

Will wait 😴

New version of Estimo uses Tracium.
So, i hope we can add RTI as quickly as it support will be added in Tracium.

According to puppeteer/puppeteer#4591 Puppeteer can capture RTI by chrome traces on Linux platform.

Linux platform is enough. I will print a warning for non-Linux platform that data is not stable but will be stable on CI (we just need to be sure about the same numbers in both methods).

@aslushnikov in what stable version of Chrome we will have this feature? With Puppeter Core we now use Chrome on desktop machines.

in what stable version of Chrome we will have this feature?

@ai the patch was landed in Chromium 77, which is scheduled to hit stable on Sep 10, 2019.

I prepared a puppeteer script according to puppeteer/puppeteer#4591 (comment).
But tidelta and ticount don't exist in trace file.

Here the issue.

If you are using Linux distro check this out to help me with testing this issue.