summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2013-01-17 16:49:57 -0800
committerEric Anholt <eric@anholt.net>2013-01-21 21:26:48 -0800
commitbe4b1664fbc98b0b1d66bb91850ecada52b36b91 (patch)
treed15160bacacfeecdae2832791df37ca593ef754b /src/mesa
parentced98f17efc73c313700bbf936f7258131037ef3 (diff)
mesa: Make the drivers call a non-code-generated dispatch table setup.
I want to drive the Save dispatch table setup from this same function. Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i915/i830_context.c2
-rw-r--r--src/mesa/drivers/dri/i915/i915_context.c2
-rw-r--r--src/mesa/drivers/dri/i965/brw_context.c2
-rw-r--r--src/mesa/drivers/dri/nouveau/nouveau_context.c2
-rw-r--r--src/mesa/drivers/dri/r200/r200_context.c2
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_context.c2
-rw-r--r--src/mesa/drivers/dri/swrast/swrast.c2
-rw-r--r--src/mesa/drivers/osmesa/osmesa.c2
-rw-r--r--src/mesa/drivers/windows/gdi/wmesa.c2
-rw-r--r--src/mesa/drivers/x11/xm_api.c2
-rw-r--r--src/mesa/main/api_exec.h2
-rw-r--r--src/mesa/main/context.c7
-rw-r--r--src/mesa/main/tests/dispatch_sanity.cpp2
-rw-r--r--src/mesa/state_tracker/st_context.c2
14 files changed, 21 insertions, 12 deletions
diff --git a/src/mesa/drivers/dri/i915/i830_context.c b/src/mesa/drivers/dri/i915/i830_context.c
index 288dfcc774a..524e7cba384 100644
--- a/src/mesa/drivers/dri/i915/i830_context.c
+++ b/src/mesa/drivers/dri/i915/i830_context.c
@@ -126,7 +126,7 @@ i830CreateContext(int api,
_mesa_compute_version(ctx);
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
return true;
diff --git a/src/mesa/drivers/dri/i915/i915_context.c b/src/mesa/drivers/dri/i915/i915_context.c
index 75a1a2c39b8..133f339321f 100644
--- a/src/mesa/drivers/dri/i915/i915_context.c
+++ b/src/mesa/drivers/dri/i915/i915_context.c
@@ -278,7 +278,7 @@ i915CreateContext(int api,
_mesa_compute_version(ctx);
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
return true;
diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
index 7b53360a381..1201565745d 100644
--- a/src/mesa/drivers/dri/i965/brw_context.c
+++ b/src/mesa/drivers/dri/i965/brw_context.c
@@ -379,7 +379,7 @@ brwCreateContext(int api,
_mesa_compute_version(ctx);
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
return true;
diff --git a/src/mesa/drivers/dri/nouveau/nouveau_context.c b/src/mesa/drivers/dri/nouveau/nouveau_context.c
index 8811562dfa8..b216c60a277 100644
--- a/src/mesa/drivers/dri/nouveau/nouveau_context.c
+++ b/src/mesa/drivers/dri/nouveau/nouveau_context.c
@@ -106,7 +106,7 @@ nouveau_context_create(gl_api api,
}
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
if (nouveau_bo_new(context_dev(ctx), NOUVEAU_BO_VRAM, 0, 4096,
diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c
index cf35079b245..1e0239b4e53 100644
--- a/src/mesa/drivers/dri/r200/r200_context.c
+++ b/src/mesa/drivers/dri/r200/r200_context.c
@@ -462,7 +462,7 @@ GLboolean r200CreateContext( gl_api api,
_mesa_compute_version(ctx);
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
*error = __DRI_CTX_ERROR_SUCCESS;
diff --git a/src/mesa/drivers/dri/radeon/radeon_context.c b/src/mesa/drivers/dri/radeon/radeon_context.c
index 26490ea4e04..f81e81f49a6 100644
--- a/src/mesa/drivers/dri/radeon/radeon_context.c
+++ b/src/mesa/drivers/dri/radeon/radeon_context.c
@@ -415,7 +415,7 @@ r100CreateContext( gl_api api,
_mesa_compute_version(ctx);
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
*error = __DRI_CTX_ERROR_SUCCESS;
diff --git a/src/mesa/drivers/dri/swrast/swrast.c b/src/mesa/drivers/dri/swrast/swrast.c
index 33420f78d6a..96382718a8e 100644
--- a/src/mesa/drivers/dri/swrast/swrast.c
+++ b/src/mesa/drivers/dri/swrast/swrast.c
@@ -791,7 +791,7 @@ dri_create_context(gl_api api,
_mesa_compute_version(mesaCtx);
- _mesa_initialize_exec_table(mesaCtx);
+ _mesa_initialize_dispatch_tables(mesaCtx);
_mesa_initialize_vbo_vtxfmt(mesaCtx);
*error = __DRI_CTX_ERROR_SUCCESS;
diff --git a/src/mesa/drivers/osmesa/osmesa.c b/src/mesa/drivers/osmesa/osmesa.c
index 5965d7d30e6..755f371611e 100644
--- a/src/mesa/drivers/osmesa/osmesa.c
+++ b/src/mesa/drivers/osmesa/osmesa.c
@@ -793,7 +793,7 @@ OSMesaCreateContextExt( GLenum format, GLint depthBits, GLint stencilBits,
_mesa_compute_version(ctx);
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
}
}
diff --git a/src/mesa/drivers/windows/gdi/wmesa.c b/src/mesa/drivers/windows/gdi/wmesa.c
index b76c0edda63..48c6661b001 100644
--- a/src/mesa/drivers/windows/gdi/wmesa.c
+++ b/src/mesa/drivers/windows/gdi/wmesa.c
@@ -642,7 +642,7 @@ WMesaContext WMesaCreateContext(HDC hDC,
_mesa_compute_version(ctx);
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
return c;
diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c
index 2ba65ffd787..f0c5957f089 100644
--- a/src/mesa/drivers/x11/xm_api.c
+++ b/src/mesa/drivers/x11/xm_api.c
@@ -967,7 +967,7 @@ XMesaContext XMesaCreateContext( XMesaVisual v, XMesaContext share_list )
_mesa_compute_version(mesaCtx);
/* Exec table initialization requires the version to be computed */
- _mesa_initialize_exec_table(mesaCtx);
+ _mesa_initialize_dispatch_tables(mesaCtx);
_mesa_initialize_vbo_vtxfmt(mesaCtx);
return c;
diff --git a/src/mesa/main/api_exec.h b/src/mesa/main/api_exec.h
index bf3faa153c7..94f7f41c14c 100644
--- a/src/mesa/main/api_exec.h
+++ b/src/mesa/main/api_exec.h
@@ -36,5 +36,7 @@ _mesa_alloc_dispatch_table(void);
extern void
_mesa_initialize_exec_table(struct gl_context *ctx);
+extern void
+_mesa_initialize_dispatch_tables(struct gl_context *ctx);
#endif
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 1f06b53f571..1c917e75a49 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -933,6 +933,13 @@ create_beginend_table(const struct gl_context *ctx)
return table;
}
+void
+_mesa_initialize_dispatch_tables(struct gl_context *ctx)
+{
+ /* Do the code-generated setup of the exec table in api_exec.c. */
+ _mesa_initialize_exec_table(ctx);
+}
+
/**
* Initialize a struct gl_context struct (rendering context).
*
diff --git a/src/mesa/main/tests/dispatch_sanity.cpp b/src/mesa/main/tests/dispatch_sanity.cpp
index 5e1a7b55edc..399b9a5c640 100644
--- a/src/mesa/main/tests/dispatch_sanity.cpp
+++ b/src/mesa/main/tests/dispatch_sanity.cpp
@@ -113,7 +113,7 @@ DispatchSanity_test::SetUpCtx(gl_api api, unsigned int version)
ctx.Version = version;
- _mesa_initialize_exec_table(&ctx);
+ _mesa_initialize_dispatch_tables(&ctx);
_mesa_initialize_vbo_vtxfmt(&ctx);
}
diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c
index 368a30b6871..b416319e1cb 100644
--- a/src/mesa/state_tracker/st_context.c
+++ b/src/mesa/state_tracker/st_context.c
@@ -189,7 +189,7 @@ st_create_context_priv( struct gl_context *ctx, struct pipe_context *pipe,
_mesa_compute_version(ctx);
- _mesa_initialize_exec_table(ctx);
+ _mesa_initialize_dispatch_tables(ctx);
_mesa_initialize_vbo_vtxfmt(ctx);
return st;