From: michaelh Date: Wed, 28 Nov 2001 01:46:36 +0000 (+0000) Subject: Cleaned up warnings X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=022ad5f4b7e62ee89ae9723242d3ecc459391711;p=fw%2Fsdcc Cleaned up warnings git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1649 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- diff --git a/src/SDCCicode.c b/src/SDCCicode.c index e3781a7f..57ee76fc 100644 --- a/src/SDCCicode.c +++ b/src/SDCCicode.c @@ -129,7 +129,6 @@ iCodeTable codeTable[] = void checkConstantRange(sym_link *ltype, value *val, char *msg, int pedantic) { double max; - char message[132]=""; int warnings=0; int negative=0; long v; diff --git a/src/ds390/ralloc.c b/src/ds390/ralloc.c index 27b8c1e4..cf85879e 100644 --- a/src/ds390/ralloc.c +++ b/src/ds390/ralloc.c @@ -36,6 +36,8 @@ /* since the pack the registers depending strictly on the MCU */ /*-----------------------------------------------------------------*/ +#define D(x) + /* Global data */ static struct { @@ -1307,7 +1309,7 @@ static void fillGaps() if (sym->uptr && !sym->ruonly && getSize(sym->type) < 4) { if (packRegsDPTRuse(operandFromSymbol(sym))) { - printf("FILL GAPS: found more DPTR use for %s in func %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN"); + D (printf ("FILL GAPS: found more DPTR use for %s in func %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN")); /* if this was ssigned to registers then */ if (bitVectBitValue(_G.totRegAssigned,sym->key)) { @@ -1392,10 +1394,10 @@ static void fillGaps() sym->regs[i] = NULL; } freeAllRegs(); - printf("Fill Gap gave up due to positioning for %s in function %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN"); + D (printf ("Fill Gap gave up due to positioning for %s in function %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN")); continue ; } - printf("FILLED GAP for %s in function %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN"); + D (printf ("FILLED GAP for %s in function %s\n",sym->name, currFunc ? currFunc->name : "UNKNOWN")); _G.totRegAssigned = bitVectSetBit(_G.totRegAssigned,sym->key); sym->isspilt = sym->spillA = 0 ; sym->usl.spillLoc->allocreq--; diff --git a/src/mcs51/main.c b/src/mcs51/main.c index c21bbd44..bbe4921c 100644 --- a/src/mcs51/main.c +++ b/src/mcs51/main.c @@ -124,11 +124,7 @@ _mcs51_genIVT (FILE * of, symbol ** interrupts, int maxInterrupts) static bool cseCostEstimation (iCode *ic, iCode *pdic) { operand *result = IC_RESULT(ic); - operand *right = IC_RIGHT(ic); - operand *left = IC_LEFT(ic); sym_link *result_type = operandType(result); - sym_link *right_type = (right ? operandType(right) : 0); - sym_link *left_type = (left ? operandType(left) : 0); /* if it is a pointer then return ok for now */ if (IC_RESULT(ic) && IS_PTR(result_type)) return 1; diff --git a/src/z80/gen.c b/src/z80/gen.c index 0f9a24c4..76345de7 100644 --- a/src/z80/gen.c +++ b/src/z80/gen.c @@ -411,7 +411,7 @@ _emitMove(const char *to, const char *from) } } -static void +void aopDump(const char *plabel, asmop *aop) { emitDebug("; Dump of %s: type %s size %u", plabel, aopNames[aop->type], aop->size); @@ -924,7 +924,7 @@ aopOp (operand * op, iCode * ic, bool result, bool requires_a) /* force a new aop if sizes differ */ sym->usl.spillLoc->aop = NULL; } - op->aop = aop = + sym->aop = op->aop = aop = aopForSym (ic, sym->usl.spillLoc, result, requires_a); wassertl (aop->size >= getSize (sym->type), "Operand doesn't fit in the spill location"); aop->size = getSize (sym->type); @@ -6940,9 +6940,7 @@ static void genBuiltInMemcpy (iCode *ic, int nParams, operand **pparams) { operand *from, *to, *count; - symbol *label; bool deInUse; - iCode *pcall; wassertl (nParams == 3, "Built-in memcpy must have two parameters"); to = pparams[2];