X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2Fpic16%2Fgen.c;h=7d58f40030e7aa79666aef838d393bc61b2d5280;hb=81cd49cd3298b973e88c4b9cdce1fa6f86a2f2b0;hp=735f113ccfc8e3ce4515644761cde442b807b04d;hpb=c2f2abbf9d58d7f0def3509779547f50ade2e2ab;p=fw%2Fsdcc diff --git a/src/pic16/gen.c b/src/pic16/gen.c index 735f113c..7d58f400 100644 --- a/src/pic16/gen.c +++ b/src/pic16/gen.c @@ -1289,6 +1289,10 @@ void pic16_aopOp (operand *op, iCode *ic, bool result) #endif sym->aop = op->aop = aop = newAsmop(AOP_PCODE); + if (sym->usl.spillLoc && getSize(sym->type) != getSize(sym->usl.spillLoc->type)) { + /* Don't reuse the new aop */ + sym->usl.spillLoc->aop = NULL; + } //aop->aopu.pcop = pic16_popGetImmd(sym->usl.spillLoc->rname,0,sym->usl.spillLoc->offset); if (sym->usl.spillLoc && sym->usl.spillLoc->rname) { aop->aopu.pcop = pic16_popRegFromString(sym->usl.spillLoc->rname,