glsl: pass shader stage to lower_output_reads and handle tess control
authorIlia Mirkin <imirkin@alum.mit.edu>
Tue, 22 Jul 2014 01:59:37 +0000 (21:59 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Wed, 22 Jul 2015 22:59:28 +0000 (00:59 +0200)
commit567f1b2ee89bf05f0600e9e79847140555f0a035
treea98dcb1c40df75bd078f40788b196ba71edc7a82
parent61846f222fffeba846f9f7277aba9cc7d48323ed
glsl: pass shader stage to lower_output_reads and handle tess control

Tessellation control outputs can be read in directly without first
having been written. Accessing these will require some special logic
anyways, so just let them through.

V2: Never lower tess control output reads, whether patch or not -- both
can be read back by other threads.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/glsl/ir_optimization.h
src/glsl/lower_output_reads.cpp
src/mesa/drivers/dri/i965/brw_shader.cpp
src/mesa/state_tracker/st_glsl_to_tgsi.cpp