summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/i810/i810span.c33
-rw-r--r--src/mesa/drivers/dri/i810/i810span.h3
2 files changed, 26 insertions, 10 deletions
diff --git a/src/mesa/drivers/dri/i810/i810span.c b/src/mesa/drivers/dri/i810/i810span.c
index dc8f4d1cb9..53bd15162f 100644
--- a/src/mesa/drivers/dri/i810/i810span.c
+++ b/src/mesa/drivers/dri/i810/i810span.c
@@ -14,6 +14,7 @@
#define DBG 0
#define LOCAL_VARS \
+ i810ContextPtr imesa = I810_CONTEXT(ctx); \
__DRIdrawablePrivate *dPriv = imesa->driDrawable; \
i810ScreenPrivate *i810Screen = imesa->i810Screen; \
GLuint pitch = i810Screen->backPitch; \
@@ -28,6 +29,7 @@
(void) read_buf; (void) buf; (void) p
#define LOCAL_DEPTH_VARS \
+ i810ContextPtr imesa = I810_CONTEXT(ctx); \
__DRIdrawablePrivate *dPriv = imesa->driDrawable; \
i810ScreenPrivate *i810Screen = imesa->i810Screen; \
GLuint pitch = i810Screen->backPitch; \
@@ -55,11 +57,7 @@
#define Y_FLIP(_y) (height - _y - 1)
-#define HW_LOCK() \
- i810ContextPtr imesa = I810_CONTEXT(ctx); \
- I810_FIREVERTICES(imesa); \
- i810DmaFinish(imesa); \
- LOCK_HARDWARE_QUIESCENT(imesa);
+#define HW_LOCK()
#define HW_CLIPLOOP() \
do { \
@@ -76,11 +74,7 @@
} \
} while (0)
-#define HW_UNLOCK() \
- UNLOCK_HARDWARE(imesa);
-
-
-
+#define HW_UNLOCK()
/* 16 bit, 565 rgb color spanline and pixel functions
*/
@@ -148,6 +142,22 @@ static void i810SetBuffer(GLcontext *ctx, GLframebuffer *buffer,
imesa->drawMap = imesa->readMap;
}
+/* Move locking out to get reasonable span performance.
+ */
+void i810SpanRenderStart( GLcontext *ctx )
+{
+ i810ContextPtr imesa = I810_CONTEXT(ctx);
+ I810_FIREVERTICES(imesa);
+ LOCK_HARDWARE(imesa);
+ i810RegetLockQuiescent( imesa );
+}
+
+void i810SpanRenderFinish( GLcontext *ctx )
+{
+ i810ContextPtr imesa = I810_CONTEXT( ctx );
+ _swrast_flush( ctx );
+ UNLOCK_HARDWARE( imesa );
+}
void i810InitSpanFuncs( GLcontext *ctx )
{
@@ -167,4 +177,7 @@ void i810InitSpanFuncs( GLcontext *ctx )
swdd->WriteDepthSpan = i810WriteDepthSpan_16;
swdd->ReadDepthPixels = i810ReadDepthPixels_16;
swdd->WriteDepthPixels = i810WriteDepthPixels_16;
+
+ swdd->SpanRenderStart = i810SpanRenderStart;
+ swdd->SpanRenderFinish = i810SpanRenderFinish;
}
diff --git a/src/mesa/drivers/dri/i810/i810span.h b/src/mesa/drivers/dri/i810/i810span.h
index a7b809bf18..545bce46a6 100644
--- a/src/mesa/drivers/dri/i810/i810span.h
+++ b/src/mesa/drivers/dri/i810/i810span.h
@@ -3,4 +3,7 @@
extern void i810InitSpanFuncs( GLcontext *ctx );
+extern void i810SpanRenderFinish( GLcontext *ctx );
+extern void i810SpanRenderStart( GLcontext *ctx );
+
#endif