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

Function breadth

benchmark/timers/immediate.js:61–72  ·  view source on GitHub ↗
(N)

Source from the content-addressed store, hash-verified

59
60// Concurrent setImmediate, 0 arguments
61function breadth(N) {
62 let n = 0;
63 bench.start();
64 function cb() {
65 n++;
66 if (n === N)
67 bench.end(N);
68 }
69 for (let i = 0; i < N; i++) {
70 setImmediate(cb);
71 }
72}
73
74// Concurrent setImmediate, 1 argument
75function breadth1(N) {

Callers 2

mainFunction · 0.85
execMethod · 0.85

Calls 2

setImmediateFunction · 0.50
startMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…