Mesa (master): glthread: remove extra _mesa_glthread_finish() from generated code

Timothy Arceri tarceri at kemper.freedesktop.org
Wed Jun 7 04:53:53 UTC 2017


Module: Mesa
Branch: master
Commit: d0cec1fce1697f9c9c99eb1e3fa8d3fa1fd86b21
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=d0cec1fce1697f9c9c99eb1e3fa8d3fa1fd86b21

Author: Timothy Arceri <tarceri at itsqueeze.com>
Date:   Tue Jun  6 15:08:16 2017 +1000

glthread: remove extra _mesa_glthread_finish() from generated code

The other user of print_sync_dispatch() was ending up with code that
looked like:

      _mesa_glthread_finish(ctx);
      _mesa_glthread_restore_dispatch(ctx);
      _mesa_glthread_finish(ctx);

Reviewed-by: Marek Olšák <marek.olsak at amd.com>

---

 src/mapi/glapi/gen/gl_marshal.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mapi/glapi/gen/gl_marshal.py b/src/mapi/glapi/gen/gl_marshal.py
index 51475e17ad..f52b9b7b81 100644
--- a/src/mapi/glapi/gen/gl_marshal.py
+++ b/src/mapi/glapi/gen/gl_marshal.py
@@ -90,7 +90,6 @@ class PrintCode(gl_XML.gl_print_base):
             out('return {0};'.format(call))
 
     def print_sync_dispatch(self, func):
-        out('_mesa_glthread_finish(ctx);')
         out('debug_print_sync_fallback("{0}");'.format(func.name))
         self.print_sync_call(func)
 
@@ -259,6 +258,7 @@ class PrintCode(gl_XML.gl_print_base):
         if need_fallback_sync:
             out('fallback_to_sync:')
         with indent():
+            out('_mesa_glthread_finish(ctx);')
             self.print_sync_dispatch(func)
 
         out('}')




More information about the mesa-commit mailing list