summary refs log tree commit diff
path: root/lisc/spill.c
diff options
context:
space:
mode:
authorQuentin Carbonneaux <quentin.carbonneaux@yale.edu>2015-07-22 07:14:22 -0400
committerQuentin Carbonneaux <quentin.carbonneaux@yale.edu>2015-09-15 23:01:29 -0400
commiteb1df2b81e18195bcf68dd56f4f339ceda7f5365 (patch)
treeafbabdffe0b437ac65719ce872f5a18bf56d63b9 /lisc/spill.c
parent4f4d4cce6f513a7fd3fdd2e0f6e2a795cfb9bb71 (diff)
downloadroux-eb1df2b81e18195bcf68dd56f4f339ceda7f5365.tar.gz
refine assertion in cost computation
Diffstat (limited to 'lisc/spill.c')
-rw-r--r--lisc/spill.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lisc/spill.c b/lisc/spill.c
index ad105e1..b09c696 100644
--- a/lisc/spill.c
+++ b/lisc/spill.c
@@ -94,7 +94,8 @@ fillcost(Fn *fn)
 			symuse(p->to, 0, 0, fn);
 			for (a=0; a<p->narg; a++) {
 				n = p->blk[a]->loop;
-				assert(b->npred && "invalid cfg");
+				assert(b->npred==p->narg &&
+					"wrong cfg");
 				n /= b->npred;
 				symuse(p->arg[a], 1, n, fn);
 			}