[Mesa-dev] meta/blit: Write gl_FragDepth only when really needed

Topi Pohjolainen topi.pohjolainen at intel.com
Thu Jan 29 06:20:59 PST 2015


Currently meta blit programs unconditionally write both color and
depth values. This series introduces two flavours - with and without
gl_FragDepth - allowing simpler programs for color only blits. Ken
had observed that i965 behaves badly emitting five unnecessary moves
when the depth is included in the shader.
While this didn't improve any performance benches I tried, it doesn't
seem to introduce any regressions either in the benches or with
piglit.

Topi Pohjolainen (5):
  meta/blit: Add plumbing for shaders without depth
  meta/blit: Write depth only when asked for
  meta/blit: Compile programs with and without depth
  meta: Don't write depth when generating miptrees
  meta: Don't write depth when decompressing tex-images

 src/mesa/drivers/common/meta.c                 | 10 ++++++----
 src/mesa/drivers/common/meta.h                 |  4 +++-
 src/mesa/drivers/common/meta_blit.c            | 13 +++++++++----
 src/mesa/drivers/common/meta_generate_mipmap.c |  2 +-
 4 files changed, 19 insertions(+), 10 deletions(-)

-- 
1.9.3



More information about the mesa-dev mailing list