nir/validate: Only require bare types to match for copy_deref
If we want to be able to use copy_deref instructions on explicitly laid out types, we have to be a little more flexible about what types we allow. Instead, of requiring the types to exactly match, only require the bare types to match. Reviewed-by: Kristian H. Kristensen <hoegsberg@chromium.org> Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
This commit is contained in:

committed by
Jason Ekstrand

parent
2b76de9b5d
commit
5d26f2d3d5
@@ -66,7 +66,8 @@ static void
|
||||
split_deref_copy_instr(nir_builder *b,
|
||||
nir_deref_instr *dst, nir_deref_instr *src)
|
||||
{
|
||||
assert(dst->type == src->type);
|
||||
assert(glsl_get_bare_type(dst->type) ==
|
||||
glsl_get_bare_type(src->type));
|
||||
if (glsl_type_is_vector_or_scalar(src->type)) {
|
||||
nir_copy_deref(b, dst, src);
|
||||
} else if (glsl_type_is_struct_or_ifc(src->type)) {
|
||||
|
Reference in New Issue
Block a user