Mesa (master): i965: remove disabled code for cycling through MRF registers in clipping.

Eric Anholt anholt at kemper.freedesktop.org
Thu May 20 20:43:37 UTC 2010


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

Author: Eric Anholt <eric at anholt.net>
Date:   Tue May 18 15:27:10 2010 -0700

i965: remove disabled code for cycling through MRF registers in clipping.

The idea would be that you could have multiple send messages going on
if nothing depended on the previous message's results and you used a
different send message.  The problem is that the later send requires
the VUE handle returned by the first send's allocate anyway.

---

 src/mesa/drivers/dri/i965/brw_clip.h      |    2 --
 src/mesa/drivers/dri/i965/brw_clip_util.c |   17 ++---------------
 2 files changed, 2 insertions(+), 17 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_clip.h b/src/mesa/drivers/dri/i965/brw_clip.h
index d71bac7..68222c6 100644
--- a/src/mesa/drivers/dri/i965/brw_clip.h
+++ b/src/mesa/drivers/dri/i965/brw_clip.h
@@ -114,8 +114,6 @@ struct brw_clip_compile {
 
    GLboolean need_direction;
 
-   GLuint last_mrf;
-
    GLuint header_position_offset;
    GLuint offset[VERT_ATTRIB_MAX];
 };
diff --git a/src/mesa/drivers/dri/i965/brw_clip_util.c b/src/mesa/drivers/dri/i965/brw_clip_util.c
index a730664..2148bc8 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_util.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_util.c
@@ -211,27 +211,14 @@ void brw_clip_emit_vue(struct brw_clip_compile *c,
 		       GLuint header)
 {
    struct brw_compile *p = &c->func;
-   GLuint start = c->last_mrf;
 
    brw_clip_ff_sync(c);
 
    assert(!(allocate && eot));
-   
-   /* Cycle through mrf regs - probably futile as we have to wait for
-    * the allocation response anyway.  Also, the order this function
-    * is invoked doesn't correspond to the order the instructions will
-    * be executed, so it won't have any effect in many cases.
-    */
-#if 0
-   if (start + c->nr_regs + 1 >= MAX_MRF)
-      start = 0;
 
-   c->last_mrf = start + c->nr_regs + 1;
-#endif
-	
    /* Copy the vertex from vertn into m1..mN+1:
     */
-   brw_copy_from_indirect(p, brw_message_reg(start+1), vert, c->nr_regs);
+   brw_copy_from_indirect(p, brw_message_reg(1), vert, c->nr_regs);
 
    /* Overwrite PrimType and PrimStart in the message header, for
     * each vertex in turn:
@@ -247,7 +234,7 @@ void brw_clip_emit_vue(struct brw_clip_compile *c,
     */
    brw_urb_WRITE(p, 
 		 allocate ? c->reg.R0 : retype(brw_null_reg(), BRW_REGISTER_TYPE_UD),
-		 start,
+		 0,
 		 c->reg.R0,
 		 allocate,
 		 1,		/* used */




More information about the mesa-commit mailing list