[Mesa-dev] [PATCH] Revert "foo"

Emil Velikov emil.l.velikov at gmail.com
Thu Sep 1 09:36:45 UTC 2016


This reverts commit 917e906379bc261c65e2cc4942d7bd3d8366f030.
---
 src/glx/g_glxglvnddispatchfuncs.c | 109 +++++++++++++++++++-------------------
 src/glx/glxglvnd.c                |   5 +-
 2 files changed, 55 insertions(+), 59 deletions(-)

diff --git a/src/glx/g_glxglvnddispatchfuncs.c b/src/glx/g_glxglvnddispatchfuncs.c
index 5ca9586..e6b9c0b 100644
--- a/src/glx/g_glxglvnddispatchfuncs.c
+++ b/src/glx/g_glxglvnddispatchfuncs.c
@@ -80,24 +80,24 @@ const char * const __glXDispatchTableStrings[DI_LAST_INDEX] = {
     __ATTRIB(WaitVideoSyncSGI),
     // glXWaitX implemented by libglvnd
 
-    __ATTRIB(BindSwapBarrierSGIX),
-    __ATTRIB(CopySubBufferMESA),
-    __ATTRIB(CreateGLXPixmapMESA),
-    __ATTRIB(GetMscRateOML),
-    __ATTRIB(GetScreenDriver),
-    __ATTRIB(GetSwapIntervalMESA),
-    __ATTRIB(GetSyncValuesOML),
-    __ATTRIB(JoinSwapGroupSGIX),
-    __ATTRIB(QueryCurrentRendererIntegerMESA),
-    __ATTRIB(QueryCurrentRendererStringMESA),
-    __ATTRIB(QueryMaxSwapBarriersSGIX),
-    __ATTRIB(QueryRendererIntegerMESA),
-    __ATTRIB(QueryRendererStringMESA),
-    __ATTRIB(ReleaseBuffersMESA),
-    __ATTRIB(SwapBuffersMscOML),
-    __ATTRIB(SwapIntervalMESA),
-    __ATTRIB(WaitForMscOML),
-    __ATTRIB(WaitForSbcOML),
+    __ATTRIB(glXBindSwapBarrierSGIX),
+    __ATTRIB(glXCopySubBufferMESA),
+    __ATTRIB(glXCreateGLXPixmapMESA),
+    __ATTRIB(glXGetMscRateOML),
+    __ATTRIB(glXGetScreenDriver),
+    __ATTRIB(glXGetSwapIntervalMESA),
+    __ATTRIB(glXGetSyncValuesOML),
+    __ATTRIB(glXJoinSwapGroupSGIX),
+    __ATTRIB(glXQueryCurrentRendererIntegerMESA),
+    __ATTRIB(glXQueryCurrentRendererStringMESA),
+    __ATTRIB(glXQueryMaxSwapBarriersSGIX),
+    __ATTRIB(glXQueryRendererIntegerMESA),
+    __ATTRIB(glXQueryRendererStringMESA),
+    __ATTRIB(glXReleaseBuffersMESA),
+    __ATTRIB(glXSwapBuffersMscOML),
+    __ATTRIB(glXSwapIntervalMESA),
+    __ATTRIB(glXWaitForMscOML),
+    __ATTRIB(glXWaitForSbcOML),
 
 #undef __ATTRIB
 };
@@ -557,7 +557,7 @@ static int dispatch_WaitVideoSyncSGI(int divisor, int remainder,
 
 
 
-static void dispatch_BindSwapBarrierSGIX(Display *dpy, GLXDrawable drawable,
+static void dispatch_glXBindSwapBarrierSGIX(Display *dpy, GLXDrawable drawable,
                                             int barrier)
 {
     PFNGLXBINDSWAPBARRIERSGIXPROC pglXBindSwapBarrierSGIX;
@@ -576,7 +576,7 @@ static void dispatch_BindSwapBarrierSGIX(Display *dpy, GLXDrawable drawable,
 
 
 
-static void dispatch_CopySubBufferMESA(Display *dpy, GLXDrawable drawable,
+static void dispatch_glXCopySubBufferMESA(Display *dpy, GLXDrawable drawable,
                                           int x, int y, int width, int height)
 {
     PFNGLXCOPYSUBBUFFERMESAPROC pglXCopySubBufferMESA;
@@ -595,7 +595,7 @@ static void dispatch_CopySubBufferMESA(Display *dpy, GLXDrawable drawable,
 
 
 
-static GLXPixmap dispatch_CreateGLXPixmapMESA(Display *dpy,
+static GLXPixmap dispatch_glXCreateGLXPixmapMESA(Display *dpy,
                                                  XVisualInfo *visinfo,
                                                  Pixmap pixmap, Colormap cmap)
 {
@@ -624,7 +624,7 @@ static GLXPixmap dispatch_CreateGLXPixmapMESA(Display *dpy,
 
 
 
-static GLboolean dispatch_GetMscRateOML(Display *dpy, GLXDrawable drawable,
+static GLboolean dispatch_glXGetMscRateOML(Display *dpy, GLXDrawable drawable,
                                            int32_t *numerator, int32_t *denominator)
 {
     PFNGLXGETMSCRATEOMLPROC pglXGetMscRateOML;
@@ -643,7 +643,7 @@ static GLboolean dispatch_GetMscRateOML(Display *dpy, GLXDrawable drawable,
 
 
 
-static const char *dispatch_GetScreenDriver(Display *dpy, int scrNum)
+static const char *dispatch_glXGetScreenDriver(Display *dpy, int scrNum)
 {
     typedef const char *(*fn_glXGetScreenDriver_ptr)(Display *dpy, int scrNum);
     fn_glXGetScreenDriver_ptr pglXGetScreenDriver;
@@ -662,7 +662,7 @@ static const char *dispatch_GetScreenDriver(Display *dpy, int scrNum)
 
 
 
-static int dispatch_GetSwapIntervalMESA(void)
+static int dispatch_glXGetSwapIntervalMESA(void)
 {
     PFNGLXGETSWAPINTERVALMESAPROC pglXGetSwapIntervalMESA;
     __GLXvendorInfo *dd;
@@ -683,7 +683,7 @@ static int dispatch_GetSwapIntervalMESA(void)
 
 
 
-static Bool dispatch_GetSyncValuesOML(Display *dpy, GLXDrawable drawable,
+static Bool dispatch_glXGetSyncValuesOML(Display *dpy, GLXDrawable drawable,
                                          int64_t *ust, int64_t *msc, int64_t *sbc)
 {
     PFNGLXGETSYNCVALUESOMLPROC pglXGetSyncValuesOML;
@@ -702,7 +702,7 @@ static Bool dispatch_GetSyncValuesOML(Display *dpy, GLXDrawable drawable,
 
 
 
-static void dispatch_JoinSwapGroupSGIX(Display *dpy, GLXDrawable drawable,
+static void dispatch_glXJoinSwapGroupSGIX(Display *dpy, GLXDrawable drawable,
                                           GLXDrawable member)
 {
     PFNGLXJOINSWAPGROUPSGIXPROC pglXJoinSwapGroupSGIX;
@@ -721,7 +721,7 @@ static void dispatch_JoinSwapGroupSGIX(Display *dpy, GLXDrawable drawable,
 
 
 
-static Bool dispatch_QueryCurrentRendererIntegerMESA(int attribute,
+static Bool dispatch_glXQueryCurrentRendererIntegerMESA(int attribute,
                                                         unsigned int *value)
 {
     PFNGLXQUERYCURRENTRENDERERINTEGERMESAPROC pglXQueryCurrentRendererIntegerMESA;
@@ -743,7 +743,7 @@ static Bool dispatch_QueryCurrentRendererIntegerMESA(int attribute,
 
 
 
-static const char *dispatch_QueryCurrentRendererStringMESA(int attribute)
+static const char *dispatch_glXQueryCurrentRendererStringMESA(int attribute)
 {
     PFNGLXQUERYCURRENTRENDERERSTRINGMESAPROC pglXQueryCurrentRendererStringMESA;
     __GLXvendorInfo *dd;
@@ -764,7 +764,7 @@ static const char *dispatch_QueryCurrentRendererStringMESA(int attribute)
 
 
 
-static Bool dispatch_QueryMaxSwapBarriersSGIX(Display *dpy, int screen,
+static Bool dispatch_glXQueryMaxSwapBarriersSGIX(Display *dpy, int screen,
                                                  int *max)
 {
     PFNGLXQUERYMAXSWAPBARRIERSSGIXPROC pglXQueryMaxSwapBarriersSGIX;
@@ -783,7 +783,7 @@ static Bool dispatch_QueryMaxSwapBarriersSGIX(Display *dpy, int screen,
 
 
 
-static Bool dispatch_QueryRendererIntegerMESA(Display *dpy, int screen,
+static Bool dispatch_glXQueryRendererIntegerMESA(Display *dpy, int screen,
                                                  int renderer, int attribute,
                                                  unsigned int *value)
 {
@@ -803,7 +803,7 @@ static Bool dispatch_QueryRendererIntegerMESA(Display *dpy, int screen,
 
 
 
-static const char *dispatch_QueryRendererStringMESA(Display *dpy, int screen,
+static const char *dispatch_glXQueryRendererStringMESA(Display *dpy, int screen,
                                                        int renderer, int attribute)
 {
     PFNGLXQUERYRENDERERSTRINGMESAPROC pglXQueryRendererStringMESA;
@@ -822,7 +822,7 @@ static const char *dispatch_QueryRendererStringMESA(Display *dpy, int screen,
 
 
 
-static Bool dispatch_ReleaseBuffersMESA(Display *dpy, GLXDrawable d)
+static Bool dispatch_glXReleaseBuffersMESA(Display *dpy, GLXDrawable d)
 {
     PFNGLXRELEASEBUFFERSMESAPROC pglXReleaseBuffersMESA;
     __GLXvendorInfo *dd;
@@ -840,7 +840,7 @@ static Bool dispatch_ReleaseBuffersMESA(Display *dpy, GLXDrawable d)
 
 
 
-static int64_t dispatch_SwapBuffersMscOML(Display *dpy, GLXDrawable drawable,
+static int64_t dispatch_glXSwapBuffersMscOML(Display *dpy, GLXDrawable drawable,
                                              int64_t target_msc, int64_t divisor,
                                              int64_t remainder)
 {
@@ -860,7 +860,7 @@ static int64_t dispatch_SwapBuffersMscOML(Display *dpy, GLXDrawable drawable,
 
 
 
-static int dispatch_SwapIntervalMESA(unsigned int interval)
+static int dispatch_glXSwapIntervalMESA(unsigned int interval)
 {
     PFNGLXSWAPINTERVALMESAPROC pglXSwapIntervalMESA;
     __GLXvendorInfo *dd;
@@ -881,7 +881,7 @@ static int dispatch_SwapIntervalMESA(unsigned int interval)
 
 
 
-static Bool dispatch_WaitForMscOML(Display *dpy, GLXDrawable drawable,
+static Bool dispatch_glXWaitForMscOML(Display *dpy, GLXDrawable drawable,
                                       int64_t target_msc, int64_t divisor,
                                       int64_t remainder, int64_t *ust,
                                       int64_t *msc, int64_t *sbc)
@@ -902,7 +902,7 @@ static Bool dispatch_WaitForMscOML(Display *dpy, GLXDrawable drawable,
 
 
 
-static Bool dispatch_WaitForSbcOML(Display *dpy, GLXDrawable drawable,
+static Bool dispatch_glXWaitForSbcOML(Display *dpy, GLXDrawable drawable,
                                       int64_t target_sbc, int64_t *ust,
                                       int64_t *msc, int64_t *sbc)
 {
@@ -930,13 +930,10 @@ const void * const __glXDispatchFunctions[DI_LAST_INDEX + 1] = {
 
     __ATTRIB(BindTexImageEXT),
     __ATTRIB(BindTexImageEXT),
-    __ATTRIB(BindSwapBarrierSGIX),
     __ATTRIB(ChooseFBConfigSGIX),
-    __ATTRIB(CopySubBufferMESA),
     __ATTRIB(CreateContextAttribsARB),
     __ATTRIB(CreateContextWithConfigSGIX),
     __ATTRIB(CreateGLXPbufferSGIX),
-    __ATTRIB(CreateGLXPixmapMESA),
     __ATTRIB(CreateGLXPixmapWithConfigSGIX),
     __ATTRIB(DestroyGLXPbufferSGIX),
     __ATTRIB(GetContextIDEXT),
@@ -952,22 +949,24 @@ const void * const __glXDispatchFunctions[DI_LAST_INDEX + 1] = {
     __ATTRIB(SelectEventSGIX),
     __ATTRIB(SwapIntervalSGI),
     __ATTRIB(WaitVideoSyncSGI),
-
-    __ATTRIB(GetMscRateOML),
-    __ATTRIB(GetScreenDriver),
-    __ATTRIB(GetSwapIntervalMESA),
-    __ATTRIB(GetSyncValuesOML),
-    __ATTRIB(JoinSwapGroupSGIX),
-    __ATTRIB(QueryCurrentRendererIntegerMESA),
-    __ATTRIB(QueryCurrentRendererStringMESA),
-    __ATTRIB(QueryMaxSwapBarriersSGIX),
-    __ATTRIB(QueryRendererIntegerMESA),
-    __ATTRIB(QueryRendererStringMESA),
-    __ATTRIB(ReleaseBuffersMESA),
-    __ATTRIB(SwapBuffersMscOML),
-    __ATTRIB(SwapIntervalMESA),
-    __ATTRIB(WaitForMscOML),
-    __ATTRIB(WaitForSbcOML),
+    __ATTRIB(glXBindSwapBarrierSGIX),
+    __ATTRIB(glXCopySubBufferMESA),
+    __ATTRIB(glXCreateGLXPixmapMESA),
+    __ATTRIB(glXGetMscRateOML),
+    __ATTRIB(glXGetScreenDriver),
+    __ATTRIB(glXGetSwapIntervalMESA),
+    __ATTRIB(glXGetSyncValuesOML),
+    __ATTRIB(glXJoinSwapGroupSGIX),
+    __ATTRIB(glXQueryCurrentRendererIntegerMESA),
+    __ATTRIB(glXQueryCurrentRendererStringMESA),
+    __ATTRIB(glXQueryMaxSwapBarriersSGIX),
+    __ATTRIB(glXQueryRendererIntegerMESA),
+    __ATTRIB(glXQueryRendererStringMESA),
+    __ATTRIB(glXReleaseBuffersMESA),
+    __ATTRIB(glXSwapBuffersMscOML),
+    __ATTRIB(glXSwapIntervalMESA),
+    __ATTRIB(glXWaitForMscOML),
+    __ATTRIB(glXWaitForSbcOML),
 
     [DI_LAST_INDEX] = NULL,
 #undef __ATTRIB
diff --git a/src/glx/glxglvnd.c b/src/glx/glxglvnd.c
index 4d4a5b2..098304d 100644
--- a/src/glx/glxglvnd.c
+++ b/src/glx/glxglvnd.c
@@ -1,5 +1,4 @@
 #include <string.h>
-#include <stdio.h>
 #include <X11/Xlib.h>
 
 #include "glvnd/libglxabi.h"
@@ -23,12 +22,11 @@ static unsigned FindGLXFunction(const GLubyte *name)
     int first = 0;
     int last = DI_FUNCTION_COUNT - 1;
 
-    printf("Looking up %s\n", (const char *) name);
     while (first <= last) {
         int middle = (first + last) / 2;
         int comp = strcmp(__glXDispatchTableStrings[middle],
                           (const char *) name);
-        
+
         if (comp < 0)
             first = middle + 1;
         else if (comp > 0)
@@ -37,7 +35,6 @@ static unsigned FindGLXFunction(const GLubyte *name)
             return middle;
     }
 
-    printf("FAILED !!!\n");
     /* Just point to the dummy entry at the end of the respective table */
     return DI_FUNCTION_COUNT;
 }
-- 
2.9.0



More information about the mesa-dev mailing list