[Mesa-dev] [PATCH 09/13] i965: Use a single binding table for all pipeline stages.

Eric Anholt eric at anholt.net
Wed Nov 9 10:34:46 PST 2011


On Tue,  8 Nov 2011 14:32:08 -0800, Kenneth Graunke <kenneth at whitecape.org> wrote:
> Although the hardware supports separate binding tables for each pipeline
> stage, we don't see much advantage over a single shared table.
> 
> Consider the contents of the binding table:
> - Textures (16)
> - Draw buffers (8)
> - Pull constant buffers (1 for VS, 1 for WM)
> 
> OpenGL's texture bindings are global: the same set of textures is
> available to all shader targets.  So our binding table entries for
> textures would be exactly the same in every table.
> 
> There are only two pull constant buffers (not many), and although draw
> buffers aren't interesting to the VS, it shouldn't hurt to have them in
> the table.  The hardware supports up to 254 binding table entries, and
> we currently only use 26.
> 
> Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>

> +   brw->state.dirty.brw |= BRW_NEW_VS_BINDING_TABLE;
>     brw->state.dirty.brw |= BRW_NEW_PS_BINDING_TABLE;
>  }

I was surprised you didn't fold these two state flags together, but I
guess it leaves us flexibility if we decide to go back on this later.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20111109/3236047d/attachment.pgp>


More information about the mesa-dev mailing list