I swear ipers runs here after this commit.
After we flush we need to redo the space check
/* Make sure we have at least 2*1024 spare dwords. */
/* XXX It would be nice to know the number of dwords we really need to
* XXX emit. */
+again:
if (!r300->winsys->check_cs(r300->winsys, dwords)) {
r300->context.flush(&r300->context, 0, NULL);
- r300_emit_buffer_validate(r300);
+ goto again;
}
if (r300->dirty_state & R300_NEW_QUERY) {
r300_update_derived_state(r300);
+ r300_emit_buffer_validate(r300);
+
if (!r300_setup_vertex_buffers(r300)) {
return;
}
indexSize = 2;
}
- r300_emit_buffer_validate(r300);
-
if (!r300->winsys->add_buffer(r300->winsys, indexBuffer,
RADEON_GEM_DOMAIN_GTT, 0)) {
goto cleanup;