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

Commit f44fb22b authored by Riddle Hsu's avatar Riddle Hsu Committed by Android (Google) Code Review
Browse files

Merge "Print state of non-ready timeout transition" into main

parents 84197daf 9deb64a1
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -96,6 +96,7 @@ class BLASTSyncEngine {
    interface TransactionReadyListener {
        void onTransactionReady(int mSyncId, SurfaceControl.Transaction transaction);
        default void onTransactionCommitTimeout() {}
        default void onReadyTimeout() {}
    }

    /**
@@ -410,6 +411,7 @@ class BLASTSyncEngine {
            if (allFinished && !mReady) {
                Slog.w(TAG, "Sync group " + mSyncId + " timed-out because not ready. If you see "
                        + "this, please file a bug.");
                mListener.onReadyTimeout();
            }
            finishNow();
            removeFromDependencies(this);
+12 −8
Original line number Diff line number Diff line
@@ -1648,14 +1648,6 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
        }

        if (mController.useFullReadyTracking()) {
            if (mReadyTracker.mMet.isEmpty()) {
                Slog.e(TAG, "#" + mSyncId + ": No conditions provided");
            } else {
                for (int i = 0; i < mReadyTracker.mConditions.size(); ++i) {
                    Slog.e(TAG, "#" + mSyncId + ": unmet condition at ready: "
                            + mReadyTracker.mConditions.get(i));
                }
            }
            for (int i = 0; i < mReadyTracker.mMet.size(); ++i) {
                ProtoLog.v(ProtoLogGroup.WM_DEBUG_WINDOW_TRANSITIONS, "#%d: Met condition: %s",
                        mSyncId, mReadyTracker.mMet.get(i));
@@ -3360,6 +3352,18 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
        applyReady();
    }

    @Override
    public void onReadyTimeout() {
        if (!mController.useFullReadyTracking()) {
            Slog.e(TAG, "#" + mSyncId + " readiness timeout, used=" + mReadyTrackerOld.mUsed
                    + " deferReadyDepth=" + mReadyTrackerOld.mDeferReadyDepth
                    + " group=" + mReadyTrackerOld.mReadyGroups);
            return;
        }
        Slog.e(TAG, "#" + mSyncId + " met conditions: " + mReadyTracker.mMet);
        Slog.e(TAG, "#" + mSyncId + " unmet conditions: " + mReadyTracker.mConditions);
    }

    /**
     * Represents a condition that must be met before an associated transition can be considered
     * ready.