svga: Flush the hwtnl primitives before writing to buffers.
authorJosé Fonseca <jfonseca@vmware.com>
Thu, 27 Oct 2011 18:09:25 +0000 (19:09 +0100)
committerJosé Fonseca <jfonseca@vmware.com>
Mon, 31 Oct 2011 15:22:09 +0000 (15:22 +0000)
commit1e9d8934a1a56e888f07a3571038a3f9205a72ae
tree591ef7bb8913783c60f7323cc9cfa4a4242759a6
parentc04b9d1d561cc3a1300e65bd410f33dfff6fe1e0
svga: Flush the hwtnl primitives before writing to buffers.

svga keeps a small queue of similar primitive draws in order to coalesce
them into a single draw primitive command.

But the buffers referred in primitives not yet emitted were being ignored
in the considerations to flush or not the context.

This fixes piglit vbo-map-remap, vbo-subdata-sync, vbo-subdata-zero, and
Seeker.

Based on investigation and patch from Brian Paul.

Reviewed-By: Brian Paul <brianp@vmware.com>
src/gallium/drivers/svga/svga_context.c
src/gallium/drivers/svga/svga_context.h
src/gallium/drivers/svga/svga_draw.c
src/gallium/drivers/svga/svga_draw.h
src/gallium/drivers/svga/svga_resource_buffer.c