Remove gpu shader optimatization for solid white or trans black colors
authoregdaniel <egdaniel@google.com>
Fri, 11 Jul 2014 15:57:40 +0000 (08:57 -0700)
committerCommit bot <commit-bot@chromium.org>
Fri, 11 Jul 2014 15:57:40 +0000 (08:57 -0700)
commit5f78d2251a440443c9eaa321dad058d7a32bfef7
treedb019baabf35aaac3c6f34d2034a444466dfb468
parent133931f4abdafa5bb0bdea3a02af1e5a70d5ac98
Remove gpu shader optimatization for solid white or trans black colors

Running test on the added bench which draws a grid of all white paths, all blue paths, or alternating checkered white/blue paths.

With optimization in (ms):
         White       Blue        Checkered
Linux    ~80         ~80         ~160
N7       ~800        ~1100       ~1500
Moto-e   ~830        ~1100       ~2500

Without optimization in (ms):
         White       Blue        Checkered
Linux    ~80         ~80         ~80
N7       ~1100       ~1100       ~1100
Moto-e   ~1100       ~1100       ~1500

BUG=skia:
R=bsalomon@google.com

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/375823005
bench/AlternatingColorPatternBench.cpp [new file with mode: 0644]
gyp/bench.gypi
src/gpu/gl/GrGLProgram.cpp
src/gpu/gl/GrGLProgramDesc.cpp
src/gpu/gl/GrGLShaderBuilder.cpp