iris: Enable non coherent framebuffer fetch on broadwell

v2: Use GEN_GEN in iris_state (Kenneth Graunke)

Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Sagar Ghuge 2019-07-16 11:29:47 -07:00 committed by Kenneth Graunke
parent 57ce422e20
commit fe0e9db797
3 changed files with 3 additions and 4 deletions

View File

@ -2131,7 +2131,7 @@ iris_create_fs_state(struct pipe_context *ctx,
struct brw_wm_prog_key key = {
KEY_INIT(devinfo->gen),
.nr_color_regions = util_bitcount(color_outputs),
.coherent_fb_fetch = true,
.coherent_fb_fetch = devinfo->gen >= 9,
.input_slots_valid =
can_rearrange_varyings ? 0 : info->inputs_read | VARYING_BIT_POS,
};

View File

@ -202,8 +202,7 @@ iris_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
case PIPE_CAP_SHADER_SAMPLES_IDENTICAL:
return true;
case PIPE_CAP_FBFETCH:
/* TODO: Support non-coherent FB fetch on Broadwell */
return devinfo->gen >= 9 ? BRW_MAX_DRAW_BUFFERS : 0;
return BRW_MAX_DRAW_BUFFERS;
case PIPE_CAP_FBFETCH_COHERENT:
case PIPE_CAP_CONSERVATIVE_RASTER_INNER_COVERAGE:
case PIPE_CAP_POST_DEPTH_COVERAGE:

View File

@ -3624,7 +3624,7 @@ iris_populate_fs_key(const struct iris_context *ice,
key->persample_interp = rast->force_persample_interp;
key->multisample_fbo = rast->multisample && fb->samples > 1;
key->coherent_fb_fetch = true;
key->coherent_fb_fetch = GEN_GEN >= 9;
key->force_dual_color_blend =
screen->driconf.dual_color_blend_by_location &&