<div dir="ltr"><div>I read through the series and, while I think it will fix the issue in 90% of cases, I don't think it's quite the right solution. There's a *lot* of subtlety here and we need to tread carefully. I think the better thing to do would be to whack the new flag in two places: Whenever we change the fast clear value (brw_blorp.c and brw_clear.c for depth) and whenever intel_miptree_set_aux_state actually changes something. There are several things which look at aux_state and it would be better to flag on that changing just to make sure we get them all.<br><br></div>--Jason<br><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Sep 14, 2017 at 3:54 AM, Iago Toral Quiroga <span dir="ltr"><<a href="mailto:itoral@igalia.com" target="_blank">itoral@igalia.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Jason, Ken: this is what I came up based on your findings that Ken<br>
reported in <a href="https://bugs.freedesktop.org/show_bug.cgi?id=102611" rel="noreferrer" target="_blank">https://bugs.freedesktop.org/<wbr>show_bug.cgi?id=102611</a>.<br>
<br>
Ken mentioned that he is not completely certain that we need to flag<br>
dirty state every time we update the surfaces and that maybe flagging<br>
only when we go from/to AUX_USAGE_NONE might suffice. I am not sure,<br>
but to me it sounds safer to flag when we create the surfaces, since<br>
at that point we know we are going to use them and in that case we<br>
need the new surface states emitted, at least until we find specific<br>
cases where we don't need this and we can drop the flag for them. Let<br>
me know if you think a different approach is better though.<br>
<br>
The last two patches should probably be squashed. The last patch<br>
signals dirty AUX state when we drop aux surfaces. I think this<br>
is in necessary too since when we upload new renderbuffers we<br>
also consider the case where we don't have aux, but I decided to<br>
split it because we have not been signaling anything for dropped<br>
aux surfaces before.<br>
<br>
Iago Toral Quiroga (3):<br>
i965: rename BRW_NEW_FAST_CLEAR_COLOR to BRW_NEW_AUX_STATE<br>
i965: emit BRW_NEW_AUX_STATE when we allocate aux surfaces<br>
i965: flag BRW_NEW_AUX_STATE if we drop the aux buffer<br>
<br>
src/mesa/drivers/dri/i965/brw_<wbr>blorp.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>context.h | 4 ++--<br>
src/mesa/drivers/dri/i965/brw_<wbr>gs_surface_state.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>state_upload.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>tcs_surface_state.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>tes_surface_state.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>vs_surface_state.c | 2 +-<br>
src/mesa/drivers/dri/i965/brw_<wbr>wm_surface_state.c | 12 ++++++------<br>
src/mesa/drivers/dri/i965/<wbr>intel_mipmap_tree.c | 7 +++++++<br>
9 files changed, 21 insertions(+), 14 deletions(-)<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
2.11.0<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>