i965/gen6: Fix assertions on VS/GS URB size.
authorPaul Berry <stereotype441@gmail.com>
Tue, 3 Sep 2013 21:19:18 +0000 (14:19 -0700)
committerPaul Berry <stereotype441@gmail.com>
Mon, 16 Sep 2013 19:53:52 +0000 (12:53 -0700)
The "{VS,GS} URB Entry Allocation Size" fields of 3DSTATE_URB allow
values in the range 0-4, but they are U8-1 fields, so the range of
possible allocation sizes is 1-5.  We were erroneously prohibiting a
size of 5.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/gen6_urb.c

index bb4cfa80a49da222ea868f9ef93efba1c135697f..b694f5d189c0ee7b566d22b7d8febf9b8b13bd99 100644 (file)
@@ -86,8 +86,8 @@ gen6_upload_urb( struct brw_context *brw )
    assert(brw->urb.nr_vs_entries >= brw->urb.min_vs_entries);
    assert(brw->urb.nr_vs_entries % 4 == 0);
    assert(brw->urb.nr_gs_entries % 4 == 0);
-   assert(vs_size < 5);
-   assert(gs_size < 5);
+   assert(vs_size <= 5);
+   assert(gs_size <= 5);
 
    BEGIN_BATCH(3);
    OUT_BATCH(_3DSTATE_URB << 16 | (3 - 2));