[Mesa-dev] [PATCH] i965: Don't inline intel_batchbuffer_require_space().

Kenneth Graunke kenneth at whitecape.org
Tue Nov 24 23:07:54 PST 2015


On Tuesday, November 24, 2015 05:17:29 PM Matt Turner wrote:
> It's called by the inline intel_batchbuffer_begin() function which
> itself is used in BEGIN_BATCH. So in sequence of code emitting multiple
> packets, we have inlined this ~200 byte function multiple times. Making
> it an out-of-line function presumably improved icache usage.
> 
> Improves performance of Gl32Batch7 by 3.39898% +/- 0.358674% (n=155) on
> Ivybridge.

That's kind of sad.  When I added the render ring prelude code to this
function, Eric was concerned about overhead like this.  I do wonder
whether we'd be better off doing explicit ring switching, like I did
on the 'ringswitch' branch of my tree.  That kills a bunch of the code
on every BEGIN_BATCH().

Eric wasn't a fan of it, as he thought it would be easy to miss places
and screw things up...though I think the assertion should help catch
that.  And there aren't that many places which need a switch_rings()
call...
-------------- 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/20151124/325a102a/attachment.sig>


More information about the mesa-dev mailing list