From 3c6f29b785d178069987a6d36d934228dc13b64e Mon Sep 17 00:00:00 2001 From: Lei Shi Date: Mon, 27 Nov 2023 16:17:41 +0800 Subject: [PATCH] benchmark: update iterations in benchmark/perf_hooks Fixes: https://github.com/nodejs/node/issues/50571 --- benchmark/perf_hooks/performance-observer.js | 2 +- benchmark/perf_hooks/resourcetiming.js | 2 +- benchmark/perf_hooks/timerfied.js | 2 +- benchmark/perf_hooks/usertiming.js | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/benchmark/perf_hooks/performance-observer.js b/benchmark/perf_hooks/performance-observer.js index 42a94932860c38..d943c4547e0431 100644 --- a/benchmark/perf_hooks/performance-observer.js +++ b/benchmark/perf_hooks/performance-observer.js @@ -13,7 +13,7 @@ function randomFn() { } const bench = common.createBenchmark(main, { - n: [1e5], + n: [1e6], pending: [1, 10], }, { options: ['--expose-internals'], diff --git a/benchmark/perf_hooks/resourcetiming.js b/benchmark/perf_hooks/resourcetiming.js index 51c4778d20065f..69ee06c92cbd9f 100644 --- a/benchmark/perf_hooks/resourcetiming.js +++ b/benchmark/perf_hooks/resourcetiming.js @@ -50,7 +50,7 @@ function createTimingInfo({ } const bench = common.createBenchmark(main, { - n: [1e5], + n: [1e6], observe: ['resource'], }); diff --git a/benchmark/perf_hooks/timerfied.js b/benchmark/perf_hooks/timerfied.js index 50be0a47fc1b5a..f1cc62637187dd 100644 --- a/benchmark/perf_hooks/timerfied.js +++ b/benchmark/perf_hooks/timerfied.js @@ -13,7 +13,7 @@ function randomFn() { } const bench = common.createBenchmark(main, { - n: [1e5], + n: [1e6], observe: ['function'], }); diff --git a/benchmark/perf_hooks/usertiming.js b/benchmark/perf_hooks/usertiming.js index 24a53a116785df..92017861d58c4a 100644 --- a/benchmark/perf_hooks/usertiming.js +++ b/benchmark/perf_hooks/usertiming.js @@ -8,7 +8,7 @@ const { } = require('perf_hooks'); const bench = common.createBenchmark(main, { - n: [1e5], + n: [1e6], observe: ['all', 'measure'], });