Skip to content

Commit de2d7c6

Browse files
committed
benchmark: reduce config for fs benchmarks
Remove redundant configuration values from four fs benchmark files to reduce total benchmark suite runtime without losing code path coverage. Refs: nodejs/performance#186
1 parent 78e56fa commit de2d7c6

4 files changed

Lines changed: 3 additions & 5 deletions

File tree

benchmark/fs/read-stream-throughput.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ const filename = tmpdir.resolve(`.removeme-benchmark-garbage-${process.pid}`);
1212
const bench = common.createBenchmark(main, {
1313
encodingType: ['buf', 'asc', 'utf'],
1414
filesize: [1000 * 1024],
15-
highWaterMark: [1024, 4096, 65535, 1024 * 1024],
15+
highWaterMark: [1024, 65535, 1024 * 1024],
1616
n: 1024,
1717
});
1818

benchmark/fs/readfile-promises.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@ const bench = common.createBenchmark(main, {
1717
1024,
1818
512 * 1024,
1919
4 * 1024 ** 2,
20-
8 * 1024 ** 2,
21-
16 * 1024 ** 2,
2220
32 * 1024 ** 2,
2321
],
2422
concurrent: [1, 10],

benchmark/fs/write-stream-throughput.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const filename = tmpdir.resolve(`.removeme-benchmark-garbage-${process.pid}`);
1111
const bench = common.createBenchmark(main, {
1212
dur: [5],
1313
encodingType: ['buf', 'asc', 'utf'],
14-
size: [2, 1024, 65535, 1024 * 1024],
14+
size: [1024, 65535, 1024 * 1024],
1515
});
1616

1717
function main({ dur, encodingType, size }) {

benchmark/fs/writefile-promises.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ let filesWritten = 0;
1313
const bench = common.createBenchmark(main, {
1414
duration: [5],
1515
encodingType: ['buf', 'asc', 'utf'],
16-
size: [2, 1024, 65535, 1024 * 1024],
16+
size: [1024, 65535, 1024 * 1024],
1717
concurrent: [1, 10],
1818
});
1919

0 commit comments

Comments
 (0)