broadcom/compiler: check that sig packing is valid when pipelining ldvary

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13641>
This commit is contained in:
Iago Toral Quiroga 2021-11-03 11:14:19 +01:00 committed by Marge Bot
parent c6e2c802c4
commit a794bdf953

View file

@ -2034,6 +2034,12 @@ fixup_pipelined_ldvary(struct v3d_compile *c,
if (v3d_qpu_sig_writes_address(c->devinfo, &prev->qpu.sig))
return false;
uint32_t sig;
struct v3d_qpu_sig new_sig = prev->qpu.sig;
new_sig.ldvary = true;
if (!v3d_qpu_sig_pack(c->devinfo, &new_sig, &sig))
return false;
/* The previous instruction cannot use flags since ldvary uses the
* 'cond' instruction field to store the destination.
*/