From: Nicolai Hähnle Date: Wed, 6 Jul 2016 12:26:47 +0000 (+0200) Subject: r600g: call cayman_emit_msaa_sample_locs only when needed X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7d2ce5258f279ec22e86ee772f257756f5314423;p=mesa.git r600g: call cayman_emit_msaa_sample_locs only when needed In the case of nr_samples <= 1, that function is (currently) a no-op anyway. Reviewed-by: Marek Olšák --- diff --git a/src/gallium/drivers/r600/evergreen_state.c b/src/gallium/drivers/r600/evergreen_state.c index fe4f14c5e4f..463dc1517d9 100644 --- a/src/gallium/drivers/r600/evergreen_state.c +++ b/src/gallium/drivers/r600/evergreen_state.c @@ -1654,7 +1654,8 @@ static void evergreen_emit_framebuffer_state(struct r600_context *rctx, struct r EG_S_028A4C_FORCE_EOV_CNTDWN_ENABLE(1) | EG_S_028A4C_FORCE_EOV_REZ_ENABLE(1); - cayman_emit_msaa_sample_locs(cs, rctx->framebuffer.nr_samples); + if (rctx->framebuffer.nr_samples > 1) + cayman_emit_msaa_sample_locs(cs, rctx->framebuffer.nr_samples); cayman_emit_msaa_config(cs, rctx->framebuffer.nr_samples, rctx->ps_iter_samples, 0, sc_mode_cntl_1); }