Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3196f1da authored by Automerger Merge Worker's avatar Automerger Merge Worker Committed by Android (Google) Code Review
Browse files

Merge changes from topic "am-3f64ae8661eb42da8e78583896dfc180"

* changes:
  Merge changes from topics "jank-tags-faas", "transition-finish-faas", "transition-type-faas" into udc-dev am: 89b54da1 am: 74d490f2
  Dump jank tag to event log am: eda59488 am: 718bedb3
  Dump the transition type in always on transition trace am: 78ece1c6 am: 2311a91b
  Dump finish time of transitions in transitions trace am: 61aaf12c am: bb67d86a
parents 3990bd99 a122413b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@
option java_package com.android.internal.jank;

# Marks a request to start tracing a CUJ. Doesn't mean the request was executed.
37001 jank_cuj_events_begin_request (CUJ Type|1|5),(Unix Time Ns|2|3),(Elapsed Time Ns|2|3),(Uptime Ns|2|3)
37001 jank_cuj_events_begin_request (CUJ Type|1|5),(Unix Time Ns|2|3),(Elapsed Time Ns|2|3),(Uptime Ns|2|3),(Tag|3)
# Marks a request to end tracing a CUJ. Doesn't mean the request was executed.
37002 jank_cuj_events_end_request (CUJ Type|1|5),(Unix Time Ns|2|3),(Elapsed Time Ns|2|3),(Uptime Time Ns|2|3)
# Marks a request to cancel tracing a CUJ. Doesn't mean the request was executed.
+1 −1
Original line number Diff line number Diff line
@@ -590,7 +590,7 @@ public class InteractionJankMonitor {
            final Configuration config = builder.build();
            postEventLogToWorkerThread((unixNanos, elapsedNanos, realtimeNanos) -> {
                EventLogTags.writeJankCujEventsBeginRequest(
                        config.mCujType, unixNanos, elapsedNanos, realtimeNanos);
                        config.mCujType, unixNanos, elapsedNanos, realtimeNanos, config.mTag);
            });
            final TrackerResult result = new TrackerResult();
            final boolean success = config.getHandler().runWithScissors(
+7 −3
Original line number Diff line number Diff line
@@ -36,8 +36,10 @@ message TransitionTraceProto {
    MAGIC_NUMBER_H = 0x45434152;  /* RACE (little-endian ASCII) */
  }

  required fixed64 magic_number = 1;  /* Must be the first field, set to value in MagicNumber */
  repeated Transition sent_transitions = 2;
  // Must be the first field, set to value in MagicNumber
  required fixed64 magic_number = 1;
  // Transitions that don't have a finish time are considered aborted
  repeated Transition finished_transitions = 2;

  // Additional debugging info only collected and dumped when explicitly requested to trace
  repeated TransitionState transition_states = 3;
@@ -50,7 +52,9 @@ message Transition {
  required uint64 finish_transaction_id = 3;
  required int64 create_time_ns = 4;
  required int64 send_time_ns = 5;
  repeated Target targets = 6;
  optional int64 finish_time_ns = 6; // consider aborted if not provided
  required int32 type = 7;
  repeated Target targets = 8;
}

message Target {
+3 −2
Original line number Diff line number Diff line
@@ -829,6 +829,7 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
        }
        mLogger.mFinishTimeNs = SystemClock.elapsedRealtimeNanos();
        mController.mLoggerHandler.post(mLogger::logOnFinish);
        mController.mTransitionTracer.logFinishedTransition(this);
        // Close the transactions now. They were originally copied to Shell in case we needed to
        // apply them due to a remote failure. Since we don't need to apply them anymore, free them
        // immediately.
@@ -1045,6 +1046,7 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
        }
        ProtoLog.v(ProtoLogGroup.WM_DEBUG_WINDOW_TRANSITIONS, "Aborting Transition: %d", mSyncId);
        mState = STATE_ABORT;
        mController.mTransitionTracer.logAbortedTransition(this);
        // Syncengine abort will call through to onTransactionReady()
        mSyncEngine.abort(mSyncId);
        mController.dispatchLegacyAppTransitionCancelled();
@@ -1249,8 +1251,7 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
                        "Calling onTransitionReady: %s", info);
                mLogger.mSendTimeNs = SystemClock.elapsedRealtimeNanos();
                mLogger.mInfo = info;
                mController.mTransitionTracer.logSentTransition(
                        this, mTargets, mLogger.mCreateTimeNs, mLogger.mSendTimeNs, info);
                mController.mTransitionTracer.logSentTransition(this, mTargets, info);
                mController.getTransitionPlayer().onTransitionReady(
                        mToken, info, transaction, mFinishTransaction);
                if (Trace.isTagEnabled(TRACE_TAG_WINDOW_MANAGER)) {
+2 −0
Original line number Diff line number Diff line
@@ -976,6 +976,8 @@ class TransitionController {
        WindowContainerTransaction mStartWCT;
        int mSyncId;
        TransitionInfo mInfo;
        ProtoOutputStream mProtoOutputStream = new ProtoOutputStream();
        long mProtoToken;

        private String buildOnSendLog() {
            StringBuilder sb = new StringBuilder("Sent Transition #").append(mSyncId)
Loading