summaryrefslogtreecommitdiffstats
path: root/services/surfaceflinger/EventLog/EventLog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'services/surfaceflinger/EventLog/EventLog.cpp')
-rw-r--r--services/surfaceflinger/EventLog/EventLog.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/services/surfaceflinger/EventLog/EventLog.cpp b/services/surfaceflinger/EventLog/EventLog.cpp
index 815242b..47bab83 100644
--- a/services/surfaceflinger/EventLog/EventLog.cpp
+++ b/services/surfaceflinger/EventLog/EventLog.cpp
@@ -31,17 +31,22 @@ ANDROID_SINGLETON_STATIC_INSTANCE(EventLog)
EventLog::EventLog() {
}
-void EventLog::doLogJank(const String8& window, int32_t value) {
- EventLog::TagBuffer buffer(LOGTAG_SF_JANK);
- buffer.startList(2);
+void EventLog::doLogFrameDurations(const String8& window,
+ const int32_t* durations, size_t numDurations) {
+ EventLog::TagBuffer buffer(LOGTAG_SF_FRAME_DUR);
+ buffer.startList(1 + numDurations);
buffer.writeString8(window);
- buffer.writeInt32(value);
+ for (size_t i = 0; i < numDurations; i++) {
+ buffer.writeInt32(durations[i]);
+ }
buffer.endList();
buffer.log();
}
-void EventLog::logJank(const String8& window, int32_t value) {
- EventLog::getInstance().doLogJank(window, value);
+void EventLog::logFrameDurations(const String8& window,
+ const int32_t* durations, size_t numDurations) {
+ EventLog::getInstance().doLogFrameDurations(window, durations,
+ numDurations);
}
// ---------------------------------------------------------------------------