iris: shorten loop

num_ubos doesn't include Tim's magic UBO for regular uniforms, so +1
This commit is contained in:
Kenneth Graunke
2018-07-24 16:11:37 -07:00
parent bf795b0244
commit fd5ed7b46b

View File

@@ -2672,8 +2672,7 @@ iris_populate_binding_table(struct iris_context *ice,
: use_null_surface(batch, ice);
}
// XXX: want the number of BTE's to shorten this loop
for (int i = 0; i < PIPE_MAX_CONSTANT_BUFFERS; i++) {
for (int i = 0; i < 1 + info->num_ubos; i++) {
struct iris_const_buffer *cbuf = &shs->constbuf[i];
if (!cbuf->surface_state.res)
break;