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

Function main

benchmark/crypto/webcrypto-hmac.js:62–80  ·  view source on GitHub ↗
({ n, mode, keyReuse, hash, keylen, len })

Source from the content-addressed store, hash-verified

60}
61
62async function main({ n, mode, keyReuse, hash, keylen, len }) {
63 if (!keys || keys.length !== n ||
64 currentHash !== hash || currentKeyLength !== keylen) {
65 await createSigningKeys(n, hash, keylen);
66 }
67
68 const data = new Uint8Array(len);
69 data.fill(0x62);
70 const sharedKey = keyReuse === 'shared' ? keys[0] : undefined;
71
72 switch (mode) {
73 case 'serial':
74 await measureSerial(n, sharedKey, data);
75 break;
76 case 'parallel':
77 await measureParallel(n, sharedKey, data);
78 break;
79 }
80}

Callers

nothing calls this directly

Calls 4

createSigningKeysFunction · 0.85
fillMethod · 0.80
measureSerialFunction · 0.70
measureParallelFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…