Commit df79b207 authored by rniwa@webkit.org's avatar rniwa@webkit.org
Browse files

Build fix after r130135. Dromaeo tests only report single memory value,

and computeStatistics should report variance as 0 in such cases.

* resources/runner.js:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@130181 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent d45202aa
2012-10-02 Ryosuke Niwa <rniwa@webkit.org>
Build fix after r130135. Dromaeo tests only report single memory value,
and computeStatistics should report variance as 0 in such cases.
* resources/runner.js:
2012-10-02 Philip Rogers <pdr@google.com>
Fix PerfTest standard deviation calculation.
......
......@@ -80,7 +80,7 @@ if (window.testRunner) {
result.mean += delta / sweep;
squareSum += delta * (x - result.mean);
}
result.variance = squareSum / (data.length - 1);
result.variance = data.length <= 1 ? 0 : squareSum / (data.length - 1);
result.stdev = Math.sqrt(result.variance);
result.unit = unit || "ms";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment