commit | e35be978351a8578549d30b6f483825d36dc0f8b | [log] [tgz] |
---|---|---|
author | Juhyun Lee <impjdi@google.com> | Fri Jul 16 10:12:26 2021 -0700 |
committer | TensorFlower Gardener <gardener@tensorflow.org> | Fri Jul 16 10:16:38 2021 -0700 |
tree | 7534aaaee3831ff0d7b402b1f586b7ebd2d99565 | |
parent | 4a91f2069f7145aab6ba2d8cfe41be8a110c18a5 [diff] |
PR #50327: Prevent glGetError infinity Imported from GitHub PR https://github.com/tensorflow/tensorflow/pull/50327 if EGL context is not available, the glGetError always return GL_INVALID_OPERATION. I use my simple EGL to WGL wrapper, and found an infinite loop when destroying interpreter. https://github.com/metarutaiga/TensorFlowLiteReduce/blob/master/third_party/EGL/egl_windows.c Copybara import of the project: -- 18670dfb2e7a020027b863e1beb216249e2ea198 by metarutaiga PiperOrigin-RevId: 385171233 Change-Id: I2e7aa4267a2ab1e98228cda653717eaf2dc44105
diff --git a/tensorflow/lite/delegates/gpu/gl/gl_errors.cc b/tensorflow/lite/delegates/gpu/gl/gl_errors.cc index 374e9c2..3cbfdbe 100644 --- a/tensorflow/lite/delegates/gpu/gl/gl_errors.cc +++ b/tensorflow/lite/delegates/gpu/gl/gl_errors.cc
@@ -64,10 +64,6 @@ // GPU process. return absl::OkStatus(); #else - EGLContext context = eglGetCurrentContext(); - if (context == EGL_NO_CONTEXT) { - return absl::InternalError("EGL Context is not available"); - } auto error = glGetError(); if (error == GL_NO_ERROR) { return absl::OkStatus();