Skip to content

Commit dfb5f30

Browse files
bzozjasnell
authored andcommitted
benchmark: make v8-bench.js output consistent
This changes the way v8-bench.js reports its performance to be consistent with other benchmarks. Reviewed-By: James M Snell <[email protected]> Reviewed-By: Andreas Madsen <[email protected]> PR-URL: #8564
1 parent 84481f9 commit dfb5f30

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

benchmark/misc/v8-bench.js

+9-4
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ load('regexp.js');
2323
load('splay.js');
2424
load('navier-stokes.js');
2525

26+
const benchmark_name = path.join('misc', 'v8-bench.js');
2627
const times = {};
2728
global.BenchmarkSuite.RunSuites({
2829
NotifyStart: function(name) {
@@ -31,8 +32,10 @@ global.BenchmarkSuite.RunSuites({
3132
NotifyResult: function(name, result) {
3233
const elapsed = process.hrtime(times[name]);
3334
common.sendResult({
34-
name: name,
35-
conf: {},
35+
name: benchmark_name,
36+
conf: {
37+
benchmark: name
38+
},
3639
rate: result,
3740
time: elapsed[0] + elapsed[1] / 1e9
3841
});
@@ -42,8 +45,10 @@ global.BenchmarkSuite.RunSuites({
4245
},
4346
NotifyScore: function(score) {
4447
common.sendResult({
45-
name: 'Score (version ' + global.BenchmarkSuite.version + ')',
46-
conf: {},
48+
name: benchmark_name,
49+
conf: {
50+
benchmark: 'Score (version ' + global.BenchmarkSuite.version + ')'
51+
},
4752
rate: score,
4853
time: 0
4954
});

0 commit comments

Comments
 (0)