blob: 9e70684023767b4915e7de1a03e02f832c5d9837 [file] [log] [blame]
Yiwei Zhang0102ad22018-05-02 17:37:17 -07001/*
2 * Copyright 2018 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#pragma once
18
Alec Mouri9a29e672020-09-14 12:39:14 -070019#include <cstdint>
Peiyong Lin65248e02020-04-18 21:15:07 -070020
Alec Mouri7d436ec2021-01-27 20:40:50 -080021#include <../Fps.h>
Adithya Srinivasanf427f762021-06-15 19:46:26 +000022#include <android/hardware/graphics/composer/2.4/IComposerClient.h>
Alec Mouri7d436ec2021-01-27 20:40:50 -080023#include <gui/JankInfo.h>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070024#include <timestatsproto/TimeStatsHelper.h>
25#include <timestatsproto/TimeStatsProtoHeader.h>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070026#include <ui/FenceTime.h>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070027#include <utils/String16.h>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070028#include <utils/Vector.h>
29
Yiwei Zhangc5f2c452018-05-08 16:31:56 -070030#include <deque>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070031#include <mutex>
Yiwei Zhang8a4015c2018-05-08 16:03:47 -070032#include <optional>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070033#include <unordered_map>
Alec Mourie4034bb2019-11-19 12:45:54 -080034#include <variant>
Yiwei Zhang0102ad22018-05-02 17:37:17 -070035
36using namespace android::surfaceflinger;
37
38namespace android {
Yiwei Zhang0102ad22018-05-02 17:37:17 -070039
40class TimeStats {
Alec Mourifb571ea2019-01-24 18:42:10 -080041public:
Ady Abraham8b9e6122021-01-26 19:11:45 -080042 using SetFrameRateVote = TimeStatsHelper::SetFrameRateVote;
43
Alec Mourifb571ea2019-01-24 18:42:10 -080044 virtual ~TimeStats() = default;
45
Tej Singhe2751772021-04-06 22:05:29 -070046 // Process a pull request from statsd.
47 virtual bool onPullAtom(const int atomId, std::string* pulledData);
Alec Mouri8e2f31b2020-01-16 22:04:35 +000048
Alec Mourifb571ea2019-01-24 18:42:10 -080049 virtual void parseArgs(bool asProto, const Vector<String16>& args, std::string& result) = 0;
50 virtual bool isEnabled() = 0;
Oliver Nguyenf3b7c9c2019-05-07 13:28:07 -070051 virtual std::string miniDump() = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -080052
53 virtual void incrementTotalFrames() = 0;
54 virtual void incrementMissedFrames() = 0;
55 virtual void incrementClientCompositionFrames() = 0;
Vishnu Nair9b079a22020-01-21 14:36:08 -080056 virtual void incrementClientCompositionReusedFrames() = 0;
Alec Mouri8de697e2020-03-19 10:52:01 -070057 // Increments the number of times the display refresh rate changed.
58 virtual void incrementRefreshRateSwitches() = 0;
Alec Mouri8f7a0102020-04-15 12:11:10 -070059 // Increments the number of changes in composition strategy
60 // The intention is to reflect the number of changes between hwc and gpu
61 // composition, where "gpu composition" may also include mixed composition.
62 virtual void incrementCompositionStrategyChanges() = 0;
Alec Mouri717bcb62020-02-10 17:07:19 -080063 // Records the most up-to-date count of display event connections.
64 // The stored count will be the maximum ever recoded.
65 virtual void recordDisplayEventConnectionCount(int32_t count) = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -080066
Alec Mouri9519bf12019-11-15 16:54:44 -080067 // Records the start and end times for a frame.
68 // The start time is the same as the beginning of a SurfaceFlinger
69 // invalidate message.
70 // The end time corresponds to when SurfaceFlinger finishes submitting the
71 // request to HWC to present a frame.
72 virtual void recordFrameDuration(nsecs_t startTime, nsecs_t endTime) = 0;
Alec Mourie4034bb2019-11-19 12:45:54 -080073 // Records the start time and end times for when RenderEngine begins work.
74 // The start time corresponds to the beginning of RenderEngine::drawLayers.
75 // The end time corresponds to when RenderEngine finishes rendering.
76 virtual void recordRenderEngineDuration(nsecs_t startTime, nsecs_t endTime) = 0;
77 // Same as above, but passes in a fence representing the end time.
78 virtual void recordRenderEngineDuration(nsecs_t startTime,
79 const std::shared_ptr<FenceTime>& readyFence) = 0;
Alec Mouri9519bf12019-11-15 16:54:44 -080080
Yiwei Zhang1a88c402019-11-18 10:43:58 -080081 virtual void setPostTime(int32_t layerId, uint64_t frameNumber, const std::string& layerName,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +000082 uid_t uid, nsecs_t postTime, int32_t gameMode) = 0;
Yiwei Zhang1a88c402019-11-18 10:43:58 -080083 virtual void setLatchTime(int32_t layerId, uint64_t frameNumber, nsecs_t latchTime) = 0;
Alec Mouri91f6df32020-01-30 08:48:58 -080084 // Reasons why latching a particular buffer may be skipped
85 enum class LatchSkipReason {
86 // If the acquire fence did not fire on some devices we skip latching
87 // the buffer until the fence fires.
88 LateAcquire,
89 };
90 // Increments the counter of skipped latch buffers.
91 virtual void incrementLatchSkipped(int32_t layerId, LatchSkipReason reason) = 0;
92 // Increments the counter of bad desired present times for this layer.
93 // Bad desired present times are "implausible" and cause SurfaceFlinger to
94 // latch a buffer immediately to avoid stalling.
95 virtual void incrementBadDesiredPresent(int32_t layerId) = 0;
Yiwei Zhang1a88c402019-11-18 10:43:58 -080096 virtual void setDesiredTime(int32_t layerId, uint64_t frameNumber, nsecs_t desiredTime) = 0;
97 virtual void setAcquireTime(int32_t layerId, uint64_t frameNumber, nsecs_t acquireTime) = 0;
98 virtual void setAcquireFence(int32_t layerId, uint64_t frameNumber,
Alec Mourifb571ea2019-01-24 18:42:10 -080099 const std::shared_ptr<FenceTime>& acquireFence) = 0;
Alec Mourie4034bb2019-11-19 12:45:54 -0800100 // SetPresent{Time, Fence} are not expected to be called in the critical
101 // rendering path, as they flush prior fences if those fences have fired.
Alec Mouri7d436ec2021-01-27 20:40:50 -0800102 virtual void setPresentTime(int32_t layerId, uint64_t frameNumber, nsecs_t presentTime,
Ady Abraham8b9e6122021-01-26 19:11:45 -0800103 Fps displayRefreshRate, std::optional<Fps> renderRate,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000104 SetFrameRateVote frameRateVote, int32_t gameMode) = 0;
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800105 virtual void setPresentFence(int32_t layerId, uint64_t frameNumber,
Alec Mouri7d436ec2021-01-27 20:40:50 -0800106 const std::shared_ptr<FenceTime>& presentFence,
Ady Abraham8b9e6122021-01-26 19:11:45 -0800107 Fps displayRefreshRate, std::optional<Fps> renderRate,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000108 SetFrameRateVote frameRateVote, int32_t gameMode) = 0;
Alec Mouri9a29e672020-09-14 12:39:14 -0700109
Alec Mouri7d436ec2021-01-27 20:40:50 -0800110 // Increments janky frames, blamed to the provided {refreshRate, renderRate, uid, layerName}
111 // key, with JankMetadata as supplementary reasons for the jank. Because FrameTimeline is the
112 // infrastructure responsible for computing jank in the system, this is expected to be called
113 // from FrameTimeline, rather than directly from SurfaceFlinger or individual layers. If there
114 // are no jank reasons, then total frames are incremented but jank is not, for accurate
Alec Mouri9a29e672020-09-14 12:39:14 -0700115 // accounting of janky frames.
Alec Mouri363faf02021-01-29 16:34:55 -0800116 // displayDeadlineDelta, displayPresentJitter, and appDeadlineDelta are also provided in order
117 // to provide contextual information about a janky frame. These values may only be uploaded if
118 // there was an associated valid jank reason, and they must be positive. When these frame counts
119 // are incremented, these are also aggregated into a global reporting packet to help with data
120 // validation and assessing of overall device health.
121 struct JankyFramesInfo {
122 Fps refreshRate;
123 std::optional<Fps> renderRate;
124 uid_t uid = 0;
125 std::string layerName;
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000126 int32_t gameMode = 0;
Alec Mouri363faf02021-01-29 16:34:55 -0800127 int32_t reasons = 0;
128 nsecs_t displayDeadlineDelta = 0;
129 nsecs_t displayPresentJitter = 0;
130 nsecs_t appDeadlineDelta = 0;
131
132 bool operator==(const JankyFramesInfo& o) const {
133 return Fps::EqualsInBuckets{}(refreshRate, o.refreshRate) &&
134 ((renderRate == std::nullopt && o.renderRate == std::nullopt) ||
135 (renderRate != std::nullopt && o.renderRate != std::nullopt &&
136 Fps::EqualsInBuckets{}(*renderRate, *o.renderRate))) &&
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000137 uid == o.uid && layerName == o.layerName && gameMode == o.gameMode &&
138 reasons == o.reasons && displayDeadlineDelta == o.displayDeadlineDelta &&
Alec Mouri363faf02021-01-29 16:34:55 -0800139 displayPresentJitter == o.displayPresentJitter &&
140 appDeadlineDelta == o.appDeadlineDelta;
141 }
142
143 friend std::ostream& operator<<(std::ostream& os, const JankyFramesInfo& info) {
144 os << "JankyFramesInfo {";
145 os << "\n .refreshRate = " << info.refreshRate;
146 os << "\n .renderRate = "
147 << (info.renderRate ? to_string(*info.renderRate) : "nullopt");
148 os << "\n .uid = " << info.uid;
149 os << "\n .layerName = " << info.layerName;
150 os << "\n .reasons = " << info.reasons;
151 os << "\n .displayDeadlineDelta = " << info.displayDeadlineDelta;
152 os << "\n .displayPresentJitter = " << info.displayPresentJitter;
153 os << "\n .appDeadlineDelta = " << info.appDeadlineDelta;
154 return os << "\n}";
155 }
156 };
157
158 virtual void incrementJankyFrames(const JankyFramesInfo& info) = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -0800159 // Clean up the layer record
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800160 virtual void onDestroy(int32_t layerId) = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -0800161 // If SF skips or rejects a buffer, remove the corresponding TimeRecord.
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800162 virtual void removeTimeRecord(int32_t layerId, uint64_t frameNumber) = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -0800163
Peiyong Lin65248e02020-04-18 21:15:07 -0700164 virtual void setPowerMode(
165 hardware::graphics::composer::V2_4::IComposerClient::PowerMode powerMode) = 0;
Alec Mourifb571ea2019-01-24 18:42:10 -0800166 // Source of truth is RefrehRateStats.
167 virtual void recordRefreshRate(uint32_t fps, nsecs_t duration) = 0;
168 virtual void setPresentFenceGlobal(const std::shared_ptr<FenceTime>& presentFence) = 0;
169};
170
171namespace impl {
172
173class TimeStats : public android::TimeStats {
Peiyong Lin65248e02020-04-18 21:15:07 -0700174 using PowerMode = android::hardware::graphics::composer::V2_4::IComposerClient::PowerMode;
175
Yiwei Zhangcf50ab92018-06-14 10:50:12 -0700176 struct FrameTime {
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700177 uint64_t frameNumber = 0;
178 nsecs_t postTime = 0;
179 nsecs_t latchTime = 0;
180 nsecs_t acquireTime = 0;
181 nsecs_t desiredTime = 0;
182 nsecs_t presentTime = 0;
Yiwei Zhangcf50ab92018-06-14 10:50:12 -0700183 };
184
185 struct TimeRecord {
186 bool ready = false;
187 FrameTime frameTime;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700188 std::shared_ptr<FenceTime> acquireFence;
189 std::shared_ptr<FenceTime> presentFence;
190 };
191
192 struct LayerRecord {
Alec Mouri9a29e672020-09-14 12:39:14 -0700193 uid_t uid;
Yiwei Zhang9689e2f2018-05-11 12:33:23 -0700194 std::string layerName;
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000195 int32_t gameMode = 0;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700196 // This is the index in timeRecords, at which the timestamps for that
197 // specific frame are still not fully received. This is not waiting for
198 // fences to signal, but rather waiting to receive those fences/timestamps.
199 int32_t waitData = -1;
Yiwei Zhangeaeea062018-06-28 14:46:51 -0700200 uint32_t droppedFrames = 0;
Alec Mouri91f6df32020-01-30 08:48:58 -0800201 uint32_t lateAcquireFrames = 0;
202 uint32_t badDesiredPresentFrames = 0;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700203 TimeRecord prevTimeRecord;
Yiwei Zhangc5f2c452018-05-08 16:31:56 -0700204 std::deque<TimeRecord> timeRecords;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700205 };
206
Yiwei Zhang3a226d22018-10-16 09:23:03 -0700207 struct PowerTime {
Peiyong Lin65248e02020-04-18 21:15:07 -0700208 PowerMode powerMode = PowerMode::OFF;
Yiwei Zhang3a226d22018-10-16 09:23:03 -0700209 nsecs_t prevTime = 0;
210 };
211
Alec Mourie4034bb2019-11-19 12:45:54 -0800212 struct RenderEngineDuration {
213 nsecs_t startTime;
214 std::variant<nsecs_t, std::shared_ptr<FenceTime>> endTime;
215 };
216
Yiwei Zhangce6ebc02018-10-20 12:42:38 -0700217 struct GlobalRecord {
218 nsecs_t prevPresentTime = 0;
219 std::deque<std::shared_ptr<FenceTime>> presentFences;
Alec Mourie4034bb2019-11-19 12:45:54 -0800220 std::deque<RenderEngineDuration> renderEngineDurations;
Yiwei Zhangce6ebc02018-10-20 12:42:38 -0700221 };
222
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700223public:
Alec Mourib3885ad2019-09-06 17:08:55 -0700224 TimeStats();
Alec Mouri8e2f31b2020-01-16 22:04:35 +0000225 // For testing only for injecting custom dependencies.
Tej Singhe2751772021-04-06 22:05:29 -0700226 TimeStats(std::optional<size_t> maxPulledLayers,
Alec Mouri37384342020-01-02 17:23:37 -0800227 std::optional<size_t> maxPulledHistogramBuckets);
Alec Mouri8e2f31b2020-01-16 22:04:35 +0000228
Tej Singhe2751772021-04-06 22:05:29 -0700229 bool onPullAtom(const int atomId, std::string* pulledData) override;
Alec Mourifb571ea2019-01-24 18:42:10 -0800230 void parseArgs(bool asProto, const Vector<String16>& args, std::string& result) override;
231 bool isEnabled() override;
Yiwei Zhang7eb58b72019-04-22 19:00:02 -0700232 std::string miniDump() override;
Yiwei Zhang7e666a52018-11-15 13:33:42 -0800233
Alec Mourifb571ea2019-01-24 18:42:10 -0800234 void incrementTotalFrames() override;
235 void incrementMissedFrames() override;
236 void incrementClientCompositionFrames() override;
Vishnu Nair9b079a22020-01-21 14:36:08 -0800237 void incrementClientCompositionReusedFrames() override;
Alec Mouri8de697e2020-03-19 10:52:01 -0700238 void incrementRefreshRateSwitches() override;
Alec Mouri8f7a0102020-04-15 12:11:10 -0700239 void incrementCompositionStrategyChanges() override;
Alec Mouri717bcb62020-02-10 17:07:19 -0800240 void recordDisplayEventConnectionCount(int32_t count) override;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700241
Alec Mouri9519bf12019-11-15 16:54:44 -0800242 void recordFrameDuration(nsecs_t startTime, nsecs_t endTime) override;
Alec Mourie4034bb2019-11-19 12:45:54 -0800243 void recordRenderEngineDuration(nsecs_t startTime, nsecs_t endTime) override;
244 void recordRenderEngineDuration(nsecs_t startTime,
245 const std::shared_ptr<FenceTime>& readyFence) override;
Alec Mouri9519bf12019-11-15 16:54:44 -0800246
Alec Mouri9a29e672020-09-14 12:39:14 -0700247 void setPostTime(int32_t layerId, uint64_t frameNumber, const std::string& layerName, uid_t uid,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000248 nsecs_t postTime, int32_t gameMode) override;
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800249 void setLatchTime(int32_t layerId, uint64_t frameNumber, nsecs_t latchTime) override;
Alec Mouri91f6df32020-01-30 08:48:58 -0800250 void incrementLatchSkipped(int32_t layerId, LatchSkipReason reason) override;
251 void incrementBadDesiredPresent(int32_t layerId) override;
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800252 void setDesiredTime(int32_t layerId, uint64_t frameNumber, nsecs_t desiredTime) override;
253 void setAcquireTime(int32_t layerId, uint64_t frameNumber, nsecs_t acquireTime) override;
254 void setAcquireFence(int32_t layerId, uint64_t frameNumber,
Alec Mourifb571ea2019-01-24 18:42:10 -0800255 const std::shared_ptr<FenceTime>& acquireFence) override;
Alec Mouri7d436ec2021-01-27 20:40:50 -0800256 void setPresentTime(int32_t layerId, uint64_t frameNumber, nsecs_t presentTime,
Ady Abraham8b9e6122021-01-26 19:11:45 -0800257 Fps displayRefreshRate, std::optional<Fps> renderRate,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000258 SetFrameRateVote frameRateVote, int32_t gameMode) override;
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800259 void setPresentFence(int32_t layerId, uint64_t frameNumber,
Alec Mouri7d436ec2021-01-27 20:40:50 -0800260 const std::shared_ptr<FenceTime>& presentFence, Fps displayRefreshRate,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000261 std::optional<Fps> renderRate, SetFrameRateVote frameRateVote,
262 int32_t gameMode) override;
Alec Mouri363faf02021-01-29 16:34:55 -0800263
264 void incrementJankyFrames(const JankyFramesInfo& info) override;
Yiwei Zhangaf8ee942018-11-22 00:15:23 -0800265 // Clean up the layer record
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800266 void onDestroy(int32_t layerId) override;
Yiwei Zhangeaeea062018-06-28 14:46:51 -0700267 // If SF skips or rejects a buffer, remove the corresponding TimeRecord.
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800268 void removeTimeRecord(int32_t layerId, uint64_t frameNumber) override;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700269
Peiyong Lin65248e02020-04-18 21:15:07 -0700270 void setPowerMode(
271 hardware::graphics::composer::V2_4::IComposerClient::PowerMode powerMode) override;
Alec Mourifb571ea2019-01-24 18:42:10 -0800272 // Source of truth is RefrehRateStats.
273 void recordRefreshRate(uint32_t fps, nsecs_t duration) override;
274 void setPresentFenceGlobal(const std::shared_ptr<FenceTime>& presentFence) override;
Yiwei Zhang3a226d22018-10-16 09:23:03 -0700275
Yiwei Zhangaf8ee942018-11-22 00:15:23 -0800276 static const size_t MAX_NUM_TIME_RECORDS = 64;
277
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700278private:
Tej Singhe2751772021-04-06 22:05:29 -0700279 bool populateGlobalAtom(std::string* pulledData);
280 bool populateLayerAtom(std::string* pulledData);
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800281 bool recordReadyLocked(int32_t layerId, TimeRecord* timeRecord);
Alec Mouri7d436ec2021-01-27 20:40:50 -0800282 void flushAvailableRecordsToStatsLocked(int32_t layerId, Fps displayRefreshRate,
Ady Abraham8b9e6122021-01-26 19:11:45 -0800283 std::optional<Fps> renderRate,
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000284 SetFrameRateVote frameRateVote, int32_t gameMode);
Yiwei Zhang3a226d22018-10-16 09:23:03 -0700285 void flushPowerTimeLocked();
Yiwei Zhangce6ebc02018-10-20 12:42:38 -0700286 void flushAvailableGlobalRecordsToStatsLocked();
Adithya Srinivasan58069dc2021-06-04 20:37:02 +0000287 bool canAddNewAggregatedStats(uid_t uid, const std::string& layerName, int32_t gameMode);
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700288
289 void enable();
290 void disable();
Alec Mouri8e2f31b2020-01-16 22:04:35 +0000291 void clearAll();
292 void clearGlobalLocked();
293 void clearLayersLocked();
Yiwei Zhang5434a782018-12-05 18:06:32 -0800294 void dump(bool asProto, std::optional<uint32_t> maxLayers, std::string& result);
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700295
296 std::atomic<bool> mEnabled = false;
297 std::mutex mMutex;
Yiwei Zhangdc224042018-10-18 15:34:00 -0700298 TimeStatsHelper::TimeStatsGlobal mTimeStats;
Yiwei Zhang1a88c402019-11-18 10:43:58 -0800299 // Hashmap for LayerRecord with layerId as the hash key
Yiwei Zhang9689e2f2018-05-11 12:33:23 -0700300 std::unordered_map<int32_t, LayerRecord> mTimeStatsTracker;
Yiwei Zhang3a226d22018-10-16 09:23:03 -0700301 PowerTime mPowerTime;
Yiwei Zhangce6ebc02018-10-20 12:42:38 -0700302 GlobalRecord mGlobalRecord;
Yiwei Zhang7eb58b72019-04-22 19:00:02 -0700303
304 static const size_t MAX_NUM_LAYER_RECORDS = 200;
Alec Mouri7d436ec2021-01-27 20:40:50 -0800305
306 static const size_t REFRESH_RATE_BUCKET_WIDTH = 30;
307 static const size_t RENDER_RATE_BUCKET_WIDTH = REFRESH_RATE_BUCKET_WIDTH;
Yiwei Zhange926ab52019-08-14 15:16:00 -0700308 static const size_t MAX_NUM_LAYER_STATS = 200;
Alec Mouri52bf7802021-01-20 08:20:50 -0800309 static const size_t MAX_NUM_PULLED_LAYERS = MAX_NUM_LAYER_STATS;
Alec Mouri52bf7802021-01-20 08:20:50 -0800310 size_t mMaxPulledLayers = MAX_NUM_PULLED_LAYERS;
Alec Mouri37384342020-01-02 17:23:37 -0800311 size_t mMaxPulledHistogramBuckets = 6;
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700312};
313
Alec Mourifb571ea2019-01-24 18:42:10 -0800314} // namespace impl
315
Yiwei Zhang0102ad22018-05-02 17:37:17 -0700316} // namespace android