diff --git a/src/gallium/drivers/crocus/crocus_query.c b/src/gallium/drivers/crocus/crocus_query.c index 677affd7513..f0e3a013f6b 100644 --- a/src/gallium/drivers/crocus/crocus_query.c +++ b/src/gallium/drivers/crocus/crocus_query.c @@ -338,7 +338,7 @@ calculate_result_on_cpu(const struct intel_device_info *devinfo, break; case PIPE_QUERY_SO_OVERFLOW_ANY_PREDICATE: q->result = false; - for (int i = 0; i < MAX_VERTEX_STREAMS; i++) + for (int i = 0; i < PIPE_MAX_VERTEX_STREAMS; i++) q->result |= stream_overflowed((void *) q->map, i); break; case PIPE_QUERY_PIPELINE_STATISTICS_SINGLE: @@ -385,12 +385,12 @@ calc_overflow_for_stream(struct mi_builder *b, static struct mi_value calc_overflow_any_stream(struct mi_builder *b, struct crocus_query *q) { - struct mi_value stream_result[MAX_VERTEX_STREAMS]; - for (int i = 0; i < MAX_VERTEX_STREAMS; i++) + struct mi_value stream_result[PIPE_MAX_VERTEX_STREAMS]; + for (int i = 0; i < PIPE_MAX_VERTEX_STREAMS; i++) stream_result[i] = calc_overflow_for_stream(b, q, i); struct mi_value result = stream_result[0]; - for (int i = 1; i < MAX_VERTEX_STREAMS; i++) + for (int i = 1; i < PIPE_MAX_VERTEX_STREAMS; i++) result = mi_ior(b, result, stream_result[i]); return result; diff --git a/src/gallium/drivers/crocus/crocus_state.c b/src/gallium/drivers/crocus/crocus_state.c index 74549291a81..6c4b6b0fb7f 100644 --- a/src/gallium/drivers/crocus/crocus_state.c +++ b/src/gallium/drivers/crocus/crocus_state.c @@ -4275,12 +4275,12 @@ static uint32_t * crocus_create_so_decl_list(const struct pipe_stream_output_info *info, const struct brw_vue_map *vue_map) { - struct GENX(SO_DECL) so_decl[MAX_VERTEX_STREAMS][128]; - int buffer_mask[MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; - int next_offset[MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; - int decls[MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; + struct GENX(SO_DECL) so_decl[PIPE_MAX_VERTEX_STREAMS][128]; + int buffer_mask[PIPE_MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; + int next_offset[PIPE_MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; + int decls[PIPE_MAX_VERTEX_STREAMS] = {0, 0, 0, 0}; int max_decls = 0; - STATIC_ASSERT(ARRAY_SIZE(so_decl[0]) >= MAX_PROGRAM_OUTPUTS); + STATIC_ASSERT(ARRAY_SIZE(so_decl[0]) >= PIPE_MAX_SO_OUTPUTS); memset(so_decl, 0, sizeof(so_decl)); @@ -4292,7 +4292,7 @@ crocus_create_so_decl_list(const struct pipe_stream_output_info *info, const int buffer = output->output_buffer; const int varying = output->register_index; const unsigned stream_id = output->stream; - assert(stream_id < MAX_VERTEX_STREAMS); + assert(stream_id < PIPE_MAX_VERTEX_STREAMS); buffer_mask[stream_id] |= 1 << buffer;