On Fri, 09 Sep 2011 15:21:14 -0700, Kenneth Graunke
wrote:
> On 09/08/2011 11:32 PM, Eric Anholt wrote:
> > + * Does algebraic optimizations (0 * a = 0, 1 * a = a, a + 0 = a).
>
> I was going to ask "what about commutativity?"...after all, 0 * a but a
> + 0 seems kind of arbitrary...but then I i
On 09/08/2011 11:32 PM, Eric Anholt wrote:
> + * Does algebraic optimizations (0 * a = 0, 1 * a = a, a + 0 = a).
I was going to ask "what about commutativity?"...after all, 0 * a but a
+ 0 seems kind of arbitrary...but then I implemented it and tried it on
shader-db:
Total instructions: 39967 ->
On 09/08/2011 11:32 PM, Eric Anholt wrote:
> We generate silly code for array access, and it's easier to generally
> support the cleanup than to specifically avoid the bad code in each
> place we might generate it.
>
> Removes 4.6% of instructions from 41.6% of shaders in shader-db,
> particularly
We generate silly code for array access, and it's easier to generally
support the cleanup than to specifically avoid the bad code in each
place we might generate it.
Removes 4.6% of instructions from 41.6% of shaders in shader-db,
particularly savage2/hon and unigine.
---
src/mesa/drivers/dri/i96