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

Author: Paul Berry <stereotype...@gmail.com>
Date:   Fri Dec 23 13:56:07 2011 -0800

i965 gen6: Fix incorrect order of dwords in gen6_update_sol_indices()

When updating SOL indices, we were accidentally putting the starting
index in dword 1 and the SVBI number to increment in dword 2--these
should be reversed.  Usually both of these values are zero, so we
didn't see any problem.  However, if a transform feedback operation
spans multiple batch buffers, the starting index will be nonzero.

Fixes piglit test "EXT_transform_feedback/intervening-read output".

Reviewed-by: Kenneth Graunke <kenn...@whitecape.org>

---

 src/mesa/drivers/dri/i965/gen6_sol.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/gen6_sol.c 
b/src/mesa/drivers/dri/i965/gen6_sol.c
index 437b3ae..f724802 100644
--- a/src/mesa/drivers/dri/i965/gen6_sol.c
+++ b/src/mesa/drivers/dri/i965/gen6_sol.c
@@ -82,8 +82,8 @@ gen6_update_sol_indices(struct brw_context *brw)
 
    BEGIN_BATCH(4);
    OUT_BATCH(_3DSTATE_GS_SVB_INDEX << 16 | (4 - 2));
-   OUT_BATCH(brw->sol.svbi_0_starting_index); /* BRW_NEW_SOL_INDICES */
    OUT_BATCH(0);
+   OUT_BATCH(brw->sol.svbi_0_starting_index); /* BRW_NEW_SOL_INDICES */
    OUT_BATCH(brw->sol.svbi_0_max_index); /* BRW_NEW_SOL_INDICES */
    ADVANCE_BATCH();
 }

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

Reply via email to