X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=src%2FSDCCmem.c;h=bf81c0e8f86d5d9c0bcf8b10d9c87c89906fef47;hb=db167ecd5f82f89d98c89e7181d07e1da8cefc7e;hp=f369a04fda8efd3580aff192be37d82f3efbe3e3;hpb=6cf005ad44bcebf9a5d6f6b8efdac2f85488cfa8;p=fw%2Fsdcc diff --git a/src/SDCCmem.c b/src/SDCCmem.c index f369a04f..bf81c0e8 100644 --- a/src/SDCCmem.c +++ b/src/SDCCmem.c @@ -404,12 +404,12 @@ allocGlobal (symbol * sym) if (SPEC_SCLS (sym->etype) == S_XDATA) { - SPEC_OCLS (sym->etype) = xdata; // should we move this to the initialized data segment? if (port->genXINIT && sym->ival && (sym->level==0) && !SPEC_ABSA(sym->etype)) { SPEC_OCLS(sym->etype)=xidata; - addSet(&xidata->syms, sym); + } else { + SPEC_OCLS (sym->etype) = xdata; } allocIntoSeg (sym); return; @@ -546,14 +546,13 @@ deallocParms (value * val) /* unmark is myparm */ lval->sym->ismyparm = 0; - /* if on stack then depending on which stack */ /* delete it from the symbol table */ deleteSym (SymbolTab, lval->sym, lval->sym->name); if (!lval->sym->isref) { - lval->sym->allocreq = 1; + lval->sym->allocreq = 0; werror (W_NO_REFERENCE, currFunc->name, "function argument", lval->sym->name); } @@ -724,7 +723,7 @@ deallocLocal (symbol * csym) for (sym = csym; sym; sym = sym->next) { - if (sym->_isparm) + if (sym->_isparm) continue; /* if it is on the stack */ @@ -1101,4 +1100,5 @@ printAllocInfo (symbol * func, FILE * of) printAllocInfoSeg (idata, func, of); printAllocInfoSeg (sfr, func, of); printAllocInfoSeg (sfrbit, func, of); + fprintf (of, ";------------------------------------------------------------\n"); }