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

Side by Side Diff: chrome/browser/performance_monitor/metric_details.cc

Issue 10834015: Add Startup Timing to CPM (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Windows fix Created 8 years, 4 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 unified diff | Download patch
OLDNEW
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 "chrome/browser/performance_monitor/metric_details.h" 5 #include "chrome/browser/performance_monitor/metric_details.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/performance_monitor/constants.h" 8 #include "chrome/browser/performance_monitor/constants.h"
9 9
10 namespace performance_monitor { 10 namespace performance_monitor {
(...skipping 13 matching lines...) Expand all
24 kMetricPrivateMemoryUsageDescription, 24 kMetricPrivateMemoryUsageDescription,
25 kMetricPrivateMemoryUsageUnits, 25 kMetricPrivateMemoryUsageUnits,
26 kMetricPrivateMemoryUsageTickSize 26 kMetricPrivateMemoryUsageTickSize
27 }, 27 },
28 { 28 {
29 kMetricSharedMemoryUsageName, 29 kMetricSharedMemoryUsageName,
30 kMetricSharedMemoryUsageDescription, 30 kMetricSharedMemoryUsageDescription,
31 kMetricSharedMemoryUsageUnits, 31 kMetricSharedMemoryUsageUnits,
32 kMetricSharedMemoryUsageTickSize 32 kMetricSharedMemoryUsageTickSize
33 }, 33 },
34 {
35 kMetricStartupTimeName,
36 kMetricStartupTimeDescription,
37 kMetricStartupTimeUnits,
38 kMetricStartupTimeTickSize
39 },
Nico 2012/08/10 01:27:58 This adds a static initializer to chrome. Because
40 {
41 kMetricTestStartupTimeName,
42 kMetricTestStartupTimeDescription,
43 kMetricTestStartupTimeUnits,
44 kMetricTestStartupTimeTickSize
45 },
46 {
47 kMetricSessionRestoreTimeName,
48 kMetricSessionRestoreTimeDescription,
49 kMetricSessionRestoreTimeUnits,
50 kMetricSessionRestoreTimeTickSize
51 }
34 }; 52 };
35 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(kMetricDetailsList) == METRIC_NUMBER_OF_METRICS, 53 COMPILE_ASSERT(ARRAYSIZE_UNSAFE(kMetricDetailsList) == METRIC_NUMBER_OF_METRICS,
36 metric_names_incorrect_size); 54 metric_names_incorrect_size);
37 55
38 } // namespace 56 } // namespace
39 57
40 const MetricDetails* GetMetricDetails(MetricType metric_type) { 58 const MetricDetails* GetMetricDetails(MetricType metric_type) {
41 DCHECK_GT(METRIC_NUMBER_OF_METRICS, metric_type); 59 DCHECK_GT(METRIC_NUMBER_OF_METRICS, metric_type);
42 return &kMetricDetailsList[metric_type]; 60 return &kMetricDetailsList[metric_type];
43 } 61 }
44 62
45 } // namespace performance_monitor 63 } // namespace performance_monitor
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698