* src/avr/ralloc.c (serialRegAssign),
[fw/sdcc] / src / pic16 / ralloc.c
index 58cc571a10d15dc2a8b3a131effe82ae664509d5..032029018a5063f812e4f538a0d07978806a2ef2 100644 (file)
@@ -2275,6 +2275,13 @@ serialRegAssign (eBBlock ** ebbs, int count)
              int j;
              int ptrRegSet = 0;
 
+             /* Make sure any spill location is definately allocated */
+             if (sym->isspilt && !sym->remat && sym->usl.spillLoc &&
+                 !sym->usl.spillLoc->allocreq)
+               {
+                 sym->usl.spillLoc->allocreq++;
+               }
+
              /* if it does not need or is spilt 
                 or is already assigned to registers
                 or will not live beyond this instructions */