Use a dynamic array for phi arguments

This commit is contained in:
Michael Forney 2020-04-19 16:31:52 -07:00 committed by Quentin Carbonneaux
parent 190263f1b6
commit 9de57265ce
6 changed files with 22 additions and 8 deletions

2
load.c
View file

@ -330,6 +330,8 @@ def(Slice sl, bits msk, Blk *b, Ins *i, Loc *il)
p->to = r;
p->cls = sl.cls;
p->narg = b->npred;
p->arg = vnew(p->narg, sizeof p->arg[0], Pfn);
p->blk = vnew(p->narg, sizeof p->blk[0], Pfn);
for (np=0; np<b->npred; ++np) {
bp = b->pred[np];
if (!bp->s2