Refactor CCallInfo representation for split arguments.

This commit is contained in:
Mike Pall
2013-05-13 19:49:46 +02:00
parent 23e47f2913
commit acda75ad2c
6 changed files with 74 additions and 59 deletions

View File

@@ -249,7 +249,7 @@ static int asm_fusemadd(ASMState *as, IRIns *ir, PPCIns pi, PPCIns pir)
/* Generate a call to a C function. */
static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
{
uint32_t n, nargs = CCI_NARGS(ci);
uint32_t n, nargs = CCI_XNARGS(ci);
int32_t ofs = 8;
Reg gpr = REGARG_FIRSTGPR, fpr = REGARG_FIRSTFPR;
if ((void *)ci->func)
@@ -1917,7 +1917,7 @@ static void asm_tail_prep(ASMState *as)
static Reg asm_setup_call_slots(ASMState *as, IRIns *ir, const CCallInfo *ci)
{
IRRef args[CCI_NARGS_MAX];
uint32_t i, nargs = (int)CCI_NARGS(ci);
uint32_t i, nargs = CCI_XNARGS(ci);
int nslots = 2, ngpr = REGARG_NUMGPR, nfpr = REGARG_NUMFPR;
asm_collectargs(as, ir, ci, args);
for (i = 0; i < nargs; i++)