/
githubmirror
/
node
Обзор
Документация
Войти
/
githubmirror
/
node
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
benchmark/napi/property_keys/index.js
15 строк
364 B
Chengzhong Wu
node-api: add property keys benchmark
29 июл 2024, 14:19
Не верифицирован
29 июл 2024, 14:19
05a9413
Код
Авторство
О чём код?
'use strict'; const common = require('../../common.js'); const binding = require(`./build/${common.buildType}/binding`); const bench = common.createBenchmark(main, { n: [5e6], implem: ['RunPropertyKey', 'RunNormalString'], }); function main({ n, implem }) { const objs = Array(n).fill(null).map((item) => new Object()); binding[implem](bench, objs); }