MCPcopy Index your code
hub / github.com/nodejs/node / generateTree

Function generateTree

deps/v8/tools/profview/profile-utils.js:508–524  ·  view source on GitHub ↗
(
    file, startTime, endTime, tree)

Source from the content-addressed store, hash-verified

506// {startTime}, {endTime} is the interval.
507// {tree} is the processor of stacks.
508function generateTree(
509 file, startTime, endTime, tree) {
510 let ticks = file.ticks;
511 let i = 0;
512 while (i < ticks.length && ticks[i].tm < startTime) {
513 i++;
514 }
515
516 let tickCount = 0;
517 while (i < ticks.length && ticks[i].tm < endTime) {
518 tree.addStack(file, i);
519 i++;
520 tickCount++;
521 }
522
523 return tickCount;
524}
525
526function computeOptimizationStats(file,
527 timeStart = -Infinity, timeEnd = Infinity) {

Callers 2

renderMethod · 0.85
renderMethod · 0.85

Calls 1

addStackMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…