| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "base/logging.h" | 5 #include "base/logging.h" |
| 6 #include "base/memory/ptr_util.h" | 6 #include "base/memory/ptr_util.h" |
| 7 #import "ios/chrome/browser/web/chrome_web_client.h" | 7 #import "ios/chrome/browser/web/chrome_web_client.h" |
| 8 #include "ios/chrome/test/base/perf_test_ios.h" | 8 #import "ios/chrome/test/base/perf_test_ios.h" |
| 9 | 9 |
| 10 PerfTest::PerfTest(std::string testGroup) | 10 PerfTest::PerfTest(std::string testGroup) |
| 11 : BlockCleanupTest(), | 11 : BlockCleanupTest(), |
| 12 testGroup_(testGroup), | 12 testGroup_(testGroup), |
| 13 firstLabel_("1st"), | 13 firstLabel_("1st"), |
| 14 averageLabel_("2nd+"), | 14 averageLabel_("2nd+"), |
| 15 isWaterfall_(false), | 15 isWaterfall_(false), |
| 16 verbose_(true), | 16 verbose_(true), |
| 17 repeatCount_(10), | 17 repeatCount_(10), |
| 18 web_client_(base::MakeUnique<ChromeWebClient>()) {} | 18 web_client_(base::MakeUnique<ChromeWebClient>()) {} |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 max = times[i]; | 103 max = times[i]; |
| 104 if (times[i] < min) | 104 if (times[i] < min) |
| 105 min = times[i]; | 105 min = times[i]; |
| 106 } | 106 } |
| 107 if (max_time) | 107 if (max_time) |
| 108 *max_time = max; | 108 *max_time = max; |
| 109 if (min_time) | 109 if (min_time) |
| 110 *min_time = min; | 110 *min_time = min; |
| 111 return sum / count; | 111 return sum / count; |
| 112 } | 112 } |
| OLD | NEW |