[Mesa-dev] [PATCH 2/7] vbo: Add a predraw resolve callback

Kenneth Graunke kenneth at whitecape.org
Wed Sep 9 10:22:17 PDT 2015


On Wednesday, September 09, 2015 10:19:10 AM Ian Romanick wrote:
> On 09/09/2015 10:10 AM, Kenneth Graunke wrote:
> > On Wednesday, September 09, 2015 02:38:56 PM Chris Wilson wrote:
> >> A common problem with using HiZ and multisampling is that surfaces need
> >> to resolved prior to use. Currently i965 does this inside its state
> >> update hook, but that is a comparatively heavyweight operation that need
> >> not be performed so frequently. The obvious solution (and therefore
> >> fraught with dragons) is to move the HiZ/color resolves into the
> >> brw_draw_prims() - however, the resolves are performed using meta and
> >> end up re-entering brw_draw_prims() corrupting the context state of the
> >> original call. To avoid the meta recursion, we can add a new callback
> >> (vbo->resolve()) into the vbo pipeline that is called just before
> >> vbo->draw().
> >>
> >> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> >> Cc: Brian Paul <brianp at vmware.com>
> >> Cc: Jordan Justen <jordan.l.justen at intel.com>
> >> Cc: Jason Ekstrand <jason.ekstrand at intel.com>
> >> Cc: Kenneth Graunke <kenneth at whitecape.org>
> >> Cc: Francisco Jerez <currojerez at riseup.net>
> >> ---
> >>  src/mesa/vbo/vbo.h            |  1 +
> >>  src/mesa/vbo/vbo_context.c    | 19 +++++++++++++++++++
> >>  src/mesa/vbo/vbo_context.h    |  1 +
> >>  src/mesa/vbo/vbo_exec_array.c |  1 +
> >>  src/mesa/vbo/vbo_exec_draw.c  |  5 ++++-
> >>  src/mesa/vbo/vbo_save_draw.c  |  2 ++
> >>  6 files changed, 28 insertions(+), 1 deletion(-)
> > 
> > What problem are you trying to solve with this patch series?
> > Are you trying to fix bugs?  If so, what triggers them?
> > Are you trying to improve performance?  If so, do you have any data
> > demonstrating that it benefits some workload?
> 
> In 0/7 he says, "By moving the current HiZ/color resolves
> we need before drawing from out of the notify and into the draw itself,
> we can save a few percent of overhead in OglBatch7 on Atom class
> devices."  Given the amount of change here, I too would like to see some
> actual performance data.

Ah, sorry - 1-7 were CC'd to me, but 0 wasn't, so it ended up in a
different mail folder and I missed it.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150909/cd428ba9/attachment.sig>


More information about the mesa-dev mailing list