diff options
author | Dave Airlie <airlied@redhat.com> | 2021-06-08 12:58:18 +1000 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2021-06-11 21:19:06 +0000 |
commit | eff418fe577f9e775b425d1166fcdf83567e8699 (patch) | |
tree | ca2f4b7108e8683851a5b7b30eae8db83647b95f /src/compiler | |
parent | 00dc4e0d832631224fe5cd0fe23443ded0310445 (diff) |
nir/edgeflags: update outputs written when lowering edge flags.
In theory you can rerun the info gather pass, but in practice that
doesn't always end well. Be consistent inside this pass and update the
info.
While we're here, change the inputs read to use VERT_BIT_EDGEFLAG.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11313>
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/nir/nir_lower_passthrough_edgeflags.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/compiler/nir/nir_lower_passthrough_edgeflags.c b/src/compiler/nir/nir_lower_passthrough_edgeflags.c index 59b02af0aef..addd6bbeb2d 100644 --- a/src/compiler/nir/nir_lower_passthrough_edgeflags.c +++ b/src/compiler/nir/nir_lower_passthrough_edgeflags.c @@ -77,11 +77,12 @@ lower_impl(nir_function_impl *impl) in->data.location = VERT_ATTRIB_EDGEFLAG; in->data.driver_location = shader->num_inputs++; - shader->info.inputs_read |= BITFIELD64_BIT(VERT_ATTRIB_EDGEFLAG); + shader->info.inputs_read |= VERT_BIT_EDGEFLAG; out = nir_variable_create(shader, nir_var_shader_out, glsl_vec4_type(), "edgeflag_out"); out->data.location = VARYING_SLOT_EDGE; + shader->info.outputs_written |= VARYING_BIT_EDGE; def = nir_load_var(&b, in); nir_store_var(&b, out, def, 0xf); |