* device/lib/pic16/libc/stdio/sprintf.c: return the number of
[fw/sdcc] / ChangeLog
1 2006-06-25 Borut Razem <borut.razem AT siol.net>
2
3         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
4           characters printed (not including the trailing '\0' used to end
5           output to strings). Problem detected in regression test bug-927659.c.
6           NOTE: printf() family functions should return int instead
7           unsigned int!
8         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
9           specifier are printed as themselves
10         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
11           support flags, width and precision specifiers
12
13 2006-06-24 Borut Razem <borut.razem AT siol.net>
14
15         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
16           to the list of sdcc tagrets not supporting bit type
17         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
18           testfor pic16 due to bug:
19           [ 1511794 ] pic16: regression test bug-895992.c fails
20
21 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
22
23         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
24         * src/SDCCglue.c (initPointer), fixed bug 1496419
25         * support/regression/tests/bug1496419.c: new, added
26
27 2006-06-22 Borut Razem <borut.razem AT siol.net>
28
29         * support/regression/ports/pic16/support.c: use gpsim usart module from
30           libgpsim_modules library
31
32 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
33
34         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
35         IP0H to IPH0.
36
37 2006-06-19 Raphael Neider <rneider AT web.de>
38
39         * src/pic/glue.h,src/pic16/glue.h: added prototypes
40         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
41           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
42           (pic14printExterns,pic14printPublics,pic16printPublics,
43           pic16_printExterns): use new functions to emit symbols
44           (picglue,pic16glue): emit publics before emitting externs
45         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
46           locally defined functions to avoid bug #1443651
47         * support/regression/tests/bug-716242.c: removed pic16 workaround
48         * support/regression/ports/pic16/spec.mk: ignore errors during build
49
50 2006-06-19 Raphael Neider <rneider AT web.de>
51
52         * src/pic/glue.h: added pic14aopLiteral prototype
53         * src/pic/glue.c (pic14aopLiteral): return unsigned int
54         * src/pic/gen.c: removed stdint.h dependency
55           (aopGet): use Safe_strdup()
56           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
57           (genDataPointerSet): use pic14aopLiteral()
58         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
59           for pic16; thanks to Bernhard and Maarten
60
61 2006-06-18 Borut Razem <borut.razem AT siol.net>
62
63         * support/regression/tests/structflexarray.c: flexible array members
64           not supported by gcc < 3
65         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
66           GUI tool by default
67         * src/pic/gen.c: don't include [p]strdin.h on solaris
68         * support/Util/pstdint.h: addad svn attributes
69         * support/regression/tests/constantRange.c,
70           support/regression/tests/rotate.c: include inttypes.h instead
71           stdint.h on solaris, addad svn attributes
72
73 2006-06-18 Raphael Neider <rneider AT web.de>
74
75         * src/SDCCsymt.c (initCSupport): change return type of divschar to
76           int for PIC16
77         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
78           (pic16_genMinusBits): simplified sign-extension
79           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
80             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
81             adjusted to correctly handle mixed-signed operands, disabled
82             now unused multiplciation routines
83         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
84           (assignResultValue): added argument denoting the size of the result
85             as returned by the function (fixes upcasts in assigning from
86             function calls: char foo(); int i = foo();)
87           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
88             function result to assignResultValue
89           (genMult): disabled inlined multiplication code
90           (genDiv): augmented to also handle the modulus operator, fixed to
91             handle mixed-signed operands correctly
92           (genMod): simply call genDiv, disabled unused code
93           (genAssign): fixed missing (sign-)extension on result
94         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
95             valid char operands, allow signed operands for native code, added
96             division and modulo operator handling
97         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
98
99         As a consequence, onebyte.c (if split into two files) and muldiv.c
100         pass regression tests.
101
102 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
103
104         * doc/Makefile.in: two runs of makeindex seem needed to get
105         correct page references in the index of sdccman.pdf
106         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
107
108 2006-06-17 Borut Razem <borut.razem AT siol.net>
109
110         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
111
112 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
113
114         * doc/sdccman.lyx: updated, added (porting source code, debugging),
115         mentioned ec2drv and paulmon
116
117 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
118
119         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
120           consecutive abs areas
121           (find_empty_space, allocate_space): added map to handle codemap or
122            xdatamap,
123           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
124            absolute idata and xdata
125         * as/mcs51/lkmem.c (summary2): updated legend
126
127 2006-06-16 Raphael Neider <rneider AT web.de>
128
129         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
130
131 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
132
133         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
134           1208515
135         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
136
137 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
138
139         * src/port.h (struct PORT): added field gp_tags, to hold the tag
140         value of generic pointers,
141         * src/avr/main.c,
142           src/ds390/main.c,
143           src/hc08/main.c,
144           src/izt/i186.c,
145           src/izt/tlcs900h.c,
146           src/mcs51/main.c,
147           src/pic/main.c,
148           src/pic16/main.c,
149           src/xa51/main.c,
150           src/z80/main.c: PORT structure, added elements for gp_tags field,
151         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
152         fields in the PORT structure of each port,
153         * src/SDCCast.c (decorateType): allow processing of generic pointers
154         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
155         S_FIXED symbols
156
157 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
158
159         * link/z80/lkgb.c,
160         * link/z80/lkgg.c,
161         * src/pic16/gen.c,
162         * src/pic16/main.c,
163         * src/pic16/pcode.c,
164         * src/pic/main.c,
165         * src/pic/pcoderegs.c,
166         * src/SDCCicode.c,
167         * src/SDCCmain.c,
168         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
169           bug 1504689 on minGW
170
171 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
172
173         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
174
175 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
176
177         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
178
179 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
180
181         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
182           for optimization
183
184 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
185
186         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
187         to a char variable. Fixed bug #1504211
188         * device/include/pic16/adc.h,
189         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
190         and fixed bug #1364390
191
192 2006-06-10 Borut Razem <borut.razem AT siol.net>
193
194         * CVSROOT: removed the CVS left-over
195
196 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
197
198         * as/hc08/asmain.c (asexit),
199         * as/hc08/lkmain.c (lkexit),
200         * as/mcs51/asmain.c (asexit),
201         * as/mcs51/lkmain.c (lkexit),
202         * src/SDCCglue.c (DEFSETFUNC),
203         * src/SDCCmain.c (linkEdit, assemble),
204         * support/librarian/sdcclib.c (AddRel),
205           replaced unlink() by standard C remove()
206         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
207         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
208           gatherImplicitVariables): new, added to fix bug 608752,
209           (createFunction): added gatherImplicitVariables()
210         * src/SDCCast.h: added createRMW prototype
211         * src/SDCCsymt.h (struct symbol): added infertype
212         * support/regression/tests/bug608752.c: new, added
213
214 2006-06-10 Raphael Neider <rneider AT web.de>
215
216         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
217           multibyte dummy reads (fixes #1503234)
218
219 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
220
221         * device/include/mcs51/compiler.h: new, added header file to enable
222           creating common sfr definition header files for different compilers
223
224 2006-06-05 Raphael Neider <rneider AT web.de>
225
226         * src/pic16/{pcode.h,genarith.c}:
227           introduced pCodeOp combining any two pCodeOps (previously only
228           two register operands could be combined), removed pcop2 from
229           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
230         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
231         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
232           rewritten to use new PO_TWO_OPS
233         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
234         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
235           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
236           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
237           (pic16_get_op): embraced return arg to allow #define return(x),
238             added new case for combined opcodes
239           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
240           (pic16_pCode2str,pic16_getRegFrompCodeOp,
241            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
242
243 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
244
245         * src/SDCCval.c (checkConstantRange): added
246         * src/SDCCval.h: added checkConstantRange
247         * support/Util/SDCCerr.c,
248         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
249         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
250         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
251         * src/SDCCast.c (decorateType): added checkConstantRange,
252         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
253         can be emitted with the correct always true/false warning,
254         added optimization for double '!';
255         result of decorateType() must be assigned back to the tree, because
256         decorateType() can change the tree
257         * src/SDCCicode.c (geniCodeLogic),
258         (geniCodeAssign): replaced new checkConstantRange, added warnings,
259         (checkConstantRange): removed, it was only a fragment which never
260         emitted a warning
261         * src/SDCCsymt.c (computeType): fixed promotion for
262         "-1 < (unsigned bit) b"
263         * src/pic/ralloc.c (packRegsForAssign),
264         * src/pic16/ralloc.c (packRegsForAssign),
265         * src/hc08/ralloc.c (packRegsForAssign),
266         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
267         from mcs51
268         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
269         * support/regression/tests/constantRange.c: added
270         * support/valdiag/tests/constantRange.c: added
271         * support/valdiag/valdiag.py: added -DPORT_HOST=1
272
273 2006-06-02 Borut Razem <borut.razem AT siol.net>
274
275         * support/regression/ports/pic16/support.c: increase stack size
276           to 255 bytes
277         * support/regression/Makefile.in: sort tests by name so that the
278           resutlts can be compared on different machines / platforms
279
280 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
281
282         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
283         * src/ds390/gen.c (emitLabel): new, added,
284           (genDjnz): fixed stack overflow bug,
285           (throughout): cosmetic changes to sync with mcs51/gen.c,
286           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
287         * src/mcs51/gen.c (genEndFunction): small optimization,
288           (throughout): cosmetic changes to sync with ds390/gen.c
289
290 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
291
292         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
293           (_print_format): fixed printing pointers
294         * src/mcs51/gen.c (emitLabel, movb): new, added,
295           (genAssign): small optimization,
296           (genDjnz): fixed stack overflow bug,
297           (throughout): replaced sprintf with SNPRINTF,
298           replaced mcs51_regWithIdx with REG_WITH_INDEX,
299           replaced emitcode("mov", "b,...") with MOVB(...),
300           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
301           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
302         * src/mcs51/peeph.def: added rules 140 and 264
303         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
304           so they may get optimized into registers
305
306 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
307
308         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
309           immediately when encountered,
310           (printUsage): always use stderr even on windows
311
312 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
313
314         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
315         (processParms): fixed bug #1247551
316         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
317         parseCmdLine, main): print '--version' to stdout,
318         print 'help' to stdout if --help is given,
319         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
320         arguments are given; fixed --help
321
322 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
323
324         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
325         * support/regression/tests/bug-1493710.c: added
326
327 2006-05-27 Borut Razem <borut.razem AT siol.net>
328
329         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
330           static instead auto
331         * support/regression/ports/pic16/support.c: increase stack size
332           from default 64 bytes to 128 bytes
333         * support/regression/tests/staticinit.c,
334           support/regression/tests/float.c: regression tests fully enabled
335           for pic16 port by putting the initialized data arrays into the code
336           section
337         * support/regression/ports/pic16/spec.mk: don't link default libraries.
338           This was changed by mistake in the previous version.
339
340 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
341
342         * src/pic16/gen.c (genFunction, genEndFunction): some
343         beautifications, fixed bug with falsely restoring FSR2 in large
344         stack model, thanks to Beau E. Cox for reporting the bug
345
346 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
347
348         * debugger/mcs51/break.c,
349         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
350           use %p to print pointers, made address variables unsigned
351         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
352         * debugger/mcs51/symtab.c (parseSymbol): must return something
353         * src/mcs51/gen.c (aopForSym): small optimization,
354            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
355           (freeAsmop): added missing break,
356           (aopPut): removed parameter bvolatile, determine it inside the function,
357           (saveRegisters, unsaveRegisters): small optimization,
358           (genIpush): removed pointless check,
359           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
360           replaced sprintf with SNPRINTF,
361           replaced strcpy with strncpyz,
362           updated aopPut calls,
363           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
364         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
365
366 2006-05-24 Borut Razem <borut.razem AT siol.net>
367
368         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
369           modification of test for the pic16 port, put the array to the code
370           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
371
372 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
373
374         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
375         * support/Util/pstdint.h: added
376
377 2006-05-22 Borut Razem <borut.razem AT siol.net>
378
379         * src/regression/Makefile: removed bool2.c test, added -q linker option
380         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
381           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
382           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
383           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
384           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
385           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
386           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
387           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
388           define SUPPORT_BIT_TYPES 0, removed unused bit variables
389
390 2006-05-22 Raphael Neider <rneider AT web.de>
391
392         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
393           bug #1492360 (problematic due to generic pointers, see code)
394
395 2006-05-22 Borut Razem <borut.razem AT siol.net>
396
397         * support/regression/ports/pic16/specs.mk: removed stack size linker
398           directive
399         * support/regression/tests/array.c,
400           support/regression/tests/bitopcse.c,
401           support/regression/tests/bug-908454.c,
402           support/regression/tests/malloc.c: modified for pic16 regression test
403         * support/regression/tests/bitfields.c:
404           pic16 - excluded bitfileds of size > 8
405         * support/regression/tests/bp.c: pic16 - reduced data size
406         * support/regression/tests/bug-221100.c: pic16 - reduced data size
407         * support/regression/tests/bug-460010.c:
408           pic16 - used the absolute address the fits in memory
409         * support/regression/tests/bug-716242.c:
410           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
411         * support/regression/tests/float.c:
412           pic16 - excluded - data size too big
413         * support/regression/tests/onebyte.c:
414           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
415         * support/regression/tests/shifts.c:
416           pic16 - function names probably have to differ in first X characters
417           (gpasm limitation?)
418         * support/regression/tests/staticinit.c:
419           pic16 - excluded some tests due error: no target memory available for
420           section ".idata"
421
422 2006-05-22 Borut Razem <borut.razem AT siol.net>
423
424         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
425           second try. Thanks Stas Sergeev once more.
426
427 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
428
429         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
430           (genLeftShift, genRightShift): fixed bug 1491627
431         * src/hc08/peeph.def (rules 7, 8.x): added
432         * support/regression/tests/shifts.c (ShiftLeftByParam,
433           ShiftRightByParam, testShiftByParam): added to test variable shifting
434
435 2006-05-20 Raphael Neider <rneider AT web.de>
436
437         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
438         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
439           (allocReg): add only new registers to dynAllocRegs,
440           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
441             #1489055, #1445850, and probably #1483693
442
443 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
444
445         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
446         bug in for-loop that didn't emit the last of CONFIG and ID registers
447
448 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
449
450         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
451           with offset
452         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
453           1489016, 1434401 and 1490124
454         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
455           1489016, 1434401 and 1490124
456
457 2006-05-17 Borut Razem <borut.razem AT siol.net>
458
459         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
460           thanks Stas Sergeev
461
462 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
463
464         * device/include/mcs51/P89c51RD2.h,
465         * device/include/mcs51/P89LPC901.h,
466         * device/include/mcs51/P89LPC922.h,
467         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
468
469 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
470
471         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
472         to fix missing stack pragma in compiled binary object file,
473
474 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
475
476         * support/packihx/configure.in,
477         * support/packihx/configure: removed warning, autoconf >= 2.5x can
478         determine sizeof basic types even while cross compiling
479
480 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
481
482         * src/avr/gen.c (aopop),
483         * src/ds390/gen.c (aopOp),
484         * src/hc08/gen.c (aopOp),
485         * src/mcs51/gen.c (aopop),
486         * src/pic16/gen.c (pic16_aopOp),
487         * src/pic/gen.c (aopOp),
488         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
489         if size of operand is smaller than spill location
490
491 2006-05-12 Borut Razem <borut.razem AT siol.net>
492
493         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
494           have to have CR/LF line endings even if they are checked out on *nix
495           or on WIN32 in cygwin binmode
496
497 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
498
499         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
500         * device/include/ds80c390.h: added sfr16 definitions
501         * src/ds390/gen.c,
502         * src/ds390/gen.h,
503         * src/ds390/main.c,
504         * src/ds390/ralloc.c,
505         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
506           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
507           bit returning functions
508         * support/regression/tests/sfr16.c: enabled test on ds390
509
510 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
511
512         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
513         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
514
515 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
516
517         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
518         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
519           (cl_address_space constructor): removed expensive initialization,
520           (cl_address_space::get_cell): extended for late initialization,
521           (cl_address_space::*): use late initialization,
522           (cl_address_decoder::activate): removed expensive initialization,
523           This reduced regression test running time by 25%
524
525 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
526
527         * packihx/,
528         * configure.in,
529         * configure,
530         * sdcc.dsw,
531         * Makefile.bcc,
532         * Makefile.in,
533         * support/packihx/Makefile.in,
534         * support/packihx/clean.mk,
535         * support/packihx/Makefile.bcc,
536         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
537
538 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
539
540         * src/SDCCval.c (valNot): fix for regression test failure
541           of not.c on big endian hosts
542
543 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
544
545         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
546
547 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
548
549         * device/lib/mcs51/Makefile.in: changed string comparison operator
550           to = for POSIX compliance; == is bash extension
551
552 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
553
554         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
555           kosmonaut_pirx
556
557 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
558
559         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
560         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
561         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
562         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
563         bug report #1478657,
564
565 2006-05-05 Borut Razem <borut.razem AT siol.net>
566
567         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
568           making the html
569
570 2006-05-02 Borut Razem <borut.razem AT siol.net>
571
572         * doc/Makefile.in: removed *.ind dependency since there is no rule to
573           create *.ind, which made make to fail if invoked with -j 2
574
575 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
576
577         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
578           Hubert Sack for patch 1479782
579
580 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
581
582         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
583
584 2006-05-01 Raphael Neider <rneider AT web.de>
585
586         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
587           (create_pic): store only prefix-free device name,
588           (init_pic): check for device names with "16" prefix,
589           (list_valid_pics),
590         * src/pic/device.h (struct PIC_device),
591         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
592             stored device name,
593         * device/include/pic/pic12f{635,675,629,683}.h,
594         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
595         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
596         * device/include/pic/pic16f505.h,
597         * device/lib/pic/libdev/pic16f505.c: removed
598         * device/include/pic/pic14devices.txt: added support for pic12f
599             devices, removed unsupported non 16-bit devices
600             [above changes provided by patch from Zik Saleeba]
601         * src/pic/*, src/pic16/*, device/include/pic16/*,
602           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
603
604 2006-05-01 Borut Razem <borut.razem AT siol.net>
605
606         * configure.in, configure, doc/Makefile.in:
607           sync with nightly build makefile - latex, dvipdf and dvips
608           not needed any more
609
610 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
611
612         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
613         in the library source
614
615 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
616
617         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
618
619 2006-04-28 Raphael Neider <rneider AT web.de>
620
621         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
622         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
623           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
624         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
625
626 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
627
628         * device/lib/pic/libdev/Makefile.in,
629         * device/lib/hc08/Makefile.in,
630         * device/lib/gbz80/Makefile.in,
631         * device/lib/z80/Makefile.in,
632         * device/lib/ds390/Makefile.in,
633         * device/lib/ds400/Makefile.in: added srcdir to include search path,
634         thanks to Borut for the bug report
635         * configure.in,
636         * configure: always create doc/Makefile independent from --enable-doc
637         * Makefile.in: always install from directory doc independent from
638         --enable-doc
639         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
640         removed
641         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
642         * doc/Makefile.in: install *.txt if present
643         * device/include/Makefile.in (install): added installation of pic/*.inc
644         and pic/*.txt files again, they were erroneously removed
645
646 2006-04-28 Raphael Neider <rneider AT web.de>
647
648         * src/pic/{gen.c,main.h,pcode.c},
649         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
650             concerning signedness with casts
651
652 2006-04-28 Raphael Neider <rneider AT web.de>
653
654         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
655             definition of an interrupt handler,
656         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
657             interrupt handler stuff from picglue() to separate routine,
658           (picglue): enabled definition of intr handlers in files w/o main()
659
660 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
661
662         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
663           compilation with MSVC 2005 Express Edition (VC8)
664
665 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
666
667         * device/lib/Makefile: fixed build of gbz80 lib
668
669 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
670
671         * support/regression/tests/bug-460010.c,
672         * support/regression/tests/bug-524691.c,
673         * support/regression/tests/bug-716242.c: removed conditional defines
674           that are already in testfwk.h
675
676 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
677
678         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
679           (AccAXRsh1): added, shift right by 1,
680           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
681            AccAXLrl1
682         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
683
684 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
685
686         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
687         remove cast to same type
688         * src/SDCCast.c (decorateType): fix for RFE 1475742,
689         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
690         * as/z80/Makefile,
691         * link/z80/Makefile: removed, they have moved to
692         Makefile.in files
693         * configure,
694         * configure.in: replaced duplicate message about ucsim by missing sdcpp
695         * install-sh: fix bug #1204398 by setting umask 0022
696         * device/lib/Makefile: separate build of z80 and gbz80 lib
697
698 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
699
700         Enabled VPATH feature: changed nearly all Makefiles (149 files).
701         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
702
703         One basic decision: e.g. src/clean.mk includes further files. In order
704         to make this work there are two solutions:
705         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
706           run configure on them. This way they can use
707           'include $(srcdir)/port-clean.mk'
708         - always include clean.mk by the Makefile at the same level. To avoid
709           that `make clean` tries to include and build Makefile.dep the
710           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
711           implemented, because now even `make uninstall` doesn't create
712           Makefile.in. clean.mk could be eliminated by pasting it in
713           Makefile.in.
714
715         * debugger/mcs51/Makefile.in: build own objects from library sources
716         (SLIB, SDCC) in current directory
717
718         * configure, configure.in: renamed --disable-device-lib-build in
719         --disable-device-lib; added --enable-doc, the required tools are
720         searched by configure; added result message; the toolchain for the
721         belonging ports are now only built, if the port is enabled.
722
723         * support/regression/*: all output is written in directory gen, because
724         the fwk and ports directories don't livet in the build tree using vpath
725
726         * doc/sdccman.lyx: renamed --disable-device-lib-build to
727         --disable-device-lib, added --enable-doc, added section VPATH
728
729         * sim/ucsim/configure.in,
730         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
731         z80 are enabled by default
732
733 2006-04-24 Raphael Neider <rneider AT web.de>
734
735         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
736             to config word, "pic14_"-prefixed some extern functions
737           (pic14_emitConfigWord): emit __config directive(s) if assignment to
738             config word has been found
739         * src/pic/device.h: added prototypes
740         * src/pic/pcode.c: added "pic14_"-prefix where needed
741         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
742             fixup
743         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
744             words,
745           (pic14emitRegularMap): ignore config words,
746           (pic14createInterruptVect): moved generating __config directives away
747           (picglue): have __config directives emitted
748
749 2006-04-24 Borut Razem <borut.razem AT siol.net>
750
751         * doc/Makefile: sync with nightly build makefile
752
753 2006-04-24 Raphael Neider <rneider AT web.de>
754
755         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
756             registers that have not been assigned proper liveranges,
757             fixes #1469504 and #1474602,
758           (pCodeRegOptimizeRegUsage): fixed typo in comment
759
760 2006-04-24 Borut Razem <borut.razem AT siol.net>
761
762         * device/examples/main8051.c: deleted - it was removed from CVS
763           24.mar.2000 and after that modified 18.feb.2001, so it reappered
764           after the transition to Subversion
765         * src/SDCCalloc.h: deleted - it was removed  from CVS
766           3.feb.2001 and after that modified 18.feb.2001, so it reappered
767           after the transition to Subversion
768         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
769           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
770           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
771           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
772
773 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
774
775         * as/asx8051.dsp: added mcs51/strcmpi.h
776         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
777         * as/hc08/aslink.h: updated lnksect prototype
778         * as/hc08/asm.h,
779         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
780         * as/hc08/asmain.c,
781         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
782           (newdot): handle A_ABS
783         * as/hc08/asout.c,
784         * as/mcs51/asout.c (outarea): output address
785         * as/hc08/lkaomf51.c,
786         * as/mcs51/lkaomf51.c: disabled unused array UsageType
787         * as/hc08/m08pst.c,
788         * as/mcs51/i51pst.c,
789         * as/z80/z80pst.c: "ABS" is not A_OVR
790         * as/hc08/lkarea.c (newarea): read a_addr,
791           (lnkarea): added codemap array, sort absolute areas to the front,
792            combine all GSINITx/GSFINAL,
793           (find_empty_space, allocate_space): new functions,
794           (lnksect): return next address, handle absolute sections
795         * as/mcs51/lkarea.c (newarea): read a_addr,
796           lnksect2 prototype changed,
797           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
798           (find_empty_space, allocate_space): new, factored out of lnksect2,
799           (lnksect2): return next address, handle absolute sections
800         * as/hc08/lkhead.c,
801         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
802         * as/hc08/lklibr.c (addfile, fndsym),
803         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
804           index out of range and detect both '\' and '/'
805         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
806         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
807           regression tests (ds390 cannot return bool yet)
808         * doc/sdccman.lyx: changed version number, document changed --no-peep,
809           document critical interrupts on z80, document changed SDCC define
810         * src/asm.c (_asxxxx_mapping): fixed .org directive,
811           (_a390_mapping): added .org directive
812         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
813           (genMultOneByte): fixed warnings
814         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
815           ones
816         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
817         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
818           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
819         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
820         * src/pic16/main.c: removed newReg prototype
821         * src/pic16/pcode.c,
822         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
823           warnings
824         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
825           ones
826         * src/pic16/ralloc.c
827         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
828           to fix warnings
829         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
830           from short to PIC_OPTYPE
831         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
832         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
833           optype from short to PIC_OPTYPE
834         * src/port.h: made int_size unsigned to fix warnings
835         * src/SDCC.y: fixed warning on MSVC
836         * src/SDCCicode.c (getArraySizePtr): return unsigned int
837         * src/SDCCopt.c (convertToFcall): fixed warnings
838         * src/SDCCsymt.h: removed double prototype for genSymName
839         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
840           offset int to fix warnings
841
842 2006-04-22 Borut Razem <borut.razem AT siol.net>
843
844         * doc/sdccman.lyx, */Makefile, */Makefile.in:
845           references to CVS replaced with Subversion
846
847 2006-04-21 Borut Razem <borut.razem AT siol.net>
848
849         * doc/sdccman.lyx, */Makefile, */Makefile.in:
850           references to CVS replaced with Subversion
851
852 2006-04-19 Borut Razem <borut.razem AT siol.net>
853
854         * src/version.awk: adapted for svn
855         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
856           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
857           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
858           /binutils-avr/etc/*.vi, *.jin: removed all properties
859           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
860
861 2006-04-19 Borut Razem <borut.razem AT siol.net>
862
863         * CVS to Subversion migration completed
864
865 2006-04-18 Borut Razem <borut.razem AT siol.net>
866
867         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
868           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
869
870 2006-04-17 Borut Razem <borut.razem AT siol.net>
871
872         * device/include/Makefile.in: added pic/*.inc to the installation
873
874 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
875
876         * support/regression/collate-results.py: fixed output in case of
877         a valdiag error
878         * support/regression/generate-cases.py: fixed splitting of pathnames
879         with dots
880         * as/hc08/lklibr.c (addfile),
881         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
882
883 2006-04-11 Raphael Neider <rneider AT web.de>
884
885         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
886         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
887         * src/pic16/pcode.c (assignValnums): fixed #1460578
888
889 2006-04-11 Raphael Neider <rneider AT web.de>
890
891         * device/lib/pic/libdev/*.c,
892         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
893           fixes #1468739, enables compilation in --std-c99 mode
894         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
895
896 2006-04-11 Raphael Neider <rneider AT web.de>
897
898         * src/pic/device.c (find_device): removed debug output
899           (list_valid_pics): enabled verbose listing of supported devices
900         * device/include/stdbool.h: define bool as char for pic14/16 as well
901
902 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
903
904         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
905
906 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
907
908         * .version: bumped version to 2.5.6
909         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
910
911 2006-04-06 Raphael Neider <rneider AT web.de>
912
913         * .version: bumped version to 2.5.6 (pic14 ABI changed)
914         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
915         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
916           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
917             pic14_constructAbsMap
918           (pic14printPublics): declare absolute global symbols as global
919           (pic14createInterruptVect),
920         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
921           (newReg): assume new registers unused, use correct name in
922             hashtable (reg->name instead of name), more debugLog output
923         * src/pic/device.h (PIC_device): added fields for verbose output
924         * src/pic/device.c: moved device definition to pic14devices.txt,
925             added routines for runtime parsing of pic14devices.txt,
926             added support for second config word
927         * src/pic/main.c (_process_pragma): removed #pragma maxram,
928           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
929           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
930           (_pic14_parseOptions): moved pCodeInitRegisters here
931           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
932         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
933           (pCodeInitRegisters): rewrapped comments, perpared new approach to
934             handling the pseudo stack
935         * device/lib/Makefile.in: ignore failures in objects-pic16,
936         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
937         * device/lib/pic/NEWS: document new dependency on picXXX.lib
938         * device/lib/pic/Makefile.subdir,
939         * device/lib/pic16/Makefile.subdir: improved clean rules
940         * device/lib/pic/libdev/: NEW, pic14 device libraries
941         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
942         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
943         * device/include/Makefile.in: create subdir and install pic14 headers
944         * device/include/pic/p16f_common.inc: removed unused declarations
945         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
946             PICs from inc2h.pl v1.6,
947             replaced BIT_AT macros with struct declarations
948         * device/include/pic/pic14devices.txt: definition of supported devices,
949             all above improvements contributed by Zik Saleeba, thanks
950         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
951         * support/scripts/sdcc.nsi: also install pic14 device libraries and
952             headers
953
954 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
955
956         * device/include/mcs51/c8051f410.h: added interrupt numbers,
957         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
958           thanks to Charles Olds
959
960 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
961
962         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
963
964 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
965
966         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
967         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
968         * support/regression/bug1464657.c: added, new test
969
970 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
971
972         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
973           version number
974
975 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
976
977         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
978           --no-peep and --peep-file <file> are used don't use default rules but
979           do use the <file>
980
981 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
982
983         * src/mcs51/gen.c (genCall): fixed bug 1457608
984
985 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
986
987         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
988         changes seem to cause (trigger?) problems with the build system.
989
990 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
991
992         * src/SDCCpeeph.c (operandsLiteral): new, added,
993           (callFuncByName): inserted operandsLiteral
994         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
995
996 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
997
998         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
999         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
1000
1001 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1002
1003         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
1004           implemented patch 1120823 Thanks to Willy De la Court (normal
1005           interrupts need an interrupt number now if they are made critical),
1006           and enabled nesting of critical functions though not for gbz80
1007           (genCritical, genEndCritical): added functions
1008           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
1009         * src/z80/mappings.i: added "ei" to all mappings
1010
1011 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1012
1013         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
1014         submitted by the Debian SDCC maintainer Aurelien Jarno:
1015         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
1016         archive with gcc 4.1 on mips and wrote the patch"
1017
1018 2006-03-16 Raphael Neider <rneider AT web.de>
1019
1020         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
1021           the left operand is shorter than the result (c* = lit-c* + int),
1022           fixes bug #1450796
1023         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
1024           OP_SYMBOL
1025
1026 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
1027
1028         * src/.version: increased version number to 2.5.5
1029         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
1030         linking is done manually in pic16 port's _linkEdit,
1031         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
1032         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
1033         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
1034         allocate asmop as AOP_ACC,
1035         (aopForRemat): added parameter 'bool result' in function declaration,
1036         (pic16_aopGet): return AOP_ACC when accessing WREG,
1037         (pic16_popGetTempReg): minor modification,
1038         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
1039         'pic16_allocWithIdx',
1040         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
1041         calling function in absolute addresses,
1042         (genAssign): take into account AOP_ACC asmop,
1043         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
1044         * src/pic16/pcoderegs.c: some debug functions and lines added,
1045         * src/pic16/ralloc.c (decodeRegType): added but commented out,
1046         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
1047         register too,
1048         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
1049         call to allocReg, not by manually allocating a new one,
1050         (pic16_assignRegisters): now before going through the register
1051         allocating functions mark all registers as free. This eliminates some
1052         side effects resulting from peephole parser done earlier in the backbone
1053
1054 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
1055
1056         * src/SDCCicode.c (geniCodeLogic),
1057         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
1058
1059 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
1060
1061         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
1062           (genSend): bugfix, do not allocate and free twice,
1063           (shiftRLong): handle partially overlapping aops
1064         * support/regression/tests/bitopcse.c: fixed warning redefined idata
1065
1066 2006-03-08 Borut Razem <borut.razem AT siol.net>
1067
1068         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
1069           for pic16
1070
1071 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
1072
1073         * support/regression/tests/bug1409955.c: new, added
1074         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
1075         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
1076           (aopForSym, aopOp): increment asmop.allocated if reused,
1077           (freeAsmop): decrement asmop.allocated and check for zero instead of
1078           using asmop.freed,
1079           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
1080           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
1081            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
1082            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
1083            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
1084            genSignedRightShift, genRightShift, genDataPointerGet,
1085            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
1086            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
1087             in reverse order from allocation,
1088           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
1089             added swappedLR to keep track
1090         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
1091           pdata & code for GCC, z80, gbz80 & hc08
1092         * support/regression/tests/zeropad.c: moved defines to testfwk.h
1093
1094 2006-03-08 Raphael Neider <rneider AT web.de>
1095
1096         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
1097
1098 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
1099
1100         * device/include/mcs51/c8051f410.h: new SiLabs mcu
1101         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
1102         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
1103
1104 2006-03-06 Borut Razem <borut.razem AT siol.net>
1105
1106         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
1107           made the linker quiet
1108
1109 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
1110
1111         * src/pic16/gen.c (genPcall): fixed bug #1443644
1112         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
1113         which dumps before the function entry point a data byte which represents
1114         the number of the local variables used by the specified function, added
1115         'xinst' for initial support for Extended Instruction Support,
1116         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
1117         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
1118         port->fun_prefix anymore (may change later),
1119         (genFunction, genEndFunction): do not store/restore local registers for
1120         _main (this should take care the --main-return command line option in
1121         the future),
1122         (genOr): removed some legacy pic-port instructions,
1123         * src/pic16/genarith.c (genAddLit): re-enabled old code because
1124         performing operations with SFR's causes data to be written more than
1125         once to each SFR. Perhaps SFRs should be handled in special cases...
1126         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
1127         pcode.h
1128         * src/pic16/main.c (_process_pragma): stack bound checking did not take
1129         into account for stack starting position,
1130         (struct OPTIONS pic16_optionsTable): added command line argument
1131         --extended or -y for Extended Instruction Support,
1132         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
1133         (deassignLRs): *** perhaps the most important change, old 'for' code
1134         (commented out for reference), didn't account for some registers which
1135         were left marked 'not free' after a pointer operation. The change
1136         reduces register usage a lot in some cases
1137
1138 2006-03-04 Borut Razem <borut.razem AT siol.net>
1139
1140         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
1141           _clean
1142         * support/regression/tests/bug-524697.c: decreased array size for
1143           mcs51 to fit into the internal RAM
1144         * support/regression/Makefile.in: a little bit more verbose
1145
1146 2006-03-03 Borut Razem <borut.razem AT siol.net>
1147
1148         * support/regression/fwk/lib/testfwk.c,
1149           support/regression/fwk/include/testfwk.h: introduced function
1150           _prints(), nonrecursive _printn(), call _initEmu() from main()
1151         * support/regression/ports/gbz80/support.asm,
1152           support/regression/ports/ucz80/support.asm,
1153           support/regression/ports/z80/support.asm,
1154           support/regression/ports/ds390/support.c,
1155           support/regression/ports/hc08/support.c,
1156           support/regression/ports/host/support.c,
1157           support/regression/ports/mcs51/support.c,
1158           support/regression/ports/xa51/support.c: added empty _initEmu()
1159           function
1160         * support/regression/ports/pic16/gpsim.cmd,
1161           support/regression/ports/pic16/spec.mk,
1162           support/regression/ports/pic16/support.c,
1163           support/regression/Makefile.in: added pic16 regression test
1164
1165 2006-03-01 Raphael Neider <rneider AT web.de>
1166
1167         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
1168           genConstPointerGet): use safe way of generating MOVFF to cover
1169             literals as well as registers, fixes bug #1440527
1170         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
1171             dereference
1172           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
1173             more correctly, fixes bug #1232186
1174           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
1175         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
1176             gplink guess the correct processor in more cases, applied patch
1177             from Till Riedel attached to and fixing bug #1436552
1178
1179 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1180
1181         * support/regression/tests/array.c: added, contains check for #1434401
1182         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
1183
1184 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
1185
1186         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
1187         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
1188         * device/include/mcs51/c8051f326.h,
1189         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
1190         * device/include/mcs51/c8051f000.h,
1191         * device/include/mcs51/c8051f018.h,
1192         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
1193           PCON_IDLE,PCON_STOP and added sfr16 definitions
1194
1195 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1196
1197         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
1198           genGetWord): fixed bug 1409955
1199
1200 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1201
1202         * device/include/hc08/mc68hc908gp32.h,
1203         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
1204
1205 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
1206
1207         * src/SDCCast.c (constExprValue): return NULL if not a value
1208         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
1209         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
1210         * support/regression/tests/bitfields.c: enabled signed bitfield for all
1211
1212 2006-02-13 Borut Razem <borut.razem AT siol.net>
1213
1214         * src/regression/ptrarg.c: added, fails due to bug #1430967
1215         * src/regression/Makefile: ptrarg.c added, ...
1216
1217 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1218
1219         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
1220         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
1221
1222 2006-02-11 Borut Razem <borut.razem AT siol.net>
1223
1224         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
1225           print "Processor: xxx" message to stdout only if --verbose
1226
1227 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1228
1229         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
1230         * support/regression/tests/bug1426356.c: added
1231         * support/regression/tests/bitfields.c: removed 2 tests
1232
1233 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
1234
1235         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
1236         * device/include/mcs51/c8051f330.h,
1237         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
1238           PCON_IDLE,PCON_STOP and added sfr16 definitions
1239         * device/lib/_divsint.c,
1240         * device/lib/_divuint.c,
1241         * device/lib/_divulong.c,
1242         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
1243           register bank bug for small stackauto
1244
1245 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
1246
1247         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
1248
1249 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
1250
1251         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
1252         * all.dsp: corrected several bin paths
1253         * device/include/mcs51/c8051f120.h,
1254         * device/include/mcs51/c8051f300.h,
1255         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
1256           to PCON_IDLE,PCON_STOP
1257         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
1258         * device/lib/printf_large.c (output_float): fixed bug 1388703
1259         * support/regression/tests/bug1057979.c: added test for bug 1388703
1260
1261 2006-02-08 Raphael Neider <rneider AT web.de>
1262
1263         * src/pic/pcode.c (pciTRIS): fixed typo,
1264           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
1265           (LinkFlow): fixed handling of flows that end in a call,
1266           (ReuseReg): perform safety check earlier
1267         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
1268             to work with flows at the beginning of a pBlock,
1269             fixes #1426557 (Symbol not previously defined),
1270           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
1271             usage information
1272           (RemoveUnusedRegisters): update register usage info
1273         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
1274             created, reuse existing ones instead
1275         * src/pic/gen.c (genPcall): fixed #1424719
1276
1277 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
1278
1279         * link/z80/lkmain.c,
1280         * link/z80/lklex.c,
1281         * link/z80/lkdata.c,
1282         * link/z80/aslink.h: fixed build on current cygwin:
1283         replaced getline() by lk_getline()
1284
1285 2006-02-01 Borut Razem <borut.razem AT siol.net>
1286
1287         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
1288           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
1289           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
1290           src/regression/bool1.c, src/regression/bool2.c,
1291           src/regression/bool3.c, src/regression/call1.c,
1292           src/regression/compare.c, src/regression/compare10.c,
1293           src/regression/compare2.c, src/regression/compare3.c,
1294           src/regression/compare4.c, src/regression/compare5.c,
1295           src/regression/compare6.c, src/regression/compare7.c,
1296           src/regression/compare8.c, src/regression/compare9.c,
1297           src/regression/configword.c, src/regression/for.c,
1298           src/regression/inline.c, src/regression/mult1.c,
1299           src/regression/nestfor.c, src/regression/or1.c,
1300           src/regression/pointer1.c, src/regression/ptrfunc.c,
1301           src/regression/rotate1.c, src/regression/rotate2.c,
1302           src/regression/rotate3.c, src/regression/rotate4.c,
1303           src/regression/rotate5.c, src/regression/rotate6.c,
1304           src/regression/rotate7.c, src/regression/string1.c,
1305           src/regression/struct1.c, src/regression/sub.c,
1306           src/regression/sub2.c, src/regression/switch1.c,
1307           src/regression/while.c, src/regression/xor.c,
1308           src/regression/create_stc, src/regression/simulate,
1309           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1310           regression tests
1311         * src/regression/gpsim_assert.h: added
1312
1313 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1314
1315         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1316         ((void (code *) (void)) 0) ();
1317         * as/hc08/aslex.c,
1318         * as/hc08/aslink.h,
1319         * as/hc08/asm.h,
1320         * as/hc08/asmain.c,
1321         * as/hc08/lkdata.c,
1322         * as/hc08/lklex.c,
1323         * as/hc08/lkmain.c,
1324         * as/mcs51/aslex.c,
1325         * as/mcs51/aslink.h,
1326         * as/mcs51/asm.h,
1327         * as/mcs51/asmain.c,
1328         * as/mcs51/lkdata.c,
1329         * as/mcs51/lklex.c,
1330         * as/mcs51/lkmain.c,
1331         * as/z80/aslex.c,
1332         * as/z80/asm.h,
1333         * as/z80/asmain.c: fixed build on current cygwin:
1334         replaced getline() by as_getline()
1335
1336 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1337
1338         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1339         declarator in the symbol chain
1340         * src/SDCCsymt.h,
1341         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1342         parameter list for function pointers
1343         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1344         * support/regression/tests/bug-716242.c: added
1345
1346 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1347
1348         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1349         offset if possible
1350         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1351
1352 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1353
1354         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1355         inifinitely recurseable, added static
1356         * support/regression/tests/bug-1408066.c: added
1357
1358 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1359
1360         * src/SDCCicode.h,
1361         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1362         renamed, added possibility to create "postLoopLbl"-labels
1363         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1364         newiTempLoopHeaderLabel
1365         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1366         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1367         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1368         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1369         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1370         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1371         (basicInduction): fixed bug #136564, made static,
1372         (loopInduction): changed parameter of basicInduction, made static,
1373         (addPostLoopBlock): added
1374         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1375         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1376         findLoopEndSeq
1377         * support/regression/tests/bug-136564.c: added
1378         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1379         --std-sdcc99 to LIBSDCCFLAGS
1380
1381 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1382
1383         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1384         while loop
1385         * support/regression/tests/bug-1406131.c: added
1386
1387 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1388
1389         * src/SDCCast.c (decorateType): fix promotion of unary minus
1390         * src/SDCCsymt.c (computeType): beautified
1391         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1392         (valUnaryPM, valComplement): fix sign and promotion,
1393         (valNot): ANSI: result type is int (SDCC: unsigned char)
1394         * support/regression/tests/uminus.c: speedup by removing superflous
1395         test case 'int'
1396         * support/regression/tests/onebyte.c: added promotion and signedness
1397         tests for unary minus
1398         * support/regressions/tests/bug-477927.c: disable warning about
1399         uninitialized variables
1400         * support/regression/tests/not.c: added
1401
1402 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1403
1404         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1405         * src/mcs51/gen.c (gen51Code): show final register usage after
1406         fillGaps in asm with --i-code-in-asm
1407         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1408         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1409         incUsed, rliveClear, adjustIChain): made static,
1410         (setFromRange): excluded because it's unused,
1411         (findPrevUseSym, markWholeLoop): added,
1412         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1413         through all branches of predecessors enables sdcc to emit the warning
1414         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1415         (rlivePoint): made static, added parameter emitWarnings which is only
1416         true during the first run out of two,
1417         (findRecursiveSucc, findRecursivePred): removed,
1418         (computeLiveRanges): made static, added parameter emitWarnings,
1419         (dumpIcRlive): added for debugging only
1420         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1421         removed prototype of setFromRange()
1422         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1423         in call of computeLiveRanges()
1424         * support/regression/tests/bug-895992.c: added
1425         * support/regression/tests/bug-971834.c: added
1426         * support/valdiag/tests/bug-895992.c: added
1427         * support/valdiag/tests/bug-971834.c: added
1428
1429 2005-12-18 Raphael Neider <rneider AT web.de>
1430
1431         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1432           (genUnpackBits): improved code for direct operands,
1433           (genPackBits): improved code for literal assignment to bitfields
1434             and for direct destination operands (no FSR indirection),
1435             prevented redundant AND, fixes #1362800,
1436           (AccLsh): added parameter to disable masking of the result
1437         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1438           skip instructions with side-effects (like incfsz),
1439           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1440         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1441         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1442           fixes #1375263
1443
1444 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1445
1446         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1447         volatile variables as spill location
1448
1449 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1450
1451         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1452         replacing literals
1453         * support/regression/tests/bug-1376320.c: added
1454
1455 2005-12-08 Raphael Neider <rneider AT web.de>
1456
1457         * src/pic/device.c: renamed is_shared to pic14_is_shared
1458         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1459         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1460           (is_valid_identifier): added for above workaround
1461
1462 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1463
1464         * device/lib/Makefile.in: fixed to enable port-specific-objects
1465         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1466           char, thanks Hubert Sack
1467         * doc/sdccman.lyx: documented --xstack-loc,
1468           elaborated a bit more on interrupts and pitfalls,
1469           removed "setjmp/longjmp unsupported",
1470           documented some unsupported C99 features
1471         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1472         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1473           if, thanks Hubert Sack
1474         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1475         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1476           make make_library
1477         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1478           regression tests can report resource usage (rfe 700441)
1479         * support/regression/collate-results.py: report resource usage
1480         * support/regression/ports/ds390/spec.mk,
1481         * support/regression/ports/hc08/spec.mk,
1482         * support/regression/ports/mcs51/spec.mk,
1483         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1484         * support/regression/ports/ds390/uCsim.cmd,
1485         * support/regression/ports/hc08/uCsim.cmd,
1486         * support/regression/ports/mcs51/uCsim.cmd,
1487         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1488         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1489           library, use the default one
1490         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1491           building the library
1492
1493 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1494
1495         * config.dsp: added dependency on .version and configure_vc.awk
1496         * device/include/setjmp.h: updated for --stack-auto and --xstack
1497         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1498         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1499         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1500         * device/lib/libsdcc.lib: added _setjmp
1501         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1502           (decorateType): fixed bug 1372851,
1503           (optimizeGetHbit): fixed warning
1504         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1505           array initialisation
1506         * support/regression/tests/bug1057979.c: added test for bug 1358192
1507         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1508
1509 2005-12-03 Borut Razem <borut.razem AT siol.net>
1510
1511         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1512           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1513
1514 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1515
1516         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1517         createIval): implement symbol independant "flexible array member",
1518         (createIvalCharPtr): implemented flexible array initialisation with a
1519         string
1520         * src/SDCCsymt.c (copyStruct): removed,
1521         (getSize): fixed misleading comment,
1522         (getAllocSize): removed, the additional allocation size is now in
1523         sym->flexArrayLength,
1524         (checkStructFlexArray): new, syntax checks for flexible array members,
1525         (compStructSize): added syntax checks for "flexible array members"
1526         (copyStruct): removed,
1527         (copyLinkChain): removed inefficient fix for bug 770487
1528         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1529         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1530         symbol->flexArrayLength
1531         * src/SDCCerr.c,
1532         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1533         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1534         * support/regression/tests/structflexarray.c: added
1535         * support/valdiag/tests/structflexiblearray.c: added
1536
1537 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1538
1539         * src/SDCCast.c (decorateType): fixed bug 1368489
1540         * support/Util/SDCCerr.c,
1541         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1542
1543 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1544
1545         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1546           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1547
1548 2005-11-27 Borut Razem <borut.razem AT siol.net>
1549
1550         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1551           support/cpp2/mkdeps.h: added command line option
1552           -obj-ext=<extension> to SDCPP to define object file externion, used
1553           for generation of make dependencies (-M)
1554         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1555
1556 2005-11-26 Borut Razem <borut.razem AT siol.net>
1557
1558         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1559           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1560           added pic and pic16 libraries
1561
1562 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1563
1564         * device/include/float.h: Corrected typo in prototype of __fsgt
1565
1566 2005-11-25 Borut Razem <borut.razem AT siol.net>
1567
1568         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1569           added creation of model-mcs51-stack-auto libraries
1570
1571 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1572
1573         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1574         and fields-list too
1575         * src/SDCCast.c (createIvalArray): removed obsolete comment
1576
1577 2005-11-24 Borut Razem <borut.razem AT siol.net>
1578
1579         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1580           added missing device/lib/mcs51/crt*.asm sources
1581
1582 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1583
1584         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1585
1586 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1587
1588         * device/lib/_fs2schar.c,
1589         * device/lib/_fs2sint.c,
1590         * device/lib/_fs2slong.c: optimized inline asm
1591
1592 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1593
1594         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1595           Better handling of floats between -1.0 and 0.0.
1596
1597 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1598
1599         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1600           (the missing "if"s prohibited removal of redundant labels)
1601
1602 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1603
1604         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1605           Properly convert floats between -1.0 and 0.0 to long, int, and char
1606           types (max integer value of negative floats tends to zero).
1607         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1608           Removed changes made so to work properly with floats between
1609           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1610           and _fs2char.c
1611
1612 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1613
1614         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1615         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1616         (genCast) cosmetic change
1617         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1618         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1619         from mcs51
1620         * support/regression/tests/bitfields (testSignedBitfields): added
1621
1622 2005-11-18 Borut Razem <borut.razem AT siol.net>
1623
1624         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1625         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1626           introduced SILENT option to make building of pic16 libraries less
1627
1628 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1629
1630         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1631           Now they work properly with floats between -1.0 and 0.0
1632         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1633
1634 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1635
1636         * src/SDCCicode.c (printOperand): added missing else
1637
1638 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1639
1640         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1641         reformatted for better readability
1642         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1643         signed bitfields
1644
1645 2005-11-17 Borut Razem <borut.razem AT siol.net>
1646
1647         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1648           introduced SILENT option to make building of pic16 libraries less
1649           verbose - used for nightly snapshot build
1650         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1651           available on Win32 platforms.
1652         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1653           medium, large, pic and pic16
1654
1655 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1656
1657         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1658           printf("%f"...) sets fraction to zero.
1659
1660 2005-11-16 Raphael Neider <rneider AT web.de>
1661
1662         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1663           fixes #1357221
1664         * src/pic/gen.c (genIfx): implemented for CARRY bit
1665         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1666           to generic pointers, fixes #1357332,
1667           (pic16_movLit2f): NEW,
1668           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1669
1670 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1671
1672         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1673
1674 2005-11-11 Raphael Neider <rneider AT web.de>
1675
1676         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1677         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1678           compute pointer's type from operand,
1679           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1680           improved single bit reads, fixes bug #1353379
1681
1682 2005-11-09 Borut Razem <borut.razem AT siol.net>
1683
1684         * support/scripts/sdcc.nsi: added lib/pic to the package
1685
1686 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1687
1688         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1689
1690 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1691
1692         * support/regression/tests/bug1348008.c: added
1693         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1694         * support/regression/tests/bug1337835.c: updated comment
1695
1696 2005-11-06 Borut Razem <borut.razem AT siol.net>
1697
1698         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1699           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1700           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1701           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1702           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1703           dynamic construction of cl_error_class and derivates - 2.nd try
1704
1705 2005-11-05 Borut Razem <borut.razem AT siol.net>
1706
1707         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1708           bug, which caused Bus Errors on sparc solaris
1709
1710 2005-11-04 Borut Razem <borut.razem AT siol.net>
1711
1712         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1713           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1714           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1715           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1716           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1717           and derivates to resolve the initialization problem on OSX
1718
1719 2005-11-02 Borut Razem <borut.razem AT siol.net>
1720
1721         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1722           corrected typo - #include <winsock2.h>
1723
1724 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1725
1726         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1727           (_asxxxx_mapping): added org directive for future enhancements
1728
1729 2005-11-01 Borut Razem <borut.razem AT siol.net>
1730
1731         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1732           enabled sockets on WIN32
1733         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1734
1735 2005-10-31 Borut Razem <borut.razem AT siol.net>
1736
1737         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1738           WIN32 backslash path delimiters should be escaped when used in C strings
1739         * support/regression/tests/bitfields.c: exclude failing assertions for
1740           __CYGWIN32__ and __MINGW32__ hosts
1741
1742 2005-10-30 Borut Razem <borut.razem AT siol.net>
1743
1744         * src/SDCCutil.c: corrected double comparison typo
1745
1746 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1747
1748         * device/lib/medium/Makefile: added for new memory model medium
1749         * device/include/asm/mcs51/features.h: updated for medium/pdata
1750         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1751           added Multiply & Accumulate sbit's and MAC0_PAGE define
1752         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1753         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1754         * device/lib/_mullong.c: update for medium model
1755         * device/lib/incl.mk: added medium model
1756         * doc/sdccman.lyx: documented medium model
1757         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1758         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1759         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1760         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1761           (allocParms): set SCLS and OCLS to pdata for medium model
1762         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1763           for pdata,
1764           (powof2): return <0 if not power of 2
1765         * src/avr/gen.c (genBitWise): use updated powof2
1766         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1767           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1768           (shiftLLeftOrResult): use B if necessary
1769         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1770         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1771         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1772         * support/regression/Makefile.in: added test-mcs51-medium
1773         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1774
1775 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1776
1777         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1778         specifier unsigned
1779         * device/lib/time.c (mktime): fixed bug 1334315
1780
1781 2005-10-28 Raphael Neider <rneider AT web.de>
1782
1783         * device/include/pic/p16f_common.inc: added common declarations
1784         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1785
1786 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1787
1788         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1789           (aopPutUsesAcc): added to predict accumulator use,
1790           (assignResultValue): save acc if necessary,
1791           (genMinusDec): store result if indirectly addressed,
1792           (genDivOneByte):  save acc if necessary,
1793           (movLeft2Result): bugfix if left already in acc,
1794           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1795             attention to accumulator use (esp. pdata),
1796           (genReceive): receive pdata correctly
1797         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1798         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1799
1800 2005-10-27 Raphael Neider <rneider AT web.de>
1801
1802         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1803
1804 2005-10-27 Raphael Neider <rneider AT web.de>
1805
1806         * .version: changed version to 2.5.4
1807         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1808         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1809           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1810             arithmetics support routines
1811         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1812         * device/lib/Makefile.in: also create installdir for pic
1813
1814         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1815           pic14 port as well
1816         * src/pic/device.c (dump_sfr): rewritten to delegate register
1817           placement to the linker (use `extern sym' rather than sym EQU addr),
1818           (validAddress): fixed to check last specified address
1819         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1820           (popGetLit): truncate literal value to 8 bit,
1821           (popGet): moved assert to more appropriate place
1822           (popGetExternal): create pCode operand from and mark the according
1823             symbol as being `extern'
1824           (popGetAddr): added sanity check on immediate's offset, provide
1825             GPOINTER tag on demand
1826           (aopPut): fixed for immediates,
1827           (mov2w_op): move operand's address or contents to WREG (depending on
1828             operand type), safer variant of mov2w,
1829           (movwf,call_libraryfunc): NEW, handy abbreviations,
1830           (get_argument_pcop,get_return_val_pcop,pass_argument,
1831           get_returnvalue): interface for accessing function parameters and
1832             return values,
1833           (assignResultValuei,genRet): use new parameter/return value interface
1834           (pic14_getDataSize): back to old version handling generic pointers,
1835           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
1836             provided implementation and/or fixed old one,
1837           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
1838             calls, removed legacy 8051 reference code
1839           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
1840           (loadSignToC): NEW, move the operands sign bit to CARRY,
1841           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
1842             genRightShiftSigned, accepts negative shift counts,
1843           (setup_fsr): load FSR and adjust IRP (indirect memory access),
1844           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
1845             generic pointers, __data pointers and __code pointers,
1846           (genUnpackBits,genPackBits): rewritten to work with generic pointers
1847             and signed bitfields, limit bitfields to 8 bit,
1848           (genDataPointerGet): fixed number of bytes read,
1849           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
1850           (genPointerGet,genPointerSet): fixed handling of __code pointers,
1851             pointers to constant data are no longer assumed to point to __code
1852             space, removed invalid pointer types,
1853           (bitpatternFromVal): retrieve the PICs representation of an integer
1854             or float literal,
1855           (genDataPointerSet): fixed assigning to po_immediate operands,
1856           (genGenPointerSet): implemented as library call,
1857           (genIfx): fixed incorrect condition,
1858           (genAddrOf): limit generic pointers' addresses to 2 bytes,
1859             provide GPOINTER tag according to destination's storage class,
1860           (genCast): added code to handle casting to generic pointers, added
1861             sign-/zero extension of the result
1862           (aop_isLitLike,op_isLitLike): fixed handling of immediates
1863         * src/pic/gen.h: added macros to access IRP bit in STATUS register
1864         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
1865           extend the result
1866         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
1867           address/register resides in the shared banks
1868           (emitSymbolToFile): improved to handle global and `pinned' symbols,
1869             put all variables into separate sections (have the linker arrange
1870             them)
1871           (picglue): put init code and interrupt handlers in separate sections
1872         * src/pic/main.c: added port specific options table, modified to PORT
1873           structure to make GPOINTERs 3 byte, added pic14_options
1874           (_pic14_do_link): private linking routine (update paths to libraries,
1875             add libsdcc.lib by default)
1876         * src/pic/main.h: declare pic14_options
1877         * src/pic/pcode.c: fixed instructions i/o relations,
1878           (RegCond): reverted to correct version,
1879           (newpCodeOpLit): truncate literals to 8 bit,
1880           (genericPrint): added debug output,
1881           (getRegFromInstruction): fixed for various operand types, simplified
1882           (BuildFlow): fixed broken handling of isntructions with labels
1883           (LinkFlow): start at last instruction in flow (skip trailing comments),
1884             pass the flow on to the next instruction after CALL
1885           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
1886           (insertPCodeInstruction): fixed inserting after a skip instruction,
1887           (DoBankSelect): fixed for labeled instructions
1888           (OptimizepBlock): honor --nopeep switch
1889           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
1890         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
1891         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
1892           (pCodeOptime2pCodes): allow disabling this optimization via
1893             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
1894             but is still buggy), started implementation of a dataflow based
1895             pCode optimization (CSE + dead code elimination)
1896           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
1897         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
1898           names are independant of the stack location and therefore portable across
1899           devices
1900
1901 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1902
1903         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
1904           (selectSpil): fixed bug 1337835 by not spilling bit variables
1905         * support/regression/tests/bug1337835.c: added test for this bug
1906         * src/mcs51/peeph.def: restart after rule 3.c,
1907           addded rules 263.x to optimize loading constants
1908
1909 2005-10-26 Raphael Neider <rneider AT web.de>
1910
1911         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
1912         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
1913           (genAssign): emit warning when casting literals to generic pointer
1914             type, also applies when taking the address of a fixed variable,
1915           (genCast): improved casting to generic pointers
1916         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
1917           extern variables, added verbose error message
1918         * device/include/pic16/{string.h,errno.h}: added #pragma library c
1919
1920 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
1921
1922         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
1923         carry must be complemented too
1924         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
1925         could be emitted by genMinus
1926         * src/SDCCval.c (constVal): fixed bug 1305065
1927
1928 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
1929
1930         * src/SDCCast.c (addCast): added promotion for bit variables
1931         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
1932         promotion casts + optimisation
1933         (optimizeGetWord): fix warning 'i' might be used uninitialized
1934         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
1935         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
1936
1937 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
1938
1939         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
1940         all chars are promoted to int; promotion should be handled in SDCCast.c
1941
1942 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1943
1944         * device/lib/_strcmp.c: Fixed bug 1326457
1945
1946 2005-10-11 Raphael Neider <rneider AT web.de>
1947
1948         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
1949         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
1950
1951 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
1952
1953         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
1954         * support/regression/tests/sfr16.c: added test for the sfr32 bug
1955
1956 2005-10-04 Raphael Neider <rneider AT web.de>
1957
1958         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
1959           device/lib/pic16/pics.all: added pic18f1320
1960         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
1961
1962 2005-09-30 Raphael Neider <rneider AT web.de>
1963
1964         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
1965         * src/pic16/devices.inc: NEW, provides device descriptions
1966         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
1967
1968 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
1969
1970         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
1971           GETHBIT
1972
1973 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
1974
1975         * doc/sdccman.lyx: updated Highest Order Bit documentation,
1976           documented Any Order Bit, Higher Order Byte and Higher Order Word
1977         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
1978         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
1979           (optimizeGetAbit): new, to get any bit, not only the high bit,
1980           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
1981           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
1982           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
1983           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
1984             RIGHT_OP: also try GETBYTE, GETWORD optimization,
1985             GETABIT, GETBYTE, GETWORD: decorate them,
1986           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
1987           (ast_print): added GETABIT, GETBYTE, GETWORD
1988         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
1989         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
1990           (geniCodeBinary): new generic binary icode,
1991           (ast2iCode): added GETABIT, GETBYTE, GETWORD
1992         * src/port.h: updated comment for PORT.hasExtBitOp
1993         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
1994           (genGetByte): new, to get a single byte,
1995           (genGetWord): new, to get a word from a long,
1996           (gen51Code): added GETABIT, GETBYTE, GETWORD
1997         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
1998
1999 2005-09-23 Raphael Neider <rneider AT web.de>
2000
2001         * configure.in, configure: have device/lib/pic configured
2002         * device/lib/Makefile.in: added model-pic14
2003         * device/lib/clean.mk: added pic/ to clean rule
2004         * device/lib/pic: added rudimentary pic14 library providing support
2005           functions for multiplication/division/generic pointer access
2006         * src/SDCCopt.c (convilong): mark support functions as extern
2007           for pic14 port as well
2008         * src/pic/gen.c (genMult): added assertions,
2009           (genpic14Code): emit warning on unhandled iCodes
2010         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
2011         * src/pic/pcode.c (pCodeOpCopy),
2012         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
2013           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
2014           SFR_REGISTER}), made safe for future extensions
2015         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
2016           instructions even if preceeded by SKIP instructions (also remove
2017           them); removed unused code
2018         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
2019           prevents leaving parts of the structure uninitialized after copying
2020
2021 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
2022
2023         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
2024           ago by me
2025         * support/regression/tests/addsub.c: added test for the bug
2026
2027 2005-09-21 Raphael Neider <rneider AT web.de>
2028
2029         * device/include/pic16/pic18f1220.h,
2030           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
2031         * device/lib/pic16/Makefile.rules: added missing opening paren
2032         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
2033           are provided in genutils.c,
2034           (genUminusFloat,genUminus,genCmpEq): added asserts on different
2035           operand/result sizes,
2036           (genCmp): assert on NULL pointers first, then check deref'ed values
2037         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
2038           result size
2039
2040 2005-09-18 Raphael Neider <rneider AT web.de>
2041
2042         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
2043           as these are now unused,
2044           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
2045         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
2046           local, avoids uninitialized pointer dereference on r->name
2047         * src/pic16/ralloc.c (newReg): fixed indentation
2048
2049 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
2050
2051         * src/SDCCval.c (constVal): fixed bug 730366
2052         * support/Util/SDCCerr.c,
2053         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
2054
2055 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
2056
2057         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
2058
2059 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
2060
2061         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
2062
2063 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
2064
2065         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
2066           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2067         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
2068           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2069         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
2070         * packihx/packihx.c (hexDigit): made c unsigned char
2071         * as/mcs51/lklibr.c (fndsym),
2072         * link/z80/lkgb.c (gb),
2073         * link/z80/lklibr.c (fndsym),
2074         * link/z80/lkrloc.c (relr),
2075         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
2076         * src/SDCC.lex (checkCurrFile, process_pragma),
2077         * src/SDCCglue.c (spacesToUnderscores),
2078         * src/SDCCmain.c (setParseWithComma, processFile),
2079         * src/asm.c (tvsprintf, printCLine),
2080         * src/avr/gen.c (emitcode, aopPut),
2081         * src/ds390/gen.c (emitcode),
2082         * src/hc08/gen.c (emitcode, emitinline),
2083         * src/mcs51/gen.c (emitcode, genInline),
2084         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2085           tokenizeLineNode),
2086         * src/pic/ralloc.c (debugLog),
2087         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2088           tokenizeLineNode),
2089         * src/pic16/ralloc.c (debugLog),
2090         * src/z80/main.c (_process_pragma):
2091            made all ctype.h function calls safe
2092         * src/SDCCopt.c: include math.h for fabs
2093         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
2094           and used them throughout the code to make ctype.h function calls safe
2095         * src/ds390/main.c (asmLineNodeFromLineNode),
2096         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
2097         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
2098            unsigned char*
2099         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
2100           (newpCodeAsmDir): made ctype.h function calls safe
2101         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
2102           pic16_emitcode):  made lbp unsigned char*
2103         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
2104           (pic16_newpCodeAsmDir): made ctype.h function calls safe
2105         * src/xa51/gen.c (emitcode),
2106         * src/z80/gen.c (_emit2): made lbp unsigned char*
2107         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
2108            char*
2109
2110 2005-09-05 Raphael Neider <rneider AT web.de>
2111
2112         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
2113           access bank splitpoint
2114
2115 2005-09-05 Raphael Neider <rneider AT web.de>
2116
2117         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
2118
2119 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
2120
2121         * .version: changed to version 2.5.3
2122         * doc/sdccman.lyx: changed version to 2.5.3,
2123           documented --codeseg and --constseg and pragma codeseg and constseg,
2124           documented bit parameters (reentrant) and bit returning
2125         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
2126            currFunc->recvSize, but is this ok for all ports?
2127           (ast2iCode): result of ~ on unsigned char must be cast to int for
2128            bool to work
2129         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
2130           function pointers in bit space
2131         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
2132           (processFuncArgs): call port.reg_parm() with reentrancy info
2133         * src/port.h,
2134         * src/avr/main.c,
2135         * src/ds390/main.c,
2136         * src/hc08/main.c,
2137         * src/pic/main.c,
2138         * src/pic16/main.c,
2139         * src/xa51/main.c,
2140         * src/z80/main.c: port.reg_parm prototype extended with
2141           "bool reentrant" parameter
2142         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
2143           options.stackAuto for allocating bit register parameters
2144         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
2145           (genSend): set BitBankUsed if it is,
2146           (selectRegBank): factored out of genCall for use in genPcall,
2147           (genCall): removed redundant dtype assignmen, use selectRegBank,
2148           (genPcall): handle returning in Carry properly, save in F0 if needed,
2149           (genReceive): handle bit register parameters
2150         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
2151           (mcs51_assignRegisters): enable bit registers for all reentrant
2152            functions and don't set BitBankUsed unconditionally
2153         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
2154         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
2155         * support/regression/tests/funptrs.c: added tests for BOOL and for return
2156
2157 2005-08-27 Borut Razem <borut.razem AT siol.net>
2158
2159         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
2160         ppc-osx (Darwin) does not support -u option. It seems that it is
2161         supported only on Linux - GNU cp
2162
2163 2005-08-25 Borut Razem <borut.razem AT siol.net>
2164
2165         * sim/ucsim/gui.src/serio.src/Makefile.in,
2166           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
2167           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2168           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
2169           install and strip, since the strip at /usr/ccs/bin should be used
2170           on solaris
2171
2172 2005-08-24 Borut Razem <borut.razem AT siol.net>
2173
2174         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
2175
2176 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
2177
2178         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
2179         ffffffffu
2180
2181 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
2182
2183         * as/mcs51/aslink.h: completed lkrloc.c prototypes
2184         * as/mcs51/lkmain.c (link_main): fixed warning
2185         * device/include/stdbool.h: ds390 has no advanced bit support yet
2186         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
2187         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
2188         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
2189           and updated their macros
2190         * src/SDCCval.c (constVal): updated comment for renamed b_long
2191
2192 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
2193
2194         * as/mcs51/asdata.c: changed ctype['['] to BINOP
2195         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
2196           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
2197           (oprio): set priority for '['
2198         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
2199            and adb_24_bit
2200         * as/mcs51/asm.h: added defines R_BIT and S_BIT
2201         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
2202         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
2203         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
2204           added overlayable BIT_BANK area
2205         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
2206           (summary2): explain 'T' in legenda
2207         * as/mcs51/lkrloc.c: replaced old K&R style,
2208           (relr): added R_BIT processing,
2209           (errmsg): added "Bit-addressable relocation error",
2210           (adb_bit): added for converting from byte- to bit-addressable space,
2211           (adb_24_bit): added for converting from byte- to bit-addressable space
2212         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
2213            used in reentrant functions now even as return value
2214         * device/lib/_gptrput.c (_gptrput): removed obsolete code
2215         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
2216           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
2217         * src/SDCCglobl.h: added indicator BitBankUsed
2218         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
2219            the bit registers b0-b7
2220         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
2221           (geniCodeCast): fixed bug 1263853,
2222           (geniCodeLogicAndOr): put result in bool or char,
2223           (geniCodeReceive): added parameter func for accessing the return type,
2224           (geniCodeFunctionBody): pass func to geniCodeReceive
2225         * src/SDCCmain.c: added indicator BitBankUsed
2226         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
2227         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
2228           (checkSClass): don't put automatic bool/bit on stack,
2229           (checkFunction): removed check on function cannot return bit
2230         * src/SDCCsymt.h: added newBoolLink prototype
2231         * src/mcs51/gen.c (rb1regs): added bit registers,
2232           (movc): created for assigning to carry,
2233           (pushReg, popReg): created for pushing registers,
2234           (sameRegs): check both AOP_REG and AOP_CRY types,
2235           (aopOp): handle bit registers,
2236           (aopPut): optimization no self-assign,
2237           (saveRegisters): push reg->base (bits) only once for bit registers,
2238            and use pushReg,
2239           (unsaveRegisters): pop reg->base only once and use popReg,
2240           (assignResultValue): added parameter func and return in carry for bits,
2241           (genIpush): optimization no reload in A if not changed,
2242           (genSend): bit parameters in reentrant functions are passed in bit
2243            registers by first assigning to bits in B, then save registers and
2244            copy B to bits,
2245           (genCall): handle returning in Carry properly, save it in F0 if needed,
2246           (genPcall): updated assignResultValue call, this is not safe yet for bit
2247            returning function !!!
2248           (genFunction): don't generate equ's for bit registers and use pushReg,
2249           (genEndFunction): take care of bit returning functions and use popReg,
2250           (genRet): return bit in Carry,
2251           (genIfx): optimize bit registers and other directly addressable bits,
2252           (genReceive): updated assignResultValue call
2253         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
2254           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
2255            registers when using stack-auto
2256         * src/mcs51/ralloc.c (_G): added allBitregs,
2257           (regs8051): added the bit registers,
2258           (createStackSpil): use macro IS_BIT,
2259           (getRegBit): added to allocate a bit register, else spill,
2260           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
2261           (updateRegUsage): factored out to ease stepping while debugging,
2262           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
2263            also allocate bit registers,
2264           (fillGaps): handle bit registers,
2265           (findAllBitregs): added to create bit vector with all bit registers,
2266           (mcs51_allBitregs): returns this bit vector,
2267           (mcs51_assignRegisters): when using stack-auto use bit registers for
2268            passing parameters and creating local variables
2269         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
2270
2271 2005-08-22 Borut Razem <borut.razem AT siol.net>
2272
2273         * device/lib/Makefile.in: replaced find option -or with -o
2274           to make it run on solaris
2275
2276 2005-08-22 Raphael Neider <rneider AT web.de>
2277
2278         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
2279           fixes #1265442 (crash on Solaris)
2280
2281 2005-08-20 Borut Razem <borut.razem AT siol.net>
2282
2283         * configure, configure.in: added tests for libsocket and libnsl libraries,
2284           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
2285           from support/regression/Makefile.in
2286         * support/regression/Makefile.in: added
2287         * device/lib/pic16/Makefile.common.in: force make to use bash shell
2288         * sim/ucsim/libtool: regenerated on sparc-solaris
2289         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2290           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
2291           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
2292           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
2293           sparc-solaris, which doesn't use GNU ld linker
2294         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
2295         * as/Makefile: find on sparc-solaris does not support -maxdepth option
2296
2297 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2298
2299         * src/mcs51/peeph.def: updated comments
2300
2301 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2302
2303         * device/lib/_gptrget.c,
2304         * device/lib/_gptrput.c: slightly shorter
2305         * doc/sdccman.lyx: incremented version
2306         * src/mcs51/peeph.def: moved peephole comments to the line of first
2307           change to better keep line correlation, reanimated 186.e
2308         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2309
2310 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2311
2312         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2313           David Saxton with quotes around file name.
2314
2315 2005-08-15 Borut Razem <borut.razem AT siol.net>
2316
2317         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2318           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2319           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2320           make tests run on x86_64 platform
2321
2322 2005-08-13 Raphael Neider <rneider AT web.de>
2323
2324         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2325           as it might be executed DURING a build (parallel make is wonderful)
2326
2327 2005-08-13 Raphael Neider <rneider AT web.de>
2328
2329         * device/lib/Makefile.in (port-specific-objects-pic16):
2330           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2331         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2332           dependency
2333         * device/lib/pic16/Makefile.rules: build subdirs before creating
2334           the library, removed builddir rule, create $(builddir) early in
2335           recurse rule, use empty recurse rule for leaf directories
2336         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2337           mkdir errors (race condition), removed duplicate suffix "hex"
2338           from clean rules
2339         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2340         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2341           prevents mkdir -p from aborting on Alpha
2342
2343 2005-08-12 Raphael Neider <rneider AT web.de>
2344
2345         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2346           db-statements in order to allow for arrays of pointers in code
2347           sections to be placed without interspersed 0-padding, fixes
2348           bug #1256215
2349         * (emitStatistics): fixed division by zero for pic18f1220
2350         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2351           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2352         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2353         * (pic16_pCodeConstString): keep track of already emitted string
2354           literals to prevent "duplicate definitions of symbol _str_NR"
2355         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2356           debug message
2357         * device/lib/Makefile.in: ignore failing PIC16 library builds
2358         * device/lib/pic16/Makefile: do not build if gputils are missing
2359         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2360
2361 2005-08-10 Raphael Neider <rneider AT web.de>
2362
2363         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2364           my last commit)
2365
2366 2005-08-10 Raphael Neider <rneider AT web.de>
2367
2368         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2369           Rokas' patch to add the new fixed point type "__fixed16x16"
2370         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2371           functions for __fixed16x16 arithmetics
2372         * device/lib/pic16: reimplemented the build system to support
2373           a separate build directory, better handling of libio (create
2374           the library in a separate subdir for each architecture) and
2375           easier configuration (centralized in Makefile.common)
2376
2377 2005-08-07 Raphael Neider <rneider AT web.de>
2378
2379         * src/pic16/gen.c (genrshTwo): fixed sign extension
2380         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2381         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2382           added T0CONbits
2383         * device/include/pic16/pic18f4220.h: NEW, header for
2384           pic18f4220 and pic18f4320
2385         * device/include/pic16/pic18fregs.h: added new devices,
2386           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2387         * device/include/pic16/signal.h: resolved name clashes
2388           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2389           to also allow testing for interrupt enable bits, added
2390           comments on how to use the macros
2391         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2392         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2393           register definitions for the devices
2394         * device/lib/pic16/pics.all: added new devices
2395         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2396           allocated memory
2397         * device/lib/pic16/libc/stdlib/memfree: do not count
2398           the block header as free memory
2399         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2400           simplified and added missing end-of-blocklist-marker
2401           (reported by Peter Onion, fixes #1252814)
2402         * (_mergeHeapBlock): fixed loop condition
2403         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2404           len==0, restructured code
2405         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2406           up a bit, reduced bitfield accesses, prevent endless loops
2407           in case of heap corruption
2408         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2409           "unreferenced arguments/must return a value" warnings
2410         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2411           replaced BAUDREG with SPBRG
2412         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2413           device/lib/pic16/debug/gstack/gstack.c: replaced
2414           _naked, _asm, _endasm with __naked, __asm, __endasm
2415
2416 2005-08-05 Raphael Neider <rneider AT web.de>
2417
2418         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2419           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2420
2421 2005-08-05 Borut Razem <borut.razem AT siol.net>
2422
2423         * device/lib/Makefile.in: added missing ';'
2424         * configure: removed ^M characters
2425
2426 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2427
2428         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2429           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2430           License
2431
2432 2005-08-04 Borut Razem <borut.razem AT siol.net>
2433
2434         * configure.in: pic16 libraries build 2nd try - enable running
2435           configure in device/lib/pic16
2436         * configure: regenerated from configure.in
2437         * device/lib/Makefile.in: create $(PORT)/bin directory
2438
2439 2005-08-03 Raphael Neider <rneider AT web.de>
2440
2441         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2442           to get/set values via pointers
2443         * (genUnpackBits,genPackBits): changed detection of
2444           ptr->bitfield vs. sym.bitfield, fixed access via generic
2445           pointers, removed dead (wrong) code for multibyte bitfields
2446         * (genNearPointerGet, genGenPointerGet): removed useless code,
2447           fixed bitfield detection, fixes #1250594
2448         * (genNearPointerSet): removed useless code
2449         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2450           and introduced macro pic16_emitpcode that conditionally emits
2451           the origin of the following pCode (useful for debugging SDCC)
2452         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2453         * (createDefmap): fixed handling of LFSR for --optimize-df
2454
2455 2005-08-02 Borut Razem <borut.razem AT siol.net>
2456
2457         * device/lib/Makefile.in: pic16 libraries build enabled since
2458           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2459
2460 2005-08-02 Raphael Neider <rneider AT web.de>
2461
2462         * src/pic16/gen.c (genPackBits): removed deprecated warning
2463         * (genGenPointerSet): fixed bitfield detection
2464
2465 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2466
2467         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2468
2469 2005-07-31 Raphael Neider <rneider AT web.de>
2470
2471         * device/lib/pic16/libdev/pic18f458.c,
2472           device/include/pic16/pic18f458.h: added missing T0CONbits
2473
2474 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2475
2476         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2477
2478 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2479
2480         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2481
2482 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2483
2484         * device/include/mcs51/at89c51ed2.h: added.
2485
2486 2005-07-23 Raphael Neider <rneider AT web.de>
2487
2488         * src/pic/gen.h: added emitpcode macro for debugging
2489         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2490           and replace by macro adding debug information on demand
2491         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2492         * (gencjne): tried to fix; replaced with correct (slower) code
2493         * (gen{Unp,P}ackBits): fixed single bit access
2494         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2495         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2496           previous instruction
2497         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2498           register has to be handled with care (forbidding movement
2499           of assignments/uses, removing assignments completely, ...)
2500         * (pCodeOptime2pCodes): make use of regIsSpecial
2501         * added lots of debugging output (commented out)
2502         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2503           from being reused as result UNLESS it is known to work
2504
2505 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2506
2507         * support/Util/dbuf.h: include <stddef.h> for size_t
2508         * .version: changed to version 2.5.2
2509
2510 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2511
2512         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2513
2514 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2515
2516         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2517           (genModOneByte): removed needless psha/pula
2518
2519 2005-07-22 Raphael Neider <rneider AT web.de>
2520
2521         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2522           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2523         * src/pic/gen.c (resolveIfx): do not "invent" labels
2524         * (genSkipc): changed to positive logic
2525         * (genSkipCond): removed as no longer needed
2526         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2527           backport from PIC16
2528         * (genLeftShift): check operands are in different registers
2529         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2530           INCF does not update CARRY...
2531         * src/pic/main.c: fixed _linkCmd
2532         * src/pic/pcode.c (unlinkpCode): added inactive code
2533         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2534           alive (do not assign result and operand overlapping registers)
2535
2536 2005-07-22 Raphael Neider <rneider AT web.de>
2537
2538         * src/pic/device.c (dump_sfr): replaced register declaration with
2539           call to emitSymbolToFile() to avoid duplicate symbols
2540         * (assignRelocatableRegisters): do not declare external symbols
2541         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2542           right (take size of type, not etype)
2543         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2544         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2545         * (packRegsForAccUse): disabled assignment of WREG as
2546           the result reg to prevent occurence of just fixed #1235003,
2547           fixes #1242954
2548         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2549           symbols (avoids duplicate symbols in .asm file)
2550         * (pic14emitRegularMap): use emitSymbolToFile()
2551         * src/pic/gen.c (aopOp): fixed spillLocation handling
2552         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2553         * (genDataPointerSet): removed unneccessary variables/output
2554
2555 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2556
2557         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2558         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2559
2560 2005-07-21 Raphael Neider <rneider AT web.de>
2561
2562         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2563           architecture cannot handle them efficiently, fixes bug #1235003
2564         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2565           check for empty sets before using them (fixes bug #1232190)
2566
2567 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2568
2569         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2570           (lnksect2): generate warnings for memory overlap
2571         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2572           constseg to set the name of these segments so you can instruct the linker
2573           to place them in banks
2574         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2575         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2576           added code_seg and const_seg to options
2577         * src/SDCCglue.c (emitMaps): use options.const_seg,
2578           (createInterruptVect): put interrupt vectors in segment HOME,
2579           (glue): put HOME before static segment and put the main glue in HOME,
2580           (glue): use options.code_seg
2581         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2582         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2583           these segments so you can instruct the linker to place them in banks
2584           (linkEdit): use code_loc for HOME segment which should be the first
2585           segment in code memory now
2586         * src/SDCCmem.c: fixed more stuff like bug 1238386
2587         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2588           (changePointer): don't change function pointers to code pointers for
2589           banked functions,
2590           (compareType): added exceptional check for banked function pointers
2591         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2592         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2593           after static in code memory
2594         * src/mcs51/gen.c: added aopLiteralLong prototype,
2595           (aopForSym): use getSize for functions,
2596           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2597           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2598           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2599           the segment,
2600           (genPcall): use call for literal function pointers and generate banked
2601           calls over the one trampoline so there's only one place for the user to
2602           modify according to his/hers hardware,
2603           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2604           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2605         * src/mcs51/main.c: added keyword banked,
2606           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2607         * support/Util/SDCCerr.c,
2608         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2609           needed for passing the bank and address to the trampoline
2610         * device/lib/mcs51/crtbank.asm: added for bankswitching
2611         * device/lib/mcs51/Makefile: added crtbank
2612
2613 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2614
2615         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2616           for fields at offset 0 of a struct or union as reported
2617           on 2005-07-07 in the developer mailing list.
2618
2619 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2620
2621         * src/SDCCmem.c: fixed bug 1238386
2622
2623 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2624
2625         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2626           (patch #1144962), added peephole 300, enabled 259.x
2627         * doc/sdccman.lyx: removed screenshot and provided link instead
2628
2629 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2630
2631         * doc/sdccman.lyx: added section about debugging with ddd
2632         * doc/figures/ddd_example.eps: screenshot of debugging session
2633
2634 2005-07-04 Raphael Neider <rneider AT web.de>
2635
2636         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2637           like CODE pointers, fixes #1115683
2638         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2639           call, fixes bugs #1232211, #1228110,
2640           fixed wrong casts to pCodeFlow from pCodeInstructions
2641
2642 2005-07-04 Raphael Neider <rneider AT web.de>
2643
2644         * src/pic/gen.c (popGet): changed assert to allow for
2645           bit operands
2646         * (popGetAddr): changed signature to provide
2647           an additional index, patched all call sites
2648         * (genCmpEq): handle literal-like operands correctly
2649         * (genAddrOf): added sanity checks on __code/__data pointers
2650         * (genAssign): added handling of symbols from __code section
2651         * (gencjne): do not generate code for comparisons whose result
2652           is neither stored nor used, fixes bug #1171114
2653         * (AccLsh, AccRsh): operate on operand instead of WREG
2654         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2655           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2656           by known count
2657         * rewrote complete shift-by-literal logic, commented unused
2658           functions out
2659         * (genConstPointerGet): get multiple bytes (if result size > 1),
2660           fixed handling of non-immediate addresses
2661         * (genPointerGet): handle CODE pointers like CONST pointers
2662         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2663         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2664           operand is to be treated as a literal or not
2665         * (mov2w,genPcall,genCmpEq),
2666           src/pic/genarith.c: use aop_isLitLike() to decide between
2667           literal/register contents
2668         * (addSign): added missing offset
2669         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2670           only emit comment in debug-mode,
2671           use {aop,op}_isLitLike throughout the file
2672         * src/pic/glue.c: fix initializers for pointers (work in progress)
2673         * src/pic/pcode.c (get_op): honor index on _const symbols
2674         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2675         * (dumppBlock): added pCode size estimation
2676         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2677           check for IS_SYMOP before OP_SYMBOL'ing
2678         * fixed indentation, compacted switch-statements
2679         * (allocReg): find free register and allocate it instead of
2680           allocating new registers all the time
2681         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2682           registers as its operands (necessary only for multibyte GETs)
2683
2684 2005-07-01 Raphael Neider <rneider AT web.de>
2685
2686         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2687           debugging .asm-output macros FENTRY + FEXIT
2688         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2689           way... I wonder...
2690         * (emitpComment): NEW, printf to pCode
2691         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2692           offset handling
2693         * (popGetAddr): NEW, variant of popGet to access an immediates
2694           high(er) bytes instead of the n'th byte of memory they reference,
2695           replaced popGet with popGetAddr where neccessary
2696         * (genDataPointerGet): reactivated and fixed implementation
2697         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2698           accesses
2699         * (genDataPointerSet): fixed multibyte assignments
2700         * (genpic14Code): fixed --i-code-in-asm handling
2701         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2702         * (genPlus): fixed index-out-of-bounds error
2703         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2704         * src/pic/ralloc.c: added debugging output macro FENTRY2
2705         * (spillThis): fixed indentation, enbraced for-body for clarity
2706         * (rematStr): commented out as now unused
2707         * (regTypeNum): commented out special spill case (overwrites
2708           arbitrary values)
2709         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2710
2711 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2712
2713         * doc/sdccman.lyx: documented sfr16/sfr32,
2714           added example for using storage class with function pointers
2715         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2716
2717 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2718
2719         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2720         * device/lib/_itoa.c,
2721         * device/lib/_ltoa.c: optimized codesize
2722         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2723           but don't know how to suppress the double warning.
2724         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2725         * support/Util/SDCCerr.c,
2726         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2727
2728 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2729
2730         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2731           fixed old K&R prototypes
2732         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2733         * device/lib/_gptrget.c,
2734         * device/lib/_gptrgetc.c,
2735         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2736           also new versions for small generic pointers and banked generic pointers
2737         * src/port.h: added const_name
2738         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2739         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2740         * src/SDCCcse.c (findPrevIc): check all associative operators
2741         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2742         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2743         * src/SDCCmem.c: updated comments,
2744           set far-space to 0 for pdata, results in optimized code
2745         * src/SDCCmem.h: added macro CONST_NAME
2746         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2747           moving the info into the highest bits, see also gptrget/gptrput
2748         * src/src.dsp: added sdcc.ico to project files
2749         * src/avr/gen.c (genCast): fixed bug 0x%d
2750         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2751         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2752           relation between ptr_type and DCL_TYPE,
2753           (genCast): fixed bug 0x%d
2754         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2755           (CODE)" for const_name
2756         * src/hc08/gen.c (genCast): fixed bug 0x%d
2757         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2758           (hc08_port): added "CONST (CODE)" for const_name
2759         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2760           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2761           between ptr_type and DCL_TYPE,
2762           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2763           operand* and took AOP() inside function so sfr-ness can be checked,
2764           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2765           new prototype,
2766           (genFunction, genEndFunction): optimized stack setup,
2767           (genMinus): optimized for literals with ending zeroes (in bytes),
2768           (genCast): fixed bug 0x%d
2769         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2770           (mcs51_port): added "CONST (CODE)" for const_name
2771         * src/mcs51/peeph.def: made rule 226 more generic
2772         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2773         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2774         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2775         * src/z80/main.c (z80_port): added NULL for const_name,
2776           (gbz80_port): added NULL for const_name
2777         * support/regression/tests/bug663539.c,
2778         * support/regression/tests/sfr16.c: new tests
2779
2780 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2781
2782         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2783
2784 2005-06-24 Raphael Neider <rneider AT web.de>
2785
2786         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2787           corrected typos...
2788         * device/include/pic16/signal.h: added USBIF
2789           and SIG_USB
2790
2791 2005-06-24 Raphael Neider <rneider AT web.de>
2792
2793         * device/lib/pic16/libdev/pic18f2455.c,
2794           device/include/pic16/pic18f2455.h: NEW
2795         * device/include/pic16/pic18fregs.h,
2796           device/lib/pic16/pics.all,
2797           src/pic16/device.c: added 18f2455
2798         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2799           device/include/pic16/{pic18f[68][567].h,usart.h}:
2800           replaced MULTIPLE_USARTS define with more relaible
2801           compatibility sfrs (for USART access)
2802
2803 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2804
2805         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2806           and the output asm file line is printed on two lines.
2807
2808 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2809
2810         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2811           BGT, BLE, BHI, and BLS instructions
2812         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2813           genCmpEq): removed
2814         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2815           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2816           fixes bug #1216342
2817         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2818
2819 2005-06-15 Raphael Neider <rneider AT web.de>
2820
2821         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2822         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2823         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2824           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2825           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2826
2827 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2828
2829         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2830           Marcel Telka in bug #1215704
2831
2832 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
2833
2834         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
2835           located in shared memory bank.
2836
2837 2005-05-31 Raphael Neider <rneider AT web.de>
2838
2839         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
2840           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
2841           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
2842
2843 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
2844
2845         * device/lib/_strncpy.c: fixed the fix
2846
2847 2005-05-26 Raphael Neider <rneider AT web.de>
2848
2849         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
2850           initializers with \0, bug #1208187
2851         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
2852           intializers with \0, bug #1208187
2853
2854 2005-05-26 Raphael Neider <rneider AT web.de>
2855
2856         * src/pic16/glue.c (pic16_printIvalChar): fixed string
2857           initializers with \0, bug #1208187
2858         * src/pic16/main.c (_process_pragma): added sanity checks
2859           for stack position and size, emit warnings when appropriate
2860
2861 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
2862
2863         * device/lib/_strncpy.c: fixed not filling with \0
2864
2865 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2866
2867         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
2868           createFunction),
2869         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
2870           compound_statement),
2871         * src/SDCCsymt.h,
2872         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
2873
2874 2005-05-24 Raphael Neider <rneider AT web.de>
2875
2876         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
2877
2878 2005-05-24 Raphael Neider <rneider AT web.de>
2879
2880         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
2881           TRISE definitions, closes bug #1162453
2882
2883 2005-05-22 Raphael Neider <rneider AT web.de>
2884
2885         * src/pic16/main.c (_process_pragma): check for missing
2886           arguments to pragmas code and udata
2887         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
2888           consistency fixes to match other headers (thanks to Jim Paris)
2889         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
2890
2891 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
2892
2893         * src/SDCCicode.c (isOperandEqual): fixed missing ;
2894
2895 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
2896
2897         * support/regression/tests/bug1198642.c: new test
2898         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
2899         * src/SDCCcse.c (findPrevIc): added comment, please have a look
2900         * support/scripts/resource.h,
2901         * support/scripts/resource.rc,
2902         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
2903         * support/scripts/sdcc.ico: added 32x32 icon
2904
2905 2005-05-18 Raphael Neider <rneider AT web.de>
2906
2907         * device/lib/pic16/libdev/pic18f*.c,
2908         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
2909           keywords to "__sfr" and "__at (X)"
2910         * device/include/pic16/pic18fregs.h: added pic18f4520
2911         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
2912           #1203088 (MPLAB compatibility)
2913
2914 2005-05-17 Raphael Neider <rneider AT web.de>
2915
2916         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
2917         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
2918         * device/lib/pic16/pics.all: added new devices
2919         * src/pic16/device.c: added support for pic18f4520
2920
2921 2005-05-16 Raphael Neider <rneider AT web.de>
2922         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
2923         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
2924         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
2925           convenience function for bit access
2926
2927 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
2928
2929         * device/lib/printf_large.c: fixed bug 1193299
2930         * support/regression/tests/bug1057979.c: added test %3.3s
2931
2932 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2933
2934         * device/include/mcs51/8051.h,
2935         * device/include/mcs51/8052.h: made parseable with lint
2936         * device/include/mcs51/lint.h: added include file for (sp)lint
2937         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
2938         * doc/cdbfileformat.lyx,
2939         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
2940
2941 2005-05-14 Raphael Neider <rneider AT web.de>
2942
2943         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
2944         * device/lib/pic16/libc/stdlib/itoa.c (new)
2945         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
2946         * device/lib/pic16/libio/Makefile: exclude subdir according to
2947           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
2948         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
2949         * src/pic16/gen.c (genFunction): prevent annoying warning
2950         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
2951           nameclashes on BeOS
2952         * support/cpp2/cppmain.c (cpp_output_string): new
2953         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
2954           fixes bug 1116802
2955
2956 2005-05-13 Borut Razem <borut.razem AT siol.net>
2957
2958         * src/SDCCmain.c (linkEdit): fixed bug 1195202
2959
2960 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2961
2962         * .version: changed to version 2.5.1; back to bleeding edge development
2963
2964 2005-05-11 Borut Razem <borut.razem AT siol.net>
2965
2966         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
2967           generate PDF version 1.3 documents
2968
2969 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2970
2971         * .version: changed to version 2.5.0
2972
2973 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2974
2975         * doc/sdccman.lyx: updated weblinks, index and smaller updates
2976
2977 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2978
2979         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
2980         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
2981         well as many smaller updates.
2982         * .version: changed to version 2.5.0-pre1
2983
2984 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2985
2986         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
2987
2988 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
2989
2990         * support/regression/tests/bug1185672.c: added
2991         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
2992           bug 1185672
2993         * src/mcs51/gen.c (genCall): added comments, made it look safer
2994         * src/mcs51/gen.c (genEndFunction): simplified
2995
2996 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
2997
2998         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
2999
3000 2005-04-14 Borut Razem <borut.razem AT siol.net>
3001
3002         * fixed bug 1045046 - SIGSEGV with really simple code?:
3003           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
3004           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
3005
3006 2005-04-14 Borut Razem <borut.razem AT siol.net>
3007
3008         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
3009           src/pic16/device.h: temporarily disabled experimental #inline pragma
3010           for 2.5.0 release
3011
3012 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
3013
3014         * device/include/z80/stdio.h,
3015         * device/include/z80/string.h: removed these highly incomplete files so
3016           SDCC can use the default ones in device/include/
3017
3018 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3019
3020         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
3021         gcc warning.
3022         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
3023         fix sdcpp warnings.
3024
3025 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3026
3027         * device/include/malloc.h: removed redundant __reentrant prototypes
3028         * device/lib/_mullong.c: added working xstack variant in asm (C version
3029           doesn't pass regression tests)
3030         * device/lib/bpx.c: used __data and made bpx char for mcs51
3031         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
3032           (createFunction): fixed bug with xstackPtr
3033         * src/SDCCcse.c: corrected comments
3034         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
3035           (killDeadCode, eBBlockFromiCode): removed unused code
3036         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
3037           corrected comments
3038         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
3039           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
3040           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
3041           (genModOneByte): fixed warning in MSVC
3042         * src/mcs51/main.c (): added comments
3043         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
3044
3045 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3046
3047         * src/SDCCmain.c (linkEdit): oops, changed one line too many
3048
3049 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
3050
3051         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
3052
3053 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
3054
3055         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
3056         characters arrays of larger size than the declared one.
3057
3058 2005-04-10 Borut Razem <borut.razem AT siol.net>
3059
3060         * src/pic/gen.c (genInline),
3061           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
3062           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
3063           (findNextInstruction), (findPrevInstruction),
3064           (findInstructionUsingLabel),
3065           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
3066         * src/pic/pcode.c (findLabel): added missing '\n'
3067         * src/src.dsp: added SDCCdwarf2.c to the project
3068
3069 2005-04-09 Borut Razem <borut.razem AT siol.net>
3070
3071         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
3072
3073 2005-04-08 Raphael Neider <rneider AT web.de>
3074
3075         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
3076           into the chain after a given one) and mergeDefmapSymbols (combine
3077           defmap entries for each symbol per pcode)
3078         * (createDefmap): have defmap entries merged in the end
3079         * (defmapReplaceSymRef): split defmap entries covering two accesses to
3080           a symbol before replacing one access type's symbol, merge symbols in
3081           the end (replacement symbol might already have an entry)
3082         * (assignValnums): keep reference to written WREG intact
3083
3084 2005-04-08 Raphael Neider <rneider AT web.de>
3085
3086         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
3087           Alpha)
3088
3089 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
3090
3091         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
3092         bytes
3093
3094 2005-04-07 Raphael Neider <rneider AT web.de>
3095
3096         * device/include/pic16/usart.h: added compatibility defines for
3097           devices with more than one USART
3098         * device/include/pic16/pic18f[68][567]20.h: activated above defines
3099
3100 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3101
3102         * device/lib/Makefile.in: updated for port specific include
3103
3104 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3105
3106         * support/regression/ports/mcs51/spec.mk: added mcs51 include
3107
3108 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3109
3110         * device/include/8051.h,
3111         * device/include/8052.h,
3112         * device/include/at89S8252.h,
3113         * device/include/at89c55.h,
3114         * device/include/at89x051.h,
3115         * device/include/at89x51.h,
3116         * device/include/at89x52.h,
3117         * device/include/mcs51reg.h,
3118         * device/include/reg51.h,
3119         * device/include/reg764.h,
3120         * device/include/regc515c.h,
3121         * device/include/sab80515.h: (re)moved these 12 files
3122         * device/include/mcs51/8051.h,
3123         * device/include/mcs51/8052.h,
3124         * device/include/mcs51/at89S8252.h,
3125         * device/include/mcs51/at89c55.h,
3126         * device/include/mcs51/at89x051.h,
3127         * device/include/mcs51/at89x51.h,
3128         * device/include/mcs51/at89x52.h,
3129         * device/include/mcs51/mcs51reg.h,
3130         * device/include/mcs51/reg51.h,
3131         * device/include/mcs51/reg764.h,
3132         * device/include/mcs51/regc515c.h,
3133         * device/include/mcs51/sab80515.h: and added them here
3134
3135 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3136
3137         * device/include/stdarg.h: changed SDCC specific keywords to double
3138           underlined form.
3139         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
3140           mcs51 and ds390.
3141         * device/include/hc08/mc68hc908gp32.h,
3142         * device/include/hc08/mc68hc908jb8.h,
3143         * device/include/hc08/mc68hc908jkjl.h,
3144         * device/include/hc08/mc68hc908qy.h: fixed comments
3145         * device/include/mcs51/README: updated
3146         * device/include/mcs51/c8051f120.h: added PINRSF
3147         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
3148         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
3149           amidst code. Also inline is not supported.
3150
3151 2005-04-06 Raphael Neider <rneider AT web.de>
3152
3153         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
3154         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
3155           callers stack/frame pointers
3156
3157 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3158
3159         * device/include/pic16/usart.h: added, missing in previous commit,
3160         * device/include/pic16/adc.h: fixed typo,
3161         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
3162         commit,
3163         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
3164         <p18fxxx.inc>
3165         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
3166         uninitialized because a bug appears with gplink
3167         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
3168         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
3169         complains for unrecognised option
3170
3171 2005-04-05 Raphael Neider <rneider AT web.de>
3172
3173         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
3174           structs as well (using memcpy)
3175         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
3176           on ISRs (GOTO has no label)
3177         * src/pic16/device.h: added OF_OPTIMIZE_DF
3178         * src/pic16/main.c: added compiler switch --optimize-df to enable the
3179           new data flow analysis/optimization
3180         * src/pic16/pcode.c: added (prototypes for and implementation of)
3181           dataflow analysis functions, fixed pCodeInstructions' inCond and
3182           outCond values, made RCALL a branch instruction
3183         * (pic16_unlinkpCode): keep C line if possible
3184         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
3185           C line moved if possible
3186         * (pic16_getRegFrompCodeOp): NEW, improved version of...
3187         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
3188           to use new pic16_getRegFrompCodeOp (works for more SFRs)
3189         * (pic16_BuildFlow): fixed skip instructions with label (did not start
3190           new flow)
3191         * (pic16_getJumptabpCode): NEW, needed in...
3192         * (LinkFlow): fixed handling of jumptables, calls and conditional
3193           branches
3194         * (pic16_InsertCommentAfter): NEW
3195         * (pic16_pCodeReplace): made verbose and flow preserving
3196         * (AnalyzeFlow): added call to data flow analysis
3197         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
3198         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
3199         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
3200
3201 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3202
3203         * src/SDCCast.c (decorateType): fixed bug #1105626
3204
3205 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
3206
3207         * device/include/asm/pic16/features.h,
3208         * pic18f*.h headers,
3209         * device/include/pic16/adc.h,
3210         * device/include/pic16/delay.h,
3211         * device/include/pic16/i2c.h,
3212         * device/include/pic16/malloc.h,
3213         * device/include/pic16/stdio.h,
3214         * device/include/pic16/stdlib.h,
3215         * device/include/pic16/string.h,
3216         * device/lib/pic16/libc/stdio/printf_tiny.c,
3217         * device/lib/pic16/libc/stdio/printf_small.c,
3218         * device/lib/pic16/libc/stdio/strmgpsim.c,
3219         * device/lib/pic16/libc/stdio/strmmssp.c,
3220         * device/lib/pic16/libc/stdio/strmusart.c,
3221         * device/lib/pic16/libc/stdio/vfprintf.c,
3222         * device/lib/pic16/libc/stdlib/ltoa.c,
3223         * device/lib/pic16/libc/stdlib/putchar.c,
3224         * device/lib/pic16/libc/stdlib/x_ftoa.c,
3225         * device/lib/pic16/libc/stdlib/memchrpgm.c,
3226         * device/lib/pic16/libc/stdlib/memchrram.c,
3227         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
3228         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
3229         * device/lib/pic16/libio/adc/adcbusy.c,
3230         * device/lib/pic16/libio/adc/adcread.c,
3231         * device/lib/pic16/libio/adc/adcsetch.c,
3232         * device/lib/pic16/libio/usart/ubaud.c,
3233         * device/lib/pic16/libio/usart/ubusy.c,
3234         * device/lib/pic16/libio/usart/udrdy.c,
3235         * device/lib/pic16/libio/usart/uopen.c,
3236         * device/lib/pic16/libio/usart/uputc.c,
3237         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
3238         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
3239         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
3240         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
3241         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
3242         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
3243         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
3244         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
3245         specific keywords to double underlined form,
3246         * device/lib/pic16/libc/Makefile.rules,
3247         * device/lib/pic16/libsdcc/Makefile.rules,
3248         * device/lib/pic16/libm/Makefile,
3249         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
3250         to compile with C standard set in Makefile.common
3251         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
3252         rand.c and crc.c in compilation process,
3253         * device/lib/pic16/libsdcc/int/divuint.c,
3254         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
3255         `c' from signed to unsigned,
3256         * device/lib/pic16/startup/crt0.c,
3257         * device/lib/pic16/startup/crt0i.c,
3258         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
3259         keywords to double underlined form, bug fixes in _do_cinit function
3260         which prevented the correct initialization of the .idata segment,
3261         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
3262         core to enter a infinite loop
3263         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
3264
3265 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3266
3267         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
3268
3269 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3270
3271         * device/include/Makefile.in: add support for hc08 subdirectory
3272         * device/include/hc08/: new subdirectory
3273         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
3274         Lucas Loizaga, thanks!
3275         * device/include/hc08/mc68hc908qy.h,
3276         * device/include/hc08/mc68hc908gp32.h,
3277         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
3278         their own directory. Changed internal macro names to use the compiler
3279         reserved namespace. Changed SDCC specific keywords to double
3280         underlined form.
3281         * device/include/math.h,
3282         * device/include/malloc.h,
3283         * device/include/stdarg.h,
3284         * device/include/stdbool.h
3285         * device/include/string.h,
3286         * device/include/tinibios.h,
3287         * device/include/ds400rom.h,
3288         * device/include/8051.h,
3289         * device/include/8052.h,
3290         * device/include/80c51xa.h,
3291         * device/include/at89c55.h,
3292         * device/include/at89S8252.h,
3293         * device/include/at89x51.h,
3294         * device/include/at89x52.h,
3295         * device/include/ds80c390.h,
3296         * device/include/reg764.h,
3297         * device/include/regc515c.h,
3298         * device/include/sab80515.h,
3299         * device/include/mcs51/c8051f000.h,
3300         * device/include/mcs51/c8051f018.h,
3301         * device/include/mcs51/c8051f020.h,
3302         * device/include/mcs51/c8051f040.h,
3303         * device/include/mcs51/c8051f060.h,
3304         * device/include/mcs51/c8051f120.h,
3305         * device/include/mcs51/c8051f300.h,
3306         * device/include/mcs51/c8051f310.h,
3307         * device/include/mcs51/c8051f320.h,
3308         * device/include/mcs51/c8051f330.h,
3309         * device/include/mcs51/c8051f350.h,
3310         * device/include/z180.h: Changed SDCC specific keywords to double
3311         underlined form.
3312
3313 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3314
3315         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3316         18F4455,
3317         * (pic16_assignConfigWordValue): disable testing of configuration
3318         register value with config mask,
3319         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3320         function with port->fun_prefix,
3321         * (genFunction): when generating a naked interrupt function never
3322         create an absolute segment placed in interrupt vector address, place
3323         the actual interrupt function at IVA instead, when an interrupt
3324         function is generated with unspecified interrupt then do not create
3325         the absolute section,
3326         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3327         code for generating a call to generic pointer get/put function with
3328         a call to function pic16_callGenericPointer(),
3329         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3330         the call to the generic pointer get/put functions with prefixing the
3331         function name with port->fun_prefix,
3332         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3333         * src/pic16/main.c (_process_pragma): prefix function with
3334         port->fun_prefix,
3335         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3336         calling assembler, old 18Fxxxx macro is deprecated,
3337         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3338         PC_ASMDIR in while condition,
3339         * (findInstruction): add PC_ASMDIR in while condition,
3340         * (buildCallTree): prefix main with port->fun_prefix,
3341         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3342         identifier for variable with banked access in instructions BTFSS,
3343         BTFSC, BCF, BSF, BTG
3344         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3345         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3346         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3347         perform optimization when enviroment variable NO_REG_OPT is set,
3348         * (insideLRBlock): NEW, return 1 if register is inside an
3349         INF_LOCALREGS block,
3350         * (RemoveRegFromLRBlock): remove a register that is completely
3351         eliminated by register optimization, but it is still left in local
3352         register store/restore in/from stack block,
3353         * (Remove2pcodes): after removing register, check to see if it
3354         should be removed from local register store/restore in/from stack
3355         block,
3356         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3357         DUMMY_READ_VOLATILE,
3358
3359         * device/include/pic16/adc.h: minor prototype modifications and
3360         update,
3361         * device/include/pic16/malloc.h: added GPL notice various
3362         modifications,
3363         * device/include/pic16/stdint.h: NEW, standard header for ints
3364         * device/include/pic16/delay.h: NEW, header for delay functions,
3365         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3366         delay1mtcy,
3367         * device/include/pic16/signal.h: NEW, header providing helper macros
3368         for implementing signal handlers,
3369         * device/include/pic16/stdio.h: added prototypes for functions,
3370         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3371         prototypes for stdin and stdout, added macro PUTCHAR to
3372         automatically implement putchar function prototype,
3373         * device/include/pic16/usart.h: modified and updated USART library,
3374         * device/lib/pic16/libio/adc/,
3375         * device/lib/pic16/libio/i2c: some modifications to improve library
3376         performance,
3377         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3378         family of functions,
3379         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3380         family of functions and other sources,
3381         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3382         of the PIC18Fxx[28] devices,
3383         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3384         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3385         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3386         _do_cinit function, because the previous failed when local variables
3387         where not placed in the same memory bank,
3388         * device/lib/pic16/libsdcc/char/: various modifications to improve
3389         library performance,
3390         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3391         information on the new functions of the c library and more...
3392
3393 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3394
3395         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3396
3397 2005-03-26 Raphael Neider <rneider AT web.de>
3398
3399         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3400           if condition == CARRY)
3401         * (genCmp): adapted to new genSkipc semantics
3402         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3403           on rIfx (genCmp was broken)
3404
3405 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3406
3407         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3408         * src/z80/main.c (_keywords[]),
3409         * src/SDCCglobal.h (struct options),
3410         * src/SDCC.y,
3411         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3412         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3413         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3414         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3415         always available in leading double underscore form. The C99 support is
3416         mostly missing, but it's a start.
3417         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3418         reserved identifier "__data".
3419
3420 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3421
3422         * src/mcs51/peeph.def: fixed bug 1170013
3423
3424 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3425
3426         * device/include/mcs51reg.h: fixed bug 842007
3427
3428 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3429
3430         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3431         last time.
3432
3433 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3434
3435         * src/port.h (struct PORT),
3436         * src/avr/ralloc.c (avr_assignRegisters),
3437         * src/avr/main.c,
3438         * src/ds390/ralloc.c (ds390_assignRegisters),
3439         * src/ds390/main.c,
3440         * src/hc08/ralloc.c (hc08_assignRegisters),
3441         * src/hc08/main.c,
3442         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3443         * src/mcs51/main.c,
3444         * src/pic/ralloc.c (pic14_assignRegisters),
3445         * src/pic/main.c,
3446         * src/pic16/ralloc.c (pic16_assignRegisters),
3447         * src/pic16/main.c,
3448         * src/xa51/ralloc.c (xa51_assignRegisters),
3449         * src/xa51/main.c,
3450         * src/z80/ralloc.c (z80_assignRegisters),
3451         * src/z80/ralloc.h,
3452         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3453         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3454         * src/SDCCcse.h,
3455         * src/SDCCdflow.c (computeDataFlow),
3456         * src/SDCCdflow.h,
3457         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3458         * src/SDCCloop.h,
3459         * src/SDCCcflow.c (*),
3460         * src/SDCCcflow.h,
3461         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3462         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3463         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3464         immedDom() returning wrong block; probably fixes bug #1160833)
3465
3466 2005-03-20 Borut Razem <borut.razem AT siol.net>
3467
3468         * support/scripts/inc2h.pl: WIN32 port
3469
3470 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3471
3472         * device/lib/makefile.in: added abs.c and labs.c
3473
3474 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3475
3476         * device/include/stdint.h: added
3477         * device/lib/abs.c: added
3478         * device/lib/labs.c: added
3479         * device/include/stdlib.h: added abs() and labs() prototypes
3480         * device/lib/libsdcc.lib: added abs and labs
3481         * device/include/float.h,
3482         * device/lib/_fsmul.c,
3483         * device/lib/printf_fast.c,
3484         * device/lib/printf_tiny.c: updated comments
3485
3486 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3487
3488         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3489         bug #1164313
3490
3491 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3492
3493         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3494         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3495
3496 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3497
3498         * device/lib/printf_large.c: removed inline assembly for portability and
3499           readability. Use printf_fast if speed or size are more important.
3500         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3501         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3502
3503 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3504
3505         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3506         prevent compiler warning
3507
3508 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3509
3510         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3511         moved to level 0 and declared as static. Also they are explicit
3512         placed in access bank. This was necessery because some times they
3513         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3514         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3515         optimizations. Currently only compare to unsigned char is implemented,
3516         * src/pic16/gen.c: added fReturnIdx array,
3517         * (struct resolvedIfx) is moved to gen.h and made public,
3518         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3519         * (aopForSym): added an optimization to directly store in stack of
3520         the operand of a SEND iCode,
3521         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3522         but as registers instead (AOP_REG) using the fReturnIdx array,
3523         * (pic16_freeAsmop): remove the freed register from the
3524         _G.sregsAlloc field,
3525         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3526         a compare of 'WREG',
3527         * (pic16_popGetTempRegCond): changed function prototype, now
3528         function takes also a bitVector argument v which holds the current
3529         set of registers that are allocated for stack access by aopForSym,
3530         registers allocated in aopForSym for accessing stack symbols are not
3531         any more part of the functions usedRegs field,
3532         * (genCall): some times aopOp is called for a stack variable to be
3533         send, aopForSym might perform the push, if this is true make sure
3534         that genCall doesn't push the variable twice by testing _G.resDirect,
3535         * (genFunction): changed testing for unspecified interrupt number
3536         from 256 to INTNO_UNSPEC,
3537         * modified selection scheme of frame pointer generation. Previously
3538         if function did use local registers a frame pointer was generated,
3539         now a frame pointer is generated only if function has arguments
3540         (that need PLUSW2 register access), or has stack arguments, or the
3541         compiler is not instructed to omit the frame pointer,
3542         * (genEndFunction): before restoring local registers that were saved
3543         in the function preamble, also restore the registers that *might*
3544         have been allocated for stack access,
3545         * (genRet): removed some old comments,
3546         * (genCmp, the active (RN's) version): added a call to the
3547         pic16_genCmp_special function to perform the compare with a more
3548         robust and optimized way,
3549         * (genInline): a feature has been added in inline code generation,
3550         which allows a wildcard variable substitution when writing inline
3551         assembly. Code is incomplete and experimental therefore undocumented,
3552         * (genCast): changed order of aopOp for result and right to allow
3553         aopForSym to directly load the result if possible,
3554         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3555         perform an optimized compare on some selected special occasions,
3556         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3557         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3558         generate an IVT any more,
3559         * src/pic16/main.c (pic16_optionsTable): added command line option
3560         --optimize-cmp,
3561         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3562         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3563         macros,
3564         * src/pic16/NOTES: Raphael Neider added in list of active developers
3565         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3566         jumptable_end to prevent bug #,
3567         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3568         inCond and outCond fields,
3569         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3570         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3571         turn off register spilling,
3572         * (packRegsForOneUse): synced with other ports' versions although it
3573         is not used currently,
3574         * (pic16_packRegisters): added an optimization while reading
3575         structure bitfields, some registers may be saved (malloc code is
3576         decreased by 80 bytes)
3577
3578 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3579
3580         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3581         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3582         this can be optimized more?
3583
3584 2005-03-10 Raphael Neider <rneider AT web.de>
3585
3586         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3587           genNearPointerGet): (hopefully) fixed access to bitfields via
3588           pointers (p->bitN = x; and x = p->bitN; failed)
3589
3590 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3591
3592         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3593
3594 2005-03-09 Raphael Neider <rneider AT web.de>
3595
3596         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3597
3598 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3599
3600         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3601         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3602           (regTypeNum): set REG_BIT type if necessary
3603         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3604         * support/regression/tests/critical.c: check bug 1144613
3605
3606 2005-03-02 Raphael Neider <rneider AT web.de>
3607
3608         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3609
3610 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3611
3612         * src/avr/ralloc.c (serialRegAssign),
3613         * src/ds390/ralloc.c (serialRegAssign),
3614         * src/hc08/ralloc.c (serialRegAssign),
3615         * src/mcs51/ralloc.c (serialRegAssign),
3616         * src/pic/ralloc.c (serialRegAssign),
3617         * src/pic16/ralloc.c (serialRegAssign),
3618         * src/xa51/ralloc.c (serialRegAssign),
3619         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3620
3621 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3622
3623         * src/SDCCast.c (decorateType): fixed bug 1124787
3624
3625 2005-02-20 Hubert Sack <sack AT digiplan.de>
3626         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3627
3628         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3629         patch #1121755
3630
3631 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3632
3633         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3634         to keep the correct label reference count when adding/removing references
3635         to labels. A peephole file using this is appended to patch #1144962.
3636
3637 2005-02-14 Raphael Neider <rneider AT web.de>
3638
3639         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3640         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3641         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3642           retrievals of result operand's value on assignment
3643
3644 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3645
3646         * device/include/pic16/string.h: modified prototype for memccpy()
3647         to memccpy(void *, void *, char, size_t)
3648         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3649         check whether to omit frame pointer or not,
3650         * (genInline): convert all occurences of "\n" to LF in inline
3651         assembler blocks, this helps formatting the inline text,
3652         * (pic16_loadFSR0): modified prototype,
3653         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3654         removed some 8051 legacy code,
3655         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3656         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3657         before allocating temporary registers in functions,
3658
3659 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3660
3661         * support/regression/tests/bitvars.c: corrected the "fix"
3662
3663 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3664
3665         * support/regression/tests/bitvars.c,
3666         * support/regression/tests/bitwise.c,
3667         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3668
3669 2005-02-10 Raphael Neider <rneider AT web.de>
3670
3671         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3672           different size for Alpha
3673         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3674
3675 2005-02-09 Raphael Neider <rneider AT web.de>
3676
3677         * src/SDCC.lex(doPragma) : save and restore warning options as well
3678           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3679         * have #pragma less_pedantic set the errorlevel to WARNING
3680           (fixes #1117001)
3681         * (cloneOptimize) : fixed wrong malloc's size
3682         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3683           facilitate correct handling of #pragma (save|restore)
3684
3685 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3686
3687         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3688
3689 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3690
3691         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3692
3693 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3694
3695         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3696
3697 2005-02-02 Raphael Neider <rneider AT web.de>
3698
3699         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3700         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3701         * (pic16_storeForReturn): fixed to allow returning function pointers
3702         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3703         * device/include/pic16/{stddef.h,stdbool.h}: added
3704
3705 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3706
3707         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3708
3709 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3710
3711         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3712         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3713          appeared to be required
3714
3715 2005-01-31 Borut Razem <borut.razem AT siol.net>
3716
3717         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3718           include/mcs51 and include/z80 directories to the package
3719
3720 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3721
3722         * src/hc08/gen.c (genFunction): fixed bug #1112752
3723
3724 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3725
3726         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3727
3728 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3729
3730         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3731
3732 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3733
3734         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3735
3736 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3737
3738         * device/include/c8051fxxx.h: removed these 6 files
3739         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3740
3741 2005-01-26 Raphael Neider <rneider AT web.de>
3742
3743         * src/pic16/gen.c (genAssign): fixed assignment from longs
3744           in codespace (were cut to three bytes)
3745         * (genDummyRead): implemented (except for CODESPACE...),
3746           fixed bug #1108575
3747         * src/pic16/glue.c (emitStatistics): beautified
3748         * device/lib/pic16/libm/Makefile: added include path
3749
3750 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3751
3752         * src/z80/gen.c (aopPut): fixed bug #1103902
3753
3754 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3755
3756         * device/lib/expf.c: fixed bug #1095792
3757
3758 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3759
3760         * device/lib/pic16/libm: added Math library sources
3761
3762 2005-01-24 Raphael Neider <rneider AT web.de>
3763
3764         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3765           to enable upcast to pCodeOpReg2 (there is no type tag to
3766           differenciate the two and pic16_popGet2p cast into PCOR2)
3767         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3768           (sizeof(sectNames) changed to sizeof(sectName))
3769           Both patches fix segfaults under MinGW.
3770
3771 2005-01-23 Raphael Neider <rneider AT web.de>
3772
3773         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3774           Safe_[mc]?alloc()'ed variables
3775         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3776           of (byte sized) temporaries (assign them to WREG for now)
3777         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3778           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3779           this might fix SIGSEGVs on MinGW...
3780         * src/SDCCopt.c (killDeadCode): restored original behaviour
3781           (volatile operands might get thrown away though)
3782
3783 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3784
3785         * src/pic16/gen.c: fixed bug #1106975,
3786         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3787         pointer update, INTCON is saved, global interrupts are disabled and
3788         restored after updateing TOS.
3789         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3790         * added function attribute 'shadowregs' to take advantage of shadow
3791         registers,
3792         * added function attribute 'wparam' as an alternative to the wparam
3793         pragma,
3794         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3795         user declares a non-ISR function as 'shadowregs',
3796         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3797
3798 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3799
3800         * .version: bumped version number to 2.4.8
3801         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3802         pic16 port,
3803         * device/lib/pic16/libio/i2c/: I2C module support library,
3804         * device/include/pic16/i2c.h: I2C support library header,
3805         * device/lib/pic16/libc/stdio/: standard IO support sources,
3806         * (printf_small.c): printf_small() source, supports float print,
3807         * (printf_tiny.c): printf_tiny() source, does not support floats,
3808         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3809         enable global optimizations for entire library source, other
3810         Makefiles in the source tree are also modified to reflect this,
3811         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3812         function,
3813         * doc/sdccman.lyx: updated to reflect new changes,
3814         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3815         sym->onStack if-case,
3816         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3817         sbit, idata, _idata, xdata, _xdata,
3818         * added pragma library, to link an external library, (see doc),
3819         * removed command line options, --pomit-config-words, --pomit-ivt,
3820         --pleave-reset-vector,
3821         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3822         when calling assembler to reflect memory model used, also define
3823         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3824         reflect stack model used,
3825         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3826         on stack return NULL,
3827
3828 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3829
3830         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
3831           of the operands is volatile. Fixes #1020220
3832
3833 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3834
3835         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
3836         * (OptimizeRegUsage): make sure that there is really no other flow where
3837           the first pCode is used
3838
3839 2005-01-22 Raphael Neider <rneider AT web.de>
3840
3841         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
3842           to fix #1106967 (pCode->seq are not set up correctly)
3843
3844 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3845
3846         * src/SDCCglue.c (glue): make sure code area is declared before the
3847         static initialization area.
3848
3849 2005-01-21 Raphael Neider <rneider AT web.de>
3850
3851         * device/lib/Makefile.in: fixed test for pic16 install dir
3852         * device/lib/pic16/*/Makefile*: modified compile flags to enable
3853           optimizations
3854         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
3855           added --optimize-goto compiler switch and pragma wparam documentation
3856         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
3857         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
3858           and PRODH closing bug #1071770 (peephole optimizer)
3859
3860 2005-01-19 Raphael Neider <rneider AT web.de>
3861
3862         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
3863           cmdLine buffers (used when calling sdcpp...) are large enough
3864           (MAX_PATH=256 truncates arguments leading to system halts when
3865           used in MinGW...)
3866         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
3867         * (genUminus): rewritten to for efficiency
3868         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
3869           used uninitialized in some cases)
3870         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
3871           copy the third byte from the int -- now assumes 0x80 (data memory)
3872         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
3873           operands (genAddLit expects the iCode's operands to swapped as
3874           well), fixed leftover bytes (crashed for short left operands)
3875         * (pic16_genMinusDec): performance improvements, removed false
3876           PIC14 emitSKPNCs
3877         * (pic16_genMinus): fixed to cope with differently sized operands
3878         * src/pic16/glue.c (pic16_glue): added new banksel optimization
3879           for --obanksel > 1
3880         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
3881         * src/pic16/graph.[ch]: implementation of directed graphs, used by
3882           new banksel optimization
3883         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
3884           analysis for temporary registers (segfaults...)
3885         * src/pic16/peeph.def: added rule
3886
3887 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
3888
3889         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
3890         which converts a float number to its ASCII representation
3891         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
3892         functions to convert the fractional and integer part of a float to ASCII,
3893         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
3894         realloc.c): added _MALLOC_SPEC to explicit place variables in data
3895         ram
3896         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
3897         _STATMEM macros,
3898         * device/include/pic16/adc.h: added GPL info,
3899         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
3900         a pCodeOp as tested operand,
3901         * (genNearPointerGet): optimized bit testing, does not use
3902         intermediate register for bit value, test directly instead with
3903         BTFSS, BTFSC, works only for single bits,
3904         * (genpic16Code): dump the name of the iCode in the asm,
3905         * src/pic16/ralloc.c (decodeOp): removed static declaration and
3906         renamed to pic16_decodeOp,
3907         * (serialRegAssign): do not allocate a temporary register for iCode
3908         sequences that test a single bit for 1/0
3909
3910 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
3911
3912         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
3913         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
3914         access stack and frame pointers. They are initially assigned to
3915         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
3916         accessing SFRs. Updated all occurences of modification of stack or
3917         frame pointer in gen.c and pcode.c,
3918         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
3919         assigning of a literal value to pointers,
3920         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
3921         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
3922         selected
3923
3924 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
3925
3926         * doc/sdccman.lyx: update documentation about stack pragma, added
3927         some info for stack memory models
3928
3929 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3930
3931         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
3932
3933 2005-01-08 Raphael Neider <rneider AT web.de>
3934
3935         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
3936           udata sections to fix bug #1097823
3937
3938 2005-01-05 Raphael Neider <rneider AT web.de>
3939
3940         * src/pic16/gen.c (genGenericShift): added handling of differently
3941           sized left operand and result
3942
3943 2005-01-04 Raphael Neider <rneider AT web.de>
3944
3945         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
3946         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
3947           to hold the condition bit)
3948         * added new version of genCmp (old code available via #define)
3949         * added new version of genShiftLeft/genShiftRight in a generic
3950           way, now supports shifting by negative values
3951         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
3952           shiftCount (expected by genGenericShift)
3953         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
3954         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
3955           dump
3956         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
3957           is an invalid literal too...)
3958
3959 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
3960
3961         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
3962         from Raphael Neider,
3963         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
3964         for 8-bit literals. This fixes some literal operands which are sign
3965         extended to 16-bits ints when instruction needs only 8-bits.
3966
3967 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
3968
3969         * device/lib/logf.c: added mcs51 assembly version
3970         * device/lib/expf.c: added mcs51 assembly version
3971         * device/lib/_logexpf.c: new shared asm code for expf and logf
3972         * device/include/math.h: add defines for assembly math library
3973         * device/lib/Makefile.in: build new _logexpf.c
3974         * device/lib/libfloat.lib: use new _logexpf.c
3975
3976 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3977
3978         * src/pic/device.c
3979         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
3980           device types which have less than 0x7f registers.
3981
3982 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
3983
3984         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
3985
3986 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
3987
3988         * device/lib/printf_fast.c: only build on supported arch.
3989         * device/lib/printf_tiny.c: only build on supported arch.
3990         * device/lib/printf_fast_f.c: only build if asm float lib
3991         * device/lib/_fsget1arg.c: only build if asm float lib
3992         * device/lib/_fsget2args.c: only build if asm float lib
3993         * device/lib/_fsnormalize.c: only build if asm float lib
3994         * device/lib/_fsreturnval.c: only build if asm float lib
3995         * device/lib/_fsrshift.c: only build if asm float lib
3996         * device/lib/_fsswapargs.c: only build if asm float lib
3997         * device/include/stdio.h: don't provide print_fast,
3998           print_fast_f, print_tiny prototypes if --xstack used
3999
4000 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
4001
4002         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
4003         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
4004           to the SOURCES
4005
4006 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4007
4008         * device/lib/printf_fast_f.c: same as printf_fast, but
4009           with floating point enabled
4010         * device/lib/printf_fast.c: minor tweaks
4011         * device/include/stdio.h: add printf_fast_f
4012
4013 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4014
4015         * src/SDCCmain.c: make --float-reent default for mcs51
4016         * device/lib/_fsadd.c: added mcs51 assembly version
4017         * device/lib/_fssub.c: added mcs51 assembly version
4018         * device/lib/_fsmul.c: added mcs51 assembly version
4019         * device/lib/_fsdiv.c: added mcs51 assembly version
4020         * device/lib/_fseq.c: added mcs51 assembly version
4021         * device/lib/_fsneq.c: added mcs51 assembly version
4022         * device/lib/_fsgt.c: added mcs51 assembly version
4023         * device/lib/_fslt.c: added mcs51 assembly version
4024         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
4025         * device/lib/Makefile.in: add _fscmp to build
4026         * device/lib/libfloat.lib: add _fscmp to build
4027
4028 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4029
4030         * device/lib/_fs2slong.c: added mcs51 assembly version
4031         * device/lib/_fs2sint.c: added mcs51 assembly version
4032         * device/lib/_fs2schar.c: added mcs51 assembly version
4033         * device/lib/_fs2ulong.c: added mcs51 assembly version
4034         * device/lib/_fs2uint.c: added mcs51 assembly version
4035         * device/lib/_fs2uchar.c: added mcs51 assembly version
4036         * device/lib/_slong2fs.c: added mcs51 assembly version
4037         * device/lib/_sint2fs.c: added mcs51 assembly version
4038         * device/lib/_schar2fs.c: added mcs51 assembly version
4039         * device/lib/_ulong2fs.c: added mcs51 assembly version
4040         * device/lib/_uint2fs.c: added mcs51 assembly version
4041         * device/lib/_uchar2fs.c: added mcs51 assembly version
4042         * device/include/float.h: added #define to select asm vs c
4043
4044 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
4045
4046         * device/lib/printf_fast.c: improvements to float output
4047         * device/include/float.h: add defines for assembly float library
4048         * device/lib/_fsget1arg.c: receive 1 float arg
4049         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
4050         * device/lib/_fsnormalize.c: normalize a float
4051         * device/lib/_fsreturnval.c: return float, various helper routines
4052         * device/lib/_fsrshift.c: right shift a float's mantissa
4053         * device/lib/_fsswapargs.c: swap 2 floats
4054         * device/lib/Makefile.in: build these 6 new files for mcs51
4055         * device/lib/libfloat.lib: add these 6 files to the library
4056
4057 2004-12-26 Borut Razem <borut.razem AT siol.net>
4058
4059         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
4060           built by gcc 3.4.2
4061
4062 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
4063
4064         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
4065           and fully reentrant and register bank neutral.
4066         * device/lib/printf_fast.c: added float (not enabled by default),
4067           added compact/slower integer (also not enabled by default),
4068           improved size/speed of fast integer code, other minor changes
4069         * device/include/stdio.h, device/lib/Makefile.in,
4070           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
4071
4072 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
4073
4074         * src/pic16/pcode.c: declaring variables other than at the start of a
4075           block is not supported in C by VC6.
4076
4077 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
4078
4079         * applied a previous patch from Raphael Neider that wasn't included
4080         in the previous commits, which fixes infinite loops within jumptable
4081         improvements,
4082         * made some fixes that previous patches introduced
4083
4084 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
4085
4086         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
4087         that fixes an issue with AOP_PCODE asmop's offset,
4088         * (pic16_popCopyReg): update instance field too,
4089         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
4090         function of pic port,
4091         * (genCmp, genAnd, genAssign),
4092         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
4093
4094 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
4095
4096         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
4097         variables initial values to idata section,
4098         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
4099         variables in some functions. This utilizes parmBytes field of iCode
4100         structure to hold the offset of the variable in stack. (might be
4101         able to use the stack field too?)
4102         * applied patch from Raphael Neider # ### , # ###
4103         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
4104         variable initial values in idata section,
4105         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
4106         for static variables with initial value
4107         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
4108         applied fix in while loop from Raphael Neider.
4109
4110 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
4111
4112         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
4113         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
4114         * src/ds390/ralloc.c (serialRegAssign): spill bits
4115         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
4116         * support/Util/SDCCerr.c,
4117         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
4118         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
4119         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
4120
4121 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
4122
4123         * device/include/sdcc-lib.h: inserted LGPL, added includes
4124           asm/ds390/features.h and asm/mcs51/features.h
4125         * device/include/asm/default/features.h,
4126         * device/include/asm/gbz80/features.h,
4127         * device/include/asm/z80/features.h: added empty _AUTOMEM
4128           and _STATMEM
4129         * device/include/asm/ds390/features.h,
4130         * device/include/asm/mcs51/features.h: added files with defines for
4131           _AUTOMEM and _STATMEM indicating automatic and static storage class
4132         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
4133         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
4134         * src/SDCCicode.c (geniCodeCast),
4135         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
4136         * src/SDCCloop.c (loopInduction): removed unused variable lr
4137         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
4138           to convertToFcall to include char modulo (RFE 1065037), added check
4139           if left operand is unsigned and use abs of literal value
4140         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
4141           as it doesn't work after conversion from peephole.def to peephole.rul
4142         * src/mcs51/gen.c (toBoolean): added check for size,
4143           (genModOneByte): optimized code for signed char modulo a literal
4144           power of 2 (thanks to Hubert Sack),
4145           (genRRC): removed unnecessary "clr c",
4146           (genRLC): replaced "add a,acc" with cheaper "rlc a"
4147         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
4148           jump optimization,
4149           swapped rules 256.c and 256.d,
4150           extended 256.d by using new multiple checks (thanks Erik),
4151           added rules 256.e and 256.f,
4152           updated rule 261.a and 261.b to new generated code
4153         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
4154
4155 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4156
4157         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
4158           induction related bugs, including first part of bug #1074377
4159
4160 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
4161
4162         * applied patch from bug-report #1076292,
4163         * applied patches for genAnd and Goto-optimizations for Raphael
4164         Neider,
4165         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
4166         dump a less iCode information,
4167         * src/pic16/device.h (pic16_options_t): added field debgen,
4168         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
4169         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
4170         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
4171         puclic,
4172         * (various functions): added macros FENTRY and FENTRY2 to functions,
4173         to emit function prologue,
4174         * (various functions): fixed indentation,
4175         * (genNearPointerGet): fixed loading of FSR0,
4176         * (genPackBits): applied patch from Raphael Neider to fix updating
4177         of FSR0 and touching only the modified bits,
4178         * src/pic16/genarith.c (various functions): added macros FENTRY to
4179         emit function prologue in comments,
4180         * src/pic16/pcode.h: added functions debugf2, debugf3,
4181         * src/pic16/ralloc.c: partial fix for packForPush caused
4182         segmentation fault,
4183
4184 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4185
4186         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
4187           <stsp AT users.sourceforge.net> with reversed byte order
4188         * support/regression/tests/rotate.c: added (ds390 skips some tests)
4189
4190 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4191
4192         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
4193           bug #1074377
4194         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
4195         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
4196
4197 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4198
4199         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
4200
4201 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4202
4203         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
4204           conditions,
4205           (setFromConditionArgs): friendly operand parser for peephole rules,
4206           (operandBaseName, operandsNotRelated): new peephole condition
4207           "operandsNotRelated" -- similar to "operandsNotSame", but takes
4208           architecture specific register naming into account, handles n-way
4209           comparisons, and supports quoted literals
4210         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
4211
4212 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4213
4214         * src/mcs51/peeph.def: fixed bug #1076940
4215
4216 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4217
4218         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
4219
4220 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4221
4222         Adding support for replacing ljmps with sjmps in jumptables
4223         generated for switch statements. For now you need to set the
4224         environment variable SDCC_SJMP_JUMPTABLE to enable this.
4225         Now 4 algorithms for mcs51 jumptable generation are used:
4226         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
4227         addresses loaded pc-relative for up to 112 cases and stack-pushing
4228         target addresses loaded with offset from dptr for up to 256 cases.
4229
4230         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
4231         * src/mcs51/main.c: adapted constants for switch table generation
4232         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
4233
4234 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
4235
4236         * device/lib/printf_large.c (_print_format): fixed bug 1073386
4237         * support/regression/tests/bug1057979.c: added test for bug 1073386
4238
4239 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4240
4241         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
4242         compilers
4243
4244 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4245
4246         * src/pic16/device.h,
4247         * src/pic16/genarith.c,
4248         * src/pic16/glue.c,
4249         * src/pic16/main.c,
4250         * src/pic16/pcode.c: applied patches #1068154 and #1070213
4251
4252 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
4253
4254         Large cummulative patch for pic16 port.
4255         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
4256         to call when a stack overflow occurs,
4257         * (malloc.h): added CVS Id tag,
4258         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
4259         variable,
4260         * added libc directory. The current version of LibC contains string
4261         functions, ctype functions and macros and some functions of the
4262         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
4263         be extensively tested in the future. Standard disclaimer here.
4264         Library is not automatically build yet. But one can build it by
4265         invoking 'make' inside the libc directory.
4266         * added ADC library under libio. Preliminary version yet.
4267
4268         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
4269         * src/pic16/gen.c (aopForRemat): asmop size is filled by
4270         aopForRemat() now and not by pic16_aopOp(),
4271         * (pic16_popGetTempReg): removed warning messgae when allocating
4272         temporary registers, its a buggy feature and will be removed,
4273         * (pic16_popGet): set register instance field in AOP_CRY,
4274         * (pic16_outBitC): fixed for results in size greater than 1,
4275         * (genUminusFloat): fixed for pic16, ported code from mcs51,
4276         * (pic16_storeForReturn): optimized return of 0,
4277         * (genCmp): experimental code for new genCmp which uses PIC18's
4278         special compare&skip instructions. Initial tests fail some times
4279         with variables grater than 1 byte in size, so new code is disabled,
4280         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
4281         a single bit,
4282         * (genCast): began a fix to optimize the casting of a bit to another
4283         bit, now assigning a bitfield to another bitfield will fail, sorry,
4284         * src/pic16/main.c: disabled the use of lr-support feature,
4285         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
4286         * added some function prototypes, added function _debugf prototype,
4287         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
4288         bits with offset (case PO_GPR_BIT),
4289         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
4290         command line,
4291         * (isBankInstruction): modified to return 0 for no banking instruction,
4292         and 1 for banking instruction,
4293         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
4294         caused stop processing pCodes after a inline assembly block,
4295         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
4296         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4297         registers when it shouldn't,
4298         * src/pic16/ralloc.c (allocReg): add preliminary support for
4299         supporting a limited set of temporary registers,
4300
4301 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4302
4303         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4304           genDataPointerSet): ensure assignments always copy in MSB to LSB
4305           order,
4306           (loadRegFromAop): recognize CLRH optimization,
4307           (genFunction): optimize RECEIVE iCodes in reentrant functions
4308
4309 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4310
4311         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4312           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4313           selected.
4314         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4315         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4316           contiguous with data
4317
4318 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4319
4320         * device/lib/_gptrget.c (_gptrget),
4321         * device/lib/_gptrgetc.c (_gptrgetc),
4322         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4323           instead of sjmp to ret
4324         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4325           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4326
4327 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4328
4329         * .version: bumped version to 2.4.7
4330         * device/lib/_gptrget.c (_gptrget): is now _naked
4331         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4332         * device/lib/_gptrput.c (_gptrput): is now _naked
4333         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4334           (createFunction): fixed xstack
4335         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4336         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4337           or bit either,
4338           (geniCodeCritical): store original interrupt state in an iTemp bit
4339           var unless stack-auto
4340         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4341         * src/SDCCmain.c (setIncludePath): added include/target to search path
4342         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4343         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4344           prototype,
4345           (processFuncArgs): put bit vars in bit area
4346         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4347           unsaveRBank): fixed xstack,
4348           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4349           (genFunction, genEndFunction): fixed xstack,
4350           (genAssign): optimization don't walk backwards through mem
4351         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4352         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4353         * support/regression/Makefile: also make library (for stack-auto) when
4354           making "all" and added "test-mcs51-xstack-auto"
4355         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4356         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4357         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4358         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4359         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4360           make-library by MAKE_LIBRARY
4361         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4362           regression tests for xstack
4363         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4364         * support/regression/tests/critical.c: test for critical on mcs51
4365
4366 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4367
4368         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4369           built version of sdcc instead of installed version
4370
4371 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4372
4373         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4374         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4375           vprintf.c now
4376         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4377         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4378           WARNING: remove device/lib/build/z80/printf.o by hand when
4379           updating from previous build!
4380         * device/lib/z80/printf.c: updated comment
4381         * support/regression/tests/bug1057979.c: test all ports now
4382         * support/regression/tests/bug1065458.c: file added
4383
4384 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4385
4386         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4387           *_start and *_end symbols for static functions
4388
4389 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4390
4391         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4392           and search crt0.o in all library paths,
4393           (setIncludePath): proper handling of --nostdinc,
4394           (setLibPath): proper handling of --nostdlib
4395         * support/regression/Makefile,
4396         * support/regression/ports/ds390/spec.mk,
4397         * support/regression/ports/gbz80/spec.mk,
4398         * support/regression/ports/hc08/spec.mk,
4399         * support/regression/ports/mcs51/spec.mk,
4400         * support/regression/ports/mcs51-large/spec.mk,
4401         * support/regression/ports/mcs51-stack-auto/spec.mk,
4402         * support/regression/ports/z80/spec.mk: use include and lib files from
4403           built version of sdcc instead of installed version
4404         * doc/sdccman.lyx: fixed typo in --nostdinc
4405
4406 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4407
4408         * src/pic/pcode.c,
4409         * src/pic/device.c,
4410         * src/pic/ralloc.c,
4411         * src/pic/gen.c : added support to generate code for struct bit fields.
4412
4413 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4414
4415         * as/xa51/xa_version.h,
4416         * device/include/errno.h,
4417         * device/include/regc515c.h,
4418         * device/lib/_itoa.c,
4419         * device/lib/_ltoa.c,
4420         * device/lib/ser_ir_cts_rts.c,
4421         * sim/ucsim/xa.src/glob.cc,
4422         * sim/ucsim/xa.src/inst_gen.cc,
4423         * sim/ucsim/xa.src/xa_bit.cc,
4424         * sim/ucsim/xa.src/xa_sfr.cc,
4425         * sim/ucsim/z80.src/inst_dd.cc,
4426         * sim/ucsim/z80.src/inst_fdcb.cc,
4427         * support/scripts/keil2sdcc.pl,
4428         * src/pic16/pic16.dsp,
4429         * src/pic16/pic16a.dsp: corrected cvs line endings
4430         * device/lib/printf_large.c: fixed bug 1057979
4431         * src/pic16/gen.c: fixed non-C standard code
4432         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4433         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4434         * support/regression/ports/mcs51/support.c: reload T1 asap
4435         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4436           pdata use and clear idata startup behaviour
4437         * support/regression/tests/bug1057979.c: added
4438
4439 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4440
4441         * device/examples/ds390/ow390/ad26.h,
4442         * device/examples/ds390/ow390/cnt1d.h,
4443         * device/examples/ds390/ow390/crcutil.c,
4444         * device/examples/ds390/ow390/ownet.h,
4445         * device/examples/ds390/ow390/owsesu.c,
4446         * device/examples/ds390/ow390/swt12.h,
4447         * device/examples/ds390/ow390/swtoper.c,
4448         * device/examples/ds390/ow390/temp10.h,
4449         * device/examples/ds390/ow390/thermodl.c,
4450         * device/examples/ds390/tinitalk/tinitalk.dsp,
4451         * device/examples/ds390/tinitalk/tinitalk.dsw,
4452         * device/examples/mcs51/clock/hw.h,
4453         * device/examples/mcs51/simple2/go.bat,
4454         * device/examples/serialcomm/windows/serial.h,
4455         * device/examples/xa51/dummy.c,
4456         * device/examples/xa51/hello.c,
4457         * device/include/80c51xa.h,
4458         * device/include/at89x051.h: corrected cvs line endings
4459
4460 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4461
4462         * src/pic16/main.c (options): added command line --gstack, to trace
4463         stack over/under flows,
4464         * added pragma 'wparam' to allow passing first byte of function
4465         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4466         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4467         call to __gstack_test function and sets up the symbol as extern,
4468         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4469         * popaop): added call to pic16_testStackOverflow,
4470         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4471         wparamList list,
4472         * (genCall, genPcall): now all parameters are passed via stack
4473         except in functions that are pass to wparam pragma in which WREG is
4474         used too,
4475         * (genPcall): REENTRANT flag is checked to see if variable prototype
4476         contains reentrant keyword, don't call a non-reentrant function, via
4477         a reentrant function pointer or vice versa, functions are never
4478         passed via WREG,
4479         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4480         D.Winkler,
4481         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4482         SIGSEGV when accessing a NULL register stucture,
4483         * (pic16_printGPointerType): modified to handle UPPER modifier for
4484         function initializers, changed prototype of function to simpler one,
4485         * (pic16_printIvalFuncPtr): check to see if function is already
4486         added in externs list,
4487         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4488         optimized a move from W to SFR with a move to the same register
4489         later after a CALL,
4490         * device/lib/pic16/debug: NEW directory, contains debug features
4491         which are enabled when linking with libdebug.lib, currently command
4492         line option --gstack enables stack pointer tracing for over/under
4493         flow, corresponding sources are in debug/gstack
4494
4495 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4496
4497         * doc/sdccman.lyx: updated SDCC version,
4498         * (PIC16 port): update list of command line options,
4499         * src/pic16/device.h (structure pic16_options_t): added field gstack
4500         to enable stack overflow tracing on push/pops,
4501         * src/pic16/device.c (statistics structure): added statistics
4502         structure,
4503         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4504         pic16_dump_int_registers): increase statistics counters for each
4505         * variable which is encountered
4506         * (pic16_dump_usection): emit each .udata variable to its own udata
4507         section,
4508         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4509         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4510         parameters via stack, otherwise use old scheme,
4511         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4512         assembler output file,
4513         * src/pic16/main.c: added command line options --gstack to enable
4514         push/pop tracing for stack overflow,
4515         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4516         instructions): added size of each instruction,
4517         * (pic16_countInstruction): estimate size of instructions in
4518         the_pFile list, inline assembly blocks are not counted,
4519         * (pic16_FixRegisterBanking): trace previous register usage, when
4520         banksel optimizations is greater than 0, don't emit a redudant
4521         banksel directive,
4522
4523 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4524
4525         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4526         * src/pic16/ralloc.c : applied same fix for pic16.
4527         * src/pic/gen.c : tidied it up a little.
4528
4529 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4530
4531         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4532         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4533
4534 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4535
4536         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4537
4538 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4539
4540         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4541         non-reentrant function __modsint in the interrupt function (thus
4542         corrupting math operations during serial I/O)
4543         * device/lib/ser_ir.c: as above, changed buffersize
4544         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4545         256.c,d for zeroing
4546         * doc/Makefile: added option -t for rsync
4547
4548 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4549
4550         * src/SDCCast.h (struct ast),
4551         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4552
4553 2004-10-20 Borut Razem <borut.razem AT siol.net>
4554
4555         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4556         package
4557
4558 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4559
4560         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4561         makefile targets,
4562         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4563         support functions to replace long sequences of MOVFF's from access
4564         bank registers to stack and vice versa,
4565         * src/pic16/device.h: added new field opt_flags, where optimization
4566         flags can be set to enable certain features,
4567         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4568         * pBlock, (genFunction, genEndFunction): surroung loop for
4569         saving/loading used registers in stack with PC_INFO pCodes,
4570         INF_LREGS. Code in between can then be optimized by pCode optimizer
4571         to support function calls,
4572         * (genDataPointerSet): fixed bug which loaded float fields in
4573         structures with corrupt data,
4574         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4575         in a standard way debug info on stderr. Feature used for developing
4576         and debugging only,
4577         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4578         obsolete chunks of code,
4579         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4580         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4581         * pic16/src/pcode.c (pic16_newpCodeInfo,
4582         * (pic16_newpCodeOpLocalRegs),
4583         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4584         feature,
4585         * (pic16_pCodeConstString): printing of the initial value of a
4586         symbol as a comment is inhibited since parsing was already done by
4587         copyStr and output is corrupt,
4588         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4589
4590 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4591
4592         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4593
4594 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4595
4596         * as/mcs51/lkarea.c: removed old K&R style,
4597           (lnksect): changed check on boundary error,
4598           (lnksect2): changed check on boundary error,
4599           (lnksect2): extend XSTK to end of page if size = 1
4600         * as/mcs51/lkmain.c: removed old K&R style,
4601           (Areas51): create l_IRAM symbol
4602         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4603         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4604           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4605         * device/lib/_mullong.c: added version to be compiled with xstack
4606         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4607         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4608         * device/lib/mcs51/crtxstack.asm: fixed comment
4609         * src/SDCCglue.c: maxInterrupts defaults to 0,
4610           (emitMaps): added pdata,
4611           (createInterruptVect): (re)moved default,
4612           (glue): added pdata,
4613           (glue): moved __start__xstack to XSTK with default size 1
4614         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4615           and options.float_rent when options.stackAuto is set,
4616           (linkEdit): only write XDATA_NAME if provided on command line
4617         * src/SDCCmem.h,
4618         * src/SDCCmem.c: added pdata
4619         * src/port.h: added pdata_name to PORT
4620         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4621           (saveRegisters, unsaveRegisters): removed usage of B,
4622           (genMinus): fixed accumulator clash,
4623           (genJumpTab): added comment, this needs another look
4624         * src/mcs51/gen.c: added check for "B in use" paranoia,
4625           added pushB() and popB()
4626         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4627           chance
4628         * src/avr/main.c,
4629         * src/ds390/main.c,
4630         * src/hc08/main.c,
4631         * src/mcs51/main.c,
4632         * src/pic/main.c,
4633         * src/pic16/main.c,
4634         * src/xa51/main.c,
4635         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4636           added PSEG (PAG,XDATA) or NULL to port specifier
4637         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4638         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4639           (_mcs51_genInitStartup): removed __start__xstack equ,
4640           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4641         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4642         * src/z80/gen.c (_rleAppend): fixed warnings
4643         * support/regression/tests/zeropad.c: added pdata test
4644         * .version: bumped to 2.4.6
4645
4646 2004-10-17 Borut Razem <borut.razem AT siol.net>
4647
4648         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4649         as a part of nightly build
4650
4651 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4652
4653         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4654         WREG holds the first byte function parameters,
4655         * (aopForSym): take special case for symbols which are in FARSPACE
4656         but in CODESPACE too,
4657         * (assignResultValue): modified to take into account _G.useWreg,
4658         * (genCall): don't use wreg for parameter passing when function is
4659         declared as reentrant, too, added optimization INCF to stack
4660         pointer when stack parameter count is 1,
4661         * (genFunction, genEndFunction): refurnished and fixed to not using
4662         wreg for passing parameters when function has varargs or is
4663         reentrant, fixed bug with symbol name compare for generating
4664         functions in absolute address,
4665         * (pic16_storeForReturn): refurnished,
4666         * (genCmp): began writing a new version of the function, not ready
4667         yet, therefore it is disabled,
4668         * (genAssign): do not read code memory when assigning a function to
4669         a pointer function,
4670         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4671         array of characters, not pointer,
4672         * (pic16initialComments): in debug mode emit an .ident directive for
4673         the assembler,
4674         * (_process_pragma): emit a new warning type (internal to pic16)
4675         when setting stack to default length, emit a similar warning when
4676         placing a function at absolute address and address is not word aligned
4677         * (_pic16_parseOptions): added 'return TRUE' statement,
4678         * (_pic16_linkEdit): if compiling a source, then add the source's
4679         file object, first in the list of objects to link,
4680
4681 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4682
4683         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4684         * src/pic/main.c : removed VC warning.
4685         * src/pic/gen.c : changed comment.
4686
4687 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4688
4689         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4690         reference to a deprecated symbol _GPTRREG was causing failure to
4691         link. Thanks G. M. Gallant for the info.
4692
4693 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4694
4695         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4696         comments for Bugs item #954788.
4697
4698 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4699
4700         * src/pic16/device.c (pic16_dump_gsection,
4701         * pic16_groupRegistersInSection): handle symbols declared to be in
4702         access bank differently,
4703         * src/pic16/gen.c (struct _G): added field resDirect,
4704         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4705         send values read from stack directly to result and don't allocate
4706         temporary values,
4707         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4708         same registers,
4709         * (pic16_sameRegsOfs): NEW,
4710         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4711         free because they were not allocated from temporary pool,
4712         * pic16_popRegFromString): workaround to fix a problem with
4713         allocating variables twice or never,
4714         * (genGenPointerGet): using PRODL instead of FSR0H,
4715         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4716         instead of FSR0H,
4717         * (genAssign): take advantage of the _G.resDirect flag,
4718         * (genCast): around line 11844, use mov2f instead of directly
4719         MOVFF'ing between operands to account for literal values,
4720         * src/pic16/genutils.c: some new debug functions for gpsim have been
4721         added,
4722         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4723         float with integer part only,
4724         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4725         place variables in access bank
4726         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4727         updated sources to reflect recent changes in gen.c
4728
4729 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4730
4731         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4732         sources that searched for headers in installation path, now the
4733         device/include/pic16 is used,
4734         * src/pic16/glue.c (pic16glue),
4735         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4736         .line directives if not in debug mode, this suppresses assembler's
4737         warnings for ignored directives
4738
4739 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4740
4741         * src/port.h: made reset_regparms prototype void parameter explicit.
4742         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4743         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4744         * doc/sdccman.lyx: documented warning disabling and how to use
4745           printf_large to make it print floats.
4746         * device/include/stdbool.h: NEW
4747         * device/lib/_atof.c,
4748         * device/lib/_divuint.c,
4749         * device/lib/_divulong.c,
4750         * device/lib/expf.c,
4751         * device/lib/printf_large.c,
4752         * device/lib/sincosf.c,
4753         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4754         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4755           a completely reentrant lib.
4756
4757 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4758
4759         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4760         * device/include/pic16/stdio.h: fixed bug with colon
4761
4762 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4763
4764         * device/include/pic16/stdio.h,
4765         * device/include/pic16/stdlib.h,
4766         * device/include/pic16/math.h: NEW
4767         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4768         declared as _naked to reduce overhead
4769         * device/lib/Makefile.in (target port-specific-objects-pic16):
4770         changed * to *.* so to ignore the CVS directory,
4771         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4772         stacked variables back in stack,
4773         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4774         corruption
4775
4776 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4777
4778         * .version: bumped version number to 2.4.5
4779         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4780         * support/Util/SDCCerr.c (messages structure): added entry for
4781         W_POSSBUG2
4782
4783         Large cumulative patch for pic16 port and libraries.
4784         * device/include/pic16/sdcc-lib.h,
4785         * device/include/pic16/stdarg.h,
4786         * device/include/asm/pic16/features.h,
4787         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4788         * device/include/pic16/float.h: changes reentrant keyword with
4789         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4790         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4791         updated target build-libraries to include objects from gptr,
4792         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4793         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4794         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4795         all function headings,
4796         * src/SDCCmain.c: added global parameter userIncDirsSet,
4797         * (parseCmdLine): when option -I is encountered add directory to
4798         userIncDirsSet too,
4799         * src/version.awk: added space between control and long,
4800         * src/pic16/NOTES: added some notes for the port,
4801         * src/pic16/gen.c: added prototype for mov2fp function,
4802         * (fReturnpic16[]): properly named return value registers,
4803         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4804         * (aopForSym): added code to handle symbols with onStack flag set,
4805         symbols onStack are allocated PTRSIZE bytes,
4806         * (aopFreeAsmop): handles special case where asmops are stack objects,
4807         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4808         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4809         added argument lock to trace flaws in allocating temporary registers
4810         when developing port,
4811         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4812         * (pic16_popRegFromString): reenabled allocating a direct register
4813         from string,
4814         * (assignResultValue): various beautifications,
4815         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4816         referenced function argument,
4817         * (genIpush): reenabled to allow stacked arguments, handles only
4818         ic->parmPush iCodes,
4819         * (genCall, genPcall): major changes to allow for variable argument
4820         functions, fixed a bug with falsely restoring stack pointer after
4821         returning from call,
4822         * (genFunction): pending code for critical function,
4823         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4824         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4825         * (genNearPointerGet): fixed bug with indirect reading, was always
4826         reading from INDF0
4827         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4828         pointers,
4829         * (genAddrOf): rewrote code to take address of a stacked function parameter
4830         * (genCast): fixed casting to generic pointer type,
4831         * src/pic16/gen.h: added AOP_STA,
4832         * (struct asmop): added field stk,
4833         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
4834         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
4835         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
4836         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
4837         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
4838         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
4839         generic pointers,
4840         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
4841         and library paths,
4842         * (pic16_port structure): generic pointer size is set to 3,
4843         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
4844         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
4845         compiler warning,
4846         * src/pic16/ralloc.c (allocReg): prevent allocating register when
4847         operand is an iTemp,
4848
4849 2004-09-24 Martin Helmling <mh AT octo-soft.de>
4850
4851         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
4852         * debugger/mcs51/simi.c: addapt new syntax of s51
4853
4854 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
4855
4856         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
4857         * src/pic16/pcode.c: commented out some calls to free() in order to
4858         fix bug #989576,
4859
4860 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4861
4862         * src/SDCCicode.h,
4863         * src/SDCCicode.c (isiCodeInFunctionCall),
4864         * src/avr/ralloc.c (selectSpil),
4865         * src/pic/ralloc.c (selectSpil),
4866         * src/pic16/ralloc.c (selectSpil),
4867         * src/ds390/ralloc.c (selectSpil),
4868         * src/hc08/ralloc.c (selectSpil),
4869         * src/xa51/ralloc.c (selectSpil),
4870         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
4871         stack in the middle of a function call sequence (fixes bug #1020268)
4872         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
4873         costs associated with the minimum switch case.
4874
4875 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4876
4877         * src/SDCC.lex: fixed bug #1030549
4878
4879 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4880
4881         * src/SDCCcse.h (struct cseDef),
4882         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
4883         over a function call if the CSE is derived from a symbol whose
4884         address has been taken (fixes bug #1029883)
4885         * support/regression/tests/bug-1029883: a new regression test for
4886         this bug
4887
4888 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4889
4890         * src/hc08/gen.c (emitinline): fixed bug #1029778
4891         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
4892         to a cast object is no longer a syntax error ("fixes" bug #1030006,
4893         and starts toward RFE #905167)
4894
4895 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
4896
4897         * src/pic16/gen.c (mov2f): New function to move an operand to
4898         another without considering if it is a literal or a register,
4899         * (pic16_sameRegs): don't check if they are both AOP_REG,
4900         * (AccRsh): removed andmask=0 lines,
4901         * (genLeftShift): duplicated to be improved in future versions,
4902         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
4903         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
4904         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
4905         * (pic16initMnemonics): added initialization for POC_INFSNZW,
4906         * (insertBankSwitch): fixed inserting banksel directives algorithm
4907         for instructions that follow a skip instruction, this fixes a report
4908         for broken subtraction code generation,
4909         * src/pic16/ralloc.c (deassignLRs): do not free register if current
4910         iCode is a left op, just in case result and right share the same
4911         registers
4912
4913 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4914
4915         * src/hc08/main.c,
4916         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
4917         preservation of HX
4918         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
4919         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
4920         on 2004-09-12; it was buggy
4921
4922 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
4923
4924         * src/SDCCsymt.h: removed RESULT_CHECK
4925         * src/SDCCast.c,
4926         * src/SDCCglue.c,
4927         * src/SDCCval.c,
4928         * src/pic/glue.c,
4929         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
4930
4931 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
4932
4933         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
4934         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
4935         configuration values no more rejected by compiler, they are assigned
4936         to configuration registers with a warning message instead,
4937         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
4938         the for-loop so last conf register is emitted too,
4939         * (_pic16_initPaths): link library libsdcc.lib by default,
4940         * (_hasNativeMulFor): modified test for multiplication according to
4941         Raphael Neider's remarks. Integer multiplication is also done with
4942         support functions,
4943         * device/include/pic16/pic18fregs.h: corrected type error in while
4944         testing and including 18f6720 header file
4945
4946 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
4947
4948         * src/pic16/device.h (pic16_options): removed field use_crt,
4949         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
4950         until an optimization to handle single bits is added,
4951         * (pic16_loadFSR0): moved before genUnpackBits,
4952         * (genAnd): some white lines removed,
4953         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
4954         leave_reset flags in pic16_options when using crt modules,
4955
4956 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
4957
4958         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
4959           for bugs 898889 & 979599. Also used some safer print instructions.
4960
4961 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
4962
4963         * src/pic16/device.h (pic16_options_t): added field use_crt,
4964         crt_name, no_crt,
4965         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
4966         catch a probable future bug,
4967         * src/pic16/gen.c: aopIdx function commented out,
4968         * (genAssign): commented out old code which used aopIdx,
4969         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
4970         code, added if conditionals to take into account the --use-crt
4971         command line options,
4972         * src/pic16/main.c (pic16_optionsTable): added new command line
4973         options, --use-crt= and --no-crt,
4974         * (_pic16_linkEdit): now the proper crt object is added in the
4975         linker command line except than when --no-crt is specified,
4976         * src/pic16/pcode.c,
4977         * src/pic16/pcode.h: added some structures and functions for a new
4978         optimization scheme to compansate for instruction overhead between
4979         same iCodes, this scheme is currently under development and is not
4980         working in any way,
4981         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
4982         to && operator,
4983         * device/lib/pic16/startup/crt0i.c,
4984         * device/lib/pic16/startup/crt0iz.c: added global char variable
4985         __uflags to force the generation of an idata section
4986
4987 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
4988
4989         * doc/Makefile,
4990         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
4991         * doc/sdccman.lyx: updated sdcc version to 2.4.4
4992
4993 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4994
4995         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
4996         Frieder) and clarified the default code optimization mode
4997
4998 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4999
5000         * src/SDCC.lex (doPragma, process_pragma),
5001         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
5002         "opt_code_size", and "opt_code_balanced"
5003         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
5004         regrouped options by category, added support for category headers
5005         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
5006         and "--opt-code-size"
5007         * doc/sdccman.lyx: documented these new options and pragmas
5008         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
5009         preference into account
5010
5011 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5012
5013         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
5014           geniCodePreDec): Fixed bug 904237 by generating a warning
5015         * src/SDCCerr.h,
5016         * src/SDCCerr.c: added warning W_SIZEOF_VOID
5017
5018 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
5019
5020         * src/pic/device.c : When no max ram set validate full memory range.
5021         * src/pic/pcode.c,
5022         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
5023
5024 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5025
5026         * device/lib/_gptrget.c,
5027         * device/lib/_gptrput.c: updated comment
5028         * device/lib/calloc.c,
5029         * device/lib/free.c,
5030         * device/lib/malloc.c,
5031         * device/lib/realloc.c: added LGPL, made them reentrant-safe
5032         * src/SDCCcse.c (cseBBlock),
5033         * src/SDCCicode.c (printOperand, geniCodeArray),
5034         * src/SDCCicode.h (struct operand): fixed bug 868103
5035         * support/regression/tests/bug-868103.c: added
5036         * src/SDCCast.c (searchLitOp),
5037         * src/SDCCcse.h (struct cseDef),
5038         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
5039         * src/SDCCicode.h (struct operand),
5040         * src/SDCCsymt.h (struct sym_link),
5041         * src/avr/gen.c (hasInc),
5042         * src/ds390/gen.c (hasInc),
5043         * src/hc08/gen.c (genPlusIncr, hasInc),
5044         * src/mcs51/gen.c (hasInc),
5045         * src/pic16/glue.c (pic16_printIvalChar),
5046         * src/pic16/ralloc.c (regWithIdx),
5047         * src/xa51/gen.c (hasInc) : removed warnings
5048         * src/SDCCast.c (createBlock): added comment ???
5049         * src/hc08/ralloc.c: updated comments
5050
5051 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5052
5053         * doc/sdccman.lyx: updated section on switch statements, added
5054         section about semaphore locking
5055         * doc/Makefile: added option -info for latex2html
5056         * device/lib/_gptrget.c,
5057         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
5058
5059 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5060
5061         * src/pic/device.h,
5062         * src/pic/device.c,
5063         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
5064          maxram is less than 0x100.
5065
5066 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5067
5068         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
5069
5070 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5071
5072         * src/port.h,
5073         * src/mcs51/main.c,
5074         * src/ds390/main.c,
5075         * src/z80/main.c,
5076         * src/hc08/main.c,
5077         * src/pic/main.c,
5078         * src/pic16/main.c,
5079         * src/avr/main.c,
5080         * src/xa51/main.c
5081         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
5082         a jump table is the best form for a switch statement, including
5083         automatic insertion of missing cases to make the case range
5084         continuous. Developed in collaboration with Frieder Ferlemann.
5085
5086 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5087
5088         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
5089         accumulator result if it needs sign extension
5090
5091 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5092
5093         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
5094
5095 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5096
5097         * device/lib/gbz80/printf.c,
5098         * device/lib/z80/printf.c: removed define for NULL
5099
5100 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5101
5102         * as/xa51/xa_link.c,
5103         * device/examples/ds390/ow390/ad26.c,
5104         * device/examples/ds390/ow390/cnt1d.c,
5105         * device/examples/ds390/ow390/counter.c,
5106         * device/examples/ds390/ow390/ds2480.h,
5107         * device/examples/ds390/ow390/ds2480ut.c,
5108         * device/examples/ds390/ow390/findtype.c,
5109         * device/examples/ds390/ow390/gethumd.c,
5110         * device/examples/ds390/ow390/owllu.c,
5111         * device/examples/ds390/ow390/ownetu.c,
5112         * device/examples/ds390/ow390/swt12.c,
5113         * device/examples/ds390/ow390/swtloop.c,
5114         * device/examples/ds390/ow390/temp.c,
5115         * device/examples/ds390/ow390/temp10.c,
5116         * device/examples/ds390/ow390/thermo21.c,
5117         * device/examples/ds390/ow390/tinilnk.c,
5118         * device/examples/ds390/ow390/tstfind.c,
5119         * device/examples/serialcomm/windows/serial.cpp,
5120         * device/examples/serialcomm/windows/test_serialcomm.cpp,
5121         * device/include/reg51.h: fixed line endings for cvs
5122
5123 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5124
5125         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
5126         packRegsForAccUse, packRegisters): new accumulator register
5127         packing algorithm
5128         * support/regression/ports/hc08/support.c (_putchar): suppress
5129         warning of unused variable
5130         * src/SDCCicode.c: added SWAP entry to codeTable
5131
5132 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
5133
5134         * device/lib/sprintf.c: forgot to add this file before previous commit
5135
5136 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
5137
5138         * src/pic16/gen.c (genPackBits): added operand right in function
5139         parameters, load result directly if p_type is POINTER (that is
5140         called by genNearPointerSet)
5141         * (genUnPackBits): added operand left in function parameters,
5142         * (genNearPointerGet, genNearPointerSet): prevent the loading of
5143         FSR0 if accessing bitfields,
5144
5145 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
5146
5147         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
5148           _print_format; updated printf, sprintf, vsprintf
5149         * device/include/asm/default/features.h: corrected comment/define
5150         * device/lib/Makefile.in: added sprintf.c
5151         * device/lib/libsdcc.lib: added sprintf module
5152         * device/lib/printf_large.c,
5153         * device/lib/vprintf.c,
5154         * device/lib/sprintf.c: totally refactored printf_large and vprintf
5155           into these 3 files
5156         * support/regression/Makefile: changed ALL_PORTS into a usefull default
5157         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
5158         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
5159           hc08 test
5160         * support/regression/tests/zeropad.c: define idata as data for hc08
5161
5162 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5163
5164         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
5165         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
5166         labels are referenced at least once (even if a reference is not found)
5167         * src/hc08/gen.c (emitcode): set isComment flag for comments
5168         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
5169         loads), rules 6a..6b (optimize jumps to return)
5170
5171 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5172
5173         * device/lib/acosf.c (acosf),
5174         * device/lib/asinf.c (asinf),
5175         * device/lib/atanf.c (atanf),
5176         * device/lib/ceilf.c (ceilf),
5177         * device/lib/cosf.c (cosf),
5178         * device/lib/coshf.c (coshf),
5179         * device/lib/cotf.c (cotf),
5180         * device/lib/fabsf.c (fabsf),
5181         * device/lib/floorf.c (floorf),
5182         * device/lib/log10f.c (log10f),
5183         * device/lib/logf.c (logf),
5184         * device/lib/sinf.c (sinf),
5185         * device/lib/sinhf.c (sinhf),
5186         * device/lib/sqrtf.c (sqrtf),
5187         * device/lib/tanf.c (tanf),
5188         * device/lib/tanhf.c (tanhf),
5189         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
5190         replaced all instances of "reentrant" in the library functions
5191         defined in math.h with this macro.
5192         * support/regression/tests/float_trans.c: reenabled test for hc08
5193
5194 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
5195
5196         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
5197         erroneously deleted
5198
5199 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5200
5201         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
5202         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
5203         multi-byte volatile operands are used
5204         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
5205         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
5206         initialization to area GSINIT0 so that it would always precede
5207         any static initializers in GSINIT
5208         * support/regression/tests/zeropad.c: fixed idata define for hc08
5209         * support/regression/tests/bug-927659.c,
5210         * support/regression/tests/float_trans.c: disabled tests for hc08
5211         pending missing library routines
5212         * .version: increased version number to 2.4.4 - hc08 port now passes
5213         regression tests
5214
5215
5216 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
5217
5218         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
5219         * Makefile.common.in,
5220         * as/Makefile,
5221         * as/hc08/Makefile.in,
5222         * as/mcs51/Makefile.in,
5223         * as/z80/Makefile.in,
5224         * debugger/mcs51/Makefile.in,
5225         * device/include/Makefile.in,
5226         * device/lib/Makefile.in,
5227         * doc/Makefile,
5228         * link/Makefile,
5229         * link/z80/Makefile.in,
5230         * packihx/Makefile.in,
5231         * sim/ucsim/main_in.mk,
5232         * sim/ucsim/avr.src/Makefile.in,
5233         * sim/ucsim/doc/Makefile.in,
5234         * sim/ucsim/gui.src/serio.src/Makefile.in,
5235         * sim/ucsim/hc08.src/Makefile.in,
5236         * sim/ucsim/s51.src/Makefile.in,
5237         * sim/ucsim/xa.src/Makefile.in,
5238         * sim/ucsim/z80.src/Makefile.in,
5239         * src/Makefile.in,
5240         * support/cpp2/Makefile.in,
5241         * support/librarian/Makefile,
5242         * support/makebin/Makefile: added DESTDIR to the install path proposed
5243         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
5244         * doc/sdccman.lyx: added DESTDIR documentation
5245
5246 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
5247
5248         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
5249         instruction for interrupt handlers, use fast returns when returning
5250         from high priority interrupts
5251
5252 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5253
5254         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
5255         code generation
5256         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
5257         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
5258         bugs, ported much of Bernhard's code from mcs51
5259         * src/mcs51/gen.c (genSend),
5260         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
5261         than one when calling a reentrant function
5262         * device/lib/_mullong.c: defined an alternate struct layout for big
5263         endian ports (hc08)
5264
5265 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5266
5267         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
5268         test
5269
5270 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5271
5272         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
5273         are sane and complete before asking the port its prefered parameter
5274         passing method (fixes bug #1017633)
5275         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
5276         and _ret3
5277
5278 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5279
5280         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
5281         problem in bitfields >= 8 bits.
5282
5283 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5284
5285         * src/SDCCsymt.c: undid changes that were not meant to be committed
5286
5287 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5288
5289         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
5290
5291 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5292
5293         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
5294           copied and wrong bit got inverted
5295
5296 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5297
5298         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5299         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5300         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5301         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5302         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5303         assignments to bitfields at known addresses
5304         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5305         reads from bitfields at known addresses
5306         * src/hc08/ralloc.c (packRegisters),
5307         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5308         genhc08Code): optimize pointer get values used as conditionals
5309         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5310         and branch
5311
5312 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5313
5314         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5315         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5316         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5317         as conditionals
5318
5319 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5320
5321         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5322
5323 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5324
5325         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5326         related problems
5327
5328 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5329
5330         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5331
5332 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5333
5334         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5335         mcs51 port
5336
5337 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5338
5339         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5340
5341 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5342
5343         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5344         cases use more compact code.
5345
5346 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5347
5348         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5349
5350 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5351
5352         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5353
5354 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5355
5356         * src/SDCCsymt.h,
5357         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5358         parameter of changePointer() from symbol* to sym_link*
5359         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5360         * src/SDCCsymt.c (compareType): void* type is castable to other
5361         pointers, but not necesarily an exact match.
5362         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5363         is no longer blindly treated as an exact match.
5364         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5365
5366 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5367
5368         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5369
5370 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5371
5372         * src/pic/gen.c,
5373         * src/pic/pcode.c,
5374         * src/pic/ralloc.h,
5375         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5376
5377 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5378
5379         * src/pic/device.c,
5380         * src/pic/device.h,
5381         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5382
5383 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5384
5385         * src/mcs51/gen.c (emitcode): fixed bug #992819
5386
5387 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5388
5389         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5390           there's no need to make it worse
5391
5392 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5393
5394         * src/mcs51/ralloc.c (deassignLR),
5395         * src/ds390/ralloc.c (deassignLR),
5396         * src/hc08/ralloc.c (deassignLR),
5397         * src/z80/ralloc.c (deassignLR),
5398         * src/pic/ralloc.c (deassignLR),
5399         * src/pic16/ralloc.c (deassignLR),
5400         * src/avr/ralloc.c (deassignLR),
5401         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5402         rlivePoint): fixed another part of bug #971834
5403
5404 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5405
5406         * src/z80/main.c: enabled "critical" keyword
5407         * src/z80/mappings.i,
5408         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5409         functions (fixes bug #979646)
5410         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5411
5412 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5413
5414         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5415           such as c:\mydir.
5416
5417 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5418
5419         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5420           doesn't disable too much optimizations
5421
5422 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5423
5424         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5425
5426 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5427
5428         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5429
5430 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5431
5432         * src/pic/gen.c tidied up tabs
5433         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5434         * src/pic/main.c tidied up tabs
5435         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5436         * src/pic/pcoderegs.c tidied up tabs
5437         * src/pic/ralloc.c tidied up tabs
5438
5439 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5440
5441         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5442         to S_FIXED for pic16 port and when symbol is not in level 0,
5443         allocate for S_REGISTER storage class and pic16 port, too,
5444         * src/pic16/device.h: prototype for checkSym,
5445         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5446         * (pic16_assignConfigWordValue): test the value and the mask to
5447         validate that the value is suitable for the configuration word,
5448         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5449         collect extern declared symbols, don't emit symbol twice, check
5450         first if symbol is in publics set first,
5451         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5452         * added command line '--fstack' which enables an experimental
5453         feature for stack access, too buggy to be used yet...
5454         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5455         * (pic16_allocDirReg): when register has storage class S_REGISTER
5456         allocate in pic16_dynAccessRegs,
5457         * device/include/pic16/pic18f????.h: modified configuration word
5458         naming convention, words started as CONFIG0H but should be CONFIG1H
5459
5460 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5461
5462         * device/include/mcs51reg.h: fixed bug 970993
5463
5464 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5465
5466         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5467         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5468         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5469         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5470         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5471         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5472           error/warning numbers,
5473           added function setWarningDisabled()
5474         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5475         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5476           _memcmp.c _memmove.c calloc.c realloc.c free.c
5477         * support/regression/tests/malloc.c: added tests for new functionality
5478         * support/regression/tests/zeropad.c: added tests for truncated initializers
5479           and initialized char arrays starting with '\x0'
5480         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5481
5482 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5483
5484         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5485
5486 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5487
5488         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5489         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5490         peephole 177.e. Thanks to anonymous
5491
5492 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5493
5494         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5495         function isn't used in the source but referenced as a
5496         variable initializer then declare it as extern in .asm file
5497
5498 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5499
5500         * .version: increased version number to 2.4.3
5501
5502         Adding version extension according to ChangeLog CVS revision
5503         * src/Makefile.in (target all): added dependency 'version.h'
5504         * (rule version.h): added rule to create version.h from ChangeLog,
5505         * (rule dep): added dependency version.h,
5506         * src/version.awk: AWK script to create version.h
5507         * src/SDCCdwarf2.c (dwWriteModule),
5508         * src/SDCCglue.c (initialComments),
5509         * src/SDCCmain.c (printVersionInfo): modified to write after
5510         version string the version extension number,
5511         * src/SDCCutil.c: included "version.h"
5512         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5513         number,
5514         * src/SDCCutil.h: added prototype for getBuildNumber
5515
5516         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5517         includeDirsSet, too,
5518         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5519         const char [] is found in function prototype...
5520
5521         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5522         moving to WREG with source is already in WREG,
5523         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5524         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5525         * (aopForSym): stack'ed symbols are partially supported, added
5526         if-clause to support symbols in FARSPACE,
5527         * (sameRegs): added test for AOP_ACC to see if registers are same,
5528         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5529         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5530         * (pic16_popRegFromString): will not allocate a new register if it
5531         doesn't find one by name, bug may have introduced...
5532         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5533         * (genIpush): revived to use pic16 port's stack,
5534         * (genAddrOf): added incomplete case for stack'ed operand,
5535         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5536         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5537         can handle multibyte operands,
5538         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5539         * (pic16initialComments): added message for MPLAB compatibility
5540         mode enabled,
5541         * src/pic16/main.h: prototype for pic16_mplab_comp,
5542         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5543         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5544         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5545         because of increased complexity of procedure,
5546         * (_process_pragma): stack pragma changed to format 'stack pos len',
5547         emit symbol '_stack_end' to conform with gplink,
5548         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5549         to search for register,
5550         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5551         PO_GPR_REGISTER,
5552         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5553         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5554         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5555         case for PO_GPR_REGISTER,
5556         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5557         dies, the new era is ahead !...
5558         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5559         pic16_dynInternalRegs,
5560         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5561         * (pic16_allocDirReg): minor optimizations and bug fixes,
5562         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5563
5564         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5565         load stack and frame pointer with address of 'stack_end' symbol
5566
5567 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5568
5569         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5570         without source code but only variable initializers
5571
5572 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5573
5574         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5575         external are not declared as extern to reduce overhead while linking
5576
5577 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5578
5579         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5580
5581 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5582
5583         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5584           Yee Keat for the patch
5585         * src/SDCCast.c (decorateType): fixed bug #979599
5586         * src/ds390/gen.h: removed local fReturnSizeDS390
5587         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5588         * src/ds390/gen.c (genAnd, genOr, genXor),
5589         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5590
5591 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5592
5593         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5594         add relFilesSet to $3, manipulate $2 to handle linking of object
5595         files without source files in command line,
5596         * device/include/pic16 (all headers): added ID location macros,
5597         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5598         entries for ID location bytes,
5599         * (pic16_assignIdByteValue): NEW,
5600         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5601         added field dumpcalltree to pic16_options_t,
5602         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5603         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5604         emitting rFalseIfx label after check_carry label,
5605         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5606         pic16_emitDIRegs), NEW
5607         * (pic16glue): dump .calltree file when option --calltree found,
5608         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5609         * (_pic16_genAssemblerPreamble): emit ID locations after
5610         configuration registers,
5611         * (pic16_linkCmd): modifications of the link command,
5612         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5613         * (pic16_pCodeInitRegisters): don't init stack registers,
5614         * (pic16_findPrevInstruction): fixed bug,
5615         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5616         bug with immediate registers,
5617         * (buildCallTree): traces stack push and pop,
5618         * (pct2): dump also stack usage for each function,
5619         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5620         * (pic16_allocDirReg): various modifications,
5621         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5622         fixed to 1,
5623
5624 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5625
5626         * src/pic16/pcode.c: removed buggy double colon
5627
5628 2004-07-01 Borut Razem <borut.razem AT siol.net>
5629
5630         * support/scripts/sdcc.nsi: added include/pic16 to setup
5631
5632 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5633
5634         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5635         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5636         target 'clean',
5637         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5638         specific command line arguments. Also added sample lkr script
5639         for placing a variable at a specific memory bank.
5640         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5641         at a specific memory bank,
5642         * (pic16_dump_isection): fixed bug which caused string literals to
5643         be omitted when dumping idata section,
5644         * (pic16_groupRegistersInSection): added code to handle registers
5645         in specific memory banks,
5646         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5647         public, all references are renamed too,
5648         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5649         AOP_DPTR2,
5650         * (pic16_storeForReturn): added case to handle when dest is WREG,
5651         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5652         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5653         pic16_rel_udata, check to see if that register is marked as being
5654         a member of a specific memory bank,
5655         * (pic16_printIvalCharPtr): added code to add string literals either
5656         to code or the idata sections,
5657         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5658         also accept the 'udata' pragma,
5659         * src/pic16/main.h: new structure types sectName and sectSym
5660         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5661         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5662         * (pic16_findPrevInstruction): fixed, it returned nothing,
5663         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5664         instruction combinations,
5665         * (pic16_FixRegisterBanking): heavily reorganised,
5666         * (pic16_AnalyzeBanking): if generating banksel directives is
5667         disabled, then don't call FixRegisterBanking at all,
5668         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5669         completely removed,
5670         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5671
5672 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5673
5674         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5675         Phuah Yee Keat <yk.phuah AT nestac.com>
5676
5677 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5678
5679         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5680         correctly the IVT even if it is relocated to some other location
5681
5682 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5683
5684         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5685         * device/include/pic16/pic18f2220.h: NEW,
5686         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5687         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5688         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5689         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5690         nodefaultlibs, ivt_loc is the location of the interrupt vector
5691         table, and nodefaultlibs signs that default libraries should not be
5692         linked in link stage,
5693         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5694         according to --ivt-loc argument,
5695         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5696         when pragma stack is found,
5697
5698 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5699
5700         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5701         256 (range check), 257 (do while), 258.a-f (bit banging
5702         f.e. on 3-wire SPI bus)
5703
5704 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5705
5706         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5707         variables used exclusively within a loop
5708
5709 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5710
5711         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5712
5713 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5714
5715         * src/SDCClrange.c (computeClash): fixed bug #971834
5716
5717 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5718
5719         * src/mcs51/gen.c (genCmp): fixed bug #975903
5720         * src/hc08/gen.c (operandsEqu),
5721         * src/ds390/gen.c (operandsEqu),
5722         * src/z80/gen.c (operandsEqu),
5723         * src/pic/gen.c (operandsEqu),
5724         * src/pic16/gen.c (operandsEqu),
5725         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5726         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5727
5728 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5729
5730         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5731
5732 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5733
5734         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5735         default case in switch statement,
5736         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5737         to eliminate problem with initialisation of pointers, but problem
5738         still exists,
5739         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5740         * (emitStaticSegment): removed various lines emitting debug info,
5741         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5742         added processor registers for utilizing EEPROM,
5743         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5744         configurable and set 8
5745
5746 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5747
5748         * .version: increased version number to 2.4.2,
5749
5750         Cumulative patch for pic16 port
5751         * src/pic16/device.c: changed scheme to dump initial values for
5752         variables in idata segment, all print_idata* functions were removed,
5753         now the pic16_printIval* will be called,
5754         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5755         * _pic16_printPointerType, pic16_printPointerType,
5756         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5757         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5758         NEW, similar to the respective functions in SDCCglue.c,
5759         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5760         way, emitting hex bytes,
5761         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5762
5763 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5764
5765         * src/avr/ralloc.c (serialRegAssign),
5766         * src/xa51/ralloc.c (serialRegAssign),
5767         * src/pic/ralloc.c (serialRegAssign),
5768         * src/pic16/ralloc.c (serialRegAssign),
5769         * src/hc08/ralloc.c (serialRegAssign),
5770         * src/z80/ralloc.c (serialRegAssign),
5771         * src/ds390/ralloc.c (serialRegAssign),
5772         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5773
5774 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5775
5776         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5777         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5778
5779 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5780
5781         Cumulative patch for pic16 port:
5782         * src/pic16/device.h (typedef PIC16_device) modified fields for
5783         defining microcontrollers,
5784         * src/pic16/device.c: added new info for all devices in Pics16 array,
5785         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5786         to be optimised out by the pCode optimiser,
5787         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5788         specially, bug reported by G.M. Gallant,
5789         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5790         as force'd so that cannot be optimised out by pCode optimiser,
5791         * src/pic16/pcode.c,
5792         * src/pic16/pcodepeeph.c,
5793         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5794         they are disabled by default, but can be enabled explicit with
5795         command argument --denable-peeps, for testing,
5796         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5797         --pomit-ivt in COMPILE_FLAGS
5798
5799 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5800
5801         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5802           compilation on MSVC
5803
5804 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5805
5806         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5807
5808 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5809
5810         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5811         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5812
5813 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5814
5815         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5816         would only assign 0x300001 register.
5817
5818 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5819
5820         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5821         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5822
5823 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5824
5825         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5826         for ds80c400
5827         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5828         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5829         added peephole 254 (left shift), 255 (jump table)
5830
5831 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
5832
5833         * device/lib/Makefile.in: removed comment line with model-pic16,
5834         * (target port-specific-objects-pic16): the libraries and objects
5835         are copied to the build directory form the device/lib/pic16/bin
5836         directory
5837
5838         Cumulative patch concerning pic16 port:
5839         * library directory has been re-organized,
5840         * added support for PIC18F1220,
5841         * added headers and library sources for chips 18f1220,18f6520,
5842         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
5843
5844         * configuration registers setting has changed, now each supported
5845         device has a complete description of the registers it uses,
5846         * all initialisations are moved to idata sections, these section
5847         can be absolute or relocatable,
5848         * fixed initialisation of codespace variables,
5849         * fixed warning about PCLATU and gpsim,
5850         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
5851         * (genAssign): use table reads when assigning from variables in codespace,
5852         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
5853         char/int variables placed in codespace,
5854         * (pic16_emitConfigRegs): NEW, emits a list with configuration
5855         registers set in .asm file, no need for --pomit-config-words anymore,
5856         * (pic16glue): some 8051 legacy segments are commented out
5857         (to be removed completely),
5858         * added support for alternative assembler and linker with --asm=
5859         and --link= command line arguments,
5860         * peepholes are disabled automatically in the port, no need to
5861         specify on command line,
5862         * port supports natively char/int/long multiplication, but converts
5863         all divisions to support functions,
5864         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
5865         to the file set in variable $2,
5866         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
5867         strings in ASCII format and not in hex,
5868         * ralloc.c (serialRegAssign): added a triplet of conditional calls
5869         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
5870         allocate proper register if iCodes aren't temporary,
5871
5872 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
5873
5874         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
5875
5876 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
5877
5878         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
5879         is commented out
5880
5881 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5882
5883         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
5884         computed address is reused
5885         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
5886         multi-byte bitfields
5887
5888 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5889
5890         * src/z80/gen.c: (genArrayInit): must check for pointers too
5891
5892 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
5893
5894         * support/regression/tests/zeropad.c: never meant to commit the
5895           nestedstruct test: removed, added check for GCC version
5896
5897 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
5898
5899         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
5900         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
5901         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
5902           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
5903           bugs 928906 and 954082 half-empty initializers
5904         * src/SDCCsymt.h,
5905         * src/SDCCsymt.c (getAllocSize): added for above fix
5906         * src/z80/gen.c (genArrayInit): fixed bug 741044
5907         * support/regression/tests/zeropad.c: added tests
5908
5909 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
5910
5911         * src/pic16/device.c (pic16_dump_section): corrected bug which
5912         caused some symbols of the libraries to be misplaced
5913
5914 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5915
5916         * src/pic16/glue.c,
5917         * src/pic16/ralloc.h,
5918         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
5919         to fix conflict with pic port
5920
5921 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
5922
5923         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
5924         externs configuration variables,
5925         * src/pic16/ralloc.h,
5926         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
5927         prototype in header, commented out some debug messages
5928
5929 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
5930
5931         * src/pic16/glue.c,
5932         * src/pic16/main.c,
5933         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
5934         for gpasm COFF object generation. Thanks to D. Hawkins for
5935         his patch info
5936
5937 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5938
5939         * src/ds390/main.c,
5940         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
5941         Brock for spotting this)
5942         * src/ds390/gen.c (genEndFunction),
5943         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
5944         interrupt handler and critical. Disable push/pop optimizations when
5945         peephole optimizations disabled.
5946
5947 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5948
5949         Updated pic16 library sources and headers.
5950         * device/lib/pic16/pic18f*/ ,
5951         * device/include/pic16/*.h: modified to handle structured SFR
5952         definitions
5953
5954 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
5955
5956         * src/port.h (PORT structure): added hook initPaths, now each
5957         port can declare its own default search paths,
5958         which can been seen with the --print-search-dirs option,
5959         see pic16 port for example,
5960         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
5961         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
5962         * (doPrintSearchDirs): NEW, replaces in a central manner the
5963         printing of search dirs which was split in set*Paths functions,
5964         * (main): added call to port->initPaths and doPrintSearchDirs,
5965         * src/avr/main.c,
5966         * src/ds390/main.c,
5967         * src/hc08/main.c,
5968         * src/izt/i186.c,
5969         * src/izt/tlcs900h.c,
5970         * src/mcs51/main.c,
5971         * src/pic/main.c,
5972         * src/pic16/main.c: modified port structures to reflect addition of
5973         initPaths hook,
5974
5975         * src/pic16/device.c (regCompare): registers are finally sorted by name,
5976         * (pic16_dump_section): for registers in same address reserve memory once,
5977         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
5978         to no_banksel,
5979         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
5980         result is greater in size than right or left,
5981         * (pic16_genUMult8X8_8): there are some cases where the result can
5982         be 16 bits size, so handle these,
5983         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
5984         * (pic16_outBitC): modified to emit pcodes,
5985         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
5986         or not,
5987         * (genDivOneByte): implemented algorithm to divide 8-bits,
5988         * (genCmp): uncommented goto, but issues still exist,
5989         * (genAnd): fixed a bug with variables >8bits,
5990         * (genPackBits): optimization added that uses BCF/BSF to change a
5991         single bit,
5992         * (genAssign): fixed bug when assigning floating point literals,
5993         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
5994         __sdcc_gsinit_startup label,
5995         * src/pic16/main.c (_pic16_init): removed search directory
5996         initialisations,
5997         * (_pic16_initPaths): NEW, used to initialise search directories,
5998         * (_hasNativeMulFor): support functions for all except char/int
5999         multiplication, and char division,
6000         * (PIC16_port struct): modified entry for native mul support,
6001         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
6002         no_banksel option,
6003         * (buildCallTree): call to register_usage is ifdef'ed out,
6004
6005 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6006
6007         * device/include/string.h: applied Stas Sergeev's patch to make this
6008         header file compatible with the preprocessor -Wundef option
6009         * src/SDCCmain.c (main): abort compilation if preprocessor reports
6010         failure (fixes bug #941458)
6011
6012 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6013
6014         * src/SDCCopt.c (killDeadCode): fixed bug #907733
6015         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
6016         that the variable, not the function, should be static
6017         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
6018         to be consistent with non-literal case
6019
6020 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6021
6022         * src/SDCCast.c (isConformingBody): fixed bug #949967
6023         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
6024         convilong): fixed bug #952086
6025
6026 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6027
6028         * src/SDCCmem.c (allocVariables): fixed bug #955321
6029
6030 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6031
6032         * src/hc08/main.c (_hc08_genAssemblerEnd),
6033         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
6034         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
6035         completely eliminated the use of a temporary file
6036         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
6037         when more than one file linked
6038         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
6039
6040 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6041
6042         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
6043         which fixes bug #543481
6044         * support/regression/tests/bug-751703.c: fixed comments left from a
6045         cut and paste error
6046         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
6047         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
6048         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
6049         scopes
6050         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
6051         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
6052         are now changed to underscores in moduleName
6053
6054 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6055
6056         * as/mcs51/lkmem.c: better fix for bug #954173
6057
6058 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
6059         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6060
6061         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
6062         * device/include/c8051f000.h,
6063         * device/include/c8051f120.h,
6064         * device/include/c8051f300.h,
6065         * device/include/c8051f310.h,
6066         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
6067         PWM16) and detab'ed
6068
6069 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6070
6071         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
6072         and mailing lists, doc'ed --no-peep-comments, removed reference
6073         to knoppix (newest version has no LyX/LaTeX), other minor changes
6074         * src/SDCCglue.c (glue): save 2 bytes stack space with
6075         option --main-return. The ljmp could probably be avoided too
6076
6077 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6078
6079         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
6080
6081 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6082
6083         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
6084         * src/SDCCopt.c (isLocalWithoutDef),
6085         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
6086         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
6087         (credit to Maarten Brock for patch #949363, on which this is based)
6088         * support/regression/tests/bug-751703.c: some test cases of extern used
6089         within inner scopes.
6090
6091 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6092
6093         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
6094         SPEC_STRUCT
6095         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
6096         struct definitions
6097         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
6098         dwWriteLabel): fix to create valid debugger symbols even when
6099         the module name has non-alphanumeric symbols in it
6100         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
6101         when a variable's allocation has been optimized away
6102
6103
6104 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6105
6106         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
6107         * src/hc08/main.c,
6108         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
6109         * src/mcs51/main.c,
6110         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
6111         * src/ds390/main.c,
6112         * src/z80/gen.c (z80_emitDebuggerSymbol),
6113         * src/z80/main.c,
6114         * src/pic/gen.c (pic14_emitDebuggerSymbol),
6115         * src/pic/main.c,
6116         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
6117         * src/pic16/main.c,
6118         * src/avr/gen.c (avr_emitDebuggerSymbol),
6119         * src/avr/main.c,
6120         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
6121         * src/xa51/main.c,
6122         * src/SDCCdebug.c (emitDebuggerSymbol),
6123         * src/SDCCdebug.h,
6124         * src/port.h: added a debugger struct to the port struct. Added a
6125         callback for defining debugger symbols
6126
6127         * src/SDCCast.c (createLabel),
6128         * src/SDCC.y (labeled_statement): mark all compiler generated labels
6129         with isitmp = 1
6130         * src/SDCCicode.h,
6131         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
6132         iCode back to the ast for the function
6133
6134         * src/hc08/ralloc.c (hc08_assignRegisters),
6135         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
6136         unneeded fields from the regs struct.
6137         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
6138         pushReg() & pullReg() functions instead of emitcode()
6139
6140         * src/hc08/gen.c (genLabel, genhc08Code),
6141         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
6142
6143         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
6144         debugger hooks
6145
6146         * src/hc08/gen.c (genEndFunction, genhc08Code),
6147         * src/hc08/gen.h,
6148         * src/mcs51/gen.c (genEndFunction, gen51Code),
6149         * src/mcs51/gen.h,
6150         * src/ds390/gen.c (genEndFunction, gen390Code),
6151         * src/ds390/gen.h,
6152         * src/z80/gen.c (genEndFunction, genZ80Code),
6153         * src/z80/gen.h,
6154         * src/z80/z80.h,
6155         * src/pic/gen.c (genEndFunction, genpic14Code),
6156         * src/pic/gen.h,
6157         * src/pic16/gen.c (genEndFunction, genpic16Code),
6158         * src/pic16/gen.h,
6159         * src/avr/gen.c (genEndFunction, genAVRCode),
6160         * src/avr/gen.h,
6161         * src/xa51/gen.c (genEndFunction, genXA51Code),
6162         * src/xa51/gen.h,
6163         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
6164         specific code to cdbFile.c and out of the backend code generators
6165
6166         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
6167         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
6168         starting address is now 0
6169
6170         * as/hc08/asm.h,
6171         * as/hc08/m08pst.c,
6172         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
6173         assembler directive for DWARF support
6174         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
6175
6176         * src/src.dsp,
6177         * src/Makefile.in,
6178         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
6179
6180 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6181
6182         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
6183         and inappropriate peephole optimization in jump tables
6184
6185 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6186
6187         * as/hc08/m08pst.c,
6188         * src/SDCCglue.c: sdccopt works for the hc08 port now
6189
6190 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
6191
6192         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
6193
6194 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6195
6196         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
6197
6198 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6199
6200         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
6201         rules
6202         * src/SDCCmain.c,
6203         * src/SDCCglobl.h,
6204         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
6205         comments from the peephole optimizer replacement rules
6206         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
6207         symbols
6208         * src/SDCCcse.c (updateSpillLocation),
6209         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
6210         equivalents
6211         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
6212         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
6213         objects far pointers
6214
6215 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6216
6217         * src/SDCCsymt.h: a missing part of my last change
6218         * src/pic/ralloc.c (regTypeNum),
6219         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
6220
6221 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6222
6223         * src/SDCCicode.h,
6224         * src/SDCCicode.c (aggrToPtrDclType),
6225         * src/SDCCptropt.h,
6226         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
6227         ptrPseudoSymConvert),
6228         * src/pic/ralloc.c (regTypeNum),
6229         * src/pic16/ralloc.c (regTypeNum),
6230         * src/hc08/ralloc.c (regTypeNum),
6231         * src/ds390/ralloc.c (regTypeNum),
6232         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
6233         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
6234
6235 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6236
6237         * link/z80/lkmain.c (afile),
6238         * as/hc08/lkmain.c (afile),
6239         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
6240         prevent a pointer problem when a filename has no directory and
6241         no extension specified.
6242
6243 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6244
6245         * link/z80/lkmain.c (afile): allow periods in directory names
6246         * link/z80/lkmain.c (afile),
6247         * as/mcs51/lkmain.c (afile),
6248         * as/hc08/lkmain.c (afile): allow linker script file to have an
6249         extension other than ".lnk"
6250         * link/z80/lklex.c (getfid),
6251         * link/z80/lkmain.c (parse),
6252         * as/mcs51/lklex.c (getfid),
6253         * as/mcs51/lkmain.c (parse),
6254         * as/hc08/lklex.c (getfid),
6255         * as/hc08/lkmain.c (parse): Support comments in the linker script
6256         file on lines by themselves and after filenames
6257
6258 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6259
6260         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
6261
6262 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6263
6264         * src/z80/peeph-z80.def: removed some peephole rules that don't
6265         work with multibyte arithmetic (fixed bug #937126)
6266         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
6267         to registers and not global variables
6268         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
6269         geniCodePreInc, geniCodePostDec, geniCodePreDec,
6270         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
6271         checking for assignments not internally generated (fixed bug #931895)
6272         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
6273         structure member (fixed bug #930072)
6274
6275 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6276
6277         * src/SDCCmain.c (linkEdit),
6278         * src/hc08/main.c (_hc08_parseOptions),
6279         * as/hc08/Makefile.in,
6280         * as/hc08/aslink.h,
6281         * as/hc08/asm.h,
6282         * as/hc08/m08pst.c,
6283         * as/hc08/lkrloc.c (relr, rele),
6284         * as/hc08/lkarea.c (lnkarea)
6285         * as/hc08/lkmain.c (afile, parse),
6286         * as/hc08/lkelf.c: support for ELF output
6287         * as/hc08/lks19.c (s19),
6288         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
6289
6290 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6291
6292         * as/mcs51/lkihx.c: Fixed bug #899105.
6293
6294 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6295
6296         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6297         .dsp files from Unix to DOS.
6298
6299 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6300
6301         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6302         function pointers; we have been compliant for several months now.
6303         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6304         change that was accidently commented out
6305         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6306         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6307         bug #922319
6308
6309 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6310
6311         * src/hc08/gen.c: output of all of the internal debugging information
6312         is now controlled by the D() macro; it is disabled by default
6313
6314 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6315
6316         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6317         harder to keep the same registers during a CAST iCode
6318         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6319         long via int can be done in a single cast, if the signedness is
6320         correct.
6321         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6322         putchar() in tinibios.c in ds390's library
6323
6324 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6325
6326         * src/SDCCast.c (decorateType): fixed bug #898889,
6327         cast result of a literal complement too
6328         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6329         fixed check for bitfields
6330
6331 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6332
6333         * src/SDCCicode.c (geniCodeLogic): made it static,
6334         (geniCodeLogicAndOr): added in order to fix bug #905492,
6335         (ast2iCode): fixed bug #905492
6336         * support/regression/tests/bug-905492.c: added
6337         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6338         (processParms): fixed bug #927659: don't copy parms, this will clear
6339         decorated flag
6340         * support/regression/tests/bug-927659.c: added
6341
6342 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6343
6344         * src/SDCCast.c (addCast): don't cast float to char
6345         * device/lib/libsdcc.lib: added _memmove
6346
6347 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6348
6349         * device/lib/large/Makefile: fixed parallel execution by
6350         replacing `make` by `$(MAKE)`
6351
6352 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6353
6354         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6355         offsets (fixes bug #923936)
6356
6357 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6358
6359         * device/lib/small/Makefile: fixed parallel execution by
6360         replacing `make` by `$(MAKE)`
6361
6362 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6363
6364         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6365
6366 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6367
6368         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6369         * src/regression/Makefile: Regression test was not running.
6370
6371 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6372
6373         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6374         complement if possible
6375         * src/SDCCval.c (valComplement),
6376         * src/SDCCicode.c (operandOperation): fixed complement of literal
6377         * support/regression/tests/onebyte.c (testComplement): added
6378
6379 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6380
6381         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6382         return an optimized tree; actually replace actParm with the new tree
6383         * src/SDCCast.h: added some parantheses to remove side effects
6384         * support/regression/tests/bug-920866.c
6385
6386 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6387         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6388         Bit operands were not being handled properly in the pic14 port.
6389         (now src/regression/add.c passes again).
6390
6391 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6392
6393         * src/SDCC.y (labeled_statement): case and default no longer require
6394         a following statement (RFE #893037)
6395
6396 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6397
6398         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6399         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6400         disabled (fixes bug #916294)
6401         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6402         "mov a,acc"; patch provided by Lenny Story
6403         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6404
6405 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6406
6407         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6408         functions
6409         * src/ds390/gen.c (genFunction, genEndFunction),
6410         * src/ds390/ralloc.c (ds390_assignRegisters),
6411         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6412         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6413         pushed if there are parameters passed on the stack. Also, a cleaner
6414         way to decide if r0/r1 should be pushed/popped. (Together they fix
6415         bug #918693)
6416
6417 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6418
6419         * doc/sdccman.lyx,
6420         * device/lib/mcs51/crtpagesfr.asm,
6421         * device/lib/mcs51/crtxinit.asm,
6422         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6423         to avoid confusion with Si Lab's SFRPAGE register.
6424
6425 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6426
6427         * src/SDCCglue.c (emitMaps): allow public sfr variables
6428         * src/SDCCglue.c (initialComments): include compiler build date
6429         with compiler version and put the timestamp of the generated
6430         assembly file on a serperate line to be less confusing.
6431         * src/port.h: added genInitStartup hook
6432         * src/avr/main.c,
6433         * src/ds390/main.c,
6434         * src/hc08/main.c,
6435         * src/pic/main.c,
6436         * src/pic16/main.c,
6437         * src/xa51/main.c,
6438         * src/z80/main.c: genInitStartup initialize as NULL (default to
6439         historical behaviour)
6440         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6441         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6442         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6443         library instead of hard coding it into the compiler.
6444         * support/regression/ports/mcs51-stack-auto/spec.mk,
6445         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6446         * device/lib/mcs51/Makefile,
6447         * device/lib/small/Makefile,
6448         * device/lib/large/Makefile,
6449         * device/lib/mcs51/crtpagesfr.asm,
6450         * device/lib/mcs51/crtstart.asm,
6451         * device/lib/mcs51/crtxclear.asm,
6452         * device/lib/mcs51/crtxinit.asm,
6453         * device/lib/mcs51/crtclear.asm,
6454         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6455         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6456         and into user configurable files.
6457         * device/lib/clean.mk: clean mcs51 directory too
6458         * support/regression/tests/longlit.c: added static to T1 declaration
6459         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6460         accesses in the initialization code
6461
6462 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6463
6464         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6465         OSCTRIMVAL as noted in bug #916008
6466
6467 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6468
6469         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6470         in loops with multiple exits (reported as incorrect registers
6471         used by Martin Helmling in Sdcc-user list)
6472
6473 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6474
6475         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6476         made ds390 register extensions look less like error messages
6477
6478 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6479
6480         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6481         reported by Adam Wozniak in Sdcc-user list
6482
6483 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6484
6485         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6486         arithmetic optimizations, added debug output
6487
6488 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6489
6490         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6491         * sdcc.spec: updated and split sdcc into 3 rpms
6492         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6493         needed for literals of LEFT_OP and '+'
6494         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6495         introduced RESULT_TYPE_NOPROM
6496         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6497         left shift
6498         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6499         limited promotion to int only for '*'
6500         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6501
6502 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6503
6504         * src/pic16/gen.c (genSkip),
6505         (genc16bit2lit), (gencjneshort): commented out
6506         (is_LitOp): new helper function, checks operand type
6507         (genCmpEq): rewritten
6508
6509 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6510
6511         * support/regression/tests/bug-908454.c: added
6512
6513 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6514
6515         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6516         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6517         (geniCodeCast): cosmetic, don't preserve bit storage class
6518         (geniCodeLeftShift): added promotion
6519         (geniCodeLogic): fixed regression
6520         * src/SDCCsymt.c (computeTypeOr): accept bits too
6521         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6522
6523 2004-03-07  Borut Razem <borut.razem AT siol.net>
6524
6525         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6526
6527 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6528
6529         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6530         version of pic16_genPackRegisters which does not check if ic is a
6531         CAST operator,
6532         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6533         function cause string1.c regression test fails
6534
6535 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6536
6537         * sim/ucsim/configure.in,
6538         * sim/ucsim/configure,
6539         * sim/ucsim/doc/Makefile.in: use docdir
6540         * src/SDCC.y: fixed sbit atrributes
6541         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6542         * src/SDCCast.c (decorateType): |^& need special promotion handling
6543         * src/SDCCast.h,
6544         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6545         * src/SDCCsymt.h (computeType),
6546         * src/SDCCicode.c: computeType() needs op
6547         * src/SDCCsymt.c (checkTypeSanity),
6548         * doc/sddman.lyx: "plain" bitfields are unsigned
6549         * src/SDCCsymt.c (computeTypeOr): added
6550         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6551         |^& ops
6552         * src/SDCCval.c (val*): computeType() needs op
6553         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6554         * support/regression/tests/onebyte.c: added tests for |^&
6555
6556 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6557
6558         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6559         for writing icode into asm output.
6560
6561 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6562
6563         * src/pic16/device.c: added some debug lines enabled
6564         with macro DEBUG_CHECK,
6565         * src/pic16/genarith.c: more debug in genPlus,
6566         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6567         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6568         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6569         * (aopForSym): onStack symbols are re-placed in data memspace,
6570         and onStack flag is cleared,
6571         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6572         copy temporary pcodeop,
6573         * (genPcall): added warning for not updating PCLATU,
6574         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6575         always true for pic16 port,
6576         * (genMultOneWord): NEW, supports integer multiplication,
6577         * (genMult): modified to call genMultOneWord,
6578         * (ifxForOp): added warning when return NULL,
6579         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6580         flag is set before call to operandFromSymbol for implicit
6581         added structures,
6582         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6583         options.intlong_rent are set by default,
6584         * (_hasNativeMulFor): modified to allow port generation of integer
6585         multiplication,
6586         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6587         set regtype to REG_SFR for all registers, restricting seting the
6588         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6589
6590 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6591
6592         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6593         more than 500 times in the regression tests
6594
6595 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6596
6597         * support/Util/SDCCerr.h,
6598         * support/Util/SDCCerr.c,
6599         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6600         enumerator_list),
6601         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6602         for symbol conflicts.
6603         * support/valdiags/tests/enum.c,
6604         * support/valdiags/tests/tentdecl.c,
6605         * support/valdiags/tests/struct.c: expect possible error messages
6606         referring to original symbol definitions.
6607         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6608         * src/SDCCsymt.h,
6609         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6610
6611 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6612
6613         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6614
6615 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6616
6617         * src/pic16/ralloc.c (newReg): fixed bug #908929
6618
6619 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6620
6621         * src/ds390/gen.c: added missing #include "main.h"
6622
6623 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6624
6625         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6626         checking if symbol is already in set,
6627         * src/pic16/device.h: prototype for checkAddSym,
6628         * src/pic16/gen.c: (_G): added entry interruptvector,
6629         * (assignResultValue): removed some commented out lines,
6630         * (genFunction): check for ISR via sym->type, absolute section for
6631         interrupt code is created via a new pBlock, the goto instruction is
6632         placed now correctly at the interrupt vector position, changed all
6633         references from ivec to _G.interruptvector,
6634         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6635         is the interrupt is a high priority one, same for return from ISR,
6636         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6637         externs to calls of checkAddSym,
6638         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6639         pic16_pcode_verbose flag is set,
6640         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6641         * src/pic16/pcoderegs.c: message about how many registers are saved
6642         will only be emitted if pic16_pcode_verbose flag is set,
6643
6644 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6645
6646         * src/ds390/ralloc.h,
6647         * src/ds390/ralloc.c (ds390_regWithIdx),
6648         * src/ds390/gen.c (emitcode),
6649         * src/ds390/main.h,
6650         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6651         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6652         ds390operandCompare, getRegsRead, getRegsWritten,
6653         initializeAsmLineNode): customized instruction size calculation for
6654         ds390, started basis for some register optimizations
6655         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6656         corresponding assembly output
6657         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6658         missing push/pop of r0/r1. Optimized push/pops
6659
6660 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6661
6662         * src/mcs51/main.c (instructionSize): fixed ACALL size
6663         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6664
6665 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6666
6667         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6668         the sorting of rlist with NULL elements
6669         * (print_idataType, print_idata): NEW to create idata sections
6670         * src/pic16/device.h: idataSymSet new variable
6671         * src/pic16/gen.c (genFunction): fixed some bugs in string
6672         comparing, improved the absolute section creation for ISRs,
6673         added FSR0L/FSR0H in registers that are saved in an ISR,
6674         * (genInline): fixed the processing of inline snippets,
6675         now they undergo no process by the peephole optimizer
6676         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6677         are placed in idataSymSet,
6678         * (pic16emitStaticSeg): extern symbols are added in externs,
6679         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6680         switching when aboslute variables are placed in access bank memory
6681         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6682         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6683         commented out with #if,
6684         * (pic16_packRegisters): reintroduce the check for CAST because some
6685         symbols are not correctly handled,
6686         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6687         pCodeInstruction instead of pCode,
6688         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6689         pCodeAsmDir definition,
6690         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6691         directive, then the argument directive is emitted without the leading
6692         tab, hack for inline labels which must be in the first column,
6693         * (compareLabel,pic16_findNextInstruction),
6694         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6695         * (insertBankSwitch): modified for the new pCodeAsmDir,
6696
6697 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6698         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6699
6700         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6701         instance,
6702         * (pushSide): commented out with #if,
6703         * (assignResultValue): fixed some typos in saving
6704         registers,
6705         * (genPcall): FIXED and sync'ed with genCall,
6706         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6707         * (genNearPointerGet): fixed to handle some more cases,
6708         implementation scheme via table reads,
6709         * (genConstPointerGet): modified to access code memory correct,
6710         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6711         and improved to handle some cases
6712         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6713         instead of "RETLW" for init data
6714         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6715         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6716         variables are placed in access bank memory (<0x80 and >=0xf80),
6717         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6718         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6719         TBLWT_POSTDEC,TBLWT_PREINC
6720         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6721         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6722         directives
6723         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6724         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6725         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6726         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6727
6728 2004-02-29  Borut Razem <borut.razem AT siol.net>
6729
6730         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6731         support/Util/findme.h, support/Util/system.h: enhance binary relative
6732         search for lib and include by using findProgramPath()
6733
6734 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6735
6736         * src/SDCCpeeph.h,
6737         * src/SDCCpeeph.c (pcDistance),
6738         * src/port.h,
6739         * src/mcs51/ralloc.h,
6740         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6741         * src/mcs51/main.h,
6742         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6743         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6744         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6745         size calculation port specific, started basis for some register
6746         optimizations
6747         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6748         missing push/pop of r0/r1. Optimized push/pops
6749         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6750         * device/lib/_modsint.c (_modsint),
6751         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6752         and stack version so regression tests pass
6753
6754 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6755
6756         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6757         * src/SDCCast.c (decorateType): catch another small optimization
6758         with '?' operator
6759         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6760         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6761         modified to finally use computeType() all over SDCC,
6762         see Feature Request #877103
6763         * src/SDCCval.h: cosmetic
6764         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6765         valCompare(); regression tested in muldiv.c
6766         * support/regression/tests/muldiv.c (testMod): mod sign follows
6767         dividend only
6768
6769 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6770
6771         * src/SDCCast.c (decorateType): fixed bug #902362
6772         * doc/INSTALL.txt: fixed install instructions for win32
6773
6774 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6775
6776         * device/include/Makefile.in (install): fixed by replacing spaces
6777         by tabs
6778         * doc/README.txt,
6779         * doc/INSTALL.txt: updated for release
6780         * doc/sdccman.lyx: added warning for --xstack being buggy
6781
6782 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6783
6784         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6785         to eliminate build warnings.
6786         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6787
6788 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6789            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6790
6791         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6792         removed -penable-stack, added comment for stack pragma, added
6793         warning for not initializing the stack/frame registers, removed
6794         comment at interrupts section
6795
6796         Stack is made permanent, there is no ability to disable stack usage.
6797         * src/pic16/device.h,
6798         * src/pic16/device.c: removed all references to USE_STACK macro,
6799         * src/pic16/device.c (pic16_dump_section): when no elements in
6800         rlist, free rlist before return,
6801         * (pic16_dump_int_registers): NEW, internal registers are a new set
6802         of general purpose registers reused by each function,
6803         * (checkAddReg): returns 1 if registers is added to set,
6804         * (pic16_groupRegistersInSection): when a registers is of type
6805         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6806         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6807         SRCASECMP macro is moved here from device.c
6808         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6809         PO_PCLATU, PO_PRODL, PO_PRODH,
6810         * (pic16_pCodeOpType, genMinus,
6811         changed compares to "a" register, with AOP_ACC,
6812         * (pic16_genPlus): fixed some bugs and indented properly,
6813         * (pic16_addSign): changed size to size+offset in the MOVWF
6814         instruction,
6815         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6816         multiply 8-bit operand by literal, result is 8-bit,
6817         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6818         multiply 2 8-bit operand, result is 8-bit,
6819         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6820         genUMult8X*_16,
6821         * src/pic16/gen.c: changed accUse to contain WREG only,
6822         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6823         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6824         true, do not use immediate addressing any more unless sym is a
6825         pointer in codespace,
6826         * (aopForRemat): do not use immediate addressing when symbol not in
6827         codespace and when symbol's address is requested,
6828         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6829         accUse size (= 1),
6830         * (aopGet): added case for AOP_ACC and don't return "accumulator
6831         bug" but WREG instead,
6832         * (popGetTempReg): pushes contents of temporary register in stack,
6833         * (popReleaseTempReg): pops contents of temporary register from
6834         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
6835         * (pic16_popGet): separated case AOP_ACC to return register WREG
6836         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
6837         or PO_IMMEDIATE and initializes their instance/offset appropriately,
6838         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
6839         the use of immediate pointers to certain cases only.
6840
6841         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
6842         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
6843         * (assignResultValue, genCall, genRet): modified to use the new
6844         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
6845         genPcall is still broken,
6846         * (genFunction): added code to create 'A' type pBlocks when
6847         interrupt functions are generated, code not extensively tested yet,
6848         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
6849         * (genEndFunction): modified so ISRs pop stored registers from stack,
6850         * (genMultOneByte): cleanup,
6851         * (AccRsh): added flag andmask, to and result with appropriate mask,
6852         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
6853         * (genDataPointerGet): fixed and reenabled its use,
6854         * (genNearDataPointerGet): bugs fixed,
6855         * (genDataPointerSet): bugs fixed,
6856         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
6857         pic16_DumpSymbol, pic16_DumpOp,
6858         * src/pic16/genutils.h: function prototypes for the above functions,
6859         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
6860         pointers,
6861         * (pic16emitRegularMap): many many many improvements, but needs a
6862         major cleanup,
6863         * src/pic16/main.c: enable_stack in pic16_options is removed,
6864         * (_pic16_parseOptions): removed command line options -penable-stack,
6865         * (_process_pragma): emit stack symbol only when stack pragma is
6866         processed,
6867         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
6868         redirected to FSR0L/FSR0H pair,
6869         * (pic16_get_op, pic16_get_op2): modifications and improvements,
6870         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
6871         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
6872         for immediates,
6873         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
6874         * (dumpPicOptype): NEW,
6875         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
6876         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
6877         with movff instruction,
6878         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
6879         added pic16_int_regs, some packRegsFor* functions are commented out,
6880         because produce errors,
6881         * src/pic16/NOTES: minor modifications
6882
6883 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6884
6885         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
6886         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
6887         --pack-iram.
6888         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
6889         * as/mcs51/lkaomf51.c: fixed bug #895763
6890
6891 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
6892
6893         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
6894
6895 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6896
6897         * doc/sdccman.lyx: added details about the HC08 storage classes and
6898         interrupts, fixed the register usage info for z80 & gbz80
6899
6900 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
6901
6902         * doc/sdccman.lyx: added more pic16 port documentation
6903         * device/include/pic16/: added header pic18fregs.h
6904
6905 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
6906
6907         * doc/sdccman.lyx: added Vangelis' contribution
6908
6909 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6910
6911         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
6912         extend to the next CALL or PCALL, not just to the next CALL.
6913
6914 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
6915
6916         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
6917
6918 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6919
6920         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
6921         bug #895752 and a better fix for bug #716790
6922
6923 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6924
6925         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
6926
6927 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6928
6929         * doc/sdccman.lyx: minor changes, minor changed
6930
6931 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
6932
6933         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
6934         which can't handle SDCC_NEWONEBYTEOPS,
6935         (geniCodeMultiply): removed conversion from mult to shift for pic14
6936         and pic16
6937
6938 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6939
6940         * src/hc08/gen.h,
6941         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
6942         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
6943         thus fixing bug #895406
6944
6945 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
6946
6947         * device/lib/_modsint.c,
6948         * device/lib/_modslong.c: sign follows divisor only
6949         * src/hc08/gen.c (genMultOneByte): if result size is 1,
6950         signs or signedness can be ignored
6951         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
6952         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
6953         added optimization for IFX,
6954         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
6955         arguments;
6956         reenabled optimization for IFX, which was removed on 2004-01-11
6957         * src/SDCCast.h: added return type IFX
6958         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
6959         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
6960         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
6961         SDCC_OLDONEBYTEOPS selects the old behaviour
6962         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
6963         changed again and commented promotion rule
6964         * src/SDCCval.c (valDiv): promotion no longer necessary
6965         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
6966         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
6967         rewritten
6968         * support/regression/tests/onebyte.c: added
6969
6970 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
6971
6972         * gen.c (genInline): reverted to old code for assemnling inline
6973         code because of bug reported James Chadd
6974
6975 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
6976
6977         * ralloc.h: missing declarations from previous patch,
6978         seems that patch for ralloc.h was never applied, fixed
6979
6980 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6981            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
6982
6983         * pcode.c,
6984         * pcode.h,
6985         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
6986         indirect addressing. Marked FSR0 as deprecated
6987         * gen.c (pointerCode): commented out, not needed now
6988         (pic16_popGet2p): new MOVFF helper function
6989         (genGenPointerGet),
6990         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
6991         (shiftRLong): removed duplicate debugging info
6992
6993 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6994
6995         * src/ds390/gen.c (genNearPointerGet),
6996         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
6997         optimization with bits, but not bitfields.
6998         * src/ds390/ralloc.c (packRegisters),
6999         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
7000
7001 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
7002
7003         * src/SDCCcse.c (algebraicOpts): copy operands before modification
7004
7005 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7006
7007         * src/SDCCsymt.h,
7008         * src/SDCCicode.c (operandFromSymbol),
7009         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
7010         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
7011         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
7012         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
7013         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
7014         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
7015         bug #892038
7016         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
7017         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
7018         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
7019         * src/SDCCsymt.c (newSymbol),
7020         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
7021         enumerator_list),
7022         * src/SDCCval.h,
7023         * src/SDCCval.c (newiList): fixed bug #885705
7024
7025 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7026
7027         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
7028         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
7029
7030 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7031
7032         * device/include/c8051f120.h,
7033         * device/include/c8051f300.h,
7034         * device/include/c8051f310.h: added/updated header files for Silicon
7035         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7036         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
7037         in new section Submitting patches
7038
7039 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7040
7041         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
7042         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7043         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7044         genGenPointerSet),
7045         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
7046         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7047         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7048         genGenPointerSet),
7049         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
7050         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7051         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7052         genGenPointerSet),
7053         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
7054         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7055         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7056         genGenPointerSet): fixed bug #892400
7057         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
7058         to eliminate build warnings.
7059         * src/SDCCast.c (processParms),
7060         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
7061         fixed bug 751859
7062         * support/valdiag/valdiag.py: added GCC to the list of defines active
7063         when compiling with gcc
7064
7065 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7066
7067         * support/Util/SDCCerr.h,
7068         * support/Util/SDCCerr.c,
7069         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
7070         with an incomplete type (fixed bug #883734)
7071         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
7072
7073 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7074
7075         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
7076
7077 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7078
7079         * src/SDCCast.c (decorateType),
7080         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
7081         function pointer implementation
7082         * support/regression/tests/funptrs.c: added tests to verify both forms
7083         of function pointers work correctly. Added tests to verify parameters
7084         are passed in the correct order.
7085
7086 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
7087
7088         * device.c (regCompare): registers are sorted by ascending
7089         address and increasing size,
7090         * main.c (_pic16_finaliseOptions): removed the declaration
7091         of compiler macro MCU. Now a macro of the format pic18fxxxx
7092         will be defined from the command line
7093
7094 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7095             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7096
7097         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
7098         PCOP_RLCF was overwritten!
7099         * gen.c (genSkip): commented out calls to pic16_emitcode,
7100         * (genCmpEQ): fixed "long" compares, only high word did get compared,
7101         * (genlshTwo),
7102         * (genRRC): added debugging info,
7103         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
7104         overwritten while shifting,
7105         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
7106         overwritten while shifting,
7107         * (AccLsh),
7108         * (AccRsh),
7109         * (shiftLLeftOrResult),
7110         * (shiftRLeftOrResult),
7111         * (shiftRLong),
7112         * (shiftLLong): Implemented with pic16_emitpcode
7113         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
7114         * (genLeftShift): Fixed bug, operand for shift by variable always
7115         was "and"ed with 0x0f,
7116         * (genLeftShiftLiteral),
7117         * (genrshTwo),
7118         * (genRightShiftLiteral): added debugging info,
7119         * (genrshFour): added comment,
7120         * (genRightShift): determined signedness from operand "left"
7121         instead of "result"
7122
7123 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7124
7125         * src/SDCCicode.c (geniCodeParms),
7126         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
7127         function pointers, fixed function pointer bugs #861242 and #861896
7128
7129 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7130
7131         * device/include/c8051f000.h,
7132         * device/include/c8051f120.h,
7133         * device/include/c8051f300.h: added header files for Silicon
7134         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7135
7136 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
7137
7138         * src/SDCCast.c (processParams): added new type flow and restructured
7139         (gatherAutoInit): added new type flow
7140         (addCast): cosmetic changes
7141         (getLeftResultType): added new type flow for array indices, patch
7142         provided by Stas, see FR #877103
7143         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
7144         array index patch by Stas
7145         * src/SDCCast.h: added prototype getResultTypeFromType()
7146         * src/SDCCval.h,
7147         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
7148         * src/pic/glue.c (pic14emitStaticSeg),
7149         * src/pic16/glue.c (pic16emitStaticSeg),
7150         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
7151         for initialization of symbols
7152         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
7153         * support/Util/SDCCerr.h:
7154         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
7155         * .version: bumped version number to 2.3.8
7156         * device/include/Makefile.in (install),
7157         * doc/Makefile (install): changed to 'rm `find ...`' construct to
7158         avoid warnings
7159
7160 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
7161
7162         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
7163         Slade Rich fixed an optimization bug
7164         * src/pic/pcodepeep.c,
7165         * src/pic/pcoderegs.c
7166         * doc/Makefile (install): added test for directory
7167
7168 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7169
7170         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
7171         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
7172         * src/pic/ralloc.c (getRegPtr, getRegGpr),
7173         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
7174         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
7175         * as/mcs51/asexpr.c (term),
7176         * as/hc08/asexpr.c (term): fixed bug #887146
7177
7178 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7179
7180         * src/z80/gen.c (genMult): handle single byte result product
7181         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
7182         DUMMY_READ_VOLATILE (fixed bug #886367)
7183
7184 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7185
7186         * support/regression/tests/libmullong.c: fixed logic, on little endian
7187         hosts we ended without a mullong_wrapper()
7188
7189 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7190
7191         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
7192         virus/worm forged address usage.
7193
7194 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7195
7196         Fixed promotion, it should be done on AST level:
7197         * src/SDCCast.c (addCast): added promotion to int
7198         (decorateType): updated call to upCast()
7199         * src/SDCCicode.c (geniCodeLeftShift): removed call to
7200         usualUnaryConversions()
7201
7202 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
7203
7204         * support/regression/tests/literalop.c (mulWrapper): Added a
7205         wrapper to remove integer overflow warnings.
7206
7207         * support/regression/tests/float_trans.c: Made work on host.
7208
7209         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
7210         location of sz80.
7211
7212         * support/regression/generate-cases.py (main): Changed from inline
7213         to a main method.
7214
7215         * doc/Makefile (install): Changed to depth first to get rid of
7216         missing directory install warning.
7217
7218         * as/Makefile (install-doc): Made work on Mac.
7219
7220 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
7221
7222         * src/SDCCast.c: added an additional type flow in decorateType() of
7223         opposite direction, see feature request #860006; it's enabled at runtime
7224         by setting the environment variable SDCC_NEWTYPEFLOW
7225         * src/SDCCast.h: changed prototype of decorateType()
7226         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
7227         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
7228         'char' to 'int' can be omitted, if both operands are 'unsigned char';
7229         see feature request #877103
7230         * src/SDCCval.c: updated call of decorateType()
7231         (valBitwise): fixed bug #882876
7232         (valMinus): added promotion
7233         (valLogicAndOr): result is unsigned
7234         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
7235         * src/SDCCsymt.c (computeType),
7236         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
7237         must not cause an unsigned operation
7238         * src/pic/glue (pic14emitRegularMap),
7239         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
7240
7241 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
7242
7243         * src/pic/pcode.c (PCodeID): commented out left over debug code
7244
7245 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
7246
7247         * support/valdiag/tests/overflow.c: added shift tests
7248         * src/pic/device.c,
7249         * src/pic/gen.c,
7250         * src/pic/gen.h,
7251         * src/pic/glue.c,
7252         * src/pic/main.c,
7253         * src/pic/pcode.c,
7254         * src/pic/pcode.h,
7255         * src/pic/pcodepeep.c,
7256         * src/pic/pcoderegs.c,
7257         * src/pic/ralloc.c,
7258         * src/pic/ralloc.h: applied patch from Slade Rich;
7259         added support for multiple code pages and multiple RAM banks on the
7260         PIC 14 port. The ASM files now no longer simply assume all the
7261         code / RAM are in the same page / bank. This means the linker can
7262         safely allocate code/RAM of separate ASM files to different pages/banks.
7263         * doc/sdccman.lyx: added Slade's tips
7264         * src/mcs51/peeph.def: fixed bug #880768
7265
7266 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7267
7268         * src/hc08/ralloc.c (rematStr): fixed bug #879282
7269         * src/SDCCast.c (decorateType): fixed bug #880197
7270
7271 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
7272
7273         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
7274         getopt.h.
7275
7276         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
7277         strtof is not part of C89 and isn't included with Mac OS X.
7278
7279 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7280
7281         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
7282         shiftL2Left2Result): fixed bug #879326
7283         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
7284         (genMultOneByte): fixed bug in signed vs unsigned multiplication
7285         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
7286         address fetch for clr instruction
7287         * device/lib/hc08/_mulint.c: created optimized assembly version
7288         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
7289
7290 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
7291
7292         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
7293         proposed in FR #877103
7294
7295 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
7296
7297         * src/SDCCval.c (cheapestVal): added missing checks
7298         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7299         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7300
7301 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7302
7303         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7304         equal operands
7305
7306 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7307
7308         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7309         loaded with the linker search paths (-L arguments) and the libraries
7310         to be linked with the current source (-l arguments). Changes
7311         currently will affect only the pic16 port.
7312         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7313         include path the port specific paths and port specific libraries,
7314         * gplink command now contains the $3 argument,
7315         * src/pic16/device.h,
7316         * src/pic16/device.c,: structure PIC_device is made public and
7317         renamed to PIC16_device, the same for variable Pics which is renamed
7318         to Pics16. Updated all references to them.
7319         * src/pic16/glue.c (pic16glue): corrected bug with code
7320         initialization which bypassed the variable initializations block.
7321
7322         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7323         COMPILE_FLAGS and added the --nostdinc option
7324
7325 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7326
7327         * device/include/mc68hc908jb8.h: Register defs for another member
7328         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7329
7330 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7331
7332         Documenting changes from previous commits.
7333         * configure.in (version 1.56),
7334         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7335         when generating output files to configure the pic16 library,
7336         but now I've commented it out, since gputils aren't installed in the
7337         SF compile farm, so library won't compile
7338
7339         * device/lib/Makefile.in (version 1.56): initially I've added in
7340         target 'all' the prerequestive 'model-pic16' so it compiled the
7341         pic16 library, but now I've commented it out for the same reasons
7342         above,
7343         * added targets 'model-pic16' and 'objects-pic16' to compile the
7344         library
7345         * added target 'port-specific-objects-pic16' to handle the
7346         generated libraries and copy them into the build/ directory
7347         * added target 'clean-intermediate-pic16' to clean intermediate
7348         files into pic16 directory
7349         * in target 'installdirs' added line to create directory pic16 in
7350         the installation path
7351
7352         * device/include/Makefile.in (version 1.11): in target 'install'
7353         added lines to copy all header files to installation path,
7354         * in target 'installdirs' added line create directory for pic16
7355         headers in the installation path
7356
7357 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7358
7359         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7360          a function call
7361
7362 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7363
7364         * configure,
7365         * device/lib/configure.in,
7366         * device/lib/configure: fixed for autoconf 2.57
7367
7368 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7369
7370         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7371         option so that it actually works. Made it specific to the z80, since
7372         the gbz80 doesn't have these kinds of I/O ports.
7373
7374 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7375
7376         * device/include/z180.h,
7377         * device/lib/_memcpy.c,
7378         * device/lib/_memmove.c,
7379         * device/lib/_mulint.c,
7380         * device/lib/ser_ir.c,
7381         * device/lib/ser_ir_cts_rts.c,
7382         * device/lib/_strcmp.c,
7383         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7384         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7385         portmode; added deprecation warning for bank= and protmode= forms.
7386         Also, guard against buffer overflow.
7387         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7388
7389 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7390
7391         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7392         changed interrupt vector table generation to only emit declared vectors.
7393         * device/include/Makefile.in: added missing backslash
7394         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7395
7396 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7397
7398         Mainly changes to support compilation of the device libraries
7399         * src/pic16/device.c: stack is allocated via symbol and not
7400         via literal number. The symbol is placed in the corresponding
7401         position of the data ram
7402         * (pic16_dump_section): relocatable and absolute uninitialized
7403         data are now emitted in sorted order to reduce section naming,
7404         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7405         weren't marked as being in the access bank,
7406
7407 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7408
7409         Added portion of GNU PIC Library under the directory
7410         device/include/pic16 and device/lib/pic16. These files
7411         contain the declarations of SFRs for the PIC18Fxx2 devices.
7412         The directory is initialized via configure from toplevel.
7413
7414 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7415
7416         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7417         the spilllocations to be compared correctly
7418
7419 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7420
7421         * src/SDCCast.c (decorateType): fixed bug introduced today
7422
7423 2004-01-12  Borut Razem <borut.razem AT siol.net>
7424
7425         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7426         doc/sdccman.lyx: upper case pragmas are deprecated
7427
7428 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7429
7430         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7431         in simpler and even better code
7432
7433 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7434
7435         * src/SDCCicode.c (operandOperation): fixed bug #874819
7436         * src/SDCCast.c (decorateType): fixed
7437         char foo (unsigned long ul) { return ul > 0; }
7438
7439 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7440
7441         * doc/sdccman.lyx: Moved and added some sections, small changes
7442         all over. Telling LaTeX to be less strict with word spacing
7443         to better keep the right margin. Changed some notes about
7444         maintainance of the ports in section 3.2.1 - is it OK like this?
7445
7446 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7447
7448         SDCC source changes:
7449         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7450         convilong): modified to inform the pic16 port that builtin functions
7451         are external
7452
7453         PIC16 PORT specific changes:
7454         * src/pic16/device.c pic16_dump_equates() added,
7455         processor registers declared internally by the port are emitted in
7456         the translation as equates,
7457         * src/pic16/gen.c: inline code is passed unprocessed to the
7458         translation,
7459         * (pic16_popGetLit2): fnuction modified to take second operand as
7460         pCodeOp pointer and not as literal,
7461         * (popRegFromIdx): prefixed with pic16_,
7462         * (pic16_popCombine2): modified to receive already allocated pCode
7463         operands,
7464         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7465         * (genFunction): initializes local stack frame and pushes on stack
7466         all the registers used by this function,
7467         * (genEndFunction): restores all registers from stack and restores
7468         stack frame,
7469         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7470         improvements,
7471         * (pic16glue): changed the program startup sequence,
7472         * added new dbName code 'A' for functions placed in absolute section
7473         * src/pic16/main.c: added function attribute _naked,
7474         * added pragma 'code' to place a fnuction at an absolute address,
7475         * added command line arguments --debug-ralloc and --pcode-verbose,
7476         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7477         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7478         * (pic16_newpCodeOpLit2): modified to take the second operand as
7479         pCodeOp pointer,
7480         * (pic16_printpBlock): modified to emit each function in a separate
7481         section,
7482         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7483         UPPER for immediate operands,
7484         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7485         instruction,
7486         * src/pic16/peeph.def: all peepholes with movff are commented out,
7487         because there is a problem in the pcode peep optimizer,
7488         * src/pic16/ralloc.c: the register allocator can now reuse local
7489         function symbols for another function. This saves register usage.
7490         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7491
7492         Added file src/pic16/NOTES with information about program writing on
7493         the current port version.
7494
7495 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7496
7497         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7498         and peephole 252 (array access)
7499
7500 2004-01-09  Borut Razem <borut.razem AT siol.net>
7501
7502         * src/SDCCmain.c : fixed #872250: -l command line defined library
7503           files are scanned before standard library files
7504
7505 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7506
7507         * src/SDCCast.c (decorateType): fixed bug #874046
7508
7509 2004-01-09  Borut Razem <borut.razem AT siol.net>
7510
7511         * support/scripts/sdcc.nsi: remove previous installation
7512
7513 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7514
7515         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7516         bytes for last interrupt vector (mcs51)
7517         * sdcc.spec: fixed typo
7518
7519 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7520
7521         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7522         gen51Code): more efficient parameter receive for --model-large
7523         ("bug" #845294)
7524
7525 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7526
7527         * src/ds390/main.c,
7528         * src/z80/main.c: added missed needLinkerScript flags (more than
7529         one port structure defined in these file)
7530         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7531         bug #795325
7532
7533 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7534
7535         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7536         * src/port.h: added flag needLinkerScript in port->linker
7537         structure to inform whether to create a .lnk file or not,
7538         * src/avr/main.c,
7539         * src/ds390/main.c,
7540         * src/hc08/main.c,
7541         * src/mcs51/main.c,
7542         * src/pic/main.c,
7543         * src/pic16/main.c,
7544         * src/xa51/main.c,
7545         * src/z80/main.c: changed appropriately to configure
7546         needLinkerScript flag
7547         * src/pic/gen.c,
7548         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7549         * src/pic/glue.c: added variable udata_section_name to
7550         override default uninitialized data segment definition for
7551         devices only with SHAREBANK memory (reported from Erik Epetrich)
7552         * (pic14emitOverlay): modified to emit a commented overlay segment
7553         directive when no overlay data exist
7554         * (picglue): modified to emit uninitialized data segment
7555         according to udata_section_name
7556         * src/pic/main.c (_pic14_parseOptions): added command line
7557         options --udata-section-name=[name] to override default
7558         udata definition name
7559         * modified _linkCmd and _asmCmd to include compiler passed
7560         arguments via -W option
7561         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7562         object file from '.rel' to '.o' in port->linker structure,
7563         changed size of fptr from 2 to 3 in port structure
7564
7565 2004-01-07  Borut Razem <borut.razem AT siol.net>
7566
7567         * support/scripts/sdcc.nsi: update PATH
7568         * support/scripts/sdcc.ico: craeted
7569
7570 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7571
7572         * device/include/Makefile.in: fix install
7573         * doc/Makefile: fix install
7574
7575 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7576
7577         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7578         in bug #860505
7579         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7580         how the function variable allocation summary is displayed; also
7581         include information about variables allocated to the overlay
7582         segment
7583
7584 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7585
7586         * as/mcs51/lkmain.c: Help about -Y option
7587         * as/mcs51/lkarea.c: Fixed gcc warnings
7588
7589 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7590
7591         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7592         fixed warning
7593         * support/valdiag/tests/overflow.c: added
7594         * src/SDCCast.c (decorateType),
7595         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7596         LEFT_OP (left shift)
7597
7598 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7599
7600         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7601         (default behaviour).
7602
7603 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7604
7605         A python script to validate compiler diagnostic messages. It can be
7606         used to verify that sdcc complains about bad c source code and
7607         gives a good location of the error.
7608         * support/valdiag/Makefile,
7609         * support/valdiag/valdiag.py,
7610         * support/valdiag/tests/*
7611
7612 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7613
7614         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7615         * src/SDCCsymt.c (newEnumType),
7616         * src/SDCCsymt.h
7617         * support/Util/SDCCerr.c,
7618         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7619         enum related bugs.
7620         * support/regression/tests/enum.c: added test for enum values that
7621         require at least 2 bytes of storage.
7622
7623 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7624
7625         * src/common.h: added ifndef/define/endif macros
7626         around the header file.
7627         Bug reported from Jesus Calvino-Fraga
7628
7629 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7630
7631         * sdcc.spec: updated
7632         * device/include/Makefile.in: don't install CVS directories
7633         * device/lib/Makefile.in: added removal of CVS directories after install
7634         * doc/Makefile: fixed install, added local_icons
7635         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7636         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7637         * src/ds390/gen.c (genRightShift): fixed bug #870788
7638         * src/SDCCast.c (decorateType): fixed bug #870781
7639
7640 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7641
7642         PIC16 port related changes:
7643         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7644         added variable stackPos,
7645
7646         * gen.c: genCall, assignResultValue: added support for
7647         pushing/retrieving function parameters to/from stack,
7648         genFunction,genEndFunction: setup stack frame for the
7649         generated function,
7650         genAddrOf: will be changed according to bug 863624
7651
7652         * added files genutils.c and genutils.h which contain gen*
7653         debugged and optimised functions extracted from gen.c
7654
7655         * glue.c: added variable 'externs' which holds extern symbols,
7656         pic16emitRegularMap: is modified to properly handle relocatable
7657          symbols under the new scheme,
7658         pic16createInterruptVect: is modified
7659         pic16printPublics: is modified to emit 'global' assembler directives,
7660         added pic16_printExterns to print extern symbols,
7661         pic16glue: initializes stack/frame pointer in the beginning of
7662         the assembly output. Temporary hack, will be corrected later,
7663         because gplink yet does not support stack and SDCC does not
7664         yet support a type of crt0.o object to create the final binary.
7665
7666         * Removed many lines that contain 8051 legacy code.
7667         * The code is finally placed under a 'code' directive.
7668         * Added port specific options.
7669
7670         * _process_pragma: simplified since now we do not need *special*
7671         include file to define SFR registers. But a separate header
7672         will be needed. This will be developed later.
7673         * _pic16_parseOptions: added, parses port specific options:
7674         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7675         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7676         --preplace-udata-with=
7677
7678         * _pic16_setDefaultOptions: modified to initialize section names,
7679         but hack is temporarly out of order since it needs improvement.
7680         * _pic16_genAssemblerPreamble: configuration words are emitted by
7681         their address instead of their name. This part is incomplete and
7682         supports only the 18Fxx2 devices. Other devices will emit an error
7683         during assembly since they do not contain the same set of config
7684         registers
7685         * _pic16_genIVT: is modified,
7686
7687         * pcode.c: added definitions for some hardware registers that are needed
7688         for stack support
7689         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7690         All PCI entries are updated. Now LFSR is supported.
7691         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7692         * added pic16_newpCodeOpLit2 to support instructions with
7693         two literal arguments
7694         * pic16_pCode2str: corrected code that emits assembler instructions
7695         with two literal operands and those that have an access bit modifier
7696         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7697         this fixes a bug which caused some labels to be lost, when an
7698         assembler directive was added, i.e. banksel,
7699         * pic16_FixRegisterBanking: improved logic that causes the insertion
7700         of bank switching,
7701         * InlineFunction: functions that are called once, are not any more
7702         inlined. This can be a port option in the future,
7703
7704         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7705
7706         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7707         hold the corresponding uninitialized symbols,
7708         * pic16_allocProcessorRegister: registers have explicit marked the
7709         accessBank field,
7710         * pic16_allocInternalRegister: registers are explicit marked as
7711         not used,
7712         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7713         processing list, so bit registers were lost,
7714         *
7715
7716         * ralloc.h: added field 'accessBank' and original symbol operand
7717         in register definition,
7718         * removed the field isMapped from register definition,
7719
7720         ** Several functions have been removed from various sources:
7721         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7722         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7723         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7724         pic16_assignRelocatableRegisters
7725
7726         ** others have been introduced:
7727         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7728         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7729
7730 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7731
7732         * support/scripts/inc2h.pl: changed definition of BIT_AT
7733         to emit 'sbit at' instead of 'bit at'. This was a request.
7734
7735         PIC16 port related preliminary changes:
7736         * gen.c: prefixed function popRegFromString with
7737         pic16_ and all references to it corrected
7738         * pcode.c: all pic16_pc_* hardware registers prefixed
7739         with underscore (_),
7740         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7741         * ralloc.c: newReg(): when register is REG_SFR then
7742         set address to rIdx,
7743         pic16_allocProcessorRegister(): marks register wasUsed=0
7744         pic16_writeUsedRegs(): added a call to assign processor
7745         registers via pic16_assignFixedRegisters
7746
7747 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7748
7749         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7750         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7751         variables in unused register banks.  Also the SSEG is placed
7752         wherever there is enough space for it, and IDATA can be anywhere
7753         in internal RAM.  For now compile using -Wl-Y[stack_size].
7754         The mem file is different for this option as well, since it
7755         makes no sense of talking about DSEG lenght.
7756
7757 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7758
7759         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7760         in certain cases, e.g. when ROM assignment, patch provided
7761         from Albert den Haan.
7762
7763 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7764
7765         Many signedness and type propagation fixes:
7766         * src/SDCCicode.c: made geniCodeCast() static
7767         replaced SPEC_ by IS_ (cosmetic)
7768         (operandOperation): fixed div and mod operation
7769         (usualBinaryConversions): added support for promotion of char
7770         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7771         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7772         (geniCodeAdd): an array index will stay unsigned, even if promoted
7773         from char to int
7774         (geniCodeArray): ditto
7775         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7776         * src/SDCCsymt.c (computeType): added more support for char;
7777         promotion of char is selectable by promoteCharToInt, fixed signedness
7778         for all cases
7779         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7780         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7781         * src/SDCCval (val*): replaced signedness calculation by
7782         computeType()
7783         rearranged if-branches (cosmetic)
7784         (valShift): added warning W_SHIFT_CHANGED
7785         (valCompare): fixed problem with different types
7786         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7787         * support/regression/tests/literalop.c: added many cases
7788         * support/regression/tests/ast_constant_folding.c: changed finally to
7789         'unsigned int'
7790         * .version: new year, new version: 2.3.7
7791         * src/SDCCmain.c (main): applied patch #866468
7792         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7793         provided by Scott Bronson
7794         * doc/sdccman.lyx: updated documentation for sdcdb
7795         updated and added chapter tips
7796
7797 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7798
7799         * src/SDCCsymt.h: missing from yesterday's commits
7800
7801 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7802
7803         * src/SDCC.y (struct_or_union_specifier),
7804         * support/Util/SDCCerr.c,
7805         * support/Util/SDCCerr.h: verify that struct & union tags are used
7806         as declared.
7807
7808 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7809
7810         * src/SDCCglobl.h: missing from yesterday's commits
7811
7812 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7813
7814         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7815         sft_attributes, struct_declaration, parameter_declaration,
7816         type_name, start_block, declaration_list),
7817         * src/SDCC.lex (check_type): support redefinition of typedef names
7818
7819 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7820
7821         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7822         aligned xdata arrays. Erik helped me with the if clause.
7823
7824 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7825
7826         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7827         warning
7828
7829 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7830
7831         * src/SDCCast.h,
7832         * src/SDCCast.c (newAst_),
7833         * src/SDCCicode.h,
7834         * src/SDCCicode.c (ast2iCode, newiCode),
7835         * src/SDCCglobl.h,
7836         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
7837         expr, statement, expression_statement, selection_statement,
7838         iteration_statement, expr_opt, jump_statement): foundation for tracking
7839         sequence points
7840         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
7841         point code too)
7842
7843 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7844
7845         * support/Util/SDCCerr.c,
7846         * src/SDCCast.h,
7847         * src/SDCCast.c (createCase, createDefault, decorateType),
7848         * src/SDCClabel.c (labelUnreach),
7849         * src/SDCC.y (labeled_statement, jump_statement): More improvements
7850         to error messages.
7851         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
7852         (with thanks to Stas Sergeev)
7853         * device/include/time.h,
7854         * device/lib/time.c (CheckTime): suppress unreachable code warning
7855
7856 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7857
7858         * src/SDCCast.c (createIvalCharPtr),
7859         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
7860         bug #753752)
7861         * support/regression/tests/nullstring.c: tests for these two bugs
7862
7863 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7864
7865         * support/Util/SDCCerr.h,
7866         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
7867         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
7868         about storage class and 'at' used inside struct or union
7869         * src/SDCCBBlock.c (iCodeFromeBBlock),
7870         * src/SDCCcse.c (ifxOptimize),
7871         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
7872         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
7873         printIval, emitStaticSeg, emitOverlay),
7874         * src/SDCClabel.c (deleteIfx),
7875         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
7876         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
7877         gatherAutoInit, processParms),
7878         * support/Util/SDCCerr.h,
7879         * support/Util/SDCCerr.c (werrorfl): Support for better error location
7880         reporting for post-parse errors.
7881
7882 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7883
7884         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
7885         implicit casts via union; they don't work on big endian systems
7886         (possible fix for bug #861138)
7887
7888 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7889
7890         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
7891         * src/mcs51/main.c: fixed the fix for bug #737001
7892
7893 2003-12-15  Borut Razem <borut.razem AT siol.net>
7894
7895         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
7896
7897 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7898
7899         * support/makebin/makebin.c: put output in binary mode
7900
7901 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7902
7903         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
7904         xdata and data memory on startup. Set the environment variable
7905         SDCC_NOGENRAMCLEAR to disable this.
7906         * src/mcs51/peephole.def,
7907         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
7908         (allows non-interrupt and interrupt code to safely compete for a resource
7909         without the non-interrupt code having to disable interrupts)
7910
7911 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7912
7913         * src/SDCCicode.c (geniCodeAdd),
7914         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
7915         with valFromType if type might be a pointer and host is big endian).
7916         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
7917         types, not just integer types.
7918         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
7919         multiply defined with mismatching "at" address.
7920
7921 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7922
7923         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
7924         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
7925         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
7926         with embedded nulls (fixed bug #753752)
7927
7928 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7929
7930         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
7931         Apparently this did not see much testing (endless loop)
7932
7933 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7934
7935         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
7936
7937 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7938
7939         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
7940         gracefully handle NULL memmap pointers
7941
7942 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7943
7944         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
7945         instead of deleting the iCode when an operand is volatile
7946         * src/z80/gen.c (genDummyRead),
7947         * src/mcs51/gen.c (genDummyRead),
7948         * src/ds390/gen.c (genDummyRead),
7949         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
7950         not just IC_RIGHT
7951         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
7952         * src/SDCC.y: fixed bug #850420
7953
7954 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7955
7956         Applied z80 i/o port patch from Peter Townson and fixed some operators
7957         to better handle operands in A register.
7958         * device/include/z180.h
7959         * src/SDCC.y
7960         * src/SDCCglue.c
7961         * src/z80/gen.c
7962         * src/z80/gen.h
7963         * src/z80/main.c
7964         * src/z80/peeph-z80.def
7965         * src/z80/peeph.def
7966         * src/z80/z80.h
7967
7968 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7969
7970         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
7971
7972 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7973
7974         * device/lib/hc08/_mullong.c: Removed extra #endif
7975
7976 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7977
7978         * sim/ucsim/hc08.src/inst.cc,
7979         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
7980         carries from x to h
7981         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
7982         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
7983         * device/include/stdarg.h: fixed varargs for hc08
7984         * device/lib/Makefile.in,
7985         * device/lib/hc08/Makefile,
7986         * device/lib/hc08/_mulint.c,
7987         * device/lib/hc08/_mullong.c: fixed some endian problems
7988
7989 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7990
7991         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
7992         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
7993         * device/lib/_gptrget.c,
7994         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
7995
7996 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7997
7998         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
7999         * src/SDCCast.c (astErrors): fixed bug #846007
8000         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
8001
8002 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8003
8004         * src/SDCCast.c (decorateType): disabled a transformation I added in
8005         revision 1.188 (access to fields of a structure at an absolute address);
8006         it breaks with bitfields, extern declarations, and gcse analysis.
8007         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
8008         could be assigned through a pointer, so don't complain.
8009         * src/SDCCast.c (astErrors),
8010         * src/SDCCast.h,
8011         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
8012
8013 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
8014
8015         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
8016         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
8017         output of __config directives, since gpasm now supports them
8018         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
8019         pre-processor macro, i.e. -DMCU=p18f452
8020         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
8021         and modified to handle 'cast' icode similarly to '=' icode
8022         * src/pic16/device.h (typedef struct PIC_device): added field
8023         'extMIface' to indicate that chip has external memory interface
8024         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
8025         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
8026         18F8720
8027
8028 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8029
8030         * src/SDCC.y (pointer): fixed bug #846006
8031         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
8032         * src/SDCCast.c (decorateType): fixed bug #846009
8033         * src/ds390/peeph.def,
8034         * src/ds390/gen.c (genAnd, genOr),
8035         * src/mcs51/peeph.def,
8036         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
8037
8038 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8039
8040         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
8041         * src/SDCCdflow.c
8042         * src/SDCCcse.c
8043         * src/SDCCcse.h
8044         * src/SDCCBBlock.h
8045         * src/SDCCBBlock.c
8046
8047 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
8048
8049         fixed bug #845089
8050         * src/SDCCbitv.h,
8051         * src/SDCCbitv.c: added function to free a bitvector
8052         * src/SDCClrange.h,
8053         * src/SDCClrange.c: added function to recompute the liveranges
8054         * src/avr/ralloc.c,
8055         * src/ds390/ralloc.c,
8056         * src/hc08/ralloc.c,
8057         * src/mcs51/ralloc.c,
8058         * src/pic/ralloc.c,
8059         * src/pic16/ralloc.c,
8060         * src/xa51/ralloc.c,
8061         * src/z80/ralloc.c: recompute the liveranges after register packing
8062
8063 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
8064
8065         * src/SDCCloop.c (newInduction): fixed bug #845630
8066
8067 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8068
8069         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
8070         inadvertantly left behind from my 2003-11-12 change
8071
8072 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8073
8074         Updated headers I neglected to commit yesterday.
8075         * src/SDCClrange.h,
8076         * src/SDCCicode.h
8077
8078 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8079
8080         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
8081         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
8082         * src/SDCCopt.c (eBBlockFromiCode),
8083         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
8084         the creation of the key hash table from the sequencing so it can be used
8085         earlier (for some GCSE bug fixes still pending)
8086
8087 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8088
8089         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
8090         * support/regression/tests/addsub.c: testing genPlus shortcut
8091
8092 2003-11-15  Borut Razem <borut.razem AT siol.net>
8093
8094         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
8095
8096 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8097
8098         * src/SDCCcse.c (cseBBlock): fixed bug #527779
8099         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
8100         ordering is immaterial.
8101         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
8102
8103 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8104
8105         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
8106         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
8107         (SIGSEV) of bug #840381
8108         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
8109         unlink new file before rename if new and old filenames are the same)
8110
8111 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8112
8113         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
8114         uninitialized variables) for the mcs51. Set environment variable
8115         SDCC_GENRAMCLEAR to test.
8116         xdata initialization slightly shorter
8117
8118 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8119
8120         * src/SDCCsymt.h,
8121         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
8122         #838241 & 780691 (basicly the same bug)
8123         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
8124         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
8125
8126 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
8127
8128         * src/SDCCmain.c (linkEdit): "fix" #834252
8129
8130 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8131
8132         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
8133         * src/SDCCast.h,
8134         * src/SDCC.y: fixed bug #819403
8135
8136 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8137
8138         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
8139         the reentrant attribute.
8140         * src/hc08/gen.c (genPackBits): added missing stack readjustment
8141         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
8142         simulation
8143         * src/SDCCast.c (decorateType): fixed bug with storage class not being
8144         updated during pointer dereference; f.e. ~(((char *)1)*) was being
8145         erroneously reduced to a literal.
8146         * src/hc08/ralloc.c (packRegisters, rematStr),
8147         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
8148         some cases
8149
8150 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8151
8152         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
8153         * doc/sdccman.lyx: changed from 'article' to 'book'
8154         * doc/Makefile: readded test_suite_spec and cdbfileformat
8155
8156 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
8157
8158         * device/include/stdlib.h: include malloc.h to comply with ANSI
8159         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
8160
8161 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8162
8163         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
8164         * doc/clean.mk: also remove *.out files
8165         * doc/sdccman.lyx: some additions, larger top/bottom margins
8166
8167 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8168
8169         * src/SDCC.y: fixed bug #837365
8170         * support/regression/tests/bitopcse.c
8171         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
8172         a symbol (might be valop instead)
8173         * device/lib/Makefile.in: added errno.c to HC08SOURCES
8174         * device/lib/clean.mk: added hc08 to the cleaning list
8175
8176 2003-11-04  Borut Razem <borut.razem AT siol.net>
8177
8178         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
8179           made 2003-11-04
8180         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8181           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
8182           malloc is declared in standard stdlib.h
8183
8184 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8185
8186         * device/lib/hc08/Makefile: need to clean .rel not .o files
8187         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
8188
8189 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8190
8191         * src/port.h,
8192         * src/hc08/main.c,
8193         * src/mcs51/main.c,
8194         * src/ds390/main.c,
8195         * src/z80/main.c,
8196         * src/avr/main.c,
8197         * src/pic/main.c,
8198         * src/pic16/main.c,
8199         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
8200         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
8201         tests (which uses the port's oclsExpense function)
8202         * src/SDCC.y,
8203         * src/SDCCast.c,
8204         * src/SDCCicode.c,
8205         * src/hc08/gen.c,
8206         * src/ds390/gen.c,
8207         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
8208
8209 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8210
8211         * src/SDCCcse.c (ifxOptimize),
8212         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
8213         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
8214         deleting the IFX iCode.
8215         * src/hc08/ralloc.c: reduced unneeded slocs
8216         * src/hc08/gen.c: fixed bug in asmopToBoolean
8217
8218 2003-11-04  Borut Razem <borut.razem AT siol.net>
8219
8220         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
8221           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8222           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
8223           transferred to configure
8224
8225 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
8226
8227         Use headers defined in the C[++] standards:
8228         * sim/ucsim/gui.src/serio.src/fileio.cc
8229         * sim/ucsim/gui.src/serio.src/frontend.cc
8230         * sim/ucsim/gui.src/serio.src/main.cc
8231         * sim/ucsim/gui.src/serio.src/posix_signal.cc
8232         * support/Util/NewAlloc.c
8233         * as/hc08/lklibr.c
8234         * as/mcs51/lklibr.c
8235         * as/z80/aslist.c
8236         * as/z80/assym.c
8237
8238 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8239
8240         * Added MSVC projects for hc08 assembler and linker:
8241         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
8242         /as/hc08/link_hc08.dsp
8243
8244 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
8245
8246         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
8247
8248 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
8249
8250         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
8251
8252 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8253
8254         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
8255
8256 2003-10-31  Borut Razem <borut.razem AT siol.net>
8257
8258         * support/cpp2/cpplib.h,
8259           support/cpp2/cpplib.c,
8260           support/cpp2/cpplex.c,
8261           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
8262           to switch _asm block preprocessing on / off. Default is
8263           #pragma preproc_asm +
8264
8265 2003-10-31  Borut Razem <borut.razem AT siol.net>
8266
8267         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
8268           when outputting comment blocks (when executed with -C option) and
8269           _asm (SDCPP specific) blocks
8270
8271 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8272
8273         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
8274
8275 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
8276
8277         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
8278
8279 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
8280
8281         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
8282         * src/SDCCast.c (decorateType): fixed bug #832664
8283
8284 2003-10-31  Borut Razem <borut.razem AT siol.net>
8285
8286         * support\cpp2\cpplex.c: fixed for SDCPP:
8287           comments(when executed with -C option) and _asm blocks
8288           were included even if they where in skipped #if block.
8289           Applied solution from GCC cpp 3.3.2
8290
8291 2003-10-31  Borut Razem <borut.razem AT siol.net>
8292
8293         * src/SDCC.lex: sdcc now understands both formats:
8294           '# <line_number> <file_name>' and
8295           '#line <line_number> <file_name>'
8296         * support/cpp2/cppmain.c: sdcpp now generates the standard
8297           '# <line_number> <file_name>' instead of former
8298           '#line <line_number> <file_name>'
8299
8300 2003-10-30  Borut Razem <borut.razem AT siol.net>
8301
8302         * support/cpp2/cpphash.h,
8303         * support/cpp2/cpplib.h
8304         * support/cpp2/cpplex.c,
8305         * support/cpp2/cppmain.c,
8306         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8307
8308 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8309
8310         Fixed a number of problems revealed by bug #827883.
8311         * src/SDCCloop.c (loopInvariants): Spill location of the
8312         result operand should be recomputed if extracted from
8313         a loop. Also, don't extract assignments of an iTemp
8314         from a literal.
8315         * src/SDCCast.c (isConformingBody): loop reversal should
8316         not occur if the control variable is involved with a
8317         relational operator.
8318
8319 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8320
8321         * .version: bumped to 2.3.6 to reflect the big improvements
8322         made by Erik and Klaus. Thanks!
8323
8324 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8325
8326         Replaced the livrange code.
8327         * src/SDCClrange.c: added new LR code
8328         * src/SDCCloop.c,
8329         * src/SDCCBBlock.h: removed remainig parts from old LR code
8330         * src/ds390/ralloc.c,
8331         * src/ds390/gen.c: minor fixes to make it work with new code
8332
8333 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8334
8335         * as/hc08/asm.h,
8336         * as/hc08/lkrloc.c,
8337         * src/hc08/gen.c,
8338         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8339         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8340         (tweaked fix for bug #818696)
8341
8342 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8343
8344         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8345
8346 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8347
8348         * src/SDCCmain.c,
8349         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8350         * src/mcs51/gen.c (gencjneshort),
8351         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8352         more efficient (per Scott Bronson's suggestion)
8353
8354 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8355
8356         Extended the semantics of the critical keyword to include
8357         individual statements. See RFE #827755 and #799831
8358         * src/SDCC.y
8359         * src/SDCCicode.c
8360         * src/SDCCopt.c
8361         * src/SDCCast.c
8362         * support/Util/SDCCerr.c
8363         * support/Util/SDCCerr.h
8364         * src/mcs51/gen.c
8365         * src/ds390/gen.c
8366         * src/hc08/gen.c
8367
8368 2003-10-19  Borut Razem <borut.razem AT siol.net>
8369
8370         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8371
8372 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8373
8374         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8375         Fixed bug #818696
8376         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8377         and predecrement operand is displayed
8378
8379 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8380
8381         * src/SDCCval.c (valMinus): fixed bug #826041
8382
8383 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8384
8385         Some hc08 related updates that I missed earlier
8386         * sim/ucsim/stypes.h
8387         * support/regression/ports/hc08/spec.mk
8388
8389 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8390
8391         New target "hc08" for the Motorola 68hc08 family of micros
8392
8393         * configure
8394         * configure.in
8395         * Makefile
8396         * src/hc08/*
8397         * src/SDCCmain.c
8398         * src/port.h
8399         * sim/ucsim/hc08.src/*
8400         * sim/ucsim/configure.in
8401         * src/ucsim/configure
8402         * sim/ucsim/packages_in.mk
8403         * as/hc08/*
8404         * as/Makefile
8405         * device/include/mc68hc908qy.h
8406         * device/lib/hc08/*
8407         * device/lib/Makefile.in
8408         * support/regression/ports/hc08/*
8409         * support/regression/Makefile
8410
8411 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8412
8413         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8414         regression test
8415         * src/ds390/gen.c (genCast): fixed bug #821957
8416
8417 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8418
8419         * device/lib/logf.c: "fixed" overlay bug
8420         * support/regression/ports/host/spec.mk: added m library
8421         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8422         * support/regression/tests/float_trans: added (for Eric)
8423
8424 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8425
8426         * src/mcs51/gen.c (genCpl): fixed bug
8427         http://sf.net/mailarchive/message.php?msg_id=6263915
8428
8429 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8430
8431         * src/SDCCast.c (decorateType): added extended constant folding
8432         * src/SDCCsymt.c (computeType): cleanup
8433         * src/SDCCval.c (valShift): minor optimization
8434         * support/regression/tests/ast_constant_folding.c: added
8435
8436 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8437
8438         * src/SDCCmain.c: removed some unintended changes
8439
8440 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8441
8442         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8443         * src/z80/gen.c: fixed part of bug #817589
8444         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8445
8446 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8447
8448         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8449         * src/SDCCcflow.c
8450         * src/SDCCcse.c
8451         * src/SDCCdflow.c
8452         * src/SDCClabel.c
8453         * src/SDCClrange.c
8454         * src/SDCCmem.c
8455         * src/SDCCopt.c
8456         * src/SDCCpeeph.c
8457         * src/SDCCset.c
8458         * src/avr/ralloc.c
8459         * src/ds390/ralloc.c
8460         * src/izt/ralloc.c
8461         * src/mcs51/ralloc.c
8462         * src/pic/ralloc.c
8463         * src/pic16/ralloc.c
8464         * src/xa51/ralloc.c
8465         * src/z80/ralloc.c
8466         * src/z80/gen.c: removed unused label "release:"
8467
8468 2003-10-06  Borut Razem <borut.razem AT siol.net>
8469
8470         * src/SDCC.lex: removed definition of unused variables
8471           save_optimize and save_options
8472
8473 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8474
8475         * clean.mk: removed '=' in "-maxdepth=1"
8476         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8477         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8478
8479 2003-10-06  Borut Razem <borut.razem AT siol.net>
8480
8481         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8482           my_unput() replaced by unput()
8483
8484 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8485
8486         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8487         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8488         type-punned pointer will break strict-aliasing rules"
8489         Old LR behaviour is again default; Klaus' LR can be choosen by
8490         defining the environment variable LRKLAUS
8491         * src/SDCCBBlock.h
8492         * src/SDCCloop.c
8493         * src/SDCClrange.c
8494         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8495         * clean.mk: fixed removal of files in bin/CVS/
8496         * device/lib/clean.mk: fixed removal of directories small and large
8497         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8498         * src/SDCCicode.c,
8499         * src/SDCCval.c: removed superflous test for pedantic
8500
8501 2003-10-05  Borut Razem <borut.razem AT siol.net>
8502
8503         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8504           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8505           message "unmatched #pragma SAVE and #pragma RESTORE"
8506
8507 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8508
8509         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8510           assembly, critical functions, atomic, nojtbound)
8511
8512 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8513
8514         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8515         * src/SDCCBBlock.h
8516         * src/SDCCloop.c
8517         * src/SDCCloop.h
8518         * src/SDCClrange.c
8519
8520 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8521
8522         * src/z80/gen.h,
8523         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8524         * src/mcs51/gen.h
8525         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8526         * src/ds390/gen.h
8527         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8528         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8529         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8530
8531 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8532
8533         * src/z80/gen.c (genRet): fixed bug #524753
8534         * src/z80/gen.c (genCast): fixed internal error on cast from
8535         pointer to long
8536         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8537         fix for bug #477835 to the z80
8538         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8539         for tracking iCodes in the peephole optimizer for z80
8540
8541 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8542
8543         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8544         the other part of bug #814548
8545         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8546
8547 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8548
8549         * src/SDCCcse.c: fixed part of bug #814548
8550
8551 2003-09-28  Borut Razem <borut.razem AT siol.net>
8552
8553         * src/asm.c: rewrite of printILine() to use temporary file instead
8554           a pipe
8555         * src/xa51/main.c: commented out declaration of int rewinds
8556
8557 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8558
8559         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8560
8561 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8562
8563         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8564         * src/asm.c (printILine): Fixed bug #811015
8565
8566 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8567
8568         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8569         freeing.
8570
8571 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8572
8573         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8574         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8575         to correctly handle general case of AOP_PAIRPTR
8576         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8577
8578 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8579
8580         * src/mcs51/ralloc.c (fillGaps),
8581         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8582         register positioning bug)
8583
8584 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8585
8586         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8587
8588 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8589
8590         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8591         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8592         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8593         (ralloc doesn't intentionally do this now, but perhaps later)
8594         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8595         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8596         register positioning bugs (Fixed bug #762602 and #795325)
8597         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8598         (Fixed bug #808779)
8599         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8600         lines that --i-code-in-asm generates
8601
8602 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8603
8604         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8605         trying to fclose a FILE* that was already closed.
8606
8607 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8608
8609         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8610         of const struct should be treated as if const themselves)
8611
8612 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8613
8614         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8615
8616 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8617
8618         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8619         Unix (/n) and DOS (/r/n) line terminations.
8620
8621 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8622
8623         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8624         bug #613775
8625
8626 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8627
8628         * src/mcs51/gen.c (genFunction, genEndFunction),
8629         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8630         and restore of EA so that stack offsets to parameters are
8631         correct when using both critical and reentrant/stack-auto.
8632         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8633         size (can be triggered in error if sloc is shared between
8634         different sized objects)
8635         * device/include/float.h: fixed macros to explicitly use
8636         unsigned long where needed
8637
8638 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8639
8640         Feature req. 799831: added code to allow nesting of critical functions
8641         * src/mcs51/gen.c (genFunction, genEndFunction)
8642         * src/ds390/gen.c (genFunction, genEndFunction)
8643
8644 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8645
8646         * src/SDCCsymt.c (sclsFromPtr),
8647         * src/SDCCsymt.h,
8648         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8649         support for standard C idiom of memory mapped variables; for
8650         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8651         to xdata int at 0x1234 tempvar = 1.
8652         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8653         provided by Akiya ISHIDA
8654
8655 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8656
8657         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8658         * src/SDCCval.c (constVal): added reduction from int to char
8659         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8660         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8661         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8662         to ignore the sign
8663         * support/regression/tests/shifts.c: fixed
8664
8665 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8666
8667         * src/z80/gen.c (genXor): Fixed bug #805445
8668
8669 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8670
8671         Fixed bug #621531 (const & volatile confusion in the type chain).
8672         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8673         refer to the const or volatile state of the pointer itself.
8674
8675         * src/SDCCast.c
8676         * src/SDCCglue.c
8677         * src/SDCCicode.c
8678         * src/SDCCsymt.c
8679         * src/SDCCval.c
8680         * src/SDCC.y
8681         * src/SDCCsymt.h
8682         * src/pic/gen.c
8683         * src/pic/ralloc.c
8684         * src/pic16/gen.c
8685         * src/pic16/ralloc.c
8686         * support/regression/tests/const.c
8687
8688 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8689
8690         When checking for duplicated modules, use absolute paths
8691         instead of relative paths.  Files changed:
8692
8693         * as/mcs51/lklib.c
8694         * link/z80/lklib.c
8695
8696 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8697
8698         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8699
8700 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8701
8702         * device/include/string.h: added size_t typedef, changed
8703         prototypes to use size_t, eliminated separate reentrant and
8704         non-reentrant declarations, added _memmove declaration
8705         * device/lib/_memcpy.c: changed to use size_t instead of int,
8706         changed /4 to >>2 to avoid division library call
8707         * device/lib/_memcmp.c,
8708         * device/lib/_memset.c,
8709         * device/lib/_strncat.c,
8710         * device/lib/_strncpy.c,
8711         * device/lib/_strncmp.c: changed to use size_t instead of int
8712         * device/lib/_memmove.c: new file (fixed bug #772294)
8713         * device/lib/Makefile.in: added _memmove.c
8714         * device/lib/z80/asm_strings.s: fixed bug #772290
8715         * support/regression/tests/bitfields.c: attempt to fix host assertion
8716         failure on amd64-unknown-linux2.2
8717
8718 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8719
8720         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8721         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8722         * as/z80/asmain.c (main): fixed bug #801766
8723
8724 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8725
8726         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8727         compilers
8728
8729 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8730
8731         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8732         reported in bug #800609
8733
8734 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8735
8736         * Top header beautifications in src/pic16 directory:
8737           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8738           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8739           pcoderegs.h, ralloc.c, ralloc.h
8740         * main.c: added top header and GPL license notice
8741         * pcode.c: fixed the if-conditional warning
8742
8743 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8744
8745         * device/lib/_mullong.c: replaced int by short for gcc
8746
8747 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8748
8749         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8750         and JUMPTABLE iCodes properly now (worked by accident before)
8751         * src/mcs51/gen.c (leftRightUseAcc),
8752         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8753         iCode properly now. Use getSize instead of nRegs since a & b
8754         aren't part of the nRegs tally.
8755
8756 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8757
8758         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8759         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8760           before instructions that use the _STATUS register
8761
8762 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8763
8764         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8765         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8766         fetching of the pointer
8767         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8768         copied from genNearPointerSet()
8769         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8770         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8771         If they pop r0/r1 they must be called in the opposite order than aopOp().
8772         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8773         (resp. --stack-auto), prepared for --xstack
8774
8775 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8776
8777         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8778
8779 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8780
8781         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8782         these ports have their own __sdcc_external_start()
8783
8784 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8785
8786         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8787         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8788         type for bits was changed. It resulted in bit variables becoming
8789         global, which is not permitted in PIC 14 assembly output.
8790
8791 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8792
8793         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8794
8795 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8796
8797         Z80 and MCS51 linkers complaint if a public symbol is defined
8798         in more than one library module:
8799
8800         * as/mcs51/lklib.c
8801         * link/z80/lklib.c
8802         * as/mcs51/Makefile.in
8803
8804 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8805
8806         A few small changes that speed up the peephole optimizer.
8807
8808         * src/SDCCpeeph.c
8809
8810 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8811
8812         Try to make the peephole optimizer smarter by maintaining
8813         an association between the assembly source code and the
8814         iCodes that originated them. Put this information to use
8815         with a new peephole rule condition "notVolatile" so that
8816         the rules can be aggressive yet still safe.
8817
8818         * src/SDCCpeeph.c
8819         * src/SDCCpeeph.h
8820         * src/mcs51/gen.c
8821         * src/mcs51/peeph.def
8822
8823 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8824
8825         Fixed bug #741761
8826
8827         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8828         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8829         if the left or right operand symbols have the accuse flag set.
8830
8831 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8832
8833         Changed the type of the result of the ! (NOT) operator to char;
8834         previously it returned the same type as the source. This allows
8835         us to eliminate all the genFloatNot functions (all of its target
8836         implementations were very buggy) since !float can use the same
8837         code as !long now.
8838
8839         * src/SDCCicode.c (ast2iCode): ! returns char
8840         * src/mcs51/gen.c (genNot, genNotFloat),
8841         * src/ds390/gen.c (genNot, genNotFloat),
8842         * src/z80/gen.c (genNot, genNotFloat),
8843         * src/pic/gen.c (genNot, genNotFloat),
8844         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
8845
8846 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
8847
8848         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8849         1. Interrupt would not compile properly. Ensure PCLATH register is saved
8850            during interrupts. Ensure WSAVE is located at a shared bank address.
8851         2. Fixed page selection in some places
8852         3. Fixed BTFSS/C to where necessary use registers directly and not simply
8853            the registers name strings.
8854         4. Fixed "signed / unsigned compare" compiler warnings.
8855         5. The PIC port manages its own allocation of the general purpose
8856            registers, but makes no attempt to reuse them. As a result when
8857            compiling it soon runs out of general purpose registers. Some
8858            additional code was added to the files pcode.c and device.c to walk
8859            through the function call tree and rename the registers so that they
8860            get reused.
8861
8862         * src/pic/device.c
8863         * src/pic/gen.c
8864         * src/pic/glue.c
8865         * src/pic/pcode.c
8866         * src/pic/pcode.h
8867         * src/pic/ralloc.c
8868         * src/pic/ralloc.h
8869         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
8870         genPlus() & genMinus() when the result is the same as left or right
8871
8872 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8873
8874         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
8875
8876 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8877
8878         Made bitfield a distinct type from bit so that bitfields
8879         convert as per ANSI C and bits retain their traditional
8880         boolean style behaviour. Implemented bitfield support in
8881         the z80 port.
8882
8883         * src/SDCCsymt.h,
8884         * src/SDCCsymt.c,
8885         * src/SDCCast.c,
8886         * src/cdbFile.c,
8887         * src/mcs51/gen.c,
8888         * src/ds390/gen.c: bit v bitfield split
8889         * src/z80/gen.c: New support for bitfields
8890         * support/regression/tests/bitfields.c: reenabled z80,
8891         added more tests
8892
8893 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8894
8895         Rules 246.x, 247.x relate to bitfields, the others speed up
8896         access to xdata mapped I/O devices.
8897
8898         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
8899
8900 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8901
8902         Cleaned up genPackBits and genUnpackBits and added two helper
8903         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
8904         for literal assignments in genPackBits (thanks to Frieder for
8905         reminding me).
8906
8907         * src/mcs51/gen.c
8908         * src/ds390/gen.c
8909
8910 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8911
8912         Fixed bug #748310 (pointer to function type mishandled when the
8913         function name is omitted). Also fixed a SIGSEGV when a function
8914         attribute (reentrant, etc) is used on a non-function or on a
8915         function but misplaced before the parameter list.
8916
8917         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
8918         bug #748310
8919         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
8920         * support/Util/SDCCerr.h,
8921         * support/Util/SDCCerr.c: Added func attr misuse error msg
8922
8923 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8924
8925         Fixed bug #787649 by anonymous
8926         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
8927         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
8928
8929 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8930
8931         Fixed numerous bitfield problems.
8932
8933         * src/SDCC.y: More bitfield related error checking
8934         * src/SDCCsymt.h,
8935         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
8936         * support/Util/SDCCerr.h,
8937         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
8938         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8939         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
8940         * support/regression/tests/bitfields.c: tests added
8941
8942 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8943
8944         Made the constant following the "interrupt" keyword optional. If
8945         omitted, the function will not automatically be given an entry
8946         in the interrupt vector table (similar to #pragma NOIV, but
8947         less syntacticly kludgy). The interrupt number is also now
8948         range checked. Also fixed a bug in the high order bit example
8949         in the manual.
8950
8951         * src/SDCC.y
8952         * src/SDCCmem.c
8953         * src/SDCCglue.c
8954         * src/SDCCsymt.h
8955         * support/Util/SDCCerr.c
8956         * support/Util/SDCCerr.h
8957         * doc/sdccman.lyx
8958
8959 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
8960
8961         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
8962         * src/SDCCicode.c (operandOperation): rewritten some ops
8963         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
8964         * src/SDCCsymt.c (computeType): literals are handled the same way as any
8965         other type
8966         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
8967         be re-activated by defining REDUCE_LITERALS)
8968         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
8969         unsigned, but are signed by default
8970         * src/SDCCval.c (constVal): rearranged
8971         * src/SDCCval.c (valMod): preliminary fix
8972         * src/SDCCval.c (valCastLiteral): use TYPE_* types
8973         * support/regression/literalop.c: added, work in progress
8974
8975 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8976
8977         Generate warnings for useless declarations like "char data;"
8978         that don't do what new users expect.
8979
8980         * src/SDCC.y
8981         * support/Util/SDCCerr.h
8982         * support/Util/SDCCerr.c
8983
8984 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
8985
8986         * src/SDCCval.c (valMult): fix overflow detection of negative int
8987
8988 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8989
8990         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
8991
8992         Changes to support big endian targets:
8993
8994         * src/ports.h
8995         * src/SDCCglue.c
8996         * src/avr/main.c
8997         * src/ds390/main.c
8998         * src/izt/i186.c
8999         * src/mcs51/main.c
9000         * src/pic/main.c
9001         * src/pic16/main.c
9002         * src/xa51/main.c
9003         * src/z80/main.c
9004
9005 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
9006
9007         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
9008         * device/lib/time.c: fixed warning "integer overflow in expression"
9009
9010 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
9011
9012         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
9013         * src/SDCCval.c (constVal): changed default to signed; hex and octal
9014         constants are unsigned; added recognition of "u" flag for unsigned
9015         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
9016         * src/SDCCval.c (valDiv, valMod): fixed signdness
9017         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
9018         signedness of modulo, left and right shift
9019         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
9020         * support/Util/SDCCerr.h: added warning W_INT_OVL
9021         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
9022         * src/SDCCast.c (ast_print): improved output of constants
9023
9024 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9025
9026         Fixed some warnings when building with MSVC:
9027
9028         * as\mcs51\asdata.c
9029         * as\z80\asdata.c
9030         * as\mcs51\asm.h
9031         * as\z80\asm.h
9032         * link\z80\aslink.h
9033         * link\z80\lkdata.c
9034         * link\z80\lkeval.c
9035         * link\z80\lkgb.c
9036         * link\z80\lkihx.c
9037         * link\z80\lks19.c
9038         * link\z80\lksym.c
9039         * support\cpp2\cpplib.c
9040         * src\ds390\gen.c
9041         * src\mcs51\gen.c
9042
9043 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
9044
9045         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
9046
9047 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9048
9049         * support\librarian\clean.mk: Do not remove Makefile.
9050         * support\librarian\Makefile: added.
9051
9052 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9053
9054         Added librarian to MSVC build:
9055         * all.dsp
9056         * sdcc.dsw
9057         * support\librarian\librarian.dsp
9058
9059         'configure' not needed for librarian, removed:
9060         * support\librarian\configure
9061         * support\librarian\configure.in
9062         * support\librarian\config_in.h
9063         * support\librarian\Makefile.in
9064
9065         Hopefully these ones built the librarian and the rest of sdcc properly:
9066         * Makefile
9067         * Makefile.common.in
9068
9069         Messed up 'configure', so revert to previous version:
9070         * configure
9071         * configure.in
9072
9073 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
9074
9075         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
9076         there, while the mantissa of a double is "only" 53 bits wide.
9077
9078 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9079
9080         Adding sdcclib to the build.  MSVC project coming soon.
9081         Files added/changed:
9082
9083         * support\librarian\clean.mk
9084         * support\librarian\configure
9085         * support\librarian\configure.in
9086         * support\librarian\config_in.h
9087         * support\librarian\Makefile.bcc
9088         * support\librarian\Makefile.in
9089         * support\librarian\sdcclib.c
9090         * Makefile.bcc
9091         * Makefile
9092         * Makefile.common.in
9093         * configure
9094         * configure.in
9095
9096 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9097
9098         Linker now complaints if linked modules have conflicting options, for
9099         example, one compiled using --model-large and another one compiled with
9100         --model-small.  The following files were modified:
9101
9102         * as\mcs51\asdata.c
9103         * as\mcs51\aslink.h
9104         * as\mcs51\asm.h
9105         * as\mcs51\asmain.c
9106         * as\mcs51\asout.c
9107         * as\mcs51\i51pst.c
9108         * as\mcs51\lkdata.c
9109         * as\mcs51\lklibr.c
9110         * as\mcs51\lkmain.c
9111         * as\z80\asdata.c
9112         * as\z80\asm.h
9113         * as\z80\asmain.c
9114         * as\z80\asout.c
9115         * as\z80\z80pst.c
9116         * link\z80\aslink.h
9117         * link\z80\lkdata.c
9118         * link\z80\lklibr.c
9119         * link\z80\lkmain.c
9120         * src\SDCCglue.c
9121
9122 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9123
9124         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
9125         as/mcs51/lklibr.c: Generate a warning when a library is not found.
9126
9127 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
9128
9129         * src/z80/mappings.i: fix _mul[us][int,long] entries
9130
9131 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9132
9133         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
9134
9135 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9136
9137         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
9138         * support/regression/tests/bitopcse.c: added
9139         fixed warning:
9140         * src/avr/gen.c:
9141         * src/pic/gen.c:
9142         * src/pic16/gen.c:
9143         * src/z80/gen.c:
9144         * src/xa51/gen.c:
9145
9146 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9147
9148         added support for new library format to z80, gbz80 linkers:
9149         *link/z80/aslink.h
9150         *link/z80/lklex.c
9151         *link/z80/lklib.c
9152         *link/z80/lklist.c
9153
9154 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9155
9156         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
9157         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
9158
9159 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
9160
9161         added DUMMY_READ_VOLATILE:
9162         * src/SDCC.y:
9163         * src/avr/gen.c:
9164         * src/xa51/gen.c:
9165         * src/z80/gen.c:
9166         * src/pic/gen.c:
9167         * src/pic16/gen.c:
9168         * src/mcs51/gen.c:
9169         * src/ds390/gen.c:
9170         * src/SDCCcse.c (algebraicOpts): many improvements
9171         * src/SDCCcse.h: removed algebraicOpts()
9172         * src/SDCCicode.c (picDummyRead): added
9173
9174 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9175
9176         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
9177         "Insufficient space in data memory".
9178
9179 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9180
9181         * src/mcs51/gen.c: fixed bug #771358
9182         * src/z80/gen.c: fixed bug #759087
9183
9184 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
9185
9186         * src/pic16/glue.c: minor cleanup by Vangelis
9187
9188 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9189
9190         * device/include/regc515c.h: fixed #758477
9191         * device/lib/_gptrget.c: saving some cycles in generic pointer get
9192         * device/lib/_gptrput.c: saved a few bytes
9193         * my tab spacing is 8, yours too?)
9194         * device/lib/_ser.c: process RX bytes earlier than TX bytes
9195         * device/lib/serial.c: process RX bytes earlier than TX bytes
9196         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
9197
9198 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9199
9200         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
9201
9202 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9203
9204     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
9205
9206 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
9207
9208         * device/lib/Makefile.in: bad fix, reverted to 1.43
9209
9210 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
9211
9212         * device/lib/Makefile.in: added missing z80 object files
9213
9214 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
9215
9216         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
9217         pic16 progress by Vangelis:
9218         * src/SDCCglobl.h:
9219         * src/SDCCmain.c:
9220         * src/pic/Makefile:
9221         * src/pic:
9222         * pic/Makefile:
9223         * pic16/device.c:
9224         * pic16/device.h:
9225         * pic16/gen.c:
9226         * pic16/gen.h:
9227         * pic16/genarith.c:
9228         * pic16/glue.c:
9229         * pic16/main.c:
9230         * pic16/pcode.c:
9231         * pic16/pcode.h:
9232         * pic16/pcodepeep.c:
9233         * pic16/peeph.def:
9234
9235 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9236
9237     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
9238
9239 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9240
9241     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
9242     added gbz80 build to MSVC project.
9243     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
9244     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
9245     from 8051 stuff and setup so it links using a .lnk file.
9246
9247 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9248
9249     * support/librarian/sdcclib.c: sdcc librarian.
9250     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
9251     with sdcclib.
9252
9253 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9254
9255     * as/mcs51/lkmain.c: properly handle extensions in function afile.
9256
9257 2003-07-02  Borut Razem <borut.razem AT siol.net>
9258
9259         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
9260         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
9261         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
9262         src/xa51/main.c, src/z80/main.c:
9263         virtualization of glue() function: each port has it's own glue function,
9264         which is accessed by do_glue function pointer in PORT.general structure
9265
9266 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
9267
9268         * DS800C400 fun, improved ROM interface and tinibios.
9269
9270 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
9271
9272         * More support for DS80C400. Now includes beginning of interface to ROM.
9273
9274 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
9275
9276         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
9277
9278 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9279
9280         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
9281
9282 2003-06-19  Borut Razem <borut.razem AT siol.net>
9283
9284         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
9285
9286 2003-06-19  Borut Razem <borut.razem AT siol.net>
9287
9288         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
9289         fixed Z80 port - crt0.o: cannot open.
9290
9291 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
9292
9293         * support/Util/MySystem.c (merge_command): revert bad fix
9294
9295 2003-06-18  Borut Razem <borut.razem AT siol.net>
9296
9297         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9298
9299 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9300
9301         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9302         option --use-stdout sends errors to stdout instead of stderr.
9303
9304 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9305
9306         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9307
9308 2003-06-15  Borut Razem <borut.razem AT siol.net>
9309
9310         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9311         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9312         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9313         fixed width array of pointers replaced with sets;
9314         multiple include and lib paths ared transferred to preprocessor and linker
9315         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9316         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9317         fixed width array of pointers
9318         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9319         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9320         fixupPath(), getPathDifference()
9321         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9322         fixed width array of pointers
9323
9324 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9325
9326         * src/pic16/ralloc.c: fix warnings
9327         * src/pic16/pcode.c: fix warning
9328
9329 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9330
9331          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9332         know all the details, but essentially this set of changes enable
9333         the pic16 port to generate movff instructions and generate assembler
9334         directives,
9335         * src/SDCCmain.c:
9336         * src/pic16/gen.c:
9337         * src/pic16/glue.c:
9338         * src/pic16/pcode.c:
9339         * src/pic16/device.c:
9340         * src/pic16/main.c:
9341         * src/pic16/pcode.h:
9342         * src/pic16/pcoderegs.c:
9343         * src/pic16/ralloc.c:
9344         * src/pic16/ralloc.h:
9345
9346 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9347
9348         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9349         added option --vc, so sdcc errors and warnings are compatible with
9350         Microsoft Visual Studio.
9351
9352 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9353
9354         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9355           device/lib/libfloat.lib: added atof function.
9356
9357 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9358
9359         * doc/sdccman.lyx: updated to Lyx 1.3
9360         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9361         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9362         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9363
9364 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9365
9366         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9367
9368 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9369
9370         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9371           additions to the "related tools/documentation" section
9372
9373 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9374
9375         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9376
9377 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9378
9379         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9380         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9381
9382 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9383
9384         * doc/sdccman.lyx: fix double dash and other minor things
9385         * doc/Makefile: fix double dash
9386
9387 2003-05-28  Karl Bongers(patches from Martin Helmling)
9388         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9389           condition and ignore commands.
9390
9391 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9392
9393         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9394           is in parts still quite out of date, I did changes as far as I felt makes sense
9395           for a non-native english speaker.
9396           Please feel free to add to the manual or to correct my changes.
9397         * doc/Makefile: undid touching the date of intermediate tex files.
9398
9399 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9400
9401         * doc/sdccman.lyx: Manual has an index now
9402
9403 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9404
9405         Finalize muluint/mulsint and mululong/mulslong merging:
9406         * device/lib/_mulint.c
9407         * device/lib/_mullong.c
9408         * device/lib/gbz80/mul.s
9409         * device/lib/gbz80/stubs.s
9410         * device/lib/z80/mul.s
9411         * device/lib/z80/stubs.s
9412         * src/SDCCsymt.c (initCSupport)
9413
9414 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9415
9416         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9417         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9418           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9419           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9420           instead of /Zm500.
9421
9422 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9423
9424         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9425           the regression tests I'm not brave enough to enable 245.b, 245.c
9426         * doc/sdccman.lyx: added latex preamble for hyperref package.
9427           Using pdflatex this will give you a hyperlinked pdf file with
9428           bookmarks. (prepend '%' before /usepackage if this breaks something)
9429
9430 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9431
9432          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9433
9434 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9435
9436         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9437
9438 2003-05-21    <johan AT balder>
9439
9440         * src/SDCCglue.c (printIval): fixed bug #739934
9441
9442 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9443
9444         Applied patch from bug 737905 (renamed yylineo to mylineno):
9445         * src/altlex.c
9446         * src/SDCCast.c
9447         * src/SDCglobl.h
9448         * src/SDCC.lex
9449         * src/SDCCsymt.c
9450         * src/SDCCval.c
9451         * src/pic16/pcode.c: Cleaned warnings
9452         * src/pic16/pcodeflow.c: Cleaned warnings
9453         * src/pic16/pcoderegs.c: Cleaned warnings
9454
9455 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9456
9457         * src/pic16/pcode.c: Cleaned warnings
9458         * src/pic16/pcodepeep.c: Cleaned warnings
9459         * src/pic16/ralloc.c: Cleaned warnings
9460
9461 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9462
9463         * doc/sdccman.lyx: fixed bug 739745
9464         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9465
9466 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9467
9468         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9469         it can be defined with CFLAGS when running configure
9470         * src/SDCCmain.c: fixed compiling + linking with object files
9471
9472 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9473
9474         * configure.in: configure for pic16 port,
9475             added --disable-pic16-port
9476         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9477         * src/SDCCmain.c: linkOptions is changed to set *,
9478             added if/endif conditional macros to remove options help
9479             messages from optionsTable when a port is not configured, added
9480             support for the PIc16 port in the ports table, when executing
9481             the compiler with no port specified on command line, a default
9482             port is selected with the new macro DEFAULT_PORT which is
9483             defined in port.h, in setDefaultOptions() linkOptions is removed
9484             from initialization assignment, since now it is a set,
9485             parseCmdLine uses setParseWithComma for linkOptions, in
9486             linkEdit() linkOptions are accessed with new function indexSet()
9487             which returns the i'th item of a set variable. See SDCCset.c, in
9488             linkEdit() when calling buildCmdLine(), added linkOptions as
9489             last argument. Now users can pass arguments to gplink via the
9490             -Wl option, main() uses pic16glue() to glue up pic16 programs
9491         * src/SDCCpeeph.c: various changes to support pic16
9492         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9493             return the i'th item of the set
9494         * src/SDCCset.h: added function prototype for indexSet()
9495         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9496         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9497         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9498             added macro DEFAULT_PORT
9499         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9500         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9501             generated
9502         * src/pic16/glue.c: commented out some error producing lines
9503         * src/pic16/main.c: __config directives are commented out to stop
9504             gpasm complaining and test the linkage with gplink, _linkCmd and
9505             _asmCmd changed to be more gplink and gpasm friendly
9506         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9507             produced an error when parsed, peep rule 12 is added to utilize
9508             movff, but it is commented out since the pCode does not support
9509             yet a command with 2 address arguments
9510
9511 2003-05-18    <johan AT balder>
9512
9513         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9514         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9515 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9516
9517         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9518   Added feature to script commands from file.
9519
9520 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9521
9522         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9523         * src/SDCCutil.c: include ctype.h for win32
9524
9525 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9526
9527         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9528
9529 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9530
9531         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9532   Fixed so you can set breakpoints prior to run, run does not stop
9533   on entry now.  Add tbreak.  Other enhancements and fixes for use
9534   with ddd.
9535
9536 2003-05-12  Borut Razem <borut.razem AT siol.net>
9537
9538         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9539
9540 2003-05-11  Borut Razem <borut.razem AT siol.net>
9541
9542         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9543         the path of bin directory, so that PATH is the only env. variable, which has to be set
9544         in case of standard installation.
9545         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9546         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9547         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9548
9549 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9550
9551         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9552         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9553         temp files are in the port dir; clean the gen/test directory when
9554         generating new test.c
9555         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9556         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9557         * support/regression/tests/zeropad.c: added
9558
9559 2003-05-09    <johan AT balder>
9560
9561         * src/SDCCglue.c: fixed bug #597940
9562
9563 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9564
9565         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9566   cache sfr, optimize next,step, fix off by one sourceline,
9567   support ddd list function.
9568         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9569
9570 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9571
9572         * support/regression/HTMLgen.py: added compare_s2f()
9573         * support/regression/Makefile: redo 1.27
9574         * support/regression/generate-cases.py: redo 1.5
9575
9576 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9577
9578         * support/regression/tests/float.c: workaround 33 bit hex constant
9579         * support/regression/tests/simplefloat.c: fix division for host
9580
9581 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9582
9583         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9584         that tame's the PIC's over-aggressive optimizer.
9585
9586 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9587
9588          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9589          support for MSVC.
9590
9591 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9592
9593         Initial support for DS80C400. "Hello world" runs on TINIm400
9594         (with polled I/O).
9595
9596 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9597
9598          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9599          * Some notes on ddd usage added in debugger/README
9600          Martin Helmling adding more features and fixes for ddd GUI debugger.
9601          Code added for nexti, stepi, up, down, and other adjustments.
9602
9603 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9604
9605         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9606         * src/pic/peeph.def Added two rules to optimize carry manipulation
9607         * src/pic/* removed debug printfs
9608
9609 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9610
9611         * debugger/mcs51/cmd.c: added header newalloc.h
9612
9613 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9614
9615         * as/Makefile: new EXEEXT
9616         * as/z80/Makefile: remove trailing slash of BUILDIR
9617         * as/z80/clean.mk: new EXEEXT
9618         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9619         * support/cpp2/Makefile.in: new EXEEXT
9620         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9621
9622 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9623
9624         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9625         EXEEXT was introduced to fix all related problems with targets
9626         "clean", "install" and "uninstall"; a couple of further flaws
9627         especially with "clean" have been fixed too
9628         * as/mcs51/Makefile.in
9629         * as/mcs51/clean.mk
9630         * as/z80/Makefile
9631         * Makefile
9632         * clean.mk
9633         * debugger/mcs51/Makefile.in
9634         * debugger/mcs51/clean.mk
9635         * link/z80/Makefile
9636         * link/z80/Makefile.in
9637         * link/z80/clean.mk
9638         * link/Makefile
9639         * packihx/Makefile.in
9640         * packihx/clean.mk
9641         * sim/ucsim/Makefile
9642         * sim/ucsim/clean.mk
9643         * sim/ucsim/avr.src/Makefile.in
9644         * sim/ucsim/avr.src/clean.mk
9645         * sim/ucsim/s51.src/Makefile.in
9646         * sim/ucsim/s51.src/clean.mk
9647         * sim/ucsim/xa.src/Makefile.in
9648         * sim/ucsim/xa.src/clean.mk
9649         * sim/ucsim/z80.src/Makefile.in
9650         * sim/ucsim/z80.src/clean.mk
9651         * sim/ucsim/main_in.mk
9652         * sim/ucsim/packages_in.mk
9653         * sim/ucsim/gui.src/Makefile.in
9654         * sim/ucsim/gui.src/serio.src/Makefile.in
9655         * sim/ucsim/gui.src/serio.src/clean.mk
9656         * src/Makefile.in
9657         * src/clean.mk
9658         * support/cpp2/Makefile.in
9659         * support/cpp2/clean.mk
9660         * support/makebin/Makefile
9661         * support/makebin/clean.mk
9662         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9663         * doc/sdccman.lyx: --program-suffix no longer needed
9664
9665 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9666
9667          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9668          Martin Helmling added support for ddd GUI debugger.
9669          Code added to display assembly, set variables, and other commands
9670          to interface to ddd.
9671
9672 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9673
9674         * as/Makefile: fix target clean
9675         * as/clean.mk: fix target clean
9676         * as/z80/clean.mk: fix target clean
9677
9678 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9679
9680         * Makefile.common.in: added  AT EXEEXT AT
9681         * configure.in: removed all mingw32 stuff
9682         * configure: rebuilt from configure.in
9683         * doc/sdccman.lyx: updated section "installation"
9684         * support/scripts/sdcc_mingw32: adapted to configure
9685         * support/scripts/sdcc_cygwin_mingw32: added
9686
9687 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9688
9689         * src/pic Added object file support for the PIC port
9690         * src/pic Applied patch from Craig Franklin (this started the object file support)
9691         * src/regression Updated the PIC regression tests for object files
9692
9693 2003-04-20  Borut Razem <borut.razem AT siol.net>
9694
9695         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9696           lklex.c: In function `getfid':
9697           lklex.c:203: warning: array subscript has type `char'
9698         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9699           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9700         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9701           stack handling macros
9702
9703 2003-04-19  Borut Razem <borut.razem AT siol.net>
9704
9705         * "handling space characters in file path" task:
9706         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9707         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9708         * support/Util/MySystem.h: make it self-sufficient
9709         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9710           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9711           handling space characters in file path
9712         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9713           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9714         * support/Util/MySystem.c: handling space characters in executable's path
9715
9716 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9717
9718         * as/z80/Makefile: fix permanent rebuild of z80
9719         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9720         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9721
9722 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9723
9724         * src/SDCCopt.c: add special case optimization to replace modulo by
9725           a power of two with a bitwise AND.
9726
9727 2003-04-18    <johan AT balder>
9728
9729         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9730
9731 2003-04-17    <johan AT balder>
9732
9733         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9734         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9735
9736 2003-04-13  Borut Razem <borut.razem AT siol.net>
9737
9738         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9739         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9740           fixed mingw problem in adl_NORMALIZE_PATH
9741
9742 2003-04-12  Borut Razem <borut.razem AT siol.net>
9743
9744         * fixed "#pragma SAVE/RESTORE can not be nested":
9745         * src/SDCC.lex: reworked pragma handling functions
9746         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9747         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9748
9749 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9750
9751         * src/SDCCutil.c (pathEquivalent): defined but not used
9752         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9753         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9754         * configure: rebuilt from configure.in
9755         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9756         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9757         * device/include/Makefile.in: replace sdcc_datadir
9758         * device/lib/Makefile.in: replace sdcc_datadir
9759         * Makefile.common.in: add LDFLAGS from configure
9760         * packihx/Makefile.in: use LDFLAGS
9761         * src/Makefile.in: use LDFLAGS
9762         * support/cpp2/Makefile.in: add LDFLAGS from configure
9763         * support/makebin/Makefile: use LDFLAGS
9764         * .version: bumped version number to 2.3.5
9765
9766 2003-04-12  Borut Razem <borut.razem AT siol.net>
9767
9768         * completed "different paths" task:
9769         * src/SDCCmacro.c: fixed bug in handling quotes
9770         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9771         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9772
9773 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9774
9775         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9776
9777 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9778
9779         * ds390/gen.c ds390/peeph.def: fix bug 706781
9780
9781 2003-04-11  Borut Razem <borut.razem AT siol.net>
9782
9783         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9784
9785 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9786
9787         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9788         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9789          set - this bit used to not be set...).
9790         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9791           bad code in PIC Port
9792         * src/regression/and2.c added to test bug 609268
9793         * src/regression/Makefile added and2.c to regression test
9794
9795
9796 2003-04-08    <johan AT CP255758-A>
9797
9798         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9799         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9800         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9801
9802 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9803
9804         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9805         fix bug #487815
9806         * support/cpp2/Makefile.in: fix bug #487815
9807         * configure: rebuilt from configure.in
9808         * Makefile.common.in: docdir changed, new path suffixes
9809         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9810         * sdcc_vc_in.h: reflect changes from sdccconf.h
9811         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9812         * src/SDCCutil.h: remove BINDIR hack
9813         * doc/sdccman.lyx: update new path hierarchy
9814
9815 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9816
9817         * src/SDCCpeeph.c: added okToRemoveSLOC test
9818
9819 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9820
9821         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9822
9823 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9824
9825         * src/SDCCpeeph.c: added labelIsReturnOnly test
9826         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9827
9828 2003-04-05    <johan AT balder>
9829
9830         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
9831         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
9832         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
9833         * src/SDCCast.c: fixed a warning
9834         * src/SDCCast.h: fixed a warning
9835         * src/SDCCicode.c (operandFromAst): fixed a warning
9836
9837 2003-04-04    <johan AT balder>
9838
9839         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
9840         * src/SDCCast.c (decorateType): fixed bug #715076
9841         * src/SDCC.y: fixed bug #702907
9842
9843 2003-04-03    <johan AT balder>
9844
9845         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
9846         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
9847         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
9848         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
9849         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
9850
9851 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
9852
9853         * _decdptr.c: fix return values
9854         * _gptrget.c: fix return values
9855         * _gptrgetc.c: fix return values
9856         * _gptrput.c: fix return values
9857         * _mulint.c: fix return values
9858         * as/z80/Makefile: fix 'make -j' problem
9859
9860 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
9861
9862         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
9863         * configure.in: big cleanup, updated to autoconf 2.5x
9864         * configure: rebuilt from configure.in
9865         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9866         * sdcc_vc_in.h: reflect changes from sdccconf.h
9867         * doc/Makefile: fixed a flaw in "make install"
9868
9869 2003-04-02    <johan AT balder>
9870
9871         * src/ds390/gen.c (genCmp): no comments
9872         * src/mcs51/gen.c (genCmp): no comments
9873         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
9874         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
9875
9876 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
9877
9878         * support/regression/generate-cases.py: place generated file in given sub directory
9879         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
9880         * support/regression/Makefile: improvements for 'make -j';
9881         side effect: it's simpler and faster now
9882
9883 2003-03-31  Borut Razem <borut.razem AT siol.net>
9884
9885         * src/z80/main.c: link-{port} and as-{port} defined without path
9886         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
9887
9888 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
9889
9890         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
9891
9892 2003-03-30  Borut Razem <borut.razem AT siol.net>
9893
9894         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
9895           changed type of list parameter to set
9896         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
9897         * src/port.h: changed type of do_assemble() parameter to set
9898         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
9899           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
9900           definition of "cppoutfilename" macro with NULL value in preProcess()
9901         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
9902         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
9903         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
9904           replaced with set *binPathSet
9905         * shash_add() deallocates the item, if allready exsists, before adding the new one
9906         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
9907
9908 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
9909
9910         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
9911           a nested for loop bug in the PIC port
9912         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
9913           for loops
9914
9915 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
9916
9917         * support/Util/dbuf.h: remove C++ stuff to make it portable
9918
9919 2003-03-28  Borut Razem <borut.razem AT siol.net>
9920
9921         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
9922           literal strings in stringLiteral()
9923         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
9924         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
9925           to the project
9926
9927 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
9928
9929         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
9930
9931 2003-03-26    <johan AT balder>
9932
9933         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
9934         * src/ds390/gen.c (saveRegisters): catched symbol abuse
9935         * src/SDCCast.c (decorateType): fixed " -v < 3"
9936
9937 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
9938
9939         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
9940         Added Lenny Story's debug infrastructure changes:
9941         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
9942         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
9943         * src/cdbFile.c: added
9944         * src/SDCCdebug.c: added
9945         * src/SDCCdebug.h: added
9946         * src/SDCCast.c (createFunction)
9947         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
9948         * src/SDCCmain.c (parseCmdLine, main)
9949         * src/SDCCmem.c (redoStackOffsets)
9950         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
9951         * src/SDCCsymt.h
9952         * src/common.h
9953         * src/avr/gen.c (genAVRCode)
9954         * src/ds390/gen.c (gen390Code)
9955         * src/mcs51/gen.c (gen51Code)
9956         * src/pic/gen.c (genpic14Code)
9957         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
9958         * src/xa51/gen.c (genXA51Code)
9959         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
9960
9961 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9962
9963         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
9964         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
9965
9966 2003-03-22    <johan AT balder>
9967
9968         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
9969
9970 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
9971
9972         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
9973         * doc/cdbfileformat.lyx: added, written by Lenny Story
9974         * doc/Makefile: added cdbfileformat.lyx
9975         * doc/clean.mk: added cdbfileformat.lyx
9976
9977 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
9978
9979         * src/mcs51/peeph.def: fix bug #705773
9980
9981 2003-03-20    <johan AT balder>
9982
9983         An sfr/sbit can have an "at #" AND an initializer
9984         * src/SDCCsymt.c (checkSClass):
9985         * src/SDCCmem.c (allocGlobal):
9986         * src/SDCCmem.c (allocLocal):
9987         * src/SDCCast.c (createBlock):
9988
9989 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
9990
9991         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
9992
9993 2003-03-16    <johan AT balder>
9994
9995         Undid the hackup of const and volatile, the problem is much bigger
9996         * src/SDCC.y:1.65
9997         * src/SDCCast.c:1.171
9998         * src/SDCCglue.c:1.138
9999         * src/SDCCicode.c:1.146
10000         * src/SDCCsymt.c:1.150
10001         * src/SDCCval.c:1.65
10002
10003 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
10004
10005         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
10006         * src/ds390/gen.c (genAddrOf): fixed bug #704087
10007
10008 2003-03-13    <johan AT balder>
10009
10010         Hackup const and volatile modifiers in type chains a bit:
10011         * src/SDCC.y:1.63
10012         * src/SDCCast.c:1.169
10013         * src/SDCCglue.c:1.136
10014         * src/SDCCicode.c:1.143
10015         * src/SDCCsymt.c1.146
10016         * src/SDCCsymt.h1.59
10017         * src/SDCCval.c:1.63
10018
10019 2003-03-12    <johan AT balder>
10020
10021         * src/SDCCBBlock.h: more LRH debugging junk
10022         * src/SDCCcflow.h: more LRH debugging junk
10023         * src/SDCCloop.c: more LRH debugging junk
10024         * src/SDCC.y (struct_declaration): fixed bug #697590
10025         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
10026         * src/ds390/gen.c (aopForRemat): fixed bug #700031
10027         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
10028
10029 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10030         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
10031         test function names must now match exactly).
10032         * src/SDCCcse.c: added special case in findCheaperOp to allow
10033         extending a short integer. Makes less awful code for bug 700121 test case.
10034
10035 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10036
10037         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
10038         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
10039
10040 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10041
10042         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
10043         actually called (operandsNotEqual() was called for all
10044         operandsNotEqualX tests).
10045
10046 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10047
10048         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
10049         with shorter literals. Fixes bug 700121.
10050
10051 2003-03-11    <johan AT balder>
10052
10053         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
10054
10055 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
10056
10057         * src/SDCCloop.c (mergeRegions): an evil beast is dead
10058         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
10059
10060 2003-03-10  Borut Razem <borut.razem AT siol.net>
10061
10062         * src/SDCCmain.c: pipe preprocessor's output
10063         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10064         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10065         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10066         which closes all pipes in pipeSet set
10067         * src/SDCCset.c: free deleted item in function deleteSetItem()
10068         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10069         moved from z80 to src subproject
10070         * .version: increased version number to 2.3.4
10071
10072 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
10073
10074         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
10075         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
10076         * support/regression/ports/xa51/spec.mk: fix typo
10077
10078 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
10079
10080         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
10081
10082 2003-03-09  Borut Razem <borut.razem AT siol.net>
10083
10084         * src/SDCCmain.c: pipe preprocessor's output
10085         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10086         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10087         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10088         which closes all pipes in pipeSet set
10089         * src/SDCCset.c: free deleted item in function deleteSetItem()
10090         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10091         moved from z80 to src subproject
10092
10093 2003-03-09  Borut Razem <borut.razem AT siol.net>
10094
10095         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
10096         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
10097         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
10098         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
10099         * src/SDCCglobl.h: unification of WIN32 native definitions
10100
10101 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10102
10103         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
10104
10105 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10106
10107         * src/configure.in:   check for endianess (even while cross-compiling)
10108         * src/configure:      check for endianess (even while cross-compiling)
10109         * src/configure_in.h: check for endianess (even while cross-compiling)
10110         * src/avr/gen.c:        remove old endianess stuff
10111         * src/mcs51/gen.c:      remove old endianess stuff
10112         * src/ds390/gen.c:      remove old endianess stuff
10113         * src/pic/gen.c:        remove old endianess stuff
10114         * src/pic/genarith.c:   remove old endianess stuff
10115         * src/pic/glue.c:       fix endianess check
10116         * src/pic16/gen.c:      remove old endianess stuff
10117         * src/pic16/genarith.c: remove old endianess stuff
10118         * src/pic16/glue.c:     fix endianess check
10119         * src/xa51/gen.c:       remove old endianess stuff
10120         * src/z80/gen.c:        fix endianess check
10121         * src/SDCCglue.c:       fix endianess check
10122         * src/ds390/peeph.def: fix bug 700036
10123
10124 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10125
10126         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
10127         * src/configure: find appropriate data-types on host for SDCC's int and long
10128         * src/configure.in: find appropriate data-types on host for SDCC's int and long
10129         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
10130         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
10131
10132 2003-03-07    <johan AT balder>
10133
10134         Just a big NOOP:
10135                 some minor cleanups before the big shot
10136                 OP_DEFS and OP_USES now use Kevin's protection
10137                 new option --nolabelopt
10138
10139         * src/SDCCBBlock.c:
10140         * src/SDCCast.c,:
10141         * src/SDCCcflow.c:
10142         * src/SDCCcse.c:
10143         * src/SDCCicode.c:
10144         * src/SDCCicode.h:
10145         * src/SDCClabel.c:
10146         * src/SDCCloop.c:
10147         * src/SDCCmain.c:
10148         * src/ds390/ralloc.c:
10149         * src/mcs51/ralloc.c:
10150         * src/pic/ralloc.c:
10151         * src/xa51/ralloc.c:
10152         * src/z80/ralloc.c:
10153
10154 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
10155
10156         * src/pic/pcode.c (get_op): fix 64 bit warnings
10157         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
10158         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
10159         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
10160         * support/regression/tests/malloc.c: fix 64 bit warnings
10161
10162 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
10163
10164         * src/mcs51/gen.c (genMinus): fixed bug 696436
10165
10166 2003-03-02  Borut Razem <borut.razem AT siol.net>
10167
10168         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
10169
10170 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
10171
10172         * configure.in: test for mkstemp
10173         * sdccconf_in.h: add HAVE_MKSTEMP
10174
10175 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
10176
10177         * device/include/ctype.h: removed warning while using --stack-auto
10178         * device/include/malloc.h: removed warning while using --stack-auto
10179         * device/include/string.h: removed warning while using --stack-auto
10180
10181 2003-02-23  Borut Razem <borut.razem AT siol.net>
10182
10183         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
10184         because NDEBUG is defined (see man assert)
10185         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
10186
10187 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10188
10189         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
10190         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
10191
10192 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10193
10194         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
10195         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
10196
10197 2003-02-18    <johan AT balder>
10198
10199         * as/mcs51/asmain.c (asmbl): module can start with a digit
10200         * as/z80/asmain.c (asmbl): module can start with a digit
10201
10202 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
10203
10204         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
10205         * src/asm.c: fix pipe() for Mingw32
10206
10207 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
10208
10209         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
10210         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
10211         make -V work again; --c1mode reads now from stdin
10212         * doc/sdccman.lyx: added --c1mode
10213         * support/Util/SDCCerr.c: new messages for c1 mode
10214         * support/Util/SDCCerr.h: new messages for c1 mode
10215         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
10216
10217 2003-02-15    <johan AT balder>
10218
10219         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
10220
10221 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
10222
10223         * doc/sdccman.lyx: Environment variables, -o and other minor things
10224
10225 2003-02-14    <johan AT balder>
10226
10227         * src/xa51/main.c: before anyone really tries to use it :)
10228
10229         * Install doc's in share/sdcc/doc
10230         * removed some obsolete files
10231         * Do a proper make distclean and uninstall
10232         M Makefile.common.in
10233         R sdccbuild.sh
10234         M as/Makefile
10235         M device/include/Makefile.in
10236         M device/lib/Makefile.in
10237         M doc/sdccman.lyx
10238         M link/Makefile
10239         M sim/ucsim/doc/Makefile.in
10240         M src/clean.mk
10241         R src/avr/peeph.rul
10242         R src/xa51/peeph.rul
10243         M support/cpp2/Makefile.in
10244         M support/makebin/Makefile
10245
10246
10247 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
10248
10249         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
10250
10251 2003-02-10  Borut Razem <borut.razem AT siol.net>
10252
10253         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
10254         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
10255         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
10256         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
10257         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
10258         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
10259         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
10260         src/z80/Makefile.bcc: Borland Makefile cleanup
10261         * as/z80/Makefile.bcc: Added Borland Makefile
10262         * support/cpp2/borland.h: Removed
10263
10264 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
10265
10266         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
10267         * src/SDCC.lex: new pragma NOIV
10268         * src/SDCCglobl.h: new pragma NOIV
10269         * src/SDCCmem.c: new pragma NOIV
10270
10271 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10272
10273         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
10274
10275 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10276
10277         * src/SDCCmain.c: signal handling is switched off by --debug
10278         * doc/Makefile: small fix for install; use clean.mk again
10279         * doc/clean.mk: clean *.pdf and *.html too
10280
10281 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
10282
10283         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
10284         * device/lib/printfl.c: fix a ds390 bug by making it portable
10285         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
10286         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
10287         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
10288         * debugger/mcs51/cmd.c: converted multi-line string literals
10289         * sim/ucsim/globals.cc: converted multi-line string literals
10290         * src/SDCCmain.c: introduced signal handler to remove temp files
10291         * doc/Makefile: small tweaks, implement clean
10292         * doc: removed generated files
10293
10294 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10295
10296         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10297         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10298         Address Record is not correctly generated for DS390."
10299
10300 2003-02-02  Borut Razem <borut.razem AT siol.net>
10301
10302         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10303         * as/mcs51/asm.h: fixed compilation with Borland C
10304         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10305         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10306         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10307         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10308         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10309         src/z80/Makefile.bcc: delete $(LIB) only if exist
10310         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10311
10312 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10313
10314         * device/include/malloc.h: introduced NULL
10315         * device/include/string.h: introduced NULL
10316         * device/include/stdlib.h: introduced NULL
10317         * device/lib/_memcpy.c: removed NULL
10318         * device/lib/_strcat.c: removed NULL
10319         * device/lib/_strchr.c: removed NULL
10320         * device/lib/_strcmp.c: removed NULL
10321         * device/lib/_strcpy.c: removed NULL
10322         * device/lib/_strcspn.c: removed NULL
10323         * device/lib/_strlen.c: removed NULL
10324         * device/lib/_strncat.c: removed NULL
10325         * device/lib/_strncmp.c: removed NULL
10326         * device/lib/_strncpy.c: removed NULL
10327         * device/lib/_strpbrk.c: removed NULL
10328         * device/lib/_strrchr.c: removed NULL
10329         * device/lib/_strspn.c: removed NULL
10330         * device/lib/_strstr.c: removed NULL
10331         * device/lib/_strtok.c: removed NULL
10332         * device/lib/malloc.c: removed NULL, include own header
10333
10334 2003-02-02    <johan AT balder>
10335
10336         * src/mcs51/ralloc.c (packForPush): fixed bug #631653, maybe other ports need this too? At least now some new alerts in SDCCBBlock.c and SDCCicode.c gives an early warning
10337         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10338         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10339         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10340         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10341         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10342
10343 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10344
10345         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10346         area 'DATA'"
10347
10348 2003-02-01    <johan AT balder>
10349
10350         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10351
10352 2003-01-31    <johan AT CP255758-A>
10353
10354         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10355
10356 2003-01-30    <johan AT balder>
10357
10358         * src/SDCCBBlock.c: automatic bug detection
10359         * src/SDCCicode.c: automatic bug detection
10360
10361 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10362
10363         * src/SDCCglobl.h:   now --xram-size 0 works
10364         * src/SDCCmain.c:    now --xram-size 0 works
10365
10366 2003-01-29    <johan AT balder>
10367
10368         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10369
10370 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10371
10372         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10373         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10374         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10375         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10376         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10377         * src/SDCCmain.c:    Added options --xram-size and --code-size
10378
10379 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10380
10381         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10382         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10383
10384 2003-01-27    <johan AT balder>
10385
10386         * src/SDCC.y: fixed bug #613764
10387
10388 2003-01-26    <johan AT balder>
10389
10390         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10391         * src/SDCCsymt.h: fixed bug #673374
10392         * src/SDCCglue.c: fixed bug #661910
10393         * src/SDCCast.c: fixed bug #458099 and 673374
10394
10395 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10396
10397         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10398         * as/mcs51/strcmpi.h: added
10399         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10400         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10401         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10402         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10403         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10404         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10405         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10406         * as/mcs51/Makefile.aslink: new module strcmpi
10407         * as/mcs51/Makefile.asx8051: new module strcmpi
10408         * as/mcs51/Makefil.bcc: new module strcmpi
10409         * as/mcs51/Makefile.in: new module strcmpi
10410         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10411
10412 2003-01-26    <johan AT balder>
10413
10414         * src/SDCCglue.c: reverted back to 1.124
10415         * src/SDCCast.c: reverted back to 1.156
10416         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10417
10418 2003-01-25    <johan AT balder>
10419
10420         * src/SDCCglue.c: A better fix for bug #661910
10421         * src/SDCCast.c: A better fix for bug #661910
10422         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10423
10424 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10425
10426         * src/Makefile.in: remove spawn.o
10427         * src/SDCCmain.c: remove spawn.h
10428         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10429         * src/spawn.c: removed
10430         * src/spawn.h: removed
10431         * support/regression/ports/ds390/spec.mk: link with -r
10432
10433 2003-01-24    <johan AT CP255758-A>
10434
10435         * src/ds390/gen.c (aopOp): fixed bug #667458
10436         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10437         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10438         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10439
10440 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10441
10442         * src/mcs51/peeph.def: better assembler identation by Frieder
10443         * src/mcs51/gen.c: better assembler identation by Frieder
10444
10445 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10446
10447         * as/z80/string.h: removed for gcc 3.2
10448         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10449         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10450
10451 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10452
10453         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10454         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10455         * support/regression/Makefile: separate temp files for ports
10456         * support/regression/generate-cases.py: separate temp files for ports
10457         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10458         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10459
10460 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10461
10462         * moved tinitalk to device/examples/ds390
10463
10464 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10465
10466         * as/mcs51/lkmem.c: rflag is for DS390
10467         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10468         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10469                          (linkEdit): move mem- and map-files the same way as ihx-files
10470         * src/z80/main.c (_setDefaultOptions): removed --generic
10471         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10472         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10473         * src/pic/glue.c (picglue): --c1mode works again
10474         * src/pic16/glue.c (pic16glue): --c1mode works again
10475         * src/asm.c (printCLine): fix #660034
10476
10477 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10478
10479         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10480         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10481         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10482         * as/mcs51/lkmem (summary): better fix for sp problem
10483         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10484         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10485         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10486                                               remove --stack-after-data
10487
10488 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10489
10490         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10491         * src/SDCCutil.c (join): ugly bug: missing '\0'
10492         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10493
10494 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10495
10496         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10497         * src/port.h: typo
10498         * src/pic/main.c (_asmCmd): gpasm supports -o
10499         * src/z80/main.c: more general macros
10500         * device/lib/Makefile.in: remove intermediate files
10501
10502 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10503
10504         * .version: Bumped version number to 2.3.3
10505         * src/SDCCBBlock.c: new option -o
10506         * src/SDCCglobl.h: new option -o
10507         * src/SDCCglue.c: new option -o
10508         * src/SDCCmain.c: new option -o
10509         * src/asm.c: new option -o
10510         * src/ds390/main.c: new option -o
10511         * src/pic/glue.c: new option -o
10512         * src/pic/pcode.c: new option -o
10513         * src/pic/ralloc.c: new option -o
10514         * src/pic16/glue.c: new option -o
10515         * src/pic16/pcode.c: new option -o
10516         * src/pic16/ralloc.c: new option -o
10517         * src/z80/main.c: new option -o
10518         * device/lib/Makefile.in: use -o
10519         * support/regression/ports/ds390/spec.mk: use -o
10520         * support/regression/ports/gbz80/spec.mk: use -o
10521         * support/regression/ports/mcs51/spec.mk: use -o
10522         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10523         * support/regression/ports/z80/spec.mk: use -o
10524         * support/regression/ports/ucz80/spec.mk: use -o
10525         * support/regression/ports/xa51/spec.mk: use -o
10526         * support/regression/fwk/lib/timeout.c: fix usage string
10527
10528 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10529         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10530
10531 2003-01-07    <johan AT balder>
10532
10533         * src/SDCCast.c (decorateType): fixed bug #600035
10534
10535 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10536         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10537         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10538         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10539         * src/pic/pcode.c: outcommented unused variable to remove warnings
10540         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10541
10542 2003-01-06    <karl AT turbobit.com>
10543         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10544    regression tests.
10545
10546 2003-01-06    <johan AT balder>
10547
10548         * src/SDCCicode.c: fixed array add
10549
10550 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10551         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10552         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10553
10554 2003-01-04    <johan AT balder>
10555
10556         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10557
10558 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10559         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10560
10561 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10562         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10563         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10564
10565 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10566         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10567
10568 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10569         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10570
10571 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10572         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10573
10574 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10575
10576     * in \sdcc\as\mcs51\ changed these files in order to create an
10577     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10578     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10579     following files to include the previous two files: aslink.dsp,
10580     Makefile.aslink, Makefile.bcc, and Makefile.in.
10581
10582     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10583     .adb instead of .cdb
10584
10585 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10586
10587         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10588         value from option --iram-size.
10589
10590 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10591
10592         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10593         dram[] array.
10594
10595 2002-09-18    <wiml AT hhhh.org>
10596
10597         * SDCClrange.h: exposed setFromRange() and setToRange()
10598         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10599           packRegsForAccUse() (bug 542397)
10600         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10601           multiple times and emitting the fetch operations more than once
10602           added aopGetUsesAcc() function to allow binary operators to
10603           fetch their operands in the correct order; made genMinus() emit
10604           compact code for X = LITERAL - Y
10605
10606 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10607         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10608         sprintf() in line 1267.
10609
10610 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10611         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10612         like ports.
10613
10614 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10615         Changes to aslink (All the changes are marked with 'JCF'):
10616
10617         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10618         summary().
10619
10620         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10621         area BSEG.  Also moves, if possible, the DATA area down into the internal
10622         ram so more space is available.
10623
10624         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10625         sflag.
10626
10627         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10628         not bytes.  Function summary() which creates a memory usage summary
10629         file with extension .mem.  Reports of overlaping stack and small stack
10630         size.  If the space for the stack is less than 16 bytes aslink trows a
10631         warning.
10632
10633         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10634         the 8051.  Option 'y' for memory summary output file.
10635
10636         Changes to sdcc (All the changes are marked with 'JCF'):
10637
10638         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10639
10640         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10641         overlaying area for it (uses RegBankUsed[4]).
10642
10643         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10644         bank zero as used by default.  By default aslink locates the stack
10645         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10646         the creation of the .mem file.  Delegates the allocation of data area
10647         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10648         the begining of the stack area to aslink.
10649
10650         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10651         glue() in SDCCglue.c creates an area for it.
10652
10653 2002-09-03  Borut Razem <borut.razem AT siol.net>
10654         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10655         sdcc/src/pic/glue.c:
10656         introduced atexit() handler for teporay files removal in case of
10657         errors, assertions, ...
10658
10659 2002-08-29  Borut Razem <borut.razem AT siol.net>
10660         * sdcc/support/cpp2/auto-host_vc_in.h:
10661         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10662         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10663         Maybe there is a similar problem with BORLANDC? It should be checked!
10664
10665         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10666         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10667         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10668         was not executed, and the compiler (cl) launched a warning:
10669         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10670
10671 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10672         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10673
10674 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10675         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10676
10677         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10678           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10679           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10680           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10681           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10682           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10683           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10684         - added Release configuration in VS projects
10685         - review of compiler an linker options
10686         - VC .exe files are generated in bin_vc directory, not to interfere
10687           with binaries generated from other projects (cygwin, mingw, bcc ...)
10688
10689         * sdcc/src/yacc.dsp: added
10690
10691         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10692         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10693         and insert the version number definitions from .version
10694
10695         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10696
10697         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10698         added - genarate auto-host.h using auto-host_vc_in.h as template
10699
10700         * sdcc/sdcc_vc.h,
10701         removed from CVS, generated automatically
10702
10703 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10704         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10705
10706 2002-08-11  Borut Razem <borut.razem AT siol.net>
10707         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10708
10709 2002-08-10  Borut Razem <borut.razem AT siol.net>
10710         * src/SDCCmain.c (main):
10711         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10712         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10713         The consequence was that some temporary files were not removed.
10714
10715         * src/SDCCglue.c:
10716         unification of code in functions tempfilename() and tempfile():
10717         function tempnam() is defined in Visual Studio 6.0 and .NET
10718
10719         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
10720
10721         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10722           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
10723         - removed compiler command line option /WX: Treats all warnings as errors
10724         - update a list of source files, included into the project
10725
10726         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10727           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10728         changed project type to Generic Project so that can be correcly converted to VS.NET project
10729
10730         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10731
10732         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10733
10734         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10735
10736         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10737         added return 0 statements after assert() to make compiler happy
10738
10739         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10740         added newline in the def file to keep MSC compiler satisfied
10741
10742         * sdcc/src/z80/gen.c:
10743         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10744           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10745         - solved MSC error in function aopDump()
10746
10747         * sdcc_vc.h: define PREFIX as "\\sdcc"
10748
10749 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10750         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10751
10752 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10753         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10754         - Rewrote the register banking algorithm.
10755         - Added pCode live-range analysis to registers (for now, only non-used and
10756         singly-used registers optimized away)
10757
10758         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10759
10760         * support/scripts/inc2h.pl Kevin L. Pauba <klpauba AT cox.net> submitted this perl script for converting MicroChip include files into SDCC Pic include files.
10761
10762 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10763         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10764
10765 2002-04-22  Michael Hope  <michaelh AT vroom>
10766
10767         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10768
10769         * configure.in (DD_COPT): Added include support required for gbdk.
10770
10771         * .version: Bumped version number just to increase it.
10772
10773         * src/SDCCmain.c: Added -nostdinc to the default options.
10774
10775 2002-04-15  Michael Hope  <michaelh AT vroom>
10776
10777         * device/lib/z80/printf.c (sprintf): Added.
10778
10779         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10780
10781         * src/z80/peeph.def: Added transpose redundent load rule.
10782
10783         * src/z80/main.c: Added force callee saves for jaune.
10784
10785         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10786
10787         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10788
10789 2002-03-28  Johan Knol  <johan AT balder>
10790
10791         * src/SDCCval.c: fixed bug #532436
10792
10793 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10794         * /src/port.h:
10795         Added "char *Processor" field to the port structure.
10796
10797         * /src/SDCCmain.c:
10798         Added -p option. Allows port dependent processor to be specified.
10799
10800         * all ports:
10801         Initialized the new field char *Processor field to NULL in all ports
10802
10803         * /src/pic/*:
10804         Compiler generated registers for interrupt context saving
10805         were not getting allocated.
10806
10807 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10808
10809         * /src/SDCCast.c:
10810         Fixed left shift. Will promote the left side of a left shift
10811         if a) left shifting more than size of operand or b) when assigned
10812         to something size > size of left side
10813
10814 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10815         * src/pic/*
10816         tons of changes. Register allocation has been
10817         rewritten. Added customization for the various PICs. Flow
10818         analysis is restructured. ...
10819
10820         * src/pic/device.h:
10821         Added
10822
10823         * src/pic/device.c:
10824         Added. device.c is a PIC port hack to accomodate variations
10825         in PIC devices.
10826
10827 2002-03-13  Michael Hope  <michaelh AT vroom>
10828
10829         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10830
10831 2002-03-04  johanknol  <johanknol AT manik>
10832
10833         * /src/SDCCval.c: fixed
10834
10835         const unsigned char arr[][2] = { { 0, 1 } };
10836         t18.c:1: error: Initializer element is not constant
10837
10838 2002-03-04  bela  <bela AT manik>
10839
10840         * /device/include/mcs51reg.h:
10841         ds89c420 register definition update
10842
10843 2002-03-03    <johan AT FRIJA>
10844
10845         * support/Util/SDCCerr.c: did something, but don't no why anymore
10846
10847         * support/regression/tests/bug-524691.c: made it a little less shy
10848
10849         * src/SDCCast.c (decorateType): fixed bug #524697
10850
10851         * src/SDCCast.c: made some lineno improvements
10852
10853         * src/SDCCval.c (getNelements): changed warning to error
10854
10855         * src/SDCCglue.c (printIvalArray): changed warning to error
10856
10857         * src/SDCCicode.c: fixed a warning for mingw
10858
10859         * src/SDCCast.c (decorateType): fixed the << promotion for ops
10860
10861         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
10862
10863 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
10864
10865         * src/ds390/peeph.def:
10866         Added some more peephole rules
10867
10868         * src/ds390/gen.c: Various fixes & enhancements
10869
10870         * src/SDCClrange.c, src/SDCClrange.h:
10871         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
10872
10873         * src/ds390/ralloc.c:
10874         various fixes & enhancements (ds390) specific
10875
10876         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
10877         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
10878         from rallocs.
10879
10880         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
10881
10882 2002-03-02    <johan AT FRIJA>
10883
10884         * src/SDCCast.c (decorateType): fixed bug #524708
10885
10886         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
10887
10888         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
10889
10890 2002-03-01  Michael Hope  <michaelh AT vroom>
10891
10892         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
10893
10894         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
10895
10896 2002-03-01    <johan AT FRIJA>
10897
10898         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
10899
10900         * src/SDCCast.c (decorateType): fixed bug #524209
10901
10902         * src/SDCCval.c (valNot): fixed bug #524195
10903
10904 2002-02-26    <johan AT balder>
10905
10906         * src/xa51/gen.c: fixed a warning
10907
10908         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
10909
10910         * src/SDCCast.c (decorateType): fixed bug #522534
10911
10912 2002-02-23    <johan AT balder>
10913
10914         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
10915
10916 2002-02-22    <johan AT balder>
10917
10918         * src/SDCCast.c: fixed bug #514865
10919
10920         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
10921
10922 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
10923
10924         * sdcc/src/SDCCloop.c:
10925         Previous fix was not good. basic blocks that have "break" or "return" are
10926         not really partof a loop , but live ranges used in these blocks should
10927         be live thru the entire loop, so set partOfLoop but don't add them to
10928         loop region
10929
10930 2002-02-21    <johan AT FRIJA>
10931
10932         * src/SDCCcse.c: fixed bug #514308
10933
10934 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
10935
10936         * src/SDCCloop.c:
10937         Fixed BUG #519583. If a conditional block ended in a return/break
10938         statement inside a loop, it was not being considered part of the loop.
10939
10940         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
10941
10942 2002-02-10  Karl Bongers <karl AT turbobit.com>
10943
10944         * debugger/*:
10945         Fixed up SDCDB debugger somewhat.  Updated debugger/README
10946         with lots of comments and notes.
10947
10948         * device/examples/test2.c:
10949         Fix bug, "red" variable not being initialized(compiler complained).
10950
10951         * device/examples/Makefile, examples/test3.c:
10952         Add Makefile in device/examples folder, compiles test3.c
10953         for use as a multiple module SDCDB test case.
10954
10955         * sim/ucsim/cmd.src/cmdset.cc:
10956         Took out debug printfs in ucsim "next" command.
10957
10958         * sim/ucsim/xa.src:
10959         Karl and Johan start ucsim XA support.  Most dissassembly working,
10960         about 75% emulation done(plenty of work remaining).
10961
10962         * sim/ucsim/z80.src:
10963         Add Z80 support to ucsim, add test-ucz80 regression test,
10964         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
10965         Notice z80 compiler fails on examples/test3.c/crc code.
10966
10967 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
10968
10969         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
10970         Added support for --parms-in-bank1
10971
10972         * src/ds390/peeph.def:
10973         added a few more peephole optimzations
10974
10975         * src/ds390/main.c:
10976         1) added __builtin_inp & __builtin_outp used to read in data of given length
10977            from a memory mapped port
10978         2) added __builtin_memcmp
10979         3) added __builtin_swapw swap bytes of a short
10980
10981         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
10982         1) handle multiple send & receives from register bank1
10983         2) ralloc can now allocate DPTR1 to some liveRanges
10984
10985         * src/SDCCsymt.c, src/SDCCsymt.h:
10986         changes to handle multiple sends & receives
10987
10988         * src/SDCCptropt.h:
10989         added some pointer arithmetic optimization
10990
10991         * src/SDCCptropt.c:
10992         added some pointer arithmetic optimizations but not stable yet so not
10993         called from anywhere (will get this working shortly)
10994
10995         * src/SDCCopt.c: fixed for multiple sends & receives
10996
10997         * src/SDCCmain.c:
10998         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
10999         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
11000            set preprocessor defines (depending on options)
11001
11002         * src/SDCCicode.c, src/SDCCicode.h:
11003         changes made to handle multiple sends & receives
11004
11005         * src/SDCCglobl.h:
11006         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
11007
11008         * src/SDCCcse.c, src/SDCCcse.h:
11009         added function findbackward def (to be used in upcoming optimization)
11010
11011         * src/SDCCcflow.c, src/SDCCcflow.h:
11012         added function returnAtEnd - to determine if a basic block terminates with
11013         a RETURN iCode
11014
11015         * src/SDCCast.c, src/SDCCast.h:
11016         added option parms-in-bank1
11017
11018         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
11019         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
11020         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
11021         adjusted for --parms-in-bank1 option
11022
11023         * device/include/string.h:
11024         donot redefine "reentrant" keyword
11025
11026         * device/include/ds80c390.h: Added some more SFRs
11027
11028 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
11029
11030         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
11031
11032 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
11033
11034         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
11035
11036 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
11037
11038         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
11039
11040 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
11041
11042         * Added --xram-movc option
11043
11044 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
11045
11046         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
11047
11048 2002-01-11  Johan Knol
11049
11050         * Added math lib of Jesus Calvino-Fraga
11051
11052 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
11053
11054         * src/SDCCmain.c (processFile): fix processing of ../../src.c
11055         * support/regression/Makefile: new target test-mcs51-stack-auto
11056         * support/regression/ports/mcs51-stack-auto/spec.mk: added
11057
11058 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11059
11060         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
11061
11062 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11063
11064         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
11065
11066 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
11067
11068         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
11069
11070         * src/SDCCglue.h: add definition for printIvalChar()
11071
11072 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11073
11074         * src/SDCCast.c: fix #498138 by Johan
11075
11076         * src/SDCCglue.c: fix #498138 by Johan
11077
11078 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11079
11080         * support/regression/Makefile: fix clean
11081
11082         * support/regression/ports/ds390/support.c: fix transmission of last character
11083
11084 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
11085
11086         * /sdcc/src/ds390/gen.c:
11087         a) improved computing address of stack variable
11088         b) took out some #if 0 code
11089         c) improved parmBytes adjustment
11090         d) improved genPlusIncr & genMinusIncr
11091         e) genCmp could generate bad code (when left assigned to DPTR)
11092         f) Fixed bug in hasInc
11093
11094         * /sdcc/src/ds390/ralloc.c:
11095         a) packRegsForSupport could mess up live information (Fixed)
11096         b) packRegsDPTRuse could be incorrect for left & right shift
11097
11098         * /sdcc/src/mcs51/ralloc.c:
11099         packRegsForSupport could mess up the live information (Fixed)
11100
11101         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
11102
11103         * /sdcc/src/SDCCast.c:
11104         can reverse a loop even if function call is present as long
11105         as the loop control variable is local & is not passed as parameter
11106
11107 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11108
11109         * /sdcc/ChangeLog: *** empty log message ***
11110
11111         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
11112         More builtin function additions for TININative
11113
11114         * /sdcc/src/ds390/ralloc.c:
11115         Had broken the regression testsuite
11116
11117         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
11118
11119         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
11120         Added funcattr hasStackParms will be set for reentrant functions when there
11121         are paramteres on the stack, this helps in minimizing frame pointer generation
11122         typeFromStr can handle function pointers now
11123
11124         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
11125         *** empty log message ***
11126
11127 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11128
11129         * /src/ds390/gen.c, /src/ds390/main.c:
11130         More builtin function additions for TININative
11131
11132         * /src/ds390/ralloc.c:
11133         Had broken the regression testsuite
11134
11135         * /src/SDCCast.c: Fixed a bug in dumptree
11136
11137         * /src/SDCCsymt.c, /src/SDCCsymt.h:
11138         Added funcattr hasStackParms will be set for reentrant functions when there
11139         are paramteres on the stack, this helps in minimizing frame pointer generation
11140         typeFromStr can handle function pointers now
11141
11142         * /doc/builtins.txt, /doc/TININative.txt:
11143         *** empty log message ***
11144
11145
11146 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11147
11148         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
11149         ALPHA version for -mTININative
11150
11151         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
11152         updated to reflect changes in the port structure
11153
11154         * /src/port.h:
11155         added function do_assemble (similar to do_link) if non-null this function
11156         will be called to do assembly (-mTININative) requires a multi command
11157         assembly
11158         added function genAssemblerEnd will be called to generate assembler Epilogue
11159
11160         * /src/SDCCsymt.c:
11161         added _JavaNative to debug info printing
11162
11163         * /src/SDCCmain.c: added option --tini-libid
11164         added port->do_assemble function (-mTININative) has a multi command assemble
11165
11166         * /src/SDCCglue.c: Disabled "constExpr" check
11167         added port->genAssemblerEnd function
11168
11169         * /src/SDCCglobl.h: Added option --tini-libid value
11170
11171         * /src/SDCCast.h:
11172         tookout optimizeCompare from the header (has no external references)
11173
11174         * /src/SDCCast.c: made one more function "static"
11175
11176 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
11177
11178         * src/z80/mappings.i: Added z80asm support.
11179
11180         * src/z80/main.c: Added z80asm support on --asm=z80asm
11181
11182         * src/z80/gen.c: Fixed asm portability issues.
11183
11184         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
11185
11186         * src/SDCCglue.c (printExterns): Added global/extern split.
11187
11188 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
11189
11190         * support/regression/Makefile: added test for mcs51 model large
11191
11192         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
11193
11194         * support/regression/ports/gbz80/spec.mk: added -mgbz80
11195
11196 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
11197
11198         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
11199
11200 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
11201
11202         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
11203
11204         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
11205
11206 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
11207
11208         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
11209
11210         * support/regression/tests/simplefloat.c: Port to mcs51.
11211
11212 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
11213         * support/regression/tests/bug-485362.c: Added.
11214
11215         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
11216
11217         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
11218
11219         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
11220
11221         * src/z80/gen.c (aopDump): Added a dump function.
11222
11223 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
11224         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
11225
11226         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
11227
11228         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
11229
11230         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
11231
11232         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
11233
11234         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
11235
11236         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
11237
11238         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
11239
11240         * support/regression/ports/ds390/support.c: Use tinibios.
11241
11242         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
11243
11244 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
11245
11246         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
11247         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
11248
11249         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
11250
11251         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
11252
11253 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
11254
11255         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
11256
11257         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
11258         (packRegsForIYUse): Created and optimised.
11259
11260 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11261
11262         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
11263 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
11264
11265         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
11266
11267         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
11268
11269         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
11270
11271 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11272
11273         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
11274
11275         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
11276
11277 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11278
11279         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
11280
11281         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
11282
11283         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
11284
11285 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11286
11287         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
11288         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
11289         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
11290
11291         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
11292
11293         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
11294         (genNotFloat): Added.
11295         (genUminusFloat): Added.
11296
11297         * device/lib/z80/Makefile: Added floating pt stubs.
11298
11299         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11300
11301         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11302
11303         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11304
11305 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11306
11307         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11308
11309         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11310
11311         * sdcc/support/regression/Makefile: Add port ds390.
11312
11313         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11314
11315         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11316
11317         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11318
11319         * sdcc/support/regression/ports/ds390/support.c: Added.
11320
11321         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11322
11323         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11324
11325         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11326
11327 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11328
11329         * device/include/malloc.h: Added z80 and gbz80 support.
11330
11331         * device/lib/gbz80/heap.s: Added.
11332
11333         * device/lib/z80/heap.s: Added.
11334
11335         * device/lib/malloc.c: Added z80 and gbz80 support.
11336
11337         * support/regression/tests/malloc.c (testMalloc): Added.
11338
11339         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11340
11341         * support/regression/tests/bug-478094.c: Added.
11342
11343         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11344
11345 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11346
11347         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11348
11349         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11350
11351         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11352
11353         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11354
11355         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11356
11357 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11358
11359         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11360
11361 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11362
11363         * support/regression/tests/bug-477927.c: Added.
11364
11365         * src/z80/peeph.def: Added minor rules.
11366
11367         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11368
11369         * src/z80/peeph.def: Added jump optimisation modification.
11370
11371 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11372
11373         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11374
11375 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11376
11377         * support/regression/tests/funptrs.c: Added.
11378
11379 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11380
11381         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11382
11383 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11384
11385         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11386
11387         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11388
11389         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11390         (movLeft2ResultLong): Created.
11391
11392         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11393         (joinPushes): Added.  Joins two char pushes into a word push.
11394
11395 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11396
11397         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11398
11399         * support/makebin/Makefile (install): Added creation of dest dir.
11400
11401 2001-10-24 Karl Bongers <karl AT turbobit.com>
11402
11403         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11404
11405 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11406
11407         * src/z80/ralloc.c: Turned off faulty pack for one use.
11408
11409         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11410
11411         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11412
11413 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11414
11415         * support/regression/Makefile: Improved clean
11416
11417         * support/regression/ports/gbz80/spec.mk: Added clean
11418
11419         * support/regression/ports/host/spec.mk: Added clean
11420
11421         * support/regression/ports/z80/spec.mk: Added clean
11422
11423         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11424
11425         * support/regression/ports/mcs51/timeout.c: little improvements
11426
11427 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11428
11429         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11430
11431         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11432
11433         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11434
11435 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11436
11437         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11438
11439         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11440
11441 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11442         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11443
11444         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11445
11446         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11447
11448         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11449
11450         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11451
11452         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11453
11454         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11455
11456         * support/regression/tests/longor.c: Added.
11457
11458 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11459
11460         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11461
11462         * as/mcs51/aslink.h: define PATH_MAX
11463
11464         * as/mcs51/asm.h: define PATH_MAX
11465
11466         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11467
11468         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11469
11470         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11471
11472         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11473
11474         * src/SDCCglobl.h: define PATH_MAX
11475
11476         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11477
11478         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11479
11480 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11481
11482         * src/z80/gen.c (gencjneshort): Fixed
11483
11484         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11485
11486 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11487
11488         * support/regression/tests/bug-469671.c: Added.
11489
11490         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11491
11492 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11493
11494         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11495
11496         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11497
11498 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11499
11500         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11501
11502         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11503
11504         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11505
11506         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11507
11508         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11509
11510         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11511
11512         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11513
11514 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11515
11516         * src/z80/gen.c (setupPair): Added 'extended stack' support for the z80.  Can now have local variables or parameters of more than 127 bytes in size.  Increadibly slow, but it will work.  Currently anything involving the carry flag.
11517
11518         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11519
11520         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11521
11522 2001-10-07    <johan AT FRIJA>
11523
11524         * device/lib/gets.c (gets): fixed the return value.
11525
11526 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11527         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11528
11529         * src/SDCCpeeph.c (peepHole): Fixed all leaks.  Added trace support for freeing lines.  Optimised restart logic to re-run instead of restart.  Now compiles dscan.c on ~60MB instead of ~200MB.
11530
11531         * support/Util/NewAlloc.c: Added ability to use libgc instead of malloc.  Added Safe_free and Safe_strdup.  Added trace support where you can log allocations and free all at once.
11532
11533         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11534
11535         * src/pic/gen.c: Removed Safe_strdup.
11536
11537         * configure.in: Added option to enable libgc support.
11538
11539         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11540         (bitVectUnion): Optimised.
11541         (bitVectIntersect): Optimised.
11542         (bitVectBitsInCommon): Optimised.
11543         (bitVectCplAnd): Optimised.
11544
11545         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11546
11547 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11548
11549         * src/SDCCmain.c: distinguish between assembler debug and plain options
11550
11551         * src/avr/main.c:   remove standard assembler options
11552
11553         * src/ds390/main.c: remove standard assembler options
11554
11555         * src/mcs51/main.c: remove standard assembler options
11556
11557         * src/port.h: removed "PENDING" comment
11558
11559 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11560
11561         * src/device/lib/_mulint.c  : new, with assember functions
11562
11563         * src/device/lib/_mullong.c : new, with assember functions
11564
11565         * src/device/lib/_divuint.c : with assember functions
11566
11567         * src/device/lib/_divsint.c : with assember functions
11568
11569         * src/device/lib/_divulong.c: with assember functions
11570
11571         * src/device/lib/_divslong.c: with assember functions
11572
11573         * src/device/lib/_moduint.c : with assember functions
11574
11575         * src/device/lib/_modsint.c : with assember functions
11576
11577         * src/device/lib/_modulong.c: with assember functions
11578
11579         * src/device/lib/_modslong.c: with assember functions
11580
11581         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11582
11583         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11584
11585         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11586                                       replaced _mululong.c and _mulslong.c by _mullong.c
11587
11588 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11589
11590         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11591
11592 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11593
11594         * src/SDCCglue.c: test, if win32api is available for MINGW
11595
11596 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11597
11598         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11599         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11600         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11601         * support/regression/ports/host/spec.mk: removed GENERIC
11602         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11603         * support/regression/ports/z80/spec.mk: removed GENERIC
11604
11605 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11606
11607         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11608
11609         * support/regression/tests/bug-467035.c: Created.
11610
11611 2001-10-01    <johan AT FRIJA>
11612
11613         * src/SDCC.y: fixed bug #466586 part 1
11614
11615 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11616
11617         * SDCCicode.c: z80 has no generic pointers
11618         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11619
11620 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11621
11622         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11623
11624 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11625
11626         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11627
11628         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11629
11630 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11631
11632         * configure.in: Fixed up so that ucsim is only configured once.
11633
11634         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11635
11636         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11637         (getPathDifference): As above.
11638
11639         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11640
11641         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11642
11643 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11644         * .version: Updated to 2.3.1
11645
11646         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11647         Added copyright header.
11648
11649         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11650         (assemble): Added support for macro based assembler commands.
11651         (linkEdit): Added support for macro based linker commands.
11652         (preProcess): Changed the pre-processor to use macros.
11653         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11654         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11655
11656         * device/lib/z80/crt0.s: Added module name for debugging.
11657
11658 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11659
11660         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11661
11662         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11663
11664         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11665
11666         * src/Makefile.in: Added SDCCmacro and SDCCutil
11667
11668 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11669
11670         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11671
11672 2001-09-16    <johan AT FRIJA>
11673
11674         * support/Util/SDCCerr.c: fixed up the error/warning/info database. I only changed the E_ W_ I_ prefix to what SDCCerr.c says it is.
11675
11676 2001-09-15    <johan AT FRIJA>
11677
11678         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11679         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11680
11681 2001-09-11    <johan AT FRIJA>
11682
11683         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11684
11685 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11686
11687         * support/regression/tests/bug-460444.c: Added test case.
11688
11689         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11690         (genCast): Added justification for all of the asserts.
11691
11692 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11693
11694         * support/regression/support.c: _xdata replaced by xdata
11695
11696         * support/regression/spec.mk: removed _generic
11697
11698 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11699
11700         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11701
11702         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11703         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11704
11705         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11706
11707         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11708
11709         * support/regression/tests/bug-460010.c: Added test case.
11710
11711         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11712
11713 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11714
11715         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11716
11717         * support/regression/testfwk.c: removed workaround for bug #436344
11718
11719         * support/regression/tests/bp.c: use less memory with mcs51
11720
11721         * support/regression/tests/bug-441448.c: use less memory
11722
11723         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11724
11725         * support/regression/collate-results.py: typo
11726
11727 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11728
11729         * support/regression/tests/fetchoverlap.c: Added new test case.
11730
11731         * support/regression/tests/bp.c: Added new test case.
11732
11733         * support/regression/tests/bug-448984.c: Added new test case.
11734
11735         * support/regression/tests/pow2shifts.c: Added new test case.
11736
11737         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11738         (genlshTwo): Fixed right shift for count > 8.
11739
11740         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11741
11742 2001-09-08    <johan AT FRIJA>
11743
11744         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11745
11746 2001-09-07    <johan AT FRIJA>
11747
11748         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11749
11750         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11751
11752 2001-09-06    <johan AT FRIJA>
11753
11754         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11755         * bernhard noted me at this: "() equals to (void)" (1.38)
11756
11757 2001-09-05    <johan AT FRIJA>
11758
11759         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11760
11761 2001-09-04    <johan AT FRIJA>
11762
11763         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11764
11765
11766 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11767
11768         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11769
11770 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11771
11772         * link/z80/aslink.h: Fixed path for PATH_MAX
11773
11774 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11775
11776         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11777
11778         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11779
11780         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11781
11782         * src/z80/gen.c (genUminus): Fixed add, sub, and uminus on the gbz80 port for longs.  Had to shift some functions about to do it.
11783
11784 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11785
11786         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11787         (genCmp): Fixed up genCmp for the GB with longs.
11788
11789         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11790
11791         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11792
11793         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11794
11795         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11796
11797 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11798
11799         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11800
11801 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11802
11803         * device/lib/gbz80/crt0.s (init): Fixed up support for the gbz80 such that it will at least run (and fail badly) the regression tests.
11804
11805         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11806
11807 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11808
11809         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11810
11811         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11812
11813 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11814
11815   * sim/ucsim/configure:    little improvement of Cygwin-detection
11816   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11817   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11818   * support/regression/tests/bug-221100.c: small changes for mcs51
11819   * support/regression/tests/bug-221168.c: small changes for mcs51
11820   * support/regression/tests/bug-227710.c: small changes for mcs51
11821   * support/regression/tests/staticinit.c: small changes for mcs51
11822   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11823   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11824   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11825
11826 $Revision$