From b18e68fc252db7df33fdf2d08d77c5ba3b17f209 Mon Sep 17 00:00:00 2001 From: Francisco Jerez Date: Wed, 24 Aug 2022 11:33:26 -0700 Subject: [PATCH] blorp: Allocate fixed amount of space for blend state. According to the simulator a cacheline of the blend state cache corresponds to 3 cachelines of L3 that are always filled regardless of the number of render targets in use. Allocate enough space to avoid pagefaults under simulation, since a scratch page isn't bound by default. Reviewed-by: Ian Romanick Part-of: --- src/intel/blorp/blorp_genX_exec_brw.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/intel/blorp/blorp_genX_exec_brw.h b/src/intel/blorp/blorp_genX_exec_brw.h index 6c435e9bbdee6..c20c2c1cd6de7 100644 --- a/src/intel/blorp/blorp_genX_exec_brw.h +++ b/src/intel/blorp/blorp_genX_exec_brw.h @@ -886,8 +886,7 @@ blorp_emit_blend_state(struct blorp_batch *batch, if (!batch->blorp->config.use_cached_dynamic_states) { struct GENX(BLEND_STATE) blend = { }; - int size = GENX(BLEND_STATE_length) * 4; - size += GENX(BLEND_STATE_ENTRY_length) * 4 * params->num_draw_buffers; + const unsigned size = 96; uint32_t *state = blorp_alloc_dynamic_state(batch, size, 64, &offset); if (state == NULL) return;