sbuf.buffer_offset = qbuf->head;
sbuf.buffer_size = sizeof(struct gfx10_sh_query_buffer_mem);
si_set_rw_shader_buffer(sctx, GFX10_GS_QUERY_BUF, &sbuf);
sbuf.buffer_offset = qbuf->head;
sbuf.buffer_size = sizeof(struct gfx10_sh_query_buffer_mem);
si_set_rw_shader_buffer(sctx, GFX10_GS_QUERY_BUF, &sbuf);
gfx10_alloc_query_buffer(sctx);
} else {
si_set_rw_shader_buffer(sctx, GFX10_GS_QUERY_BUF, NULL);
gfx10_alloc_query_buffer(sctx);
} else {
si_set_rw_shader_buffer(sctx, GFX10_GS_QUERY_BUF, NULL);
/* If a query_begin is followed by a query_end without a draw
* in-between, we need to clear the atom to ensure that the
/* If a query_begin is followed by a query_end without a draw
* in-between, we need to clear the atom to ensure that the