From: Kenneth Graunke Date: Fri, 7 Sep 2018 19:26:55 +0000 (-0700) Subject: iris: fix constant buffer 0 to be absolute X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=938afd484a5f9cb003eb4a2406be8ea1894e2cd6;p=mesa.git iris: fix constant buffer 0 to be absolute thanks to Jason for catching this. Fixes some va64 tests. Surprisingly not much else, as apparently getting to UBO range 4 is uncommon! --- diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c index cfdd69bdde2..5472ff57fca 100644 --- a/src/gallium/drivers/iris/iris_state.c +++ b/src/gallium/drivers/iris/iris_state.c @@ -498,6 +498,17 @@ iris_init_render_context(struct iris_screen *screen, sba.DynamicStateBufferSize = 0xfffff; } + // XXX: INSTPM on Gen8 + uint32_t reg_val; + iris_pack_state(GENX(CS_DEBUG_MODE2), ®_val, reg) { + reg.CONSTANT_BUFFERAddressOffsetDisable = true; + reg.CONSTANT_BUFFERAddressOffsetDisableMask = true; + } + iris_emit_cmd(batch, GENX(MI_LOAD_REGISTER_IMM), lri) { + lri.RegisterOffset = GENX(CS_DEBUG_MODE2_num); + lri.DataDWord = reg_val; + } + /* 3DSTATE_DRAWING_RECTANGLE is non-pipelined, so we want to avoid * changing it dynamically. We set it to the maximum size here, and * instead include the render target dimensions in the viewport, so