[Mesa-dev] [PATCH] i965: Fix symbolic size of next_offset[] array.
Kenneth Graunke
kenneth at whitecape.org
Wed Mar 1 01:04:00 UTC 2017
It's indexed by buffer, not stream. BRW_MAX_SOL_BUFFERS and
MAX_VERTEX_STREAMS happen to both be 4, so there's no actual bug.
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/mesa/drivers/dri/i965/gen7_sol_state.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/gen7_sol_state.c b/src/mesa/drivers/dri/i965/gen7_sol_state.c
index d3dcf49a36d..ca96da5d9e5 100644
--- a/src/mesa/drivers/dri/i965/gen7_sol_state.c
+++ b/src/mesa/drivers/dri/i965/gen7_sol_state.c
@@ -106,7 +106,7 @@ gen7_upload_3dstate_so_decl_list(struct brw_context *brw,
xfb_obj->program->sh.LinkedTransformFeedback;
uint16_t 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 next_offset[BRW_MAX_SOL_BUFFERS] = {0, 0, 0, 0};
int decls[MAX_VERTEX_STREAMS] = {0, 0, 0, 0};
int max_decls = 0;
STATIC_ASSERT(ARRAY_SIZE(so_decl[0]) >= MAX_PROGRAM_OUTPUTS);
--
2.11.1
More information about the mesa-dev
mailing list