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

Method postProcess

deps/v8/tools/parse-processor.mjs:837–873  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

835 }
836
837 postProcess() {
838 this.scripts = Array.from(this.idToScript.values())
839 .filter(each => !each.isNative);
840
841 if (this.scripts.length == 0) {
842 console.error("Could not find any scripts!");
843 return false;
844 }
845
846 this.scripts.forEach(script => {
847 script.finalize();
848 script.calculateMetrics(false);
849 });
850
851 this.scripts.forEach(script => this.totalScript.addAllFunktions(script));
852 this.totalScript.calculateMetrics(true);
853
854 this.firstEventTimestamp = this.totalScript.timestampMin(
855 this.scripts.map(each => each.firstEventTimestamp));
856 this.lastParseEventTimestamp = this.totalScript.timestampMax(
857 this.scripts.map(each => each.lastParseEventTimestamp));
858 this.lastEventTimestamp = this.totalScript.timestampMax(
859 this.scripts.map(each => each.lastEventTimestamp));
860
861 const series = {
862 firstParseEvent: 'Any Parse Event',
863 parse: 'Parsing',
864 preparse: 'Preparsing',
865 resolution: 'Preparsing with Var. Resolution',
866 lazyCompile: 'Lazy Compilation',
867 compile: 'Eager Compilation',
868 execution: 'First Execution',
869 };
870 let metrics = Object.keys(series);
871 this.totalScript.getAccumulatedTimeMetrics(
872 metrics, 0, this.lastEventTimestamp, 10);
873 }
874
875 processFunctionEvent(
876 eventName, scriptId, startPosition, endPosition, duration, timestamp,

Callers 2

processStringMethod · 0.95
processLogFileMethod · 0.95

Calls 13

calculateMetricsMethod · 0.80
addAllFunktionsMethod · 0.80
timestampMinMethod · 0.80
timestampMaxMethod · 0.80
filterMethod · 0.65
forEachMethod · 0.65
mapMethod · 0.65
keysMethod · 0.65
fromMethod · 0.45
valuesMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected