Throttling CTS producing frame speed
authorYiHsing Shen <yihsing.shen@mediatek.com>
Tue, 9 Nov 2021 02:03:40 +0000 (02:03 +0000)
committerMatthew Netsch <quic_mnetsch@quicinc.com>
Fri, 7 Jan 2022 15:38:59 +0000 (10:38 -0500)
CTS checks the present time of the frame 6 frames ago. However, if
the default buffer count of BufferQueue is more than 7, CTS could
produce frames continuously in a short time. In this case, the frame
6 frames ago might be not presented yet then CTS fails. To prevent
this situation, CTS produces frames at the speed according to
compositeInterval.

Component: EGL

Affected tests:
dEQP-EGL.functional.get_frame_timestamps.*

Change-Id: I1ac15974a6c4147ee2546ad21dea1fb3e6bf38f9

modules/egl/teglGetFrameTimestampsTests.cpp

index cf6f8bb..f846e97 100644 (file)
@@ -673,6 +673,7 @@ void GetFrameTimestampTest::executeForConfig (EGLDisplay display, EGLConfig conf
                                        verifyNeighboringFrames(frame7ago, frame6ago, m_result);
                                }
                        }
+                       deSleep(static_cast<deUint32>(frame.compositeInterval / 1000000));
                }
 
                // All timestamps for the most recently swapped frame should