freedreno/cffdec: When .mergedregs is set, don't count half regs.

This matches what ir3.c does in the mergedregs case: just count max full
reg used.  This flag is unset so far, but will be soon and keeps our
output comparable between blob and freedreno.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6323>
This commit is contained in:
Eric Anholt 2020-08-17 10:58:06 -07:00 committed by Marge Bot
parent 803ec06b1b
commit ce335dcb19

View file

@ -272,7 +272,7 @@ static void print_reg_stats(struct disasm_ctx *ctx)
* assigned to shader:
*/
fullreg = (fullreg + 3) / 4;
halfreg = (halfreg + 3) / 4;
halfreg = ctx->regs.used.mergedregs ? 0 : (halfreg + 3) / 4;
// Note this count of instructions includes rptN, which matches
// up to how mesa prints this: