Handle unsupported no_config contexts am: b60ae978ad am: 307c716b4e am: d217b05e1c
authorMark Adams <marka@nvidia.com>
Wed, 7 Feb 2018 17:53:44 +0000 (17:53 +0000)
committerandroid-build-merger <android-build-merger@google.com>
Wed, 7 Feb 2018 17:53:44 +0000 (17:53 +0000)
am: b6f119f293

Change-Id: Idce771c51e63ac558615ac2f3fe4e50ab11d1dd5

modules/egl/teglGetFrameTimestampsTests.cpp

index bbf27cc..09deb06 100644 (file)
@@ -194,7 +194,8 @@ void populateFrameTimes(FrameTimes* frameTimes, TimestampInfoMap& map, const std
 
 bool timestampValid (EGLnsecsANDROID timestamp)
 {
-       return (timestamp >= 0) || (timestamp == EGL_TIMESTAMP_PENDING_ANDROID);
+       // \todo [2017-10-19 brianderson] Don't consider 0 invalid once kernel fix is in.
+       return (timestamp > 0) || (timestamp == EGL_TIMESTAMP_PENDING_ANDROID);
 }
 
 bool timestampPending (EGLnsecsANDROID timestamp)
@@ -241,7 +242,7 @@ void verifySingleFrame (const FrameTimes& frameTimes, tcu::ResultCollector& resu
        // be sure that the readsDone time must be after the renderingComplete time.
     // It may also be equal to the renderingComplete time if no reads were
     // peformed.
-       if (verifyReadsDone)
+       if (verifyReadsDone && timestampValid(frameTimes.readsDone))
                check_le(result, frameTimes.renderingComplete, frameTimes.readsDone, "Buffer rendering completed after reads completed.");
 
        // Verify CPU/GPU dependencies