glapi: rename u_current dispatch table functions

Put "table" in the names to make things more understandable.

Reviewed-by: Chia-I Wu <olv@lunarg.com>
This commit is contained in:
Brian Paul
2014-03-05 07:47:41 -07:00
parent 280e065707
commit 846a7e8630
6 changed files with 13 additions and 13 deletions
+2 -2
View File
@@ -36,7 +36,7 @@
#ifdef MAPI_MODE_BRIDGE
#define ENTRY_CURRENT_TABLE_GET "_glapi_get_dispatch"
#else
#define ENTRY_CURRENT_TABLE_GET U_STRINGIFY(u_current_get_internal)
#define ENTRY_CURRENT_TABLE_GET U_STRINGIFY(u_current_get_table_internal)
#endif
#if defined(USE_X86_ASM) && defined(__GNUC__)
@@ -57,7 +57,7 @@ entry_current_get(void)
#ifdef MAPI_MODE_BRIDGE
return GET_DISPATCH();
#else
return u_current_get();
return u_current_get_table();
#endif
}
+1 -1
View File
@@ -60,5 +60,5 @@ _glapi_set_context(void *context)
void
_glapi_set_dispatch(struct _glapi_table *dispatch)
{
u_current_set((const struct mapi_table *) dispatch);
u_current_set_table((const struct mapi_table *) dispatch);
}
+1 -1
View File
@@ -186,5 +186,5 @@ mapi_table_fill(struct mapi_table *tbl, const mapi_proc *procs)
void
mapi_table_make_current(const struct mapi_table *tbl)
{
u_current_set(tbl);
u_current_set_table(tbl);
}
+1 -1
View File
@@ -64,7 +64,7 @@ _glapi_set_context(void *context)
void
_glapi_set_dispatch(struct _glapi_table *dispatch)
{
u_current_set((const struct mapi_table *) dispatch);
u_current_set_table((const struct mapi_table *) dispatch);
}
/**
+3 -3
View File
@@ -168,7 +168,7 @@ u_current_init(void)
}
else if (knownID != u_thread_self()) {
ThreadSafe = 1;
u_current_set(NULL);
u_current_set_table(NULL);
u_current_set_context(NULL);
}
u_mutex_unlock(ThreadCheckMutex);
@@ -230,7 +230,7 @@ u_current_get_context_internal(void)
* table (__glapi_noop_table).
*/
void
u_current_set(const struct mapi_table *tbl)
u_current_set_table(const struct mapi_table *tbl)
{
u_current_init();
@@ -253,7 +253,7 @@ u_current_set(const struct mapi_table *tbl)
* Return pointer to current dispatch table for calling thread.
*/
struct mapi_table *
u_current_get_internal(void)
u_current_get_table_internal(void)
{
#if defined(GLX_USE_TLS)
return u_current_table;
+5 -5
View File
@@ -17,7 +17,7 @@
#define u_current_context _glapi_Context
#endif
#define u_current_get_internal _glapi_get_dispatch
#define u_current_get_table_internal _glapi_get_dispatch
#define u_current_get_context_internal _glapi_get_context
#define u_current_table_tsd _gl_DispatchTSD
@@ -52,10 +52,10 @@ void
u_current_destroy(void);
void
u_current_set(const struct mapi_table *tbl);
u_current_set_table(const struct mapi_table *tbl);
struct mapi_table *
u_current_get_internal(void);
u_current_get_table_internal(void);
void
u_current_set_context(const void *ptr);
@@ -64,13 +64,13 @@ void *
u_current_get_context_internal(void);
static INLINE const struct mapi_table *
u_current_get(void)
u_current_get_table(void)
{
#ifdef GLX_USE_TLS
return u_current_table;
#else
return (likely(u_current_table) ?
u_current_table : u_current_get_internal());
u_current_table : u_current_get_table_internal());
#endif
}