Report deltas as 0 instead of -1 for prediction expired display frames
Since both positive and negative values are valid for the deltas,
reporting -1 for cases where we cannot provide a delta skews the
metrics. Instead, report 0 as the delta since the jank is already
reported as unknown.
Bug: 184986864
Test: libsurfaceflinger_unittest
Change-Id: I09cbb0cb7084620038b4d5ada6c196647733bbe5
diff --git a/services/surfaceflinger/tests/unittests/FrameTimelineTest.cpp b/services/surfaceflinger/tests/unittests/FrameTimelineTest.cpp
index 982252f..9654905 100644
--- a/services/surfaceflinger/tests/unittests/FrameTimelineTest.cpp
+++ b/services/surfaceflinger/tests/unittests/FrameTimelineTest.cpp
@@ -671,7 +671,7 @@
incrementJankyFrames(
TimeStats::JankyFramesInfo{refreshRate, renderRate, sUidOne, sLayerNameOne,
JankType::Unknown | JankType::AppDeadlineMissed,
- -1, -1, 25}));
+ 0, 0, 25}));
auto presentFence1 = fenceFactory.createFenceTimeForTest(Fence::NO_FENCE);
int64_t surfaceFrameToken1 = mTokenManager->generateTokenForPredictions({10, 20, 60});
int64_t sfToken1 = mTokenManager->generateTokenForPredictions({82, 90, 90});