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

Method printHeavyProfile

deps/v8/tools/tickprocessor.mjs:1062–1078  ·  view source on GitHub ↗
(profile, opt_indent)

Source from the content-addressed store, hash-verified

1060 }
1061
1062 printHeavyProfile(profile, opt_indent) {
1063 const indent = opt_indent || 0;
1064 const indentStr = ''.padStart(indent);
1065 this.processProfile(profile, () => true, (rec) => {
1066 // Cut off too infrequent callers.
1067 if (rec.parentTotalPercent < TickProcessor.CALL_PROFILE_CUTOFF_PCT) return;
1068 const funcName = this.formatFunctionName(rec.internalFuncName);
1069 print(`${` ${rec.totalTime.toString().padStart(5)} ` +
1070 rec.parentTotalPercent.toFixed(1).toString().padStart(5)}% ${indentStr}${funcName}`);
1071 // Limit backtrace depth.
1072 if (indent < 2 * this.callGraphSize_) {
1073 this.printHeavyProfile(rec.children, indent + 2);
1074 }
1075 // Delimit top-level functions.
1076 if (indent == 0) print('');
1077 });
1078 }
1079}

Callers 2

processHeapSampleEndMethod · 0.95
printStatisticsMethod · 0.95

Calls 4

processProfileMethod · 0.95
formatFunctionNameMethod · 0.95
printFunction · 0.70
toStringMethod · 0.45

Tested by

no test coverage detected