From a9ce662c44bdd0c2032d8db6b18dab11073ff10b Mon Sep 17 00:00:00 2001 From: Boleyn Su Date: Wed, 18 Nov 2020 03:15:29 +0000 Subject: Revert "gpuDrawTime should default to 0 when endTime is unknown" This reverts commit 95cf4e70883d56acdb5da40052c5f77713e592e6. Reason for revert: the fix is not working and also found that it is set to -1 on purpose Change-Id: I3ea5553606a7824ba23909b0e36b2538d0f3d29f --- libs/hwui/FrameInfo.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/hwui/FrameInfo.h b/libs/hwui/FrameInfo.h index 738246d56d0d..ee7d15a2fbce 100644 --- a/libs/hwui/FrameInfo.h +++ b/libs/hwui/FrameInfo.h @@ -159,7 +159,7 @@ public: // GPU start time is approximated to the moment before swapBuffer is invoked. // We could add an EGLSyncKHR fence at the beginning of the frame, but that is an overhead. int64_t endTime = get(FrameInfoIndex::GpuCompleted); - return endTime > 0 ? endTime - get(FrameInfoIndex::SwapBuffers) : 0; + return endTime > 0 ? endTime - get(FrameInfoIndex::SwapBuffers) : -1; } inline int64_t& set(FrameInfoIndex index) { return mFrameInfo[static_cast(index)]; } -- cgit v1.2.3-59-g8ed1b