summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2016-11-07 10:16:45 -0800
committerEric Anholt <[email protected]>2016-11-09 15:33:56 -0800
commit695a2e2ffa5faa7b303ca819dcb2e2922dfce5ab (patch)
tree631822da033c5edb45282d3eb961668bf9599b63 /src/gallium/drivers
parent4d019bd703e7c20d56d5b858577607115b4926a3 (diff)
vc4: Print a reg pressure estimate in our reg allocation failure dump.
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/vc4/vc4_qir.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_qir.c b/src/gallium/drivers/vc4/vc4_qir.c
index 446af66affd..a34eccf5091 100644
--- a/src/gallium/drivers/vc4/vc4_qir.c
+++ b/src/gallium/drivers/vc4/vc4_qir.c
@@ -381,6 +381,7 @@ void
qir_dump(struct vc4_compile *c)
{
int ip = 0;
+ int pressure = 0;
qir_for_each_block(block, c) {
fprintf(stderr, "BLOCK %d:\n", block->index);
@@ -388,6 +389,8 @@ qir_dump(struct vc4_compile *c)
if (c->temp_start) {
bool first = true;
+ fprintf(stderr, "%3d ", pressure);
+
for (int i = 0; i < c->num_temps; i++) {
if (c->temp_start[i] != ip)
continue;
@@ -398,6 +401,7 @@ qir_dump(struct vc4_compile *c)
fprintf(stderr, ", ");
}
fprintf(stderr, "S%4d", i);
+ pressure++;
}
if (first)
@@ -419,6 +423,7 @@ qir_dump(struct vc4_compile *c)
fprintf(stderr, ", ");
}
fprintf(stderr, "E%4d", i);
+ pressure--;
}
if (first)