* doc/knownbugs.html: removed [ 1520966 ] from the list
[fw/sdcc] / ChangeLog
1 2006-07-26 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * device/lib/pic/libsdcc/fsdiv.c,
4         * device/lib/pic/libsdcc/fsmul.c,
5         * device/lib/pic16/libsdcc/float/fsdiv.c,
6         * device/lib/pic16/libsdcc/float/fsmul.c,
7         * device/lib/_fsdiv.c,
8         * device/lib/_fsmul.c: bugfix, handle too large and too small numbers
9         * support/regression/tests/bug1520966.c: added
10         * doc/knownbugs.html: removed [ 1520966 ] from the list
11
12 2006-07-25 Borut Razem <borut.razem AT siol.net>
13
14         * configure.in, configure, sdccconf_in.h: fixed bug
15           [ 1519095 ] regression test onebyte.c fails on ppc64 host
16         * doc/knownbugs.html: removed [ 1519095 ] from the list
17
18 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
19
20         * doc/knownbugs.html: added, contains list of known bugs at release
21         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
22
23 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
24
25         * device/include/mcs51/compiler.h: added SFRX for xdata based special
26           function registers and corrected defaults with additional warning
27         * device/lib/malloc.c: cosmetic changes
28         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
29         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
30           (fillGaps): and used it
31
32 2006-07-20 Raphael Neider <rneider AT web.de>
33
34         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
35           output unless SDCCPICDEBUG is set
36         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
37           output if SILENT is set
38
39 2006-07-11 Borut Razem <borut.razem AT siol.net>
40
41         * doc/README.txt: updated
42
43 2006-07-10 Borut Razem <borut.razem AT siol.net>
44
45         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
46           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
47           in WIN32 installation
48         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
49           release candidate 1
50
51 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
52
53         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
54         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
55
56 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
57
58         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
59
60 2006-07-06 Borut Razem <borut.razem AT siol.net>
61
62         * support/regression/tests/bitfields.c:
63           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
64         * support/regression/tests/constantRange.c:
65           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
66
67 2006-07-04 Borut Razem <borut.razem AT siol.net>
68
69         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
70           src/port.mk,
71           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
72           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
73           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
74           reverted changes from 2006-07-03
75         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
76         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
77           added CPPFLAGS, used by the host port
78
79 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
80
81         * support/regression/valdiag/tests/switch.c,
82         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
83         * support/regression/tests/libmullong.c: fixed for host
84         * support/regression/ports/host/spec.mk: disable all warnings for host,
85         SDCC runs with --less-pedantic too
86
87 2006-07-03 Borut Razem <borut.razem AT siol.net>
88
89         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
90           defined CPPFLAGS
91         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
92         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
93           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
94           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
95           include ../port.mk
96         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
97           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
98           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
99           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
100
101 2006-07-02 Raphael Neider <rneider AT web.de>
102
103         * src/pic16/devices.inc,
104         * device/include/pic16/pic18fregs.h,
105         * device/include/pic16/pic18f4550.h,
106         * device/lib/pic16/pics.all,
107         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
108
109 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
110
111         * as/hc08/lkaomf51.c (OutputName),
112         * as/mcs51/lkaomf51.c (OutputName),
113         * as/z80/asmain.c (asmbl),
114         * src/ds390/main.c (asmLineNodeFromLineNode),
115         * src/hc08/ralloc.c (hc08_assignRegisters),
116         * src/mcs51/main.c (asmLineNodeFromLineNode),
117         * src/xa51/ralloc.c (checkRegMask),
118         * src/xa51/gen.c (emitcode),
119         * src/z80/gen.c (_emit2),
120         * src/SDCCast.c (searchLitOp),
121         * src/SDCCglobl.h,
122         * support/packihx/packihx.c,
123         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
124         * src/ds390/gen.c (aopPutUsesAcc),
125         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
126         * support/regression/tests/libmullong.c (mullong_wrapper),
127         * src/SDCCsymt.c (powof2),
128         * src/SDCCast.c,
129         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
130         * src/SDCCsymt.h: added TYPE_TARGET_*
131         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
132         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
133         SDCCast because 1) header problems 2) this is the right place
134         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
135         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
136         prototype
137
138 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
139
140         * src/SDCCicode.h: removed buggy semicolon in unused macro
141         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
142         search for previous definiton of auto symbols too,
143         (findPrevUse): fixed logic of emitWarnings
144
145 2006-06-26 Raphael Neider <rneider AT web.de>
146
147         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
148           PCLATH and PCLATU on interrupts, potentially fixes #1505141
149
150 2006-06-25 Raphael Neider <rneider AT web.de>
151
152         * device/lib/pic/libm: NEW, added math library functions
153         * device/lib/pic/libsdcc: NEW; added float support functions
154         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
155         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
156           NEW, added math related headers
157         * device/include/asm/pic/features.h: NEW
158         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
159           (popGet): allow larger offsets for AOP_PCODE,
160           (genDataPointerSet): handle literals explicitly, more debug output,
161           (genAssign): fixed for float using aopLiteral ;-)
162         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
163           GOTO initialisation routine
164         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
165           flag on registers, fixes #1469043 (local variables do not work)
166         * src/pic/main.c (_pic14_do_link),
167         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
168           available
169
170 2006-06-25 Borut Razem <borut.razem AT siol.net>
171
172         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
173           characters printed (not including the trailing '\0' used to end
174           output to strings). Problem detected in regression test bug-927659.c.
175           NOTE: printf() family functions should return int instead
176           unsigned int!
177         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
178           specifier are printed as themselves
179         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
180           support flags, width and precision specifiers
181
182 2006-06-24 Borut Razem <borut.razem AT siol.net>
183
184         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
185           to the list of sdcc tagrets not supporting bit type
186         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
187           testfor pic16 due to bug:
188           [ 1511794 ] pic16: regression test bug-895992.c fails
189
190 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
191
192         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
193         * src/SDCCglue.c (initPointer), fixed bug 1496419
194         * support/regression/tests/bug1496419.c: new, added
195
196 2006-06-22 Borut Razem <borut.razem AT siol.net>
197
198         * support/regression/ports/pic16/support.c: use gpsim usart module from
199           libgpsim_modules library
200
201 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
202
203         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
204         IP0H to IPH0.
205
206 2006-06-19 Raphael Neider <rneider AT web.de>
207
208         * src/pic/glue.h,src/pic16/glue.h: added prototypes
209         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
210           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
211           (pic14printExterns,pic14printPublics,pic16printPublics,
212           pic16_printExterns): use new functions to emit symbols
213           (picglue,pic16glue): emit publics before emitting externs
214         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
215           locally defined functions to avoid bug #1443651
216         * support/regression/tests/bug-716242.c: removed pic16 workaround
217         * support/regression/ports/pic16/spec.mk: ignore errors during build
218
219 2006-06-19 Raphael Neider <rneider AT web.de>
220
221         * src/pic/glue.h: added pic14aopLiteral prototype
222         * src/pic/glue.c (pic14aopLiteral): return unsigned int
223         * src/pic/gen.c: removed stdint.h dependency
224           (aopGet): use Safe_strdup()
225           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
226           (genDataPointerSet): use pic14aopLiteral()
227         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
228           for pic16; thanks to Bernhard and Maarten
229
230 2006-06-18 Borut Razem <borut.razem AT siol.net>
231
232         * support/regression/tests/structflexarray.c: flexible array members
233           not supported by gcc < 3
234         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
235           GUI tool by default
236         * src/pic/gen.c: don't include [p]strdin.h on solaris
237         * support/Util/pstdint.h: addad svn attributes
238         * support/regression/tests/constantRange.c,
239           support/regression/tests/rotate.c: include inttypes.h instead
240           stdint.h on solaris, addad svn attributes
241
242 2006-06-18 Raphael Neider <rneider AT web.de>
243
244         * src/SDCCsymt.c (initCSupport): change return type of divschar to
245           int for PIC16
246         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
247           (pic16_genMinusBits): simplified sign-extension
248           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
249             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
250             adjusted to correctly handle mixed-signed operands, disabled
251             now unused multiplciation routines
252         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
253           (assignResultValue): added argument denoting the size of the result
254             as returned by the function (fixes upcasts in assigning from
255             function calls: char foo(); int i = foo();)
256           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
257             function result to assignResultValue
258           (genMult): disabled inlined multiplication code
259           (genDiv): augmented to also handle the modulus operator, fixed to
260             handle mixed-signed operands correctly
261           (genMod): simply call genDiv, disabled unused code
262           (genAssign): fixed missing (sign-)extension on result
263         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
264             valid char operands, allow signed operands for native code, added
265             division and modulo operator handling
266         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
267
268         As a consequence, onebyte.c (if split into two files) and muldiv.c
269         pass regression tests.
270
271 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
272
273         * doc/Makefile.in: two runs of makeindex seem needed to get
274         correct page references in the index of sdccman.pdf
275         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
276
277 2006-06-17 Borut Razem <borut.razem AT siol.net>
278
279         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
280
281 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
282
283         * doc/sdccman.lyx: updated, added (porting source code, debugging),
284         mentioned ec2drv and paulmon
285
286 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
287
288         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
289           consecutive abs areas
290           (find_empty_space, allocate_space): added map to handle codemap or
291            xdatamap,
292           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
293            absolute idata and xdata
294         * as/mcs51/lkmem.c (summary2): updated legend
295
296 2006-06-16 Raphael Neider <rneider AT web.de>
297
298         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
299
300 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
301
302         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
303           1208515
304         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
305
306 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
307
308         * src/port.h (struct PORT): added field gp_tags, to hold the tag
309         value of generic pointers,
310         * src/avr/main.c,
311           src/ds390/main.c,
312           src/hc08/main.c,
313           src/izt/i186.c,
314           src/izt/tlcs900h.c,
315           src/mcs51/main.c,
316           src/pic/main.c,
317           src/pic16/main.c,
318           src/xa51/main.c,
319           src/z80/main.c: PORT structure, added elements for gp_tags field,
320         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
321         fields in the PORT structure of each port,
322         * src/SDCCast.c (decorateType): allow processing of generic pointers
323         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
324         S_FIXED symbols
325
326 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
327
328         * link/z80/lkgb.c,
329         * link/z80/lkgg.c,
330         * src/pic16/gen.c,
331         * src/pic16/main.c,
332         * src/pic16/pcode.c,
333         * src/pic/main.c,
334         * src/pic/pcoderegs.c,
335         * src/SDCCicode.c,
336         * src/SDCCmain.c,
337         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
338           bug 1504689 on minGW
339
340 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
341
342         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
343
344 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
345
346         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
347
348 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
349
350         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
351           for optimization
352
353 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
354
355         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
356         to a char variable. Fixed bug #1504211
357         * device/include/pic16/adc.h,
358         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
359         and fixed bug #1364390
360
361 2006-06-10 Borut Razem <borut.razem AT siol.net>
362
363         * CVSROOT: removed the CVS left-over
364
365 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
366
367         * as/hc08/asmain.c (asexit),
368         * as/hc08/lkmain.c (lkexit),
369         * as/mcs51/asmain.c (asexit),
370         * as/mcs51/lkmain.c (lkexit),
371         * src/SDCCglue.c (DEFSETFUNC),
372         * src/SDCCmain.c (linkEdit, assemble),
373         * support/librarian/sdcclib.c (AddRel),
374           replaced unlink() by standard C remove()
375         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
376         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
377           gatherImplicitVariables): new, added to fix bug 608752,
378           (createFunction): added gatherImplicitVariables()
379         * src/SDCCast.h: added createRMW prototype
380         * src/SDCCsymt.h (struct symbol): added infertype
381         * support/regression/tests/bug608752.c: new, added
382
383 2006-06-10 Raphael Neider <rneider AT web.de>
384
385         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
386           multibyte dummy reads (fixes #1503234)
387
388 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
389
390         * device/include/mcs51/compiler.h: new, added header file to enable
391           creating common sfr definition header files for different compilers
392
393 2006-06-05 Raphael Neider <rneider AT web.de>
394
395         * src/pic16/{pcode.h,genarith.c}:
396           introduced pCodeOp combining any two pCodeOps (previously only
397           two register operands could be combined), removed pcop2 from
398           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
399         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
400         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
401           rewritten to use new PO_TWO_OPS
402         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
403         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
404           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
405           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
406           (pic16_get_op): embraced return arg to allow #define return(x),
407             added new case for combined opcodes
408           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
409           (pic16_pCode2str,pic16_getRegFrompCodeOp,
410            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
411
412 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
413
414         * src/SDCCval.c (checkConstantRange): added
415         * src/SDCCval.h: added checkConstantRange
416         * support/Util/SDCCerr.c,
417         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
418         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
419         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
420         * src/SDCCast.c (decorateType): added checkConstantRange,
421         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
422         can be emitted with the correct always true/false warning,
423         added optimization for double '!';
424         result of decorateType() must be assigned back to the tree, because
425         decorateType() can change the tree
426         * src/SDCCicode.c (geniCodeLogic),
427         (geniCodeAssign): replaced new checkConstantRange, added warnings,
428         (checkConstantRange): removed, it was only a fragment which never
429         emitted a warning
430         * src/SDCCsymt.c (computeType): fixed promotion for
431         "-1 < (unsigned bit) b"
432         * src/pic/ralloc.c (packRegsForAssign),
433         * src/pic16/ralloc.c (packRegsForAssign),
434         * src/hc08/ralloc.c (packRegsForAssign),
435         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
436         from mcs51
437         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
438         * support/regression/tests/constantRange.c: added
439         * support/valdiag/tests/constantRange.c: added
440         * support/valdiag/valdiag.py: added -DPORT_HOST=1
441
442 2006-06-02 Borut Razem <borut.razem AT siol.net>
443
444         * support/regression/ports/pic16/support.c: increase stack size
445           to 255 bytes
446         * support/regression/Makefile.in: sort tests by name so that the
447           resutlts can be compared on different machines / platforms
448
449 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
450
451         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
452         * src/ds390/gen.c (emitLabel): new, added,
453           (genDjnz): fixed stack overflow bug,
454           (throughout): cosmetic changes to sync with mcs51/gen.c,
455           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
456         * src/mcs51/gen.c (genEndFunction): small optimization,
457           (throughout): cosmetic changes to sync with ds390/gen.c
458
459 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
460
461         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
462           (_print_format): fixed printing pointers
463         * src/mcs51/gen.c (emitLabel, movb): new, added,
464           (genAssign): small optimization,
465           (genDjnz): fixed stack overflow bug,
466           (throughout): replaced sprintf with SNPRINTF,
467           replaced mcs51_regWithIdx with REG_WITH_INDEX,
468           replaced emitcode("mov", "b,...") with MOVB(...),
469           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
470           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
471         * src/mcs51/peeph.def: added rules 140 and 264
472         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
473           so they may get optimized into registers
474
475 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
476
477         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
478           immediately when encountered,
479           (printUsage): always use stderr even on windows
480
481 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
482
483         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
484         (processParms): fixed bug #1247551
485         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
486         parseCmdLine, main): print '--version' to stdout,
487         print 'help' to stdout if --help is given,
488         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
489         arguments are given; fixed --help
490
491 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
492
493         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
494         * support/regression/tests/bug-1493710.c: added
495
496 2006-05-27 Borut Razem <borut.razem AT siol.net>
497
498         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
499           static instead auto
500         * support/regression/ports/pic16/support.c: increase stack size
501           from default 64 bytes to 128 bytes
502         * support/regression/tests/staticinit.c,
503           support/regression/tests/float.c: regression tests fully enabled
504           for pic16 port by putting the initialized data arrays into the code
505           section
506         * support/regression/ports/pic16/spec.mk: don't link default libraries.
507           This was changed by mistake in the previous version.
508
509 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
510
511         * src/pic16/gen.c (genFunction, genEndFunction): some
512         beautifications, fixed bug with falsely restoring FSR2 in large
513         stack model, thanks to Beau E. Cox for reporting the bug
514
515 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
516
517         * debugger/mcs51/break.c,
518         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
519           use %p to print pointers, made address variables unsigned
520         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
521         * debugger/mcs51/symtab.c (parseSymbol): must return something
522         * src/mcs51/gen.c (aopForSym): small optimization,
523            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
524           (freeAsmop): added missing break,
525           (aopPut): removed parameter bvolatile, determine it inside the function,
526           (saveRegisters, unsaveRegisters): small optimization,
527           (genIpush): removed pointless check,
528           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
529           replaced sprintf with SNPRINTF,
530           replaced strcpy with strncpyz,
531           updated aopPut calls,
532           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
533         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
534
535 2006-05-24 Borut Razem <borut.razem AT siol.net>
536
537         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
538           modification of test for the pic16 port, put the array to the code
539           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
540
541 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
542
543         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
544         * support/Util/pstdint.h: added
545
546 2006-05-22 Borut Razem <borut.razem AT siol.net>
547
548         * src/regression/Makefile: removed bool2.c test, added -q linker option
549         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
550           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
551           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
552           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
553           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
554           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
555           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
556           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
557           define SUPPORT_BIT_TYPES 0, removed unused bit variables
558
559 2006-05-22 Raphael Neider <rneider AT web.de>
560
561         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
562           bug #1492360 (problematic due to generic pointers, see code)
563
564 2006-05-22 Borut Razem <borut.razem AT siol.net>
565
566         * support/regression/ports/pic16/specs.mk: removed stack size linker
567           directive
568         * support/regression/tests/array.c,
569           support/regression/tests/bitopcse.c,
570           support/regression/tests/bug-908454.c,
571           support/regression/tests/malloc.c: modified for pic16 regression test
572         * support/regression/tests/bitfields.c:
573           pic16 - excluded bitfileds of size > 8
574         * support/regression/tests/bp.c: pic16 - reduced data size
575         * support/regression/tests/bug-221100.c: pic16 - reduced data size
576         * support/regression/tests/bug-460010.c:
577           pic16 - used the absolute address the fits in memory
578         * support/regression/tests/bug-716242.c:
579           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
580         * support/regression/tests/float.c:
581           pic16 - excluded - data size too big
582         * support/regression/tests/onebyte.c:
583           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
584         * support/regression/tests/shifts.c:
585           pic16 - function names probably have to differ in first X characters
586           (gpasm limitation?)
587         * support/regression/tests/staticinit.c:
588           pic16 - excluded some tests due error: no target memory available for
589           section ".idata"
590
591 2006-05-22 Borut Razem <borut.razem AT siol.net>
592
593         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
594           second try. Thanks Stas Sergeev once more.
595
596 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
597
598         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
599           (genLeftShift, genRightShift): fixed bug 1491627
600         * src/hc08/peeph.def (rules 7, 8.x): added
601         * support/regression/tests/shifts.c (ShiftLeftByParam,
602           ShiftRightByParam, testShiftByParam): added to test variable shifting
603
604 2006-05-20 Raphael Neider <rneider AT web.de>
605
606         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
607         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
608           (allocReg): add only new registers to dynAllocRegs,
609           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
610             #1489055, #1445850, and probably #1483693
611
612 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
613
614         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
615         bug in for-loop that didn't emit the last of CONFIG and ID registers
616
617 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
618
619         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
620           with offset
621         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
622           1489016, 1434401 and 1490124
623         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
624           1489016, 1434401 and 1490124
625
626 2006-05-17 Borut Razem <borut.razem AT siol.net>
627
628         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
629           thanks Stas Sergeev
630
631 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
632
633         * device/include/mcs51/P89c51RD2.h,
634         * device/include/mcs51/P89LPC901.h,
635         * device/include/mcs51/P89LPC922.h,
636         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
637
638 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
639
640         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
641         to fix missing stack pragma in compiled binary object file,
642
643 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
644
645         * support/packihx/configure.in,
646         * support/packihx/configure: removed warning, autoconf >= 2.5x can
647         determine sizeof basic types even while cross compiling
648
649 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
650
651         * src/avr/gen.c (aopop),
652         * src/ds390/gen.c (aopOp),
653         * src/hc08/gen.c (aopOp),
654         * src/mcs51/gen.c (aopop),
655         * src/pic16/gen.c (pic16_aopOp),
656         * src/pic/gen.c (aopOp),
657         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
658         if size of operand is smaller than spill location
659
660 2006-05-12 Borut Razem <borut.razem AT siol.net>
661
662         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
663           have to have CR/LF line endings even if they are checked out on *nix
664           or on WIN32 in cygwin binmode
665
666 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
667
668         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
669         * device/include/ds80c390.h: added sfr16 definitions
670         * src/ds390/gen.c,
671         * src/ds390/gen.h,
672         * src/ds390/main.c,
673         * src/ds390/ralloc.c,
674         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
675           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
676           bit returning functions
677         * support/regression/tests/sfr16.c: enabled test on ds390
678
679 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
680
681         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
682         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
683
684 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
685
686         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
687         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
688           (cl_address_space constructor): removed expensive initialization,
689           (cl_address_space::get_cell): extended for late initialization,
690           (cl_address_space::*): use late initialization,
691           (cl_address_decoder::activate): removed expensive initialization,
692           This reduced regression test running time by 25%
693
694 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
695
696         * packihx/,
697         * configure.in,
698         * configure,
699         * sdcc.dsw,
700         * Makefile.bcc,
701         * Makefile.in,
702         * support/packihx/Makefile.in,
703         * support/packihx/clean.mk,
704         * support/packihx/Makefile.bcc,
705         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
706
707 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
708
709         * src/SDCCval.c (valNot): fix for regression test failure
710           of not.c on big endian hosts
711
712 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
713
714         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
715
716 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
717
718         * device/lib/mcs51/Makefile.in: changed string comparison operator
719           to = for POSIX compliance; == is bash extension
720
721 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
722
723         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
724           kosmonaut_pirx
725
726 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
727
728         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
729         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
730         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
731         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
732         bug report #1478657,
733
734 2006-05-05 Borut Razem <borut.razem AT siol.net>
735
736         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
737           making the html
738
739 2006-05-02 Borut Razem <borut.razem AT siol.net>
740
741         * doc/Makefile.in: removed *.ind dependency since there is no rule to
742           create *.ind, which made make to fail if invoked with -j 2
743
744 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
745
746         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
747           Hubert Sack for patch 1479782
748
749 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
750
751         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
752
753 2006-05-01 Raphael Neider <rneider AT web.de>
754
755         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
756           (create_pic): store only prefix-free device name,
757           (init_pic): check for device names with "16" prefix,
758           (list_valid_pics),
759         * src/pic/device.h (struct PIC_device),
760         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
761             stored device name,
762         * device/include/pic/pic12f{635,675,629,683}.h,
763         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
764         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
765         * device/include/pic/pic16f505.h,
766         * device/lib/pic/libdev/pic16f505.c: removed
767         * device/include/pic/pic14devices.txt: added support for pic12f
768             devices, removed unsupported non 16-bit devices
769             [above changes provided by patch from Zik Saleeba]
770         * src/pic/*, src/pic16/*, device/include/pic16/*,
771           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
772
773 2006-05-01 Borut Razem <borut.razem AT siol.net>
774
775         * configure.in, configure, doc/Makefile.in:
776           sync with nightly build makefile - latex, dvipdf and dvips
777           not needed any more
778
779 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
780
781         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
782         in the library source
783
784 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
785
786         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
787
788 2006-04-28 Raphael Neider <rneider AT web.de>
789
790         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
791         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
792           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
793         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
794
795 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
796
797         * device/lib/pic/libdev/Makefile.in,
798         * device/lib/hc08/Makefile.in,
799         * device/lib/gbz80/Makefile.in,
800         * device/lib/z80/Makefile.in,
801         * device/lib/ds390/Makefile.in,
802         * device/lib/ds400/Makefile.in: added srcdir to include search path,
803         thanks to Borut for the bug report
804         * configure.in,
805         * configure: always create doc/Makefile independent from --enable-doc
806         * Makefile.in: always install from directory doc independent from
807         --enable-doc
808         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
809         removed
810         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
811         * doc/Makefile.in: install *.txt if present
812         * device/include/Makefile.in (install): added installation of pic/*.inc
813         and pic/*.txt files again, they were erroneously removed
814
815 2006-04-28 Raphael Neider <rneider AT web.de>
816
817         * src/pic/{gen.c,main.h,pcode.c},
818         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
819             concerning signedness with casts
820
821 2006-04-28 Raphael Neider <rneider AT web.de>
822
823         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
824             definition of an interrupt handler,
825         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
826             interrupt handler stuff from picglue() to separate routine,
827           (picglue): enabled definition of intr handlers in files w/o main()
828
829 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
830
831         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
832           compilation with MSVC 2005 Express Edition (VC8)
833
834 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
835
836         * device/lib/Makefile: fixed build of gbz80 lib
837
838 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
839
840         * support/regression/tests/bug-460010.c,
841         * support/regression/tests/bug-524691.c,
842         * support/regression/tests/bug-716242.c: removed conditional defines
843           that are already in testfwk.h
844
845 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
846
847         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
848           (AccAXRsh1): added, shift right by 1,
849           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
850            AccAXLrl1
851         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
852
853 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
854
855         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
856         remove cast to same type
857         * src/SDCCast.c (decorateType): fix for RFE 1475742,
858         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
859         * as/z80/Makefile,
860         * link/z80/Makefile: removed, they have moved to
861         Makefile.in files
862         * configure,
863         * configure.in: replaced duplicate message about ucsim by missing sdcpp
864         * install-sh: fix bug #1204398 by setting umask 0022
865         * device/lib/Makefile: separate build of z80 and gbz80 lib
866
867 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
868
869         Enabled VPATH feature: changed nearly all Makefiles (149 files).
870         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
871
872         One basic decision: e.g. src/clean.mk includes further files. In order
873         to make this work there are two solutions:
874         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
875           run configure on them. This way they can use
876           'include $(srcdir)/port-clean.mk'
877         - always include clean.mk by the Makefile at the same level. To avoid
878           that `make clean` tries to include and build Makefile.dep the
879           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
880           implemented, because now even `make uninstall` doesn't create
881           Makefile.in. clean.mk could be eliminated by pasting it in
882           Makefile.in.
883
884         * debugger/mcs51/Makefile.in: build own objects from library sources
885         (SLIB, SDCC) in current directory
886
887         * configure, configure.in: renamed --disable-device-lib-build in
888         --disable-device-lib; added --enable-doc, the required tools are
889         searched by configure; added result message; the toolchain for the
890         belonging ports are now only built, if the port is enabled.
891
892         * support/regression/*: all output is written in directory gen, because
893         the fwk and ports directories don't livet in the build tree using vpath
894
895         * doc/sdccman.lyx: renamed --disable-device-lib-build to
896         --disable-device-lib, added --enable-doc, added section VPATH
897
898         * sim/ucsim/configure.in,
899         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
900         z80 are enabled by default
901
902 2006-04-24 Raphael Neider <rneider AT web.de>
903
904         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
905             to config word, "pic14_"-prefixed some extern functions
906           (pic14_emitConfigWord): emit __config directive(s) if assignment to
907             config word has been found
908         * src/pic/device.h: added prototypes
909         * src/pic/pcode.c: added "pic14_"-prefix where needed
910         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
911             fixup
912         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
913             words,
914           (pic14emitRegularMap): ignore config words,
915           (pic14createInterruptVect): moved generating __config directives away
916           (picglue): have __config directives emitted
917
918 2006-04-24 Borut Razem <borut.razem AT siol.net>
919
920         * doc/Makefile: sync with nightly build makefile
921
922 2006-04-24 Raphael Neider <rneider AT web.de>
923
924         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
925             registers that have not been assigned proper liveranges,
926             fixes #1469504 and #1474602,
927           (pCodeRegOptimizeRegUsage): fixed typo in comment
928
929 2006-04-24 Borut Razem <borut.razem AT siol.net>
930
931         * device/examples/main8051.c: deleted - it was removed from CVS
932           24.mar.2000 and after that modified 18.feb.2001, so it reappered
933           after the transition to Subversion
934         * src/SDCCalloc.h: deleted - it was removed  from CVS
935           3.feb.2001 and after that modified 18.feb.2001, so it reappered
936           after the transition to Subversion
937         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
938           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
939           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
940           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
941
942 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
943
944         * as/asx8051.dsp: added mcs51/strcmpi.h
945         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
946         * as/hc08/aslink.h: updated lnksect prototype
947         * as/hc08/asm.h,
948         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
949         * as/hc08/asmain.c,
950         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
951           (newdot): handle A_ABS
952         * as/hc08/asout.c,
953         * as/mcs51/asout.c (outarea): output address
954         * as/hc08/lkaomf51.c,
955         * as/mcs51/lkaomf51.c: disabled unused array UsageType
956         * as/hc08/m08pst.c,
957         * as/mcs51/i51pst.c,
958         * as/z80/z80pst.c: "ABS" is not A_OVR
959         * as/hc08/lkarea.c (newarea): read a_addr,
960           (lnkarea): added codemap array, sort absolute areas to the front,
961            combine all GSINITx/GSFINAL,
962           (find_empty_space, allocate_space): new functions,
963           (lnksect): return next address, handle absolute sections
964         * as/mcs51/lkarea.c (newarea): read a_addr,
965           lnksect2 prototype changed,
966           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
967           (find_empty_space, allocate_space): new, factored out of lnksect2,
968           (lnksect2): return next address, handle absolute sections
969         * as/hc08/lkhead.c,
970         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
971         * as/hc08/lklibr.c (addfile, fndsym),
972         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
973           index out of range and detect both '\' and '/'
974         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
975         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
976           regression tests (ds390 cannot return bool yet)
977         * doc/sdccman.lyx: changed version number, document changed --no-peep,
978           document critical interrupts on z80, document changed SDCC define
979         * src/asm.c (_asxxxx_mapping): fixed .org directive,
980           (_a390_mapping): added .org directive
981         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
982           (genMultOneByte): fixed warnings
983         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
984           ones
985         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
986         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
987           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
988         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
989         * src/pic16/main.c: removed newReg prototype
990         * src/pic16/pcode.c,
991         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
992           warnings
993         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
994           ones
995         * src/pic16/ralloc.c
996         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
997           to fix warnings
998         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
999           from short to PIC_OPTYPE
1000         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
1001         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
1002           optype from short to PIC_OPTYPE
1003         * src/port.h: made int_size unsigned to fix warnings
1004         * src/SDCC.y: fixed warning on MSVC
1005         * src/SDCCicode.c (getArraySizePtr): return unsigned int
1006         * src/SDCCopt.c (convertToFcall): fixed warnings
1007         * src/SDCCsymt.h: removed double prototype for genSymName
1008         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
1009           offset int to fix warnings
1010
1011 2006-04-22 Borut Razem <borut.razem AT siol.net>
1012
1013         * doc/sdccman.lyx, */Makefile, */Makefile.in:
1014           references to CVS replaced with Subversion
1015
1016 2006-04-21 Borut Razem <borut.razem AT siol.net>
1017
1018         * doc/sdccman.lyx, */Makefile, */Makefile.in:
1019           references to CVS replaced with Subversion
1020
1021 2006-04-19 Borut Razem <borut.razem AT siol.net>
1022
1023         * src/version.awk: adapted for svn
1024         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
1025           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
1026           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
1027           /binutils-avr/etc/*.vi, *.jin: removed all properties
1028           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
1029
1030 2006-04-19 Borut Razem <borut.razem AT siol.net>
1031
1032         * CVS to Subversion migration completed
1033
1034 2006-04-18 Borut Razem <borut.razem AT siol.net>
1035
1036         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
1037           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
1038
1039 2006-04-17 Borut Razem <borut.razem AT siol.net>
1040
1041         * device/include/Makefile.in: added pic/*.inc to the installation
1042
1043 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
1044
1045         * support/regression/collate-results.py: fixed output in case of
1046         a valdiag error
1047         * support/regression/generate-cases.py: fixed splitting of pathnames
1048         with dots
1049         * as/hc08/lklibr.c (addfile),
1050         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
1051
1052 2006-04-11 Raphael Neider <rneider AT web.de>
1053
1054         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
1055         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
1056         * src/pic16/pcode.c (assignValnums): fixed #1460578
1057
1058 2006-04-11 Raphael Neider <rneider AT web.de>
1059
1060         * device/lib/pic/libdev/*.c,
1061         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
1062           fixes #1468739, enables compilation in --std-c99 mode
1063         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
1064
1065 2006-04-11 Raphael Neider <rneider AT web.de>
1066
1067         * src/pic/device.c (find_device): removed debug output
1068           (list_valid_pics): enabled verbose listing of supported devices
1069         * device/include/stdbool.h: define bool as char for pic14/16 as well
1070
1071 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1072
1073         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
1074
1075 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
1076
1077         * .version: bumped version to 2.5.6
1078         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
1079
1080 2006-04-06 Raphael Neider <rneider AT web.de>
1081
1082         * .version: bumped version to 2.5.6 (pic14 ABI changed)
1083         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
1084         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
1085           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
1086             pic14_constructAbsMap
1087           (pic14printPublics): declare absolute global symbols as global
1088           (pic14createInterruptVect),
1089         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
1090           (newReg): assume new registers unused, use correct name in
1091             hashtable (reg->name instead of name), more debugLog output
1092         * src/pic/device.h (PIC_device): added fields for verbose output
1093         * src/pic/device.c: moved device definition to pic14devices.txt,
1094             added routines for runtime parsing of pic14devices.txt,
1095             added support for second config word
1096         * src/pic/main.c (_process_pragma): removed #pragma maxram,
1097           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
1098           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
1099           (_pic14_parseOptions): moved pCodeInitRegisters here
1100           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
1101         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
1102           (pCodeInitRegisters): rewrapped comments, perpared new approach to
1103             handling the pseudo stack
1104         * device/lib/Makefile.in: ignore failures in objects-pic16,
1105         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
1106         * device/lib/pic/NEWS: document new dependency on picXXX.lib
1107         * device/lib/pic/Makefile.subdir,
1108         * device/lib/pic16/Makefile.subdir: improved clean rules
1109         * device/lib/pic/libdev/: NEW, pic14 device libraries
1110         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
1111         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
1112         * device/include/Makefile.in: create subdir and install pic14 headers
1113         * device/include/pic/p16f_common.inc: removed unused declarations
1114         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
1115             PICs from inc2h.pl v1.6,
1116             replaced BIT_AT macros with struct declarations
1117         * device/include/pic/pic14devices.txt: definition of supported devices,
1118             all above improvements contributed by Zik Saleeba, thanks
1119         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
1120         * support/scripts/sdcc.nsi: also install pic14 device libraries and
1121             headers
1122
1123 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1124
1125         * device/include/mcs51/c8051f410.h: added interrupt numbers,
1126         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
1127           thanks to Charles Olds
1128
1129 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1130
1131         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
1132
1133 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
1134
1135         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
1136         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
1137         * support/regression/bug1464657.c: added, new test
1138
1139 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1140
1141         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
1142           version number
1143
1144 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1145
1146         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
1147           --no-peep and --peep-file <file> are used don't use default rules but
1148           do use the <file>
1149
1150 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
1151
1152         * src/mcs51/gen.c (genCall): fixed bug 1457608
1153
1154 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1155
1156         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
1157         changes seem to cause (trigger?) problems with the build system.
1158
1159 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
1160
1161         * src/SDCCpeeph.c (operandsLiteral): new, added,
1162           (callFuncByName): inserted operandsLiteral
1163         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
1164
1165 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1166
1167         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
1168         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
1169
1170 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1171
1172         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
1173           implemented patch 1120823 Thanks to Willy De la Court (normal
1174           interrupts need an interrupt number now if they are made critical),
1175           and enabled nesting of critical functions though not for gbz80
1176           (genCritical, genEndCritical): added functions
1177           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
1178         * src/z80/mappings.i: added "ei" to all mappings
1179
1180 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1181
1182         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
1183         submitted by the Debian SDCC maintainer Aurelien Jarno:
1184         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
1185         archive with gcc 4.1 on mips and wrote the patch"
1186
1187 2006-03-16 Raphael Neider <rneider AT web.de>
1188
1189         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
1190           the left operand is shorter than the result (c* = lit-c* + int),
1191           fixes bug #1450796
1192         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
1193           OP_SYMBOL
1194
1195 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
1196
1197         * src/.version: increased version number to 2.5.5
1198         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
1199         linking is done manually in pic16 port's _linkEdit,
1200         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
1201         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
1202         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
1203         allocate asmop as AOP_ACC,
1204         (aopForRemat): added parameter 'bool result' in function declaration,
1205         (pic16_aopGet): return AOP_ACC when accessing WREG,
1206         (pic16_popGetTempReg): minor modification,
1207         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
1208         'pic16_allocWithIdx',
1209         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
1210         calling function in absolute addresses,
1211         (genAssign): take into account AOP_ACC asmop,
1212         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
1213         * src/pic16/pcoderegs.c: some debug functions and lines added,
1214         * src/pic16/ralloc.c (decodeRegType): added but commented out,
1215         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
1216         register too,
1217         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
1218         call to allocReg, not by manually allocating a new one,
1219         (pic16_assignRegisters): now before going through the register
1220         allocating functions mark all registers as free. This eliminates some
1221         side effects resulting from peephole parser done earlier in the backbone
1222
1223 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
1224
1225         * src/SDCCicode.c (geniCodeLogic),
1226         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
1227
1228 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
1229
1230         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
1231           (genSend): bugfix, do not allocate and free twice,
1232           (shiftRLong): handle partially overlapping aops
1233         * support/regression/tests/bitopcse.c: fixed warning redefined idata
1234
1235 2006-03-08 Borut Razem <borut.razem AT siol.net>
1236
1237         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
1238           for pic16
1239
1240 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
1241
1242         * support/regression/tests/bug1409955.c: new, added
1243         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
1244         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
1245           (aopForSym, aopOp): increment asmop.allocated if reused,
1246           (freeAsmop): decrement asmop.allocated and check for zero instead of
1247           using asmop.freed,
1248           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
1249           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
1250            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
1251            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
1252            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
1253            genSignedRightShift, genRightShift, genDataPointerGet,
1254            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
1255            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
1256             in reverse order from allocation,
1257           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
1258             added swappedLR to keep track
1259         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
1260           pdata & code for GCC, z80, gbz80 & hc08
1261         * support/regression/tests/zeropad.c: moved defines to testfwk.h
1262
1263 2006-03-08 Raphael Neider <rneider AT web.de>
1264
1265         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
1266
1267 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
1268
1269         * device/include/mcs51/c8051f410.h: new SiLabs mcu
1270         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
1271         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
1272
1273 2006-03-06 Borut Razem <borut.razem AT siol.net>
1274
1275         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
1276           made the linker quiet
1277
1278 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
1279
1280         * src/pic16/gen.c (genPcall): fixed bug #1443644
1281         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
1282         which dumps before the function entry point a data byte which represents
1283         the number of the local variables used by the specified function, added
1284         'xinst' for initial support for Extended Instruction Support,
1285         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
1286         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
1287         port->fun_prefix anymore (may change later),
1288         (genFunction, genEndFunction): do not store/restore local registers for
1289         _main (this should take care the --main-return command line option in
1290         the future),
1291         (genOr): removed some legacy pic-port instructions,
1292         * src/pic16/genarith.c (genAddLit): re-enabled old code because
1293         performing operations with SFR's causes data to be written more than
1294         once to each SFR. Perhaps SFRs should be handled in special cases...
1295         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
1296         pcode.h
1297         * src/pic16/main.c (_process_pragma): stack bound checking did not take
1298         into account for stack starting position,
1299         (struct OPTIONS pic16_optionsTable): added command line argument
1300         --extended or -y for Extended Instruction Support,
1301         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
1302         (deassignLRs): *** perhaps the most important change, old 'for' code
1303         (commented out for reference), didn't account for some registers which
1304         were left marked 'not free' after a pointer operation. The change
1305         reduces register usage a lot in some cases
1306
1307 2006-03-04 Borut Razem <borut.razem AT siol.net>
1308
1309         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
1310           _clean
1311         * support/regression/tests/bug-524697.c: decreased array size for
1312           mcs51 to fit into the internal RAM
1313         * support/regression/Makefile.in: a little bit more verbose
1314
1315 2006-03-03 Borut Razem <borut.razem AT siol.net>
1316
1317         * support/regression/fwk/lib/testfwk.c,
1318           support/regression/fwk/include/testfwk.h: introduced function
1319           _prints(), nonrecursive _printn(), call _initEmu() from main()
1320         * support/regression/ports/gbz80/support.asm,
1321           support/regression/ports/ucz80/support.asm,
1322           support/regression/ports/z80/support.asm,
1323           support/regression/ports/ds390/support.c,
1324           support/regression/ports/hc08/support.c,
1325           support/regression/ports/host/support.c,
1326           support/regression/ports/mcs51/support.c,
1327           support/regression/ports/xa51/support.c: added empty _initEmu()
1328           function
1329         * support/regression/ports/pic16/gpsim.cmd,
1330           support/regression/ports/pic16/spec.mk,
1331           support/regression/ports/pic16/support.c,
1332           support/regression/Makefile.in: added pic16 regression test
1333
1334 2006-03-01 Raphael Neider <rneider AT web.de>
1335
1336         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
1337           genConstPointerGet): use safe way of generating MOVFF to cover
1338             literals as well as registers, fixes bug #1440527
1339         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
1340             dereference
1341           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
1342             more correctly, fixes bug #1232186
1343           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
1344         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
1345             gplink guess the correct processor in more cases, applied patch
1346             from Till Riedel attached to and fixing bug #1436552
1347
1348 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1349
1350         * support/regression/tests/array.c: added, contains check for #1434401
1351         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
1352
1353 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
1354
1355         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
1356         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
1357         * device/include/mcs51/c8051f326.h,
1358         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
1359         * device/include/mcs51/c8051f000.h,
1360         * device/include/mcs51/c8051f018.h,
1361         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
1362           PCON_IDLE,PCON_STOP and added sfr16 definitions
1363
1364 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1365
1366         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
1367           genGetWord): fixed bug 1409955
1368
1369 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
1370
1371         * device/include/hc08/mc68hc908gp32.h,
1372         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
1373
1374 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
1375
1376         * src/SDCCast.c (constExprValue): return NULL if not a value
1377         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
1378         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
1379         * support/regression/tests/bitfields.c: enabled signed bitfield for all
1380
1381 2006-02-13 Borut Razem <borut.razem AT siol.net>
1382
1383         * src/regression/ptrarg.c: added, fails due to bug #1430967
1384         * src/regression/Makefile: ptrarg.c added, ...
1385
1386 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1387
1388         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
1389         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
1390
1391 2006-02-11 Borut Razem <borut.razem AT siol.net>
1392
1393         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
1394           print "Processor: xxx" message to stdout only if --verbose
1395
1396 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1397
1398         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
1399         * support/regression/tests/bug1426356.c: added
1400         * support/regression/tests/bitfields.c: removed 2 tests
1401
1402 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
1403
1404         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
1405         * device/include/mcs51/c8051f330.h,
1406         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
1407           PCON_IDLE,PCON_STOP and added sfr16 definitions
1408         * device/lib/_divsint.c,
1409         * device/lib/_divuint.c,
1410         * device/lib/_divulong.c,
1411         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
1412           register bank bug for small stackauto
1413
1414 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
1415
1416         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
1417
1418 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
1419
1420         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
1421         * all.dsp: corrected several bin paths
1422         * device/include/mcs51/c8051f120.h,
1423         * device/include/mcs51/c8051f300.h,
1424         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
1425           to PCON_IDLE,PCON_STOP
1426         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
1427         * device/lib/printf_large.c (output_float): fixed bug 1388703
1428         * support/regression/tests/bug1057979.c: added test for bug 1388703
1429
1430 2006-02-08 Raphael Neider <rneider AT web.de>
1431
1432         * src/pic/pcode.c (pciTRIS): fixed typo,
1433           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
1434           (LinkFlow): fixed handling of flows that end in a call,
1435           (ReuseReg): perform safety check earlier
1436         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
1437             to work with flows at the beginning of a pBlock,
1438             fixes #1426557 (Symbol not previously defined),
1439           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
1440             usage information
1441           (RemoveUnusedRegisters): update register usage info
1442         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
1443             created, reuse existing ones instead
1444         * src/pic/gen.c (genPcall): fixed #1424719
1445
1446 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
1447
1448         * link/z80/lkmain.c,
1449         * link/z80/lklex.c,
1450         * link/z80/lkdata.c,
1451         * link/z80/aslink.h: fixed build on current cygwin:
1452         replaced getline() by lk_getline()
1453
1454 2006-02-01 Borut Razem <borut.razem AT siol.net>
1455
1456         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
1457           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
1458           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
1459           src/regression/bool1.c, src/regression/bool2.c,
1460           src/regression/bool3.c, src/regression/call1.c,
1461           src/regression/compare.c, src/regression/compare10.c,
1462           src/regression/compare2.c, src/regression/compare3.c,
1463           src/regression/compare4.c, src/regression/compare5.c,
1464           src/regression/compare6.c, src/regression/compare7.c,
1465           src/regression/compare8.c, src/regression/compare9.c,
1466           src/regression/configword.c, src/regression/for.c,
1467           src/regression/inline.c, src/regression/mult1.c,
1468           src/regression/nestfor.c, src/regression/or1.c,
1469           src/regression/pointer1.c, src/regression/ptrfunc.c,
1470           src/regression/rotate1.c, src/regression/rotate2.c,
1471           src/regression/rotate3.c, src/regression/rotate4.c,
1472           src/regression/rotate5.c, src/regression/rotate6.c,
1473           src/regression/rotate7.c, src/regression/string1.c,
1474           src/regression/struct1.c, src/regression/sub.c,
1475           src/regression/sub2.c, src/regression/switch1.c,
1476           src/regression/while.c, src/regression/xor.c,
1477           src/regression/create_stc, src/regression/simulate,
1478           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
1479           regression tests
1480         * src/regression/gpsim_assert.h: added
1481
1482 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
1483
1484         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
1485         ((void (code *) (void)) 0) ();
1486         * as/hc08/aslex.c,
1487         * as/hc08/aslink.h,
1488         * as/hc08/asm.h,
1489         * as/hc08/asmain.c,
1490         * as/hc08/lkdata.c,
1491         * as/hc08/lklex.c,
1492         * as/hc08/lkmain.c,
1493         * as/mcs51/aslex.c,
1494         * as/mcs51/aslink.h,
1495         * as/mcs51/asm.h,
1496         * as/mcs51/asmain.c,
1497         * as/mcs51/lkdata.c,
1498         * as/mcs51/lklex.c,
1499         * as/mcs51/lkmain.c,
1500         * as/z80/aslex.c,
1501         * as/z80/asm.h,
1502         * as/z80/asmain.c: fixed build on current cygwin:
1503         replaced getline() by as_getline()
1504
1505 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
1506
1507         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
1508         declarator in the symbol chain
1509         * src/SDCCsymt.h,
1510         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
1511         parameter list for function pointers
1512         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
1513         * support/regression/tests/bug-716242.c: added
1514
1515 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
1516
1517         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
1518         offset if possible
1519         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
1520
1521 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
1522
1523         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
1524         inifinitely recurseable, added static
1525         * support/regression/tests/bug-1408066.c: added
1526
1527 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
1528
1529         * src/SDCCicode.h,
1530         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
1531         renamed, added possibility to create "postLoopLbl"-labels
1532         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
1533         newiTempLoopHeaderLabel
1534         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
1535         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
1536         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
1537         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
1538         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
1539         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
1540         (basicInduction): fixed bug #136564, made static,
1541         (loopInduction): changed parameter of basicInduction, made static,
1542         (addPostLoopBlock): added
1543         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
1544         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
1545         findLoopEndSeq
1546         * support/regression/tests/bug-136564.c: added
1547         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
1548         --std-sdcc99 to LIBSDCCFLAGS
1549
1550 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
1551
1552         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
1553         while loop
1554         * support/regression/tests/bug-1406131.c: added
1555
1556 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
1557
1558         * src/SDCCast.c (decorateType): fix promotion of unary minus
1559         * src/SDCCsymt.c (computeType): beautified
1560         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
1561         (valUnaryPM, valComplement): fix sign and promotion,
1562         (valNot): ANSI: result type is int (SDCC: unsigned char)
1563         * support/regression/tests/uminus.c: speedup by removing superflous
1564         test case 'int'
1565         * support/regression/tests/onebyte.c: added promotion and signedness
1566         tests for unary minus
1567         * support/regressions/tests/bug-477927.c: disable warning about
1568         uninitialized variables
1569         * support/regression/tests/not.c: added
1570
1571 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
1572
1573         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
1574         * src/mcs51/gen.c (gen51Code): show final register usage after
1575         fillGaps in asm with --i-code-in-asm
1576         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
1577         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
1578         incUsed, rliveClear, adjustIChain): made static,
1579         (setFromRange): excluded because it's unused,
1580         (findPrevUseSym, markWholeLoop): added,
1581         (findPrevUse): rewritten; fixes bug 895992; now a complete search
1582         through all branches of predecessors enables sdcc to emit the warning
1583         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
1584         (rlivePoint): made static, added parameter emitWarnings which is only
1585         true during the first run out of two,
1586         (findRecursiveSucc, findRecursivePred): removed,
1587         (computeLiveRanges): made static, added parameter emitWarnings,
1588         (dumpIcRlive): added for debugging only
1589         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
1590         removed prototype of setFromRange()
1591         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
1592         in call of computeLiveRanges()
1593         * support/regression/tests/bug-895992.c: added
1594         * support/regression/tests/bug-971834.c: added
1595         * support/valdiag/tests/bug-895992.c: added
1596         * support/valdiag/tests/bug-971834.c: added
1597
1598 2005-12-18 Raphael Neider <rneider AT web.de>
1599
1600         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
1601           (genUnpackBits): improved code for direct operands,
1602           (genPackBits): improved code for literal assignment to bitfields
1603             and for direct destination operands (no FSR indirection),
1604             prevented redundant AND, fixes #1362800,
1605           (AccLsh): added parameter to disable masking of the result
1606         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
1607           skip instructions with side-effects (like incfsz),
1608           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
1609         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
1610         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
1611           fixes #1375263
1612
1613 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
1614
1615         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
1616         volatile variables as spill location
1617
1618 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
1619
1620         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
1621         replacing literals
1622         * support/regression/tests/bug-1376320.c: added
1623
1624 2005-12-08 Raphael Neider <rneider AT web.de>
1625
1626         * src/pic/device.c: renamed is_shared to pic14_is_shared
1627         * src/pic/gen.c (genIfx): re-enabled handling of sbits
1628         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
1629           (is_valid_identifier): added for above workaround
1630
1631 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
1632
1633         * device/lib/Makefile.in: fixed to enable port-specific-objects
1634         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
1635           char, thanks Hubert Sack
1636         * doc/sdccman.lyx: documented --xstack-loc,
1637           elaborated a bit more on interrupts and pitfalls,
1638           removed "setjmp/longjmp unsupported",
1639           documented some unsupported C99 features
1640         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
1641         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
1642           if, thanks Hubert Sack
1643         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
1644         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
1645           make make_library
1646         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
1647           regression tests can report resource usage (rfe 700441)
1648         * support/regression/collate-results.py: report resource usage
1649         * support/regression/ports/ds390/spec.mk,
1650         * support/regression/ports/hc08/spec.mk,
1651         * support/regression/ports/mcs51/spec.mk,
1652         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
1653         * support/regression/ports/ds390/uCsim.cmd,
1654         * support/regression/ports/hc08/uCsim.cmd,
1655         * support/regression/ports/mcs51/uCsim.cmd,
1656         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
1657         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
1658           library, use the default one
1659         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
1660           building the library
1661
1662 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1663
1664         * config.dsp: added dependency on .version and configure_vc.awk
1665         * device/include/setjmp.h: updated for --stack-auto and --xstack
1666         * device/include/mcs51/at89c51snd1c.h: corrected line endings
1667         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
1668         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
1669         * device/lib/libsdcc.lib: added _setjmp
1670         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
1671           (decorateType): fixed bug 1372851,
1672           (optimizeGetHbit): fixed warning
1673         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
1674           array initialisation
1675         * support/regression/tests/bug1057979.c: added test for bug 1358192
1676         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
1677
1678 2005-12-03 Borut Razem <borut.razem AT siol.net>
1679
1680         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
1681           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
1682
1683 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1684
1685         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
1686         createIval): implement symbol independant "flexible array member",
1687         (createIvalCharPtr): implemented flexible array initialisation with a
1688         string
1689         * src/SDCCsymt.c (copyStruct): removed,
1690         (getSize): fixed misleading comment,
1691         (getAllocSize): removed, the additional allocation size is now in
1692         sym->flexArrayLength,
1693         (checkStructFlexArray): new, syntax checks for flexible array members,
1694         (compStructSize): added syntax checks for "flexible array members"
1695         (copyStruct): removed,
1696         (copyLinkChain): removed inefficient fix for bug 770487
1697         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
1698         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
1699         symbol->flexArrayLength
1700         * src/SDCCerr.c,
1701         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
1702         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
1703         * support/regression/tests/structflexarray.c: added
1704         * support/valdiag/tests/structflexiblearray.c: added
1705
1706 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
1707
1708         * src/SDCCast.c (decorateType): fixed bug 1368489
1709         * support/Util/SDCCerr.c,
1710         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
1711
1712 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1713
1714         * device/include/mcs51/at89c51snd1c.h: added file submitted by
1715           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
1716
1717 2005-11-27 Borut Razem <borut.razem AT siol.net>
1718
1719         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
1720           support/cpp2/mkdeps.h: added command line option
1721           -obj-ext=<extension> to SDCPP to define object file externion, used
1722           for generation of make dependencies (-M)
1723         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
1724
1725 2005-11-26 Borut Razem <borut.razem AT siol.net>
1726
1727         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
1728           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
1729           added pic and pic16 libraries
1730
1731 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1732
1733         * device/include/float.h: Corrected typo in prototype of __fsgt
1734
1735 2005-11-25 Borut Razem <borut.razem AT siol.net>
1736
1737         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
1738           added creation of model-mcs51-stack-auto libraries
1739
1740 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
1741
1742         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
1743         and fields-list too
1744         * src/SDCCast.c (createIvalArray): removed obsolete comment
1745
1746 2005-11-24 Borut Razem <borut.razem AT siol.net>
1747
1748         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
1749           added missing device/lib/mcs51/crt*.asm sources
1750
1751 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
1752
1753         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
1754
1755 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
1756
1757         * device/lib/_fs2schar.c,
1758         * device/lib/_fs2sint.c,
1759         * device/lib/_fs2slong.c: optimized inline asm
1760
1761 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1762
1763         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1764           Better handling of floats between -1.0 and 0.0.
1765
1766 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1767
1768         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
1769           (the missing "if"s prohibited removal of redundant labels)
1770
1771 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1772
1773         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
1774           Properly convert floats between -1.0 and 0.0 to long, int, and char
1775           types (max integer value of negative floats tends to zero).
1776         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1777           Removed changes made so to work properly with floats between
1778           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
1779           and _fs2char.c
1780
1781 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1782
1783         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
1784         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
1785         (genCast) cosmetic change
1786         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
1787         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
1788         from mcs51
1789         * support/regression/tests/bitfields (testSignedBitfields): added
1790
1791 2005-11-18 Borut Razem <borut.razem AT siol.net>
1792
1793         * sdcc/device/lib/Makefile.in: remove all unnecessary files
1794         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
1795           introduced SILENT option to make building of pic16 libraries less
1796
1797 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1798
1799         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
1800           Now they work properly with floats between -1.0 and 0.0
1801         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
1802
1803 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
1804
1805         * src/SDCCicode.c (printOperand): added missing else
1806
1807 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
1808
1809         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
1810         reformatted for better readability
1811         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
1812         signed bitfields
1813
1814 2005-11-17 Borut Razem <borut.razem AT siol.net>
1815
1816         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
1817           introduced SILENT option to make building of pic16 libraries less
1818           verbose - used for nightly snapshot build
1819         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
1820           available on Win32 platforms.
1821         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
1822           medium, large, pic and pic16
1823
1824 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
1825
1826         * device/lib/printf_large.c: Temporary patch for bug 1358192:
1827           printf("%f"...) sets fraction to zero.
1828
1829 2005-11-16 Raphael Neider <rneider AT web.de>
1830
1831         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
1832           fixes #1357221
1833         * src/pic/gen.c (genIfx): implemented for CARRY bit
1834         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
1835           to generic pointers, fixes #1357332,
1836           (pic16_movLit2f): NEW,
1837           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
1838
1839 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
1840
1841         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
1842
1843 2005-11-11 Raphael Neider <rneider AT web.de>
1844
1845         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
1846         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
1847           compute pointer's type from operand,
1848           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
1849           improved single bit reads, fixes bug #1353379
1850
1851 2005-11-09 Borut Razem <borut.razem AT siol.net>
1852
1853         * support/scripts/sdcc.nsi: added lib/pic to the package
1854
1855 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
1856
1857         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
1858
1859 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
1860
1861         * support/regression/tests/bug1348008.c: added
1862         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
1863         * support/regression/tests/bug1337835.c: updated comment
1864
1865 2005-11-06 Borut Razem <borut.razem AT siol.net>
1866
1867         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1868           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1869           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1870           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1871           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
1872           dynamic construction of cl_error_class and derivates - 2.nd try
1873
1874 2005-11-05 Borut Razem <borut.razem AT siol.net>
1875
1876         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
1877           bug, which caused Bus Errors on sparc solaris
1878
1879 2005-11-04 Borut Razem <borut.razem AT siol.net>
1880
1881         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
1882           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
1883           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
1884           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
1885           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
1886           and derivates to resolve the initialization problem on OSX
1887
1888 2005-11-02 Borut Razem <borut.razem AT siol.net>
1889
1890         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1891           corrected typo - #include <winsock2.h>
1892
1893 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
1894
1895         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
1896           (_asxxxx_mapping): added org directive for future enhancements
1897
1898 2005-11-01 Borut Razem <borut.razem AT siol.net>
1899
1900         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
1901           enabled sockets on WIN32
1902         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
1903
1904 2005-10-31 Borut Razem <borut.razem AT siol.net>
1905
1906         * support/regression/generate-cases.py: escape backslashes in {testcase}:
1907           WIN32 backslash path delimiters should be escaped when used in C strings
1908         * support/regression/tests/bitfields.c: exclude failing assertions for
1909           __CYGWIN32__ and __MINGW32__ hosts
1910
1911 2005-10-30 Borut Razem <borut.razem AT siol.net>
1912
1913         * src/SDCCutil.c: corrected double comparison typo
1914
1915 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
1916
1917         * device/lib/medium/Makefile: added for new memory model medium
1918         * device/include/asm/mcs51/features.h: updated for medium/pdata
1919         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
1920           added Multiply & Accumulate sbit's and MAC0_PAGE define
1921         * device/include/mcs51/c8051f300.h: added sfr16 definitions
1922         * device/include/mcs51/c8051f310.h: added sfr16 definitions
1923         * device/lib/_mullong.c: update for medium model
1924         * device/lib/incl.mk: added medium model
1925         * doc/sdccman.lyx: documented medium model
1926         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
1927         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
1928         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
1929         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
1930           (allocParms): set SCLS and OCLS to pdata for medium model
1931         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
1932           for pdata,
1933           (powof2): return <0 if not power of 2
1934         * src/avr/gen.c (genBitWise): use updated powof2
1935         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
1936           (shiftR2Left2Result): small optimization in setup, save acc when storing,
1937           (shiftLLeftOrResult): use B if necessary
1938         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
1939         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
1940         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
1941         * support/regression/Makefile.in: added test-mcs51-medium
1942         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
1943
1944 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
1945
1946         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
1947         specifier unsigned
1948         * device/lib/time.c (mktime): fixed bug 1334315
1949
1950 2005-10-28 Raphael Neider <rneider AT web.de>
1951
1952         * device/include/pic/p16f_common.inc: added common declarations
1953         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
1954
1955 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
1956
1957         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
1958           (aopPutUsesAcc): added to predict accumulator use,
1959           (assignResultValue): save acc if necessary,
1960           (genMinusDec): store result if indirectly addressed,
1961           (genDivOneByte):  save acc if necessary,
1962           (movLeft2Result): bugfix if left already in acc,
1963           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
1964             attention to accumulator use (esp. pdata),
1965           (genReceive): receive pdata correctly
1966         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
1967         * src/SDCCicode.h: added isOperandInPagedSpace prototype
1968
1969 2005-10-27 Raphael Neider <rneider AT web.de>
1970
1971         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
1972
1973 2005-10-27 Raphael Neider <rneider AT web.de>
1974
1975         * .version: changed version to 2.5.4
1976         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
1977         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
1978           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
1979             arithmetics support routines
1980         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
1981         * device/lib/Makefile.in: also create installdir for pic
1982
1983         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
1984           pic14 port as well
1985         * src/pic/device.c (dump_sfr): rewritten to delegate register
1986           placement to the linker (use `extern sym' rather than sym EQU addr),
1987           (validAddress): fixed to check last specified address
1988         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
1989           (popGetLit): truncate literal value to 8 bit,
1990           (popGet): moved assert to more appropriate place
1991           (popGetExternal): create pCode operand from and mark the according
1992             symbol as being `extern'
1993           (popGetAddr): added sanity check on immediate's offset, provide
1994             GPOINTER tag on demand
1995           (aopPut): fixed for immediates,
1996           (mov2w_op): move operand's address or contents to WREG (depending on
1997             operand type), safer variant of mov2w,
1998           (movwf,call_libraryfunc): NEW, handy abbreviations,
1999           (get_argument_pcop,get_return_val_pcop,pass_argument,
2000           get_returnvalue): interface for accessing function parameters and
2001             return values,
2002           (assignResultValuei,genRet): use new parameter/return value interface
2003           (pic14_getDataSize): back to old version handling generic pointers,
2004           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
2005             provided implementation and/or fixed old one,
2006           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
2007             calls, removed legacy 8051 reference code
2008           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
2009           (loadSignToC): NEW, move the operands sign bit to CARRY,
2010           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
2011             genRightShiftSigned, accepts negative shift counts,
2012           (setup_fsr): load FSR and adjust IRP (indirect memory access),
2013           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
2014             generic pointers, __data pointers and __code pointers,
2015           (genUnpackBits,genPackBits): rewritten to work with generic pointers
2016             and signed bitfields, limit bitfields to 8 bit,
2017           (genDataPointerGet): fixed number of bytes read,
2018           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
2019           (genPointerGet,genPointerSet): fixed handling of __code pointers,
2020             pointers to constant data are no longer assumed to point to __code
2021             space, removed invalid pointer types,
2022           (bitpatternFromVal): retrieve the PICs representation of an integer
2023             or float literal,
2024           (genDataPointerSet): fixed assigning to po_immediate operands,
2025           (genGenPointerSet): implemented as library call,
2026           (genIfx): fixed incorrect condition,
2027           (genAddrOf): limit generic pointers' addresses to 2 bytes,
2028             provide GPOINTER tag according to destination's storage class,
2029           (genCast): added code to handle casting to generic pointers, added
2030             sign-/zero extension of the result
2031           (aop_isLitLike,op_isLitLike): fixed handling of immediates
2032         * src/pic/gen.h: added macros to access IRP bit in STATUS register
2033         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
2034           extend the result
2035         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
2036           address/register resides in the shared banks
2037           (emitSymbolToFile): improved to handle global and `pinned' symbols,
2038             put all variables into separate sections (have the linker arrange
2039             them)
2040           (picglue): put init code and interrupt handlers in separate sections
2041         * src/pic/main.c: added port specific options table, modified to PORT
2042           structure to make GPOINTERs 3 byte, added pic14_options
2043           (_pic14_do_link): private linking routine (update paths to libraries,
2044             add libsdcc.lib by default)
2045         * src/pic/main.h: declare pic14_options
2046         * src/pic/pcode.c: fixed instructions i/o relations,
2047           (RegCond): reverted to correct version,
2048           (newpCodeOpLit): truncate literals to 8 bit,
2049           (genericPrint): added debug output,
2050           (getRegFromInstruction): fixed for various operand types, simplified
2051           (BuildFlow): fixed broken handling of isntructions with labels
2052           (LinkFlow): start at last instruction in flow (skip trailing comments),
2053             pass the flow on to the next instruction after CALL
2054           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
2055           (insertPCodeInstruction): fixed inserting after a skip instruction,
2056           (DoBankSelect): fixed for labeled instructions
2057           (OptimizepBlock): honor --nopeep switch
2058           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
2059         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
2060         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
2061           (pCodeOptime2pCodes): allow disabling this optimization via
2062             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
2063             but is still buggy), started implementation of a dataflow based
2064             pCode optimization (CSE + dead code elimination)
2065           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
2066         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
2067           names are independant of the stack location and therefore portable across
2068           devices
2069
2070 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
2071
2072         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
2073           (selectSpil): fixed bug 1337835 by not spilling bit variables
2074         * support/regression/tests/bug1337835.c: added test for this bug
2075         * src/mcs51/peeph.def: restart after rule 3.c,
2076           addded rules 263.x to optimize loading constants
2077
2078 2005-10-26 Raphael Neider <rneider AT web.de>
2079
2080         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
2081         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
2082           (genAssign): emit warning when casting literals to generic pointer
2083             type, also applies when taking the address of a fixed variable,
2084           (genCast): improved casting to generic pointers
2085         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
2086           extern variables, added verbose error message
2087         * device/include/pic16/{string.h,errno.h}: added #pragma library c
2088
2089 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
2090
2091         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
2092         carry must be complemented too
2093         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
2094         could be emitted by genMinus
2095         * src/SDCCval.c (constVal): fixed bug 1305065
2096
2097 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
2098
2099         * src/SDCCast.c (addCast): added promotion for bit variables
2100         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
2101         promotion casts + optimisation
2102         (optimizeGetWord): fix warning 'i' might be used uninitialized
2103         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
2104         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
2105
2106 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
2107
2108         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
2109         all chars are promoted to int; promotion should be handled in SDCCast.c
2110
2111 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2112
2113         * device/lib/_strcmp.c: Fixed bug 1326457
2114
2115 2005-10-11 Raphael Neider <rneider AT web.de>
2116
2117         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
2118         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
2119
2120 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
2121
2122         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
2123         * support/regression/tests/sfr16.c: added test for the sfr32 bug
2124
2125 2005-10-04 Raphael Neider <rneider AT web.de>
2126
2127         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
2128           device/lib/pic16/pics.all: added pic18f1320
2129         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
2130
2131 2005-09-30 Raphael Neider <rneider AT web.de>
2132
2133         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
2134         * src/pic16/devices.inc: NEW, provides device descriptions
2135         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
2136
2137 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
2138
2139         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
2140           GETHBIT
2141
2142 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
2143
2144         * doc/sdccman.lyx: updated Highest Order Bit documentation,
2145           documented Any Order Bit, Higher Order Byte and Higher Order Word
2146         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
2147         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
2148           (optimizeGetAbit): new, to get any bit, not only the high bit,
2149           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
2150           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
2151           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
2152           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
2153             RIGHT_OP: also try GETBYTE, GETWORD optimization,
2154             GETABIT, GETBYTE, GETWORD: decorate them,
2155           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
2156           (ast_print): added GETABIT, GETBYTE, GETWORD
2157         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
2158         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
2159           (geniCodeBinary): new generic binary icode,
2160           (ast2iCode): added GETABIT, GETBYTE, GETWORD
2161         * src/port.h: updated comment for PORT.hasExtBitOp
2162         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
2163           (genGetByte): new, to get a single byte,
2164           (genGetWord): new, to get a word from a long,
2165           (gen51Code): added GETABIT, GETBYTE, GETWORD
2166         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
2167
2168 2005-09-23 Raphael Neider <rneider AT web.de>
2169
2170         * configure.in, configure: have device/lib/pic configured
2171         * device/lib/Makefile.in: added model-pic14
2172         * device/lib/clean.mk: added pic/ to clean rule
2173         * device/lib/pic: added rudimentary pic14 library providing support
2174           functions for multiplication/division/generic pointer access
2175         * src/SDCCopt.c (convilong): mark support functions as extern
2176           for pic14 port as well
2177         * src/pic/gen.c (genMult): added assertions,
2178           (genpic14Code): emit warning on unhandled iCodes
2179         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
2180         * src/pic/pcode.c (pCodeOpCopy),
2181         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
2182           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
2183           SFR_REGISTER}), made safe for future extensions
2184         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
2185           instructions even if preceeded by SKIP instructions (also remove
2186           them); removed unused code
2187         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
2188           prevents leaving parts of the structure uninitialized after copying
2189
2190 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
2191
2192         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
2193           ago by me
2194         * support/regression/tests/addsub.c: added test for the bug
2195
2196 2005-09-21 Raphael Neider <rneider AT web.de>
2197
2198         * device/include/pic16/pic18f1220.h,
2199           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
2200         * device/lib/pic16/Makefile.rules: added missing opening paren
2201         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
2202           are provided in genutils.c,
2203           (genUminusFloat,genUminus,genCmpEq): added asserts on different
2204           operand/result sizes,
2205           (genCmp): assert on NULL pointers first, then check deref'ed values
2206         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
2207           result size
2208
2209 2005-09-18 Raphael Neider <rneider AT web.de>
2210
2211         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
2212           as these are now unused,
2213           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
2214         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
2215           local, avoids uninitialized pointer dereference on r->name
2216         * src/pic16/ralloc.c (newReg): fixed indentation
2217
2218 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
2219
2220         * src/SDCCval.c (constVal): fixed bug 730366
2221         * support/Util/SDCCerr.c,
2222         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
2223
2224 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
2225
2226         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
2227
2228 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
2229
2230         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
2231
2232 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
2233
2234         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
2235           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2236         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
2237           (hex2dec): made hex_digit unsigned char, removed ascii dependance
2238         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
2239         * packihx/packihx.c (hexDigit): made c unsigned char
2240         * as/mcs51/lklibr.c (fndsym),
2241         * link/z80/lkgb.c (gb),
2242         * link/z80/lklibr.c (fndsym),
2243         * link/z80/lkrloc.c (relr),
2244         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
2245         * src/SDCC.lex (checkCurrFile, process_pragma),
2246         * src/SDCCglue.c (spacesToUnderscores),
2247         * src/SDCCmain.c (setParseWithComma, processFile),
2248         * src/asm.c (tvsprintf, printCLine),
2249         * src/avr/gen.c (emitcode, aopPut),
2250         * src/ds390/gen.c (emitcode),
2251         * src/hc08/gen.c (emitcode, emitinline),
2252         * src/mcs51/gen.c (emitcode, genInline),
2253         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2254           tokenizeLineNode),
2255         * src/pic/ralloc.c (debugLog),
2256         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
2257           tokenizeLineNode),
2258         * src/pic16/ralloc.c (debugLog),
2259         * src/z80/main.c (_process_pragma):
2260            made all ctype.h function calls safe
2261         * src/SDCCopt.c: include math.h for fabs
2262         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
2263           and used them throughout the code to make ctype.h function calls safe
2264         * src/ds390/main.c (asmLineNodeFromLineNode),
2265         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
2266         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
2267            unsigned char*
2268         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
2269           (newpCodeAsmDir): made ctype.h function calls safe
2270         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
2271           pic16_emitcode):  made lbp unsigned char*
2272         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
2273           (pic16_newpCodeAsmDir): made ctype.h function calls safe
2274         * src/xa51/gen.c (emitcode),
2275         * src/z80/gen.c (_emit2): made lbp unsigned char*
2276         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
2277            char*
2278
2279 2005-09-05 Raphael Neider <rneider AT web.de>
2280
2281         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
2282           access bank splitpoint
2283
2284 2005-09-05 Raphael Neider <rneider AT web.de>
2285
2286         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
2287
2288 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
2289
2290         * .version: changed to version 2.5.3
2291         * doc/sdccman.lyx: changed version to 2.5.3,
2292           documented --codeseg and --constseg and pragma codeseg and constseg,
2293           documented bit parameters (reentrant) and bit returning
2294         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
2295            currFunc->recvSize, but is this ok for all ports?
2296           (ast2iCode): result of ~ on unsigned char must be cast to int for
2297            bool to work
2298         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
2299           function pointers in bit space
2300         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
2301           (processFuncArgs): call port.reg_parm() with reentrancy info
2302         * src/port.h,
2303         * src/avr/main.c,
2304         * src/ds390/main.c,
2305         * src/hc08/main.c,
2306         * src/pic/main.c,
2307         * src/pic16/main.c,
2308         * src/xa51/main.c,
2309         * src/z80/main.c: port.reg_parm prototype extended with
2310           "bool reentrant" parameter
2311         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
2312           options.stackAuto for allocating bit register parameters
2313         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
2314           (genSend): set BitBankUsed if it is,
2315           (selectRegBank): factored out of genCall for use in genPcall,
2316           (genCall): removed redundant dtype assignmen, use selectRegBank,
2317           (genPcall): handle returning in Carry properly, save in F0 if needed,
2318           (genReceive): handle bit register parameters
2319         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
2320           (mcs51_assignRegisters): enable bit registers for all reentrant
2321            functions and don't set BitBankUsed unconditionally
2322         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
2323         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
2324         * support/regression/tests/funptrs.c: added tests for BOOL and for return
2325
2326 2005-08-27 Borut Razem <borut.razem AT siol.net>
2327
2328         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
2329         ppc-osx (Darwin) does not support -u option. It seems that it is
2330         supported only on Linux - GNU cp
2331
2332 2005-08-25 Borut Razem <borut.razem AT siol.net>
2333
2334         * sim/ucsim/gui.src/serio.src/Makefile.in,
2335           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
2336           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2337           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
2338           install and strip, since the strip at /usr/ccs/bin should be used
2339           on solaris
2340
2341 2005-08-24 Borut Razem <borut.razem AT siol.net>
2342
2343         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
2344
2345 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
2346
2347         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
2348         ffffffffu
2349
2350 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
2351
2352         * as/mcs51/aslink.h: completed lkrloc.c prototypes
2353         * as/mcs51/lkmain.c (link_main): fixed warning
2354         * device/include/stdbool.h: ds390 has no advanced bit support yet
2355         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
2356         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
2357         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
2358           and updated their macros
2359         * src/SDCCval.c (constVal): updated comment for renamed b_long
2360
2361 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
2362
2363         * as/mcs51/asdata.c: changed ctype['['] to BINOP
2364         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
2365           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
2366           (oprio): set priority for '['
2367         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
2368            and adb_24_bit
2369         * as/mcs51/asm.h: added defines R_BIT and S_BIT
2370         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
2371         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
2372         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
2373           added overlayable BIT_BANK area
2374         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
2375           (summary2): explain 'T' in legenda
2376         * as/mcs51/lkrloc.c: replaced old K&R style,
2377           (relr): added R_BIT processing,
2378           (errmsg): added "Bit-addressable relocation error",
2379           (adb_bit): added for converting from byte- to bit-addressable space,
2380           (adb_24_bit): added for converting from byte- to bit-addressable space
2381         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
2382            used in reentrant functions now even as return value
2383         * device/lib/_gptrput.c (_gptrput): removed obsolete code
2384         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
2385           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
2386         * src/SDCCglobl.h: added indicator BitBankUsed
2387         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
2388            the bit registers b0-b7
2389         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
2390           (geniCodeCast): fixed bug 1263853,
2391           (geniCodeLogicAndOr): put result in bool or char,
2392           (geniCodeReceive): added parameter func for accessing the return type,
2393           (geniCodeFunctionBody): pass func to geniCodeReceive
2394         * src/SDCCmain.c: added indicator BitBankUsed
2395         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
2396         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
2397           (checkSClass): don't put automatic bool/bit on stack,
2398           (checkFunction): removed check on function cannot return bit
2399         * src/SDCCsymt.h: added newBoolLink prototype
2400         * src/mcs51/gen.c (rb1regs): added bit registers,
2401           (movc): created for assigning to carry,
2402           (pushReg, popReg): created for pushing registers,
2403           (sameRegs): check both AOP_REG and AOP_CRY types,
2404           (aopOp): handle bit registers,
2405           (aopPut): optimization no self-assign,
2406           (saveRegisters): push reg->base (bits) only once for bit registers,
2407            and use pushReg,
2408           (unsaveRegisters): pop reg->base only once and use popReg,
2409           (assignResultValue): added parameter func and return in carry for bits,
2410           (genIpush): optimization no reload in A if not changed,
2411           (genSend): bit parameters in reentrant functions are passed in bit
2412            registers by first assigning to bits in B, then save registers and
2413            copy B to bits,
2414           (genCall): handle returning in Carry properly, save it in F0 if needed,
2415           (genPcall): updated assignResultValue call, this is not safe yet for bit
2416            returning function !!!
2417           (genFunction): don't generate equ's for bit registers and use pushReg,
2418           (genEndFunction): take care of bit returning functions and use popReg,
2419           (genRet): return bit in Carry,
2420           (genIfx): optimize bit registers and other directly addressable bits,
2421           (genReceive): updated assignResultValue call
2422         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
2423           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
2424            registers when using stack-auto
2425         * src/mcs51/ralloc.c (_G): added allBitregs,
2426           (regs8051): added the bit registers,
2427           (createStackSpil): use macro IS_BIT,
2428           (getRegBit): added to allocate a bit register, else spill,
2429           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
2430           (updateRegUsage): factored out to ease stepping while debugging,
2431           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
2432            also allocate bit registers,
2433           (fillGaps): handle bit registers,
2434           (findAllBitregs): added to create bit vector with all bit registers,
2435           (mcs51_allBitregs): returns this bit vector,
2436           (mcs51_assignRegisters): when using stack-auto use bit registers for
2437            passing parameters and creating local variables
2438         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
2439
2440 2005-08-22 Borut Razem <borut.razem AT siol.net>
2441
2442         * device/lib/Makefile.in: replaced find option -or with -o
2443           to make it run on solaris
2444
2445 2005-08-22 Raphael Neider <rneider AT web.de>
2446
2447         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
2448           fixes #1265442 (crash on Solaris)
2449
2450 2005-08-20 Borut Razem <borut.razem AT siol.net>
2451
2452         * configure, configure.in: added tests for libsocket and libnsl libraries,
2453           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
2454           from support/regression/Makefile.in
2455         * support/regression/Makefile.in: added
2456         * device/lib/pic16/Makefile.common.in: force make to use bash shell
2457         * sim/ucsim/libtool: regenerated on sparc-solaris
2458         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
2459           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
2460           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
2461           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
2462           sparc-solaris, which doesn't use GNU ld linker
2463         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
2464         * as/Makefile: find on sparc-solaris does not support -maxdepth option
2465
2466 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
2467
2468         * src/mcs51/peeph.def: updated comments
2469
2470 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2471
2472         * device/lib/_gptrget.c,
2473         * device/lib/_gptrput.c: slightly shorter
2474         * doc/sdccman.lyx: incremented version
2475         * src/mcs51/peeph.def: moved peephole comments to the line of first
2476           change to better keep line correlation, reanimated 186.e
2477         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
2478
2479 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
2480
2481         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
2482           David Saxton with quotes around file name.
2483
2484 2005-08-15 Borut Razem <borut.razem AT siol.net>
2485
2486         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
2487           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
2488           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
2489           make tests run on x86_64 platform
2490
2491 2005-08-13 Raphael Neider <rneider AT web.de>
2492
2493         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
2494           as it might be executed DURING a build (parallel make is wonderful)
2495
2496 2005-08-13 Raphael Neider <rneider AT web.de>
2497
2498         * device/lib/Makefile.in (port-specific-objects-pic16):
2499           revert to cp $(PORT)/bin/*.* $(PORTDIR)
2500         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
2501           dependency
2502         * device/lib/pic16/Makefile.rules: build subdirs before creating
2503           the library, removed builddir rule, create $(builddir) early in
2504           recurse rule, use empty recurse rule for leaf directories
2505         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
2506           mkdir errors (race condition), removed duplicate suffix "hex"
2507           from clean rules
2508         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
2509         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
2510           prevents mkdir -p from aborting on Alpha
2511
2512 2005-08-12 Raphael Neider <rneider AT web.de>
2513
2514         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
2515           db-statements in order to allow for arrays of pointers in code
2516           sections to be placed without interspersed 0-padding, fixes
2517           bug #1256215
2518         * (emitStatistics): fixed division by zero for pic18f1220
2519         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
2520           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
2521         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
2522         * (pic16_pCodeConstString): keep track of already emitted string
2523           literals to prevent "duplicate definitions of symbol _str_NR"
2524         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
2525           debug message
2526         * device/lib/Makefile.in: ignore failing PIC16 library builds
2527         * device/lib/pic16/Makefile: do not build if gputils are missing
2528         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
2529
2530 2005-08-10 Raphael Neider <rneider AT web.de>
2531
2532         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
2533           my last commit)
2534
2535 2005-08-10 Raphael Neider <rneider AT web.de>
2536
2537         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
2538           Rokas' patch to add the new fixed point type "__fixed16x16"
2539         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
2540           functions for __fixed16x16 arithmetics
2541         * device/lib/pic16: reimplemented the build system to support
2542           a separate build directory, better handling of libio (create
2543           the library in a separate subdir for each architecture) and
2544           easier configuration (centralized in Makefile.common)
2545
2546 2005-08-07 Raphael Neider <rneider AT web.de>
2547
2548         * src/pic16/gen.c (genrshTwo): fixed sign extension
2549         * src/pic16/device.c: added pic18f2320, 4220 and 4320
2550         * device/include/pic16/pic18f2220.h: changed some bit definitions,
2551           added T0CONbits
2552         * device/include/pic16/pic18f4220.h: NEW, header for
2553           pic18f4220 and pic18f4320
2554         * device/include/pic16/pic18fregs.h: added new devices,
2555           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
2556         * device/include/pic16/signal.h: resolved name clashes
2557           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
2558           to also allow testing for interrupt enable bits, added
2559           comments on how to use the macros
2560         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
2561         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
2562           register definitions for the devices
2563         * device/lib/pic16/pics.all: added new devices
2564         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
2565           allocated memory
2566         * device/lib/pic16/libc/stdlib/memfree: do not count
2567           the block header as free memory
2568         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
2569           simplified and added missing end-of-blocklist-marker
2570           (reported by Peter Onion, fixes #1252814)
2571         * (_mergeHeapBlock): fixed loop condition
2572         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
2573           len==0, restructured code
2574         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
2575           up a bit, reduced bitfield accesses, prevent endless loops
2576           in case of heap corruption
2577         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
2578           "unreferenced arguments/must return a value" warnings
2579         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
2580           replaced BAUDREG with SPBRG
2581         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
2582           device/lib/pic16/debug/gstack/gstack.c: replaced
2583           _naked, _asm, _endasm with __naked, __asm, __endasm
2584
2585 2005-08-05 Raphael Neider <rneider AT web.de>
2586
2587         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
2588           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
2589
2590 2005-08-05 Borut Razem <borut.razem AT siol.net>
2591
2592         * device/lib/Makefile.in: added missing ';'
2593         * configure: removed ^M characters
2594
2595 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2596
2597         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
2598           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
2599           License
2600
2601 2005-08-04 Borut Razem <borut.razem AT siol.net>
2602
2603         * configure.in: pic16 libraries build 2nd try - enable running
2604           configure in device/lib/pic16
2605         * configure: regenerated from configure.in
2606         * device/lib/Makefile.in: create $(PORT)/bin directory
2607
2608 2005-08-03 Raphael Neider <rneider AT web.de>
2609
2610         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
2611           to get/set values via pointers
2612         * (genUnpackBits,genPackBits): changed detection of
2613           ptr->bitfield vs. sym.bitfield, fixed access via generic
2614           pointers, removed dead (wrong) code for multibyte bitfields
2615         * (genNearPointerGet, genGenPointerGet): removed useless code,
2616           fixed bitfield detection, fixes #1250594
2617         * (genNearPointerSet): removed useless code
2618         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
2619           and introduced macro pic16_emitpcode that conditionally emits
2620           the origin of the following pCode (useful for debugging SDCC)
2621         * src/pic16/pcode.c: changed (and disabled) some debug outputs
2622         * (createDefmap): fixed handling of LFSR for --optimize-df
2623
2624 2005-08-02 Borut Razem <borut.razem AT siol.net>
2625
2626         * device/lib/Makefile.in: pic16 libraries build enabled since
2627           gputils-0.13.2 are now localy installed at sourceforge's compile farm
2628
2629 2005-08-02 Raphael Neider <rneider AT web.de>
2630
2631         * src/pic16/gen.c (genPackBits): removed deprecated warning
2632         * (genGenPointerSet): fixed bitfield detection
2633
2634 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2635
2636         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
2637
2638 2005-07-31 Raphael Neider <rneider AT web.de>
2639
2640         * device/lib/pic16/libdev/pic18f458.c,
2641           device/include/pic16/pic18f458.h: added missing T0CONbits
2642
2643 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
2644
2645         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
2646
2647 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
2648
2649         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
2650
2651 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2652
2653         * device/include/mcs51/at89c51ed2.h: added.
2654
2655 2005-07-23 Raphael Neider <rneider AT web.de>
2656
2657         * src/pic/gen.h: added emitpcode macro for debugging
2658         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
2659           and replace by macro adding debug information on demand
2660         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
2661         * (gencjne): tried to fix; replaced with correct (slower) code
2662         * (gen{Unp,P}ackBits): fixed single bit access
2663         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
2664         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
2665           previous instruction
2666         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
2667           register has to be handled with care (forbidding movement
2668           of assignments/uses, removing assignments completely, ...)
2669         * (pCodeOptime2pCodes): make use of regIsSpecial
2670         * added lots of debugging output (commented out)
2671         * src/pic/rallloc.c (deassignLRs): prevent operand registers
2672           from being reused as result UNLESS it is known to work
2673
2674 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
2675
2676         * support/Util/dbuf.h: include <stddef.h> for size_t
2677         * .version: changed to version 2.5.2
2678
2679 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2680
2681         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
2682
2683 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2684
2685         * src/hc08/gen.c (genMinus): fixed bug #1241835,
2686           (genModOneByte): removed needless psha/pula
2687
2688 2005-07-22 Raphael Neider <rneider AT web.de>
2689
2690         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
2691           have PIC14 handled like PIC16, fixes broken pic14 linker calls
2692         * src/pic/gen.c (resolveIfx): do not "invent" labels
2693         * (genSkipc): changed to positive logic
2694         * (genSkipCond): removed as no longer needed
2695         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
2696           backport from PIC16
2697         * (genLeftShift): check operands are in different registers
2698         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
2699           INCF does not update CARRY...
2700         * src/pic/main.c: fixed _linkCmd
2701         * src/pic/pcode.c (unlinkpCode): added inactive code
2702         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
2703           alive (do not assign result and operand overlapping registers)
2704
2705 2005-07-22 Raphael Neider <rneider AT web.de>
2706
2707         * src/pic/device.c (dump_sfr): replaced register declaration with
2708           call to emitSymbolToFile() to avoid duplicate symbols
2709         * (assignRelocatableRegisters): do not declare external symbols
2710         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
2711           right (take size of type, not etype)
2712         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
2713         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
2714         * (packRegsForAccUse): disabled assignment of WREG as
2715           the result reg to prevent occurence of just fixed #1235003,
2716           fixes #1242954
2717         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
2718           symbols (avoids duplicate symbols in .asm file)
2719         * (pic14emitRegularMap): use emitSymbolToFile()
2720         * src/pic/gen.c (aopOp): fixed spillLocation handling
2721         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
2722         * (genDataPointerSet): removed unneccessary variables/output
2723
2724 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
2725
2726         * as/mcs51/lkarea.c: enlarged codemap for banked memory
2727         * device/lib/mcs51/crtbank.asm: added # to 0x0F
2728
2729 2005-07-21 Raphael Neider <rneider AT web.de>
2730
2731         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
2732           architecture cannot handle them efficiently, fixes bug #1235003
2733         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
2734           check for empty sets before using them (fixes bug #1232190)
2735
2736 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
2737
2738         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
2739           (lnksect2): generate warnings for memory overlap
2740         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
2741           constseg to set the name of these segments so you can instruct the linker
2742           to place them in banks
2743         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
2744         * src/SDCCglobl.h: added MODEL_HUGE to enum,
2745           added code_seg and const_seg to options
2746         * src/SDCCglue.c (emitMaps): use options.const_seg,
2747           (createInterruptVect): put interrupt vectors in segment HOME,
2748           (glue): put HOME before static segment and put the main glue in HOME,
2749           (glue): use options.code_seg
2750         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
2751         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
2752           these segments so you can instruct the linker to place them in banks
2753           (linkEdit): use code_loc for HOME segment which should be the first
2754           segment in code memory now
2755         * src/SDCCmem.c: fixed more stuff like bug 1238386
2756         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
2757           (changePointer): don't change function pointers to code pointers for
2758           banked functions,
2759           (compareType): added exceptional check for banked function pointers
2760         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
2761         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
2762           after static in code memory
2763         * src/mcs51/gen.c: added aopLiteralLong prototype,
2764           (aopForSym): use getSize for functions,
2765           (genCall): generate banked calls over one trampoline __sdcc_banked_call
2766           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
2767           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
2768           the segment,
2769           (genPcall): use call for literal function pointers and generate banked
2770           calls over the one trampoline so there's only one place for the user to
2771           modify according to his/hers hardware,
2772           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
2773           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
2774         * src/mcs51/main.c: added keyword banked,
2775           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
2776         * support/Util/SDCCerr.c,
2777         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
2778           needed for passing the bank and address to the trampoline
2779         * device/lib/mcs51/crtbank.asm: added for bankswitching
2780         * device/lib/mcs51/Makefile: added crtbank
2781
2782 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2783
2784         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
2785           for fields at offset 0 of a struct or union as reported
2786           on 2005-07-07 in the developer mailing list.
2787
2788 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
2789
2790         * src/SDCCmem.c: fixed bug 1238386
2791
2792 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2793
2794         * src/mcs51/peeph.def: added labelrefcounting for peepholes
2795           (patch #1144962), added peephole 300, enabled 259.x
2796         * doc/sdccman.lyx: removed screenshot and provided link instead
2797
2798 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2799
2800         * doc/sdccman.lyx: added section about debugging with ddd
2801         * doc/figures/ddd_example.eps: screenshot of debugging session
2802
2803 2005-07-04 Raphael Neider <rneider AT web.de>
2804
2805         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
2806           like CODE pointers, fixes #1115683
2807         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
2808           call, fixes bugs #1232211, #1228110,
2809           fixed wrong casts to pCodeFlow from pCodeInstructions
2810
2811 2005-07-04 Raphael Neider <rneider AT web.de>
2812
2813         * src/pic/gen.c (popGet): changed assert to allow for
2814           bit operands
2815         * (popGetAddr): changed signature to provide
2816           an additional index, patched all call sites
2817         * (genCmpEq): handle literal-like operands correctly
2818         * (genAddrOf): added sanity checks on __code/__data pointers
2819         * (genAssign): added handling of symbols from __code section
2820         * (gencjne): do not generate code for comparisons whose result
2821           is neither stored nor used, fixes bug #1171114
2822         * (AccLsh, AccRsh): operate on operand instead of WREG
2823         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
2824           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
2825           by known count
2826         * rewrote complete shift-by-literal logic, commented unused
2827           functions out
2828         * (genConstPointerGet): get multiple bytes (if result size > 1),
2829           fixed handling of non-immediate addresses
2830         * (genPointerGet): handle CODE pointers like CONST pointers
2831         * (genpic14Code): insert C-SRC lines as Cource-pCodes
2832         * ({aop,op}_isLitLike): NEW, single place to decide whether an
2833           operand is to be treated as a literal or not
2834         * (mov2w,genPcall,genCmpEq),
2835           src/pic/genarith.c: use aop_isLitLike() to decide between
2836           literal/register contents
2837         * (addSign): added missing offset
2838         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
2839           only emit comment in debug-mode,
2840           use {aop,op}_isLitLike throughout the file
2841         * src/pic/glue.c: fix initializers for pointers (work in progress)
2842         * src/pic/pcode.c (get_op): honor index on _const symbols
2843         * ({reset,dump}pCodeStatistics): NEW, estimate code size
2844         * (dumppBlock): added pCode size estimation
2845         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
2846           check for IS_SYMOP before OP_SYMBOL'ing
2847         * fixed indentation, compacted switch-statements
2848         * (allocReg): find free register and allocate it instead of
2849           allocating new registers all the time
2850         * (deassignLRs): prevent POINTER_GET's from being assigned the same
2851           registers as its operands (necessary only for multibyte GETs)
2852
2853 2005-07-01 Raphael Neider <rneider AT web.de>
2854
2855         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
2856           debugging .asm-output macros FENTRY + FEXIT
2857         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
2858           way... I wonder...
2859         * (emitpComment): NEW, printf to pCode
2860         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
2861           offset handling
2862         * (popGetAddr): NEW, variant of popGet to access an immediates
2863           high(er) bytes instead of the n'th byte of memory they reference,
2864           replaced popGet with popGetAddr where neccessary
2865         * (genDataPointerGet): reactivated and fixed implementation
2866         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
2867           accesses
2868         * (genDataPointerSet): fixed multibyte assignments
2869         * (genpic14Code): fixed --i-code-in-asm handling
2870         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
2871         * (genPlus): fixed index-out-of-bounds error
2872         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
2873         * src/pic/ralloc.c: added debugging output macro FENTRY2
2874         * (spillThis): fixed indentation, enbraced for-body for clarity
2875         * (rematStr): commented out as now unused
2876         * (regTypeNum): commented out special spill case (overwrites
2877           arbitrary values)
2878         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
2879
2880 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
2881
2882         * doc/sdccman.lyx: documented sfr16/sfr32,
2883           added example for using storage class with function pointers
2884         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
2885
2886 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
2887
2888         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
2889         * device/lib/_itoa.c,
2890         * device/lib/_ltoa.c: optimized codesize
2891         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
2892           but don't know how to suppress the double warning.
2893         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
2894         * support/Util/SDCCerr.c,
2895         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
2896
2897 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
2898
2899         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
2900           fixed old K&R prototypes
2901         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
2902         * device/lib/_gptrget.c,
2903         * device/lib/_gptrgetc.c,
2904         * device/lib/_gptrput.c: changed versions for new memory indicator values,
2905           also new versions for small generic pointers and banked generic pointers
2906         * src/port.h: added const_name
2907         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
2908         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
2909         * src/SDCCcse.c (findPrevIc): check all associative operators
2910         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
2911         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
2912         * src/SDCCmem.c: updated comments,
2913           set far-space to 0 for pdata, results in optimized code
2914         * src/SDCCmem.h: added macro CONST_NAME
2915         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
2916           moving the info into the highest bits, see also gptrget/gptrput
2917         * src/src.dsp: added sdcc.ico to project files
2918         * src/avr/gen.c (genCast): fixed bug 0x%d
2919         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
2920         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
2921           relation between ptr_type and DCL_TYPE,
2922           (genCast): fixed bug 0x%d
2923         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
2924           (CODE)" for const_name
2925         * src/hc08/gen.c (genCast): fixed bug 0x%d
2926         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
2927           (hc08_port): added "CONST (CODE)" for const_name
2928         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
2929           (aopForRemat, adjustArithmeticResult): disconnected direct relation
2930           between ptr_type and DCL_TYPE,
2931           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
2932           operand* and took AOP() inside function so sfr-ness can be checked,
2933           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
2934           new prototype,
2935           (genFunction, genEndFunction): optimized stack setup,
2936           (genMinus): optimized for literals with ending zeroes (in bytes),
2937           (genCast): fixed bug 0x%d
2938         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
2939           (mcs51_port): added "CONST (CODE)" for const_name
2940         * src/mcs51/peeph.def: made rule 226 more generic
2941         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
2942         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
2943         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
2944         * src/z80/main.c (z80_port): added NULL for const_name,
2945           (gbz80_port): added NULL for const_name
2946         * support/regression/tests/bug663539.c,
2947         * support/regression/tests/sfr16.c: new tests
2948
2949 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
2950
2951         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
2952
2953 2005-06-24 Raphael Neider <rneider AT web.de>
2954
2955         * device/lib/pic16/libdev/pic18f[68][567]20.c:
2956           corrected typos...
2957         * device/include/pic16/signal.h: added USBIF
2958           and SIG_USB
2959
2960 2005-06-24 Raphael Neider <rneider AT web.de>
2961
2962         * device/lib/pic16/libdev/pic18f2455.c,
2963           device/include/pic16/pic18f2455.h: NEW
2964         * device/include/pic16/pic18fregs.h,
2965           device/lib/pic16/pics.all,
2966           src/pic16/device.c: added 18f2455
2967         * device/lib/pic16/libdev/pic18f[68][567]20.c,
2968           device/include/pic16/{pic18f[68][567].h,usart.h}:
2969           replaced MULTIPLE_USARTS define with more relaible
2970           compatibility sfrs (for USART access)
2971
2972 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
2973
2974         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
2975           and the output asm file line is printed on two lines.
2976
2977 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2978
2979         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
2980           BGT, BLE, BHI, and BLS instructions
2981         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
2982           genCmpEq): removed
2983         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
2984           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
2985           fixes bug #1216342
2986         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
2987
2988 2005-06-15 Raphael Neider <rneider AT web.de>
2989
2990         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
2991         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
2992         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
2993           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
2994           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
2995
2996 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2997
2998         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
2999           Marcel Telka in bug #1215704
3000
3001 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
3002
3003         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
3004           located in shared memory bank.
3005
3006 2005-05-31 Raphael Neider <rneider AT web.de>
3007
3008         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
3009           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
3010           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
3011
3012 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
3013
3014         * device/lib/_strncpy.c: fixed the fix
3015
3016 2005-05-26 Raphael Neider <rneider AT web.de>
3017
3018         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
3019           initializers with \0, bug #1208187
3020         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
3021           intializers with \0, bug #1208187
3022
3023 2005-05-26 Raphael Neider <rneider AT web.de>
3024
3025         * src/pic16/glue.c (pic16_printIvalChar): fixed string
3026           initializers with \0, bug #1208187
3027         * src/pic16/main.c (_process_pragma): added sanity checks
3028           for stack position and size, emit warnings when appropriate
3029
3030 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
3031
3032         * device/lib/_strncpy.c: fixed not filling with \0
3033
3034 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3035
3036         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
3037           createFunction),
3038         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
3039           compound_statement),
3040         * src/SDCCsymt.h,
3041         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
3042
3043 2005-05-24 Raphael Neider <rneider AT web.de>
3044
3045         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
3046
3047 2005-05-24 Raphael Neider <rneider AT web.de>
3048
3049         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
3050           TRISE definitions, closes bug #1162453
3051
3052 2005-05-22 Raphael Neider <rneider AT web.de>
3053
3054         * src/pic16/main.c (_process_pragma): check for missing
3055           arguments to pragmas code and udata
3056         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
3057           consistency fixes to match other headers (thanks to Jim Paris)
3058         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
3059
3060 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
3061
3062         * src/SDCCicode.c (isOperandEqual): fixed missing ;
3063
3064 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
3065
3066         * support/regression/tests/bug1198642.c: new test
3067         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
3068         * src/SDCCcse.c (findPrevIc): added comment, please have a look
3069         * support/scripts/resource.h,
3070         * support/scripts/resource.rc,
3071         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
3072         * support/scripts/sdcc.ico: added 32x32 icon
3073
3074 2005-05-18 Raphael Neider <rneider AT web.de>
3075
3076         * device/lib/pic16/libdev/pic18f*.c,
3077         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
3078           keywords to "__sfr" and "__at (X)"
3079         * device/include/pic16/pic18fregs.h: added pic18f4520
3080         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
3081           #1203088 (MPLAB compatibility)
3082
3083 2005-05-17 Raphael Neider <rneider AT web.de>
3084
3085         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
3086         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
3087         * device/lib/pic16/pics.all: added new devices
3088         * src/pic16/device.c: added support for pic18f4520
3089
3090 2005-05-16 Raphael Neider <rneider AT web.de>
3091         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
3092         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
3093         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
3094           convenience function for bit access
3095
3096 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
3097
3098         * device/lib/printf_large.c: fixed bug 1193299
3099         * support/regression/tests/bug1057979.c: added test %3.3s
3100
3101 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3102
3103         * device/include/mcs51/8051.h,
3104         * device/include/mcs51/8052.h: made parseable with lint
3105         * device/include/mcs51/lint.h: added include file for (sp)lint
3106         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
3107         * doc/cdbfileformat.lyx,
3108         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
3109
3110 2005-05-14 Raphael Neider <rneider AT web.de>
3111
3112         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
3113         * device/lib/pic16/libc/stdlib/itoa.c (new)
3114         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
3115         * device/lib/pic16/libio/Makefile: exclude subdir according to
3116           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
3117         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
3118         * src/pic16/gen.c (genFunction): prevent annoying warning
3119         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
3120           nameclashes on BeOS
3121         * support/cpp2/cppmain.c (cpp_output_string): new
3122         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
3123           fixes bug 1116802
3124
3125 2005-05-13 Borut Razem <borut.razem AT siol.net>
3126
3127         * src/SDCCmain.c (linkEdit): fixed bug 1195202
3128
3129 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3130
3131         * .version: changed to version 2.5.1; back to bleeding edge development
3132
3133 2005-05-11 Borut Razem <borut.razem AT siol.net>
3134
3135         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
3136           generate PDF version 1.3 documents
3137
3138 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3139
3140         * .version: changed to version 2.5.0
3141
3142 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3143
3144         * doc/sdccman.lyx: updated weblinks, index and smaller updates
3145
3146 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3147
3148         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
3149         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
3150         well as many smaller updates.
3151         * .version: changed to version 2.5.0-pre1
3152
3153 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
3154
3155         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
3156
3157 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
3158
3159         * support/regression/tests/bug1185672.c: added
3160         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
3161           bug 1185672
3162         * src/mcs51/gen.c (genCall): added comments, made it look safer
3163         * src/mcs51/gen.c (genEndFunction): simplified
3164
3165 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
3166
3167         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
3168
3169 2005-04-14 Borut Razem <borut.razem AT siol.net>
3170
3171         * fixed bug 1045046 - SIGSEGV with really simple code?:
3172           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
3173           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
3174
3175 2005-04-14 Borut Razem <borut.razem AT siol.net>
3176
3177         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
3178           src/pic16/device.h: temporarily disabled experimental #inline pragma
3179           for 2.5.0 release
3180
3181 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
3182
3183         * device/include/z80/stdio.h,
3184         * device/include/z80/string.h: removed these highly incomplete files so
3185           SDCC can use the default ones in device/include/
3186
3187 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3188
3189         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
3190         gcc warning.
3191         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
3192         fix sdcpp warnings.
3193
3194 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3195
3196         * device/include/malloc.h: removed redundant __reentrant prototypes
3197         * device/lib/_mullong.c: added working xstack variant in asm (C version
3198           doesn't pass regression tests)
3199         * device/lib/bpx.c: used __data and made bpx char for mcs51
3200         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
3201           (createFunction): fixed bug with xstackPtr
3202         * src/SDCCcse.c: corrected comments
3203         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
3204           (killDeadCode, eBBlockFromiCode): removed unused code
3205         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
3206           corrected comments
3207         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
3208           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
3209           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
3210           (genModOneByte): fixed warning in MSVC
3211         * src/mcs51/main.c (): added comments
3212         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
3213
3214 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
3215
3216         * src/SDCCmain.c (linkEdit): oops, changed one line too many
3217
3218 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
3219
3220         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
3221
3222 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
3223
3224         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
3225         characters arrays of larger size than the declared one.
3226
3227 2005-04-10 Borut Razem <borut.razem AT siol.net>
3228
3229         * src/pic/gen.c (genInline),
3230           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
3231           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
3232           (findNextInstruction), (findPrevInstruction),
3233           (findInstructionUsingLabel),
3234           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
3235         * src/pic/pcode.c (findLabel): added missing '\n'
3236         * src/src.dsp: added SDCCdwarf2.c to the project
3237
3238 2005-04-09 Borut Razem <borut.razem AT siol.net>
3239
3240         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
3241
3242 2005-04-08 Raphael Neider <rneider AT web.de>
3243
3244         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
3245           into the chain after a given one) and mergeDefmapSymbols (combine
3246           defmap entries for each symbol per pcode)
3247         * (createDefmap): have defmap entries merged in the end
3248         * (defmapReplaceSymRef): split defmap entries covering two accesses to
3249           a symbol before replacing one access type's symbol, merge symbols in
3250           the end (replacement symbol might already have an entry)
3251         * (assignValnums): keep reference to written WREG intact
3252
3253 2005-04-08 Raphael Neider <rneider AT web.de>
3254
3255         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
3256           Alpha)
3257
3258 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
3259
3260         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
3261         bytes
3262
3263 2005-04-07 Raphael Neider <rneider AT web.de>
3264
3265         * device/include/pic16/usart.h: added compatibility defines for
3266           devices with more than one USART
3267         * device/include/pic16/pic18f[68][567]20.h: activated above defines
3268
3269 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3270
3271         * device/lib/Makefile.in: updated for port specific include
3272
3273 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3274
3275         * support/regression/ports/mcs51/spec.mk: added mcs51 include
3276
3277 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
3278
3279         * device/include/8051.h,
3280         * device/include/8052.h,
3281         * device/include/at89S8252.h,
3282         * device/include/at89c55.h,
3283         * device/include/at89x051.h,
3284         * device/include/at89x51.h,
3285         * device/include/at89x52.h,
3286         * device/include/mcs51reg.h,
3287         * device/include/reg51.h,
3288         * device/include/reg764.h,
3289         * device/include/regc515c.h,
3290         * device/include/sab80515.h: (re)moved these 12 files
3291         * device/include/mcs51/8051.h,
3292         * device/include/mcs51/8052.h,
3293         * device/include/mcs51/at89S8252.h,
3294         * device/include/mcs51/at89c55.h,
3295         * device/include/mcs51/at89x051.h,
3296         * device/include/mcs51/at89x51.h,
3297         * device/include/mcs51/at89x52.h,
3298         * device/include/mcs51/mcs51reg.h,
3299         * device/include/mcs51/reg51.h,
3300         * device/include/mcs51/reg764.h,
3301         * device/include/mcs51/regc515c.h,
3302         * device/include/mcs51/sab80515.h: and added them here
3303
3304 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
3305
3306         * device/include/stdarg.h: changed SDCC specific keywords to double
3307           underlined form.
3308         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
3309           mcs51 and ds390.
3310         * device/include/hc08/mc68hc908gp32.h,
3311         * device/include/hc08/mc68hc908jb8.h,
3312         * device/include/hc08/mc68hc908jkjl.h,
3313         * device/include/hc08/mc68hc908qy.h: fixed comments
3314         * device/include/mcs51/README: updated
3315         * device/include/mcs51/c8051f120.h: added PINRSF
3316         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
3317         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
3318           amidst code. Also inline is not supported.
3319
3320 2005-04-06 Raphael Neider <rneider AT web.de>
3321
3322         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
3323         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
3324           callers stack/frame pointers
3325
3326 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
3327
3328         * device/include/pic16/usart.h: added, missing in previous commit,
3329         * device/include/pic16/adc.h: fixed typo,
3330         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
3331         commit,
3332         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
3333         <p18fxxx.inc>
3334         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
3335         uninitialized because a bug appears with gplink
3336         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
3337         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
3338         complains for unrecognised option
3339
3340 2005-04-05 Raphael Neider <rneider AT web.de>
3341
3342         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
3343           structs as well (using memcpy)
3344         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
3345           on ISRs (GOTO has no label)
3346         * src/pic16/device.h: added OF_OPTIMIZE_DF
3347         * src/pic16/main.c: added compiler switch --optimize-df to enable the
3348           new data flow analysis/optimization
3349         * src/pic16/pcode.c: added (prototypes for and implementation of)
3350           dataflow analysis functions, fixed pCodeInstructions' inCond and
3351           outCond values, made RCALL a branch instruction
3352         * (pic16_unlinkpCode): keep C line if possible
3353         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
3354           C line moved if possible
3355         * (pic16_getRegFrompCodeOp): NEW, improved version of...
3356         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
3357           to use new pic16_getRegFrompCodeOp (works for more SFRs)
3358         * (pic16_BuildFlow): fixed skip instructions with label (did not start
3359           new flow)
3360         * (pic16_getJumptabpCode): NEW, needed in...
3361         * (LinkFlow): fixed handling of jumptables, calls and conditional
3362           branches
3363         * (pic16_InsertCommentAfter): NEW
3364         * (pic16_pCodeReplace): made verbose and flow preserving
3365         * (AnalyzeFlow): added call to data flow analysis
3366         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
3367         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
3368         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
3369
3370 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3371
3372         * src/SDCCast.c (decorateType): fixed bug #1105626
3373
3374 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
3375
3376         * device/include/asm/pic16/features.h,
3377         * pic18f*.h headers,
3378         * device/include/pic16/adc.h,
3379         * device/include/pic16/delay.h,
3380         * device/include/pic16/i2c.h,
3381         * device/include/pic16/malloc.h,
3382         * device/include/pic16/stdio.h,
3383         * device/include/pic16/stdlib.h,
3384         * device/include/pic16/string.h,
3385         * device/lib/pic16/libc/stdio/printf_tiny.c,
3386         * device/lib/pic16/libc/stdio/printf_small.c,
3387         * device/lib/pic16/libc/stdio/strmgpsim.c,
3388         * device/lib/pic16/libc/stdio/strmmssp.c,
3389         * device/lib/pic16/libc/stdio/strmusart.c,
3390         * device/lib/pic16/libc/stdio/vfprintf.c,
3391         * device/lib/pic16/libc/stdlib/ltoa.c,
3392         * device/lib/pic16/libc/stdlib/putchar.c,
3393         * device/lib/pic16/libc/stdlib/x_ftoa.c,
3394         * device/lib/pic16/libc/stdlib/memchrpgm.c,
3395         * device/lib/pic16/libc/stdlib/memchrram.c,
3396         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
3397         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
3398         * device/lib/pic16/libio/adc/adcbusy.c,
3399         * device/lib/pic16/libio/adc/adcread.c,
3400         * device/lib/pic16/libio/adc/adcsetch.c,
3401         * device/lib/pic16/libio/usart/ubaud.c,
3402         * device/lib/pic16/libio/usart/ubusy.c,
3403         * device/lib/pic16/libio/usart/udrdy.c,
3404         * device/lib/pic16/libio/usart/uopen.c,
3405         * device/lib/pic16/libio/usart/uputc.c,
3406         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
3407         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
3408         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
3409         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
3410         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
3411         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
3412         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
3413         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
3414         specific keywords to double underlined form,
3415         * device/lib/pic16/libc/Makefile.rules,
3416         * device/lib/pic16/libsdcc/Makefile.rules,
3417         * device/lib/pic16/libm/Makefile,
3418         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
3419         to compile with C standard set in Makefile.common
3420         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
3421         rand.c and crc.c in compilation process,
3422         * device/lib/pic16/libsdcc/int/divuint.c,
3423         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
3424         `c' from signed to unsigned,
3425         * device/lib/pic16/startup/crt0.c,
3426         * device/lib/pic16/startup/crt0i.c,
3427         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
3428         keywords to double underlined form, bug fixes in _do_cinit function
3429         which prevented the correct initialization of the .idata segment,
3430         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
3431         core to enter a infinite loop
3432         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
3433
3434 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3435
3436         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
3437
3438 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3439
3440         * device/include/Makefile.in: add support for hc08 subdirectory
3441         * device/include/hc08/: new subdirectory
3442         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
3443         Lucas Loizaga, thanks!
3444         * device/include/hc08/mc68hc908qy.h,
3445         * device/include/hc08/mc68hc908gp32.h,
3446         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
3447         their own directory. Changed internal macro names to use the compiler
3448         reserved namespace. Changed SDCC specific keywords to double
3449         underlined form.
3450         * device/include/math.h,
3451         * device/include/malloc.h,
3452         * device/include/stdarg.h,
3453         * device/include/stdbool.h
3454         * device/include/string.h,
3455         * device/include/tinibios.h,
3456         * device/include/ds400rom.h,
3457         * device/include/8051.h,
3458         * device/include/8052.h,
3459         * device/include/80c51xa.h,
3460         * device/include/at89c55.h,
3461         * device/include/at89S8252.h,
3462         * device/include/at89x51.h,
3463         * device/include/at89x52.h,
3464         * device/include/ds80c390.h,
3465         * device/include/reg764.h,
3466         * device/include/regc515c.h,
3467         * device/include/sab80515.h,
3468         * device/include/mcs51/c8051f000.h,
3469         * device/include/mcs51/c8051f018.h,
3470         * device/include/mcs51/c8051f020.h,
3471         * device/include/mcs51/c8051f040.h,
3472         * device/include/mcs51/c8051f060.h,
3473         * device/include/mcs51/c8051f120.h,
3474         * device/include/mcs51/c8051f300.h,
3475         * device/include/mcs51/c8051f310.h,
3476         * device/include/mcs51/c8051f320.h,
3477         * device/include/mcs51/c8051f330.h,
3478         * device/include/mcs51/c8051f350.h,
3479         * device/include/z180.h: Changed SDCC specific keywords to double
3480         underlined form.
3481
3482 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
3483
3484         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
3485         18F4455,
3486         * (pic16_assignConfigWordValue): disable testing of configuration
3487         register value with config mask,
3488         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
3489         function with port->fun_prefix,
3490         * (genFunction): when generating a naked interrupt function never
3491         create an absolute segment placed in interrupt vector address, place
3492         the actual interrupt function at IVA instead, when an interrupt
3493         function is generated with unspecified interrupt then do not create
3494         the absolute section,
3495         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
3496         code for generating a call to generic pointer get/put function with
3497         a call to function pic16_callGenericPointer(),
3498         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
3499         the call to the generic pointer get/put functions with prefixing the
3500         function name with port->fun_prefix,
3501         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
3502         * src/pic16/main.c (_process_pragma): prefix function with
3503         port->fun_prefix,
3504         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
3505         calling assembler, old 18Fxxxx macro is deprecated,
3506         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
3507         PC_ASMDIR in while condition,
3508         * (findInstruction): add PC_ASMDIR in while condition,
3509         * (buildCallTree): prefix main with port->fun_prefix,
3510         * (pic16_pCode2str): fixed bug that didn't emit the memory access
3511         identifier for variable with banked access in instructions BTFSS,
3512         BTFSC, BCF, BSF, BTG
3513         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
3514         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
3515         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
3516         perform optimization when enviroment variable NO_REG_OPT is set,
3517         * (insideLRBlock): NEW, return 1 if register is inside an
3518         INF_LOCALREGS block,
3519         * (RemoveRegFromLRBlock): remove a register that is completely
3520         eliminated by register optimization, but it is still left in local
3521         register store/restore in/from stack block,
3522         * (Remove2pcodes): after removing register, check to see if it
3523         should be removed from local register store/restore in/from stack
3524         block,
3525         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
3526         DUMMY_READ_VOLATILE,
3527
3528         * device/include/pic16/adc.h: minor prototype modifications and
3529         update,
3530         * device/include/pic16/malloc.h: added GPL notice various
3531         modifications,
3532         * device/include/pic16/stdint.h: NEW, standard header for ints
3533         * device/include/pic16/delay.h: NEW, header for delay functions,
3534         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
3535         delay1mtcy,
3536         * device/include/pic16/signal.h: NEW, header providing helper macros
3537         for implementing signal handlers,
3538         * device/include/pic16/stdio.h: added prototypes for functions,
3539         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
3540         prototypes for stdin and stdout, added macro PUTCHAR to
3541         automatically implement putchar function prototype,
3542         * device/include/pic16/usart.h: modified and updated USART library,
3543         * device/lib/pic16/libio/adc/,
3544         * device/lib/pic16/libio/i2c: some modifications to improve library
3545         performance,
3546         * device/lib/pic16/libc/stdio/: modifications for the new printf*
3547         family of functions,
3548         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
3549         family of functions and other sources,
3550         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
3551         of the PIC18Fxx[28] devices,
3552         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
3553         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
3554         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
3555         _do_cinit function, because the previous failed when local variables
3556         where not placed in the same memory bank,
3557         * device/lib/pic16/libsdcc/char/: various modifications to improve
3558         library performance,
3559         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
3560         information on the new functions of the c library and more...
3561
3562 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3563
3564         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
3565
3566 2005-03-26 Raphael Neider <rneider AT web.de>
3567
3568         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
3569           if condition == CARRY)
3570         * (genCmp): adapted to new genSkipc semantics
3571         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
3572           on rIfx (genCmp was broken)
3573
3574 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3575
3576         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
3577         * src/z80/main.c (_keywords[]),
3578         * src/SDCCglobal.h (struct options),
3579         * src/SDCC.y,
3580         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
3581         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
3582         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
3583         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
3584         always available in leading double underscore form. The C99 support is
3585         mostly missing, but it's a start.
3586         * support/regression/tests/bug-227710.c: fixed nonconforming use of
3587         reserved identifier "__data".
3588
3589 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
3590
3591         * src/mcs51/peeph.def: fixed bug 1170013
3592
3593 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
3594
3595         * device/include/mcs51reg.h: fixed bug 842007
3596
3597 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3598
3599         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
3600         last time.
3601
3602 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3603
3604         * src/port.h (struct PORT),
3605         * src/avr/ralloc.c (avr_assignRegisters),
3606         * src/avr/main.c,
3607         * src/ds390/ralloc.c (ds390_assignRegisters),
3608         * src/ds390/main.c,
3609         * src/hc08/ralloc.c (hc08_assignRegisters),
3610         * src/hc08/main.c,
3611         * src/mcs51/ralloc.c (mcs51_assignRegisters),
3612         * src/mcs51/main.c,
3613         * src/pic/ralloc.c (pic14_assignRegisters),
3614         * src/pic/main.c,
3615         * src/pic16/ralloc.c (pic16_assignRegisters),
3616         * src/pic16/main.c,
3617         * src/xa51/ralloc.c (xa51_assignRegisters),
3618         * src/xa51/main.c,
3619         * src/z80/ralloc.c (z80_assignRegisters),
3620         * src/z80/ralloc.h,
3621         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
3622         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
3623         * src/SDCCcse.h,
3624         * src/SDCCdflow.c (computeDataFlow),
3625         * src/SDCCdflow.h,
3626         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
3627         * src/SDCCloop.h,
3628         * src/SDCCcflow.c (*),
3629         * src/SDCCcflow.h,
3630         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
3631         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
3632         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
3633         immedDom() returning wrong block; probably fixes bug #1160833)
3634
3635 2005-03-20 Borut Razem <borut.razem AT siol.net>
3636
3637         * support/scripts/inc2h.pl: WIN32 port
3638
3639 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
3640
3641         * device/lib/makefile.in: added abs.c and labs.c
3642
3643 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
3644
3645         * device/include/stdint.h: added
3646         * device/lib/abs.c: added
3647         * device/lib/labs.c: added
3648         * device/include/stdlib.h: added abs() and labs() prototypes
3649         * device/lib/libsdcc.lib: added abs and labs
3650         * device/include/float.h,
3651         * device/lib/_fsmul.c,
3652         * device/lib/printf_fast.c,
3653         * device/lib/printf_tiny.c: updated comments
3654
3655 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3656
3657         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
3658         bug #1164313
3659
3660 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3661
3662         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
3663         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
3664
3665 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
3666
3667         * device/lib/printf_large.c: removed inline assembly for portability and
3668           readability. Use printf_fast if speed or size are more important.
3669         * src/pic16/gen.c: removed conditions around use of DEBUGpc
3670         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
3671
3672 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
3673
3674         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
3675         prevent compiler warning
3676
3677 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3678
3679         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
3680         moved to level 0 and declared as static. Also they are explicit
3681         placed in access bank. This was necessery because some times they
3682         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
3683         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
3684         optimizations. Currently only compare to unsigned char is implemented,
3685         * src/pic16/gen.c: added fReturnIdx array,
3686         * (struct resolvedIfx) is moved to gen.h and made public,
3687         * (struct _G): added sregsAlloc and sregsAllocSet fields,
3688         * (aopForSym): added an optimization to directly store in stack of
3689         the operand of a SEND iCode,
3690         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
3691         but as registers instead (AOP_REG) using the fReturnIdx array,
3692         * (pic16_freeAsmop): remove the freed register from the
3693         _G.sregsAlloc field,
3694         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
3695         a compare of 'WREG',
3696         * (pic16_popGetTempRegCond): changed function prototype, now
3697         function takes also a bitVector argument v which holds the current
3698         set of registers that are allocated for stack access by aopForSym,
3699         registers allocated in aopForSym for accessing stack symbols are not
3700         any more part of the functions usedRegs field,
3701         * (genCall): some times aopOp is called for a stack variable to be
3702         send, aopForSym might perform the push, if this is true make sure
3703         that genCall doesn't push the variable twice by testing _G.resDirect,
3704         * (genFunction): changed testing for unspecified interrupt number
3705         from 256 to INTNO_UNSPEC,
3706         * modified selection scheme of frame pointer generation. Previously
3707         if function did use local registers a frame pointer was generated,
3708         now a frame pointer is generated only if function has arguments
3709         (that need PLUSW2 register access), or has stack arguments, or the
3710         compiler is not instructed to omit the frame pointer,
3711         * (genEndFunction): before restoring local registers that were saved
3712         in the function preamble, also restore the registers that *might*
3713         have been allocated for stack access,
3714         * (genRet): removed some old comments,
3715         * (genCmp, the active (RN's) version): added a call to the
3716         pic16_genCmp_special function to perform the compare with a more
3717         robust and optimized way,
3718         * (genInline): a feature has been added in inline code generation,
3719         which allows a wildcard variable substitution when writing inline
3720         assembly. Code is incomplete and experimental therefore undocumented,
3721         * (genCast): changed order of aopOp for result and right to allow
3722         aopForSym to directly load the result if possible,
3723         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
3724         perform an optimized compare on some selected special occasions,
3725         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
3726         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
3727         generate an IVT any more,
3728         * src/pic16/main.c (pic16_optionsTable): added command line option
3729         --optimize-cmp,
3730         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
3731         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
3732         macros,
3733         * src/pic16/NOTES: Raphael Neider added in list of active developers
3734         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
3735         jumptable_end to prevent bug #,
3736         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
3737         inCond and outCond fields,
3738         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
3739         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
3740         turn off register spilling,
3741         * (packRegsForOneUse): synced with other ports' versions although it
3742         is not used currently,
3743         * (pic16_packRegisters): added an optimization while reading
3744         structure bitfields, some registers may be saved (malloc code is
3745         decreased by 80 bytes)
3746
3747 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
3748
3749         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
3750         left is a bitfield, if yes, then don't optimize assignment. Perhaps
3751         this can be optimized more?
3752
3753 2005-03-10 Raphael Neider <rneider AT web.de>
3754
3755         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
3756           genNearPointerGet): (hopefully) fixed access to bitfields via
3757           pointers (p->bitN = x; and x = p->bitN; failed)
3758
3759 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
3760
3761         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
3762
3763 2005-03-09 Raphael Neider <rneider AT web.de>
3764
3765         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
3766
3767 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
3768
3769         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
3770         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
3771           (regTypeNum): set REG_BIT type if necessary
3772         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
3773         * support/regression/tests/critical.c: check bug 1144613
3774
3775 2005-03-02 Raphael Neider <rneider AT web.de>
3776
3777         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
3778
3779 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3780
3781         * src/avr/ralloc.c (serialRegAssign),
3782         * src/ds390/ralloc.c (serialRegAssign),
3783         * src/hc08/ralloc.c (serialRegAssign),
3784         * src/mcs51/ralloc.c (serialRegAssign),
3785         * src/pic/ralloc.c (serialRegAssign),
3786         * src/pic16/ralloc.c (serialRegAssign),
3787         * src/xa51/ralloc.c (serialRegAssign),
3788         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
3789
3790 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
3791
3792         * src/SDCCast.c (decorateType): fixed bug 1124787
3793
3794 2005-02-20 Hubert Sack <sack AT digiplan.de>
3795         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3796
3797         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
3798         patch #1121755
3799
3800 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3801
3802         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
3803         to keep the correct label reference count when adding/removing references
3804         to labels. A peephole file using this is appended to patch #1144962.
3805
3806 2005-02-14 Raphael Neider <rneider AT web.de>
3807
3808         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
3809         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
3810         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
3811           retrievals of result operand's value on assignment
3812
3813 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
3814
3815         * device/include/pic16/string.h: modified prototype for memccpy()
3816         to memccpy(void *, void *, char, size_t)
3817         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
3818         check whether to omit frame pointer or not,
3819         * (genInline): convert all occurences of "\n" to LF in inline
3820         assembler blocks, this helps formatting the inline text,
3821         * (pic16_loadFSR0): modified prototype,
3822         * (genNearPointerGet, genNearPointerSet): reorganization of code,
3823         removed some 8051 legacy code,
3824         * (genPackBits): enabled handling bitfields exceeding one byte in size,
3825         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
3826         before allocating temporary registers in functions,
3827
3828 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
3829
3830         * support/regression/tests/bitvars.c: corrected the "fix"
3831
3832 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
3833
3834         * support/regression/tests/bitvars.c,
3835         * support/regression/tests/bitwise.c,
3836         * support/regression/tests/rotate.c: "fixed" problems on Alpha
3837
3838 2005-02-10 Raphael Neider <rneider AT web.de>
3839
3840         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
3841           different size for Alpha
3842         * src/pic16/gen.c (genCmpEq) : improved compare with 0
3843
3844 2005-02-09 Raphael Neider <rneider AT web.de>
3845
3846         * src/SDCC.lex(doPragma) : save and restore warning options as well
3847           (also added new stack plus clone- and copyAndFreeSDCCERRG())
3848         * have #pragma less_pedantic set the errorlevel to WARNING
3849           (fixes #1117001)
3850         * (cloneOptimize) : fixed wrong malloc's size
3851         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
3852           facilitate correct handling of #pragma (save|restore)
3853
3854 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
3855
3856         * src/mcs51/gen.c: removed non-standard C nameless struct/union
3857
3858 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
3859
3860         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
3861
3862 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
3863
3864         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
3865
3866 2005-02-02 Raphael Neider <rneider AT web.de>
3867
3868         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
3869         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
3870         * (pic16_storeForReturn): fixed to allow returning function pointers
3871         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
3872         * device/include/pic16/{stddef.h,stdbool.h}: added
3873
3874 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
3875
3876         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
3877
3878 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
3879
3880         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
3881         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
3882          appeared to be required
3883
3884 2005-01-31 Borut Razem <borut.razem AT siol.net>
3885
3886         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
3887           include/mcs51 and include/z80 directories to the package
3888
3889 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3890
3891         * src/hc08/gen.c (genFunction): fixed bug #1112752
3892
3893 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3894
3895         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
3896
3897 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3898
3899         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
3900
3901 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
3902
3903         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
3904
3905 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
3906
3907         * device/include/c8051fxxx.h: removed these 6 files
3908         * device/include/mcs51/c8051fxxx.h: added these 11 new files
3909
3910 2005-01-26 Raphael Neider <rneider AT web.de>
3911
3912         * src/pic16/gen.c (genAssign): fixed assignment from longs
3913           in codespace (were cut to three bytes)
3914         * (genDummyRead): implemented (except for CODESPACE...),
3915           fixed bug #1108575
3916         * src/pic16/glue.c (emitStatistics): beautified
3917         * device/lib/pic16/libm/Makefile: added include path
3918
3919 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3920
3921         * src/z80/gen.c (aopPut): fixed bug #1103902
3922
3923 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3924
3925         * device/lib/expf.c: fixed bug #1095792
3926
3927 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
3928
3929         * device/lib/pic16/libm: added Math library sources
3930
3931 2005-01-24 Raphael Neider <rneider AT web.de>
3932
3933         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
3934           to enable upcast to pCodeOpReg2 (there is no type tag to
3935           differenciate the two and pic16_popGet2p cast into PCOR2)
3936         * src/pic16/main.c (_process_pragma): fixed another malloc bug
3937           (sizeof(sectNames) changed to sizeof(sectName))
3938           Both patches fix segfaults under MinGW.
3939
3940 2005-01-23 Raphael Neider <rneider AT web.de>
3941
3942         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
3943           Safe_[mc]?alloc()'ed variables
3944         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
3945           of (byte sized) temporaries (assign them to WREG for now)
3946         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
3947           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
3948           this might fix SIGSEGVs on MinGW...
3949         * src/SDCCopt.c (killDeadCode): restored original behaviour
3950           (volatile operands might get thrown away though)
3951
3952 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
3953
3954         * src/pic16/gen.c: fixed bug #1106975,
3955         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
3956         pointer update, INTCON is saved, global interrupts are disabled and
3957         restored after updateing TOS.
3958         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
3959         * added function attribute 'shadowregs' to take advantage of shadow
3960         registers,
3961         * added function attribute 'wparam' as an alternative to the wparam
3962         pragma,
3963         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
3964         user declares a non-ISR function as 'shadowregs',
3965         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
3966
3967 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
3968
3969         * .version: bumped version number to 2.4.8
3970         * device/lib/pic16/pics.all: list of PIC18F devices supported by
3971         pic16 port,
3972         * device/lib/pic16/libio/i2c/: I2C module support library,
3973         * device/include/pic16/i2c.h: I2C support library header,
3974         * device/lib/pic16/libc/stdio/: standard IO support sources,
3975         * (printf_small.c): printf_small() source, supports float print,
3976         * (printf_tiny.c): printf_tiny() source, does not support floats,
3977         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
3978         enable global optimizations for entire library source, other
3979         Makefiles in the source tree are also modified to reflect this,
3980         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
3981         function,
3982         * doc/sdccman.lyx: updated to reflect new changes,
3983         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
3984         sym->onStack if-case,
3985         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
3986         sbit, idata, _idata, xdata, _xdata,
3987         * added pragma library, to link an external library, (see doc),
3988         * removed command line options, --pomit-config-words, --pomit-ivt,
3989         --pleave-reset-vector,
3990         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
3991         when calling assembler to reflect memory model used, also define
3992         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
3993         reflect stack model used,
3994         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
3995         on stack return NULL,
3996
3997 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
3998
3999         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
4000           of the operands is volatile. Fixes #1020220
4001
4002 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
4003
4004         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
4005         * (OptimizeRegUsage): make sure that there is really no other flow where
4006           the first pCode is used
4007
4008 2005-01-22 Raphael Neider <rneider AT web.de>
4009
4010         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
4011           to fix #1106967 (pCode->seq are not set up correctly)
4012
4013 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4014
4015         * src/SDCCglue.c (glue): make sure code area is declared before the
4016         static initialization area.
4017
4018 2005-01-21 Raphael Neider <rneider AT web.de>
4019
4020         * device/lib/Makefile.in: fixed test for pic16 install dir
4021         * device/lib/pic16/*/Makefile*: modified compile flags to enable
4022           optimizations
4023         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
4024           added --optimize-goto compiler switch and pragma wparam documentation
4025         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
4026         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
4027           and PRODH closing bug #1071770 (peephole optimizer)
4028
4029 2005-01-19 Raphael Neider <rneider AT web.de>
4030
4031         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
4032           cmdLine buffers (used when calling sdcpp...) are large enough
4033           (MAX_PATH=256 truncates arguments leading to system halts when
4034           used in MinGW...)
4035         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
4036         * (genUminus): rewritten to for efficiency
4037         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
4038           used uninitialized in some cases)
4039         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
4040           copy the third byte from the int -- now assumes 0x80 (data memory)
4041         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
4042           operands (genAddLit expects the iCode's operands to swapped as
4043           well), fixed leftover bytes (crashed for short left operands)
4044         * (pic16_genMinusDec): performance improvements, removed false
4045           PIC14 emitSKPNCs
4046         * (pic16_genMinus): fixed to cope with differently sized operands
4047         * src/pic16/glue.c (pic16_glue): added new banksel optimization
4048           for --obanksel > 1
4049         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
4050         * src/pic16/graph.[ch]: implementation of directed graphs, used by
4051           new banksel optimization
4052         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
4053           analysis for temporary registers (segfaults...)
4054         * src/pic16/peeph.def: added rule
4055
4056 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
4057
4058         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
4059         which converts a float number to its ASCII representation
4060         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
4061         functions to convert the fractional and integer part of a float to ASCII,
4062         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
4063         realloc.c): added _MALLOC_SPEC to explicit place variables in data
4064         ram
4065         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
4066         _STATMEM macros,
4067         * device/include/pic16/adc.h: added GPL info,
4068         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
4069         a pCodeOp as tested operand,
4070         * (genNearPointerGet): optimized bit testing, does not use
4071         intermediate register for bit value, test directly instead with
4072         BTFSS, BTFSC, works only for single bits,
4073         * (genpic16Code): dump the name of the iCode in the asm,
4074         * src/pic16/ralloc.c (decodeOp): removed static declaration and
4075         renamed to pic16_decodeOp,
4076         * (serialRegAssign): do not allocate a temporary register for iCode
4077         sequences that test a single bit for 1/0
4078
4079 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
4080
4081         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
4082         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
4083         access stack and frame pointers. They are initially assigned to
4084         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
4085         accessing SFRs. Updated all occurences of modification of stack or
4086         frame pointer in gen.c and pcode.c,
4087         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
4088         assigning of a literal value to pointers,
4089         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
4090         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
4091         selected
4092
4093 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
4094
4095         * doc/sdccman.lyx: update documentation about stack pragma, added
4096         some info for stack memory models
4097
4098 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4099
4100         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
4101
4102 2005-01-08 Raphael Neider <rneider AT web.de>
4103
4104         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
4105           udata sections to fix bug #1097823
4106
4107 2005-01-05 Raphael Neider <rneider AT web.de>
4108
4109         * src/pic16/gen.c (genGenericShift): added handling of differently
4110           sized left operand and result
4111
4112 2005-01-04 Raphael Neider <rneider AT web.de>
4113
4114         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
4115         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
4116           to hold the condition bit)
4117         * added new version of genCmp (old code available via #define)
4118         * added new version of genShiftLeft/genShiftRight in a generic
4119           way, now supports shifting by negative values
4120         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
4121           shiftCount (expected by genGenericShift)
4122         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
4123         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
4124           dump
4125         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
4126           is an invalid literal too...)
4127
4128 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
4129
4130         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
4131         from Raphael Neider,
4132         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
4133         for 8-bit literals. This fixes some literal operands which are sign
4134         extended to 16-bits ints when instruction needs only 8-bits.
4135
4136 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
4137
4138         * device/lib/logf.c: added mcs51 assembly version
4139         * device/lib/expf.c: added mcs51 assembly version
4140         * device/lib/_logexpf.c: new shared asm code for expf and logf
4141         * device/include/math.h: add defines for assembly math library
4142         * device/lib/Makefile.in: build new _logexpf.c
4143         * device/lib/libfloat.lib: use new _logexpf.c
4144
4145 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4146
4147         * src/pic/device.c
4148         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
4149           device types which have less than 0x7f registers.
4150
4151 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
4152
4153         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
4154
4155 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4156
4157         * device/lib/printf_fast.c: only build on supported arch.
4158         * device/lib/printf_tiny.c: only build on supported arch.
4159         * device/lib/printf_fast_f.c: only build if asm float lib
4160         * device/lib/_fsget1arg.c: only build if asm float lib
4161         * device/lib/_fsget2args.c: only build if asm float lib
4162         * device/lib/_fsnormalize.c: only build if asm float lib
4163         * device/lib/_fsreturnval.c: only build if asm float lib
4164         * device/lib/_fsrshift.c: only build if asm float lib
4165         * device/lib/_fsswapargs.c: only build if asm float lib
4166         * device/include/stdio.h: don't provide print_fast,
4167           print_fast_f, print_tiny prototypes if --xstack used
4168
4169 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
4170
4171         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
4172         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
4173           to the SOURCES
4174
4175 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
4176
4177         * device/lib/printf_fast_f.c: same as printf_fast, but
4178           with floating point enabled
4179         * device/lib/printf_fast.c: minor tweaks
4180         * device/include/stdio.h: add printf_fast_f
4181
4182 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4183
4184         * src/SDCCmain.c: make --float-reent default for mcs51
4185         * device/lib/_fsadd.c: added mcs51 assembly version
4186         * device/lib/_fssub.c: added mcs51 assembly version
4187         * device/lib/_fsmul.c: added mcs51 assembly version
4188         * device/lib/_fsdiv.c: added mcs51 assembly version
4189         * device/lib/_fseq.c: added mcs51 assembly version
4190         * device/lib/_fsneq.c: added mcs51 assembly version
4191         * device/lib/_fsgt.c: added mcs51 assembly version
4192         * device/lib/_fslt.c: added mcs51 assembly version
4193         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
4194         * device/lib/Makefile.in: add _fscmp to build
4195         * device/lib/libfloat.lib: add _fscmp to build
4196
4197 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
4198
4199         * device/lib/_fs2slong.c: added mcs51 assembly version
4200         * device/lib/_fs2sint.c: added mcs51 assembly version
4201         * device/lib/_fs2schar.c: added mcs51 assembly version
4202         * device/lib/_fs2ulong.c: added mcs51 assembly version
4203         * device/lib/_fs2uint.c: added mcs51 assembly version
4204         * device/lib/_fs2uchar.c: added mcs51 assembly version
4205         * device/lib/_slong2fs.c: added mcs51 assembly version
4206         * device/lib/_sint2fs.c: added mcs51 assembly version
4207         * device/lib/_schar2fs.c: added mcs51 assembly version
4208         * device/lib/_ulong2fs.c: added mcs51 assembly version
4209         * device/lib/_uint2fs.c: added mcs51 assembly version
4210         * device/lib/_uchar2fs.c: added mcs51 assembly version
4211         * device/include/float.h: added #define to select asm vs c
4212
4213 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
4214
4215         * device/lib/printf_fast.c: improvements to float output
4216         * device/include/float.h: add defines for assembly float library
4217         * device/lib/_fsget1arg.c: receive 1 float arg
4218         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
4219         * device/lib/_fsnormalize.c: normalize a float
4220         * device/lib/_fsreturnval.c: return float, various helper routines
4221         * device/lib/_fsrshift.c: right shift a float's mantissa
4222         * device/lib/_fsswapargs.c: swap 2 floats
4223         * device/lib/Makefile.in: build these 6 new files for mcs51
4224         * device/lib/libfloat.lib: add these 6 files to the library
4225
4226 2004-12-26 Borut Razem <borut.razem AT siol.net>
4227
4228         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
4229           built by gcc 3.4.2
4230
4231 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
4232
4233         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
4234           and fully reentrant and register bank neutral.
4235         * device/lib/printf_fast.c: added float (not enabled by default),
4236           added compact/slower integer (also not enabled by default),
4237           improved size/speed of fast integer code, other minor changes
4238         * device/include/stdio.h, device/lib/Makefile.in,
4239           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
4240
4241 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
4242
4243         * src/pic16/pcode.c: declaring variables other than at the start of a
4244           block is not supported in C by VC6.
4245
4246 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
4247
4248         * applied a previous patch from Raphael Neider that wasn't included
4249         in the previous commits, which fixes infinite loops within jumptable
4250         improvements,
4251         * made some fixes that previous patches introduced
4252
4253 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
4254
4255         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
4256         that fixes an issue with AOP_PCODE asmop's offset,
4257         * (pic16_popCopyReg): update instance field too,
4258         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
4259         function of pic port,
4260         * (genCmp, genAnd, genAssign),
4261         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
4262
4263 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
4264
4265         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
4266         variables initial values to idata section,
4267         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
4268         variables in some functions. This utilizes parmBytes field of iCode
4269         structure to hold the offset of the variable in stack. (might be
4270         able to use the stack field too?)
4271         * applied patch from Raphael Neider # ### , # ###
4272         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
4273         variable initial values in idata section,
4274         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
4275         for static variables with initial value
4276         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
4277         applied fix in while loop from Raphael Neider.
4278
4279 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
4280
4281         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
4282         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
4283         * src/ds390/ralloc.c (serialRegAssign): spill bits
4284         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
4285         * support/Util/SDCCerr.c,
4286         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
4287         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
4288         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
4289
4290 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
4291
4292         * device/include/sdcc-lib.h: inserted LGPL, added includes
4293           asm/ds390/features.h and asm/mcs51/features.h
4294         * device/include/asm/default/features.h,
4295         * device/include/asm/gbz80/features.h,
4296         * device/include/asm/z80/features.h: added empty _AUTOMEM
4297           and _STATMEM
4298         * device/include/asm/ds390/features.h,
4299         * device/include/asm/mcs51/features.h: added files with defines for
4300           _AUTOMEM and _STATMEM indicating automatic and static storage class
4301         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
4302         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
4303         * src/SDCCicode.c (geniCodeCast),
4304         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
4305         * src/SDCCloop.c (loopInduction): removed unused variable lr
4306         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
4307           to convertToFcall to include char modulo (RFE 1065037), added check
4308           if left operand is unsigned and use abs of literal value
4309         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
4310           as it doesn't work after conversion from peephole.def to peephole.rul
4311         * src/mcs51/gen.c (toBoolean): added check for size,
4312           (genModOneByte): optimized code for signed char modulo a literal
4313           power of 2 (thanks to Hubert Sack),
4314           (genRRC): removed unnecessary "clr c",
4315           (genRLC): replaced "add a,acc" with cheaper "rlc a"
4316         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
4317           jump optimization,
4318           swapped rules 256.c and 256.d,
4319           extended 256.d by using new multiple checks (thanks Erik),
4320           added rules 256.e and 256.f,
4321           updated rule 261.a and 261.b to new generated code
4322         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
4323
4324 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4325
4326         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
4327           induction related bugs, including first part of bug #1074377
4328
4329 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
4330
4331         * applied patch from bug-report #1076292,
4332         * applied patches for genAnd and Goto-optimizations for Raphael
4333         Neider,
4334         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
4335         dump a less iCode information,
4336         * src/pic16/device.h (pic16_options_t): added field debgen,
4337         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
4338         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
4339         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
4340         puclic,
4341         * (various functions): added macros FENTRY and FENTRY2 to functions,
4342         to emit function prologue,
4343         * (various functions): fixed indentation,
4344         * (genNearPointerGet): fixed loading of FSR0,
4345         * (genPackBits): applied patch from Raphael Neider to fix updating
4346         of FSR0 and touching only the modified bits,
4347         * src/pic16/genarith.c (various functions): added macros FENTRY to
4348         emit function prologue in comments,
4349         * src/pic16/pcode.h: added functions debugf2, debugf3,
4350         * src/pic16/ralloc.c: partial fix for packForPush caused
4351         segmentation fault,
4352
4353 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4354
4355         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
4356           <stsp AT users.sourceforge.net> with reversed byte order
4357         * support/regression/tests/rotate.c: added (ds390 skips some tests)
4358
4359 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4360
4361         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
4362           bug #1074377
4363         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
4364         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
4365
4366 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4367
4368         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
4369
4370 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4371
4372         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
4373           conditions,
4374           (setFromConditionArgs): friendly operand parser for peephole rules,
4375           (operandBaseName, operandsNotRelated): new peephole condition
4376           "operandsNotRelated" -- similar to "operandsNotSame", but takes
4377           architecture specific register naming into account, handles n-way
4378           comparisons, and supports quoted literals
4379         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
4380
4381 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4382
4383         * src/mcs51/peeph.def: fixed bug #1076940
4384
4385 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
4386
4387         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
4388
4389 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4390
4391         Adding support for replacing ljmps with sjmps in jumptables
4392         generated for switch statements. For now you need to set the
4393         environment variable SDCC_SJMP_JUMPTABLE to enable this.
4394         Now 4 algorithms for mcs51 jumptable generation are used:
4395         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
4396         addresses loaded pc-relative for up to 112 cases and stack-pushing
4397         target addresses loaded with offset from dptr for up to 256 cases.
4398
4399         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
4400         * src/mcs51/main.c: adapted constants for switch table generation
4401         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
4402
4403 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
4404
4405         * device/lib/printf_large.c (_print_format): fixed bug 1073386
4406         * support/regression/tests/bug1057979.c: added test for bug 1073386
4407
4408 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4409
4410         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
4411         compilers
4412
4413 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
4414
4415         * src/pic16/device.h,
4416         * src/pic16/genarith.c,
4417         * src/pic16/glue.c,
4418         * src/pic16/main.c,
4419         * src/pic16/pcode.c: applied patches #1068154 and #1070213
4420
4421 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
4422
4423         Large cummulative patch for pic16 port.
4424         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
4425         to call when a stack overflow occurs,
4426         * (malloc.h): added CVS Id tag,
4427         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
4428         variable,
4429         * added libc directory. The current version of LibC contains string
4430         functions, ctype functions and macros and some functions of the
4431         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
4432         be extensively tested in the future. Standard disclaimer here.
4433         Library is not automatically build yet. But one can build it by
4434         invoking 'make' inside the libc directory.
4435         * added ADC library under libio. Preliminary version yet.
4436
4437         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
4438         * src/pic16/gen.c (aopForRemat): asmop size is filled by
4439         aopForRemat() now and not by pic16_aopOp(),
4440         * (pic16_popGetTempReg): removed warning messgae when allocating
4441         temporary registers, its a buggy feature and will be removed,
4442         * (pic16_popGet): set register instance field in AOP_CRY,
4443         * (pic16_outBitC): fixed for results in size greater than 1,
4444         * (genUminusFloat): fixed for pic16, ported code from mcs51,
4445         * (pic16_storeForReturn): optimized return of 0,
4446         * (genCmp): experimental code for new genCmp which uses PIC18's
4447         special compare&skip instructions. Initial tests fail some times
4448         with variables grater than 1 byte in size, so new code is disabled,
4449         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
4450         a single bit,
4451         * (genCast): began a fix to optimize the casting of a bit to another
4452         bit, now assigning a bitfield to another bitfield will fail, sorry,
4453         * src/pic16/main.c: disabled the use of lr-support feature,
4454         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
4455         * added some function prototypes, added function _debugf prototype,
4456         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
4457         bits with offset (case PO_GPR_BIT),
4458         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
4459         command line,
4460         * (isBankInstruction): modified to return 0 for no banking instruction,
4461         and 1 for banking instruction,
4462         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
4463         caused stop processing pCodes after a inline assembly block,
4464         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
4465         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
4466         registers when it shouldn't,
4467         * src/pic16/ralloc.c (allocReg): add preliminary support for
4468         supporting a limited set of temporary registers,
4469
4470 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4471
4472         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
4473           genDataPointerSet): ensure assignments always copy in MSB to LSB
4474           order,
4475           (loadRegFromAop): recognize CLRH optimization,
4476           (genFunction): optimize RECEIVE iCodes in reentrant functions
4477
4478 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4479
4480         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
4481           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
4482           selected.
4483         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
4484         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
4485           contiguous with data
4486
4487 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4488
4489         * device/lib/_gptrget.c (_gptrget),
4490         * device/lib/_gptrgetc.c (_gptrgetc),
4491         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
4492           instead of sjmp to ret
4493         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
4494           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
4495
4496 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4497
4498         * .version: bumped version to 2.4.7
4499         * device/lib/_gptrget.c (_gptrget): is now _naked
4500         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
4501         * device/lib/_gptrput.c (_gptrput): is now _naked
4502         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
4503           (createFunction): fixed xstack
4504         * src/SDCCglue.c (emitMaps): set allocation required for bit area
4505         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
4506           or bit either,
4507           (geniCodeCritical): store original interrupt state in an iTemp bit
4508           var unless stack-auto
4509         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
4510         * src/SDCCmain.c (setIncludePath): added include/target to search path
4511         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
4512         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
4513           prototype,
4514           (processFuncArgs): put bit vars in bit area
4515         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
4516           unsaveRBank): fixed xstack,
4517           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
4518           (genFunction, genEndFunction): fixed xstack,
4519           (genAssign): optimization don't walk backwards through mem
4520         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
4521         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
4522         * support/regression/Makefile: also make library (for stack-auto) when
4523           making "all" and added "test-mcs51-xstack-auto"
4524         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
4525         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
4526         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
4527         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
4528         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
4529           make-library by MAKE_LIBRARY
4530         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
4531           regression tests for xstack
4532         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
4533         * support/regression/tests/critical.c: test for critical on mcs51
4534
4535 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4536
4537         * support/regression/ports/ucz80/spec.mk: use include and lib files from
4538           built version of sdcc instead of installed version
4539
4540 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4541
4542         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
4543         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
4544           vprintf.c now
4545         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
4546         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
4547           WARNING: remove device/lib/build/z80/printf.o by hand when
4548           updating from previous build!
4549         * device/lib/z80/printf.c: updated comment
4550         * support/regression/tests/bug1057979.c: test all ports now
4551         * support/regression/tests/bug1065458.c: file added
4552
4553 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4554
4555         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
4556           *_start and *_end symbols for static functions
4557
4558 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
4559
4560         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
4561           and search crt0.o in all library paths,
4562           (setIncludePath): proper handling of --nostdinc,
4563           (setLibPath): proper handling of --nostdlib
4564         * support/regression/Makefile,
4565         * support/regression/ports/ds390/spec.mk,
4566         * support/regression/ports/gbz80/spec.mk,
4567         * support/regression/ports/hc08/spec.mk,
4568         * support/regression/ports/mcs51/spec.mk,
4569         * support/regression/ports/mcs51-large/spec.mk,
4570         * support/regression/ports/mcs51-stack-auto/spec.mk,
4571         * support/regression/ports/z80/spec.mk: use include and lib files from
4572           built version of sdcc instead of installed version
4573         * doc/sdccman.lyx: fixed typo in --nostdinc
4574
4575 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
4576
4577         * src/pic/pcode.c,
4578         * src/pic/device.c,
4579         * src/pic/ralloc.c,
4580         * src/pic/gen.c : added support to generate code for struct bit fields.
4581
4582 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4583
4584         * as/xa51/xa_version.h,
4585         * device/include/errno.h,
4586         * device/include/regc515c.h,
4587         * device/lib/_itoa.c,
4588         * device/lib/_ltoa.c,
4589         * device/lib/ser_ir_cts_rts.c,
4590         * sim/ucsim/xa.src/glob.cc,
4591         * sim/ucsim/xa.src/inst_gen.cc,
4592         * sim/ucsim/xa.src/xa_bit.cc,
4593         * sim/ucsim/xa.src/xa_sfr.cc,
4594         * sim/ucsim/z80.src/inst_dd.cc,
4595         * sim/ucsim/z80.src/inst_fdcb.cc,
4596         * support/scripts/keil2sdcc.pl,
4597         * src/pic16/pic16.dsp,
4598         * src/pic16/pic16a.dsp: corrected cvs line endings
4599         * device/lib/printf_large.c: fixed bug 1057979
4600         * src/pic16/gen.c: fixed non-C standard code
4601         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
4602         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
4603         * support/regression/ports/mcs51/support.c: reload T1 asap
4604         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
4605           pdata use and clear idata startup behaviour
4606         * support/regression/tests/bug1057979.c: added
4607
4608 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
4609
4610         * device/examples/ds390/ow390/ad26.h,
4611         * device/examples/ds390/ow390/cnt1d.h,
4612         * device/examples/ds390/ow390/crcutil.c,
4613         * device/examples/ds390/ow390/ownet.h,
4614         * device/examples/ds390/ow390/owsesu.c,
4615         * device/examples/ds390/ow390/swt12.h,
4616         * device/examples/ds390/ow390/swtoper.c,
4617         * device/examples/ds390/ow390/temp10.h,
4618         * device/examples/ds390/ow390/thermodl.c,
4619         * device/examples/ds390/tinitalk/tinitalk.dsp,
4620         * device/examples/ds390/tinitalk/tinitalk.dsw,
4621         * device/examples/mcs51/clock/hw.h,
4622         * device/examples/mcs51/simple2/go.bat,
4623         * device/examples/serialcomm/windows/serial.h,
4624         * device/examples/xa51/dummy.c,
4625         * device/examples/xa51/hello.c,
4626         * device/include/80c51xa.h,
4627         * device/include/at89x051.h: corrected cvs line endings
4628
4629 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
4630
4631         * src/pic16/main.c (options): added command line --gstack, to trace
4632         stack over/under flows,
4633         * added pragma 'wparam' to allow passing first byte of function
4634         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
4635         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
4636         call to __gstack_test function and sets up the symbol as extern,
4637         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
4638         * popaop): added call to pic16_testStackOverflow,
4639         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
4640         wparamList list,
4641         * (genCall, genPcall): now all parameters are passed via stack
4642         except in functions that are pass to wparam pragma in which WREG is
4643         used too,
4644         * (genPcall): REENTRANT flag is checked to see if variable prototype
4645         contains reentrant keyword, don't call a non-reentrant function, via
4646         a reentrant function pointer or vice versa, functions are never
4647         passed via WREG,
4648         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
4649         D.Winkler,
4650         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
4651         SIGSEGV when accessing a NULL register stucture,
4652         * (pic16_printGPointerType): modified to handle UPPER modifier for
4653         function initializers, changed prototype of function to simpler one,
4654         * (pic16_printIvalFuncPtr): check to see if function is already
4655         added in externs list,
4656         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
4657         optimized a move from W to SFR with a move to the same register
4658         later after a CALL,
4659         * device/lib/pic16/debug: NEW directory, contains debug features
4660         which are enabled when linking with libdebug.lib, currently command
4661         line option --gstack enables stack pointer tracing for over/under
4662         flow, corresponding sources are in debug/gstack
4663
4664 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
4665
4666         * doc/sdccman.lyx: updated SDCC version,
4667         * (PIC16 port): update list of command line options,
4668         * src/pic16/device.h (structure pic16_options_t): added field gstack
4669         to enable stack overflow tracing on push/pops,
4670         * src/pic16/device.c (statistics structure): added statistics
4671         structure,
4672         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
4673         pic16_dump_int_registers): increase statistics counters for each
4674         * variable which is encountered
4675         * (pic16_dump_usection): emit each .udata variable to its own udata
4676         section,
4677         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
4678         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
4679         parameters via stack, otherwise use old scheme,
4680         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
4681         assembler output file,
4682         * src/pic16/main.c: added command line options --gstack to enable
4683         push/pop tracing for stack overflow,
4684         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
4685         instructions): added size of each instruction,
4686         * (pic16_countInstruction): estimate size of instructions in
4687         the_pFile list, inline assembly blocks are not counted,
4688         * (pic16_FixRegisterBanking): trace previous register usage, when
4689         banksel optimizations is greater than 0, don't emit a redudant
4690         banksel directive,
4691
4692 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
4693
4694         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
4695         * src/pic16/ralloc.c : applied same fix for pic16.
4696         * src/pic/gen.c : tidied it up a little.
4697
4698 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4699
4700         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
4701         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
4702
4703 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4704
4705         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
4706
4707 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4708
4709         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
4710         non-reentrant function __modsint in the interrupt function (thus
4711         corrupting math operations during serial I/O)
4712         * device/lib/ser_ir.c: as above, changed buffersize
4713         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
4714         256.c,d for zeroing
4715         * doc/Makefile: added option -t for rsync
4716
4717 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4718
4719         * src/SDCCast.h (struct ast),
4720         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
4721
4722 2004-10-20 Borut Razem <borut.razem AT siol.net>
4723
4724         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
4725         package
4726
4727 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
4728
4729         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
4730         makefile targets,
4731         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
4732         support functions to replace long sequences of MOVFF's from access
4733         bank registers to stack and vice versa,
4734         * src/pic16/device.h: added new field opt_flags, where optimization
4735         flags can be set to enable certain features,
4736         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
4737         * pBlock, (genFunction, genEndFunction): surroung loop for
4738         saving/loading used registers in stack with PC_INFO pCodes,
4739         INF_LREGS. Code in between can then be optimized by pCode optimizer
4740         to support function calls,
4741         * (genDataPointerSet): fixed bug which loaded float fields in
4742         structures with corrupt data,
4743         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
4744         in a standard way debug info on stderr. Feature used for developing
4745         and debugging only,
4746         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
4747         obsolete chunks of code,
4748         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
4749         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
4750         * pic16/src/pcode.c (pic16_newpCodeInfo,
4751         * (pic16_newpCodeOpLocalRegs),
4752         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
4753         feature,
4754         * (pic16_pCodeConstString): printing of the initial value of a
4755         symbol as a comment is inhibited since parsing was already done by
4756         copyStr and output is corrupt,
4757         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
4758
4759 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4760
4761         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
4762
4763 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
4764
4765         * as/mcs51/lkarea.c: removed old K&R style,
4766           (lnksect): changed check on boundary error,
4767           (lnksect2): changed check on boundary error,
4768           (lnksect2): extend XSTK to end of page if size = 1
4769         * as/mcs51/lkmain.c: removed old K&R style,
4770           (Areas51): create l_IRAM symbol
4771         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
4772         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
4773           model-mcs51-stack-auto, added model-mcs51-xstack-auto
4774         * device/lib/_mullong.c: added version to be compiled with xstack
4775         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
4776         * device/lib/mcs51/crtxclear.asm: clear pdata as well
4777         * device/lib/mcs51/crtxstack.asm: fixed comment
4778         * src/SDCCglue.c: maxInterrupts defaults to 0,
4779           (emitMaps): added pdata,
4780           (createInterruptVect): (re)moved default,
4781           (glue): added pdata,
4782           (glue): moved __start__xstack to XSTK with default size 1
4783         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
4784           and options.float_rent when options.stackAuto is set,
4785           (linkEdit): only write XDATA_NAME if provided on command line
4786         * src/SDCCmem.h,
4787         * src/SDCCmem.c: added pdata
4788         * src/port.h: added pdata_name to PORT
4789         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
4790           (saveRegisters, unsaveRegisters): removed usage of B,
4791           (genMinus): fixed accumulator clash,
4792           (genJumpTab): added comment, this needs another look
4793         * src/mcs51/gen.c: added check for "B in use" paranoia,
4794           added pushB() and popB()
4795         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
4796           chance
4797         * src/avr/main.c,
4798         * src/ds390/main.c,
4799         * src/hc08/main.c,
4800         * src/mcs51/main.c,
4801         * src/pic/main.c,
4802         * src/pic16/main.c,
4803         * src/xa51/main.c,
4804         * src/z80/main.c: (reset_regparms) made void parameter explicit and
4805           added PSEG (PAG,XDATA) or NULL to port specifier
4806         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
4807         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
4808           (_mcs51_genInitStartup): removed __start__xstack equ,
4809           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
4810         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
4811         * src/z80/gen.c (_rleAppend): fixed warnings
4812         * support/regression/tests/zeropad.c: added pdata test
4813         * .version: bumped to 2.4.6
4814
4815 2004-10-17 Borut Razem <borut.razem AT siol.net>
4816
4817         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
4818         as a part of nightly build
4819
4820 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
4821
4822         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
4823         WREG holds the first byte function parameters,
4824         * (aopForSym): take special case for symbols which are in FARSPACE
4825         but in CODESPACE too,
4826         * (assignResultValue): modified to take into account _G.useWreg,
4827         * (genCall): don't use wreg for parameter passing when function is
4828         declared as reentrant, too, added optimization INCF to stack
4829         pointer when stack parameter count is 1,
4830         * (genFunction, genEndFunction): refurnished and fixed to not using
4831         wreg for passing parameters when function has varargs or is
4832         reentrant, fixed bug with symbol name compare for generating
4833         functions in absolute address,
4834         * (pic16_storeForReturn): refurnished,
4835         * (genCmp): began writing a new version of the function, not ready
4836         yet, therefore it is disabled,
4837         * (genAssign): do not read code memory when assigning a function to
4838         a pointer function,
4839         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
4840         array of characters, not pointer,
4841         * (pic16initialComments): in debug mode emit an .ident directive for
4842         the assembler,
4843         * (_process_pragma): emit a new warning type (internal to pic16)
4844         when setting stack to default length, emit a similar warning when
4845         placing a function at absolute address and address is not word aligned
4846         * (_pic16_parseOptions): added 'return TRUE' statement,
4847         * (_pic16_linkEdit): if compiling a source, then add the source's
4848         file object, first in the list of objects to link,
4849
4850 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
4851
4852         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
4853         * src/pic/main.c : removed VC warning.
4854         * src/pic/gen.c : changed comment.
4855
4856 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
4857
4858         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
4859         reference to a deprecated symbol _GPTRREG was causing failure to
4860         link. Thanks G. M. Gallant for the info.
4861
4862 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
4863
4864         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
4865         comments for Bugs item #954788.
4866
4867 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
4868
4869         * src/pic16/device.c (pic16_dump_gsection,
4870         * pic16_groupRegistersInSection): handle symbols declared to be in
4871         access bank differently,
4872         * src/pic16/gen.c (struct _G): added field resDirect,
4873         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
4874         send values read from stack directly to result and don't allocate
4875         temporary values,
4876         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
4877         same registers,
4878         * (pic16_sameRegsOfs): NEW,
4879         * (freeAsmop): if _G.resDirect is set then do not mark registers as
4880         free because they were not allocated from temporary pool,
4881         * pic16_popRegFromString): workaround to fix a problem with
4882         allocating variables twice or never,
4883         * (genGenPointerGet): using PRODL instead of FSR0H,
4884         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
4885         instead of FSR0H,
4886         * (genAssign): take advantage of the _G.resDirect flag,
4887         * (genCast): around line 11844, use mov2f instead of directly
4888         MOVFF'ing between operands to account for literal values,
4889         * src/pic16/genutils.c: some new debug functions for gpsim have been
4890         added,
4891         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
4892         float with integer part only,
4893         * src/pic16/main.c (_process_pragma): handle pragma udata access to
4894         place variables in access bank
4895         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
4896         updated sources to reflect recent changes in gen.c
4897
4898 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
4899
4900         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
4901         sources that searched for headers in installation path, now the
4902         device/include/pic16 is used,
4903         * src/pic16/glue.c (pic16glue),
4904         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
4905         .line directives if not in debug mode, this suppresses assembler's
4906         warnings for ignored directives
4907
4908 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
4909
4910         * src/port.h: made reset_regparms prototype void parameter explicit.
4911         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
4912         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
4913         * doc/sdccman.lyx: documented warning disabling and how to use
4914           printf_large to make it print floats.
4915         * device/include/stdbool.h: NEW
4916         * device/lib/_atof.c,
4917         * device/lib/_divuint.c,
4918         * device/lib/_divulong.c,
4919         * device/lib/expf.c,
4920         * device/lib/printf_large.c,
4921         * device/lib/sincosf.c,
4922         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
4923         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
4924           a completely reentrant lib.
4925
4926 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
4927
4928         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
4929         * device/include/pic16/stdio.h: fixed bug with colon
4930
4931 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
4932
4933         * device/include/pic16/stdio.h,
4934         * device/include/pic16/stdlib.h,
4935         * device/include/pic16/math.h: NEW
4936         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
4937         declared as _naked to reduce overhead
4938         * device/lib/Makefile.in (target port-specific-objects-pic16):
4939         changed * to *.* so to ignore the CVS directory,
4940         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
4941         stacked variables back in stack,
4942         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
4943         corruption
4944
4945 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
4946
4947         * .version: bumped version number to 2.4.5
4948         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
4949         * support/Util/SDCCerr.c (messages structure): added entry for
4950         W_POSSBUG2
4951
4952         Large cumulative patch for pic16 port and libraries.
4953         * device/include/pic16/sdcc-lib.h,
4954         * device/include/pic16/stdarg.h,
4955         * device/include/asm/pic16/features.h,
4956         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
4957         * device/include/pic16/float.h: changes reentrant keyword with
4958         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
4959         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
4960         updated target build-libraries to include objects from gptr,
4961         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
4962         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
4963         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
4964         all function headings,
4965         * src/SDCCmain.c: added global parameter userIncDirsSet,
4966         * (parseCmdLine): when option -I is encountered add directory to
4967         userIncDirsSet too,
4968         * src/version.awk: added space between control and long,
4969         * src/pic16/NOTES: added some notes for the port,
4970         * src/pic16/gen.c: added prototype for mov2fp function,
4971         * (fReturnpic16[]): properly named return value registers,
4972         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
4973         * (aopForSym): added code to handle symbols with onStack flag set,
4974         symbols onStack are allocated PTRSIZE bytes,
4975         * (aopFreeAsmop): handles special case where asmops are stack objects,
4976         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
4977         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
4978         added argument lock to trace flaws in allocating temporary registers
4979         when developing port,
4980         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
4981         * (pic16_popRegFromString): reenabled allocating a direct register
4982         from string,
4983         * (assignResultValue): various beautifications,
4984         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
4985         referenced function argument,
4986         * (genIpush): reenabled to allow stacked arguments, handles only
4987         ic->parmPush iCodes,
4988         * (genCall, genPcall): major changes to allow for variable argument
4989         functions, fixed a bug with falsely restoring stack pointer after
4990         returning from call,
4991         * (genFunction): pending code for critical function,
4992         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
4993         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
4994         * (genNearPointerGet): fixed bug with indirect reading, was always
4995         reading from INDF0
4996         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
4997         pointers,
4998         * (genAddrOf): rewrote code to take address of a stacked function parameter
4999         * (genCast): fixed casting to generic pointer type,
5000         * src/pic16/gen.h: added AOP_STA,
5001         * (struct asmop): added field stk,
5002         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
5003         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
5004         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
5005         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
5006         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
5007         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
5008         generic pointers,
5009         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
5010         and library paths,
5011         * (pic16_port structure): generic pointer size is set to 3,
5012         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
5013         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
5014         compiler warning,
5015         * src/pic16/ralloc.c (allocReg): prevent allocating register when
5016         operand is an iTemp,
5017
5018 2004-09-24 Martin Helmling <mh AT octo-soft.de>
5019
5020         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
5021         * debugger/mcs51/simi.c: addapt new syntax of s51
5022
5023 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
5024
5025         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
5026         * src/pic16/pcode.c: commented out some calls to free() in order to
5027         fix bug #989576,
5028
5029 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5030
5031         * src/SDCCicode.h,
5032         * src/SDCCicode.c (isiCodeInFunctionCall),
5033         * src/avr/ralloc.c (selectSpil),
5034         * src/pic/ralloc.c (selectSpil),
5035         * src/pic16/ralloc.c (selectSpil),
5036         * src/ds390/ralloc.c (selectSpil),
5037         * src/hc08/ralloc.c (selectSpil),
5038         * src/xa51/ralloc.c (selectSpil),
5039         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
5040         stack in the middle of a function call sequence (fixes bug #1020268)
5041         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
5042         costs associated with the minimum switch case.
5043
5044 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5045
5046         * src/SDCC.lex: fixed bug #1030549
5047
5048 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5049
5050         * src/SDCCcse.h (struct cseDef),
5051         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
5052         over a function call if the CSE is derived from a symbol whose
5053         address has been taken (fixes bug #1029883)
5054         * support/regression/tests/bug-1029883: a new regression test for
5055         this bug
5056
5057 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5058
5059         * src/hc08/gen.c (emitinline): fixed bug #1029778
5060         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
5061         to a cast object is no longer a syntax error ("fixes" bug #1030006,
5062         and starts toward RFE #905167)
5063
5064 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
5065
5066         * src/pic16/gen.c (mov2f): New function to move an operand to
5067         another without considering if it is a literal or a register,
5068         * (pic16_sameRegs): don't check if they are both AOP_REG,
5069         * (AccRsh): removed andmask=0 lines,
5070         * (genLeftShift): duplicated to be improved in future versions,
5071         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
5072         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
5073         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
5074         * (pic16initMnemonics): added initialization for POC_INFSNZW,
5075         * (insertBankSwitch): fixed inserting banksel directives algorithm
5076         for instructions that follow a skip instruction, this fixes a report
5077         for broken subtraction code generation,
5078         * src/pic16/ralloc.c (deassignLRs): do not free register if current
5079         iCode is a left op, just in case result and right share the same
5080         registers
5081
5082 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5083
5084         * src/hc08/main.c,
5085         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
5086         preservation of HX
5087         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
5088         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
5089         on 2004-09-12; it was buggy
5090
5091 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
5092
5093         * src/SDCCsymt.h: removed RESULT_CHECK
5094         * src/SDCCast.c,
5095         * src/SDCCglue.c,
5096         * src/SDCCval.c,
5097         * src/pic/glue.c,
5098         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
5099
5100 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
5101
5102         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
5103         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
5104         configuration values no more rejected by compiler, they are assigned
5105         to configuration registers with a warning message instead,
5106         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
5107         the for-loop so last conf register is emitted too,
5108         * (_pic16_initPaths): link library libsdcc.lib by default,
5109         * (_hasNativeMulFor): modified test for multiplication according to
5110         Raphael Neider's remarks. Integer multiplication is also done with
5111         support functions,
5112         * device/include/pic16/pic18fregs.h: corrected type error in while
5113         testing and including 18f6720 header file
5114
5115 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
5116
5117         * src/pic16/device.h (pic16_options): removed field use_crt,
5118         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
5119         until an optimization to handle single bits is added,
5120         * (pic16_loadFSR0): moved before genUnpackBits,
5121         * (genAnd): some white lines removed,
5122         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
5123         leave_reset flags in pic16_options when using crt modules,
5124
5125 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
5126
5127         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
5128           for bugs 898889 & 979599. Also used some safer print instructions.
5129
5130 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
5131
5132         * src/pic16/device.h (pic16_options_t): added field use_crt,
5133         crt_name, no_crt,
5134         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
5135         catch a probable future bug,
5136         * src/pic16/gen.c: aopIdx function commented out,
5137         * (genAssign): commented out old code which used aopIdx,
5138         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
5139         code, added if conditionals to take into account the --use-crt
5140         command line options,
5141         * src/pic16/main.c (pic16_optionsTable): added new command line
5142         options, --use-crt= and --no-crt,
5143         * (_pic16_linkEdit): now the proper crt object is added in the
5144         linker command line except than when --no-crt is specified,
5145         * src/pic16/pcode.c,
5146         * src/pic16/pcode.h: added some structures and functions for a new
5147         optimization scheme to compansate for instruction overhead between
5148         same iCodes, this scheme is currently under development and is not
5149         working in any way,
5150         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
5151         to && operator,
5152         * device/lib/pic16/startup/crt0i.c,
5153         * device/lib/pic16/startup/crt0iz.c: added global char variable
5154         __uflags to force the generation of an idata section
5155
5156 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
5157
5158         * doc/Makefile,
5159         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
5160         * doc/sdccman.lyx: updated sdcc version to 2.4.4
5161
5162 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5163
5164         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
5165         Frieder) and clarified the default code optimization mode
5166
5167 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5168
5169         * src/SDCC.lex (doPragma, process_pragma),
5170         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
5171         "opt_code_size", and "opt_code_balanced"
5172         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
5173         regrouped options by category, added support for category headers
5174         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
5175         and "--opt-code-size"
5176         * doc/sdccman.lyx: documented these new options and pragmas
5177         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
5178         preference into account
5179
5180 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5181
5182         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
5183           geniCodePreDec): Fixed bug 904237 by generating a warning
5184         * src/SDCCerr.h,
5185         * src/SDCCerr.c: added warning W_SIZEOF_VOID
5186
5187 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
5188
5189         * src/pic/device.c : When no max ram set validate full memory range.
5190         * src/pic/pcode.c,
5191         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
5192
5193 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5194
5195         * device/lib/_gptrget.c,
5196         * device/lib/_gptrput.c: updated comment
5197         * device/lib/calloc.c,
5198         * device/lib/free.c,
5199         * device/lib/malloc.c,
5200         * device/lib/realloc.c: added LGPL, made them reentrant-safe
5201         * src/SDCCcse.c (cseBBlock),
5202         * src/SDCCicode.c (printOperand, geniCodeArray),
5203         * src/SDCCicode.h (struct operand): fixed bug 868103
5204         * support/regression/tests/bug-868103.c: added
5205         * src/SDCCast.c (searchLitOp),
5206         * src/SDCCcse.h (struct cseDef),
5207         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
5208         * src/SDCCicode.h (struct operand),
5209         * src/SDCCsymt.h (struct sym_link),
5210         * src/avr/gen.c (hasInc),
5211         * src/ds390/gen.c (hasInc),
5212         * src/hc08/gen.c (genPlusIncr, hasInc),
5213         * src/mcs51/gen.c (hasInc),
5214         * src/pic16/glue.c (pic16_printIvalChar),
5215         * src/pic16/ralloc.c (regWithIdx),
5216         * src/xa51/gen.c (hasInc) : removed warnings
5217         * src/SDCCast.c (createBlock): added comment ???
5218         * src/hc08/ralloc.c: updated comments
5219
5220 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5221
5222         * doc/sdccman.lyx: updated section on switch statements, added
5223         section about semaphore locking
5224         * doc/Makefile: added option -info for latex2html
5225         * device/lib/_gptrget.c,
5226         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
5227
5228 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5229
5230         * src/pic/device.h,
5231         * src/pic/device.c,
5232         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
5233          maxram is less than 0x100.
5234
5235 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
5236
5237         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
5238
5239 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5240
5241         * src/port.h,
5242         * src/mcs51/main.c,
5243         * src/ds390/main.c,
5244         * src/z80/main.c,
5245         * src/hc08/main.c,
5246         * src/pic/main.c,
5247         * src/pic16/main.c,
5248         * src/avr/main.c,
5249         * src/xa51/main.c
5250         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
5251         a jump table is the best form for a switch statement, including
5252         automatic insertion of missing cases to make the case range
5253         continuous. Developed in collaboration with Frieder Ferlemann.
5254
5255 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5256
5257         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
5258         accumulator result if it needs sign extension
5259
5260 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5261
5262         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
5263
5264 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5265
5266         * device/lib/gbz80/printf.c,
5267         * device/lib/z80/printf.c: removed define for NULL
5268
5269 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
5270
5271         * as/xa51/xa_link.c,
5272         * device/examples/ds390/ow390/ad26.c,
5273         * device/examples/ds390/ow390/cnt1d.c,
5274         * device/examples/ds390/ow390/counter.c,
5275         * device/examples/ds390/ow390/ds2480.h,
5276         * device/examples/ds390/ow390/ds2480ut.c,
5277         * device/examples/ds390/ow390/findtype.c,
5278         * device/examples/ds390/ow390/gethumd.c,
5279         * device/examples/ds390/ow390/owllu.c,
5280         * device/examples/ds390/ow390/ownetu.c,
5281         * device/examples/ds390/ow390/swt12.c,
5282         * device/examples/ds390/ow390/swtloop.c,
5283         * device/examples/ds390/ow390/temp.c,
5284         * device/examples/ds390/ow390/temp10.c,
5285         * device/examples/ds390/ow390/thermo21.c,
5286         * device/examples/ds390/ow390/tinilnk.c,
5287         * device/examples/ds390/ow390/tstfind.c,
5288         * device/examples/serialcomm/windows/serial.cpp,
5289         * device/examples/serialcomm/windows/test_serialcomm.cpp,
5290         * device/include/reg51.h: fixed line endings for cvs
5291
5292 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5293
5294         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
5295         packRegsForAccUse, packRegisters): new accumulator register
5296         packing algorithm
5297         * support/regression/ports/hc08/support.c (_putchar): suppress
5298         warning of unused variable
5299         * src/SDCCicode.c: added SWAP entry to codeTable
5300
5301 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
5302
5303         * device/lib/sprintf.c: forgot to add this file before previous commit
5304
5305 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
5306
5307         * src/pic16/gen.c (genPackBits): added operand right in function
5308         parameters, load result directly if p_type is POINTER (that is
5309         called by genNearPointerSet)
5310         * (genUnPackBits): added operand left in function parameters,
5311         * (genNearPointerGet, genNearPointerSet): prevent the loading of
5312         FSR0 if accessing bitfields,
5313
5314 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
5315
5316         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
5317           _print_format; updated printf, sprintf, vsprintf
5318         * device/include/asm/default/features.h: corrected comment/define
5319         * device/lib/Makefile.in: added sprintf.c
5320         * device/lib/libsdcc.lib: added sprintf module
5321         * device/lib/printf_large.c,
5322         * device/lib/vprintf.c,
5323         * device/lib/sprintf.c: totally refactored printf_large and vprintf
5324           into these 3 files
5325         * support/regression/Makefile: changed ALL_PORTS into a usefull default
5326         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
5327         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
5328           hc08 test
5329         * support/regression/tests/zeropad.c: define idata as data for hc08
5330
5331 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5332
5333         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
5334         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
5335         labels are referenced at least once (even if a reference is not found)
5336         * src/hc08/gen.c (emitcode): set isComment flag for comments
5337         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
5338         loads), rules 6a..6b (optimize jumps to return)
5339
5340 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5341
5342         * device/lib/acosf.c (acosf),
5343         * device/lib/asinf.c (asinf),
5344         * device/lib/atanf.c (atanf),
5345         * device/lib/ceilf.c (ceilf),
5346         * device/lib/cosf.c (cosf),
5347         * device/lib/coshf.c (coshf),
5348         * device/lib/cotf.c (cotf),
5349         * device/lib/fabsf.c (fabsf),
5350         * device/lib/floorf.c (floorf),
5351         * device/lib/log10f.c (log10f),
5352         * device/lib/logf.c (logf),
5353         * device/lib/sinf.c (sinf),
5354         * device/lib/sinhf.c (sinhf),
5355         * device/lib/sqrtf.c (sqrtf),
5356         * device/lib/tanf.c (tanf),
5357         * device/lib/tanhf.c (tanhf),
5358         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
5359         replaced all instances of "reentrant" in the library functions
5360         defined in math.h with this macro.
5361         * support/regression/tests/float_trans.c: reenabled test for hc08
5362
5363 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
5364
5365         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
5366         erroneously deleted
5367
5368 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5369
5370         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
5371         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
5372         multi-byte volatile operands are used
5373         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
5374         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
5375         initialization to area GSINIT0 so that it would always precede
5376         any static initializers in GSINIT
5377         * support/regression/tests/zeropad.c: fixed idata define for hc08
5378         * support/regression/tests/bug-927659.c,
5379         * support/regression/tests/float_trans.c: disabled tests for hc08
5380         pending missing library routines
5381         * .version: increased version number to 2.4.4 - hc08 port now passes
5382         regression tests
5383
5384
5385 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
5386
5387         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
5388         * Makefile.common.in,
5389         * as/Makefile,
5390         * as/hc08/Makefile.in,
5391         * as/mcs51/Makefile.in,
5392         * as/z80/Makefile.in,
5393         * debugger/mcs51/Makefile.in,
5394         * device/include/Makefile.in,
5395         * device/lib/Makefile.in,
5396         * doc/Makefile,
5397         * link/Makefile,
5398         * link/z80/Makefile.in,
5399         * packihx/Makefile.in,
5400         * sim/ucsim/main_in.mk,
5401         * sim/ucsim/avr.src/Makefile.in,
5402         * sim/ucsim/doc/Makefile.in,
5403         * sim/ucsim/gui.src/serio.src/Makefile.in,
5404         * sim/ucsim/hc08.src/Makefile.in,
5405         * sim/ucsim/s51.src/Makefile.in,
5406         * sim/ucsim/xa.src/Makefile.in,
5407         * sim/ucsim/z80.src/Makefile.in,
5408         * src/Makefile.in,
5409         * support/cpp2/Makefile.in,
5410         * support/librarian/Makefile,
5411         * support/makebin/Makefile: added DESTDIR to the install path proposed
5412         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
5413         * doc/sdccman.lyx: added DESTDIR documentation
5414
5415 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
5416
5417         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
5418         instruction for interrupt handlers, use fast returns when returning
5419         from high priority interrupts
5420
5421 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5422
5423         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
5424         code generation
5425         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
5426         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
5427         bugs, ported much of Bernhard's code from mcs51
5428         * src/mcs51/gen.c (genSend),
5429         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
5430         than one when calling a reentrant function
5431         * device/lib/_mullong.c: defined an alternate struct layout for big
5432         endian ports (hc08)
5433
5434 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5435
5436         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
5437         test
5438
5439 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5440
5441         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
5442         are sane and complete before asking the port its prefered parameter
5443         passing method (fixes bug #1017633)
5444         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
5445         and _ret3
5446
5447 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5448
5449         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
5450         problem in bitfields >= 8 bits.
5451
5452 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5453
5454         * src/SDCCsymt.c: undid changes that were not meant to be committed
5455
5456 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5457
5458         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
5459
5460 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
5461
5462         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
5463           copied and wrong bit got inverted
5464
5465 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5466
5467         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
5468         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
5469         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
5470         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
5471         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
5472         assignments to bitfields at known addresses
5473         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
5474         reads from bitfields at known addresses
5475         * src/hc08/ralloc.c (packRegisters),
5476         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
5477         genhc08Code): optimize pointer get values used as conditionals
5478         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
5479         and branch
5480
5481 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5482
5483         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
5484         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
5485         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
5486         as conditionals
5487
5488 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5489
5490         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
5491
5492 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5493
5494         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
5495         related problems
5496
5497 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
5498
5499         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
5500
5501 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5502
5503         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
5504         mcs51 port
5505
5506 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5507
5508         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
5509
5510 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5511
5512         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
5513         cases use more compact code.
5514
5515 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
5516
5517         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
5518
5519 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5520
5521         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
5522
5523 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5524
5525         * src/SDCCsymt.h,
5526         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
5527         parameter of changePointer() from symbol* to sym_link*
5528         * src/SDCCast.c (decorateType): call changePointer() for CAST op
5529         * src/SDCCsymt.c (compareType): void* type is castable to other
5530         pointers, but not necesarily an exact match.
5531         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
5532         is no longer blindly treated as an exact match.
5533         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
5534
5535 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
5536
5537         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
5538
5539 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
5540
5541         * src/pic/gen.c,
5542         * src/pic/pcode.c,
5543         * src/pic/ralloc.h,
5544         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
5545
5546 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
5547
5548         * src/pic/device.c,
5549         * src/pic/device.h,
5550         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
5551
5552 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5553
5554         * src/mcs51/gen.c (emitcode): fixed bug #992819
5555
5556 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
5557
5558         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
5559           there's no need to make it worse
5560
5561 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5562
5563         * src/mcs51/ralloc.c (deassignLR),
5564         * src/ds390/ralloc.c (deassignLR),
5565         * src/hc08/ralloc.c (deassignLR),
5566         * src/z80/ralloc.c (deassignLR),
5567         * src/pic/ralloc.c (deassignLR),
5568         * src/pic16/ralloc.c (deassignLR),
5569         * src/avr/ralloc.c (deassignLR),
5570         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
5571         rlivePoint): fixed another part of bug #971834
5572
5573 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5574
5575         * src/z80/main.c: enabled "critical" keyword
5576         * src/z80/mappings.i,
5577         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
5578         functions (fixes bug #979646)
5579         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
5580
5581 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5582
5583         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
5584           such as c:\mydir.
5585
5586 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
5587
5588         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
5589           doesn't disable too much optimizations
5590
5591 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5592
5593         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
5594
5595 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
5596
5597         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
5598
5599 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
5600
5601         * src/pic/gen.c tidied up tabs
5602         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
5603         * src/pic/main.c tidied up tabs
5604         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
5605         * src/pic/pcoderegs.c tidied up tabs
5606         * src/pic/ralloc.c tidied up tabs
5607
5608 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
5609
5610         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
5611         to S_FIXED for pic16 port and when symbol is not in level 0,
5612         allocate for S_REGISTER storage class and pic16 port, too,
5613         * src/pic16/device.h: prototype for checkSym,
5614         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
5615         * (pic16_assignConfigWordValue): test the value and the mask to
5616         validate that the value is suitable for the configuration word,
5617         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
5618         collect extern declared symbols, don't emit symbol twice, check
5619         first if symbol is in publics set first,
5620         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
5621         * added command line '--fstack' which enables an experimental
5622         feature for stack access, too buggy to be used yet...
5623         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
5624         * (pic16_allocDirReg): when register has storage class S_REGISTER
5625         allocate in pic16_dynAccessRegs,
5626         * device/include/pic16/pic18f????.h: modified configuration word
5627         naming convention, words started as CONFIG0H but should be CONFIG1H
5628
5629 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5630
5631         * device/include/mcs51reg.h: fixed bug 970993
5632
5633 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
5634
5635         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
5636         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
5637         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
5638         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
5639         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
5640         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
5641           error/warning numbers,
5642           added function setWarningDisabled()
5643         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
5644         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
5645           _memcmp.c _memmove.c calloc.c realloc.c free.c
5646         * support/regression/tests/malloc.c: added tests for new functionality
5647         * support/regression/tests/zeropad.c: added tests for truncated initializers
5648           and initialized char arrays starting with '\x0'
5649         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
5650
5651 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
5652
5653         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
5654
5655 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5656
5657         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
5658         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
5659         peephole 177.e. Thanks to anonymous
5660
5661 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
5662
5663         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
5664         function isn't used in the source but referenced as a
5665         variable initializer then declare it as extern in .asm file
5666
5667 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
5668
5669         * .version: increased version number to 2.4.3
5670
5671         Adding version extension according to ChangeLog CVS revision
5672         * src/Makefile.in (target all): added dependency 'version.h'
5673         * (rule version.h): added rule to create version.h from ChangeLog,
5674         * (rule dep): added dependency version.h,
5675         * src/version.awk: AWK script to create version.h
5676         * src/SDCCdwarf2.c (dwWriteModule),
5677         * src/SDCCglue.c (initialComments),
5678         * src/SDCCmain.c (printVersionInfo): modified to write after
5679         version string the version extension number,
5680         * src/SDCCutil.c: included "version.h"
5681         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
5682         number,
5683         * src/SDCCutil.h: added prototype for getBuildNumber
5684
5685         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
5686         includeDirsSet, too,
5687         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
5688         const char [] is found in function prototype...
5689
5690         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
5691         moving to WREG with source is already in WREG,
5692         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
5693         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
5694         * (aopForSym): stack'ed symbols are partially supported, added
5695         if-clause to support symbols in FARSPACE,
5696         * (sameRegs): added test for AOP_ACC to see if registers are same,
5697         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
5698         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
5699         * (pic16_popRegFromString): will not allocate a new register if it
5700         doesn't find one by name, bug may have introduced...
5701         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
5702         * (genIpush): revived to use pic16 port's stack,
5703         * (genAddrOf): added incomplete case for stack'ed operand,
5704         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
5705         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
5706         can handle multibyte operands,
5707         * src/pic16/glue.c (pic16_printIval*): some debug info added,
5708         * (pic16initialComments): added message for MPLAB compatibility
5709         mode enabled,
5710         * src/pic16/main.h: prototype for pic16_mplab_comp,
5711         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
5712         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
5713         * (_pic16_linkEdit): NEW, handles link stage, transferred here
5714         because of increased complexity of procedure,
5715         * (_process_pragma): stack pragma changed to format 'stack pos len',
5716         emit symbol '_stack_end' to conform with gplink,
5717         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
5718         to search for register,
5719         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
5720         PO_GPR_REGISTER,
5721         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
5722         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
5723         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
5724         case for PO_GPR_REGISTER,
5725         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
5726         dies, the new era is ahead !...
5727         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
5728         pic16_dynInternalRegs,
5729         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
5730         * (pic16_allocDirReg): minor optimizations and bug fixes,
5731         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
5732
5733         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
5734         load stack and frame pointer with address of 'stack_end' symbol
5735
5736 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
5737
5738         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
5739         without source code but only variable initializers
5740
5741 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
5742
5743         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
5744         external are not declared as extern to reduce overhead while linking
5745
5746 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
5747
5748         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
5749
5750 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
5751
5752         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
5753           Yee Keat for the patch
5754         * src/SDCCast.c (decorateType): fixed bug #979599
5755         * src/ds390/gen.h: removed local fReturnSizeDS390
5756         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
5757         * src/ds390/gen.c (genAnd, genOr, genXor),
5758         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
5759
5760 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
5761
5762         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
5763         add relFilesSet to $3, manipulate $2 to handle linking of object
5764         files without source files in command line,
5765         * device/include/pic16 (all headers): added ID location macros,
5766         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
5767         entries for ID location bytes,
5768         * (pic16_assignIdByteValue): NEW,
5769         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
5770         added field dumpcalltree to pic16_options_t,
5771         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
5772         is used instead of pic16_Gstack_base_addr, check if (ifx) before
5773         emitting rFalseIfx label after check_carry label,
5774         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
5775         pic16_emitDIRegs), NEW
5776         * (pic16glue): dump .calltree file when option --calltree found,
5777         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
5778         * (_pic16_genAssemblerPreamble): emit ID locations after
5779         configuration registers,
5780         * (pic16_linkCmd): modifications of the link command,
5781         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
5782         * (pic16_pCodeInitRegisters): don't init stack registers,
5783         * (pic16_findPrevInstruction): fixed bug,
5784         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
5785         bug with immediate registers,
5786         * (buildCallTree): traces stack push and pop,
5787         * (pct2): dump also stack usage for each function,
5788         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
5789         * (pic16_allocDirReg): various modifications,
5790         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
5791         fixed to 1,
5792
5793 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
5794
5795         * src/pic16/pcode.c: removed buggy double colon
5796
5797 2004-07-01 Borut Razem <borut.razem AT siol.net>
5798
5799         * support/scripts/sdcc.nsi: added include/pic16 to setup
5800
5801 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
5802
5803         * device/lib/Makefile.in: fixed bug in target objects-pic16,
5804         * device/lib/pic16/Makefile: prefixed with dash (-) command under
5805         target 'clean',
5806         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
5807         specific command line arguments. Also added sample lkr script
5808         for placing a variable at a specific memory bank.
5809         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
5810         at a specific memory bank,
5811         * (pic16_dump_isection): fixed bug which caused string literals to
5812         be omitted when dumping idata section,
5813         * (pic16_groupRegistersInSection): added code to handle registers
5814         in specific memory banks,
5815         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
5816         public, all references are renamed too,
5817         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
5818         AOP_DPTR2,
5819         * (pic16_storeForReturn): added case to handle when dest is WREG,
5820         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
5821         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
5822         pic16_rel_udata, check to see if that register is marked as being
5823         a member of a specific memory bank,
5824         * (pic16_printIvalCharPtr): added code to add string literals either
5825         to code or the idata sections,
5826         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
5827         also accept the 'udata' pragma,
5828         * src/pic16/main.h: new structure types sectName and sectSym
5829         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
5830         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
5831         * (pic16_findPrevInstruction): fixed, it returned nothing,
5832         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
5833         instruction combinations,
5834         * (pic16_FixRegisterBanking): heavily reorganised,
5835         * (pic16_AnalyzeBanking): if generating banksel directives is
5836         disabled, then don't call FixRegisterBanking at all,
5837         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
5838         completely removed,
5839         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
5840
5841 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
5842
5843         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
5844         Phuah Yee Keat <yk.phuah AT nestac.com>
5845
5846 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5847
5848         * src/pic16/glue.c (pic16createInterruptVect): function now emits
5849         correctly the IVT even if it is relocated to some other location
5850
5851 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
5852
5853         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
5854         * device/include/pic16/pic18f2220.h: NEW,
5855         * device/lib/pic16/libdev/pic18f2220.c: NEW,
5856         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
5857         * src/pic16/device.c (struct Pics16): added info for 18f2220,
5858         * src/pic16/device.h (struct pic16_options): added ivt_loc and
5859         nodefaultlibs, ivt_loc is the location of the interrupt vector
5860         table, and nodefaultlibs signs that default libraries should not be
5861         linked in link stage,
5862         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
5863         according to --ivt-loc argument,
5864         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
5865         when pragma stack is found,
5866
5867 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5868
5869         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
5870         256 (range check), 257 (do while), 258.a-f (bit banging
5871         f.e. on 3-wire SPI bus)
5872
5873 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5874
5875         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
5876         variables used exclusively within a loop
5877
5878 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
5879
5880         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
5881
5882 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5883
5884         * src/SDCClrange.c (computeClash): fixed bug #971834
5885
5886 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5887
5888         * src/mcs51/gen.c (genCmp): fixed bug #975903
5889         * src/hc08/gen.c (operandsEqu),
5890         * src/ds390/gen.c (operandsEqu),
5891         * src/z80/gen.c (operandsEqu),
5892         * src/pic/gen.c (operandsEqu),
5893         * src/pic16/gen.c (operandsEqu),
5894         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
5895         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
5896
5897 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5898
5899         * src/SDCCcse.c (cseBBlock): fixed bug #966963
5900
5901 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
5902
5903         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
5904         default case in switch statement,
5905         * glue.c (pic16_initPointer): expr is initialised via decoarteType
5906         to eliminate problem with initialisation of pointers, but problem
5907         still exists,
5908         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
5909         * (emitStaticSegment): removed various lines emitting debug info,
5910         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
5911         added processor registers for utilizing EEPROM,
5912         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
5913         configurable and set 8
5914
5915 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
5916
5917         * .version: increased version number to 2.4.2,
5918
5919         Cumulative patch for pic16 port
5920         * src/pic16/device.c: changed scheme to dump initial values for
5921         variables in idata segment, all print_idata* functions were removed,
5922         now the pic16_printIval* will be called,
5923         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
5924         * _pic16_printPointerType, pic16_printPointerType,
5925         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
5926         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
5927         NEW, similar to the respective functions in SDCCglue.c,
5928         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
5929         way, emitting hex bytes,
5930         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
5931
5932 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5933
5934         * src/avr/ralloc.c (serialRegAssign),
5935         * src/xa51/ralloc.c (serialRegAssign),
5936         * src/pic/ralloc.c (serialRegAssign),
5937         * src/pic16/ralloc.c (serialRegAssign),
5938         * src/hc08/ralloc.c (serialRegAssign),
5939         * src/z80/ralloc.c (serialRegAssign),
5940         * src/ds390/ralloc.c (serialRegAssign),
5941         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
5942
5943 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5944
5945         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
5946         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
5947
5948 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
5949
5950         Cumulative patch for pic16 port:
5951         * src/pic16/device.h (typedef PIC16_device) modified fields for
5952         defining microcontrollers,
5953         * src/pic16/device.c: added new info for all devices in Pics16 array,
5954         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
5955         to be optimised out by the pCode optimiser,
5956         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
5957         specially, bug reported by G.M. Gallant,
5958         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
5959         as force'd so that cannot be optimised out by pCode optimiser,
5960         * src/pic16/pcode.c,
5961         * src/pic16/pcodepeeph.c,
5962         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
5963         they are disabled by default, but can be enabled explicit with
5964         command argument --denable-peeps, for testing,
5965         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
5966         --pomit-ivt in COMPILE_FLAGS
5967
5968 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5969
5970         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
5971           compilation on MSVC
5972
5973 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
5974
5975         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
5976
5977 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5978
5979         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
5980         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
5981
5982 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
5983
5984         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
5985         would only assign 0x300001 register.
5986
5987 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
5988
5989         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
5990         in COMPILE_FLAGS. Thanks to G. Gallant for report.
5991
5992 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5993
5994         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
5995         for ds80c400
5996         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
5997         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
5998         added peephole 254 (left shift), 255 (jump table)
5999
6000 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
6001
6002         * device/lib/Makefile.in: removed comment line with model-pic16,
6003         * (target port-specific-objects-pic16): the libraries and objects
6004         are copied to the build directory form the device/lib/pic16/bin
6005         directory
6006
6007         Cumulative patch concerning pic16 port:
6008         * library directory has been re-organized,
6009         * added support for PIC18F1220,
6010         * added headers and library sources for chips 18f1220,18f6520,
6011         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
6012
6013         * configuration registers setting has changed, now each supported
6014         device has a complete description of the registers it uses,
6015         * all initialisations are moved to idata sections, these section
6016         can be absolute or relocatable,
6017         * fixed initialisation of codespace variables,
6018         * fixed warning about PCLATU and gpsim,
6019         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
6020         * (genAssign): use table reads when assigning from variables in codespace,
6021         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
6022         char/int variables placed in codespace,
6023         * (pic16_emitConfigRegs): NEW, emits a list with configuration
6024         registers set in .asm file, no need for --pomit-config-words anymore,
6025         * (pic16glue): some 8051 legacy segments are commented out
6026         (to be removed completely),
6027         * added support for alternative assembler and linker with --asm=
6028         and --link= command line arguments,
6029         * peepholes are disabled automatically in the port, no need to
6030         specify on command line,
6031         * port supports natively char/int/long multiplication, but converts
6032         all divisions to support functions,
6033         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
6034         to the file set in variable $2,
6035         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
6036         strings in ASCII format and not in hex,
6037         * ralloc.c (serialRegAssign): added a triplet of conditional calls
6038         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
6039         allocate proper register if iCodes aren't temporary,
6040
6041 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
6042
6043         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
6044
6045 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
6046
6047         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
6048         is commented out
6049
6050 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6051
6052         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
6053         computed address is reused
6054         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
6055         multi-byte bitfields
6056
6057 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6058
6059         * src/z80/gen.c: (genArrayInit): must check for pointers too
6060
6061 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
6062
6063         * support/regression/tests/zeropad.c: never meant to commit the
6064           nestedstruct test: removed, added check for GCC version
6065
6066 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
6067
6068         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
6069         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
6070         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
6071           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
6072           bugs 928906 and 954082 half-empty initializers
6073         * src/SDCCsymt.h,
6074         * src/SDCCsymt.c (getAllocSize): added for above fix
6075         * src/z80/gen.c (genArrayInit): fixed bug 741044
6076         * support/regression/tests/zeropad.c: added tests
6077
6078 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
6079
6080         * src/pic16/device.c (pic16_dump_section): corrected bug which
6081         caused some symbols of the libraries to be misplaced
6082
6083 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6084
6085         * src/pic16/glue.c,
6086         * src/pic16/ralloc.h,
6087         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
6088         to fix conflict with pic port
6089
6090 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
6091
6092         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
6093         externs configuration variables,
6094         * src/pic16/ralloc.h,
6095         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
6096         prototype in header, commented out some debug messages
6097
6098 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
6099
6100         * src/pic16/glue.c,
6101         * src/pic16/main.c,
6102         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
6103         for gpasm COFF object generation. Thanks to D. Hawkins for
6104         his patch info
6105
6106 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6107
6108         * src/ds390/main.c,
6109         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
6110         Brock for spotting this)
6111         * src/ds390/gen.c (genEndFunction),
6112         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
6113         interrupt handler and critical. Disable push/pop optimizations when
6114         peephole optimizations disabled.
6115
6116 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6117
6118         Updated pic16 library sources and headers.
6119         * device/lib/pic16/pic18f*/ ,
6120         * device/include/pic16/*.h: modified to handle structured SFR
6121         definitions
6122
6123 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
6124
6125         * src/port.h (PORT structure): added hook initPaths, now each
6126         port can declare its own default search paths,
6127         which can been seen with the --print-search-dirs option,
6128         see pic16 port for example,
6129         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
6130         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
6131         * (doPrintSearchDirs): NEW, replaces in a central manner the
6132         printing of search dirs which was split in set*Paths functions,
6133         * (main): added call to port->initPaths and doPrintSearchDirs,
6134         * src/avr/main.c,
6135         * src/ds390/main.c,
6136         * src/hc08/main.c,
6137         * src/izt/i186.c,
6138         * src/izt/tlcs900h.c,
6139         * src/mcs51/main.c,
6140         * src/pic/main.c,
6141         * src/pic16/main.c: modified port structures to reflect addition of
6142         initPaths hook,
6143
6144         * src/pic16/device.c (regCompare): registers are finally sorted by name,
6145         * (pic16_dump_section): for registers in same address reserve memory once,
6146         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
6147         to no_banksel,
6148         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
6149         result is greater in size than right or left,
6150         * (pic16_genUMult8X8_8): there are some cases where the result can
6151         be 16 bits size, so handle these,
6152         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
6153         * (pic16_outBitC): modified to emit pcodes,
6154         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
6155         or not,
6156         * (genDivOneByte): implemented algorithm to divide 8-bits,
6157         * (genCmp): uncommented goto, but issues still exist,
6158         * (genAnd): fixed a bug with variables >8bits,
6159         * (genPackBits): optimization added that uses BCF/BSF to change a
6160         single bit,
6161         * (genAssign): fixed bug when assigning floating point literals,
6162         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
6163         __sdcc_gsinit_startup label,
6164         * src/pic16/main.c (_pic16_init): removed search directory
6165         initialisations,
6166         * (_pic16_initPaths): NEW, used to initialise search directories,
6167         * (_hasNativeMulFor): support functions for all except char/int
6168         multiplication, and char division,
6169         * (PIC16_port struct): modified entry for native mul support,
6170         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
6171         no_banksel option,
6172         * (buildCallTree): call to register_usage is ifdef'ed out,
6173
6174 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6175
6176         * device/include/string.h: applied Stas Sergeev's patch to make this
6177         header file compatible with the preprocessor -Wundef option
6178         * src/SDCCmain.c (main): abort compilation if preprocessor reports
6179         failure (fixes bug #941458)
6180
6181 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6182
6183         * src/SDCCopt.c (killDeadCode): fixed bug #907733
6184         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
6185         that the variable, not the function, should be static
6186         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
6187         to be consistent with non-literal case
6188
6189 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6190
6191         * src/SDCCast.c (isConformingBody): fixed bug #949967
6192         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
6193         convilong): fixed bug #952086
6194
6195 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6196
6197         * src/SDCCmem.c (allocVariables): fixed bug #955321
6198
6199 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6200
6201         * src/hc08/main.c (_hc08_genAssemblerEnd),
6202         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
6203         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
6204         completely eliminated the use of a temporary file
6205         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
6206         when more than one file linked
6207         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
6208
6209 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6210
6211         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
6212         which fixes bug #543481
6213         * support/regression/tests/bug-751703.c: fixed comments left from a
6214         cut and paste error
6215         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
6216         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
6217         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
6218         scopes
6219         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
6220         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
6221         are now changed to underscores in moduleName
6222
6223 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6224
6225         * as/mcs51/lkmem.c: better fix for bug #954173
6226
6227 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
6228         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6229
6230         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
6231         * device/include/c8051f000.h,
6232         * device/include/c8051f120.h,
6233         * device/include/c8051f300.h,
6234         * device/include/c8051f310.h,
6235         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
6236         PWM16) and detab'ed
6237
6238 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6239
6240         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
6241         and mailing lists, doc'ed --no-peep-comments, removed reference
6242         to knoppix (newest version has no LyX/LaTeX), other minor changes
6243         * src/SDCCglue.c (glue): save 2 bytes stack space with
6244         option --main-return. The ljmp could probably be avoided too
6245
6246 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6247
6248         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
6249
6250 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6251
6252         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
6253         * src/SDCCopt.c (isLocalWithoutDef),
6254         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
6255         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
6256         (credit to Maarten Brock for patch #949363, on which this is based)
6257         * support/regression/tests/bug-751703.c: some test cases of extern used
6258         within inner scopes.
6259
6260 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6261
6262         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
6263         SPEC_STRUCT
6264         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
6265         struct definitions
6266         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
6267         dwWriteLabel): fix to create valid debugger symbols even when
6268         the module name has non-alphanumeric symbols in it
6269         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
6270         when a variable's allocation has been optimized away
6271
6272
6273 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6274
6275         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
6276         * src/hc08/main.c,
6277         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
6278         * src/mcs51/main.c,
6279         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
6280         * src/ds390/main.c,
6281         * src/z80/gen.c (z80_emitDebuggerSymbol),
6282         * src/z80/main.c,
6283         * src/pic/gen.c (pic14_emitDebuggerSymbol),
6284         * src/pic/main.c,
6285         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
6286         * src/pic16/main.c,
6287         * src/avr/gen.c (avr_emitDebuggerSymbol),
6288         * src/avr/main.c,
6289         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
6290         * src/xa51/main.c,
6291         * src/SDCCdebug.c (emitDebuggerSymbol),
6292         * src/SDCCdebug.h,
6293         * src/port.h: added a debugger struct to the port struct. Added a
6294         callback for defining debugger symbols
6295
6296         * src/SDCCast.c (createLabel),
6297         * src/SDCC.y (labeled_statement): mark all compiler generated labels
6298         with isitmp = 1
6299         * src/SDCCicode.h,
6300         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
6301         iCode back to the ast for the function
6302
6303         * src/hc08/ralloc.c (hc08_assignRegisters),
6304         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
6305         unneeded fields from the regs struct.
6306         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
6307         pushReg() & pullReg() functions instead of emitcode()
6308
6309         * src/hc08/gen.c (genLabel, genhc08Code),
6310         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
6311
6312         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
6313         debugger hooks
6314
6315         * src/hc08/gen.c (genEndFunction, genhc08Code),
6316         * src/hc08/gen.h,
6317         * src/mcs51/gen.c (genEndFunction, gen51Code),
6318         * src/mcs51/gen.h,
6319         * src/ds390/gen.c (genEndFunction, gen390Code),
6320         * src/ds390/gen.h,
6321         * src/z80/gen.c (genEndFunction, genZ80Code),
6322         * src/z80/gen.h,
6323         * src/z80/z80.h,
6324         * src/pic/gen.c (genEndFunction, genpic14Code),
6325         * src/pic/gen.h,
6326         * src/pic16/gen.c (genEndFunction, genpic16Code),
6327         * src/pic16/gen.h,
6328         * src/avr/gen.c (genEndFunction, genAVRCode),
6329         * src/avr/gen.h,
6330         * src/xa51/gen.c (genEndFunction, genXA51Code),
6331         * src/xa51/gen.h,
6332         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
6333         specific code to cdbFile.c and out of the backend code generators
6334
6335         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
6336         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
6337         starting address is now 0
6338
6339         * as/hc08/asm.h,
6340         * as/hc08/m08pst.c,
6341         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
6342         assembler directive for DWARF support
6343         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
6344
6345         * src/src.dsp,
6346         * src/Makefile.in,
6347         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
6348
6349 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6350
6351         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
6352         and inappropriate peephole optimization in jump tables
6353
6354 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6355
6356         * as/hc08/m08pst.c,
6357         * src/SDCCglue.c: sdccopt works for the hc08 port now
6358
6359 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
6360
6361         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
6362
6363 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6364
6365         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
6366
6367 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6368
6369         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
6370         rules
6371         * src/SDCCmain.c,
6372         * src/SDCCglobl.h,
6373         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
6374         comments from the peephole optimizer replacement rules
6375         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
6376         symbols
6377         * src/SDCCcse.c (updateSpillLocation),
6378         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
6379         equivalents
6380         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
6381         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
6382         objects far pointers
6383
6384 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6385
6386         * src/SDCCsymt.h: a missing part of my last change
6387         * src/pic/ralloc.c (regTypeNum),
6388         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
6389
6390 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6391
6392         * src/SDCCicode.h,
6393         * src/SDCCicode.c (aggrToPtrDclType),
6394         * src/SDCCptropt.h,
6395         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
6396         ptrPseudoSymConvert),
6397         * src/pic/ralloc.c (regTypeNum),
6398         * src/pic16/ralloc.c (regTypeNum),
6399         * src/hc08/ralloc.c (regTypeNum),
6400         * src/ds390/ralloc.c (regTypeNum),
6401         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
6402         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
6403
6404 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6405
6406         * link/z80/lkmain.c (afile),
6407         * as/hc08/lkmain.c (afile),
6408         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
6409         prevent a pointer problem when a filename has no directory and
6410         no extension specified.
6411
6412 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6413
6414         * link/z80/lkmain.c (afile): allow periods in directory names
6415         * link/z80/lkmain.c (afile),
6416         * as/mcs51/lkmain.c (afile),
6417         * as/hc08/lkmain.c (afile): allow linker script file to have an
6418         extension other than ".lnk"
6419         * link/z80/lklex.c (getfid),
6420         * link/z80/lkmain.c (parse),
6421         * as/mcs51/lklex.c (getfid),
6422         * as/mcs51/lkmain.c (parse),
6423         * as/hc08/lklex.c (getfid),
6424         * as/hc08/lkmain.c (parse): Support comments in the linker script
6425         file on lines by themselves and after filenames
6426
6427 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6428
6429         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
6430
6431 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6432
6433         * src/z80/peeph-z80.def: removed some peephole rules that don't
6434         work with multibyte arithmetic (fixed bug #937126)
6435         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
6436         to registers and not global variables
6437         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
6438         geniCodePreInc, geniCodePostDec, geniCodePreDec,
6439         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
6440         checking for assignments not internally generated (fixed bug #931895)
6441         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
6442         structure member (fixed bug #930072)
6443
6444 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6445
6446         * src/SDCCmain.c (linkEdit),
6447         * src/hc08/main.c (_hc08_parseOptions),
6448         * as/hc08/Makefile.in,
6449         * as/hc08/aslink.h,
6450         * as/hc08/asm.h,
6451         * as/hc08/m08pst.c,
6452         * as/hc08/lkrloc.c (relr, rele),
6453         * as/hc08/lkarea.c (lnkarea)
6454         * as/hc08/lkmain.c (afile, parse),
6455         * as/hc08/lkelf.c: support for ELF output
6456         * as/hc08/lks19.c (s19),
6457         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
6458
6459 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6460
6461         * as/mcs51/lkihx.c: Fixed bug #899105.
6462
6463 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6464
6465         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
6466         .dsp files from Unix to DOS.
6467
6468 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6469
6470         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
6471         function pointers; we have been compliant for several months now.
6472         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
6473         change that was accidently commented out
6474         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
6475         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
6476         bug #922319
6477
6478 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6479
6480         * src/hc08/gen.c: output of all of the internal debugging information
6481         is now controlled by the D() macro; it is disabled by default
6482
6483 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6484
6485         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
6486         harder to keep the same registers during a CAST iCode
6487         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
6488         long via int can be done in a single cast, if the signedness is
6489         correct.
6490         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
6491         putchar() in tinibios.c in ds390's library
6492
6493 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
6494
6495         * src/SDCCast.c (decorateType): fixed bug #898889,
6496         cast result of a literal complement too
6497         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
6498         fixed check for bitfields
6499
6500 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
6501
6502         * src/SDCCicode.c (geniCodeLogic): made it static,
6503         (geniCodeLogicAndOr): added in order to fix bug #905492,
6504         (ast2iCode): fixed bug #905492
6505         * support/regression/tests/bug-905492.c: added
6506         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
6507         (processParms): fixed bug #927659: don't copy parms, this will clear
6508         decorated flag
6509         * support/regression/tests/bug-927659.c: added
6510
6511 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
6512
6513         * src/SDCCast.c (addCast): don't cast float to char
6514         * device/lib/libsdcc.lib: added _memmove
6515
6516 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
6517
6518         * device/lib/large/Makefile: fixed parallel execution by
6519         replacing `make` by `$(MAKE)`
6520
6521 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6522
6523         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
6524         offsets (fixes bug #923936)
6525
6526 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
6527
6528         * device/lib/small/Makefile: fixed parallel execution by
6529         replacing `make` by `$(MAKE)`
6530
6531 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6532
6533         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
6534
6535 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
6536
6537         * src/pic/gen.c (genCpl): multi-byte complements were not working.
6538         * src/regression/Makefile: Regression test was not running.
6539
6540 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
6541
6542         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
6543         complement if possible
6544         * src/SDCCval.c (valComplement),
6545         * src/SDCCicode.c (operandOperation): fixed complement of literal
6546         * support/regression/tests/onebyte.c (testComplement): added
6547
6548 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
6549
6550         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
6551         return an optimized tree; actually replace actParm with the new tree
6552         * src/SDCCast.h: added some parantheses to remove side effects
6553         * support/regression/tests/bug-920866.c
6554
6555 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
6556         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
6557         Bit operands were not being handled properly in the pic14 port.
6558         (now src/regression/add.c passes again).
6559
6560 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6561
6562         * src/SDCC.y (labeled_statement): case and default no longer require
6563         a following statement (RFE #893037)
6564
6565 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6566
6567         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
6568         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
6569         disabled (fixes bug #916294)
6570         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
6571         "mov a,acc"; patch provided by Lenny Story
6572         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
6573
6574 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6575
6576         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
6577         functions
6578         * src/ds390/gen.c (genFunction, genEndFunction),
6579         * src/ds390/ralloc.c (ds390_assignRegisters),
6580         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
6581         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
6582         pushed if there are parameters passed on the stack. Also, a cleaner
6583         way to decide if r0/r1 should be pushed/popped. (Together they fix
6584         bug #918693)
6585
6586 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6587
6588         * doc/sdccman.lyx,
6589         * device/lib/mcs51/crtpagesfr.asm,
6590         * device/lib/mcs51/crtxinit.asm,
6591         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
6592         to avoid confusion with Si Lab's SFRPAGE register.
6593
6594 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6595
6596         * src/SDCCglue.c (emitMaps): allow public sfr variables
6597         * src/SDCCglue.c (initialComments): include compiler build date
6598         with compiler version and put the timestamp of the generated
6599         assembly file on a serperate line to be less confusing.
6600         * src/port.h: added genInitStartup hook
6601         * src/avr/main.c,
6602         * src/ds390/main.c,
6603         * src/hc08/main.c,
6604         * src/pic/main.c,
6605         * src/pic16/main.c,
6606         * src/xa51/main.c,
6607         * src/z80/main.c: genInitStartup initialize as NULL (default to
6608         historical behaviour)
6609         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
6610         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
6611         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
6612         library instead of hard coding it into the compiler.
6613         * support/regression/ports/mcs51-stack-auto/spec.mk,
6614         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
6615         * device/lib/mcs51/Makefile,
6616         * device/lib/small/Makefile,
6617         * device/lib/large/Makefile,
6618         * device/lib/mcs51/crtpagesfr.asm,
6619         * device/lib/mcs51/crtstart.asm,
6620         * device/lib/mcs51/crtxclear.asm,
6621         * device/lib/mcs51/crtxinit.asm,
6622         * device/lib/mcs51/crtclear.asm,
6623         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
6624         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
6625         and into user configurable files.
6626         * device/lib/clean.mk: clean mcs51 directory too
6627         * support/regression/tests/longlit.c: added static to T1 declaration
6628         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
6629         accesses in the initialization code
6630
6631 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6632
6633         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
6634         OSCTRIMVAL as noted in bug #916008
6635
6636 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6637
6638         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
6639         in loops with multiple exits (reported as incorrect registers
6640         used by Martin Helmling in Sdcc-user list)
6641
6642 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6643
6644         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
6645         made ds390 register extensions look less like error messages
6646
6647 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6648
6649         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
6650         reported by Adam Wozniak in Sdcc-user list
6651
6652 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
6653
6654         * src/SDCCast.c (decorateType): fixed with bug and promotion in
6655         arithmetic optimizations, added debug output
6656
6657 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
6658
6659         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
6660         * sdcc.spec: updated and split sdcc into 3 rpms
6661         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
6662         needed for literals of LEFT_OP and '+'
6663         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
6664         introduced RESULT_TYPE_NOPROM
6665         (geniCodeMultiply): fixed logic for decision if mul is optimized to
6666         left shift
6667         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
6668         limited promotion to int only for '*'
6669         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
6670
6671 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
6672
6673         * src/pic16/gen.c (genSkip),
6674         (genc16bit2lit), (gencjneshort): commented out
6675         (is_LitOp): new helper function, checks operand type
6676         (genCmpEq): rewritten
6677
6678 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
6679
6680         * support/regression/tests/bug-908454.c: added
6681
6682 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
6683
6684         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
6685         * src/SDCCicode.c (usualBinaryConversions): op needs int type
6686         (geniCodeCast): cosmetic, don't preserve bit storage class
6687         (geniCodeLeftShift): added promotion
6688         (geniCodeLogic): fixed regression
6689         * src/SDCCsymt.c (computeTypeOr): accept bits too
6690         (compareType): 2nd part of fix for bug #908454, needed for bitfields
6691
6692 2004-03-07  Borut Razem <borut.razem AT siol.net>
6693
6694         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
6695
6696 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
6697
6698         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
6699         version of pic16_genPackRegisters which does not check if ic is a
6700         CAST operator,
6701         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
6702         function cause string1.c regression test fails
6703
6704 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
6705
6706         * sim/ucsim/configure.in,
6707         * sim/ucsim/configure,
6708         * sim/ucsim/doc/Makefile.in: use docdir
6709         * src/SDCC.y: fixed sbit atrributes
6710         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
6711         * src/SDCCast.c (decorateType): |^& need special promotion handling
6712         * src/SDCCast.h,
6713         * src/SDCCsymt.h: moved definition of RESULT_TYPE
6714         * src/SDCCsymt.h (computeType),
6715         * src/SDCCicode.c: computeType() needs op
6716         * src/SDCCsymt.c (checkTypeSanity),
6717         * doc/sddman.lyx: "plain" bitfields are unsigned
6718         * src/SDCCsymt.c (computeTypeOr): added
6719         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
6720         |^& ops
6721         * src/SDCCval.c (val*): computeType() needs op
6722         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
6723         * support/regression/tests/onebyte.c: added tests for |^&
6724
6725 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
6726
6727         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
6728         for writing icode into asm output.
6729
6730 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
6731
6732         * src/pic16/device.c: added some debug lines enabled
6733         with macro DEBUG_CHECK,
6734         * src/pic16/genarith.c: more debug in genPlus,
6735         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
6736         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
6737         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
6738         * (aopForSym): onStack symbols are re-placed in data memspace,
6739         and onStack flag is cleared,
6740         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
6741         copy temporary pcodeop,
6742         * (genPcall): added warning for not updating PCLATU,
6743         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
6744         always true for pic16 port,
6745         * (genMultOneWord): NEW, supports integer multiplication,
6746         * (genMult): modified to call genMultOneWord,
6747         * (ifxForOp): added warning when return NULL,
6748         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
6749         flag is set before call to operandFromSymbol for implicit
6750         added structures,
6751         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
6752         options.intlong_rent are set by default,
6753         * (_hasNativeMulFor): modified to allow port generation of integer
6754         multiplication,
6755         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
6756         set regtype to REG_SFR for all registers, restricting seting the
6757         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
6758
6759 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6760
6761         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
6762         more than 500 times in the regression tests
6763
6764 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6765
6766         * support/Util/SDCCerr.h,
6767         * support/Util/SDCCerr.c,
6768         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
6769         enumerator_list),
6770         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
6771         for symbol conflicts.
6772         * support/valdiags/tests/enum.c,
6773         * support/valdiags/tests/tentdecl.c,
6774         * support/valdiags/tests/struct.c: expect possible error messages
6775         referring to original symbol definitions.
6776         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
6777         * src/SDCCsymt.h,
6778         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
6779
6780 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
6781
6782         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
6783
6784 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
6785
6786         * src/pic16/ralloc.c (newReg): fixed bug #908929
6787
6788 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6789
6790         * src/ds390/gen.c: added missing #include "main.h"
6791
6792 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
6793
6794         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
6795         checking if symbol is already in set,
6796         * src/pic16/device.h: prototype for checkAddSym,
6797         * src/pic16/gen.c: (_G): added entry interruptvector,
6798         * (assignResultValue): removed some commented out lines,
6799         * (genFunction): check for ISR via sym->type, absolute section for
6800         interrupt code is created via a new pBlock, the goto instruction is
6801         placed now correctly at the interrupt vector position, changed all
6802         references from ivec to _G.interruptvector,
6803         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
6804         is the interrupt is a high priority one, same for return from ISR,
6805         * src/pic16/glue.c: changed all calls of addSetHead for publics and
6806         externs to calls of checkAddSym,
6807         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
6808         pic16_pcode_verbose flag is set,
6809         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
6810         * src/pic16/pcoderegs.c: message about how many registers are saved
6811         will only be emitted if pic16_pcode_verbose flag is set,
6812
6813 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6814
6815         * src/ds390/ralloc.h,
6816         * src/ds390/ralloc.c (ds390_regWithIdx),
6817         * src/ds390/gen.c (emitcode),
6818         * src/ds390/main.h,
6819         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
6820         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6821         ds390operandCompare, getRegsRead, getRegsWritten,
6822         initializeAsmLineNode): customized instruction size calculation for
6823         ds390, started basis for some register optimizations
6824         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
6825         corresponding assembly output
6826         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
6827         missing push/pop of r0/r1. Optimized push/pops
6828
6829 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6830
6831         * src/mcs51/main.c (instructionSize): fixed ACALL size
6832         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
6833
6834 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
6835
6836         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
6837         the sorting of rlist with NULL elements
6838         * (print_idataType, print_idata): NEW to create idata sections
6839         * src/pic16/device.h: idataSymSet new variable
6840         * src/pic16/gen.c (genFunction): fixed some bugs in string
6841         comparing, improved the absolute section creation for ISRs,
6842         added FSR0L/FSR0H in registers that are saved in an ISR,
6843         * (genInline): fixed the processing of inline snippets,
6844         now they undergo no process by the peephole optimizer
6845         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
6846         are placed in idataSymSet,
6847         * (pic16emitStaticSeg): extern symbols are added in externs,
6848         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
6849         switching when aboslute variables are placed in access bank memory
6850         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
6851         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
6852         commented out with #if,
6853         * (pic16_packRegisters): reintroduce the check for CAST because some
6854         symbols are not correctly handled,
6855         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
6856         pCodeInstruction instead of pCode,
6857         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
6858         pCodeAsmDir definition,
6859         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
6860         directive, then the argument directive is emitted without the leading
6861         tab, hack for inline labels which must be in the first column,
6862         * (compareLabel,pic16_findNextInstruction),
6863         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
6864         * (insertBankSwitch): modified for the new pCodeAsmDir,
6865
6866 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6867         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
6868
6869         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
6870         instance,
6871         * (pushSide): commented out with #if,
6872         * (assignResultValue): fixed some typos in saving
6873         registers,
6874         * (genPcall): FIXED and sync'ed with genCall,
6875         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
6876         * (genNearPointerGet): fixed to handle some more cases,
6877         implementation scheme via table reads,
6878         * (genConstPointerGet): modified to access code memory correct,
6879         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
6880         and improved to handle some cases
6881         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
6882         instead of "RETLW" for init data
6883         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
6884         not IN_DIRSPACE, work around to reduce bank switching when aboslute
6885         variables are placed in access bank memory (<0x80 and >=0xf80),
6886         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
6887         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
6888         TBLWT_POSTDEC,TBLWT_PREINC
6889         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
6890         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
6891         directives
6892         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
6893         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
6894         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
6895         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
6896
6897 2004-02-29  Borut Razem <borut.razem AT siol.net>
6898
6899         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
6900         support/Util/findme.h, support/Util/system.h: enhance binary relative
6901         search for lib and include by using findProgramPath()
6902
6903 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6904
6905         * src/SDCCpeeph.h,
6906         * src/SDCCpeeph.c (pcDistance),
6907         * src/port.h,
6908         * src/mcs51/ralloc.h,
6909         * src/mcs51/ralloc.c (mcs51_regWithIdx),
6910         * src/mcs51/main.h,
6911         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
6912         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
6913         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
6914         size calculation port specific, started basis for some register
6915         optimizations
6916         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
6917         missing push/pop of r0/r1. Optimized push/pops
6918         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
6919         * device/lib/_modsint.c (_modsint),
6920         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
6921         and stack version so regression tests pass
6922
6923 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
6924
6925         * src/Makefile.in (dep): include SLIBOBJS in dependency check
6926         * src/SDCCast.c (decorateType): catch another small optimization
6927         with '?' operator
6928         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
6929         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
6930         modified to finally use computeType() all over SDCC,
6931         see Feature Request #877103
6932         * src/SDCCval.h: cosmetic
6933         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
6934         valCompare(); regression tested in muldiv.c
6935         * support/regression/tests/muldiv.c (testMod): mod sign follows
6936         dividend only
6937
6938 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
6939
6940         * src/SDCCast.c (decorateType): fixed bug #902362
6941         * doc/INSTALL.txt: fixed install instructions for win32
6942
6943 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
6944
6945         * device/include/Makefile.in (install): fixed by replacing spaces
6946         by tabs
6947         * doc/README.txt,
6948         * doc/INSTALL.txt: updated for release
6949         * doc/sdccman.lyx: added warning for --xstack being buggy
6950
6951 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
6952
6953         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
6954         to eliminate build warnings.
6955         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
6956
6957 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
6958            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
6959
6960         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
6961         removed -penable-stack, added comment for stack pragma, added
6962         warning for not initializing the stack/frame registers, removed
6963         comment at interrupts section
6964
6965         Stack is made permanent, there is no ability to disable stack usage.
6966         * src/pic16/device.h,
6967         * src/pic16/device.c: removed all references to USE_STACK macro,
6968         * src/pic16/device.c (pic16_dump_section): when no elements in
6969         rlist, free rlist before return,
6970         * (pic16_dump_int_registers): NEW, internal registers are a new set
6971         of general purpose registers reused by each function,
6972         * (checkAddReg): returns 1 if registers is added to set,
6973         * (pic16_groupRegistersInSection): when a registers is of type
6974         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
6975         * src/pic16/device.h: memRange and Assigned Memory are deleted,
6976         SRCASECMP macro is moved here from device.c
6977         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
6978         PO_PCLATU, PO_PRODL, PO_PRODH,
6979         * (pic16_pCodeOpType, genMinus,
6980         changed compares to "a" register, with AOP_ACC,
6981         * (pic16_genPlus): fixed some bugs and indented properly,
6982         * (pic16_addSign): changed size to size+offset in the MOVWF
6983         instruction,
6984         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
6985         multiply 8-bit operand by literal, result is 8-bit,
6986         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
6987         multiply 2 8-bit operand, result is 8-bit,
6988         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
6989         genUMult8X*_16,
6990         * src/pic16/gen.c: changed accUse to contain WREG only,
6991         * (pic16_emitcomment): renamed to pic16_emitpcomment,
6992         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
6993         true, do not use immediate addressing any more unless sym is a
6994         pointer in codespace,
6995         * (aopForRemat): do not use immediate addressing when symbol not in
6996         codespace and when symbol's address is requested,
6997         * (aopOp): for-loop in if(sym->accUse) is modified for the new
6998         accUse size (= 1),
6999         * (aopGet): added case for AOP_ACC and don't return "accumulator
7000         bug" but WREG instead,
7001         * (popGetTempReg): pushes contents of temporary register in stack,
7002         * (popReleaseTempReg): pops contents of temporary register from
7003         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
7004         * (pic16_popGet): separated case AOP_ACC to return register WREG
7005         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
7006         or PO_IMMEDIATE and initializes their instance/offset appropriately,
7007         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
7008         the use of immediate pointers to certain cases only.
7009
7010         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
7011         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
7012         * (assignResultValue, genCall, genRet): modified to use the new
7013         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
7014         genPcall is still broken,
7015         * (genFunction): added code to create 'A' type pBlocks when
7016         interrupt functions are generated, code not extensively tested yet,
7017         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
7018         * (genEndFunction): modified so ISRs pop stored registers from stack,
7019         * (genMultOneByte): cleanup,
7020         * (AccRsh): added flag andmask, to and result with appropriate mask,
7021         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
7022         * (genDataPointerGet): fixed and reenabled its use,
7023         * (genNearDataPointerGet): bugs fixed,
7024         * (genDataPointerSet): bugs fixed,
7025         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
7026         pic16_DumpSymbol, pic16_DumpOp,
7027         * src/pic16/genutils.h: function prototypes for the above functions,
7028         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
7029         pointers,
7030         * (pic16emitRegularMap): many many many improvements, but needs a
7031         major cleanup,
7032         * src/pic16/main.c: enable_stack in pic16_options is removed,
7033         * (_pic16_parseOptions): removed command line options -penable-stack,
7034         * (_process_pragma): emit stack symbol only when stack pragma is
7035         processed,
7036         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
7037         redirected to FSR0L/FSR0H pair,
7038         * (pic16_get_op, pic16_get_op2): modifications and improvements,
7039         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
7040         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
7041         for immediates,
7042         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
7043         * (dumpPicOptype): NEW,
7044         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
7045         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
7046         with movff instruction,
7047         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
7048         added pic16_int_regs, some packRegsFor* functions are commented out,
7049         because produce errors,
7050         * src/pic16/NOTES: minor modifications
7051
7052 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7053
7054         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
7055         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
7056         --pack-iram.
7057         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
7058         * as/mcs51/lkaomf51.c: fixed bug #895763
7059
7060 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
7061
7062         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
7063
7064 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7065
7066         * doc/sdccman.lyx: added details about the HC08 storage classes and
7067         interrupts, fixed the register usage info for z80 & gbz80
7068
7069 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
7070
7071         * doc/sdccman.lyx: added more pic16 port documentation
7072         * device/include/pic16/: added header pic18fregs.h
7073
7074 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
7075
7076         * doc/sdccman.lyx: added Vangelis' contribution
7077
7078 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7079
7080         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
7081         extend to the next CALL or PCALL, not just to the next CALL.
7082
7083 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
7084
7085         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
7086
7087 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7088
7089         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
7090         bug #895752 and a better fix for bug #716790
7091
7092 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7093
7094         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
7095
7096 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7097
7098         * doc/sdccman.lyx: minor changes, minor changed
7099
7100 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
7101
7102         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
7103         which can't handle SDCC_NEWONEBYTEOPS,
7104         (geniCodeMultiply): removed conversion from mult to shift for pic14
7105         and pic16
7106
7107 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7108
7109         * src/hc08/gen.h,
7110         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
7111         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
7112         thus fixing bug #895406
7113
7114 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
7115
7116         * device/lib/_modsint.c,
7117         * device/lib/_modslong.c: sign follows divisor only
7118         * src/hc08/gen.c (genMultOneByte): if result size is 1,
7119         signs or signedness can be ignored
7120         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
7121         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
7122         added optimization for IFX,
7123         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
7124         arguments;
7125         reenabled optimization for IFX, which was removed on 2004-01-11
7126         * src/SDCCast.h: added return type IFX
7127         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
7128         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
7129         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
7130         SDCC_OLDONEBYTEOPS selects the old behaviour
7131         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
7132         changed again and commented promotion rule
7133         * src/SDCCval.c (valDiv): promotion no longer necessary
7134         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
7135         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
7136         rewritten
7137         * support/regression/tests/onebyte.c: added
7138
7139 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
7140
7141         * gen.c (genInline): reverted to old code for assemnling inline
7142         code because of bug reported James Chadd
7143
7144 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
7145
7146         * ralloc.h: missing declarations from previous patch,
7147         seems that patch for ralloc.h was never applied, fixed
7148
7149 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7150            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7151
7152         * pcode.c,
7153         * pcode.h,
7154         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
7155         indirect addressing. Marked FSR0 as deprecated
7156         * gen.c (pointerCode): commented out, not needed now
7157         (pic16_popGet2p): new MOVFF helper function
7158         (genGenPointerGet),
7159         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
7160         (shiftRLong): removed duplicate debugging info
7161
7162 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7163
7164         * src/ds390/gen.c (genNearPointerGet),
7165         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
7166         optimization with bits, but not bitfields.
7167         * src/ds390/ralloc.c (packRegisters),
7168         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
7169
7170 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
7171
7172         * src/SDCCcse.c (algebraicOpts): copy operands before modification
7173
7174 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7175
7176         * src/SDCCsymt.h,
7177         * src/SDCCicode.c (operandFromSymbol),
7178         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
7179         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
7180         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
7181         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
7182         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
7183         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
7184         bug #892038
7185         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
7186         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
7187         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
7188         * src/SDCCsymt.c (newSymbol),
7189         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
7190         enumerator_list),
7191         * src/SDCCval.h,
7192         * src/SDCCval.c (newiList): fixed bug #885705
7193
7194 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7195
7196         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
7197         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
7198
7199 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7200
7201         * device/include/c8051f120.h,
7202         * device/include/c8051f300.h,
7203         * device/include/c8051f310.h: added/updated header files for Silicon
7204         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7205         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
7206         in new section Submitting patches
7207
7208 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7209
7210         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
7211         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7212         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7213         genGenPointerSet),
7214         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
7215         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7216         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7217         genGenPointerSet),
7218         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
7219         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7220         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7221         genGenPointerSet),
7222         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
7223         genFarPointerGet, genCodePointerGet, genGenPointerGet,
7224         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
7225         genGenPointerSet): fixed bug #892400
7226         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
7227         to eliminate build warnings.
7228         * src/SDCCast.c (processParms),
7229         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
7230         fixed bug 751859
7231         * support/valdiag/valdiag.py: added GCC to the list of defines active
7232         when compiling with gcc
7233
7234 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7235
7236         * support/Util/SDCCerr.h,
7237         * support/Util/SDCCerr.c,
7238         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
7239         with an incomplete type (fixed bug #883734)
7240         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
7241
7242 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7243
7244         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
7245
7246 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7247
7248         * src/SDCCast.c (decorateType),
7249         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
7250         function pointer implementation
7251         * support/regression/tests/funptrs.c: added tests to verify both forms
7252         of function pointers work correctly. Added tests to verify parameters
7253         are passed in the correct order.
7254
7255 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
7256
7257         * device.c (regCompare): registers are sorted by ascending
7258         address and increasing size,
7259         * main.c (_pic16_finaliseOptions): removed the declaration
7260         of compiler macro MCU. Now a macro of the format pic18fxxxx
7261         will be defined from the command line
7262
7263 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
7264             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
7265
7266         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
7267         PCOP_RLCF was overwritten!
7268         * gen.c (genSkip): commented out calls to pic16_emitcode,
7269         * (genCmpEQ): fixed "long" compares, only high word did get compared,
7270         * (genlshTwo),
7271         * (genRRC): added debugging info,
7272         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
7273         overwritten while shifting,
7274         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
7275         overwritten while shifting,
7276         * (AccLsh),
7277         * (AccRsh),
7278         * (shiftLLeftOrResult),
7279         * (shiftRLeftOrResult),
7280         * (shiftRLong),
7281         * (shiftLLong): Implemented with pic16_emitpcode
7282         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
7283         * (genLeftShift): Fixed bug, operand for shift by variable always
7284         was "and"ed with 0x0f,
7285         * (genLeftShiftLiteral),
7286         * (genrshTwo),
7287         * (genRightShiftLiteral): added debugging info,
7288         * (genrshFour): added comment,
7289         * (genRightShift): determined signedness from operand "left"
7290         instead of "result"
7291
7292 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7293
7294         * src/SDCCicode.c (geniCodeParms),
7295         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
7296         function pointers, fixed function pointer bugs #861242 and #861896
7297
7298 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7299
7300         * device/include/c8051f000.h,
7301         * device/include/c8051f120.h,
7302         * device/include/c8051f300.h: added header files for Silicon
7303         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
7304
7305 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
7306
7307         * src/SDCCast.c (processParams): added new type flow and restructured
7308         (gatherAutoInit): added new type flow
7309         (addCast): cosmetic changes
7310         (getLeftResultType): added new type flow for array indices, patch
7311         provided by Stas, see FR #877103
7312         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
7313         array index patch by Stas
7314         * src/SDCCast.h: added prototype getResultTypeFromType()
7315         * src/SDCCval.h,
7316         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
7317         * src/pic/glue.c (pic14emitStaticSeg),
7318         * src/pic16/glue.c (pic16emitStaticSeg),
7319         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
7320         for initialization of symbols
7321         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
7322         * support/Util/SDCCerr.h:
7323         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
7324         * .version: bumped version number to 2.3.8
7325         * device/include/Makefile.in (install),
7326         * doc/Makefile (install): changed to 'rm `find ...`' construct to
7327         avoid warnings
7328
7329 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
7330
7331         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
7332         Slade Rich fixed an optimization bug
7333         * src/pic/pcodepeep.c,
7334         * src/pic/pcoderegs.c
7335         * doc/Makefile (install): added test for directory
7336
7337 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7338
7339         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
7340         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
7341         * src/pic/ralloc.c (getRegPtr, getRegGpr),
7342         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
7343         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
7344         * as/mcs51/asexpr.c (term),
7345         * as/hc08/asexpr.c (term): fixed bug #887146
7346
7347 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7348
7349         * src/z80/gen.c (genMult): handle single byte result product
7350         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
7351         DUMMY_READ_VOLATILE (fixed bug #886367)
7352
7353 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7354
7355         * support/regression/tests/libmullong.c: fixed logic, on little endian
7356         hosts we ended without a mullong_wrapper()
7357
7358 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7359
7360         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
7361         virus/worm forged address usage.
7362
7363 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
7364
7365         Fixed promotion, it should be done on AST level:
7366         * src/SDCCast.c (addCast): added promotion to int
7367         (decorateType): updated call to upCast()
7368         * src/SDCCicode.c (geniCodeLeftShift): removed call to
7369         usualUnaryConversions()
7370
7371 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
7372
7373         * support/regression/tests/literalop.c (mulWrapper): Added a
7374         wrapper to remove integer overflow warnings.
7375
7376         * support/regression/tests/float_trans.c: Made work on host.
7377
7378         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
7379         location of sz80.
7380
7381         * support/regression/generate-cases.py (main): Changed from inline
7382         to a main method.
7383
7384         * doc/Makefile (install): Changed to depth first to get rid of
7385         missing directory install warning.
7386
7387         * as/Makefile (install-doc): Made work on Mac.
7388
7389 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
7390
7391         * src/SDCCast.c: added an additional type flow in decorateType() of
7392         opposite direction, see feature request #860006; it's enabled at runtime
7393         by setting the environment variable SDCC_NEWTYPEFLOW
7394         * src/SDCCast.h: changed prototype of decorateType()
7395         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
7396         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
7397         'char' to 'int' can be omitted, if both operands are 'unsigned char';
7398         see feature request #877103
7399         * src/SDCCval.c: updated call of decorateType()
7400         (valBitwise): fixed bug #882876
7401         (valMinus): added promotion
7402         (valLogicAndOr): result is unsigned
7403         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
7404         * src/SDCCsymt.c (computeType),
7405         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
7406         must not cause an unsigned operation
7407         * src/pic/glue (pic14emitRegularMap),
7408         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
7409
7410 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
7411
7412         * src/pic/pcode.c (PCodeID): commented out left over debug code
7413
7414 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
7415
7416         * support/valdiag/tests/overflow.c: added shift tests
7417         * src/pic/device.c,
7418         * src/pic/gen.c,
7419         * src/pic/gen.h,
7420         * src/pic/glue.c,
7421         * src/pic/main.c,
7422         * src/pic/pcode.c,
7423         * src/pic/pcode.h,
7424         * src/pic/pcodepeep.c,
7425         * src/pic/pcoderegs.c,
7426         * src/pic/ralloc.c,
7427         * src/pic/ralloc.h: applied patch from Slade Rich;
7428         added support for multiple code pages and multiple RAM banks on the
7429         PIC 14 port. The ASM files now no longer simply assume all the
7430         code / RAM are in the same page / bank. This means the linker can
7431         safely allocate code/RAM of separate ASM files to different pages/banks.
7432         * doc/sdccman.lyx: added Slade's tips
7433         * src/mcs51/peeph.def: fixed bug #880768
7434
7435 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7436
7437         * src/hc08/ralloc.c (rematStr): fixed bug #879282
7438         * src/SDCCast.c (decorateType): fixed bug #880197
7439
7440 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
7441
7442         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
7443         getopt.h.
7444
7445         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
7446         strtof is not part of C89 and isn't included with Mac OS X.
7447
7448 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7449
7450         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
7451         shiftL2Left2Result): fixed bug #879326
7452         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
7453         (genMultOneByte): fixed bug in signed vs unsigned multiplication
7454         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
7455         address fetch for clr instruction
7456         * device/lib/hc08/_mulint.c: created optimized assembly version
7457         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
7458
7459 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
7460
7461         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
7462         proposed in FR #877103
7463
7464 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
7465
7466         * src/SDCCval.c (cheapestVal): added missing checks
7467         * src/SDCCicode.c (usualBinaryConversions): fixed condition
7468         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
7469
7470 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
7471
7472         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
7473         equal operands
7474
7475 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
7476
7477         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
7478         loaded with the linker search paths (-L arguments) and the libraries
7479         to be linked with the current source (-l arguments). Changes
7480         currently will affect only the pic16 port.
7481         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
7482         include path the port specific paths and port specific libraries,
7483         * gplink command now contains the $3 argument,
7484         * src/pic16/device.h,
7485         * src/pic16/device.c,: structure PIC_device is made public and
7486         renamed to PIC16_device, the same for variable Pics which is renamed
7487         to Pics16. Updated all references to them.
7488         * src/pic16/glue.c (pic16glue): corrected bug with code
7489         initialization which bypassed the variable initializations block.
7490
7491         * device/lib/pic16/Makefile.rules: removed --penable-stack from
7492         COMPILE_FLAGS and added the --nostdinc option
7493
7494 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7495
7496         * device/include/mc68hc908jb8.h: Register defs for another member
7497         of the hc08 family. Contributed by Bjorn Bringert - thanks!
7498
7499 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
7500
7501         Documenting changes from previous commits.
7502         * configure.in (version 1.56),
7503         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
7504         when generating output files to configure the pic16 library,
7505         but now I've commented it out, since gputils aren't installed in the
7506         SF compile farm, so library won't compile
7507
7508         * device/lib/Makefile.in (version 1.56): initially I've added in
7509         target 'all' the prerequestive 'model-pic16' so it compiled the
7510         pic16 library, but now I've commented it out for the same reasons
7511         above,
7512         * added targets 'model-pic16' and 'objects-pic16' to compile the
7513         library
7514         * added target 'port-specific-objects-pic16' to handle the
7515         generated libraries and copy them into the build/ directory
7516         * added target 'clean-intermediate-pic16' to clean intermediate
7517         files into pic16 directory
7518         * in target 'installdirs' added line to create directory pic16 in
7519         the installation path
7520
7521         * device/include/Makefile.in (version 1.11): in target 'install'
7522         added lines to copy all header files to installation path,
7523         * in target 'installdirs' added line create directory for pic16
7524         headers in the installation path
7525
7526 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
7527
7528         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
7529          a function call
7530
7531 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
7532
7533         * configure,
7534         * device/lib/configure.in,
7535         * device/lib/configure: fixed for autoconf 2.57
7536
7537 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7538
7539         * src/z80/main.c (_parseOptions): fixed the portmode= command line
7540         option so that it actually works. Made it specific to the z80, since
7541         the gbz80 doesn't have these kinds of I/O ports.
7542
7543 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7544
7545         * device/include/z180.h,
7546         * device/lib/_memcpy.c,
7547         * device/lib/_memmove.c,
7548         * device/lib/_mulint.c,
7549         * device/lib/ser_ir.c,
7550         * device/lib/ser_ir_cts_rts.c,
7551         * device/lib/_strcmp.c,
7552         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
7553         * src/z80/main.c (_process_pragma): add support for pragmas bank and
7554         portmode; added deprecation warning for bank= and protmode= forms.
7555         Also, guard against buffer overflow.
7556         * src/z80/gen.c (aopGet): generate better code for sfr banked read
7557
7558 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7559
7560         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
7561         changed interrupt vector table generation to only emit declared vectors.
7562         * device/include/Makefile.in: added missing backslash
7563         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
7564
7565 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7566
7567         Mainly changes to support compilation of the device libraries
7568         * src/pic16/device.c: stack is allocated via symbol and not
7569         via literal number. The symbol is placed in the corresponding
7570         position of the data ram
7571         * (pic16_dump_section): relocatable and absolute uninitialized
7572         data are now emitted in sorted order to reduce section naming,
7573         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
7574         weren't marked as being in the access bank,
7575
7576 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
7577
7578         Added portion of GNU PIC Library under the directory
7579         device/include/pic16 and device/lib/pic16. These files
7580         contain the declarations of SFRs for the PIC18Fxx2 devices.
7581         The directory is initialized via configure from toplevel.
7582
7583 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
7584
7585         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
7586         the spilllocations to be compared correctly
7587
7588 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7589
7590         * src/SDCCast.c (decorateType): fixed bug introduced today
7591
7592 2004-01-12  Borut Razem <borut.razem AT siol.net>
7593
7594         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
7595         doc/sdccman.lyx: upper case pragmas are deprecated
7596
7597 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
7598
7599         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
7600         in simpler and even better code
7601
7602 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
7603
7604         * src/SDCCicode.c (operandOperation): fixed bug #874819
7605         * src/SDCCast.c (decorateType): fixed
7606         char foo (unsigned long ul) { return ul > 0; }
7607
7608 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7609
7610         * doc/sdccman.lyx: Moved and added some sections, small changes
7611         all over. Telling LaTeX to be less strict with word spacing
7612         to better keep the right margin. Changed some notes about
7613         maintainance of the ports in section 3.2.1 - is it OK like this?
7614
7615 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7616
7617         SDCC source changes:
7618         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
7619         convilong): modified to inform the pic16 port that builtin functions
7620         are external
7621
7622         PIC16 PORT specific changes:
7623         * src/pic16/device.c pic16_dump_equates() added,
7624         processor registers declared internally by the port are emitted in
7625         the translation as equates,
7626         * src/pic16/gen.c: inline code is passed unprocessed to the
7627         translation,
7628         * (pic16_popGetLit2): fnuction modified to take second operand as
7629         pCodeOp pointer and not as literal,
7630         * (popRegFromIdx): prefixed with pic16_,
7631         * (pic16_popCombine2): modified to receive already allocated pCode
7632         operands,
7633         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
7634         * (genFunction): initializes local stack frame and pushes on stack
7635         all the registers used by this function,
7636         * (genEndFunction): restores all registers from stack and restores
7637         stack frame,
7638         * src/pic16/glue.c (pic16emitRegularMap): various changes and
7639         improvements,
7640         * (pic16glue): changed the program startup sequence,
7641         * added new dbName code 'A' for functions placed in absolute section
7642         * src/pic16/main.c: added function attribute _naked,
7643         * added pragma 'code' to place a fnuction at an absolute address,
7644         * added command line arguments --debug-ralloc and --pcode-verbose,
7645         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
7646         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
7647         * (pic16_newpCodeOpLit2): modified to take the second operand as
7648         pCodeOp pointer,
7649         * (pic16_printpBlock): modified to emit each function in a separate
7650         section,
7651         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
7652         UPPER for immediate operands,
7653         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
7654         instruction,
7655         * src/pic16/peeph.def: all peepholes with movff are commented out,
7656         because there is a problem in the pcode peep optimizer,
7657         * src/pic16/ralloc.c: the register allocator can now reuse local
7658         function symbols for another function. This saves register usage.
7659         * src/pic16/ralloc.h: added flag isLocal in structure regs,
7660
7661         Added file src/pic16/NOTES with information about program writing on
7662         the current port version.
7663
7664 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7665
7666         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
7667         and peephole 252 (array access)
7668
7669 2004-01-09  Borut Razem <borut.razem AT siol.net>
7670
7671         * src/SDCCmain.c : fixed #872250: -l command line defined library
7672           files are scanned before standard library files
7673
7674 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7675
7676         * src/SDCCast.c (decorateType): fixed bug #874046
7677
7678 2004-01-09  Borut Razem <borut.razem AT siol.net>
7679
7680         * support/scripts/sdcc.nsi: remove previous installation
7681
7682 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7683
7684         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
7685         bytes for last interrupt vector (mcs51)
7686         * sdcc.spec: fixed typo
7687
7688 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7689
7690         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
7691         gen51Code): more efficient parameter receive for --model-large
7692         ("bug" #845294)
7693
7694 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7695
7696         * src/ds390/main.c,
7697         * src/z80/main.c: added missed needLinkerScript flags (more than
7698         one port structure defined in these file)
7699         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
7700         bug #795325
7701
7702 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
7703
7704         * src/SDCCmain.c: removed various references to DEFAULT_PORT
7705         * src/port.h: added flag needLinkerScript in port->linker
7706         structure to inform whether to create a .lnk file or not,
7707         * src/avr/main.c,
7708         * src/ds390/main.c,
7709         * src/hc08/main.c,
7710         * src/mcs51/main.c,
7711         * src/pic/main.c,
7712         * src/pic16/main.c,
7713         * src/xa51/main.c,
7714         * src/z80/main.c: changed appropriately to configure
7715         needLinkerScript flag
7716         * src/pic/gen.c,
7717         * src/pic16/gen.c (genAddrOf): fixed bug #863624
7718         * src/pic/glue.c: added variable udata_section_name to
7719         override default uninitialized data segment definition for
7720         devices only with SHAREBANK memory (reported from Erik Epetrich)
7721         * (pic14emitOverlay): modified to emit a commented overlay segment
7722         directive when no overlay data exist
7723         * (picglue): modified to emit uninitialized data segment
7724         according to udata_section_name
7725         * src/pic/main.c (_pic14_parseOptions): added command line
7726         options --udata-section-name=[name] to override default
7727         udata definition name
7728         * modified _linkCmd and _asmCmd to include compiler passed
7729         arguments via -W option
7730         * src/pic16/main.c: added $l in _asmCmd, changed extension for
7731         object file from '.rel' to '.o' in port->linker structure,
7732         changed size of fptr from 2 to 3 in port structure
7733
7734 2004-01-07  Borut Razem <borut.razem AT siol.net>
7735
7736         * support/scripts/sdcc.nsi: update PATH
7737         * support/scripts/sdcc.ico: craeted
7738
7739 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
7740
7741         * device/include/Makefile.in: fix install
7742         * doc/Makefile: fix install
7743
7744 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7745
7746         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
7747         in bug #860505
7748         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
7749         how the function variable allocation summary is displayed; also
7750         include information about variables allocated to the overlay
7751         segment
7752
7753 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7754
7755         * as/mcs51/lkmain.c: Help about -Y option
7756         * as/mcs51/lkarea.c: Fixed gcc warnings
7757
7758 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7759
7760         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
7761         fixed warning
7762         * support/valdiag/tests/overflow.c: added
7763         * src/SDCCast.c (decorateType),
7764         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
7765         LEFT_OP (left shift)
7766
7767 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7768
7769         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
7770         (default behaviour).
7771
7772 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7773
7774         A python script to validate compiler diagnostic messages. It can be
7775         used to verify that sdcc complains about bad c source code and
7776         gives a good location of the error.
7777         * support/valdiag/Makefile,
7778         * support/valdiag/valdiag.py,
7779         * support/valdiag/tests/*
7780
7781 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7782
7783         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
7784         * src/SDCCsymt.c (newEnumType),
7785         * src/SDCCsymt.h
7786         * support/Util/SDCCerr.c,
7787         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
7788         enum related bugs.
7789         * support/regression/tests/enum.c: added test for enum values that
7790         require at least 2 bytes of storage.
7791
7792 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7793
7794         * src/common.h: added ifndef/define/endif macros
7795         around the header file.
7796         Bug reported from Jesus Calvino-Fraga
7797
7798 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
7799
7800         * sdcc.spec: updated
7801         * device/include/Makefile.in: don't install CVS directories
7802         * device/lib/Makefile.in: added removal of CVS directories after install
7803         * doc/Makefile: fixed install, added local_icons
7804         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
7805         * src/mcs51/gen.c (genRightShift): fixed bug #870788
7806         * src/ds390/gen.c (genRightShift): fixed bug #870788
7807         * src/SDCCast.c (decorateType): fixed bug #870781
7808
7809 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
7810
7811         PIC16 port related changes:
7812         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
7813         added variable stackPos,
7814
7815         * gen.c: genCall, assignResultValue: added support for
7816         pushing/retrieving function parameters to/from stack,
7817         genFunction,genEndFunction: setup stack frame for the
7818         generated function,
7819         genAddrOf: will be changed according to bug 863624
7820
7821         * added files genutils.c and genutils.h which contain gen*
7822         debugged and optimised functions extracted from gen.c
7823
7824         * glue.c: added variable 'externs' which holds extern symbols,
7825         pic16emitRegularMap: is modified to properly handle relocatable
7826          symbols under the new scheme,
7827         pic16createInterruptVect: is modified
7828         pic16printPublics: is modified to emit 'global' assembler directives,
7829         added pic16_printExterns to print extern symbols,
7830         pic16glue: initializes stack/frame pointer in the beginning of
7831         the assembly output. Temporary hack, will be corrected later,
7832         because gplink yet does not support stack and SDCC does not
7833         yet support a type of crt0.o object to create the final binary.
7834
7835         * Removed many lines that contain 8051 legacy code.
7836         * The code is finally placed under a 'code' directive.
7837         * Added port specific options.
7838
7839         * _process_pragma: simplified since now we do not need *special*
7840         include file to define SFR registers. But a separate header
7841         will be needed. This will be developed later.
7842         * _pic16_parseOptions: added, parses port specific options:
7843         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
7844         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
7845         --preplace-udata-with=
7846
7847         * _pic16_setDefaultOptions: modified to initialize section names,
7848         but hack is temporarly out of order since it needs improvement.
7849         * _pic16_genAssemblerPreamble: configuration words are emitted by
7850         their address instead of their name. This part is incomplete and
7851         supports only the 18Fxx2 devices. Other devices will emit an error
7852         during assembly since they do not contain the same set of config
7853         registers
7854         * _pic16_genIVT: is modified,
7855
7856         * pcode.c: added definitions for some hardware registers that are needed
7857         for stack support
7858         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
7859         All PCI entries are updated. Now LFSR is supported.
7860         * Removed pic16_pciTRIS is mentioned by mdubuc in source
7861         * added pic16_newpCodeOpLit2 to support instructions with
7862         two literal arguments
7863         * pic16_pCode2str: corrected code that emits assembler instructions
7864         with two literal operands and those that have an access bit modifier
7865         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
7866         this fixes a bug which caused some labels to be lost, when an
7867         assembler directive was added, i.e. banksel,
7868         * pic16_FixRegisterBanking: improved logic that causes the insertion
7869         of bank switching,
7870         * InlineFunction: functions that are called once, are not any more
7871         inlined. This can be a port option in the future,
7872
7873         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
7874
7875         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
7876         hold the corresponding uninitialized symbols,
7877         * pic16_allocProcessorRegister: registers have explicit marked the
7878         accessBank field,
7879         * pic16_allocInternalRegister: registers are explicit marked as
7880         not used,
7881         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
7882         processing list, so bit registers were lost,
7883         *
7884
7885         * ralloc.h: added field 'accessBank' and original symbol operand
7886         in register definition,
7887         * removed the field isMapped from register definition,
7888
7889         ** Several functions have been removed from various sources:
7890         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
7891         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
7892         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
7893         pic16_assignRelocatableRegisters
7894
7895         ** others have been introduced:
7896         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
7897         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
7898
7899 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
7900
7901         * support/scripts/inc2h.pl: changed definition of BIT_AT
7902         to emit 'sbit at' instead of 'bit at'. This was a request.
7903
7904         PIC16 port related preliminary changes:
7905         * gen.c: prefixed function popRegFromString with
7906         pic16_ and all references to it corrected
7907         * pcode.c: all pic16_pc_* hardware registers prefixed
7908         with underscore (_),
7909         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
7910         * ralloc.c: newReg(): when register is REG_SFR then
7911         set address to rIdx,
7912         pic16_allocProcessorRegister(): marks register wasUsed=0
7913         pic16_writeUsedRegs(): added a call to assign processor
7914         registers via pic16_assignFixedRegisters
7915
7916 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7917
7918         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
7919         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
7920         variables in unused register banks.  Also the SSEG is placed
7921         wherever there is enough space for it, and IDATA can be anywhere
7922         in internal RAM.  For now compile using -Wl-Y[stack_size].
7923         The mem file is different for this option as well, since it
7924         makes no sense of talking about DSEG lenght.
7925
7926 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
7927
7928         * src/SDCClrange.c: fixed bug 869095 that caused segfault
7929         in certain cases, e.g. when ROM assignment, patch provided
7930         from Albert den Haan.
7931
7932 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
7933
7934         Many signedness and type propagation fixes:
7935         * src/SDCCicode.c: made geniCodeCast() static
7936         replaced SPEC_ by IS_ (cosmetic)
7937         (operandOperation): fixed div and mod operation
7938         (usualBinaryConversions): added support for promotion of char
7939         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
7940         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
7941         (geniCodeAdd): an array index will stay unsigned, even if promoted
7942         from char to int
7943         (geniCodeArray): ditto
7944         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
7945         * src/SDCCsymt.c (computeType): added more support for char;
7946         promotion of char is selectable by promoteCharToInt, fixed signedness
7947         for all cases
7948         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7949         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
7950         * src/SDCCval (val*): replaced signedness calculation by
7951         computeType()
7952         rearranged if-branches (cosmetic)
7953         (valShift): added warning W_SHIFT_CHANGED
7954         (valCompare): fixed problem with different types
7955         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
7956         * support/regression/tests/literalop.c: added many cases
7957         * support/regression/tests/ast_constant_folding.c: changed finally to
7958         'unsigned int'
7959         * .version: new year, new version: 2.3.7
7960         * src/SDCCmain.c (main): applied patch #866468
7961         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
7962         provided by Scott Bronson
7963         * doc/sdccman.lyx: updated documentation for sdcdb
7964         updated and added chapter tips
7965
7966 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7967
7968         * src/SDCCsymt.h: missing from yesterday's commits
7969
7970 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7971
7972         * src/SDCC.y (struct_or_union_specifier),
7973         * support/Util/SDCCerr.c,
7974         * support/Util/SDCCerr.h: verify that struct & union tags are used
7975         as declared.
7976
7977 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7978
7979         * src/SDCCglobl.h: missing from yesterday's commits
7980
7981 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7982
7983         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
7984         sft_attributes, struct_declaration, parameter_declaration,
7985         type_name, start_block, declaration_list),
7986         * src/SDCC.lex (check_type): support redefinition of typedef names
7987
7988 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7989
7990         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
7991         aligned xdata arrays. Erik helped me with the if clause.
7992
7993 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7994
7995         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
7996         warning
7997
7998 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7999
8000         * src/SDCCast.h,
8001         * src/SDCCast.c (newAst_),
8002         * src/SDCCicode.h,
8003         * src/SDCCicode.c (ast2iCode, newiCode),
8004         * src/SDCCglobl.h,
8005         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
8006         expr, statement, expression_statement, selection_statement,
8007         iteration_statement, expr_opt, jump_statement): foundation for tracking
8008         sequence points
8009         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
8010         point code too)
8011
8012 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8013
8014         * support/Util/SDCCerr.c,
8015         * src/SDCCast.h,
8016         * src/SDCCast.c (createCase, createDefault, decorateType),
8017         * src/SDCClabel.c (labelUnreach),
8018         * src/SDCC.y (labeled_statement, jump_statement): More improvements
8019         to error messages.
8020         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
8021         (with thanks to Stas Sergeev)
8022         * device/include/time.h,
8023         * device/lib/time.c (CheckTime): suppress unreachable code warning
8024
8025 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8026
8027         * src/SDCCast.c (createIvalCharPtr),
8028         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
8029         bug #753752)
8030         * support/regression/tests/nullstring.c: tests for these two bugs
8031
8032 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8033
8034         * support/Util/SDCCerr.h,
8035         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
8036         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
8037         about storage class and 'at' used inside struct or union
8038         * src/SDCCBBlock.c (iCodeFromeBBlock),
8039         * src/SDCCcse.c (ifxOptimize),
8040         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
8041         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
8042         printIval, emitStaticSeg, emitOverlay),
8043         * src/SDCClabel.c (deleteIfx),
8044         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
8045         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
8046         gatherAutoInit, processParms),
8047         * support/Util/SDCCerr.h,
8048         * support/Util/SDCCerr.c (werrorfl): Support for better error location
8049         reporting for post-parse errors.
8050
8051 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8052
8053         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
8054         implicit casts via union; they don't work on big endian systems
8055         (possible fix for bug #861138)
8056
8057 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8058
8059         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
8060         * src/mcs51/main.c: fixed the fix for bug #737001
8061
8062 2003-12-15  Borut Razem <borut.razem AT siol.net>
8063
8064         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
8065
8066 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8067
8068         * support/makebin/makebin.c: put output in binary mode
8069
8070 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8071
8072         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
8073         xdata and data memory on startup. Set the environment variable
8074         SDCC_NOGENRAMCLEAR to disable this.
8075         * src/mcs51/peephole.def,
8076         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
8077         (allows non-interrupt and interrupt code to safely compete for a resource
8078         without the non-interrupt code having to disable interrupts)
8079
8080 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8081
8082         * src/SDCCicode.c (geniCodeAdd),
8083         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
8084         with valFromType if type might be a pointer and host is big endian).
8085         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
8086         types, not just integer types.
8087         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
8088         multiply defined with mismatching "at" address.
8089
8090 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8091
8092         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
8093         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
8094         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
8095         with embedded nulls (fixed bug #753752)
8096
8097 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8098
8099         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
8100         Apparently this did not see much testing (endless loop)
8101
8102 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8103
8104         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
8105
8106 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8107
8108         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
8109         gracefully handle NULL memmap pointers
8110
8111 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8112
8113         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
8114         instead of deleting the iCode when an operand is volatile
8115         * src/z80/gen.c (genDummyRead),
8116         * src/mcs51/gen.c (genDummyRead),
8117         * src/ds390/gen.c (genDummyRead),
8118         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
8119         not just IC_RIGHT
8120         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
8121         * src/SDCC.y: fixed bug #850420
8122
8123 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8124
8125         Applied z80 i/o port patch from Peter Townson and fixed some operators
8126         to better handle operands in A register.
8127         * device/include/z180.h
8128         * src/SDCC.y
8129         * src/SDCCglue.c
8130         * src/z80/gen.c
8131         * src/z80/gen.h
8132         * src/z80/main.c
8133         * src/z80/peeph-z80.def
8134         * src/z80/peeph.def
8135         * src/z80/z80.h
8136
8137 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8138
8139         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
8140
8141 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8142
8143         * device/lib/hc08/_mullong.c: Removed extra #endif
8144
8145 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8146
8147         * sim/ucsim/hc08.src/inst.cc,
8148         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
8149         carries from x to h
8150         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
8151         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
8152         * device/include/stdarg.h: fixed varargs for hc08
8153         * device/lib/Makefile.in,
8154         * device/lib/hc08/Makefile,
8155         * device/lib/hc08/_mulint.c,
8156         * device/lib/hc08/_mullong.c: fixed some endian problems
8157
8158 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8159
8160         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
8161         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
8162         * device/lib/_gptrget.c,
8163         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
8164
8165 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8166
8167         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
8168         * src/SDCCast.c (astErrors): fixed bug #846007
8169         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
8170
8171 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8172
8173         * src/SDCCast.c (decorateType): disabled a transformation I added in
8174         revision 1.188 (access to fields of a structure at an absolute address);
8175         it breaks with bitfields, extern declarations, and gcse analysis.
8176         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
8177         could be assigned through a pointer, so don't complain.
8178         * src/SDCCast.c (astErrors),
8179         * src/SDCCast.h,
8180         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
8181
8182 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
8183
8184         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
8185         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
8186         output of __config directives, since gpasm now supports them
8187         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
8188         pre-processor macro, i.e. -DMCU=p18f452
8189         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
8190         and modified to handle 'cast' icode similarly to '=' icode
8191         * src/pic16/device.h (typedef struct PIC_device): added field
8192         'extMIface' to indicate that chip has external memory interface
8193         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
8194         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
8195         18F8720
8196
8197 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8198
8199         * src/SDCC.y (pointer): fixed bug #846006
8200         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
8201         * src/SDCCast.c (decorateType): fixed bug #846009
8202         * src/ds390/peeph.def,
8203         * src/ds390/gen.c (genAnd, genOr),
8204         * src/mcs51/peeph.def,
8205         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
8206
8207 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8208
8209         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
8210         * src/SDCCdflow.c
8211         * src/SDCCcse.c
8212         * src/SDCCcse.h
8213         * src/SDCCBBlock.h
8214         * src/SDCCBBlock.c
8215
8216 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
8217
8218         fixed bug #845089
8219         * src/SDCCbitv.h,
8220         * src/SDCCbitv.c: added function to free a bitvector
8221         * src/SDCClrange.h,
8222         * src/SDCClrange.c: added function to recompute the liveranges
8223         * src/avr/ralloc.c,
8224         * src/ds390/ralloc.c,
8225         * src/hc08/ralloc.c,
8226         * src/mcs51/ralloc.c,
8227         * src/pic/ralloc.c,
8228         * src/pic16/ralloc.c,
8229         * src/xa51/ralloc.c,
8230         * src/z80/ralloc.c: recompute the liveranges after register packing
8231
8232 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
8233
8234         * src/SDCCloop.c (newInduction): fixed bug #845630
8235
8236 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8237
8238         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
8239         inadvertantly left behind from my 2003-11-12 change
8240
8241 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8242
8243         Updated headers I neglected to commit yesterday.
8244         * src/SDCClrange.h,
8245         * src/SDCCicode.h
8246
8247 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8248
8249         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
8250         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
8251         * src/SDCCopt.c (eBBlockFromiCode),
8252         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
8253         the creation of the key hash table from the sequencing so it can be used
8254         earlier (for some GCSE bug fixes still pending)
8255
8256 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8257
8258         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
8259         * support/regression/tests/addsub.c: testing genPlus shortcut
8260
8261 2003-11-15  Borut Razem <borut.razem AT siol.net>
8262
8263         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
8264
8265 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8266
8267         * src/SDCCcse.c (cseBBlock): fixed bug #527779
8268         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
8269         ordering is immaterial.
8270         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
8271
8272 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8273
8274         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
8275         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
8276         (SIGSEV) of bug #840381
8277         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
8278         unlink new file before rename if new and old filenames are the same)
8279
8280 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8281
8282         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
8283         uninitialized variables) for the mcs51. Set environment variable
8284         SDCC_GENRAMCLEAR to test.
8285         xdata initialization slightly shorter
8286
8287 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8288
8289         * src/SDCCsymt.h,
8290         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
8291         #838241 & 780691 (basicly the same bug)
8292         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
8293         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
8294
8295 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
8296
8297         * src/SDCCmain.c (linkEdit): "fix" #834252
8298
8299 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8300
8301         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
8302         * src/SDCCast.h,
8303         * src/SDCC.y: fixed bug #819403
8304
8305 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8306
8307         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
8308         the reentrant attribute.
8309         * src/hc08/gen.c (genPackBits): added missing stack readjustment
8310         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
8311         simulation
8312         * src/SDCCast.c (decorateType): fixed bug with storage class not being
8313         updated during pointer dereference; f.e. ~(((char *)1)*) was being
8314         erroneously reduced to a literal.
8315         * src/hc08/ralloc.c (packRegisters, rematStr),
8316         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
8317         some cases
8318
8319 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8320
8321         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
8322         * doc/sdccman.lyx: changed from 'article' to 'book'
8323         * doc/Makefile: readded test_suite_spec and cdbfileformat
8324
8325 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
8326
8327         * device/include/stdlib.h: include malloc.h to comply with ANSI
8328         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
8329
8330 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8331
8332         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
8333         * doc/clean.mk: also remove *.out files
8334         * doc/sdccman.lyx: some additions, larger top/bottom margins
8335
8336 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8337
8338         * src/SDCC.y: fixed bug #837365
8339         * support/regression/tests/bitopcse.c
8340         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
8341         a symbol (might be valop instead)
8342         * device/lib/Makefile.in: added errno.c to HC08SOURCES
8343         * device/lib/clean.mk: added hc08 to the cleaning list
8344
8345 2003-11-04  Borut Razem <borut.razem AT siol.net>
8346
8347         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
8348           made 2003-11-04
8349         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8350           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
8351           malloc is declared in standard stdlib.h
8352
8353 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8354
8355         * device/lib/hc08/Makefile: need to clean .rel not .o files
8356         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
8357
8358 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8359
8360         * src/port.h,
8361         * src/hc08/main.c,
8362         * src/mcs51/main.c,
8363         * src/ds390/main.c,
8364         * src/z80/main.c,
8365         * src/avr/main.c,
8366         * src/pic/main.c,
8367         * src/pic16/main.c,
8368         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
8369         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
8370         tests (which uses the port's oclsExpense function)
8371         * src/SDCC.y,
8372         * src/SDCCast.c,
8373         * src/SDCCicode.c,
8374         * src/hc08/gen.c,
8375         * src/ds390/gen.c,
8376         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
8377
8378 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8379
8380         * src/SDCCcse.c (ifxOptimize),
8381         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
8382         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
8383         deleting the IFX iCode.
8384         * src/hc08/ralloc.c: reduced unneeded slocs
8385         * src/hc08/gen.c: fixed bug in asmopToBoolean
8386
8387 2003-11-04  Borut Razem <borut.razem AT siol.net>
8388
8389         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
8390           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
8391           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
8392           transferred to configure
8393
8394 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
8395
8396         Use headers defined in the C[++] standards:
8397         * sim/ucsim/gui.src/serio.src/fileio.cc
8398         * sim/ucsim/gui.src/serio.src/frontend.cc
8399         * sim/ucsim/gui.src/serio.src/main.cc
8400         * sim/ucsim/gui.src/serio.src/posix_signal.cc
8401         * support/Util/NewAlloc.c
8402         * as/hc08/lklibr.c
8403         * as/mcs51/lklibr.c
8404         * as/z80/aslist.c
8405         * as/z80/assym.c
8406
8407 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8408
8409         * Added MSVC projects for hc08 assembler and linker:
8410         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
8411         /as/hc08/link_hc08.dsp
8412
8413 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
8414
8415         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
8416
8417 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
8418
8419         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
8420
8421 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8422
8423         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
8424
8425 2003-10-31  Borut Razem <borut.razem AT siol.net>
8426
8427         * support/cpp2/cpplib.h,
8428           support/cpp2/cpplib.c,
8429           support/cpp2/cpplex.c,
8430           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
8431           to switch _asm block preprocessing on / off. Default is
8432           #pragma preproc_asm +
8433
8434 2003-10-31  Borut Razem <borut.razem AT siol.net>
8435
8436         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
8437           when outputting comment blocks (when executed with -C option) and
8438           _asm (SDCPP specific) blocks
8439
8440 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8441
8442         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
8443
8444 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
8445
8446         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
8447
8448 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
8449
8450         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
8451         * src/SDCCast.c (decorateType): fixed bug #832664
8452
8453 2003-10-31  Borut Razem <borut.razem AT siol.net>
8454
8455         * support\cpp2\cpplex.c: fixed for SDCPP:
8456           comments(when executed with -C option) and _asm blocks
8457           were included even if they where in skipped #if block.
8458           Applied solution from GCC cpp 3.3.2
8459
8460 2003-10-31  Borut Razem <borut.razem AT siol.net>
8461
8462         * src/SDCC.lex: sdcc now understands both formats:
8463           '# <line_number> <file_name>' and
8464           '#line <line_number> <file_name>'
8465         * support/cpp2/cppmain.c: sdcpp now generates the standard
8466           '# <line_number> <file_name>' instead of former
8467           '#line <line_number> <file_name>'
8468
8469 2003-10-30  Borut Razem <borut.razem AT siol.net>
8470
8471         * support/cpp2/cpphash.h,
8472         * support/cpp2/cpplib.h
8473         * support/cpp2/cpplex.c,
8474         * support/cpp2/cppmain.c,
8475         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
8476
8477 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8478
8479         Fixed a number of problems revealed by bug #827883.
8480         * src/SDCCloop.c (loopInvariants): Spill location of the
8481         result operand should be recomputed if extracted from
8482         a loop. Also, don't extract assignments of an iTemp
8483         from a literal.
8484         * src/SDCCast.c (isConformingBody): loop reversal should
8485         not occur if the control variable is involved with a
8486         relational operator.
8487
8488 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
8489
8490         * .version: bumped to 2.3.6 to reflect the big improvements
8491         made by Erik and Klaus. Thanks!
8492
8493 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
8494
8495         Replaced the livrange code.
8496         * src/SDCClrange.c: added new LR code
8497         * src/SDCCloop.c,
8498         * src/SDCCBBlock.h: removed remainig parts from old LR code
8499         * src/ds390/ralloc.c,
8500         * src/ds390/gen.c: minor fixes to make it work with new code
8501
8502 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8503
8504         * as/hc08/asm.h,
8505         * as/hc08/lkrloc.c,
8506         * src/hc08/gen.c,
8507         * src/hc08/ralloc.c: Fix various warnings related to the hc08
8508         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
8509         (tweaked fix for bug #818696)
8510
8511 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8512
8513         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
8514
8515 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8516
8517         * src/SDCCmain.c,
8518         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
8519         * src/mcs51/gen.c (gencjneshort),
8520         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
8521         more efficient (per Scott Bronson's suggestion)
8522
8523 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8524
8525         Extended the semantics of the critical keyword to include
8526         individual statements. See RFE #827755 and #799831
8527         * src/SDCC.y
8528         * src/SDCCicode.c
8529         * src/SDCCopt.c
8530         * src/SDCCast.c
8531         * support/Util/SDCCerr.c
8532         * support/Util/SDCCerr.h
8533         * src/mcs51/gen.c
8534         * src/ds390/gen.c
8535         * src/hc08/gen.c
8536
8537 2003-10-19  Borut Razem <borut.razem AT siol.net>
8538
8539         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
8540
8541 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8542
8543         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
8544         Fixed bug #818696
8545         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
8546         and predecrement operand is displayed
8547
8548 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8549
8550         * src/SDCCval.c (valMinus): fixed bug #826041
8551
8552 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8553
8554         Some hc08 related updates that I missed earlier
8555         * sim/ucsim/stypes.h
8556         * support/regression/ports/hc08/spec.mk
8557
8558 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8559
8560         New target "hc08" for the Motorola 68hc08 family of micros
8561
8562         * configure
8563         * configure.in
8564         * Makefile
8565         * src/hc08/*
8566         * src/SDCCmain.c
8567         * src/port.h
8568         * sim/ucsim/hc08.src/*
8569         * sim/ucsim/configure.in
8570         * src/ucsim/configure
8571         * sim/ucsim/packages_in.mk
8572         * as/hc08/*
8573         * as/Makefile
8574         * device/include/mc68hc908qy.h
8575         * device/lib/hc08/*
8576         * device/lib/Makefile.in
8577         * support/regression/ports/hc08/*
8578         * support/regression/Makefile
8579
8580 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8581
8582         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
8583         regression test
8584         * src/ds390/gen.c (genCast): fixed bug #821957
8585
8586 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
8587
8588         * device/lib/logf.c: "fixed" overlay bug
8589         * support/regression/ports/host/spec.mk: added m library
8590         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
8591         * support/regression/tests/float_trans: added (for Eric)
8592
8593 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
8594
8595         * src/mcs51/gen.c (genCpl): fixed bug
8596         http://sf.net/mailarchive/message.php?msg_id=6263915
8597
8598 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
8599
8600         * src/SDCCast.c (decorateType): added extended constant folding
8601         * src/SDCCsymt.c (computeType): cleanup
8602         * src/SDCCval.c (valShift): minor optimization
8603         * support/regression/tests/ast_constant_folding.c: added
8604
8605 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8606
8607         * src/SDCCmain.c: removed some unintended changes
8608
8609 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8610
8611         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
8612         * src/z80/gen.c: fixed part of bug #817589
8613         * src/SDCCsymt.c (checkFunction): fixed bug #817895
8614
8615 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
8616
8617         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
8618         * src/SDCCcflow.c
8619         * src/SDCCcse.c
8620         * src/SDCCdflow.c
8621         * src/SDCClabel.c
8622         * src/SDCClrange.c
8623         * src/SDCCmem.c
8624         * src/SDCCopt.c
8625         * src/SDCCpeeph.c
8626         * src/SDCCset.c
8627         * src/avr/ralloc.c
8628         * src/ds390/ralloc.c
8629         * src/izt/ralloc.c
8630         * src/mcs51/ralloc.c
8631         * src/pic/ralloc.c
8632         * src/pic16/ralloc.c
8633         * src/xa51/ralloc.c
8634         * src/z80/ralloc.c
8635         * src/z80/gen.c: removed unused label "release:"
8636
8637 2003-10-06  Borut Razem <borut.razem AT siol.net>
8638
8639         * src/SDCC.lex: removed definition of unused variables
8640           save_optimize and save_options
8641
8642 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
8643
8644         * clean.mk: removed '=' in "-maxdepth=1"
8645         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
8646         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
8647
8648 2003-10-06  Borut Razem <borut.razem AT siol.net>
8649
8650         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
8651           my_unput() replaced by unput()
8652
8653 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
8654
8655         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
8656         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
8657         type-punned pointer will break strict-aliasing rules"
8658         Old LR behaviour is again default; Klaus' LR can be choosen by
8659         defining the environment variable LRKLAUS
8660         * src/SDCCBBlock.h
8661         * src/SDCCloop.c
8662         * src/SDCClrange.c
8663         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
8664         * clean.mk: fixed removal of files in bin/CVS/
8665         * device/lib/clean.mk: fixed removal of directories small and large
8666         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
8667         * src/SDCCicode.c,
8668         * src/SDCCval.c: removed superflous test for pedantic
8669
8670 2003-10-05  Borut Razem <borut.razem AT siol.net>
8671
8672         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
8673           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
8674           message "unmatched #pragma SAVE and #pragma RESTORE"
8675
8676 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8677
8678         * doc/sdccman.lyx: various additions and updates (interrupts, inline
8679           assembly, critical functions, atomic, nojtbound)
8680
8681 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
8682
8683         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
8684         * src/SDCCBBlock.h
8685         * src/SDCCloop.c
8686         * src/SDCCloop.h
8687         * src/SDCClrange.c
8688
8689 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8690
8691         * src/z80/gen.h,
8692         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8693         * src/mcs51/gen.h
8694         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8695         * src/ds390/gen.h
8696         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
8697         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
8698         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
8699
8700 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8701
8702         * src/z80/gen.c (genRet): fixed bug #524753
8703         * src/z80/gen.c (genCast): fixed internal error on cast from
8704         pointer to long
8705         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
8706         fix for bug #477835 to the z80
8707         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
8708         for tracking iCodes in the peephole optimizer for z80
8709
8710 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8711
8712         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
8713         the other part of bug #814548
8714         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
8715
8716 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
8717
8718         * src/SDCCcse.c: fixed part of bug #814548
8719
8720 2003-09-28  Borut Razem <borut.razem AT siol.net>
8721
8722         * src/asm.c: rewrite of printILine() to use temporary file instead
8723           a pipe
8724         * src/xa51/main.c: commented out declaration of int rewinds
8725
8726 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8727
8728         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
8729
8730 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8731
8732         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
8733         * src/asm.c (printILine): Fixed bug #811015
8734
8735 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8736
8737         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
8738         freeing.
8739
8740 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8741
8742         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
8743         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
8744         to correctly handle general case of AOP_PAIRPTR
8745         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
8746
8747 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8748
8749         * src/mcs51/ralloc.c (fillGaps),
8750         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
8751         register positioning bug)
8752
8753 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
8754
8755         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
8756
8757 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8758
8759         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
8760         genCodePointerGet, genGenPointerGet, genFarPointerSet,
8761         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
8762         (ralloc doesn't intentionally do this now, but perhaps later)
8763         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
8764         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
8765         register positioning bugs (Fixed bug #762602 and #795325)
8766         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
8767         (Fixed bug #808779)
8768         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
8769         lines that --i-code-in-asm generates
8770
8771 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8772
8773         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
8774         trying to fclose a FILE* that was already closed.
8775
8776 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8777
8778         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
8779         of const struct should be treated as if const themselves)
8780
8781 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
8782
8783         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
8784
8785 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8786
8787         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
8788         Unix (/n) and DOS (/r/n) line terminations.
8789
8790 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8791
8792         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
8793         bug #613775
8794
8795 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8796
8797         * src/mcs51/gen.c (genFunction, genEndFunction),
8798         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
8799         and restore of EA so that stack offsets to parameters are
8800         correct when using both critical and reentrant/stack-auto.
8801         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
8802         size (can be triggered in error if sloc is shared between
8803         different sized objects)
8804         * device/include/float.h: fixed macros to explicitly use
8805         unsigned long where needed
8806
8807 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
8808
8809         Feature req. 799831: added code to allow nesting of critical functions
8810         * src/mcs51/gen.c (genFunction, genEndFunction)
8811         * src/ds390/gen.c (genFunction, genEndFunction)
8812
8813 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8814
8815         * src/SDCCsymt.c (sclsFromPtr),
8816         * src/SDCCsymt.h,
8817         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
8818         support for standard C idiom of memory mapped variables; for
8819         example, *((xdata int*)0x1234) = 1 is now internally equivalent
8820         to xdata int at 0x1234 tempvar = 1.
8821         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
8822         provided by Akiya ISHIDA
8823
8824 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
8825
8826         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
8827         * src/SDCCval.c (constVal): added reduction from int to char
8828         * src/SDCCval.c (valMult, valDiv): fixed sign handling
8829         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
8830         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
8831         to ignore the sign
8832         * support/regression/tests/shifts.c: fixed
8833
8834 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8835
8836         * src/z80/gen.c (genXor): Fixed bug #805445
8837
8838 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8839
8840         Fixed bug #621531 (const & volatile confusion in the type chain).
8841         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
8842         refer to the const or volatile state of the pointer itself.
8843
8844         * src/SDCCast.c
8845         * src/SDCCglue.c
8846         * src/SDCCicode.c
8847         * src/SDCCsymt.c
8848         * src/SDCCval.c
8849         * src/SDCC.y
8850         * src/SDCCsymt.h
8851         * src/pic/gen.c
8852         * src/pic/ralloc.c
8853         * src/pic16/gen.c
8854         * src/pic16/ralloc.c
8855         * support/regression/tests/const.c
8856
8857 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8858
8859         When checking for duplicated modules, use absolute paths
8860         instead of relative paths.  Files changed:
8861
8862         * as/mcs51/lklib.c
8863         * link/z80/lklib.c
8864
8865 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8866
8867         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
8868
8869 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8870
8871         * device/include/string.h: added size_t typedef, changed
8872         prototypes to use size_t, eliminated separate reentrant and
8873         non-reentrant declarations, added _memmove declaration
8874         * device/lib/_memcpy.c: changed to use size_t instead of int,
8875         changed /4 to >>2 to avoid division library call
8876         * device/lib/_memcmp.c,
8877         * device/lib/_memset.c,
8878         * device/lib/_strncat.c,
8879         * device/lib/_strncpy.c,
8880         * device/lib/_strncmp.c: changed to use size_t instead of int
8881         * device/lib/_memmove.c: new file (fixed bug #772294)
8882         * device/lib/Makefile.in: added _memmove.c
8883         * device/lib/z80/asm_strings.s: fixed bug #772290
8884         * support/regression/tests/bitfields.c: attempt to fix host assertion
8885         failure on amd64-unknown-linux2.2
8886
8887 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8888
8889         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
8890         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
8891         * as/z80/asmain.c (main): fixed bug #801766
8892
8893 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
8894
8895         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
8896         compilers
8897
8898 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8899
8900         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
8901         reported in bug #800609
8902
8903 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
8904
8905         * Top header beautifications in src/pic16 directory:
8906           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
8907           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
8908           pcoderegs.h, ralloc.c, ralloc.h
8909         * main.c: added top header and GPL license notice
8910         * pcode.c: fixed the if-conditional warning
8911
8912 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
8913
8914         * device/lib/_mullong.c: replaced int by short for gcc
8915
8916 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8917
8918         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
8919         and JUMPTABLE iCodes properly now (worked by accident before)
8920         * src/mcs51/gen.c (leftRightUseAcc),
8921         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
8922         iCode properly now. Use getSize instead of nRegs since a & b
8923         aren't part of the nRegs tally.
8924
8925 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
8926
8927         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
8928         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
8929           before instructions that use the _STATUS register
8930
8931 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
8932
8933         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
8934         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
8935         fetching of the pointer
8936         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
8937         copied from genNearPointerSet()
8938         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
8939         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
8940         If they pop r0/r1 they must be called in the opposite order than aopOp().
8941         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
8942         (resp. --stack-auto), prepared for --xstack
8943
8944 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8945
8946         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
8947
8948 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
8949
8950         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
8951         these ports have their own __sdcc_external_start()
8952
8953 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
8954
8955         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
8956         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
8957         type for bits was changed. It resulted in bit variables becoming
8958         global, which is not permitted in PIC 14 assembly output.
8959
8960 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8961
8962         * doc/sdccman.lyx: various additions and updates. Rearranged sections
8963
8964 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8965
8966         Z80 and MCS51 linkers complaint if a public symbol is defined
8967         in more than one library module:
8968
8969         * as/mcs51/lklib.c
8970         * link/z80/lklib.c
8971         * as/mcs51/Makefile.in
8972
8973 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8974
8975         A few small changes that speed up the peephole optimizer.
8976
8977         * src/SDCCpeeph.c
8978
8979 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8980
8981         Try to make the peephole optimizer smarter by maintaining
8982         an association between the assembly source code and the
8983         iCodes that originated them. Put this information to use
8984         with a new peephole rule condition "notVolatile" so that
8985         the rules can be aggressive yet still safe.
8986
8987         * src/SDCCpeeph.c
8988         * src/SDCCpeeph.h
8989         * src/mcs51/gen.c
8990         * src/mcs51/peeph.def
8991
8992 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8993
8994         Fixed bug #741761
8995
8996         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
8997         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
8998         if the left or right operand symbols have the accuse flag set.
8999
9000 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9001
9002         Changed the type of the result of the ! (NOT) operator to char;
9003         previously it returned the same type as the source. This allows
9004         us to eliminate all the genFloatNot functions (all of its target
9005         implementations were very buggy) since !float can use the same
9006         code as !long now.
9007
9008         * src/SDCCicode.c (ast2iCode): ! returns char
9009         * src/mcs51/gen.c (genNot, genNotFloat),
9010         * src/ds390/gen.c (genNot, genNotFloat),
9011         * src/z80/gen.c (genNot, genNotFloat),
9012         * src/pic/gen.c (genNot, genNotFloat),
9013         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
9014
9015 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
9016
9017         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
9018         1. Interrupt would not compile properly. Ensure PCLATH register is saved
9019            during interrupts. Ensure WSAVE is located at a shared bank address.
9020         2. Fixed page selection in some places
9021         3. Fixed BTFSS/C to where necessary use registers directly and not simply
9022            the registers name strings.
9023         4. Fixed "signed / unsigned compare" compiler warnings.
9024         5. The PIC port manages its own allocation of the general purpose
9025            registers, but makes no attempt to reuse them. As a result when
9026            compiling it soon runs out of general purpose registers. Some
9027            additional code was added to the files pcode.c and device.c to walk
9028            through the function call tree and rename the registers so that they
9029            get reused.
9030
9031         * src/pic/device.c
9032         * src/pic/gen.c
9033         * src/pic/glue.c
9034         * src/pic/pcode.c
9035         * src/pic/pcode.h
9036         * src/pic/ralloc.c
9037         * src/pic/ralloc.h
9038         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
9039         genPlus() & genMinus() when the result is the same as left or right
9040
9041 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9042
9043         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
9044
9045 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9046
9047         Made bitfield a distinct type from bit so that bitfields
9048         convert as per ANSI C and bits retain their traditional
9049         boolean style behaviour. Implemented bitfield support in
9050         the z80 port.
9051
9052         * src/SDCCsymt.h,
9053         * src/SDCCsymt.c,
9054         * src/SDCCast.c,
9055         * src/cdbFile.c,
9056         * src/mcs51/gen.c,
9057         * src/ds390/gen.c: bit v bitfield split
9058         * src/z80/gen.c: New support for bitfields
9059         * support/regression/tests/bitfields.c: reenabled z80,
9060         added more tests
9061
9062 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9063
9064         Rules 246.x, 247.x relate to bitfields, the others speed up
9065         access to xdata mapped I/O devices.
9066
9067         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
9068
9069 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9070
9071         Cleaned up genPackBits and genUnpackBits and added two helper
9072         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
9073         for literal assignments in genPackBits (thanks to Frieder for
9074         reminding me).
9075
9076         * src/mcs51/gen.c
9077         * src/ds390/gen.c
9078
9079 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9080
9081         Fixed bug #748310 (pointer to function type mishandled when the
9082         function name is omitted). Also fixed a SIGSEGV when a function
9083         attribute (reentrant, etc) is used on a non-function or on a
9084         function but misplaced before the parameter list.
9085
9086         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
9087         bug #748310
9088         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
9089         * support/Util/SDCCerr.h,
9090         * support/Util/SDCCerr.c: Added func attr misuse error msg
9091
9092 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9093
9094         Fixed bug #787649 by anonymous
9095         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
9096         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
9097
9098 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9099
9100         Fixed numerous bitfield problems.
9101
9102         * src/SDCC.y: More bitfield related error checking
9103         * src/SDCCsymt.h,
9104         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
9105         * support/Util/SDCCerr.h,
9106         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
9107         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9108         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
9109         * support/regression/tests/bitfields.c: tests added
9110
9111 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9112
9113         Made the constant following the "interrupt" keyword optional. If
9114         omitted, the function will not automatically be given an entry
9115         in the interrupt vector table (similar to #pragma NOIV, but
9116         less syntacticly kludgy). The interrupt number is also now
9117         range checked. Also fixed a bug in the high order bit example
9118         in the manual.
9119
9120         * src/SDCC.y
9121         * src/SDCCmem.c
9122         * src/SDCCglue.c
9123         * src/SDCCsymt.h
9124         * support/Util/SDCCerr.c
9125         * support/Util/SDCCerr.h
9126         * doc/sdccman.lyx
9127
9128 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
9129
9130         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
9131         * src/SDCCicode.c (operandOperation): rewritten some ops
9132         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
9133         * src/SDCCsymt.c (computeType): literals are handled the same way as any
9134         other type
9135         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
9136         be re-activated by defining REDUCE_LITERALS)
9137         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
9138         unsigned, but are signed by default
9139         * src/SDCCval.c (constVal): rearranged
9140         * src/SDCCval.c (valMod): preliminary fix
9141         * src/SDCCval.c (valCastLiteral): use TYPE_* types
9142         * support/regression/literalop.c: added, work in progress
9143
9144 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9145
9146         Generate warnings for useless declarations like "char data;"
9147         that don't do what new users expect.
9148
9149         * src/SDCC.y
9150         * support/Util/SDCCerr.h
9151         * support/Util/SDCCerr.c
9152
9153 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
9154
9155         * src/SDCCval.c (valMult): fix overflow detection of negative int
9156
9157 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9158
9159         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
9160
9161         Changes to support big endian targets:
9162
9163         * src/ports.h
9164         * src/SDCCglue.c
9165         * src/avr/main.c
9166         * src/ds390/main.c
9167         * src/izt/i186.c
9168         * src/mcs51/main.c
9169         * src/pic/main.c
9170         * src/pic16/main.c
9171         * src/xa51/main.c
9172         * src/z80/main.c
9173
9174 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
9175
9176         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
9177         * device/lib/time.c: fixed warning "integer overflow in expression"
9178
9179 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
9180
9181         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
9182         * src/SDCCval.c (constVal): changed default to signed; hex and octal
9183         constants are unsigned; added recognition of "u" flag for unsigned
9184         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
9185         * src/SDCCval.c (valDiv, valMod): fixed signdness
9186         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
9187         signedness of modulo, left and right shift
9188         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
9189         * support/Util/SDCCerr.h: added warning W_INT_OVL
9190         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
9191         * src/SDCCast.c (ast_print): improved output of constants
9192
9193 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9194
9195         Fixed some warnings when building with MSVC:
9196
9197         * as\mcs51\asdata.c
9198         * as\z80\asdata.c
9199         * as\mcs51\asm.h
9200         * as\z80\asm.h
9201         * link\z80\aslink.h
9202         * link\z80\lkdata.c
9203         * link\z80\lkeval.c
9204         * link\z80\lkgb.c
9205         * link\z80\lkihx.c
9206         * link\z80\lks19.c
9207         * link\z80\lksym.c
9208         * support\cpp2\cpplib.c
9209         * src\ds390\gen.c
9210         * src\mcs51\gen.c
9211
9212 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
9213
9214         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
9215
9216 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9217
9218         * support\librarian\clean.mk: Do not remove Makefile.
9219         * support\librarian\Makefile: added.
9220
9221 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9222
9223         Added librarian to MSVC build:
9224         * all.dsp
9225         * sdcc.dsw
9226         * support\librarian\librarian.dsp
9227
9228         'configure' not needed for librarian, removed:
9229         * support\librarian\configure
9230         * support\librarian\configure.in
9231         * support\librarian\config_in.h
9232         * support\librarian\Makefile.in
9233
9234         Hopefully these ones built the librarian and the rest of sdcc properly:
9235         * Makefile
9236         * Makefile.common.in
9237
9238         Messed up 'configure', so revert to previous version:
9239         * configure
9240         * configure.in
9241
9242 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
9243
9244         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
9245         there, while the mantissa of a double is "only" 53 bits wide.
9246
9247 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9248
9249         Adding sdcclib to the build.  MSVC project coming soon.
9250         Files added/changed:
9251
9252         * support\librarian\clean.mk
9253         * support\librarian\configure
9254         * support\librarian\configure.in
9255         * support\librarian\config_in.h
9256         * support\librarian\Makefile.bcc
9257         * support\librarian\Makefile.in
9258         * support\librarian\sdcclib.c
9259         * Makefile.bcc
9260         * Makefile
9261         * Makefile.common.in
9262         * configure
9263         * configure.in
9264
9265 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9266
9267         Linker now complaints if linked modules have conflicting options, for
9268         example, one compiled using --model-large and another one compiled with
9269         --model-small.  The following files were modified:
9270
9271         * as\mcs51\asdata.c
9272         * as\mcs51\aslink.h
9273         * as\mcs51\asm.h
9274         * as\mcs51\asmain.c
9275         * as\mcs51\asout.c
9276         * as\mcs51\i51pst.c
9277         * as\mcs51\lkdata.c
9278         * as\mcs51\lklibr.c
9279         * as\mcs51\lkmain.c
9280         * as\z80\asdata.c
9281         * as\z80\asm.h
9282         * as\z80\asmain.c
9283         * as\z80\asout.c
9284         * as\z80\z80pst.c
9285         * link\z80\aslink.h
9286         * link\z80\lkdata.c
9287         * link\z80\lklibr.c
9288         * link\z80\lkmain.c
9289         * src\SDCCglue.c
9290
9291 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9292
9293         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
9294         as/mcs51/lklibr.c: Generate a warning when a library is not found.
9295
9296 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
9297
9298         * src/z80/mappings.i: fix _mul[us][int,long] entries
9299
9300 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9301
9302         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
9303
9304 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9305
9306         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
9307         * support/regression/tests/bitopcse.c: added
9308         fixed warning:
9309         * src/avr/gen.c:
9310         * src/pic/gen.c:
9311         * src/pic16/gen.c:
9312         * src/z80/gen.c:
9313         * src/xa51/gen.c:
9314
9315 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9316
9317         added support for new library format to z80, gbz80 linkers:
9318         *link/z80/aslink.h
9319         *link/z80/lklex.c
9320         *link/z80/lklib.c
9321         *link/z80/lklist.c
9322
9323 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
9324
9325         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
9326         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
9327
9328 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
9329
9330         added DUMMY_READ_VOLATILE:
9331         * src/SDCC.y:
9332         * src/avr/gen.c:
9333         * src/xa51/gen.c:
9334         * src/z80/gen.c:
9335         * src/pic/gen.c:
9336         * src/pic16/gen.c:
9337         * src/mcs51/gen.c:
9338         * src/ds390/gen.c:
9339         * src/SDCCcse.c (algebraicOpts): many improvements
9340         * src/SDCCcse.h: removed algebraicOpts()
9341         * src/SDCCicode.c (picDummyRead): added
9342
9343 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9344
9345         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
9346         "Insufficient space in data memory".
9347
9348 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9349
9350         * src/mcs51/gen.c: fixed bug #771358
9351         * src/z80/gen.c: fixed bug #759087
9352
9353 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
9354
9355         * src/pic16/glue.c: minor cleanup by Vangelis
9356
9357 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9358
9359         * device/include/regc515c.h: fixed #758477
9360         * device/lib/_gptrget.c: saving some cycles in generic pointer get
9361         * device/lib/_gptrput.c: saved a few bytes
9362         * my tab spacing is 8, yours too?)
9363         * device/lib/_ser.c: process RX bytes earlier than TX bytes
9364         * device/lib/serial.c: process RX bytes earlier than TX bytes
9365         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
9366
9367 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9368
9369         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
9370
9371 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9372
9373     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
9374
9375 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
9376
9377         * device/lib/Makefile.in: bad fix, reverted to 1.43
9378
9379 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
9380
9381         * device/lib/Makefile.in: added missing z80 object files
9382
9383 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
9384
9385         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
9386         pic16 progress by Vangelis:
9387         * src/SDCCglobl.h:
9388         * src/SDCCmain.c:
9389         * src/pic/Makefile:
9390         * src/pic:
9391         * pic/Makefile:
9392         * pic16/device.c:
9393         * pic16/device.h:
9394         * pic16/gen.c:
9395         * pic16/gen.h:
9396         * pic16/genarith.c:
9397         * pic16/glue.c:
9398         * pic16/main.c:
9399         * pic16/pcode.c:
9400         * pic16/pcode.h:
9401         * pic16/pcodepeep.c:
9402         * pic16/peeph.def:
9403
9404 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9405
9406     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
9407
9408 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9409
9410     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
9411     added gbz80 build to MSVC project.
9412     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
9413     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
9414     from 8051 stuff and setup so it links using a .lnk file.
9415
9416 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9417
9418     * support/librarian/sdcclib.c: sdcc librarian.
9419     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
9420     with sdcclib.
9421
9422 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9423
9424     * as/mcs51/lkmain.c: properly handle extensions in function afile.
9425
9426 2003-07-02  Borut Razem <borut.razem AT siol.net>
9427
9428         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
9429         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
9430         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
9431         src/xa51/main.c, src/z80/main.c:
9432         virtualization of glue() function: each port has it's own glue function,
9433         which is accessed by do_glue function pointer in PORT.general structure
9434
9435 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
9436
9437         * DS800C400 fun, improved ROM interface and tinibios.
9438
9439 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
9440
9441         * More support for DS80C400. Now includes beginning of interface to ROM.
9442
9443 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
9444
9445         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
9446
9447 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9448
9449         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
9450
9451 2003-06-19  Borut Razem <borut.razem AT siol.net>
9452
9453         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
9454
9455 2003-06-19  Borut Razem <borut.razem AT siol.net>
9456
9457         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
9458         fixed Z80 port - crt0.o: cannot open.
9459
9460 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
9461
9462         * support/Util/MySystem.c (merge_command): revert bad fix
9463
9464 2003-06-18  Borut Razem <borut.razem AT siol.net>
9465
9466         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
9467
9468 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9469
9470         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9471         option --use-stdout sends errors to stdout instead of stderr.
9472
9473 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
9474
9475         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
9476
9477 2003-06-15  Borut Razem <borut.razem AT siol.net>
9478
9479         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
9480         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
9481         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
9482         fixed width array of pointers replaced with sets;
9483         multiple include and lib paths ared transferred to preprocessor and linker
9484         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
9485         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
9486         fixed width array of pointers
9487         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
9488         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
9489         fixupPath(), getPathDifference()
9490         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
9491         fixed width array of pointers
9492
9493 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
9494
9495         * src/pic16/ralloc.c: fix warnings
9496         * src/pic16/pcode.c: fix warning
9497
9498 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
9499
9500          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
9501         know all the details, but essentially this set of changes enable
9502         the pic16 port to generate movff instructions and generate assembler
9503         directives,
9504         * src/SDCCmain.c:
9505         * src/pic16/gen.c:
9506         * src/pic16/glue.c:
9507         * src/pic16/pcode.c:
9508         * src/pic16/device.c:
9509         * src/pic16/main.c:
9510         * src/pic16/pcode.h:
9511         * src/pic16/pcoderegs.c:
9512         * src/pic16/ralloc.c:
9513         * src/pic16/ralloc.h:
9514
9515 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9516
9517         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
9518         added option --vc, so sdcc errors and warnings are compatible with
9519         Microsoft Visual Studio.
9520
9521 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9522
9523         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
9524           device/lib/libfloat.lib: added atof function.
9525
9526 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
9527
9528         * doc/sdccman.lyx: updated to Lyx 1.3
9529         * doc/cdbfileformat.lyx: updated to Lyx 1.3
9530         * doc/test_suite_spec.lyx: updated to Lyx 1.3
9531         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
9532
9533 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
9534
9535         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
9536
9537 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9538
9539         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
9540           additions to the "related tools/documentation" section
9541
9542 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
9543
9544         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
9545
9546 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
9547
9548         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
9549         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
9550
9551 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
9552
9553         * doc/sdccman.lyx: fix double dash and other minor things
9554         * doc/Makefile: fix double dash
9555
9556 2003-05-28  Karl Bongers(patches from Martin Helmling)
9557         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
9558           condition and ignore commands.
9559
9560 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9561
9562         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
9563           is in parts still quite out of date, I did changes as far as I felt makes sense
9564           for a non-native english speaker.
9565           Please feel free to add to the manual or to correct my changes.
9566         * doc/Makefile: undid touching the date of intermediate tex files.
9567
9568 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9569
9570         * doc/sdccman.lyx: Manual has an index now
9571
9572 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
9573
9574         Finalize muluint/mulsint and mululong/mulslong merging:
9575         * device/lib/_mulint.c
9576         * device/lib/_mullong.c
9577         * device/lib/gbz80/mul.s
9578         * device/lib/gbz80/stubs.s
9579         * device/lib/z80/mul.s
9580         * device/lib/z80/stubs.s
9581         * src/SDCCsymt.c (initCSupport)
9582
9583 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9584
9585         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
9586         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
9587           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
9588           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
9589           instead of /Zm500.
9590
9591 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9592
9593         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
9594           the regression tests I'm not brave enough to enable 245.b, 245.c
9595         * doc/sdccman.lyx: added latex preamble for hyperref package.
9596           Using pdflatex this will give you a hyperlinked pdf file with
9597           bookmarks. (prepend '%' before /usepackage if this breaks something)
9598
9599 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9600
9601          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
9602
9603 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
9604
9605         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
9606
9607 2003-05-21    <johan AT balder>
9608
9609         * src/SDCCglue.c (printIval): fixed bug #739934
9610
9611 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9612
9613         Applied patch from bug 737905 (renamed yylineo to mylineno):
9614         * src/altlex.c
9615         * src/SDCCast.c
9616         * src/SDCglobl.h
9617         * src/SDCC.lex
9618         * src/SDCCsymt.c
9619         * src/SDCCval.c
9620         * src/pic16/pcode.c: Cleaned warnings
9621         * src/pic16/pcodeflow.c: Cleaned warnings
9622         * src/pic16/pcoderegs.c: Cleaned warnings
9623
9624 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
9625
9626         * src/pic16/pcode.c: Cleaned warnings
9627         * src/pic16/pcodepeep.c: Cleaned warnings
9628         * src/pic16/ralloc.c: Cleaned warnings
9629
9630 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
9631
9632         * doc/sdccman.lyx: fixed bug 739745
9633         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
9634
9635 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
9636
9637         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
9638         it can be defined with CFLAGS when running configure
9639         * src/SDCCmain.c: fixed compiling + linking with object files
9640
9641 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
9642
9643         * configure.in: configure for pic16 port,
9644             added --disable-pic16-port
9645         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
9646         * src/SDCCmain.c: linkOptions is changed to set *,
9647             added if/endif conditional macros to remove options help
9648             messages from optionsTable when a port is not configured, added
9649             support for the PIc16 port in the ports table, when executing
9650             the compiler with no port specified on command line, a default
9651             port is selected with the new macro DEFAULT_PORT which is
9652             defined in port.h, in setDefaultOptions() linkOptions is removed
9653             from initialization assignment, since now it is a set,
9654             parseCmdLine uses setParseWithComma for linkOptions, in
9655             linkEdit() linkOptions are accessed with new function indexSet()
9656             which returns the i'th item of a set variable. See SDCCset.c, in
9657             linkEdit() when calling buildCmdLine(), added linkOptions as
9658             last argument. Now users can pass arguments to gplink via the
9659             -Wl option, main() uses pic16glue() to glue up pic16 programs
9660         * src/SDCCpeeph.c: various changes to support pic16
9661         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
9662             return the i'th item of the set
9663         * src/SDCCset.h: added function prototype for indexSet()
9664         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
9665         * src/clean.mk: added pic16 in CLEANALLPORTS variable
9666         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
9667             added macro DEFAULT_PORT
9668         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
9669         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
9670             generated
9671         * src/pic16/glue.c: commented out some error producing lines
9672         * src/pic16/main.c: __config directives are commented out to stop
9673             gpasm complaining and test the linkage with gplink, _linkCmd and
9674             _asmCmd changed to be more gplink and gpasm friendly
9675         * src/pic16/peeph.def: peep rule 3 is commented out, since it
9676             produced an error when parsed, peep rule 12 is added to utilize
9677             movff, but it is commented out since the pCode does not support
9678             yet a command with 2 address arguments
9679
9680 2003-05-18    <johan AT balder>
9681
9682         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9683         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
9684 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
9685
9686         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
9687   Added feature to script commands from file.
9688
9689 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
9690
9691         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
9692         * src/SDCCutil.c: include ctype.h for win32
9693
9694 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
9695
9696         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
9697
9698 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
9699
9700         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
9701   Fixed so you can set breakpoints prior to run, run does not stop
9702   on entry now.  Add tbreak.  Other enhancements and fixes for use
9703   with ddd.
9704
9705 2003-05-12  Borut Razem <borut.razem AT siol.net>
9706
9707         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
9708
9709 2003-05-11  Borut Razem <borut.razem AT siol.net>
9710
9711         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
9712         the path of bin directory, so that PATH is the only env. variable, which has to be set
9713         in case of standard installation.
9714         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
9715         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
9716         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
9717
9718 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9719
9720         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
9721         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
9722         temp files are in the port dir; clean the gen/test directory when
9723         generating new test.c
9724         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
9725         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
9726         * support/regression/tests/zeropad.c: added
9727
9728 2003-05-09    <johan AT balder>
9729
9730         * src/SDCCglue.c: fixed bug #597940
9731
9732 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
9733
9734         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9735   cache sfr, optimize next,step, fix off by one sourceline,
9736   support ddd list function.
9737         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
9738
9739 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
9740
9741         * support/regression/HTMLgen.py: added compare_s2f()
9742         * support/regression/Makefile: redo 1.27
9743         * support/regression/generate-cases.py: redo 1.5
9744
9745 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
9746
9747         * support/regression/tests/float.c: workaround 33 bit hex constant
9748         * support/regression/tests/simplefloat.c: fix division for host
9749
9750 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
9751
9752         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
9753         that tame's the PIC's over-aggressive optimizer.
9754
9755 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9756
9757          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
9758          support for MSVC.
9759
9760 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
9761
9762         Initial support for DS80C400. "Hello world" runs on TINIm400
9763         (with polled I/O).
9764
9765 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
9766
9767          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
9768          * Some notes on ddd usage added in debugger/README
9769          Martin Helmling adding more features and fixes for ddd GUI debugger.
9770          Code added for nexti, stepi, up, down, and other adjustments.
9771
9772 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
9773
9774         * src/pic/pCodepeep.c non-wildcard asmops are now handled
9775         * src/pic/peeph.def Added two rules to optimize carry manipulation
9776         * src/pic/* removed debug printfs
9777
9778 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
9779
9780         * debugger/mcs51/cmd.c: added header newalloc.h
9781
9782 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
9783
9784         * as/Makefile: new EXEEXT
9785         * as/z80/Makefile: remove trailing slash of BUILDIR
9786         * as/z80/clean.mk: new EXEEXT
9787         * Makefile.common.in: add to CFLAGS (and others), don't replace it
9788         * support/cpp2/Makefile.in: new EXEEXT
9789         * src/pic/glue.c (pic14emitRegularMap): fixed warning
9790
9791 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
9792
9793         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
9794         EXEEXT was introduced to fix all related problems with targets
9795         "clean", "install" and "uninstall"; a couple of further flaws
9796         especially with "clean" have been fixed too
9797         * as/mcs51/Makefile.in
9798         * as/mcs51/clean.mk
9799         * as/z80/Makefile
9800         * Makefile
9801         * clean.mk
9802         * debugger/mcs51/Makefile.in
9803         * debugger/mcs51/clean.mk
9804         * link/z80/Makefile
9805         * link/z80/Makefile.in
9806         * link/z80/clean.mk
9807         * link/Makefile
9808         * packihx/Makefile.in
9809         * packihx/clean.mk
9810         * sim/ucsim/Makefile
9811         * sim/ucsim/clean.mk
9812         * sim/ucsim/avr.src/Makefile.in
9813         * sim/ucsim/avr.src/clean.mk
9814         * sim/ucsim/s51.src/Makefile.in
9815         * sim/ucsim/s51.src/clean.mk
9816         * sim/ucsim/xa.src/Makefile.in
9817         * sim/ucsim/xa.src/clean.mk
9818         * sim/ucsim/z80.src/Makefile.in
9819         * sim/ucsim/z80.src/clean.mk
9820         * sim/ucsim/main_in.mk
9821         * sim/ucsim/packages_in.mk
9822         * sim/ucsim/gui.src/Makefile.in
9823         * sim/ucsim/gui.src/serio.src/Makefile.in
9824         * sim/ucsim/gui.src/serio.src/clean.mk
9825         * src/Makefile.in
9826         * src/clean.mk
9827         * support/cpp2/Makefile.in
9828         * support/cpp2/clean.mk
9829         * support/makebin/Makefile
9830         * support/makebin/clean.mk
9831         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
9832         * doc/sdccman.lyx: --program-suffix no longer needed
9833
9834 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
9835
9836          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
9837          Martin Helmling added support for ddd GUI debugger.
9838          Code added to display assembly, set variables, and other commands
9839          to interface to ddd.
9840
9841 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
9842
9843         * as/Makefile: fix target clean
9844         * as/clean.mk: fix target clean
9845         * as/z80/clean.mk: fix target clean
9846
9847 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
9848
9849         * Makefile.common.in: added  AT EXEEXT AT
9850         * configure.in: removed all mingw32 stuff
9851         * configure: rebuilt from configure.in
9852         * doc/sdccman.lyx: updated section "installation"
9853         * support/scripts/sdcc_mingw32: adapted to configure
9854         * support/scripts/sdcc_cygwin_mingw32: added
9855
9856 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
9857
9858         * src/pic Added object file support for the PIC port
9859         * src/pic Applied patch from Craig Franklin (this started the object file support)
9860         * src/regression Updated the PIC regression tests for object files
9861
9862 2003-04-20  Borut Razem <borut.razem AT siol.net>
9863
9864         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
9865           lklex.c: In function `getfid':
9866           lklex.c:203: warning: array subscript has type `char'
9867         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
9868           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
9869         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
9870           stack handling macros
9871
9872 2003-04-19  Borut Razem <borut.razem AT siol.net>
9873
9874         * "handling space characters in file path" task:
9875         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
9876         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
9877         * support/Util/MySystem.h: make it self-sufficient
9878         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
9879           src/z80/main.c, sdcc/as/mcs51/lklex.c:
9880           handling space characters in file path
9881         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
9882           (it will be used by assemblers, which have their own includes, e.g. gpasm)
9883         * support/Util/MySystem.c: handling space characters in executable's path
9884
9885 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
9886
9887         * as/z80/Makefile: fix permanent rebuild of z80
9888         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
9889         * support/regression/tests/bitfields.c: added Johan's bitfields.c
9890
9891 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
9892
9893         * src/SDCCopt.c: add special case optimization to replace modulo by
9894           a power of two with a bitwise AND.
9895
9896 2003-04-18    <johan AT balder>
9897
9898         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
9899
9900 2003-04-17    <johan AT balder>
9901
9902         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
9903         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
9904
9905 2003-04-13  Borut Razem <borut.razem AT siol.net>
9906
9907         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
9908         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
9909           fixed mingw problem in adl_NORMALIZE_PATH
9910
9911 2003-04-12  Borut Razem <borut.razem AT siol.net>
9912
9913         * fixed "#pragma SAVE/RESTORE can not be nested":
9914         * src/SDCC.lex: reworked pragma handling functions
9915         * sdcc/src/SDCCglobl.h: reworked stack handling macros
9916         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
9917
9918 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9919
9920         * src/SDCCutil.c (pathEquivalent): defined but not used
9921         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
9922         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
9923         * configure: rebuilt from configure.in
9924         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9925         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
9926         * device/include/Makefile.in: replace sdcc_datadir
9927         * device/lib/Makefile.in: replace sdcc_datadir
9928         * Makefile.common.in: add LDFLAGS from configure
9929         * packihx/Makefile.in: use LDFLAGS
9930         * src/Makefile.in: use LDFLAGS
9931         * support/cpp2/Makefile.in: add LDFLAGS from configure
9932         * support/makebin/Makefile: use LDFLAGS
9933         * .version: bumped version number to 2.3.5
9934
9935 2003-04-12  Borut Razem <borut.razem AT siol.net>
9936
9937         * completed "different paths" task:
9938         * src/SDCCmacro.c: fixed bug in handling quotes
9939         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
9940         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
9941
9942 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
9943
9944         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
9945
9946 2003-04-11 kevin Vigor <kevin AT vigor.nu>
9947
9948         * ds390/gen.c ds390/peeph.def: fix bug 706781
9949
9950 2003-04-11  Borut Razem <borut.razem AT siol.net>
9951
9952         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
9953
9954 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
9955
9956         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
9957         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
9958          set - this bit used to not be set...).
9959         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
9960           bad code in PIC Port
9961         * src/regression/and2.c added to test bug 609268
9962         * src/regression/Makefile added and2.c to regression test
9963
9964
9965 2003-04-08    <johan AT CP255758-A>
9966
9967         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
9968         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
9969         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
9970
9971 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
9972
9973         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
9974         fix bug #487815
9975         * support/cpp2/Makefile.in: fix bug #487815
9976         * configure: rebuilt from configure.in
9977         * Makefile.common.in: docdir changed, new path suffixes
9978         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
9979         * sdcc_vc_in.h: reflect changes from sdccconf.h
9980         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
9981         * src/SDCCutil.h: remove BINDIR hack
9982         * doc/sdccman.lyx: update new path hierarchy
9983
9984 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9985
9986         * src/SDCCpeeph.c: added okToRemoveSLOC test
9987
9988 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9989
9990         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
9991
9992 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
9993
9994         * src/SDCCpeeph.c: added labelIsReturnOnly test
9995         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
9996
9997 2003-04-05    <johan AT balder>
9998
9999         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
10000         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
10001         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
10002         * src/SDCCast.c: fixed a warning
10003         * src/SDCCast.h: fixed a warning
10004         * src/SDCCicode.c (operandFromAst): fixed a warning
10005
10006 2003-04-04    <johan AT balder>
10007
10008         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
10009         * src/SDCCast.c (decorateType): fixed bug #715076
10010         * src/SDCC.y: fixed bug #702907
10011
10012 2003-04-03    <johan AT balder>
10013
10014         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
10015         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
10016         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
10017         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
10018         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
10019
10020 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
10021
10022         * _decdptr.c: fix return values
10023         * _gptrget.c: fix return values
10024         * _gptrgetc.c: fix return values
10025         * _gptrput.c: fix return values
10026         * _mulint.c: fix return values
10027         * as/z80/Makefile: fix 'make -j' problem
10028
10029 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
10030
10031         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
10032         * configure.in: big cleanup, updated to autoconf 2.5x
10033         * configure: rebuilt from configure.in
10034         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
10035         * sdcc_vc_in.h: reflect changes from sdccconf.h
10036         * doc/Makefile: fixed a flaw in "make install"
10037
10038 2003-04-02    <johan AT balder>
10039
10040         * src/ds390/gen.c (genCmp): no comments
10041         * src/mcs51/gen.c (genCmp): no comments
10042         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
10043         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
10044
10045 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
10046
10047         * support/regression/generate-cases.py: place generated file in given sub directory
10048         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
10049         * support/regression/Makefile: improvements for 'make -j';
10050         side effect: it's simpler and faster now
10051
10052 2003-03-31  Borut Razem <borut.razem AT siol.net>
10053
10054         * src/z80/main.c: link-{port} and as-{port} defined without path
10055         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
10056
10057 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
10058
10059         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
10060
10061 2003-03-30  Borut Razem <borut.razem AT siol.net>
10062
10063         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
10064           changed type of list parameter to set
10065         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
10066         * src/port.h: changed type of do_assemble() parameter to set
10067         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
10068           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
10069           definition of "cppoutfilename" macro with NULL value in preProcess()
10070         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
10071         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
10072         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
10073           replaced with set *binPathSet
10074         * shash_add() deallocates the item, if allready exsists, before adding the new one
10075         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
10076
10077 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
10078
10079         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
10080           a nested for loop bug in the PIC port
10081         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
10082           for loops
10083
10084 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
10085
10086         * support/Util/dbuf.h: remove C++ stuff to make it portable
10087
10088 2003-03-28  Borut Razem <borut.razem AT siol.net>
10089
10090         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
10091           literal strings in stringLiteral()
10092         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
10093         * src/Makefile.bcc, src/Makefile.in, src\src.dsp: added support/Util/dbuf.c
10094           to the project
10095
10096 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
10097
10098         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
10099
10100 2003-03-26    <johan AT balder>
10101
10102         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
10103         * src/ds390/gen.c (saveRegisters): catched symbol abuse
10104         * src/SDCCast.c (decorateType): fixed " -v < 3"
10105
10106 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
10107
10108         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
10109         Added Lenny Story's debug infrastructure changes:
10110         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
10111         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
10112         * src/cdbFile.c: added
10113         * src/SDCCdebug.c: added
10114         * src/SDCCdebug.h: added
10115         * src/SDCCast.c (createFunction)
10116         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
10117         * src/SDCCmain.c (parseCmdLine, main)
10118         * src/SDCCmem.c (redoStackOffsets)
10119         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
10120         * src/SDCCsymt.h
10121         * src/common.h
10122         * src/avr/gen.c (genAVRCode)
10123         * src/ds390/gen.c (gen390Code)
10124         * src/mcs51/gen.c (gen51Code)
10125         * src/pic/gen.c (genpic14Code)
10126         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
10127         * src/xa51/gen.c (genXA51Code)
10128         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
10129
10130 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10131
10132         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
10133         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
10134
10135 2003-03-22    <johan AT balder>
10136
10137         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
10138
10139 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
10140
10141         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
10142         * doc/cdbfileformat.lyx: added, written by Lenny Story
10143         * doc/Makefile: added cdbfileformat.lyx
10144         * doc/clean.mk: added cdbfileformat.lyx
10145
10146 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
10147
10148         * src/mcs51/peeph.def: fix bug #705773
10149
10150 2003-03-20    <johan AT balder>
10151
10152         An sfr/sbit can have an "at #" AND an initializer
10153         * src/SDCCsymt.c (checkSClass):
10154         * src/SDCCmem.c (allocGlobal):
10155         * src/SDCCmem.c (allocLocal):
10156         * src/SDCCast.c (createBlock):
10157
10158 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
10159
10160         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
10161
10162 2003-03-16    <johan AT balder>
10163
10164         Undid the hackup of const and volatile, the problem is much bigger
10165         * src/SDCC.y:1.65
10166         * src/SDCCast.c:1.171
10167         * src/SDCCglue.c:1.138
10168         * src/SDCCicode.c:1.146
10169         * src/SDCCsymt.c:1.150
10170         * src/SDCCval.c:1.65
10171
10172 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
10173
10174         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
10175         * src/ds390/gen.c (genAddrOf): fixed bug #704087
10176
10177 2003-03-13    <johan AT balder>
10178
10179         Hackup const and volatile modifiers in type chains a bit:
10180         * src/SDCC.y:1.63
10181         * src/SDCCast.c:1.169
10182         * src/SDCCglue.c:1.136
10183         * src/SDCCicode.c:1.143
10184         * src/SDCCsymt.c1.146
10185         * src/SDCCsymt.h1.59
10186         * src/SDCCval.c:1.63
10187
10188 2003-03-12    <johan AT balder>
10189
10190         * src/SDCCBBlock.h: more LRH debugging junk
10191         * src/SDCCcflow.h: more LRH debugging junk
10192         * src/SDCCloop.c: more LRH debugging junk
10193         * src/SDCC.y (struct_declaration): fixed bug #697590
10194         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
10195         * src/ds390/gen.c (aopForRemat): fixed bug #700031
10196         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
10197
10198 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10199         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
10200         test function names must now match exactly).
10201         * src/SDCCcse.c: added special case in findCheaperOp to allow
10202         extending a short integer. Makes less awful code for bug 700121 test case.
10203
10204 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10205
10206         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
10207         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
10208
10209 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10210
10211         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
10212         actually called (operandsNotEqual() was called for all
10213         operandsNotEqualX tests).
10214
10215 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
10216
10217         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
10218         with shorter literals. Fixes bug 700121.
10219
10220 2003-03-11    <johan AT balder>
10221
10222         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
10223
10224 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
10225
10226         * src/SDCCloop.c (mergeRegions): an evil beast is dead
10227         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
10228
10229 2003-03-10  Borut Razem <borut.razem AT siol.net>
10230
10231         * src/SDCCmain.c: pipe preprocessor's output
10232         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10233         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10234         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10235         which closes all pipes in pipeSet set
10236         * src/SDCCset.c: free deleted item in function deleteSetItem()
10237         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10238         moved from z80 to src subproject
10239         * .version: increased version number to 2.3.4
10240
10241 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
10242
10243         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
10244         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
10245         * support/regression/ports/xa51/spec.mk: fix typo
10246
10247 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
10248
10249         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
10250
10251 2003-03-09  Borut Razem <borut.razem AT siol.net>
10252
10253         * src/SDCCmain.c: pipe preprocessor's output
10254         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
10255         * sdcc_vc_in.h: define pclose as _pclose for WIN32
10256         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
10257         which closes all pipes in pipeSet set
10258         * src/SDCCset.c: free deleted item in function deleteSetItem()
10259         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
10260         moved from z80 to src subproject
10261
10262 2003-03-09  Borut Razem <borut.razem AT siol.net>
10263
10264         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
10265         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
10266         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
10267         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
10268         * src/SDCCglobl.h: unification of WIN32 native definitions
10269
10270 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10271
10272         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
10273
10274 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10275
10276         * src/configure.in:   check for endianess (even while cross-compiling)
10277         * src/configure:      check for endianess (even while cross-compiling)
10278         * src/configure_in.h: check for endianess (even while cross-compiling)
10279         * src/avr/gen.c:        remove old endianess stuff
10280         * src/mcs51/gen.c:      remove old endianess stuff
10281         * src/ds390/gen.c:      remove old endianess stuff
10282         * src/pic/gen.c:        remove old endianess stuff
10283         * src/pic/genarith.c:   remove old endianess stuff
10284         * src/pic/glue.c:       fix endianess check
10285         * src/pic16/gen.c:      remove old endianess stuff
10286         * src/pic16/genarith.c: remove old endianess stuff
10287         * src/pic16/glue.c:     fix endianess check
10288         * src/xa51/gen.c:       remove old endianess stuff
10289         * src/z80/gen.c:        fix endianess check
10290         * src/SDCCglue.c:       fix endianess check
10291         * src/ds390/peeph.def: fix bug 700036
10292
10293 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
10294
10295         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
10296         * src/configure: find appropriate data-types on host for SDCC's int and long
10297         * src/configure.in: find appropriate data-types on host for SDCC's int and long
10298         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
10299         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
10300
10301 2003-03-07    <johan AT balder>
10302
10303         Just a big NOOP:
10304                 some minor cleanups before the big shot
10305                 OP_DEFS and OP_USES now use Kevin's protection
10306                 new option --nolabelopt
10307
10308         * src/SDCCBBlock.c:
10309         * src/SDCCast.c,:
10310         * src/SDCCcflow.c:
10311         * src/SDCCcse.c:
10312         * src/SDCCicode.c:
10313         * src/SDCCicode.h:
10314         * src/SDCClabel.c:
10315         * src/SDCCloop.c:
10316         * src/SDCCmain.c:
10317         * src/ds390/ralloc.c:
10318         * src/mcs51/ralloc.c:
10319         * src/pic/ralloc.c:
10320         * src/xa51/ralloc.c:
10321         * src/z80/ralloc.c:
10322
10323 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
10324
10325         * src/pic/pcode.c (get_op): fix 64 bit warnings
10326         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
10327         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
10328         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
10329         * support/regression/tests/malloc.c: fix 64 bit warnings
10330
10331 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
10332
10333         * src/mcs51/gen.c (genMinus): fixed bug 696436
10334
10335 2003-03-02  Borut Razem <borut.razem AT siol.net>
10336
10337         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
10338
10339 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
10340
10341         * configure.in: test for mkstemp
10342         * sdccconf_in.h: add HAVE_MKSTEMP
10343
10344 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
10345
10346         * device/include/ctype.h: removed warning while using --stack-auto
10347         * device/include/malloc.h: removed warning while using --stack-auto
10348         * device/include/string.h: removed warning while using --stack-auto
10349
10350 2003-02-23  Borut Razem <borut.razem AT siol.net>
10351
10352         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
10353         because NDEBUG is defined (see man assert)
10354         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
10355
10356 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10357
10358         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
10359         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
10360
10361 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10362
10363         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
10364         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
10365
10366 2003-02-18    <johan AT balder>
10367
10368         * as/mcs51/asmain.c (asmbl): module can start with a digit
10369         * as/z80/asmain.c (asmbl): module can start with a digit
10370
10371 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
10372
10373         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
10374         * src/asm.c: fix pipe() for Mingw32
10375
10376 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
10377
10378         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
10379         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
10380         make -V work again; --c1mode reads now from stdin
10381         * doc/sdccman.lyx: added --c1mode
10382         * support/Util/SDCCerr.c: new messages for c1 mode
10383         * support/Util/SDCCerr.h: new messages for c1 mode
10384         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
10385
10386 2003-02-15    <johan AT balder>
10387
10388         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
10389
10390 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
10391
10392         * doc/sdccman.lyx: Environment variables, -o and other minor things
10393
10394 2003-02-14    <johan AT balder>
10395
10396         * src/xa51/main.c: before anyone really tries to use it :)
10397
10398         * Install doc's in share/sdcc/doc
10399         * removed some obsolete files
10400         * Do a proper make distclean and uninstall
10401         M Makefile.common.in
10402         R sdccbuild.sh
10403         M as/Makefile
10404         M device/include/Makefile.in
10405         M device/lib/Makefile.in
10406         M doc/sdccman.lyx
10407         M link/Makefile
10408         M sim/ucsim/doc/Makefile.in
10409         M src/clean.mk
10410         R src/avr/peeph.rul
10411         R src/xa51/peeph.rul
10412         M support/cpp2/Makefile.in
10413         M support/makebin/Makefile
10414
10415
10416 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
10417
10418         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
10419
10420 2003-02-10  Borut Razem <borut.razem AT siol.net>
10421
10422         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
10423         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
10424         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
10425         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
10426         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
10427         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
10428         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
10429         src/z80/Makefile.bcc: Borland Makefile cleanup
10430         * as/z80/Makefile.bcc: Added Borland Makefile
10431         * support/cpp2/borland.h: Removed
10432
10433 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
10434
10435         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
10436         * src/SDCC.lex: new pragma NOIV
10437         * src/SDCCglobl.h: new pragma NOIV
10438         * src/SDCCmem.c: new pragma NOIV
10439
10440 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10441
10442         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
10443
10444 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
10445
10446         * src/SDCCmain.c: signal handling is switched off by --debug
10447         * doc/Makefile: small fix for install; use clean.mk again
10448         * doc/clean.mk: clean *.pdf and *.html too
10449
10450 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
10451
10452         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
10453         * device/lib/printfl.c: fix a ds390 bug by making it portable
10454         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
10455         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
10456         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
10457         * debugger/mcs51/cmd.c: converted multi-line string literals
10458         * sim/ucsim/globals.cc: converted multi-line string literals
10459         * src/SDCCmain.c: introduced signal handler to remove temp files
10460         * doc/Makefile: small tweaks, implement clean
10461         * doc: removed generated files
10462
10463 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10464
10465         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
10466         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
10467         Address Record is not correctly generated for DS390."
10468
10469 2003-02-02  Borut Razem <borut.razem AT siol.net>
10470
10471         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
10472         * as/mcs51/asm.h: fixed compilation with Borland C
10473         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
10474         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
10475         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
10476         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
10477         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
10478         src/z80/Makefile.bcc: delete $(LIB) only if exist
10479         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
10480
10481 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
10482
10483         * device/include/malloc.h: introduced NULL
10484         * device/include/string.h: introduced NULL
10485         * device/include/stdlib.h: introduced NULL
10486         * device/lib/_memcpy.c: removed NULL
10487         * device/lib/_strcat.c: removed NULL
10488         * device/lib/_strchr.c: removed NULL
10489         * device/lib/_strcmp.c: removed NULL
10490         * device/lib/_strcpy.c: removed NULL
10491         * device/lib/_strcspn.c: removed NULL
10492         * device/lib/_strlen.c: removed NULL
10493         * device/lib/_strncat.c: removed NULL
10494         * device/lib/_strncmp.c: removed NULL
10495         * device/lib/_strncpy.c: removed NULL
10496         * device/lib/_strpbrk.c: removed NULL
10497         * device/lib/_strrchr.c: removed NULL
10498         * device/lib/_strspn.c: removed NULL
10499         * device/lib/_strstr.c: removed NULL
10500         * device/lib/_strtok.c: removed NULL
10501         * device/lib/malloc.c: removed NULL, include own header
10502
10503 2003-02-02    <johan AT balder>
10504
10505         * 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
10506         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
10507         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
10508         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
10509         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
10510         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
10511
10512 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10513
10514         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
10515         area 'DATA'"
10516
10517 2003-02-01    <johan AT balder>
10518
10519         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
10520
10521 2003-01-31    <johan AT CP255758-A>
10522
10523         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
10524
10525 2003-01-30    <johan AT balder>
10526
10527         * src/SDCCBBlock.c: automatic bug detection
10528         * src/SDCCicode.c: automatic bug detection
10529
10530 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10531
10532         * src/SDCCglobl.h:   now --xram-size 0 works
10533         * src/SDCCmain.c:    now --xram-size 0 works
10534
10535 2003-01-29    <johan AT balder>
10536
10537         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
10538
10539 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10540
10541         * as/mcs51/aslink.h: Added options --xram-size and --code-size
10542         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
10543         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
10544         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
10545         * src/SDCCglobl.h:   Added options --xram-size and --code-size
10546         * src/SDCCmain.c:    Added options --xram-size and --code-size
10547
10548 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
10549
10550         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
10551         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
10552
10553 2003-01-27    <johan AT balder>
10554
10555         * src/SDCC.y: fixed bug #613764
10556
10557 2003-01-26    <johan AT balder>
10558
10559         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
10560         * src/SDCCsymt.h: fixed bug #673374
10561         * src/SDCCglue.c: fixed bug #661910
10562         * src/SDCCast.c: fixed bug #458099 and 673374
10563
10564 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
10565
10566         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
10567         * as/mcs51/strcmpi.h: added
10568         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
10569         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
10570         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
10571         * as/mcs51/assym.c: strcmpi -> as_strcmpi
10572         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
10573         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
10574         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
10575         * as/mcs51/Makefile.aslink: new module strcmpi
10576         * as/mcs51/Makefile.asx8051: new module strcmpi
10577         * as/mcs51/Makefil.bcc: new module strcmpi
10578         * as/mcs51/Makefile.in: new module strcmpi
10579         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
10580
10581 2003-01-26    <johan AT balder>
10582
10583         * src/SDCCglue.c: reverted back to 1.124
10584         * src/SDCCast.c: reverted back to 1.156
10585         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
10586
10587 2003-01-25    <johan AT balder>
10588
10589         * src/SDCCglue.c: A better fix for bug #661910
10590         * src/SDCCast.c: A better fix for bug #661910
10591         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
10592
10593 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10594
10595         * src/Makefile.in: remove spawn.o
10596         * src/SDCCmain.c: remove spawn.h
10597         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
10598         * src/spawn.c: removed
10599         * src/spawn.h: removed
10600         * support/regression/ports/ds390/spec.mk: link with -r
10601
10602 2003-01-24    <johan AT CP255758-A>
10603
10604         * src/ds390/gen.c (aopOp): fixed bug #667458
10605         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
10606         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
10607         (createIvalCharPtr): an ival doesn't always have a storage class anymore
10608
10609 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
10610
10611         * src/mcs51/peeph.def: better assembler identation by Frieder
10612         * src/mcs51/gen.c: better assembler identation by Frieder
10613
10614 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
10615
10616         * as/z80/string.h: removed for gcc 3.2
10617         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
10618         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
10619
10620 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10621
10622         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
10623         * src/SDCCpeeph.c (replaceRule): fix bug #663503
10624         * support/regression/Makefile: separate temp files for ports
10625         * support/regression/generate-cases.py: separate temp files for ports
10626         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10627         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
10628
10629 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
10630
10631         * moved tinitalk to device/examples/ds390
10632
10633 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
10634
10635         * as/mcs51/lkmem.c: rflag is for DS390
10636         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
10637         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
10638                          (linkEdit): move mem- and map-files the same way as ihx-files
10639         * src/z80/main.c (_setDefaultOptions): removed --generic
10640         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
10641         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
10642         * src/pic/glue.c (picglue): --c1mode works again
10643         * src/pic16/glue.c (pic16glue): --c1mode works again
10644         * src/asm.c (printCLine): fix #660034
10645
10646 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
10647
10648         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
10649         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
10650         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
10651         * as/mcs51/lkmem (summary): better fix for sp problem
10652         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
10653         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
10654         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
10655                                               remove --stack-after-data
10656
10657 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
10658
10659         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
10660         * src/SDCCutil.c (join): ugly bug: missing '\0'
10661         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
10662
10663 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10664
10665         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
10666         * src/port.h: typo
10667         * src/pic/main.c (_asmCmd): gpasm supports -o
10668         * src/z80/main.c: more general macros
10669         * device/lib/Makefile.in: remove intermediate files
10670
10671 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
10672
10673         * .version: Bumped version number to 2.3.3
10674         * src/SDCCBBlock.c: new option -o
10675         * src/SDCCglobl.h: new option -o
10676         * src/SDCCglue.c: new option -o
10677         * src/SDCCmain.c: new option -o
10678         * src/asm.c: new option -o
10679         * src/ds390/main.c: new option -o
10680         * src/pic/glue.c: new option -o
10681         * src/pic/pcode.c: new option -o
10682         * src/pic/ralloc.c: new option -o
10683         * src/pic16/glue.c: new option -o
10684         * src/pic16/pcode.c: new option -o
10685         * src/pic16/ralloc.c: new option -o
10686         * src/z80/main.c: new option -o
10687         * device/lib/Makefile.in: use -o
10688         * support/regression/ports/ds390/spec.mk: use -o
10689         * support/regression/ports/gbz80/spec.mk: use -o
10690         * support/regression/ports/mcs51/spec.mk: use -o
10691         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
10692         * support/regression/ports/z80/spec.mk: use -o
10693         * support/regression/ports/ucz80/spec.mk: use -o
10694         * support/regression/ports/xa51/spec.mk: use -o
10695         * support/regression/fwk/lib/timeout.c: fix usage string
10696
10697 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
10698         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
10699
10700 2003-01-07    <johan AT balder>
10701
10702         * src/SDCCast.c (decorateType): fixed bug #600035
10703
10704 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
10705         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
10706         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
10707         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
10708         * src/pic/pcode.c: outcommented unused variable to remove warnings
10709         * src/pic/ralloc.c: outcommented unused variable to remove warnings
10710
10711 2003-01-06    <karl AT turbobit.com>
10712         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
10713    regression tests.
10714
10715 2003-01-06    <johan AT balder>
10716
10717         * src/SDCCicode.c: fixed array add
10718
10719 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
10720         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
10721         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
10722
10723 2003-01-04    <johan AT balder>
10724
10725         * src/SDCCval.c (getNelements): fixed the initialized array of structures
10726
10727 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10728         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
10729
10730 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10731         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
10732         * support/regression/tests/bug-524697.c: fit mem usage into 8032
10733
10734 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
10735         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
10736
10737 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
10738         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
10739
10740 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
10741         * src/mcs51/main.c: removed {bindir}{sep} from aslink
10742
10743 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10744
10745     * in \sdcc\as\mcs51\ changed these files in order to create an
10746     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
10747     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
10748     following files to include the previous two files: aslink.dsp,
10749     Makefile.aslink, Makefile.bcc, and Makefile.in.
10750
10751     * Changed \sdcc\src\SDCCmain.c so it creates files with extension
10752     .adb instead of .cdb
10753
10754 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10755
10756         * \sdcc\as\mcs51\lklist.c: Now reports memory usage using the
10757         value from option --iram-size.
10758
10759 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10760
10761         * \sdcc\as\mcs51\lklist.c: added boundary check before using
10762         dram[] array.
10763
10764 2002-09-18    <wiml AT hhhh.org>
10765
10766         * SDCClrange.h: exposed setFromRange() and setToRange()
10767         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
10768           packRegsForAccUse() (bug 542397)
10769         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
10770           multiple times and emitting the fetch operations more than once
10771           added aopGetUsesAcc() function to allow binary operators to
10772           fetch their operands in the correct order; made genMinus() emit
10773           compact code for X = LITERAL - Y
10774
10775 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10776         * \sdcc\as\mcs51\lklist.c: Fixed incorrect number of parameters to
10777         sprintf() in line 1267.
10778
10779 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10780         * \sdcc\src\SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
10781         like ports.
10782
10783 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10784         Changes to aslink (All the changes are marked with 'JCF'):
10785
10786         * \sdcc\as\mcs51\aslink.h: External definition of sflag and
10787         summary().
10788
10789         * \sdcc\as\mcs51\lkarea.c: Computes the size of area BSEG_BYTES from
10790         area BSEG.  Also moves, if possible, the DATA area down into the internal
10791         ram so more space is available.
10792
10793         * \sdcc\as\mcs51\lkdata.c: Definition of memory summary output flag
10794         sflag.
10795
10796         * \sdcc\as\mcs51\lklist.c: For the BSEG area report the size in bits,
10797         not bytes.  Function summary() which creates a memory usage summary
10798         file with extension .mem.  Reports of overlaping stack and small stack
10799         size.  If the space for the stack is less than 16 bytes aslink trows a
10800         warning.
10801
10802         * \sdcc\as\mcs51\lkmain.c: Creation of some of the default areas for
10803         the 8051.  Option 'y' for memory summary output file.
10804
10805         Changes to sdcc (All the changes are marked with 'JCF'):
10806
10807         * \sdcc\src\SDCCglobl.h: External definition of RegBankUsed[4].
10808
10809         * \sdcc\src\SDCCglue.c:  If a register bank is used, creates an
10810         overlaying area for it (uses RegBankUsed[4]).
10811
10812         * \sdcc\src\SDCCmain.c: Definition RegBankUsed[4]; marks register
10813         bank zero as used by default.  By default aslink locates the stack
10814         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
10815         the creation of the .mem file.  Delegates the allocation of data area
10816         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
10817         the begining of the stack area to aslink.
10818
10819         * \sdcc\src\SDCCmem.c:  If a register bank is used, marks it so
10820         glue() in SDCCglue.c creates an area for it.
10821
10822 2002-09-03  Borut Razem <borut.razem AT siol.net>
10823         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
10824         sdcc/src/pic/glue.c:
10825         introduced atexit() handler for teporay files removal in case of
10826         errors, assertions, ...
10827
10828 2002-08-29  Borut Razem <borut.razem AT siol.net>
10829         * sdcc/support/cpp2/auto-host_vc_in.h:
10830         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
10831         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
10832         Maybe there is a similar problem with BORLANDC? It should be checked!
10833
10834         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
10835         corrected improper use of assert: the assignment to clr variable was done inside the assert.
10836         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
10837         was not executed, and the compiler (cl) launched a warning:
10838         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
10839
10840 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
10841         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
10842
10843 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
10844         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
10845
10846         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10847           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
10848           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
10849           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10850           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
10851           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
10852           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
10853         - added Release configuration in VS projects
10854         - review of compiler an linker options
10855         - VC .exe files are generated in bin_vc directory, not to interfere
10856           with binaries generated from other projects (cygwin, mingw, bcc ...)
10857
10858         * sdcc/src/yacc.dsp: added
10859
10860         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
10861         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
10862         and insert the version number definitions from .version
10863
10864         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
10865
10866         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
10867         added - genarate auto-host.h using auto-host_vc_in.h as template
10868
10869         * sdcc/sdcc_vc.h,
10870         removed from CVS, generated automatically
10871
10872 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
10873         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
10874
10875 2002-08-11  Borut Razem <borut.razem AT siol.net>
10876         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
10877
10878 2002-08-10  Borut Razem <borut.razem AT siol.net>
10879         * src/SDCCmain.c (main):
10880         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
10881         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
10882         The consequence was that some temporary files were not removed.
10883
10884         * src/SDCCglue.c:
10885         unification of code in functions tempfilename() and tempfile():
10886         function tempnam() is defined in Visual Studio 6.0 and .NET
10887
10888         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
10889
10890         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
10891           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
10892         - removed compiler command line option /WX: Treats all warnings as errors
10893         - update a list of source files, included into the project
10894
10895         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
10896           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
10897         changed project type to Generic Project so that can be correcly converted to VS.NET project
10898
10899         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
10900
10901         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
10902
10903         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
10904
10905         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
10906         added return 0 statements after assert() to make compiler happy
10907
10908         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
10909         added newline in the def file to keep MSC compiler satisfied
10910
10911         * sdcc/src/z80/gen.c:
10912         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
10913           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
10914         - solved MSC error in function aopDump()
10915
10916         * sdcc_vc.h: define PREFIX as "\\sdcc"
10917
10918 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
10919         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
10920
10921 2002-06-22  Scott Dattalo <scott AT dattalo.com>
10922         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
10923         - Rewrote the register banking algorithm.
10924         - Added pCode live-range analysis to registers (for now, only non-used and
10925         singly-used registers optimized away)
10926
10927         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
10928
10929         * 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.
10930
10931 2002-05-10  Scott Dattalo <scott AT dattalo.com>
10932         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
10933
10934 2002-04-22  Michael Hope  <michaelh AT vroom>
10935
10936         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
10937
10938         * configure.in (DD_COPT): Added include support required for gbdk.
10939
10940         * .version: Bumped version number just to increase it.
10941
10942         * src/SDCCmain.c: Added -nostdinc to the default options.
10943
10944 2002-04-15  Michael Hope  <michaelh AT vroom>
10945
10946         * device/lib/z80/printf.c (sprintf): Added.
10947
10948         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
10949
10950         * src/z80/peeph.def: Added transpose redundent load rule.
10951
10952         * src/z80/main.c: Added force callee saves for jaune.
10953
10954         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
10955
10956         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
10957
10958 2002-03-28  Johan Knol  <johan AT balder>
10959
10960         * src/SDCCval.c: fixed bug #532436
10961
10962 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10963         * /src/port.h:
10964         Added "char *Processor" field to the port structure.
10965
10966         * /src/SDCCmain.c:
10967         Added -p option. Allows port dependent processor to be specified.
10968
10969         * all ports:
10970         Initialized the new field char *Processor field to NULL in all ports
10971
10972         * /src/pic/*:
10973         Compiler generated registers for interrupt context saving
10974         were not getting allocated.
10975
10976 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
10977
10978         * /src/SDCCast.c:
10979         Fixed left shift. Will promote the left side of a left shift
10980         if a) left shifting more than size of operand or b) when assigned
10981         to something size > size of left side
10982
10983 2002-03-14  Scott Dattalo <scott AT dattalo.com>
10984         * src/pic/*
10985         tons of changes. Register allocation has been
10986         rewritten. Added customization for the various PICs. Flow
10987         analysis is restructured. ...
10988
10989         * src/pic/device.h:
10990         Added
10991
10992         * src/pic/device.c:
10993         Added. device.c is a PIC port hack to accomodate variations
10994         in PIC devices.
10995
10996 2002-03-13  Michael Hope  <michaelh AT vroom>
10997
10998         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
10999
11000 2002-03-04  johanknol  <johanknol AT manik>
11001
11002         * /src/SDCCval.c: fixed
11003
11004         const unsigned char arr[][2] = { { 0, 1 } };
11005         t18.c:1: error: Initializer element is not constant
11006
11007 2002-03-04  bela  <bela AT manik>
11008
11009         * /device/include/mcs51reg.h:
11010         ds89c420 register definition update
11011
11012 2002-03-03    <johan AT FRIJA>
11013
11014         * support/Util/SDCCerr.c: did something, but don't no why anymore
11015
11016         * support/regression/tests/bug-524691.c: made it a little less shy
11017
11018         * src/SDCCast.c (decorateType): fixed bug #524697
11019
11020         * src/SDCCast.c: made some lineno improvements
11021
11022         * src/SDCCval.c (getNelements): changed warning to error
11023
11024         * src/SDCCglue.c (printIvalArray): changed warning to error
11025
11026         * src/SDCCicode.c: fixed a warning for mingw
11027
11028         * src/SDCCast.c (decorateType): fixed the << promotion for ops
11029
11030         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
11031
11032 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
11033
11034         * src/ds390/peeph.def:
11035         Added some more peephole rules
11036
11037         * src/ds390/gen.c: Various fixes & enhancements
11038
11039         * src/SDCClrange.c, src/SDCClrange.h:
11040         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
11041
11042         * src/ds390/ralloc.c:
11043         various fixes & enhancements (ds390) specific
11044
11045         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
11046         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
11047         from rallocs.
11048
11049         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
11050
11051 2002-03-02    <johan AT FRIJA>
11052
11053         * src/SDCCast.c (decorateType): fixed bug #524708
11054
11055         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
11056
11057         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
11058
11059 2002-03-01  Michael Hope  <michaelh AT vroom>
11060
11061         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
11062
11063         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
11064
11065 2002-03-01    <johan AT FRIJA>
11066
11067         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
11068
11069         * src/SDCCast.c (decorateType): fixed bug #524209
11070
11071         * src/SDCCval.c (valNot): fixed bug #524195
11072
11073 2002-02-26    <johan AT balder>
11074
11075         * src/xa51/gen.c: fixed a warning
11076
11077         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
11078
11079         * src/SDCCast.c (decorateType): fixed bug #522534
11080
11081 2002-02-23    <johan AT balder>
11082
11083         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
11084
11085 2002-02-22    <johan AT balder>
11086
11087         * src/SDCCast.c: fixed bug #514865
11088
11089         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
11090
11091 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
11092
11093         * sdcc/src/SDCCloop.c:
11094         Previous fix was not good. basic blocks that have "break" or "return" are
11095         not really partof a loop , but live ranges used in these blocks should
11096         be live thru the entire loop, so set partOfLoop but don't add them to
11097         loop region
11098
11099 2002-02-21    <johan AT FRIJA>
11100
11101         * src/SDCCcse.c: fixed bug #514308
11102
11103 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
11104
11105         * src/SDCCloop.c:
11106         Fixed BUG #519583. If a conditional block ended in a return/break
11107         statement inside a loop, it was not being considered part of the loop.
11108
11109         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
11110
11111 2002-02-10  Karl Bongers <karl AT turbobit.com>
11112
11113         * debugger/*:
11114         Fixed up SDCDB debugger somewhat.  Updated debugger/README
11115         with lots of comments and notes.
11116
11117         * device/examples/test2.c:
11118         Fix bug, "red" variable not being initialized(compiler complained).
11119
11120         * device/examples/Makefile, examples/test3.c:
11121         Add Makefile in device/examples folder, compiles test3.c
11122         for use as a multiple module SDCDB test case.
11123
11124         * sim/ucsim/cmd.src/cmdset.cc:
11125         Took out debug printfs in ucsim "next" command.
11126
11127         * sim/ucsim/xa.src:
11128         Karl and Johan start ucsim XA support.  Most dissassembly working,
11129         about 75% emulation done(plenty of work remaining).
11130
11131         * sim/ucsim/z80.src:
11132         Add Z80 support to ucsim, add test-ucz80 regression test,
11133         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
11134         Notice z80 compiler fails on examples/test3.c/crc code.
11135
11136 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
11137
11138         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
11139         Added support for --parms-in-bank1
11140
11141         * src/ds390/peeph.def:
11142         added a few more peephole optimzations
11143
11144         * src/ds390/main.c:
11145         1) added __builtin_inp & __builtin_outp used to read in data of given length
11146            from a memory mapped port
11147         2) added __builtin_memcmp
11148         3) added __builtin_swapw swap bytes of a short
11149
11150         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
11151         1) handle multiple send & receives from register bank1
11152         2) ralloc can now allocate DPTR1 to some liveRanges
11153
11154         * src/SDCCsymt.c, src/SDCCsymt.h:
11155         changes to handle multiple sends & receives
11156
11157         * src/SDCCptropt.h:
11158         added some pointer arithmetic optimization
11159
11160         * src/SDCCptropt.c:
11161         added some pointer arithmetic optimizations but not stable yet so not
11162         called from anywhere (will get this working shortly)
11163
11164         * src/SDCCopt.c: fixed for multiple sends & receives
11165
11166         * src/SDCCmain.c:
11167         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
11168         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
11169            set preprocessor defines (depending on options)
11170
11171         * src/SDCCicode.c, src/SDCCicode.h:
11172         changes made to handle multiple sends & receives
11173
11174         * src/SDCCglobl.h:
11175         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
11176
11177         * src/SDCCcse.c, src/SDCCcse.h:
11178         added function findbackward def (to be used in upcoming optimization)
11179
11180         * src/SDCCcflow.c, src/SDCCcflow.h:
11181         added function returnAtEnd - to determine if a basic block terminates with
11182         a RETURN iCode
11183
11184         * src/SDCCast.c, src/SDCCast.h:
11185         added option parms-in-bank1
11186
11187         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
11188         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
11189         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
11190         adjusted for --parms-in-bank1 option
11191
11192         * device/include/string.h:
11193         donot redefine "reentrant" keyword
11194
11195         * device/include/ds80c390.h: Added some more SFRs
11196
11197 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
11198
11199         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
11200
11201 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
11202
11203         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
11204
11205 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
11206
11207         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
11208
11209 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
11210
11211         * Added --xram-movc option
11212
11213 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
11214
11215         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
11216
11217 2002-01-11  Johan Knol
11218
11219         * Added math lib of Jesus Calvino-Fraga
11220
11221 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
11222
11223         * src/SDCCmain.c (processFile): fix processing of ../../src.c
11224         * support/regression/Makefile: new target test-mcs51-stack-auto
11225         * support/regression/ports/mcs51-stack-auto/spec.mk: added
11226
11227 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11228
11229         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
11230
11231 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
11232
11233         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
11234
11235 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
11236
11237         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
11238
11239         * src/SDCCglue.h: add definition for printIvalChar()
11240
11241 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11242
11243         * src/SDCCast.c: fix #498138 by Johan
11244
11245         * src/SDCCglue.c: fix #498138 by Johan
11246
11247 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
11248
11249         * support/regression/Makefile: fix clean
11250
11251         * support/regression/ports/ds390/support.c: fix transmission of last character
11252
11253 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
11254
11255         * /sdcc/src/ds390/gen.c:
11256         a) improved computing address of stack variable
11257         b) took out some #if 0 code
11258         c) improved parmBytes adjustment
11259         d) improved genPlusIncr & genMinusIncr
11260         e) genCmp could generate bad code (when left assigned to DPTR)
11261         f) Fixed bug in hasInc
11262
11263         * /sdcc/src/ds390/ralloc.c:
11264         a) packRegsForSupport could mess up live information (Fixed)
11265         b) packRegsDPTRuse could be incorrect for left & right shift
11266
11267         * /sdcc/src/mcs51/ralloc.c:
11268         packRegsForSupport could mess up the live information (Fixed)
11269
11270         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
11271
11272         * /sdcc/src/SDCCast.c:
11273         can reverse a loop even if function call is present as long
11274         as the loop control variable is local & is not passed as parameter
11275
11276 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11277
11278         * /sdcc/ChangeLog: *** empty log message ***
11279
11280         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
11281         More builtin function additions for TININative
11282
11283         * /sdcc/src/ds390/ralloc.c:
11284         Had broken the regression testsuite
11285
11286         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
11287
11288         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
11289         Added funcattr hasStackParms will be set for reentrant functions when there
11290         are paramteres on the stack, this helps in minimizing frame pointer generation
11291         typeFromStr can handle function pointers now
11292
11293         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
11294         *** empty log message ***
11295
11296 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11297
11298         * /src/ds390/gen.c, /src/ds390/main.c:
11299         More builtin function additions for TININative
11300
11301         * /src/ds390/ralloc.c:
11302         Had broken the regression testsuite
11303
11304         * /src/SDCCast.c: Fixed a bug in dumptree
11305
11306         * /src/SDCCsymt.c, /src/SDCCsymt.h:
11307         Added funcattr hasStackParms will be set for reentrant functions when there
11308         are paramteres on the stack, this helps in minimizing frame pointer generation
11309         typeFromStr can handle function pointers now
11310
11311         * /doc/builtins.txt, /doc/TININative.txt:
11312         *** empty log message ***
11313
11314
11315 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
11316
11317         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
11318         ALPHA version for -mTININative
11319
11320         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
11321         updated to reflect changes in the port structure
11322
11323         * /src/port.h:
11324         added function do_assemble (similar to do_link) if non-null this function
11325         will be called to do assembly (-mTININative) requires a multi command
11326         assembly
11327         added function genAssemblerEnd will be called to generate assembler Epilogue
11328
11329         * /src/SDCCsymt.c:
11330         added _JavaNative to debug info printing
11331
11332         * /src/SDCCmain.c: added option --tini-libid
11333         added port->do_assemble function (-mTININative) has a multi command assemble
11334
11335         * /src/SDCCglue.c: Disabled "constExpr" check
11336         added port->genAssemblerEnd function
11337
11338         * /src/SDCCglobl.h: Added option --tini-libid value
11339
11340         * /src/SDCCast.h:
11341         tookout optimizeCompare from the header (has no external references)
11342
11343         * /src/SDCCast.c: made one more function "static"
11344
11345 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
11346
11347         * src/z80/mappings.i: Added z80asm support.
11348
11349         * src/z80/main.c: Added z80asm support on --asm=z80asm
11350
11351         * src/z80/gen.c: Fixed asm portability issues.
11352
11353         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
11354
11355         * src/SDCCglue.c (printExterns): Added global/extern split.
11356
11357 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
11358
11359         * support/regression/Makefile: added test for mcs51 model large
11360
11361         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
11362
11363         * support/regression/ports/gbz80/spec.mk: added -mgbz80
11364
11365 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
11366
11367         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
11368
11369 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
11370
11371         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
11372
11373         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
11374
11375 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
11376
11377         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
11378
11379         * support/regression/tests/simplefloat.c: Port to mcs51.
11380
11381 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
11382         * support/regression/tests/bug-485362.c: Added.
11383
11384         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
11385
11386         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
11387
11388         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
11389
11390         * src/z80/gen.c (aopDump): Added a dump function.
11391
11392 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
11393         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
11394
11395         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
11396
11397         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
11398
11399         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
11400
11401         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
11402
11403         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
11404
11405         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
11406
11407         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
11408
11409         * support/regression/ports/ds390/support.c: Use tinibios.
11410
11411         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
11412
11413 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
11414
11415         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
11416         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
11417
11418         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
11419
11420         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
11421
11422 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
11423
11424         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
11425
11426         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
11427         (packRegsForIYUse): Created and optimised.
11428
11429 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11430
11431         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
11432 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
11433
11434         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
11435
11436         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
11437
11438         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
11439
11440 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11441
11442         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
11443
11444         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
11445
11446 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11447
11448         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
11449
11450         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
11451
11452         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
11453
11454 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
11455
11456         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
11457         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
11458         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
11459
11460         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
11461
11462         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
11463         (genNotFloat): Added.
11464         (genUminusFloat): Added.
11465
11466         * device/lib/z80/Makefile: Added floating pt stubs.
11467
11468         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
11469
11470         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
11471
11472         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
11473
11474 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
11475
11476         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
11477
11478         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
11479
11480         * sdcc/support/regression/Makefile: Add port ds390.
11481
11482         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
11483
11484         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
11485
11486         * sdcc/support/regression/ports/ds390/spec.mk: Added.
11487
11488         * sdcc/support/regression/ports/ds390/support.c: Added.
11489
11490         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
11491
11492         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
11493
11494         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
11495
11496 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11497
11498         * device/include/malloc.h: Added z80 and gbz80 support.
11499
11500         * device/lib/gbz80/heap.s: Added.
11501
11502         * device/lib/z80/heap.s: Added.
11503
11504         * device/lib/malloc.c: Added z80 and gbz80 support.
11505
11506         * support/regression/tests/malloc.c (testMalloc): Added.
11507
11508         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
11509
11510         * support/regression/tests/bug-478094.c: Added.
11511
11512         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
11513
11514 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
11515
11516         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
11517
11518         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
11519
11520         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
11521
11522         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
11523
11524         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
11525
11526 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
11527
11528         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
11529
11530 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
11531
11532         * support/regression/tests/bug-477927.c: Added.
11533
11534         * src/z80/peeph.def: Added minor rules.
11535
11536         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
11537
11538         * src/z80/peeph.def: Added jump optimisation modification.
11539
11540 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
11541
11542         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
11543
11544 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
11545
11546         * support/regression/tests/funptrs.c: Added.
11547
11548 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
11549
11550         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
11551
11552 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
11553
11554         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
11555
11556         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
11557
11558         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
11559         (movLeft2ResultLong): Created.
11560
11561         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
11562         (joinPushes): Added.  Joins two char pushes into a word push.
11563
11564 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
11565
11566         * support/cpp2/Makefile.in (install): Added creation of dest dir.
11567
11568         * support/makebin/Makefile (install): Added creation of dest dir.
11569
11570 2001-10-24 Karl Bongers <karl AT turbobit.com>
11571
11572         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
11573
11574 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
11575
11576         * src/z80/ralloc.c: Turned off faulty pack for one use.
11577
11578         * src/z80/peeph-gbz80.def: Removed redundent restart options.
11579
11580         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
11581
11582 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
11583
11584         * support/regression/Makefile: Improved clean
11585
11586         * support/regression/ports/gbz80/spec.mk: Added clean
11587
11588         * support/regression/ports/host/spec.mk: Added clean
11589
11590         * support/regression/ports/z80/spec.mk: Added clean
11591
11592         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
11593
11594         * support/regression/ports/mcs51/timeout.c: little improvements
11595
11596 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
11597
11598         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
11599
11600         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
11601
11602         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
11603
11604 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
11605
11606         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
11607
11608         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
11609
11610 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
11611         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
11612
11613         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
11614
11615         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
11616
11617         * src/mcs51/main.c (_linkCmd): Added bin path to command.
11618
11619         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
11620
11621         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
11622
11623         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
11624
11625         * support/regression/tests/longor.c: Added.
11626
11627 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
11628
11629         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
11630
11631         * as/mcs51/aslink.h: define PATH_MAX
11632
11633         * as/mcs51/asm.h: define PATH_MAX
11634
11635         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
11636
11637         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
11638
11639         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
11640
11641         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
11642
11643         * src/SDCCglobl.h: define PATH_MAX
11644
11645         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
11646
11647         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
11648
11649 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
11650
11651         * src/z80/gen.c (gencjneshort): Fixed
11652
11653         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
11654
11655 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
11656
11657         * support/regression/tests/bug-469671.c: Added.
11658
11659         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
11660
11661 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
11662
11663         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
11664
11665         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
11666
11667 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
11668
11669         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
11670
11671         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
11672
11673         * src/device/lib/_mullong.c : removed hint: nooverlay bug
11674
11675         * src/device/lib/_divuint.c : removed hint: nooverlay bug
11676
11677         * src/device/lib/_divulong.c: removed hint: nooverlay bug
11678
11679         * src/device/lib/_moduint.c : removed hint: nooverlay bug
11680
11681         * src/device/lib/_modulong.c: removed hint: nooverlay bug
11682
11683 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
11684
11685         * 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.
11686
11687         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
11688
11689         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
11690
11691 2001-10-07    <johan AT FRIJA>
11692
11693         * device/lib/gets.c (gets): fixed the return value.
11694
11695 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
11696         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
11697
11698         * 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.
11699
11700         * 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.
11701
11702         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
11703
11704         * src/pic/gen.c: Removed Safe_strdup.
11705
11706         * configure.in: Added option to enable libgc support.
11707
11708         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
11709         (bitVectUnion): Optimised.
11710         (bitVectIntersect): Optimised.
11711         (bitVectBitsInCommon): Optimised.
11712         (bitVectCplAnd): Optimised.
11713
11714         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
11715
11716 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11717
11718         * src/SDCCmain.c: distinguish between assembler debug and plain options
11719
11720         * src/avr/main.c:   remove standard assembler options
11721
11722         * src/ds390/main.c: remove standard assembler options
11723
11724         * src/mcs51/main.c: remove standard assembler options
11725
11726         * src/port.h: removed "PENDING" comment
11727
11728 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11729
11730         * src/device/lib/_mulint.c  : new, with assember functions
11731
11732         * src/device/lib/_mullong.c : new, with assember functions
11733
11734         * src/device/lib/_divuint.c : with assember functions
11735
11736         * src/device/lib/_divsint.c : with assember functions
11737
11738         * src/device/lib/_divulong.c: with assember functions
11739
11740         * src/device/lib/_divslong.c: with assember functions
11741
11742         * src/device/lib/_moduint.c : with assember functions
11743
11744         * src/device/lib/_modsint.c : with assember functions
11745
11746         * src/device/lib/_modulong.c: with assember functions
11747
11748         * src/device/lib/_modslong.c: with assember functions
11749
11750         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
11751
11752         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
11753
11754         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
11755                                       replaced _mululong.c and _mulslong.c by _mullong.c
11756
11757 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
11758
11759         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
11760
11761 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11762
11763         * src/SDCCglue.c: test, if win32api is available for MINGW
11764
11765 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
11766
11767         * src/SDCCsymt.c: no more _modifier in printTypeChain()
11768         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
11769         * support/regression/ports/gbz80/spec.mk: removed GENERIC
11770         * support/regression/ports/host/spec.mk: removed GENERIC
11771         * support/regression/ports/mcs51/spec.mk: removed GENERIC
11772         * support/regression/ports/z80/spec.mk: removed GENERIC
11773
11774 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
11775
11776         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
11777
11778         * support/regression/tests/bug-467035.c: Created.
11779
11780 2001-10-01    <johan AT FRIJA>
11781
11782         * src/SDCC.y: fixed bug #466586 part 1
11783
11784 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
11785
11786         * SDCCicode.c: z80 has no generic pointers
11787         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
11788
11789 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
11790
11791         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
11792
11793 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
11794
11795         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
11796
11797         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
11798
11799 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
11800
11801         * configure.in: Fixed up so that ucsim is only configured once.
11802
11803         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
11804
11805         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
11806         (getPathDifference): As above.
11807
11808         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
11809
11810         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
11811
11812 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
11813         * .version: Updated to 2.3.1
11814
11815         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
11816         Added copyright header.
11817
11818         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
11819         (assemble): Added support for macro based assembler commands.
11820         (linkEdit): Added support for macro based linker commands.
11821         (preProcess): Changed the pre-processor to use macros.
11822         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
11823         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
11824
11825         * device/lib/z80/crt0.s: Added module name for debugging.
11826
11827 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
11828
11829         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11830
11831         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
11832
11833         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
11834
11835         * src/Makefile.in: Added SDCCmacro and SDCCutil
11836
11837 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
11838
11839         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
11840
11841 2001-09-16    <johan AT FRIJA>
11842
11843         * 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.
11844
11845 2001-09-15    <johan AT FRIJA>
11846
11847         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
11848         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
11849
11850 2001-09-11    <johan AT FRIJA>
11851
11852         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
11853
11854 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
11855
11856         * support/regression/tests/bug-460444.c: Added test case.
11857
11858         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
11859         (genCast): Added justification for all of the asserts.
11860
11861 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
11862
11863         * support/regression/support.c: _xdata replaced by xdata
11864
11865         * support/regression/spec.mk: removed _generic
11866
11867 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
11868
11869         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
11870
11871         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
11872         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
11873
11874         * src/z80/peeph.def: Added a rule to optimise shift then compare.
11875
11876         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
11877
11878         * support/regression/tests/bug-460010.c: Added test case.
11879
11880         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
11881
11882 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
11883
11884         * support/regression/Makefile: inter-port-clean adjusted for mcs51
11885
11886         * support/regression/testfwk.c: removed workaround for bug #436344
11887
11888         * support/regression/tests/bp.c: use less memory with mcs51
11889
11890         * support/regression/tests/bug-441448.c: use less memory
11891
11892         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
11893
11894         * support/regression/collate-results.py: typo
11895
11896 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
11897
11898         * support/regression/tests/fetchoverlap.c: Added new test case.
11899
11900         * support/regression/tests/bp.c: Added new test case.
11901
11902         * support/regression/tests/bug-448984.c: Added new test case.
11903
11904         * support/regression/tests/pow2shifts.c: Added new test case.
11905
11906         * src/z80/gen.c: Turned off the noise it normally generates for the release.
11907         (genlshTwo): Fixed right shift for count > 8.
11908
11909         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
11910
11911 2001-09-08    <johan AT FRIJA>
11912
11913         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
11914
11915 2001-09-07    <johan AT FRIJA>
11916
11917         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
11918
11919         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
11920
11921 2001-09-06    <johan AT FRIJA>
11922
11923         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
11924         * bernhard noted me at this: "() equals to (void)" (1.38)
11925
11926 2001-09-05    <johan AT FRIJA>
11927
11928         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
11929
11930 2001-09-04    <johan AT FRIJA>
11931
11932         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
11933
11934
11935 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
11936
11937         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
11938
11939 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
11940
11941         * link/z80/aslink.h: Fixed path for PATH_MAX
11942
11943 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
11944
11945         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
11946
11947         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
11948
11949         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
11950
11951         * 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.
11952
11953 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
11954
11955         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
11956         (genCmp): Fixed up genCmp for the GB with longs.
11957
11958         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
11959
11960         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
11961
11962         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
11963
11964         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
11965
11966 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
11967
11968         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
11969
11970 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
11971
11972         * 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.
11973
11974         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
11975
11976 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
11977
11978         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
11979
11980         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
11981
11982 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
11983
11984   * sim/ucsim/configure:    little improvement of Cygwin-detection
11985   * sim/ucsim/configure.in: little improvement of Cygwin-detection
11986   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
11987   * support/regression/tests/bug-221100.c: small changes for mcs51
11988   * support/regression/tests/bug-221168.c: small changes for mcs51
11989   * support/regression/tests/bug-227710.c: small changes for mcs51
11990   * support/regression/tests/staticinit.c: small changes for mcs51
11991   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
11992   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11993   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
11994
11995 $Revision$