glsl: Optimize lrp(x, 0, a) into x - (x * a).
authorMatt Turner <mattst88@gmail.com>
Mon, 24 Feb 2014 23:00:45 +0000 (15:00 -0800)
committerMatt Turner <mattst88@gmail.com>
Fri, 28 Feb 2014 18:36:12 +0000 (10:36 -0800)
commitd5fa8a956211692441b9c3ffc97b7486599ab3a3
tree5cb6b7339c046f62088950bf97a104ad7fe71578
parentecc6c3d4ab31c6cd848bce02790000c165a02229
glsl: Optimize lrp(x, 0, a) into x - (x * a).

Helps one program in shader-db:

instructions in affected programs:     96 -> 92 (-4.17%)

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
src/glsl/opt_algebraic.cpp