mirror of
https://github.com/nodejs/node.git
synced 2024-11-30 15:30:56 +01:00
19 lines
257 B
JavaScript
19 lines
257 B
JavaScript
|
'use strict';
|
||
|
|
||
|
const common = require('../common');
|
||
|
|
||
|
const bench = common.createBenchmark(main, {
|
||
|
n: [1e6]
|
||
|
});
|
||
|
|
||
|
|
||
|
function main(conf) {
|
||
|
const n = conf.n >>> 0;
|
||
|
|
||
|
bench.start();
|
||
|
for (var i = 0; i < n; i++) {
|
||
|
process.hrtime();
|
||
|
}
|
||
|
bench.end(n);
|
||
|
}
|