Demarcate cached sets in composition summary
Previously, the composition summary indicated that HWC was compositing
more layers than it actually was.
Example when youtube video open and playing in a free form window
Before: bbrrrRrbbb
After: [b:brr]r[R:rbbb]
So there are 2 cached sets and 1 uncached set. One cached set and one uncached layer is composited by HWC, the other cached set is composed by the GPU.
Bug: 391428079
Flag: EXEMPT log only update
Test: Capture perfetto trace and confirm layers are skipped and overridden as expected
Change-Id: I4ffda43f5248ef8bb690cdaca0eeca7ffac3d997
diff --git a/services/surfaceflinger/LayerFE.h b/services/surfaceflinger/LayerFE.h
index 64ec278..a537456 100644
--- a/services/surfaceflinger/LayerFE.h
+++ b/services/surfaceflinger/LayerFE.h
@@ -59,9 +59,10 @@
void setReleaseFence(const FenceResult& releaseFence) override;
LayerFE::ReleaseFencePromiseStatus getReleaseFencePromiseStatus() override;
void onPictureProfileCommitted() override;
- void setHwcCompositionType(aidl::android::hardware::graphics::composer3::Composition) override;
- aidl::android::hardware::graphics::composer3::Composition getHwcCompositionType()
- const override;
+
+ // Used for debugging purposes, e.g. perfetto tracing, dumpsys.
+ void setLastHwcState(const HwcLayerDebugState &state) override;
+ const HwcLayerDebugState &getLastHwcState() const override;
std::unique_ptr<surfaceflinger::frontend::LayerSnapshot> mSnapshot;
@@ -93,8 +94,7 @@
std::string mName;
std::promise<FenceResult> mReleaseFence;
ReleaseFencePromiseStatus mReleaseFencePromiseStatus = ReleaseFencePromiseStatus::UNINITIALIZED;
- aidl::android::hardware::graphics::composer3::Composition mLastHwcCompositionType =
- aidl::android::hardware::graphics::composer3::Composition::INVALID;
+ HwcLayerDebugState mLastHwcState;
};
} // namespace android