nir: Validate after deserialization.
It's a particularly relevant place for NIR bugs to occur, and if you make a mistake in this code it gets caught in your debug build in something like mesa/st's call to nir_split_var_copies() during finalization, which is rather misleading. Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11860>
This commit is contained in:
parent
f855b25fd0
commit
bb35195b73
|
@ -2102,6 +2102,8 @@ nir_deserialize(void *mem_ctx,
|
|||
|
||||
free(ctx.idx_table);
|
||||
|
||||
nir_validate_shader(ctx.nir, "after deserialize");
|
||||
|
||||
return ctx.nir;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue