From d1be67db39463b48369cb71979ed18662b2c157e Mon Sep 17 00:00:00 2001 From: Lionel Landwerlin Date: Thu, 18 Apr 2019 11:57:57 +0100 Subject: iris: implement WaEnableStateCacheRedirectToCS This 3d performance workaround was initially put in the kernel but the media driver requires different settings so the register has been whitelisted in i915 [1] and userspace drivers are left initializing it as they wish. [1] : https://patchwork.freedesktop.org/series/59494/ Signed-off-by: Lionel Landwerlin Reviewed-by: Anuj Phogat --- src/gallium/drivers/iris/iris_state.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/gallium/drivers/iris') diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c index 8d5383598d2..2c85ba3778a 100644 --- a/src/gallium/drivers/iris/iris_state.c +++ b/src/gallium/drivers/iris/iris_state.c @@ -721,6 +721,13 @@ iris_init_render_context(struct iris_screen *screen, } iris_emit_lri(batch, COMMON_SLICE_CHICKEN3, reg_val); + iris_pack_state(GENX(SLICE_COMMON_ECO_CHICKEN1), ®_val, reg) { + reg.StateCacheRedirectToCSSectionEnable = true; + reg.StateCacheRedirectToCSSectionEnableMask = true; + } + iris_emit_lri(batch, SLICE_COMMON_ECO_CHICKEN1, reg_val); + + // XXX: 3D_MODE? #endif -- cgit v1.2.3