Skip to content

Commit 00f7a5d

Browse files
Lei ShiUlisesGascon
Lei Shi
authored andcommitted
benchmark: increase the iteration number to an appropriate value
Current iteration number is too small that fwrite occupies large portion of execution time which made crypo execution time measured inaccurate. The iteration above 1e5 makes 50% higher and stable score. PR-URL: #50766 Reviewed-By: Debadree Chatterjee <debadree333@gmail.com> Reviewed-By: Filip Skokan <panva.ip@gmail.com> Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br>
1 parent 6584dd8 commit 00f7a5d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

benchmark/crypto/webcrypto-digest.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const bench = common.createBenchmark(main, {
88
sync: ['createHash', 'subtle'],
99
data: [10, 20, 50, 100],
1010
method: ['SHA-1', 'SHA-256', 'SHA-384', 'SHA-512'],
11-
n: [1e3],
11+
n: [1e5],
1212
});
1313

1414
const kMethods = {

0 commit comments

Comments
 (0)