[Mesa-dev] [PATCH] i965/fs: Compact the virtual GRF arrays.

Eric Anholt eric at anholt.net
Fri Nov 2 14:23:01 PDT 2012


Kenneth Graunke <kenneth at whitecape.org> writes:

> During code generation, we create tons of temporary variables, many of
> which get immediately killed and are never used.  Later optimization and
> analysis passes, such as compute_live_intervals, loop over all the
> virtual GRFs.  By compacting them, we can save a lot of overhead.
>
> Reduces compilation time in L4D2's largest fragment shader from 10.2
> seconds to 5.2 seconds (50%).  Drops compute_live_variables() from
> 10-12% of another game's startup time to 8%.

Cool.  I'd tried something similar before and not measured an
improvement.  I'm fully in favor.

Reviewed-by: Eric Anholt <eric at anholt.net>

-------------- 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/20121102/83d23e1a/attachment.pgp>


More information about the mesa-dev mailing list