From 82b1660b1d7921a9b7d55156bd67f17da34eb106 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Mon, 16 Oct 2017 10:43:40 -0700 Subject: [PATCH] benchmark: improve http2 benchmark configs PR-URL: https://github.com/nodejs/node/pull/16239 Reviewed-By: Matteo Collina Reviewed-By: Anatoli Papirovski Reviewed-By: Anna Henningsen --- benchmark/http2/headers.js | 3 ++- benchmark/http2/respond-with-fd.js | 5 +++-- benchmark/http2/simple.js | 5 +++-- benchmark/http2/write.js | 5 +++-- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/benchmark/http2/headers.js b/benchmark/http2/headers.js index f6b29347cdb..62156774caa 100644 --- a/benchmark/http2/headers.js +++ b/benchmark/http2/headers.js @@ -6,7 +6,8 @@ const PORT = common.PORT; const bench = common.createBenchmark(main, { n: [1e3], nheaders: [0, 10, 100, 1000], -}, { flags: ['--no-warnings'] }); + benchmarker: ['h2load'] +}, { flags: ['--no-warnings', '--expose-http2'] }); function main(conf) { const n = +conf.n; diff --git a/benchmark/http2/respond-with-fd.js b/benchmark/http2/respond-with-fd.js index a235bd87d51..791e5f3d1e7 100644 --- a/benchmark/http2/respond-with-fd.js +++ b/benchmark/http2/respond-with-fd.js @@ -10,8 +10,9 @@ const file = path.join(path.resolve(__dirname, '../fixtures'), 'alice.html'); const bench = common.createBenchmark(main, { requests: [100, 1000, 10000, 100000, 1000000], streams: [100, 200, 1000], - clients: [1, 2] -}, { flags: ['--no-warnings'] }); + clients: [1, 2], + benchmarker: ['h2load'] +}, { flags: ['--no-warnings', '--expose-http2'] }); function main(conf) { diff --git a/benchmark/http2/simple.js b/benchmark/http2/simple.js index 8d7767197bc..e8cb3ddee2d 100644 --- a/benchmark/http2/simple.js +++ b/benchmark/http2/simple.js @@ -11,8 +11,9 @@ const file = path.join(path.resolve(__dirname, '../fixtures'), 'alice.html'); const bench = common.createBenchmark(main, { requests: [100, 1000, 10000, 100000], streams: [100, 200, 1000], - clients: [1, 2] -}, { flags: ['--no-warnings'] }); + clients: [1, 2], + benchmarker: ['h2load'] +}, { flags: ['--no-warnings', '--expose-http2'] }); function main(conf) { const n = +conf.requests; diff --git a/benchmark/http2/write.js b/benchmark/http2/write.js index e4f64cc05de..91b9c8f0c5c 100644 --- a/benchmark/http2/write.js +++ b/benchmark/http2/write.js @@ -6,8 +6,9 @@ const PORT = common.PORT; const bench = common.createBenchmark(main, { streams: [100, 200, 1000], length: [64 * 1024, 128 * 1024, 256 * 1024, 1024 * 1024], - size: [100000] -}, { flags: ['--no-warnings'] }); + size: [100000], + benchmarker: ['h2load'] +}, { flags: ['--no-warnings', '--expose-http2'] }); function main(conf) { const m = +conf.streams;