OSDN Git Service

Use correct timestamps of events for logging.
authorSudheer Shanka <sudheersai@google.com>
Mon, 12 Jun 2017 17:37:29 +0000 (10:37 -0700)
committerSudheer Shanka <sudheersai@google.com>
Tue, 13 Jun 2017 17:29:03 +0000 (10:29 -0700)
commitc766db0a54679cd67884d7366cee8b6e8ecd447c
treefbf2b95b607e12e1648417b40160188919f7516a
parent8490ed92e19a804e7ff7fc9ca9d433a8ce00105c
Use correct timestamps of events for logging.

Currently when WM detects certain events, it will notify the logger
of these events asynchronously and logger uses the timestamp at which it
gets notified to log these events. It's possible that the delay between
when the event actually occurs and when the logger gets notified could be
large. So for better accuracy, WM should also pass on the event timestamp
to the logger.

Bug: 62375480
Test: Triggered sysui_multi_action event logs and verified that
      APP_TRANSITION_DELAY_MS is less than APP_TRANSITION_WINDOWS_DRAWN_DELAY_MS.
Test: When the system is not busy, the timestamps we used to log earlier
      and timestamps we log with this change are almost same.
Change-Id: I5f62654a6b7f179d821c0082b180246c8a569df1
core/java/android/app/ActivityManagerInternal.java
services/core/java/com/android/server/am/ActivityManagerService.java
services/core/java/com/android/server/am/ActivityMetricsLogger.java
services/core/java/com/android/server/am/ActivityRecord.java
services/core/java/com/android/server/wm/AppWindowContainerController.java
services/core/java/com/android/server/wm/AppWindowContainerListener.java
services/core/java/com/android/server/wm/WindowManagerService.java