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

Author: Eric Anholt <e...@anholt.net>
Date:   Wed Mar 10 13:51:24 2010 -0800

i965: Set up the execution size before relying on it.

Fixes hangs with texturing in the non-GLSL path since
f6d210c284751ac50a8d6358de7e75a1ff1e4ac7

---

 src/mesa/drivers/dri/i965/brw_eu_emit.c |   12 +++++++-----
 1 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_eu_emit.c 
b/src/mesa/drivers/dri/i965/brw_eu_emit.c
index 40c1b71..82f2fda 100644
--- a/src/mesa/drivers/dri/i965/brw_eu_emit.c
+++ b/src/mesa/drivers/dri/i965/brw_eu_emit.c
@@ -1290,10 +1290,6 @@ void brw_SAMPLE(struct brw_compile *p,
                GLuint simd_mode)
 {
    GLboolean need_stall = 0;
-   GLboolean dispatch_16 = GL_FALSE;
-
-   if (p->current->header.execution_size == BRW_EXECUTE_16)
-      dispatch_16 = GL_TRUE;
 
    if (writemask == 0) {
       /*printf("%s: zero writemask??\n", __FUNCTION__); */
@@ -1331,8 +1327,14 @@ void brw_SAMPLE(struct brw_compile *p,
          /* printf("need stall %x %x\n", newmask , writemask); */
       }
       else {
+        GLboolean dispatch_16 = GL_FALSE;
+
         struct brw_reg m1 = brw_message_reg(msg_reg_nr);
-        
+
+        guess_execution_size(p->current, dest);
+        if (p->current->header.execution_size == BRW_EXECUTE_16)
+           dispatch_16 = GL_TRUE;
+
         newmask = ~newmask & WRITEMASK_XYZW;
 
         brw_push_insn_state(p);

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to