From d99979b6e01eb5546f99a33db95d26d06f857740 Mon Sep 17 00:00:00 2001 From: vrokas Date: Wed, 3 Mar 2004 11:32:17 +0000 Subject: [PATCH] * src/pic16/ralloc.c (newReg): fixed bug #908929 git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@3243 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- ChangeLog | 4 ++++ src/pic16/ralloc.c | 10 +++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 4052420d..09d4f047 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2004-02-03 Vangelis Rokas + + * src/pic16/ralloc.c (newReg): fixed bug #908929 + 2004-03-02 Erik Petrich * src/ds390/gen.c: added missing #include "main.h" diff --git a/src/pic16/ralloc.c b/src/pic16/ralloc.c index 6a58ede3..2ffbce10 100644 --- a/src/pic16/ralloc.c +++ b/src/pic16/ralloc.c @@ -384,7 +384,8 @@ regs* newReg(short type, short pc_type, int rIdx, char *name, int size, int alia dReg->reglives.assignedpFlows = newSet(); dReg->regop = refop; - hTabAddItem(&dynDirectRegNames, regname2key(name), dReg); + if(!(type == REG_SFR && alias == 0x80)) + hTabAddItem(&dynDirectRegNames, regname2key(name), dReg); return dReg; } @@ -566,6 +567,7 @@ pic16_allocDirReg (operand *op ) if(!IS_SYMOP(op)) { debugLog ("%s BAD, op is NULL\n", __FUNCTION__); +// fprintf(stderr, "%s BAD, op is NULL\n", __FUNCTION__); return NULL; } @@ -751,6 +753,7 @@ regs *pic16_typeRegWithIdx (int idx, int type, int fixed) regs *dReg; debugLog ("%s - requesting index = 0x%x\n", __FUNCTION__,idx); +// fprintf(stderr, "%s - requesting index = 0x%x\n", __FUNCTION__, idx); switch (type) { @@ -818,6 +821,7 @@ pic16_allocWithIdx (int idx) regs *dReg; debugLog ("%s - allocating with index = 0x%x\n", __FUNCTION__,idx); +// fprintf(stderr, "%s - allocating with index = 0x%x\n", __FUNCTION__,idx); if( (dReg = regWithIdx ( pic16_dynAllocRegs, idx,0)) != NULL) { @@ -3015,11 +3019,15 @@ pack: } +#if 1 + #define NO_packRegsForAccUse #define NO_packRegsForSupport #define NO_packRegsForOneuse #define NO_cast_peep +#endif + #ifndef NO_packRegsForSupport /*-----------------------------------------------------------------*/ -- 2.47.2