Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(533)

Unified Diff: benchmarks/spinning-balls/v.js

Issue 8430006: Convert array index to integer when computing pause distribution for spinning-balls. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: benchmarks/spinning-balls/v.js
diff --git a/benchmarks/spinning-balls/v.js b/benchmarks/spinning-balls/v.js
index bd009738872740a9a1de2fe02949439479d1749a..d8a5e2a156e58e99ceb48adebdda5e51caf1aa96 100644
--- a/benchmarks/spinning-balls/v.js
+++ b/benchmarks/spinning-balls/v.js
@@ -353,8 +353,8 @@ function updateStats(pause) {
if (pause > 20) {
sumOfSquaredPauses += (pause - 20) * (pause - 20);
}
- pauseDistribution[pause / 10] |= 0;
- pauseDistribution[pause / 10]++;
+ pauseDistribution[Math.floor(pause / 10)] |= 0;
+ pauseDistribution[Math.floor(pause / 10)]++;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698