Re: [Mesa-dev] [PATCH 5/9] nir: Add a flag for lowering fneg/ineg.

2015-02-03 Thread Connor Abbott
On Tue, Feb 3, 2015 at 5:20 PM, Eric Anholt wrote: > Connor Abbott writes: > >> I think this logic should be flipped around... you should have a flag >> 'lower_sub' which is false for vc4 but true for i965, and then if the >> flag is true we lower sub to add+neg and if false we try and >> reconst

Re: [Mesa-dev] [PATCH 5/9] nir: Add a flag for lowering fneg/ineg.

2015-02-03 Thread Eric Anholt
Connor Abbott writes: > I think this logic should be flipped around... you should have a flag > 'lower_sub' which is false for vc4 but true for i965, and then if the > flag is true we lower sub to add+neg and if false we try and > reconstruct sub (and do other things like pulling neg's out of > m

Re: [Mesa-dev] [PATCH 5/9] nir: Add a flag for lowering fneg/ineg.

2015-02-01 Thread Connor Abbott
I think this logic should be flipped around... you should have a flag 'lower_sub' which is false for vc4 but true for i965, and then if the flag is true we lower sub to add+neg and if false we try and reconstruct sub (and do other things like pulling neg's out of multiplies). That way, eventually w

[Mesa-dev] [PATCH 5/9] nir: Add a flag for lowering fneg/ineg.

2015-02-01 Thread Eric Anholt
vc4 cse/algebraic-disabled stats: total instructions in shared programs: 44911 -> 44732 (-0.40%) instructions in affected programs: 11371 -> 11192 (-1.57%) --- src/gallium/drivers/vc4/vc4_program.c | 1 + src/glsl/nir/nir.h| 2 ++ src/glsl/nir/nir_opt_algebraic.py | 1