Fix fastest test lookup

This commit is contained in:
kpdecker
2013-08-24 16:03:28 -05:00
parent b700d91a70
commit 94ba2b95d0
+1 -19
View File
@@ -12,25 +12,7 @@ var print = require("sys").print;
BenchWarmer.prototype = {
winners: function(benches) {
var result = Benchmark.filter(benches, function(bench) { return bench.cycles; });
if (result.length > 1) {
result.sort(function(a, b) { return b.compare(a); });
first = result[0];
last = result[result.length - 1];
var winners = [];
Benchmark.each(result, function(bench) {
if (bench.compare(first) === 0) {
winners.push(bench);
}
});
return winners;
} else {
return result;
}
return Benchmark.filter(benches, 'fastest');
},
suite: function(suite, fn) {
this.suiteName = suite;