Function
streamWrite
(algo, message, encoding, n, len)
Source from the content-addressed store, hash-verified
| 58 | } |
| 59 | |
| 60 | function streamWrite(algo, message, encoding, n, len) { |
| 61 | const written = n * len; |
| 62 | const bits = written * 8; |
| 63 | const gbits = bits / (1024 * 1024 * 1024); |
| 64 | const h = crypto.createHash(algo); |
| 65 | |
| 66 | while (n-- > 0) |
| 67 | h.write(message, encoding); |
| 68 | |
| 69 | h.end(); |
| 70 | h.read(); |
| 71 | |
| 72 | bench.end(gbits); |
| 73 | } |
Callers
nothing calls this directly
Tested by
no test coverage detected
Used in the wild real call sites across dependent graphs
searching dependent graphs…