* src/pic/glue.c (pic14emitRegularMap): mark initialized symbols as
authortecodev <tecodev@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Mon, 22 Jan 2007 01:42:00 +0000 (01:42 +0000)
committertecodev <tecodev@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Mon, 22 Jan 2007 01:42:00 +0000 (01:42 +0000)
  emitted, do not emit them again...

git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@4594 4a8a32a2-be11-0410-ad9d-d568d2c75423

ChangeLog
src/pic/glue.c

index ac8f64a313aa507734c8d549f584d29f14369228..46c0dd588153fc9db26247abaa46c041519958c8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2007-01-22 Raphael Neider <rneider AT web.de>
+
+       * src/pic/glue.c (pic14emitRegularMap): mark initialized symbols as
+         emitted, do not emit them again...
+
 2007-01-22 Raphael Neider <rneider AT web.de>
 
        * src/regression/bank1.c, src/regression/compare6.c,
index dcd6a971d5c37ce3b3dd627a2589d085c6a144bf..6148bf71e0671050378d332426fd9945d297a829 100644 (file)
@@ -404,6 +404,13 @@ pic14emitRegularMap (memmap * map, bool addPublics, bool arFlag)
                        //dbuf_printf (&map->oBuf, "\t.ds\t0x%04x\n", (unsigned int)getSize (sym->type) & 0xffff);
                }
 
+               /* if it has a initial value then do it only if
+               it is a global variable */
+               if (sym->ival) {
+                   /* mark symbol as already defined */
+                   pic14_stringInSet(sym->name, &emitted, 1);
+                   pic14_stringInSet(sym->rname, &emitted, 1);
+               }
 #if 0          
                /* if it has a initial value then do it only if
                it is a global variable */