glsl: set patch outputs written directly in shader_info
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
@@ -128,7 +128,7 @@ mark(struct gl_program *prog, ir_variable *var, int offset, int len,
|
|||||||
} else {
|
} else {
|
||||||
assert(var->data.mode == ir_var_shader_out);
|
assert(var->data.mode == ir_var_shader_out);
|
||||||
if (is_patch_generic) {
|
if (is_patch_generic) {
|
||||||
prog->PatchOutputsWritten |= bitfield;
|
prog->info.patch_outputs_written |= bitfield;
|
||||||
} else if (!var->data.read_only) {
|
} else if (!var->data.read_only) {
|
||||||
prog->info.outputs_written |= bitfield;
|
prog->info.outputs_written |= bitfield;
|
||||||
if (var->data.index > 0)
|
if (var->data.index > 0)
|
||||||
@@ -431,7 +431,7 @@ do_set_program_inouts(exec_list *instructions, struct gl_program *prog,
|
|||||||
prog->SecondaryOutputsWritten = 0;
|
prog->SecondaryOutputsWritten = 0;
|
||||||
prog->info.outputs_read = 0;
|
prog->info.outputs_read = 0;
|
||||||
prog->info.patch_inputs_read = 0;
|
prog->info.patch_inputs_read = 0;
|
||||||
prog->PatchOutputsWritten = 0;
|
prog->info.patch_outputs_written = 0;
|
||||||
prog->SystemValuesRead = 0;
|
prog->SystemValuesRead = 0;
|
||||||
if (shader_stage == MESA_SHADER_FRAGMENT) {
|
if (shader_stage == MESA_SHADER_FRAGMENT) {
|
||||||
prog->info.fs.uses_sample_qualifier = false;
|
prog->info.fs.uses_sample_qualifier = false;
|
||||||
|
@@ -30,7 +30,6 @@ copy_shader_info(const struct gl_shader_program *shader_prog,
|
|||||||
{
|
{
|
||||||
shader_info *info = &sh->Program->info;
|
shader_info *info = &sh->Program->info;
|
||||||
|
|
||||||
info->patch_outputs_written = sh->Program->PatchOutputsWritten;
|
|
||||||
info->system_values_read = sh->Program->SystemValuesRead;
|
info->system_values_read = sh->Program->SystemValuesRead;
|
||||||
info->uses_texture_gather = sh->Program->UsesGather;
|
info->uses_texture_gather = sh->Program->UsesGather;
|
||||||
}
|
}
|
||||||
|
@@ -1923,7 +1923,6 @@ struct gl_program
|
|||||||
struct shader_info info;
|
struct shader_info info;
|
||||||
|
|
||||||
GLbitfield64 SecondaryOutputsWritten; /**< Subset of OutputsWritten outputs written with non-zero index. */
|
GLbitfield64 SecondaryOutputsWritten; /**< Subset of OutputsWritten outputs written with non-zero index. */
|
||||||
GLbitfield PatchOutputsWritten; /**< VAR[0..31] usage for patch outputs (user-defined only) */
|
|
||||||
GLbitfield SystemValuesRead; /**< Bitmask of SYSTEM_VALUE_x inputs used */
|
GLbitfield SystemValuesRead; /**< Bitmask of SYSTEM_VALUE_x inputs used */
|
||||||
GLbitfield TexturesUsed[MAX_COMBINED_TEXTURE_IMAGE_UNITS]; /**< TEXTURE_x_BIT bitmask */
|
GLbitfield TexturesUsed[MAX_COMBINED_TEXTURE_IMAGE_UNITS]; /**< TEXTURE_x_BIT bitmask */
|
||||||
GLbitfield SamplersUsed; /**< Bitfield of which samplers are used */
|
GLbitfield SamplersUsed; /**< Bitfield of which samplers are used */
|
||||||
|
Reference in New Issue
Block a user