Re: [Mesa-dev] [PATCH v2] glsl: Optimize min/max expression trees

2014-09-29 Thread Iago Toral Quiroga
On vie, 2014-09-26 at 12:57 -0400, Connor Abbott wrote: On Fri, Sep 26, 2014 at 9:02 AM, Iago Toral Quiroga ito...@igalia.com wrote: Original patch by Petri Latvala petri.latv...@intel.com: Add an optimization pass that drops min/max expression operands that can be proven to not

[Mesa-dev] [PATCH v2] glsl: Optimize min/max expression trees

2014-09-26 Thread Iago Toral Quiroga
Original patch by Petri Latvala petri.latv...@intel.com: Add an optimization pass that drops min/max expression operands that can be proven to not contribute to the final result. The algorithm is similar to alpha-beta pruning on a minmax search, from the field of AI. This optimization pass can

Re: [Mesa-dev] [PATCH v2] glsl: Optimize min/max expression trees

2014-09-26 Thread Connor Abbott
On Fri, Sep 26, 2014 at 9:02 AM, Iago Toral Quiroga ito...@igalia.com wrote: Original patch by Petri Latvala petri.latv...@intel.com: Add an optimization pass that drops min/max expression operands that can be proven to not contribute to the final result. The algorithm is similar to