<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Jun 14, 2018 at 10:55 AM, Jason Ekstrand <span dir="ltr"><<a href="mailto:jason@jlekstrand.net" target="_blank">jason@jlekstrand.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On June 14, 2018 01:43:12 Michel Dänzer <<a href="mailto:michel@daenzer.net" target="_blank">michel@daenzer.net</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 2018-06-13 10:26 PM, Jason Ekstrand wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
The current BO cache puts BOs back into the recycle bucket the moment the<br>
refcount hits zero.  If the BO is busy, we just don't re-use it until it<br>
isn't or we re-use it for a render target which we assume will be used<br>
first for drawing.  This patch series reworks the way the BO cache works a<br>
bit so that we don't ever recycle a busy BO.  On the down side, it means<br>
that we don't get the "keep busy BOs busy" heuristic (which we have no<br>
proof actually helps).  On the up side, we can now easily use a MRU<br>
heuristic instead of round-robin for all buffers and not just the busy<br>
ones.  Will this be an improvement, a regression or a wash?  I don't know<br>
but I doubt it will have a major effect one way or another.<br>
</blockquote>
<br>
FWIW, I suspect this could be a significant loss with overlapping copies<br>
in glamor (e.g. x11perf -copywinwin500), because it won't be able to<br>
reuse the busy BOs anymore (glamor creates a temporary FBO for each<br>
overlapping copy).<br>
</blockquote>
<br></span>
That's rather horrific... That seems like something glamour could do better.  How common are overlapping copies in practice?  Are we talking a couple per frame or hundreds?  If that really is going on then we may need to rethink our approach on this one. :-(<br></blockquote><div><br></div><div>I did some testing and x11perf -copywinwin500 is... exactly the same with or without my patches.  If anything they might improve it by just a hair.</div><div><br></div><div>--Jason<br></div></div><br></div></div>