diff options
author | Carl Worth <cworth@cworth.org> | 2008-07-07 15:58:27 -0700 |
---|---|---|
committer | Carl Worth <you@yourdomain.example.com> | 2008-07-12 08:15:08 -0700 |
commit | 757c00927a6f5760135136450b8d02d0f999ac1c (patch) | |
tree | 1cbfc7ce7b8d1054ba8d31e8fa78893265b3dc7d /src | |
parent | 0c548cd040d0c5e1812470ccdf6de86b6a2926d7 (diff) |
Use up to 256 separate vertex buffers
This allows us to only call i830WaitSync once every 128 calls to composite
rather than on every call. However, we do need to also call MI_FLUSH to
avoid the vertex cache getting in our way, (since our "separate" buffers
are all allocated as one contiguous chunk).
Diffstat (limited to 'src')
-rw-r--r-- | src/i965_render.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/i965_render.c b/src/i965_render.c index 3c7379c3..1cbfe242 100644 --- a/src/i965_render.c +++ b/src/i965_render.c @@ -60,7 +60,7 @@ do { \ #endif #define MAX_VERTEX_PER_COMPOSITE 24 -#define MAX_VERTEX_BUFFERS 1 +#define MAX_VERTEX_BUFFERS 256 struct blendinfo { Bool dst_alpha; @@ -1401,7 +1401,8 @@ i965_composite(PixmapPtr pDst, int srcX, int srcY, int maskX, int maskY, } assert (i * 4 <= sizeof(card_state->vb)); - BEGIN_BATCH(11); + BEGIN_BATCH(12); + OUT_BATCH(MI_FLUSH); /* Set up the pointer to our (single) vertex buffer */ OUT_BATCH(BRW_3DSTATE_VERTEX_BUFFERS | 3); OUT_BATCH((0 << VB0_BUFFER_INDEX_SHIFT) | |