diff options
| author | 2026-03-23 19:20:32 +0100 | |
|---|---|---|
| committer | 2026-03-23 19:20:32 +0100 | |
| commit | 8630aeb8b43c507cd00f5b091ddcee4def464f4d (patch) | |
| tree | 1e39866c9f95e2f30903b96c7f255dd03a463d82 /src/ir_abi0.c | |
| parent | 9ffc0e5a21817a45956bc35d5996bfae09c4d49e (diff) | |
IR: mark free'd instructions as such
That way they are not copied when inlining.
Also rename ninstr -> ninstrtab. opnarg -> opnoper
Diffstat (limited to 'src/ir_abi0.c')
| -rw-r--r-- | src/ir_abi0.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ir_abi0.c b/src/ir_abi0.c index 61a310f..74a9d62 100644 --- a/src/ir_abi0.c +++ b/src/ir_abi0.c @@ -235,8 +235,9 @@ patcharg(Block *blk, int *icall, IRCall *call, return 1; } else { /* aggregate in registers */ Ref r[2]; + IRType typ = ref2type(arg->l); delinstr(blk, arginst); - load2regs(r, ref2type(arg->l), arg->r, nabi, abi, r2off, blk, &arginst); + load2regs(r, typ, arg->r, nabi, abi, r2off, blk, &arginst); for (int i = 0; i < nabi; ++i) insertinstr(blk, arginst++, mkinstr2(Oarg, 0, mktyperef(abi[i].ty), r[i])); *icall = arginst + (call->narg - argidx - 1); |