ruhleder ruhleder - 7 months ago 47
Javascript Question

Calculate total time based on a .cpuprofile file

I created a JavaScript CPU profile with Chrome and saved it as a

file. Using only this file, I want to calculate the "Total Time" for each node in this profile (as can be seen in the Chrome Profiler when you load the file.)

I found out how to calculate the "Self Time" here. Does anyone know how to extend it to the "Total Time"?


I have found a solution to this problem:

I was looking for the Bottom Up Profile times. For anyone interested, I have created a npm package called cpuprofile that calculates all necessary times.