* as/doc/asmlnk.doc, as/doc/asxhtm.html: updated link-xx and aslink
[fw/sdcc] / ChangeLog
1 2008-03-14 Borut Razem <borut.razem AT siol.net>
2
3         * as/doc/asmlnk.doc, as/doc/asxhtm.html: updated link-xx and aslink
4           command line options
5         * as/link/hc08/lkmain.c: converted tabs to spaces so that the usage
6           is correctly displayed
7         * as/link/z80/lkmain.c: usage line commented out
8
9 2008-03-13 Borut Razem <borut.razem AT siol.net>
10
11         * doc/sdccman.lyx: corrected to be able to convert to PDF,
12           updated the list pf supported pic14 devices
13
14 2008-03-12 Maarten Brock <sourceforge.brock AT dse.nl>
15
16         * doc/sdccman.lyx: added paragraph about bankswitching for mcs51
17
18 2008-03-12 Borut Razem <borut.razem AT siol.net>
19
20         * as/doc/asmlnk.doc, as/doc/asxhtm.html: updated command line options,
21           fixed documentation request #1718191
22         * as/hc80/asmain.c, as/mcs51/asmain.c: added option -c to usage
23         * doc/sdccman.lyx: added description of --no-std-crt0 gbz80
24           command line option
25
26 2008-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
27
28         * src/SDCCast.c (isConformingBody): fixed bug 1505811, thanks Robert Larice
29         * support/regression/tests/bug1505811.c: new, added
30
31 2008-03-09 Raphael Neider <rneider AT web.de>
32
33         * device/include/pic16/pic18f2620.h,
34         * device/include/pic16/pic18f4620.h,
35         * device/lib/pic16/libdev/pic18f2620.c,
36         * device/lib/pic16/libdev/pic18f4525.c,
37         * device/lib/pic16/libdev/pic18f4620.c: merged 18f2525/2620/4525/4620
38           family to consistently use pic18f4620.[ch], fixes #1832562
39
40 2008-03-09 Borut Razem <borut.razem AT siol.net>
41
42         * .version, sdcc.spec, doc/sdccman.lyx, doc/INSTALL.txt:
43           changed sdcc version to 2.8.0
44         * knownbugs.html: regenerated
45         * support/scripts/gen_known_bugs.pl: added number of open bugs
46
47 2008-03-09 Raphael Neider <rneider AT web.de>
48
49         * src/pic16/gen.c (pic16_mov2w_volatile): NEW, read volatile operands,
50           (genOr): read volatile operand even if the result is known,
51           closes #1511838
52           (genOr,genXor): removed unused legacy code,
53           (genDummyRead): use pic16_mov2w_volatile()
54
55 2008-03-08 Borut Razem <borut.razem AT siol.net>
56
57         * src/SDCCglue.c: fixed bug #1864582: multiple definition of char
58           cons w. --model-large
59         * support/regression/staticinit.c: added regression test for bug
60           #1864582
61
62 2008-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
63
64         * src/ds390/gen.c (pushSide, genPcall),
65         * src/hc08/gen.c (pushSide, genPcall): synchronized with mcs51
66         * src/mcs51/gen.c: cosmetic changes
67         * support/regression/fwk/include/testfwk.h: added macro reentrant
68         * support/regression/tests/bug1908493.c: new, added
69
70 2008-03-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
71
72         * src/SDCCdebug.c:, as/link/lkaomf51.c: Fixed bug 1909409: Pdata in OMF file
73
74 2008-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
75
76         * src/mcs51/gen.c (pushSide, genPcall): fixed bug 1908493
77         * src/SDCCmain.c (preProcess): removed -DSDCC_PARMS_IN_BANK1 because it is
78           already set in ds390/main.c and mcs51/main.c
79
80 2008-03-07 Raphael Neider <rneider AT web.de>
81
82         * src/regression/init0.c: new test for initialized arrays of function
83           pointers
84         * src/regression/Makefile: made a bit more flexible, added init0.c
85         * src/pic/glue.c (emitIvals): hacky fix for initializing from function
86           pointers, closes #1427663
87
88 2008-03-05 Borut Razem <borut.razem AT siol.net>
89
90         * dos/sdccman.lyx: docummented predefined macros SDCC_REVISION,
91           SDCC_PARMS_IN_BANK1, SDCC_FLOAT_REENT and SDCC_INT_LONG_REENT
92
93 2008-03-05 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
94
95         * support/librarian/sdcclib.c:Added feature request 1908061:
96           Synchronise sdcclib commands with ar.
97
98 2008-03-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
99
100         * src/SDCCmain.c: added predefined macros SDCC_REVISION (RFE #1907229),
101           and (depending on corresponding compiler option) SDCC_PARMS_IN_BANK1,
102           SDCC_FLOAT_REENT, SDCC_INT_LONG_REENT
103         * device/include/mcs51/compiler.h: removed umlauts, added double
104           underscore
105
106 2008-03-04 Maarten Brock <sourceforge.brock AT dse.nl>
107
108         * src/SDCCptropt.c (ptrPseudoSymConvert): fixed bug 1536762
109         * support/regression/tests/bug1536762.c: new, added
110         * src/SDCCutil.c,
111         * src/SDCCutil.h: added getBuildDate()
112         * src/SDCCmain.c (printVersionInfo),
113         * src/SDCCglue.c (initialComments): use getBuildDate() instead of
114           __DATE__
115         * src/*/ralloc.c: removed IS_OP_RUONLY macro
116         * src/ds390/ralloc.c (packRegisters),
117         * src/mcs51/ralloc.c (packRegisters),
118         * src/z80/ralloc.c (packRegisters): applied fix for bug 1618050, thanks
119           Robert Larice
120         * support/regression/tests/bug1618050.c: new, added
121         * src/SDCCsymt.h: fixed typo in DECLSPEC2TXT
122         * support/regression/fwk/include/testfwk.h,
123         * support/regression/tests/bug1838000.c: moved _AUTOMEM and _STATMEM to
124           testfwk.h
125
126 2008-03-04 Raphael Neider <rneider AT web.de>
127
128         * src/pic/gen.c: removed unused prototypes, prevent internal errors
129           on accessing OP_SYM_TYPE(op)
130         * src/pic/gen.h: removed unused prototype of genMinusDec()
131         * src/pic/genarith.c (genMinus): cosmetic changes, rewritten to
132           fix #1876953 (invalid subtraction code), removed unused code
133
134 2008-03-03 Raphael Neider <rneider AT web.de>
135
136         * src/pic/gen.c,
137         * src/pic/gen.h,
138         * src/pic/genarith.c,
139         * src/pic/ralloc.c,
140         * src/pic/ralloc.h: removed AOP_R0, AOP_R1, AOP_DPTR, AOP_DPTR2,
141           AOP_ACC, and *_IDX and adjusted code, removed unused legacy code
142
143 2008-03-03 Raphael Neider <rneider AT web.de>
144
145         * src/pic/device.c (find_device): search user-specified paths first
146           for pic14devices.txt, fixes #1900827
147
148 2008-03-02 Borut Razem <borut.razem AT siol.net>
149
150         * support/scripts/sdcc.nsi: fixed bug in IsNT, LogicLib-isation of
151           AddToPath and RemoveFromPath
152
153 2008-03-01 Borut Razem <borut.razem AT siol.net>
154
155         * support/scripts/sdcc.nsi: reverted MULTIUSER page since it didn't
156           work correctly, added debugging support if -DSDCC.DEBUG command line
157           option is defined
158
159 2008-02-28 Borut Razem <borut.razem AT siol.net>
160
161         * doc/sdccman.lyx: cosmetic changes
162
163 2008-02-28 Maarten Brock <sourceforge.brock AT dse.nl>
164
165         * src/mcs51/ralloc.c (fillGaps): fixed bug 1839671
166         * doc/sdccman.lyx: fixed unmeant removal of spaces
167
168 2008-02-27 Borut Razem <borut.razem AT siol.net>
169
170         * support/scripts/sdcc.nsi: corrected installation directory for
171           current user installation mode
172         * doc/README.txt: added Philipp Klaus Krause to the developers list
173
174 2008-02-27 Maarten Brock <sourceforge.brock AT dse.nl>
175
176         * src/mcs51/gen.c (genUnpackBits): don't generate ifxJump, instead
177           return ifx condition
178           (genNearPointerGet, genPagedPointerGet, genFarPointerGet,
179           genCodePointerGet, genGenPointerGet): cleanup aop before generating
180             ifxJump to fix bug 1838000
181         * src/SDCCsymt.c (aggregateToPointer): fix problem for xstack
182         * support/regression/tests/bug1838000.c: new, added
183         * device/include/mcs51/cc1110.h: new, added, thanks to Pravin Angolkar
184
185 2008-02-26 Borut Razem <borut.razem AT siol.net>
186
187         * src/SDCCast.c, doc/sdccman.lyx: fixed RFE #1901171: inerger promotion
188           of casted varargs
189         * support/scripts/sdcc.nsi: added MULTIUSER page,
190           NSIS upgraded to version 2.35
191
192 2008-02-25 Maarten Brock <sourceforge.brock AT dse.nl>
193
194         * src/mcs51/ralloc.c (isSpiltOnStack): fixed bug 1565152
195         * support/regression/tests/bug1565152.c: new, added
196
197 2008-02-25 Maarten Brock <sourceforge.brock AT dse.nl>
198
199         * src/mcs51/gen.c (genPagedPointerSet): fixed bug 1670148
200         * support/regression/ports/mcs51-xstack-auto/spec.mk: added expf.c
201         * support/regression/tests/bug1670148.c: new, added
202
203 2008-02-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
204
205         * device/include/mcs51/at89c51ed2.h: fixed bug 1901469.
206
207 2008-02-24 Borut Razem <borut.razem AT siol.net>
208
209         * src/SDCCast.c, src/SDCCast.h: fixed bug #1874922: explicit typecast
210           is ineffective for unsigned char parameter
211
212 2008-02-24 Maarten Brock <sourceforge.brock AT dse.nl>
213
214         * src/SDCCast.c (expandInlineFuncs): fixed bug 1875869
215         * src/SDCCglue.c (printIvalBitFields): fixed bug 1806631
216         * support/regression/tests/bitopcse.c: removed hc08 exception, see testfwk.h
217         * support/Util/MySystem.c (my_system): output errorcode when verbose
218
219 2008-02-22 Philipp Klaus Krause <pkk AT spth.de>
220
221         * src/z80/gen.c (genMult): Rewrote 8-bit multiplication by constant,
222           implements #1898231
223
224 2008-02-22 Philipp Klaus Krause <pkk AT spth.de>
225
226         * device/lib/z80/mul.s: Rewrote __muluchar_rrx_s, to improve 8-bit mult.,
227           implements #1896290
228
229 2008-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
230
231         * src/SDCCast.c (createIvalStruct): fixed bug 1466761
232
233 2008-02-21 Borut Razem <borut.razem AT siol.net>
234
235         * support/regression/Makefile.in,
236           support/regression/ports/ds390/spec.mk,
237           support/regression/ports/hc08/spec.mk,
238           support/regression/ports/mcs51-common/spec.mk,
239           support/regression/ports/pic14/spec.mk,
240           support/regression/ports/pic16/spec.mk,
241           support/regression/ports/ucz80/spec.mk,
242           support/regression/ports/xa51/spec.mk:
243           added CFLAGS when compiling timeout
244
245 2008-02-20 Philipp Klaus Krause <pkk AT spth.de>
246
247         * support/regression/tests/bugs-1596270-1736867.c: Regression test for
248           #1596270, #1736867
249
250 2008-02-20 Maarten Brock <sourceforge.brock AT dse.nl>
251
252         * src/SDCClrange.c (findPrevUse): fixed bug 1888147
253         * support/regression/tests/bug1888147.c: new, added
254
255 2008-02-20 Philipp Klaus Krause <pkk AT spth.de>
256
257         * src/z80/gen.c: fixed bugs #1596270, #1736867
258
259 2008-02-20 Philipp Klaus Krause <pkk AT spth.de>
260
261         * src/z80/gen.c: fixed bug in register pair loading when swapping register
262           contents, mostly fixes #1596270
263
264 2008-02-20 Philipp Klaus Krause <pkk AT spth.de>
265
266         * src/z80/peeph.def,
267         * src/z80/peeph-z80.def: moved peephole that breaks gbz80 to z80-specific
268           peepholes, fixes #1806565
269
270 2008-02-20 Maarten Brock <sourceforge.brock AT dse.nl>
271
272         * src/SDCCpeeph.c (operandBaseName): added check for @Ri
273         * src/mcs51/peeph.def (rule 177.c): added operandsNotRelated(%1 %3)
274           fixes bug 1739475, thanks Robert Larice
275           (rule 271): new, added
276
277 2008-02-18 Borut Razem <borut.razem AT siol.net>
278
279         * sim/ucsim/s51.src/Makefile.in: fixed error made in previous commit
280
281 2008-02-17 Maarten Brock <sourceforge.brock AT dse.nl>
282
283         * src/SDCCmain.c (linkEdit): emit -z when using --debug for z80
284
285 2008-02-17 Raphael Neider <rneider AT web.de>
286
287         * src/pic16/genarith.c,
288         * src/pic16/gen.c,
289         * src/pic16/gen.h,
290         * src/pic16/genutils.c: removed unused legacy code,
291           removed unused fields from struct asmop and struct _G
292
293 2008-02-17 Raphael Neider <rneider AT web.de>
294
295         * src/pic16/gen.c (AccRsh): cosmetic changes,
296           (shiftR1Left2ResultSigned,shiftR1Left2Result,shiftL1Left2Result,
297           genRightShiftLiteral): fixed to work with SFRs as result by
298           assigning only once to result,
299           removed a lot of unused/excluded code fragments
300
301 2008-02-17 Raphael Neider <rneider AT web.de>
302
303         * device/include/pic/pic16f88.h,
304         * device/include/pic/pic16f886.h,
305         * device/include/pic/pic16f887.h: added TRISA6 and TRISA7
306
307 2008-02-17 Borut Razem <borut.razem AT siol.net>
308
309         * src/z80/peeph.def: applied patch
310           #1893626: Optimize tail calls on Z80, thanks to Philipp Krause
311         * src/z80/gen.c, src/z80/peeph.def: applied patch
312           #1893510: Improve logical left shift on Z80, thanks to Philipp Krause
313         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
314           sim/ucsim/s51.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
315           sim/ucsim/xa.src/Makefile.in, sim/ucsim/z80.src/Makefile.in,
316           sim/ucsim/main_in.mk: renamed libutil.a to libucsimutil.a in order to
317           enable compilation on Mac OS X 10.5 (Leopard) and XCode v3.0
318
319 2008-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
320
321         * as/link/mcs51/aslink.dsp: removed SDK define
322         * as/link/z80/clean.mk: brought in sync with other ports
323         * as/link/z80/lklibr.c (SdccLib, fndsym): handle the dflag here too
324         * as/hc08/Makefile.bcc,
325         * as/mcs51/Makefile.bcc,
326         * as/z80/Makefile.bcc: noice.c was moved to as/asxxsrc/
327         * src/z80/main.c (_setValues): use the now capitalized -Z,
328           (z80_port, gbz80_port): generate debug information when asked
329
330 2008-02-16 Borut Razem <borut.razem AT siol.net>
331
332         * as/z80/asmain.c, as/z80/asm.h, as/z80/asdata.c,
333           as/link/z80/lkmain.c, as/z80/as_gbz80.dsp, as/z80/as_z80.dsp,
334           as/z80/Makefile.in. as/z80/Makefile.bcc:
335           applied patch #1893393: patch for as-z80 and link-z80 to generate
336           cdb, thanks to Armin Diehl
337         * as/*/asnoice.c, as/hc08/as_hc08.dsp, as/hc08/Makefile.in,
338           as/mcs51/asx8051.dsp, as/mcs51/Makefile.in:
339           asnoice.c moved to as/asxxsrc/asnoice.c
340         * src/z80/peeph-gbz80.def: applied patch
341           #1880235: Z80 return peephole, thanks to Philipp Krause
342
343 2008-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
344
345         * .version,
346         * doc/sdccman.lyx: bumped version to 2.7.5
347         * src/SDCCsymt.c (compareType, comparePtrType): fixed bug 1281583
348
349 2008-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
350
351         * device/include/pic16/stdlib.h,
352         * device/lib/pic16/libc/stdlib/ltoa.c,
353         * device/lib/pic16/libc/stdio/vfprintf.c: ascii strings are char*
354
355 2008-02-13 Borut Razem <borut.razem AT siol.net>
356
357         * src/SDCCmain.c, src/SDCCglue.c: fixed --c1mode
358         * src/pic16/glue.c, src/SDCCast.c, src/SDCCast.h, src/SDCCBBlock.c,
359           src/SDCCcse.c, src/SDCCglue.c, src/SDCCicode.c, src/SDCCloop.c,
360           src/SDCCopt.c,  src/SDCCval.c:
361           fixed bug #1890273: SDCC Warning 154 shows wrong filename
362
363 2008-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
364
365         * src/SDCCsymt.c (compareType): fixed bug 1309013
366
367 2008-02-09 Borut Razem <borut.razem AT siol.net>
368
369         * src/SDCCval.c, src/SDCCval.h:
370           code cleaning, added function constChrVal()
371         * src/SDCCglue.c, src/pic/glue.c, src/pic16/glue.c, src/SDCCast.c, src/SDCC.y:
372           call constChrVal() instead constVal()
373
374 2008-02-01 Maarten Brock <sourceforge.brock AT dse.nl>
375
376         * src/SDCCast.c (resolveSymbols): added reentrancy check for parameters
377           of function pointer
378         * src/SDCCerr.h,
379         * src/SDCCerr.c: changed warning W_NONRENT_ARGS to error E_NONRENT_ARGS
380         * support/regression/tests/absolute.c: added TestStruct TestVar (see also
381           bug 1859853)
382
383 2008-02-01 Raphael Neider <rneider AT web.de>
384
385         * device/include/pic/pic16f886.h,
386         * device/include/pic/pic16f887.h: added RA6 and RA7
387
388 2008-01-24 Raphael Neider <rneider AT web.de>
389
390         * device/include/pic/pic16f88.h: added RA6 and RA7
391         * device/lib/pic/libdev/disabled_pic16f886.c,
392         * device/lib/pic/libdev/disabled_pic16f887.c: renamed and enabled
393
394         * src/pic16/devices.inc,
395         * device/include/pic16/pic18f2423.h,
396         * device/include/pic16/pic18f2523.h,
397         * device/include/pic16/pic18fregs.h,
398         * device/lib/pic16/pics.all
399         * device/lib/pic16/libdev/pic18f2423.c,
400         * device/lib/pic16/libdev/pic18f2523.c: added 18f2423 and 18f2523
401         * device/lib/pic16/libio/i2c.ignore,
402         * device/lib/pic16/libio/usart.ignore,
403         * device/lib/pic16/libio/adc.ignore: ignore new devices
404
405 2008-01-23 Maarten Brock <sourceforge.brock AT dse.nl>
406
407         * src/SDCCast.c (createRMW): fixed bug 1582651
408
409 2008-01-20 Borut Razem <borut.razem AT siol.net>
410
411         * src/SDCCcse.c: partially fixed enhancement request
412           #1793872 - multiply by -1 not collapsed
413         * support/regression/tests/arithcsi.c: added regression test
414
415 2008-01-19 Maarten Brock <sourceforge.brock AT dse.nl>
416
417         * as/mcs51/asx8051.dsp: removed define SDK
418         * as/mcs51/i51mch.c (machine): fixed bug 1865114
419         * device/include/asm/ds390/features.h: fixed bug with ds390 & stack-auto
420         * as/link/lklex.c,
421         * as/link/mcs51/lkmain.c: used LKDIRSEP, LKDIRSEPSTR and LKOBJEXT,
422           cosmetic changes, brought more in sync, changed old K&R to ANSI
423
424 2008-01-13 Borut Razem <borut.razem AT siol.net>
425
426         * support/scripts/sdcc.nsi: added Uninstall/reinstall page, ...
427         * src/SDCCicode.c: fixed bug #1870216 - Error 122: dividing by zero
428
429 2007-12-30 Borut Razem <borut.razem AT siol.net>
430
431         * src/pic16/gen.c: fixed implementation of bitwise operations for
432           pic16 target
433         * support/regression/tests/bitwise.c: added test cases
434
435 2007-12-29 Borut Razem <borut.razem AT siol.net>
436
437         * src/SDCCasm.[ch]: renamed from asm[ch], use dbuf_getline(), ...
438         * src/src.dsp, src/Makefile.bcc, src/Makefile.in, src/common.h,
439           src/SDCCglue.c, src/xa51/main.c: asm.[ch] renamed to SDCCasm.[ch]
440         * support/Util/dbuf_string.[ch]: added function dbuf_getline()
441         * src/ds390/gen.c, src/hc08/gen.c, src/mcs51/gen.c, src/pic16/gen.c,
442           src/pic/gen.c, src/z80/gen.c, src/xa51/gen.c, src/pic16/ralloc.c,
443           src/pic16/pcode.[ch]: added const qualifier
444         * as/hc08/Makefile.bcc, as/hc08/Makefile.in, as/hc08/as_hc08.dsp,
445           as/mcs51/Makefile.bcc, as/mcs51/Makefile.in, as/mcs51/asx8051.dsp,
446           as/z80/Makefile.bcc, as/z80/Makefile.in, as/z80/as_gbz80.dsp,
447           as/z80/as_z80.dsp: added dbuf.[ch] and dbuf_string[ch] to project
448         * as/asxxsrc/aslex.c: use dbuf_getline()
449         * as/hc08/asdata.c, as/hc08/asexpr.c, as/hc08/asm.h, as/hc08/m08adr.c,
450           as/mcs51/asdata.c, as/mcs51/asexpr.c, as/mcs51/asm.h,
451           as/mcs51/i51adr.c, as/z80/asdata.c, as/z80/asexpr.c, as/z80/aslist.c,
452           as/z80/asm.h, as/z80/z80adr.c:
453           changed type of ib and ip to const char *
454
455 2007-12-28 Borut Razem <borut.razem AT siol.net>
456
457         * as/asxxsrc/aslex.c: moved from as/mcs51/aslex.c;
458           introduced (readlin) - long lines are turuncated
459         * as/hc08/as_hc08.dsp, as/mcs51/asx8051.dsp, as/z80/as_gbz80.dsp,
460           as/z80/as_z80.dsp, as/hc08/Makefile.in, as/mcs51/Makefile.in,
461           as/z80/Makefile.in: moved aslex.c to asxxsrc
462         * as/hc08/aslex.c, as/z80/aslex.c: deleted
463         * as/hc08/asmain.c, as/mcs51/asmain.c:
464           added missing initialization of a_addr field
465         * support/regression/tests/long_asm_line.c: added regtest for long
466           assembler line
467
468 2007-12-22 Borut Razem <borut.razem AT siol.net>
469
470         * src/SDCC.lex: fixed bug #1852894: # character hangs the compiler
471
472 2007-12-20 Maarten Brock <sourceforge.brock AT dse.nl>
473
474         * src/SDCCsymt.c (computeType): fixed bug, thanks Fan Weiguang
475
476 2007-12-16 Borut Razem <borut.razem AT siol.net>
477
478         * device/include/pic16/stdbool.h: removed, since already exists in
479          device/include/; this also fixes bitopcse.c regression test for pic16
480          target
481         * support/regression/fwk/inclusw/testfwk.h: added macro ASSERT_FAILED
482         * src/pic16/glue.c: fixed bug #1851855: generic static pointer
483           dereference doesn't work; covered by regression test bug1399290
484
485 2007-12-05 Borut Razem <borut.razem AT siol.net>
486
487         * doc/sdccman.lyx: fixed bug #1844509 - Correction to Manual 4.6.9
488           Adding new PIC16
489
490 2007-12-01 Borut Razem <borut.razem AT siol.net>
491
492         * sim/ucsim/cmd.src/cmdmem.cc, sim/ucsim/cmd.src/mem.cc:
493           corrected handling of the highest_valid_address
494
495 2007-11-17 Raphael Neider <rneider AT web.de>
496
497         * src/pic/main.c (_asmCmd): include debug arguments (-g as $3)
498         * src/pic/glue.c (picglue): emit .file if --debug is given
499
500 2007-11-17 Raphael Neider <rneider AT web.de>
501
502         * src/pic16/genarith.c (pic16_genPlus, pic16_genMinus): take special
503         care when left or right operand resides in result, fixes #1830220
504
505 2007-11-17 Borut Razem <borut.razem AT siol.net>
506
507         * src/SDCCglue.c, src/pic16/glue.c: reverted fix for bug
508           #983491 - "Merge duplicate strings function is ineffective"
509         * support/regression/tests/bug-983491.c: regtest disabled
510         * as/asxxsrc: created
511           as/asxxsrc/assym.c, as/asxxsrc/strcmpi.c: moved
512           as/hc08/assym.c, as/mcs51/assym.c, as/strcmpi.c,
513           as/z80/assym.c, as/hc08/asstore.c, as/mcs51/asstore.c: deleted
514           as/hc08/Makefile.bcc, as/hc08/Makefile.in, as/hc08/as_hc08.dsp,
515           as/hc08/asm.h, as/link/hc08/Makefile.bcc, as/link/hc08/Makefile.in,
516           as/link/hc08/link_hc08.dsp, as/link/mcs51/Makefile.bcc,
517           as/link/mcs51/Makefile.in, as/link/mcs51/aslink.dsp,
518           as/link/z80/Makefile.in, as/link/z80/linkgbz80.dsp,
519           as/link/z80/linkz80.dsp, as/mcs51/Makefile.bcc, as/mcs51/Makefile.in,
520           as/mcs51/asm.h, as/mcs51/asx8051.dsp, as/z80/Makefile.bcc,
521           as/z80/Makefile.in, as/z80/as_gbz80.dsp, as/z80/as_z80.dsp,
522           as/z80/Makefile.as_hc08, as/mcs51/Makefile.asx8051: modified
523           created as/asxxsrc directory, assym.c and strcpi.c moved into it
524
525 2007-11-15 Maarten Brock <sourceforge.brock AT dse.nl>
526
527         * device/include/stdarg.h: added and removed some casts
528         * src/SDCCsymt.c (compareType): Fully check types between generic and
529           non-generic pointers, also accept ptr-ptr to void-ptr assignments
530
531 2007-11-13 Borut Razem <borut.razem AT siol.net>
532
533         * support/regression/tests/bug-1817005.c:
534           added regtest for bug #1817005 - as-z80 chokes on long labels
535
536 2007-11-12 Borut Razem <borut.razem AT siol.net>
537
538         * as\z80\asmain.c, as\z80\asm.h, as\z80\assym.c, as\z80\asdata.c,
539           as\z80\asout.c, as\z80\aslist.c:
540           fixed bug #1817005 - as-z80 chokes on long labels
541
542 2007-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
543
544         * as/hc08/asmain.c,
545         * as/z80/asmain.c: cosmetic changes
546         * as/hc08/alloc.h,
547         * as/mcs51/alloc.h,
548         * as/z80/alloc.h: removed
549         * as/hc08/assym.c,
550         * as/mcs51/assym.c: replaced alloc.h with stdlib.h
551         * as/link/aslink.h: added LKDIRSEP and, LKDIRSEPSTR
552         * as/link/hc08/Makefile.in,
553         * as/link/mcs51/Makefile.in,
554         * as/link/z80/Makefile.in: added -DUNIX to CFLAGS
555         * as/link/lklex.c,
556         * as/link/mcs51/lkarea.c,
557         * as/link/mcs51/lkmain.c: cosmetic changes
558         * as/link/hc08/lklibr.c,
559         * as/link/z80/lklibr.c,
560         * as/link/mcs51/lklibr.c: used LKDIRSEP, LKDIRSEPSTR and LKOBJEXT,
561           used cygwin_conv_to_full_posix_path,
562           added warnings, cosmetic changes, brought more in sync
563           changed old K&R into ANSI function declarations
564         * as/link/z80/lklibr.c (loadAdb): added
565         * as/link/z80/lkmain.c: removed -- option from usage text
566
567 2007-11-03 Maarten Brock <sourceforge.brock AT dse.nl>
568
569         * src/mcs51/gen.c (outBitC): optimized for no result
570
571 2007-10-31 Borut Razem <borut.razem AT siol.net>
572
573         * src/SDCCsymt.c: fixed (hopeful properly) bug
574           #1805702 - order of extern matters
575         * support/regression/tests/bug-1805702.c: enabled regtest for bug
576           #1805702
577
578 2007-10-29 Borut Razem <borut.razem AT siol.net>
579
580         * src/SDCCsymt.c: reverted bad fixed of bug #1805702
581           - order of extern matters
582         * support/regression/tests/bug-1805702.c: disabled regtest for bug
583           #1805702
584
585 2007-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
586
587         * src/ds390/peeph.def: replaced 24bitModeAndPortDS390 by
588           24bitMode, portIsDS390
589         * src/mcs51/gen.c (genOr): optimized for RFE 1750727
590         * src/SDCCpeeph.c (flat24bitModeAndPortDS390): removed
591           (notVolatileVariable): also check sloc names,
592           (callFuncByName): moved ftab[] out of function and sorted it by use
593
594 2007-10-28 Maarten Brock <sourceforge.brock AT dse.nl>
595
596         * device/include/stdarg.h: fixed bug in va_start macro for --xstack
597         * src/hc08/gen.c (aopForRemat): aop->aopu.aop_immd.from_cast_remat not set,
598           aop->aopu.aop_immd.aop_immd2 not filled with (generic) pointer type
599         * src/SDCCicode.c (geniCodeCast): fixed bug 880197
600         * support/regression/tests/bug-880197.c: new, added
601
602 2007-10-28 Borut Razem <borut.razem AT siol.net>
603
604         * support/regression/Makefile.in,
605           support/regression/ports/mcs51-large/spec.mk,
606           support/regression/ports/mcs51-xstack-auto/spec.mk,
607           support/regression/ports/mcs51-stack-auto/spec.mk,
608           support/regression/ports/mcs51-medium/spec.mk,
609           support/regression/ports/mcs51-common/spec.mk,
610           support/regression/ports/mcs51-common/*,
611           support/regression/ports/mcs51-small/*:
612           mcs51 renamed to mcs51-common, created mcs51-small
613         * src/SDCCsymt.c: fixed bug #1805702 - order of extern matters
614         * support/regression/tests/bug-1805702.c: added regtest for bug
615           #1805702
616
617 2007-10-26 Maarten Brock <sourceforge.brock AT dse.nl>
618
619         * src/mcs51/peeph.def: moved rules 257.x to 253.x and re-enabled 253.b,
620           added new rules 265 - 270
621         * support/regression/tests/bug1721024.c:new, added
622         * support/regression/Makefile.in: renamed test-mcs51 to test-mcs51-small,
623           introduced new test-mcs51 to run all mcs51 tests
624
625 2007-10-25 Maarten Brock <sourceforge.brock AT dse.nl>
626
627         * support/regression/tests/bug1816470.c: new, added
628
629 2007-10-21 Maarten Brock <sourceforge.brock AT dse.nl>
630
631         * src/SDCCast.c (resultTypePropagate): do propagate for LEFT_OP, do not
632           propagate for *,+,- with float, fixed bug 1816470
633           (decorateType): cast to resultTypeProp instead of resultType
634
635 2007-10-19 Borut Razem <borut.razem AT siol.net>
636
637         * src/pic16/glue.c: fixed bug #983491 - "Merge duplicate strings
638           function is ineffective" for pic16 tareget
639         * support/scripts/listerr.c: corrected include path
640         * device/lib/_itoa.c: fixed bug #1806402 - _itoa and _uitoa leak to
641           adjacent memory
642
643 2007-10-18 Maarten Brock <sourceforge.brock AT dse.nl>
644
645         * support/regression/tests/using.c: new, added
646         * support/regression/tests/vaargs.c: fixed and enabled test
647
648 2007-10-18 Borut Razem <borut.razem AT siol.net>
649
650         * src/SDCCglue.c: fixed bug #983491 - Merge duplicate strings function
651           is ineffective
652         * support/regression/tests/bug-983491.c: added regtest for bug #983491
653
654 2007-10-18 Maarten Brock <sourceforge.brock AT dse.nl>
655
656         * doc/sdccman.lyx: documented option --Werror
657         * src/SDCCsymt.c (checkFunction): fixed bug 1815418 by setting
658           RegBankUsed[] earlier
659
660 2007-10-14 Maarten Brock <sourceforge.brock AT dse.nl>
661
662         * device/include/mcs51/p89lpc938.h: new, added, thanks Kyle Guinn
663         * src/pic/glue.c,
664         * src/SDCCval.c,
665         * src/SDCCast.c,
666         * src/SDCCast.h: replaced AST_LIT_VALUE with AST_FLOAT_VALUE and
667           AST_ULONG_VALUE
668         * src/SDCCast.c (decorateType): improved optimization of tri-op
669         * src/SDCCerr.c (vwerror, setWError),
670         * src/SDCCerr.h,
671         * src/SDCCmain.c (parseCmdLine): added option --Werror to treat all
672           warnings as errors, thanks Stas Sergeev for PATCH 1813211
673
674 2007-10-13 Maarten Brock <sourceforge.brock AT dse.nl>
675
676         * src/mcs51/gen.c (leftRightUseAcc): use macro IS_OP_ACCUSE
677         * src/SDCCast.c (decorateType): optimize bit=cond?1:0, RFE 1738430
678         * support/regression/tests/bug-223113.c,
679         * support/regression/tests/bug-426632.c,
680         * support/regression/tests/bug-468811.c,
681         * support/regression/tests/bug-477835.c,
682         * support/regression/tests/bug-478094.c,
683         * support/regression/tests/bug-499644.c,
684         * support/regression/tests/bug-524209.c,
685         * support/regression/tests/bug-524211.c,
686         * support/regression/tests/packcast.c,
687         * support/regression/tests/structidx.c: added empty tests
688         * support/regression/tests/bug-607243.c: enabled test
689
690 2007-10-06 Borut Razem <borut.razem AT siol.net>
691
692         * .version, doc/sdccman.lyx: bumped version to 2.7.4 to indicate the full
693            support of universal binaries on Mac OS X
694
695 2007-10-02 Borut Razem <borut.razem AT siol.net>
696
697         * src/SDCCval.h: unified double2ul macro for all platforms
698         * src/SDCCval.c: fixed bug #1777758 - applied Maarten's patch
699         * support/regression/tests/bitwise.c: added regtest for bug #1777758
700
701 2007-09-30 Borut Razem <borut.razem AT siol.net>
702
703         * src/SDCCval.h: fixed bug #1739860 - sdcc does not work correctly on some
704           platforms
705         * sdcc_vc_in.h: enabled warnings
706         * src/hc08/gen.c: fixed MSVC warning C4146: unary minus operator applied to
707           unsigned type, result still unsigned
708         * src/mcs51/peep.c: fixed gcc warning: suggest parentheses around && within ||
709
710 2007-09-28 Raphael Neider <rneider AT web.de>
711
712         * src/pic/device.c (find_device): prevent buffer underflow error
713         * src/pic/pcoderegs.c (OptimizeRegUsage): avoid dereferencing
714           the just destroyed list entry
715
716 2007-09-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
717
718         * doc/sdccman.lyx: there's a dedicated wiki page for cmake and sdcc, thanks
719           Alexander Neundorf
720
721 2007-09-18 Borut Razem <borut.razem AT siol.net>
722
723         * src/SDCCval.c: fixed MSVC warning C4146: unary minus operator
724          applied to unsigned type, result still unsigned
725
726 2007-09-17 Borut Razem <borut.razem AT siol.net>
727
728         * src/SDCC.y, src/SDCCast.c, src/SDCCcse.c, src/SDCCglue.c,
729           src/SDCCicode.c, src/SDCCopt.c, src/SDCCsymt.c, src/SDCCval.c,
730           src/SDCCval.h, src/hc08/gen.c, src/avr/gen.c, src/ds390/gen.c,
731           src/mcs51/gen.c, src/pic/gen.c, src/pic/genarith.c, src/pic/glue.c,
732           src/pic/ralloc.c, src/pic16/gen.c, src/pic16/genarith.c,
733           src/pic16/genutils.c, src/pic16/glue.c, src/pic16/main.c,
734           src/z80/gen.c, src/z80/ralloc.c:
735           fixed bug #1739860 - sdcc does not work correctly on some platforms
736           (not finished)
737           introduced and used ulFromVal(), double2ul(), used strtod() instead sscanf()
738
739 2007-09-17 Raphael Neider <rneider AT web.de>
740
741         * src/pic16/device.c: reverted to previous version
742         * device/lib/pic16/Makefile.common.in: quieten gpasm via -Wa,-q
743
744 2007-09-16 Raphael Neider <rneider AT web.de>
745
746         * src/pic16/device.c (pic16_dump_usection): do not reserve 0 bytes,
747           as this raises a ton of gpasm warnings, just emit a second label
748         * src/pic16/devices.inc,
749         * device/lib/pic16/pics.all,
750         * device/lib/pic16/libdev/pic18f2585.c,
751         * device/lib/pic16/libdev/pic18f2680.c,
752         * device/lib/pic16/libdev/pic18f2682.c,
753         * device/lib/pic16/libdev/pic18f2685.c,
754         * device/lib/pic16/libdev/pic18f4585.c,
755         * device/lib/pic16/libdev/pic18f4680.c,
756         * device/lib/pic16/libdev/pic18f4682.c,
757         * device/lib/pic16/libdev/pic18f4685.c,
758         * device/include/pic16/pic18f2585.h,
759         * device/include/pic16/pic18f2680.h,
760         * device/include/pic16/pic18f2682.h,
761         * device/include/pic16/pic18f2685.h,
762         * device/include/pic16/pic18f4585.h,
763         * device/include/pic16/pic18f4680.h,
764         * device/include/pic16/pic18f4682.h,
765         * device/include/pic16/pic18f4685.h,
766         * device/include/pic16/pic18fregs.h: added 18f2585, 18f2680,
767           18f2682, 18f2685, 18f4585, 18f4680, 18f4682, 18f4685,
768           patch contributed by Anton Strobl, applied with changes
769
770 2007-09-16 Raphael Neider <rneider AT web.de>
771
772         * device/include/pic16/pic18f2431.h,
773         * device/include/pic16/pic18f25j10.h,
774         * device/include/pic16/pic18f4431.h,
775         * device/include/pic16/pic18f45j10.h: adopted common include style
776         * device/include/pic16/pic18f1320.h,
777         * device/include/pic16/pic18f2320.h,
778         * device/include/pic16/pic18f2525.h,
779         * device/include/pic16/pic18f4320.h,
780         * device/include/pic16/pic18f4525.h: NEW, just include proper .h file
781         * device/include/pic16/pic18fregs.h: prepared for automatic include
782           file selection by having DEVICE.h for every DEVICE
783         * device/lib/pic16/libdev/pic18f2320.c,
784         * device/lib/pic16/libdev/pic18f4320.c: just include proper .c file
785
786         * device/lib/pic16/configure.in,
787         * device/lib/pic16/configure: use rm -rf instead of rmdir
788         * device/lib/pic16/Makefile.in: use RMDIR to remove build directories
789         * device/lib/pic16/libc/stdlib/free.c: avoid warning on pointer cast
790
791 2007-09-09 Borut Razem <borut.razem AT siol.net>
792
793         * src/SDCCmain.c, src/SDCCutil.c: print newline after printVersionInfo(),
794           distingush between i386 and ppc Mac OS X versions
795
796 2007-09-05 Maarten Brock <sourceforge.brock AT dse.nl>
797
798         * src/mcs51/gen.c (genReceive): fixed bug 1788177
799         * support/regression/tests/bug1788177.c: new, added
800
801 2007-09-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
802
803         * doc/sdccman.lyx: mentioned d52 and cmake, customizing startup code
804         * device/include/mcs51/lint.h added keyword __naked
805
806 2007-09-04 Maarten Brock <sourceforge.brock AT dse.nl>
807
808         * src/pic16/glue.c,
809         * src/pic/glue.c,
810         * src/SDCCmem.h: removed maxRegBank
811         * src/SDCCmem.c (allocVariables): removed maxRegBank and moved setting
812           RegBankUsed[] to checkFunction() in SDCCsymt.c to fix bug 1759839
813         * src/SDCCsymt.c (checkFunction): set RegBankUsed[] here
814         * src/mcs51/peep.c (isCallerSaveFunc, termScanAtFunc): changed function
815           name and behaviour to handle banked functions
816           (scan4op): and use it to fix bug 1786213
817
818 2007-09-03 Raphael Neider <rneider AT web.de>
819
820         * device/include/pic16/pic18f248.h,
821         * device/include/pic16/pic18f258.h,
822         * device/include/pic16/pic18f448.h,
823         * device/lib/pic16/libdev/pic18f248.c,
824         * device/lib/pic16/libdev/pic18f258.c,
825         * device/lib/pic16/libdev/pic18f448.c: fixed TRISEbits,
826           added T0CONbits, fixes #1786891
827
828 2007-08-29 Maarten Brock <sourceforge.brock AT dse.nl>
829
830         * src/ds390/gen.c (genFarPointerSet),
831         * src/hc08/ralloc.c (packRegisters),
832         * src/mcs51/ralloc.c (packRegisters),
833         * src/SDCCcse.c (cseBBlock): check if result is a symbol first to fix
834           bug 1750318
835         * src/SDCCicode.h: POINTER_SET can be true for literals too
836         * support/regression/tests/bug1750318.c: new, added
837
838 2007-08-23 Borut Razem <borut.razem AT siol.net>
839
840         * debugger/mcs51/sdcdb.c: fixed compilation with older readline
841           library versions without the completition functionality
842
843 2007-08-22 Raphael Neider <rneider AT web.de>
844
845         * device/include/pic16/pic18f1220.h,
846         * device/lib/pic16/libdev/pic18f1220.c: applied patch #1776191
847
848 2007-08-12 Borut Razem <borut.razem AT siol.net>
849
850         * debugger/mcs51/Makefile.in: support/Util/SDCCerr.[ch] moved to src
851
852 2007-08-11 Borut Razem <borut.razem AT siol.net>
853
854         * support/Util/SDCCerr.c, support/Util/SDCCerr.h, src/src.dsp,
855           src/Makefile.in, src/Makefile.bcc, support/scripts/listerr.c:
856           support/Util/SDCCerr.[ch] moved to src
857         * as/hc08/as_hc08.dsp, as/link/hc08/link_hc08.dsp,
858           as/link/z80/linkgbz80.dsp, as/link/z80/linkz80.dsp,
859           device/examples/ds390/tinitalk/tinitalk.dsp,
860           device/examples/serialcomm/windows/serialcomm.dsp,
861           support/librarian/librarian.dsp:
862           removed linking of unused odbc32.lib and odbccp32.lib
863         * support/scripts/winres.h:
864           added for compilation with Visual C++ 2005 Express Edition
865
866 2007-08-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
867
868         * device/include/mcs51/at89c51ed.h: Fixed typo in declarations of CKCON0
869           and CKCON1.
870
871 2007-08-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
872
873         * sdccconf_in.h: update the endian test so that SPARC Solaris
874           does not throw syntax errors
875
876 2007-08-06 Borut Razem <borut.razem AT siol.net>
877
878         * doc/sdccman.lyx: removed two index entries which prevented the
879           generation of sdcc doc archive
880
881 2007-08-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
882
883         * doc/sdccman.lyx: Same changes made 2007-07-28 but using lyx 1.4.4
884           instead of lyx 1.5.0.
885
886 2007-07-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
887
888         * device/include/hc08/mc68hc908apxx.h: new header contributed by
889           Lucas Loizaga, with minor modifications. Thanks!
890
891 2007-07-28 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
892
893         * doc/sdccman.lyx: Documented --acall-ajmp and described new features
894           in sdcclib.
895
896 2007-07-28 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
897
898         * src/SDCCglobl.h, src/SDCCpeeph.c, src/SDCCglue.c, src/mcs51/main.c,
899           src/mcs51/peeph.def: Added option --acall-ajmp: replaces lcall/ljmp
900           with acall/ajmp.
901
902 2007-07-22 Borut Razem <borut.razem AT siol.net>
903
904         * configure.in, configure: re-introduced .version
905         * sdcc.spec, doc/INSTALL.txt: they are used only for releases;
906           the version reverted to 2.7.0
907
908 2007-07-18 Maarten Brock <sourceforge.brock AT dse.nl>
909
910         * configure.in,
911         * doc/sdccman.lyx: bumped version to 2.7.3
912         * device/include/mcs51/compiler.h: fixed elif->else
913         * src/mcs51/gen.c (genAnd, genOr): handle accuse for pure bit operands
914         * src/mcs51/ralloc.c (createStackSpil): fixed SCLS bug with sloc for sbit,
915           (operandUsesAcc, packRegsForAccUse): added parameter allowBitspace to
916            enable accuse for bit operands
917         * src/SDCCmain.c (printVersionInfo),
918         * src/SDCCutil.c (getBuildEnvironment): factored out creation of build
919           environment descriptor
920         * src/SDCCutil.h: added getBuildEnvironment
921         * src/SDCCglue.c (initialComments): use getBuildEnvironment
922         * support/regression/tests/bug1464657.c: enabled test test_Peephole251
923         * support/regression/tests/bug-408972.c: enabled test leftShiftLong
924         * support/regression/tests/bug1348008.c,
925         * support/regression/tests/bug1496419.c,
926         * support/regression/tests/bug1503067.c,
927         * support/regression/tests/preproc.c: added empty tests
928
929 2007-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
930
931         * support/regression/tests/bug1678803.c: new, added
932
933 2007-07-14 Maarten Brock <sourceforge.brock AT dse.nl>
934
935         * as/link/aslink.h,
936         * as/link/hc08/lkihx.c,
937         * as/link/hc08/lkrloc.c,
938         * as/link/mcs51/lkihx.c,
939         * as/link/mcs51/lkrloc.c: renamed ihxEntendedLinearAddress to
940           ihxExtendedLinearAddress
941         * as/link/mcs51/lkrloc.c (relr),
942         * as/mcs51/asout.c (outr11, outr19): handle absolute destination for
943           acall/ajmp, see bug 830513
944
945 2007-07-13 Maarten Brock <sourceforge.brock AT dse.nl>
946
947         * src/SDCCcse.c (replaceAllSymBySym): renamed siaddr to isaddr,
948           (cseBBlock): remember aggr2ptr has been used
949         * src/SDCCicode.c (operandSize): added function to handle aggr2ptr,
950           (geniCodeAssign): fixed bug 868103
951         * src/SDCCicode.h: made operand.aggr2ptr 2 bits wide,
952           added operandSize prototype
953         * src/mcs51/gen.c (aopOp): use operandSize to fix bug 868103,
954           (genDataPointerSet): use max of size of right and result,
955           (gencjne): added parameter useCarry for optimization,
956           (genCmpEq): use carry if appropriate,
957           (genXor): check if operand already in carry
958         * support/regression/tests/bug-868103.c: enabled test
959
960 2007-07-12 Raphael Neider <rneider AT web.de>
961
962         * src/pic16/gen.c (genNearPointerSet): fixed handling of literals
963
964 2007-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
965
966         * src/SDCCsymt.c (compareType): fixed bugs 1738367 and 1745717 with patch
967           from Robert Larice, thanks
968         * support/regression/tests/bitopcse.c,
969         * support/regression/tests/bitvars.c,
970         * support/regression/tests/bug-908454.c: use <stdbool.h> for the bit types
971         * support/regression/tests/bug-927659.c: enabled test for z80
972         * support/regression/tests/bug1738367.c: added extra tests by Frieder
973         * support/regression/tests/bug1745717.c: new, added
974         * support/regression/tests/literalop.c,
975         * support/regression/tests/nullstring.c: removed storage definitions that
976           are now in testfwk.h
977
978 2007-07-10 Maarten Brock <sourceforge.brock AT dse.nl>
979
980         * device/include/stdbool.h: do not define __bool_true_false_are_defined
981           and bool for targets that do not fully support it.
982         * support/regression/tests/bug1546986.c,
983         * support/regression/tests/bug1723128.c,
984         * support/regression/tests/bug1734654.c,
985         * support/regression/tests/bug1738367.c,
986         * support/regression/tests/constantRange.c: only use bool if allowed
987
988 2007-07-09 Maarten Brock <sourceforge.brock AT dse.nl>
989
990         * src/mcs51/peep.c (isCallerSaveFunc): fixed bug 1749275, thanks Robert
991           Larice, also handle function pointers
992         * support/regression/tests/bug1749275.c: new, added
993
994 2007-07-03 Borut Razem <borut.razem AT siol.net>
995
996         * src/mcs51/gen.c, src/avr/gen.c, src/pic/gen.c, src/z80/gen.c,
997           src/pic16/gen.c, src/hc08/gen.c, src/ds390/gen.c: fixed RFE
998           #1746528: SDCC should ignore ':' in inline assembler comments
999         * device/include/typeof.h: fixed bug #1747142: typeof.h needs fixing
1000
1001 2007-07-02 Maarten Brock <sourceforge.brock AT dse.nl>
1002
1003         * device/include/mcs51/C8051F360.h: fixed bug #1746410, thanks Chris Jones
1004         * device/lib/mcs51/crtxclear.asm: do not set __XPAGE unconditionally
1005
1006 2007-06-29 Borut Razem <borut.razem AT siol.net>
1007
1008         * src/SDCCmain.c: fixed bug
1009           #1744746: SDCC #4867: broken option --xram-size
1010
1011 2007-06-28 Borut Razem <borut.razem AT siol.net>
1012
1013         * sim/ucsim/configure.in, sim/ucsim/configure, sim/ucsim/ddconfig_in.h:
1014           find out the endianess of host machine for ucsim
1015
1016 2007-06-27 Borut Razem <borut.razem AT siol.net>
1017
1018         * support/regression/generate-cases.py: corrected the file name
1019           in warning
1020         * configure.in, configure, sdccconf_in.h: find out the endianess of
1021           host machine
1022         * src/SDCC.y: fixed bug #1744146: Crash when compiling array of
1023           negative size
1024
1025 2007-06-27 Gudjon I. Gudjonsson <gudjon AT gudjon.org>
1026
1027         * device/include/mcs51/p89c66x.h: NXP header file, OK to change licence
1028
1029 2007-06-26 Borut Razem <borut.razem AT siol.net>
1030
1031         * support/regression/generate-cases.py: display warning if function
1032           list is empty; implemented more flexible rule for detection of
1033           testing functions, allowing return type 'void' in the same line as
1034           the function name in the function definition
1035         * support/regression/tests/bug-1654060.c: corrected test
1036         * support/librarian/sdcclib.c: fixed warning:
1037           format '%s' expects type 'char *', but argument 2 has type 'int'
1038
1039 2007-06-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1040
1041         * support/librarian/sdcclib.c: Added feature Requests [1510635]
1042           Multiple infiles for sdcclib.
1043
1044 2007-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1045
1046         * src/SDCCast.c (inlineFindMaxBlockno, createFunction): fixed
1047           bug 1731741
1048
1049 2007-06-18 Borut Razem <borut.razem AT siol.net>
1050
1051         * src/SDCCmain.c: removed option -C since SDCC compiler doesn't know
1052           how to handle comments, so they have to be removed by the
1053           preprocessor; fixed bug #1738926:SDCC #4852: broken option -V
1054         * src/SDCCmain.c, src/SDCCargs.h, src/ds390/main.c, src/mcs15/main.c,
1055           src/pic16/main.c, src/pic/main.c, src/z80/main.c,
1056           support/Util/SDCCerr.c, support/Util/SDCCerr.h:
1057           table driven option hadling
1058
1059 2007-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
1060
1061         * src/SDCCast.c (decorateType),
1062         * src/SDCCicode.c (geniCodeConditional): moved optimization for '?' from
1063           iCode to ast level to fix bug 1738367
1064         * support/regression/tests/bug1738367.c: new, added
1065
1066 2007-06-15 Raphael Neider <rneider AT web.de>
1067
1068         * src/pic16/devices.inc,
1069         * device/lib/pic16/pics.all,
1070         * device/include/pic16/pic18fregs.h,
1071         * device/include/pic16/pic18f[24][45]20.h,
1072         * device/lib/pic16/libdev/pic18f[24][45]20.c: added support for
1073           18f2420, 18f2520, and 18f4420 devices, updated 18f4520 definitions
1074         * device/lib/pic16/Makefile.in: faster cleanup
1075
1076 2007-06-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1077
1078         * src/mcs51/peeph.def: added 177.i (mov from a is slightly cheaper)
1079
1080 2007-06-13 Raphael Neider <rneider AT web.de>
1081
1082         * src/SDCCmain.c: prevent NULL pointer dereference, avoid warning
1083
1084 2007-06-12 Raphael Neider <rneider AT web.de>
1085
1086         * support/scripts/inc2h.pl: conditionally emit defines for SFR bits,
1087           suppress bit defines if NO_BIT_DEFINES is #define'd
1088         * device/include/pic/pic*.h: recreated all headers to include
1089           conditional bit defines
1090         * device/include/pic/pic16f886.h,
1091         * device/include/pic/pic16f887.h: fixed based on newer .inc file
1092         * device/include/pic/recreate.sh: script to recreate the complete
1093           device library files based on the currently supported devices
1094
1095 2007-06-12 Borut Razem <borut.razem AT siol.net>
1096
1097         * src/pic16/main.c, src/SDCCargs.h, SDCCmain.c,
1098           support/regression/Makefile.in, support/scripts/build.mak,
1099           support/scripts/Makefile.snapshot:
1100           use new svn URL scheme
1101         * doc/sdccman.lyx: SDCC Wiki moved to
1102           http://sdcc.wiki.sourceforge.net/
1103
1104 2007-06-10 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1105
1106         * src/mcs51/peeph.def: disabled rule 132.d to fix #1734654
1107         * support/regression/tests/bug1734654.c: added
1108
1109 2007-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
1110
1111         * src/SDCCast.c (decorateType): optimized '?' for equal operands
1112         * src/SDCCicode.c (geniCodeConditional): optimization for bit result
1113           with literal operands
1114
1115 2007-06-10 Borut Razem <borut.razem AT siol.net>
1116
1117         * as/link/z80/lklibr.c: fixed mingw build warning
1118           lklibr.c:575: warning: implicit declaration of function 'tolower'
1119         * src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c,
1120           src/z80/main.c: move target specific options from src/SDCCmain.c
1121           to src/<target>/main.c
1122
1123 2007-06-09 Borut Razem <borut.razem AT siol.net>
1124
1125         * src/z80/gen.c: fixed bug #1294691: nested ifs make compiler crash;
1126           removed unused swap_sense; removed outBitCLong, replaced with outBitC
1127         * support/regression/tests/bug-1294691.c: added
1128
1129 2007-06-09 Maarten Brock <sourceforge.brock AT dse.nl>
1130
1131         * src/SDCCmem.c (allocDefault): removed check sym->level==0 for SPEC_ABSA,
1132           can also be static, fixes bug 1733438
1133         * src/SDCCsymt.c (checkSClass): static local vars in reentrant funcs can
1134           have absolute address too
1135           (computeType): added optimization for 'cond ? true : false'
1136         * support/regression/tests/absolute.c: added test for static absolute var
1137
1138 2007-06-08 Raphael Neider <rneider AT web.de>
1139
1140         * src/regression/Makefile: suppress parallel builds, allow easy
1141           switching between pic14/pic16 ports
1142         * src/regression/picregs.h: added pic14/16 header file switch
1143         * src/regression/{compare7.c,compare8.c,compare9.c,compare10.c,
1144           inline.c,nestfor.c,string1.c}: include "picregs.h"
1145
1146 2007-06-07 Borut Razem <borut.razem AT siol.net>
1147
1148         * sim/ucsim/*.[ch], sim/ucsim/configure, sim/ucsim/configure.in:
1149           permanent solution to suppress GCC 4.2.0 c++ warning:
1150           deprecated conversion from string constant to `char *'
1151           use 'const char *' where ever required
1152         * support/regression/generate-cases.py: implemented more flexible rule
1153           for detection of testing functions, allowing white-spaces surrounding
1154           the function name and the 'void' parameter.
1155         * support/regression/tests/constantRange.c,
1156           support/regression/tests/scott-compare3.c: fixed failing regression
1157           tests, uncovered by implementation of more flexible rule for detection
1158           of testing functions
1159
1160 2007-06-04 Maarten Brock <sourceforge.brock AT dse.nl>
1161
1162         * src/SDCCast.c(decorateType): better optimize '!!' and comparisons
1163
1164 2007-06-04 Borut Razem <borut.razem AT siol.net>
1165
1166         * configure.in, configure, config_vc.awk: sdcc version number is now
1167           stored in configure.in; removed .version
1168         * configure.in, configure, sdcc.spec, doc/sdccman.lyx, doc/sdccman.lyx,
1169           doc/INSTALL.txt: version bumped to 2.7.2
1170         * sim/ucsim/configure.in, sim/ucsim/configure:
1171           use "read" to read from .version
1172
1173 2007-06-03 Borut Razem <borut.razem AT siol.net>
1174
1175         * */Makefile.in: removed annoying warning:
1176           Makefile:xx: Makefile.dep: No such file or directory
1177
1178 2007-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
1179
1180         * src/mcs51/gen.c (outBitC, genRet): used IS_OP_RUONLY,
1181           (genNot, genXor): used toCarry, also fixes a bug for c = bit ^ val
1182         * src/mcs51/ralloc.c: removed IS_OP_RUONLY + some cosmetic changes
1183         * src/SDCCast.c (resultTypePropagate): propagate for '!',
1184           (decorateType): also optimize comparisons with RESULT_TYPE_BIT,
1185           bugfix: only use newBoolLink for bit result type
1186         * src/SDCCicode.c (geniCodeLogic): added param tree,
1187           bugfix: use newBoolLink if tree is bit type, bug appears when ruonly,
1188           (geniCodeLogicAndOr): use IS_BIT,
1189           (geniCodeJumpTable, geniCodeSwitch): added NULL param to geniCodeLogic,
1190           (ast2iCode): added tree param to geniCodeLogic for comparisons
1191         * src/SDCCsymt.h: added IS_OP_RUONLY and IS_OP_ACCUSE
1192         * support/regression/tests/bug1723128.c: added test NotZero
1193
1194 2007-06-01 Borut Razem <borut.razem AT siol.net>
1195
1196         * SDCPP synchronized with GCC CPP release version 4.2.0,
1197           currently the latest release:
1198         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
1199           support/cpp2/c-ppoutput.c, support/cpp2/cppdefault.c,
1200           support/cpp2/cppdefault.h, support/cpp2/except.h,
1201           support/cpp2/libcpp/directives.c, support/cpp2/libcpp/expr.c,
1202           support/cpp2/libcpp/files.c, support/cpp2/libcpp/include/cpplib.h,
1203           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
1204           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/macro.c,
1205           support/cpp2/libcpp/mkdeps.c, support/cpp2/libiberty/getpwd.c,
1206           support/cpp2/libiberty/hashtab.c, support/cpp2/optc-gen.awk,
1207           support/cpp2/opth-gen.awk, support/cpp2/opts.c,
1208           support/cpp2/opts.h, support/cpp2/output.h,
1209           support/cpp2/prefix.c, support/cpp2/sdcpp-opts.c,
1210           support/cpp2/sdcpp.dsp, support/cpp2/sdcpp.opt,
1211           support/cpp2/system.h, support/cpp2/version.c,
1212           support/cpp2/Makefile.in: modified
1213         * support/cpp2/opts-common.c: added
1214         * device/lib/pic16/libdev/pic18f[24][45]j10.c: fixed svn atrributes
1215         * device/lib/pic16/libdev/pic18f[24]5j10.c:
1216           search for included source file in local directory
1217         * sim/ucsim/configure, sim/ucsim/configure.in:
1218           temporary solution to suppress GCC 4.2.0 c++ warning:
1219           deprecated conversion from string constant to `char *'
1220
1221 2007-06-01 Raphael Neider <rneider AT web.de>
1222
1223         * device/lib/pic/libdev/pic12f683.c,
1224         * device/include/pic/pic12f683.h: added GPIO bits
1225
1226 2007-06-01 Raphael Neider <rneider AT web.de>
1227
1228         * doc/sdccman.lyx: added --disable-pic16-port, fixed some `--' and
1229           quotation marks, clarified role of PIC14 vs. PIC16 ports
1230         * src/pic16/devices.inc,
1231         * device/include/pic16/pic18fregs.h,
1232         * device/include/pic16/pic18f[24][45]j10.h,
1233         * device/lib/pic16/pics.all,
1234         * device/lib/pic16/libdev/pic18f[24][45]j10.c: added support for
1235           18f24j10, 18f25j10, 18f44j10, and 18f45j10
1236         * device/lib/pic16/libio/{i2c,adc,usart}.ignore: do not build IO libs
1237           for new devices as they are not yet supported by gputils
1238
1239 2007-05-31 Borut Razem <borut.razem AT siol.net>
1240
1241         * Small Device C Compiler 2.7.0 released
1242         * .version, sdcc.spec, doc/sdccman.lyx, doc/INSTALL.txt:
1243           changed sdcc version to 2.7.1
1244         * support/scripts/sdcc.nsi: added How to create WIN32 release
1245           setup.exe package
1246
1247 2007-05-29 Maarten Brock <sourceforge.brock AT dse.nl>
1248
1249         * doc/sdccman.lyx: documented initialization and allocation of absolute
1250           variables, bit parameter passing, the need for function pointers to be
1251           reentrant and alpha quality support of inline and retrict
1252
1253 2007-05-26 Borut Razem <borut.razem AT siol.net>
1254
1255         * support/regression/tests/bug1057979.c, support/regression/tests/malloc.c,
1256           support/regression/fwk/include/testfwk.h: fixed compilation on Mac OS x
1257         * docs/knownbugs.html: updated
1258
1259 2007-05-25 Maarten Brock <sourceforge.brock AT dse.nl>
1260
1261         * doc/sdccman.lyx: inserted footnotes about inline assembler labels,
1262           thanks Jan Waclawek
1263         * src/mcs51/gen.c (aopPut): fixed part of bug 1723128 when result is
1264           AOP_CRY and ruonly
1265           (gencjneshort): optimized when left is AOP_DIR
1266         * src/SDCCglue.c (printIvalStruct): fixed other part of bug 1723128 for
1267           initializing unions in a struct/array
1268         * support/regression/fwk/include/testfwk.h: added defines for data, near
1269           and far for host and z80
1270         * support/regression/tests/bug1723128.c: new, added
1271
1272 2007-05-22 Borut Razem <borut.razem AT siol.net>
1273
1274         * doc/knownbugs.html: updated
1275
1276 2007-05-21 Raphael Neider <rneider AT web.de>
1277
1278         * src/pic16/glue.c (pic16_initPointer): avoid assertion, emit better
1279           error message instead
1280         * src/pic/pcoderegs.c (pCodeOptime2pCodes): keep register state intact
1281
1282 2007-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
1283
1284         * src/mcs51/peeph.def (257.b): disabled to fix bug 1721024
1285
1286 2007-05-21 Raphael Neider <rneider AT web.de>
1287
1288         * src/pic/pcoderegs.c (pCodeOptime2pCodes): fixed bogus optimization,
1289           closes #1722392
1290         * src/regression/gpsim_assert.h,
1291         * src/regression/Makefile,
1292         * src/regression/pcodeopt.c: regression test for the above fix
1293
1294 2007-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
1295
1296         * src/SDCCpeeph.c (labelIsUncondJump): ignore identical labels for
1297           jumps to self, fixed bug 1717281
1298
1299 2007-05-10 Borut Razem <borut.razem AT siol.net>
1300
1301         * support/scripts/gen_known_bugs.pl: cosmetic fix
1302         * doc/knownbugs.html: generated by gen_known_bugs.pl
1303
1304 2007-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1305
1306         * src/SDCCast.c (createFunction): also generate non-inlined version of
1307           function for functions declared as "static inline"
1308         * src/SDCCast.c (fixupInline, inlineAddDecl): reset symbol state so
1309           function can be inlined after non-inlined version generated.
1310
1311 2007-05-10 Borut Razem <borut.razem AT siol.net>
1312
1313         * support/scripts/gen_known_bugs.pl: added script
1314           which generates knownbugs.html
1315
1316 2007-05-09 Maarten Brock <sourceforge.brock AT dse.nl>
1317
1318         * doc/knownbugs.html: updated for release 2.7.0
1319
1320 2007-05-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1321
1322         * device/include/mcs51/uPSD33xx.h: Added patch by Jan Waclawek.
1323
1324 2007-05-08 Maarten Brock <sourceforge.brock AT dse.nl>
1325
1326         * src/ds390/gen.c (emitcode): don't change properties of previous lines,
1327           (throughout): updated generating comments
1328         * src/mcs51/gen.c (emitcode): don't change properties of previous lines,
1329           (throughout): updated generating comments
1330         * src/SDCCpeeph.c (peepHole): continue searching at the first replaced
1331           rule instead of at the second, or it might skip lines when removing the
1332           complete match
1333         * support/regression/tests/bug1714204.c: changed test to foo
1334
1335 2007-05-08 Borut Razem <borut.razem AT siol.net>
1336
1337         * doc/sdccman.lyx: changed sdcc version to 2.7.0,
1338           thanks to SDCC Distributed Compile Farm members,
1339           added Z80 and GBZ80 command line options
1340         * .version, doc/INSTALL.txt, sdcc.spec: changed sdcc version to 2.7.0
1341
1342 2007-05-08 Maarten Brock <sourceforge.brock AT dse.nl>
1343
1344         * device/lib/mcs51/crtxinit.asm: added disabled version for dual dptr
1345         * device/include/mcs51/uPSD33xx.h: added sfr DPS as alias for DPTC
1346         * support/regression/tests/longlit.c: modified to be tested at all and
1347           to pass the actual test
1348
1349 2007-05-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1350
1351         * device/include/mcs51/uPSD33xx.h: Added.
1352
1353 2007-05-07 Maarten Brock <sourceforge.brock AT dse.nl>
1354
1355         * device/lib/_gptrput.c,
1356         * device/lib/_gptrget.c: removed old code,
1357          (_gptrgetWord),
1358         * src/ds390/gen.c (genGenPointerGet): fixed bug 1714204
1359         * support/regression/tests/bug1714204.c: new, added
1360
1361 2007-05-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1362
1363         * support/regression/tests/regtrack.c: test was never executed
1364           because of the regression test being picky about white spaces.
1365         * device/lib/mcs51/crtclear.asm: added comment
1366
1367 2007-05-06 Raphael Neider <rneider AT web.de>
1368
1369         * device/lib/pic/Makefile.rules,
1370         * device/lib/pic16/Makefile.rules: make sure *.ignore file exists,
1371           made "&> /dev/null" redirection sh-safe ("> /dev/null 2>&1")
1372
1373 2007-05-06 Raphael Neider <rneider AT web.de>
1374
1375         * src/pic16/device.h,
1376         * src/pic16/main.h,
1377         * src/pic16/main.c (pic16_optionsTable,_pic16_parseOptions,
1378           _pic16_setDefaultOptions): removed/reordered command-line args
1379         * doc/sdccman.lyx: updated PIC14 and PIC16 documentation (supported
1380           devices, regrouped command line args, environment variables),
1381           clarified sone points, added sections on how to add devices to the
1382           PIC14/PIC16 ports
1383
1384 2007-05-06 Maarten Brock <sourceforge.brock AT dse.nl>
1385
1386         * src/z80/peeph.def: fixed bug in rule 2
1387
1388 2007-05-05 Maarten Brock <sourceforge.brock AT dse.nl>
1389
1390         * src/port.h: added TARGET_MCS51_LIKE
1391         * src/SDCCpeeph.c (labelIsUncondJump): new, added, other targets could
1392           take advantage of it too
1393         * src/z80/gen.c (genIpush): push b, d or h directly instead of using a,
1394           (shiftR2Left2Result): Optimized: don't check shifting by 0
1395         * src/z80/peeph-z80.def,
1396         * src/z80/peeph.def: whole set of new rules by Philipp Krause with some
1397           modifications, see patch 1700823
1398         * src/mcs51/peep.c (): fixed bug 1712928
1399         * support/regression/tests/bug1712928.c: new, added
1400
1401 2007-05-05 Borut Razem <borut.razem AT siol.net>
1402
1403         * device/lib/pic16/Makefile.common.in,
1404           device/lib/pic/Makefile.common.in, sim/ucsim/cmd.src/Makefile.in:
1405           removed bash dependencies
1406
1407 2007-05-01 Borut Razem <borut.razem AT siol.net>
1408
1409         * src/SDCCicode.c:
1410           fixed bug #1710507: --i-code-in-asm makes compile fail
1411           all iCode comments are now one liners
1412         * src/mcs51/gen.c: fixed memory leak
1413
1414 2007-05-01 Raphael Neider <rneider AT web.de>
1415
1416         * device/lib/pic/libdev/*.c
1417         * device/include/pic/*.h: regenerated all device libs from updated
1418           .inc files
1419         * support/scripts/inc2h.pl: documented usage, now uses strict to
1420           catch more bugs
1421
1422 2007-04-30 Borut Razem <borut.razem AT siol.net>
1423
1424         * doc/sdccman.lyx:
1425           fixed bug #1669175: Problem with space in output paths
1426           documented how to use paths with spaces for Windows users
1427
1428 2007-04-29 Borut Razem <borut.razem AT siol.net>
1429
1430         * Fixed svn:eol-style and svn:keywords properties
1431         * src/SDCCval.c: fixed bug
1432           #1592871: Segfault with "large" const arrays of characters
1433           replaced recursion with iteration
1434         * Removed svn:executable property from non-executable files
1435
1436 2007-04-29 Maarten Brock <sourceforge.brock AT dse.nl>
1437
1438         * src/mcs51/gen.c (genRet): fixed bug 1707003
1439
1440 2007-04-27 Raphael Neider <rneider AT web.de>
1441
1442         * src/pic16/pcode.c (pBlockRemoveUnusedLabels,pic16_pBlockAddInval,
1443           createReachingDefinitions,assignValnums,pic16_destructDF,
1444           pic16_createDF,pic16_vcg_dumpedges,pic16_vcg_dump_default):
1445           prevent NULL pointer dereferences
1446         * device/lib/pic/libdev/pic16f886.c,
1447         * device/lib/pic/libdev/pic16f887.c: svn mv'ed to disabled_* to
1448           prevent building them, gputils do not really support them yet
1449
1450 2007-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1451
1452         * device/lib/_ltoa.c: 36 bytes less __data mem. This really
1453           helps printf_small. 32 bytes more __idata mem.
1454
1455 2007-04-27 Raphael Neider <rneider AT web.de>
1456
1457         * src/pic/pcode.c (addpCode2pBlock,LinkFlow,pBlockRemoveUnusedLabels):
1458           return early when pb or pb->pcHead is NULL (patch #1708427)
1459         * src/regression/empty.c,
1460         * src/regression/Makefile: added test with empty functions
1461         * support/Util/SDCCerr.c: fixed typo in E_INIT_STRUCT message
1462
1463 2007-04-27 Borut Razem <borut.razem AT siol.net>
1464
1465         * src/SDCCast.c: fixed feature request
1466           #1547512: Redundant strings linked when using sizeof("abc")
1467
1468 2007-04-23 Borut Razem <borut.razem AT siol.net>
1469
1470         * doc/sdccman.lyx, src/SDCCmain.c:
1471           peep-hole comments are generated only if --fverbose-asm option is
1472           specified and --no-peep-comments is not, as proposed by Frieder.
1473         * support/regression/Makefile.in: compile regression tests with
1474           --fverbose-asm option so one can "grep" whether a new (or an old)
1475           peephole is (still) applied; requested by Frieder.
1476
1477 2007-04-23 Kevin Buettner <kevin AT buettner.to>
1478
1479         * device/include/pic/pic16f886.h,
1480         * device/include/pic/pic16f887.h,
1481         * device/lib/pic/libdev/pic16f886.c,
1482         * device/lib/pic/libdev/pic16f887.c,
1483         * device/include/pic/pic14devices.txt,
1484         * device/lib/pic/libdev/devices.txt: Add 16f886 and 16f887.
1485
1486 2007-04-23 Kevin Buettner <kevin AT buettner.to>
1487
1488         * device/lib/pic/libsdcc/idata.c: PAGESEL _main before going there,
1489           fixes #1704666
1490
1491 2007-04-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1492
1493         * device/lib/_memset.c: assembler version for mcs51
1494
1495 2007-04-22 Borut Razem <borut.razem AT siol.net>
1496
1497         * support/scripts/listerr.c: program to create the list of errors and
1498           warnings list from - added
1499         * doc/sdccman.lyx: removed the note
1500           "For list of warnings and corresponding codes, see err_warn.txt"
1501         * src/SDCCsymt.c: fixed bug #1699804:
1502           Bug with some uses of sizeof(static local array) (MCS51)
1503         * support/regression/tests/bug-1699804.c: added
1504
1505 2007-04-20 Maarten Brock <sourceforge.brock AT dse.nl>
1506
1507         * as/mcs51/asmain.c (search_path_append, search_path_fopen): new, added,
1508           (main): added option -i,
1509           (asmbl, case S_INCL): use search_path_fopen,
1510           mostly from patch 1579668 by Peter Miller, thanks
1511         * src/z80/main.c: fixed typo --callee-saves-bc
1512         * device/include/mcs51/compiler.h: added sfrword for Tasking
1513
1514 2007-04-20 Borut Razem <borut.razem AT siol.net>
1515
1516         * src/z80/main.c: replaced reserved keyword asm with asmblr
1517
1518 2007-04-19 Borut Razem <borut.razem AT siol.net>
1519
1520         * src/port.h: use const pointers to strings
1521         * src/SDCCargs.h: declared getStringArg() and getIntArg()
1522         * src/pic16/main.c: include SDCCargs.h
1523         * src/SDCCglobl.h: code_seg and const_seg are not pointers to
1524           const char, since the strings are dynamically allocated
1525         * src/SDCCmain.c: options.code_seg and options.const_seg are
1526           dynamically allocated; check port specific command line options
1527           before the general ones
1528         * src/z80/main.c: fixed bug #1631895: codeseg/constseg #pragma fail
1529
1530 2007-04-18 Maarten Brock <sourceforge.brock AT dse.nl>
1531
1532         * device/include/ds400rom.h,
1533         * device/lib/ds390/lcd390.c,
1534         * device/lib/ds390/memcpyx.c,
1535         * device/lib/ds390/rtc390.c,
1536         * device/lib/ds400/ds400rom.c,
1537         * device/lib/ds400/memcpyx.c,
1538         * device/lib/hc08/_ret.c: more replacements of keywords with their
1539           double underscore equivalents
1540         * device/lib/ds390/Makefile.in,
1541         * device/lib/ds400/Makefile.in,
1542         * device/lib/gbz80/Makefile.in,
1543         * device/lib/hc08/Makefile.in,
1544         * device/lib/mcs51/Makefile.in,
1545         * device/lib/z80/Makefile.in: added --std-c89 to CFLAGS
1546
1547 2007-04-17 Borut Razem <borut.razem AT siol.net>
1548
1549         * doc/sdccman.lyx, src/SDCCmain.c, src/SDCCglobal.h, src/ds390/gen.c,
1550           src/hc08/gen.c, src/mcs51/gen.c, src/mcs51/rtrack.c:
1551           fixed #1493816: option --no-gen-comments: --no-gen-comments renamed
1552           to --fverbose-asm, to be gcc'ish
1553
1554 2007-04-17 Maarten Brock <sourceforge.brock AT dse.nl>
1555
1556         * src/mcs51/gen.c (aopOp): set size to 1 for ruonly, fixes bug 1699455
1557
1558 2007-04-17 Borut Razem <borut.razem AT siol.net>
1559
1560         * doc/sdccman.lyx: fixed #1701874: Mac OSX references in SDCC manual
1561         * device/lib/ds400/tinibios.c, device/lib/hc08/_divuint.c,
1562           device/lib/hc08/_divulong.c: replaced _asm and _endasm keywords
1563           with their double underscore equivalent
1564
1565 2007-04-14 Borut Razem <borut.razem AT siol.net>
1566
1567         * doc/sdccman.lyx: some additional "freeware" replaced with "free open
1568           source"
1569
1570 2007-04-13 Borut Razem <borut.razem AT siol.net>
1571
1572         * doc/sdccman.lyx: -pedantic-parse-number is not in conformance with
1573           C99 standard
1574         * device/examples/serialcomm/windows/serial.[ch],
1575           device/examples/serialcomm/windows/test_serialcomm.cpp:
1576           updated by Bela Torok
1577         * device/examples/serialcomm/windows/serialcomm.dsw,
1578           device/examples/serialcomm/windows/serialcomm.dsp: added
1579
1580 2007-04-13 Jan Waclawek <wek AT efton.sk>
1581
1582         * doc/sdccman.lyx: additions and changes at various places
1583           (submitted as #1697136).
1584           (svn commit by Frieder Ferlemann <Frieder.Ferlemann AT web.de>)
1585
1586 2007-04-10 Borut Razem <borut.razem AT siol.net>
1587
1588         * doc/cdbfileformat.lyx, doc/sdccman.lyx, doc/test_suite_spec.lyx:
1589           LyX file format changed to 245
1590         * doc/sdccman.lyx, doc/README.txt, sdc/SDCC.lex, src/SDCCglue.c:
1591           "FreeWare" replaced with "free open source"
1592
1593 2007-04-10 Maarten Brock <sourceforge.brock AT dse.nl>
1594
1595         * device/include/mcs51/C8051F120.h: added some defines for bits in RSTSRC
1596
1597 2007-04-08 Maarten Brock <sourceforge.brock AT dse.nl>
1598
1599         * device/include/pic16/pic18fregs.h,
1600         * device/lib/_bp.c,
1601         * device/lib/_decdptr.c,
1602         * device/lib/_divsint.c,
1603         * device/lib/_divslong.c,
1604         * device/lib/_divuint.c,
1605         * device/lib/_divulong.c,
1606         * device/lib/_fs2schar.c,
1607         * device/lib/_fs2sint.c,
1608         * device/lib/_fs2slong.c,
1609         * device/lib/_fs2uchar.c,
1610         * device/lib/_fs2uint.c,
1611         * device/lib/_fs2ulong.c,
1612         * device/lib/_fsadd.c,
1613         * device/lib/_fscmp.c,
1614         * device/lib/_fsdiv.c,
1615         * device/lib/_fseq.c,
1616         * device/lib/_fsget1arg.c,
1617         * device/lib/_fsget2args.c,
1618         * device/lib/_fsgt.c,
1619         * device/lib/_fslt.c,
1620         * device/lib/_fsmul.c,
1621         * device/lib/_fsneq.c,
1622         * device/lib/_fsnormalize.c,
1623         * device/lib/_fsreturnval.c,
1624         * device/lib/_fsrshift.c,
1625         * device/lib/_fssub.c,
1626         * device/lib/_fsswapargs.c,
1627         * device/lib/_gptrget.c,
1628         * device/lib/_gptrgetc.c,
1629         * device/lib/_gptrput.c,
1630         * device/lib/_logexpf.c,
1631         * device/lib/_modsint.c,
1632         * device/lib/_modslong.c,
1633         * device/lib/_moduint.c,
1634         * device/lib/_modulong.c,
1635         * device/lib/_mulint.c,
1636         * device/lib/_mullong.c,
1637         * device/lib/_schar2fs.c,
1638         * device/lib/_ser.c,
1639         * device/lib/_setjmp.c,
1640         * device/lib/_sint2fs.c,
1641         * device/lib/_slong2fs.c,
1642         * device/lib/_spx.c,
1643         * device/lib/_uchar2fs.c,
1644         * device/lib/_uint2fs.c,
1645         * device/lib/_ulong2fs.c,
1646         * device/lib/asincosf.c,
1647         * device/lib/atanf.c,
1648         * device/lib/calloc.c,
1649         * device/lib/ds390/tinibios.c,
1650         * device/lib/ds400/tinibios.c,
1651         * device/lib/expf.c,
1652         * device/lib/free.c,
1653         * device/lib/hc08/_mulint.c,
1654         * device/lib/logf.c,
1655         * device/lib/malloc.c,
1656         * device/lib/printf_fast.c,
1657         * device/lib/printf_tiny.c,
1658         * device/lib/printfl.c,
1659         * device/lib/realloc.c,
1660         * device/lib/ser_ir.c,
1661         * device/lib/serial.c,
1662         * support/regression/tests/libmullong.c: replaced all special keywords
1663           with their double underscore equivalent
1664         * support/regression/ports/mcs51-xstack-auto/spec.mk,
1665         * device/lib/Makefile.in: compile libs with --std-c99 instead of
1666           --std-sdcc99
1667         * src/mcs51/gen.c (outBitC): don't store if result is return-use-only,
1668           (genRet): if the bit-symbol is ruonly it already is in the carry
1669         * src/mcs51/ralloc.c (regTypeNum): make regType REG_CND for ruonly bit
1670         * src/SDCCast.c (createFunction): applied patch 887171 by Stas Sergeev
1671         * src/SDCCicode.c (ast2iCode): '!', GETHBIT, GETABIT: only set operand
1672           type UCHAR if dest is not bit
1673
1674 2007-04-03 Maarten Brock <sourceforge.brock AT dse.nl>
1675
1676         * device/include/math.h,
1677         * device/lib/cotf.c,
1678         * device/lib/expf.c,
1679         * device/lib/sincoshf.c: changed XMAX to C99 HUGE_VALF
1680
1681 2007-04-01 Borut Razem <borut.razem AT siol.net>
1682
1683         * src/SDCC.lex, src/SDCCmain.c, support/cpp2/sdcpp.c:
1684           fixed bug #1692042: input buffer overflow...scanner uses REJECT
1685         * support/cpp2/sdcpp.c: fixed recursion bug - internal_error() called
1686           gcc_unreachable() called internal_error()...
1687
1688 2007-03-30 Raphael Neider <rneider AT web.de>
1689
1690         * src/pic/ralloc.c (isData): suppress garbage debug output
1691
1692 2007-03-28 Borut Razem <borut.razem AT siol.net>
1693
1694         * doc/sdccman.lyx:
1695           "Nightly Snapshots" replaced with "Snapshot Builds", since the SDCC
1696           is developed, built and used worldwide, and the word "night" doesn't
1697           make any sense.
1698
1699 2007-03-28 Maarten Brock <sourceforge.brock AT dse.nl>
1700
1701         * device/include/mcs51/C8051F360.h: new, added
1702         * device/include/mcs51/C8051F520.h: fixed buggy sbit addresses SPI0CN
1703
1704 2007-03-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1705
1706         * src/SDCC.y (declaration_specifiers, function_specifier),
1707         * support/Util/SDCCerr.c,
1708         * support/Util/SDCCerr.h,
1709         * src/SDCCsymt.h,
1710         * src/SDCCsymt.c (mergeSpec, checkFunction): Parse and validate the
1711           inline keyword
1712         * src/SDCCmem.c (deallocParms),
1713         * src/SDCCast.c: support for function inlining, not quite complete
1714         * src/SDCCsymt.c (printTypeChain, printTypeChainRaw): display
1715           'restrict' qualifier
1716
1717 2007-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
1718
1719         * src/mcs51/gen.c (saveRegisters, unsaveRegisters): free some bitVects,
1720           (saveRBank, unsaveRBank): don't save bits,
1721           (genFunction, genEndFunction): save bits exactly once, fix bug 1535242
1722         * support/regression/tests/bug1535242.c: new, added
1723         * device/include/assert.h: applied patch 1686533 to fix bug 1686528,
1724           thanks Alexey Shamrin <shamrin AT gmail.com>,
1725           made assert.h header ANSI compliant (added a check for NDEBUG macro,
1726           removed header guard)
1727         * .version,
1728         * sdcc.spec: bumped version to 2.6.5
1729         * src/SDCCmain.c(parseCmdLine): fixed bug 1677144
1730
1731 2007-03-22 Borut Razem <borut.razem AT siol.net>
1732
1733         * debugger/mcs51/cmd.c, debugger/mcs51/sdcdb.c:
1734           fixed bug #1653671: sdcdb integration into ddd is broken
1735
1736 2007-03-22 Raphael Neider <rneider AT web.de>
1737
1738         * src/pic/gen.c (popGetExternal): augmented to also create references
1739           to external variables (not only labels),
1740           (genCall): comment on plan to reduce PAGESEL overhead,
1741           (genFunction, genEndFunction): also save/restore FSR around interrupt
1742           handling code, removed lots of unused code
1743           (genDivOneByte): release acquired temp register
1744         * src/pic/glue.c (pic14createInterruptVect): adapt to new signature
1745           of popGetExternal
1746         * device/lib/pic/libsdcc/shadowregs.c: NEW, provide storage location
1747           for registers that need to be saved during interrupts (FSR, STATUS,
1748           PCLATH; W needs special handling), currently only FSR is used
1749
1750 2007-03-22 Raphael Neider <rneider AT web.de>
1751
1752         * device/include/pic/pic14devices.txt: 16f688 has only one config word
1753
1754 2007-03-19 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1755
1756         * /as/link/mcs51/aslink.dsp: Object extension for mcs51 is 'rel' not 'o'.
1757
1758 2007-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
1759
1760         * src/mcs51/peeph.def (263.x): fixed bug for volatile variables
1761
1762 2007-03-14 Maarten Brock <sourceforge.brock AT dse.nl>
1763
1764         * as/link/aslink.h: added LKOBJEXT
1765         * as/link/hc08/link_hc08.dsp,
1766         * as/link/hc08/Makefile.bcc,
1767         * as/link/hc08/Makefile.in,
1768         * as/link/mcs51/aslink.dsp,
1769         * as/link/mcs51/Makefile.bcc,
1770         * as/link/mcs51/Makefile.in: moved lkamof51.c and lkdata.c
1771         * as/link/hc08/lkaomf51.c,      as/link/mcs51/lkaomf51.c,
1772         * as/link/lkaomf51.c: merged and moved
1773         * as/link/hc08/lkdata.c,        as/link/mcs51/lkdata.c,
1774         * as/link/z80/lkdata.c,
1775         * as/link/lkdata.c: merged and moved
1776         * as/link/hc08/lkmain.c,
1777         * as/link/mcs51/lkmain.c: cosmetic changes
1778         * as/link/z80/lkeval.c,         as/link/lkeval.c: merged
1779         * as/link/lklex.c: use LKOBJEXT
1780         * as/link/z80/lklist.c,         as/link/lklist.c: merged,
1781           ANSI-fied functions, removed bubble-sorts
1782         * as/link/z80/lksym.c           as/link/lksym.c: merged,
1783           ANSI-fied functions
1784         * as/link/z80/linkgbz80.dsp,
1785         * as/link/z80/linkz80.dsp,
1786         * as/link/z80/Makefile.in: added lkaomf51.c and lknoice.c,
1787           moved lkdata.c, lkeval.c, lkhead.c, lklex.x, lklist.c, lksym.c
1788         * as/link/z80/lkhead.c,
1789         * as/link/z80/lklex.c: deleted
1790         * as/link/z80/lklibr.c: moved LKOBJEXT to aslink.h
1791         * as/link/z80/lkmain.c: added copyfile()
1792
1793 2007-03-13 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1794
1795         * device/include/mcs51/P89LPC925.h: Added missing P1_6 and P1_7.
1796
1797 2007-03-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1798
1799         * device/lib/_strlen.c: assembler version for mcs51
1800
1801 2007-03-13 Raphael Neider <rneider AT web.de>
1802
1803         * device/include/pic16/pic18f2221.h,
1804         * device/include/pic16/pic18f2321.h,
1805         * device/include/pic16/pic18f2331.h,
1806         * device/include/pic16/pic18f4221.h,
1807         * device/include/pic16/pic18f4321.h,
1808         * device/include/pic16/pic18f4331.h: fixed config byte location names
1809         * support/scripts/inc2h-pic16.pl: removed debug output, emit
1810           consistently named config byte locations
1811
1812 2007-03-13 Borut Razem <borut.razem AT siol.net>
1813
1814         * src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
1815           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/s51.src/Makefile.in,
1816           sim/ucsim/xa.src/Makefile.in, sim/ucsim/z80.src/Makefile.in,
1817           as/link/z80/Makefile.in, as/z80/Makefile.in:
1818           introduced LDFLAGS
1819
1820 2007-03-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1821
1822         * device/lib/printfl.c: 13 bytes less __data mem (12 more __idata)
1823         * device/lib/printf_large.c: pointer was converted to generic
1824         pointer for mcs51 models other than model-small (Maarten noticed)
1825
1826 2007-03-10 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1827
1828         * device/include/mcs51/ADuC84x.h: Added.
1829
1830 2007-03-10 Borut Razem <borut.razem AT siol.net>
1831
1832         * src/SDCC.lex, src/SDCCutil.[ch], src/SDCCval:
1833           fixed RFE #1624219: double backslashes in filenames;
1834           functions hexEscape(), octalEscape() and copyStr() moved from
1835           SDCCval.c to SDCCutil.c and made them glovbally available
1836
1837 2007-03-09 Borut Razem <borut.razem AT siol.net>
1838
1839         * src/SDCC.lex, src/SDCCast.c. src/SDCCglobl.c, src/SDCCsymt.c,
1840           src/SDCCval.c: fixed bugs #1676768: Wrong line number reported and
1841           1673361: Missaligned comments in output files
1842
1843 2007-03-09 Raphael Neider <rneider AT web.de>
1844
1845         * device/include/pic/pic14devices.txt: fixed confsiz of 16f91[3467]
1846
1847 2007-03-09 Raphael Neider <rneider AT web.de>
1848
1849         * src/pic/gen.c,
1850         * src/pic/glue.c,
1851         * src/pic/ralloc.c: suppress undesired debug output
1852         * src/SDCCmain.c (linkEdit): initialize c to quieten compiler
1853
1854 2007-03-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1855
1856         * device/lib/printf_large.c: 6 bytes less __data mem (6 more __idata)
1857
1858 2007-03-07 Borut Razem <borut.razem AT siol.net>
1859
1860         * device/lib/pic16/libdev/pic18f[24][34]31.c:
1861           search include files in the current directory
1862
1863 2007-03-04 Maarten Brock <sourceforge.brock AT dse.nl>
1864
1865         * src/SDCCglue.c (emitMaps, glue),
1866         * src/SDCCmem.c (initMem, allocDefault): added x_abs for initialized
1867           absolute xdata
1868         * support/regression/tests/absolute.c: added xdata test
1869
1870 2007-03-03 Maarten Brock <sourceforge.brock AT dse.nl>
1871
1872         * src/SDCCmain.c (parseCmdLine): only set options.xstack_loc for mcs51,
1873           added condition to macro, fixes bug 1666080
1874
1875 2007-03-02 Raphael Neider <rneider AT web.de>
1876
1877         * src/pic/gen.c (genGenPointerSet): removed bogus assertion
1878
1879 2007-02-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1880
1881         * device/lib/mcs51/crtxclear.asm: pdata segment of 256 byte would not
1882         be cleared. Unconditionally set __XPAGE
1883         * src/hc08/gen.c: --no-gen-comments (RFE #1493816) for hc08
1884
1885 2007-02-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1886
1887         * src/SDCCglobl.h,
1888         * src/SDCCmain.c,
1889         * src/mcs51/gen.c,
1890         * src/mcs51/rtrack.c,
1891         * src/ds390/gen.c,
1892         * doc/sdccman.lyx: added --no-gen-comments
1893         * src/mcs51/peeph.def: added 192.b, disabled 185
1894
1895 2007-02-25 Raphael Neider <rneider AT web.de>
1896
1897         * src/pic16/gen.c (genCast): fixed typo
1898         * device/lib/pic16/Makefile.subdir: only install existing files
1899         * device/lib/pic16/libdev/Makefile.in: build serially, avoid races
1900
1901 2007-02-25 Maarten Brock <sourceforge.brock AT dse.nl>
1902
1903         * device/lib/mcs51/crtcall.asm: new, added for indirect calls
1904         * device/lib/mcs51/crtclear.asm,
1905         * device/lib/mcs51/crtxclear.asm: renumbered labels
1906         * device/lib/mcs51/Makefile.in: added crtcall.asm
1907         * doc/sdccman.lyx: documented mcs51 crt* library startup code
1908         * src/mcs51/gen.c (movc): removed,
1909           (aopGet, genPlusBits): clear a after loading the carry (possibly from
1910             acc.x or psw.x),
1911           (toCarry, genSend, genRet): added function toCarry,
1912           (genPcall): use "lcall @a+dptr" for functions w/o parameters,
1913           (assignBit, genAssign, genCast): added function assignBit
1914         * src/mcs51/Makefile.bcc: added rtrack.c
1915         * src/mcs51/ralloc.h: made valueKnown a bitfield
1916         * src/mcs51/rtrack.c (getReg, rtrackUpdate): added getReg,
1917           fixed "jbc acc" and "cpl acc" bug, enhanced "cjne", "jnz" and "djnz",
1918           disabled InvalidateAllRx for lcall __gptrput, added "xch a,rn"
1919         * src/pic/pcode.c (FixRegisterBanking): fixed warning used uninitialized
1920         * src/z80/gen.c: added AOP_IS_PAIRPTR,
1921           (_pop): only pop valid pairs, see gencjneshort,
1922           (gencjneshort): return pair that still needs to be popped, restructured,
1923           (gencjne, genCmpEq): call _pop
1924
1925 2007-02-23 Raphael Neider <rneider AT web.de>
1926
1927         * device/include/pic/pic14devices.txt: 16f684 has only one config word
1928
1929 2007-02-22 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1930
1931         * device/include/mcs51/P89LPC925.h: Added.
1932
1933 2007-02-18 Raphael Neider <rneider AT web.de>
1934
1935         * src/pic/glue.c (emitInitVal): fixed #1659894 (SIGSEGV on arrays)
1936
1937 2007-02-17 Borut Razem <borut.razem AT siol.net>
1938
1939         * support/cpp2/directives.c, support/cpp2/version.c:
1940           synchronized with GCC CPP 4.1.2
1941
1942 2007-02-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1943
1944         * src/mcs51/rtrack.h,
1945         * src/mcs51/rtrack.c: added register tracking for the mcs51 port,
1946           by checking the strings passed by emitcode() to the assembler.
1947           Feel free to change. This in part addresses RFE #482179.
1948           Set environment variable SDCC_RTRACK to enable.
1949         * src/mcs51/gen.c: inserted hooks
1950         * src/mcs51/ralloc.h: added two members to struct regs
1951         * support/regression/tests/regtrack.c: added
1952
1953 2007-02-14 Borut Razem <borut.razem AT siol.net>
1954
1955         * src/SDCC.y: fixed bug #1291133: duplicate members across enum(s)
1956         * Makefile.in: applied patch from Makefile related part of
1957           #1469393: Compiler does not initialize static data
1958
1959 2007-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
1960
1961         * src/SDCCicode.c (geniCodeAssign): return (itemp) right instead of left
1962           for better fix of bug 1273984, compiles pic16 rand.c
1963
1964 2007-02-12 Borut Razem <borut.razem AT siol.net>
1965
1966         * src/pic16/main.c: fixed pic16 standard library directory bug
1967
1968 2007-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
1969
1970         * src/hc08/gen.c (genSwap): fix swap regression test
1971
1972 2007-02-10 Borut Razem <borut.razem AT siol.net>
1973
1974         * src/SDCCsymt.c: fixed bug #1159134: invalid duplicate declarations
1975           with same scope
1976         * support/regression/tests/bug-1654060.c: added regression test for
1977           #1654060
1978
1979 2007-02-09 Bernhard Held <bernhard AT bernhardheld.de>
1980
1981         * src/mcs51/gen.c (genRet): fixed RFE 1652561: added code for bit to
1982         bit moves in return statement
1983
1984 2007-02-09 Borut Razem <borut.razem AT siol.net>
1985
1986         * src/SDCC.y: fixed bug #1654060 typedef within function causes
1987           syntax error
1988
1989 2007-02-07 Maarten Brock <sourceforge.brock AT dse.nl>
1990
1991         * src/mcs51/gen.c (aopPut): use direct name for pushing registers
1992         * src/SDCCmain.c (parseCmdLine): dbuf_s path must be initialised
1993
1994 2007-02-07 Raphael Neider <rneider AT web.de>
1995
1996         * src/pic16/devices.inc,
1997         * device/include/pic16/pic18fregs.h,
1998         * device/include/pic16/pic18f[24][34]31.h,
1999         * device/lib/pic16/libdev/pic18f[24][34]31.c,
2000         * device/lib/pic16/pics.all: added 18f[24][34]31 family
2001         * device/lib/pic16/libio/i2c.ignore: do not build i2c
2002
2003 2007-02-07 Maarten Brock <sourceforge.brock AT dse.nl>
2004
2005         * device/lib/printf_large.c (_print_format): fixed compare/assign bug, how
2006           can this have lived here for so many years?
2007         * src/SDCCicode.c (ast2iCode): return left instead of right for assignment,
2008           fixes bug 1273984, see also patch 1645121, thanks Gnther Jehle
2009         * support/regression/tests/bug1273984.c: new, added, thanks Gnther Jehle
2010
2011 2007-02-06 Bernhard Held <bernhard AT bernhardheld.de>
2012
2013         * src/SDCCBlock.c (addiCodeToeBBlock): fixed bug 1652207: GOTO icodes
2014         appended by loop induction must be at the very end of the eBBlock
2015
2016 2007-02-05 Kevin Vigor
2017
2018         * src/ds390/gen.c, src/ds390/main.c: Address bug 1469393.
2019
2020 2007-02-05 Borut Razem <borut.razem AT siol.net>
2021
2022         * support/regression/fwk/lib/timeout.c: native WIN32 port,
2023           implemented #1651830 Reg. tests: rewrite timeout.c to use WIN32 API
2024
2025 2007-02-03 Borut Razem <borut.razem AT siol.net>
2026
2027         * src/SDCC.y, src/SDCCmain.c, src/SDCCglobl.h, doc/sdccman.lyx:
2028           applied patch #1646602 option to set default signedness of char to
2029           unsigned, added -funsigned-char command line option,
2030           thanks to Gunther Jehle
2031         * device/lib/Makefile.in: added the -f option to rm so it doesn't
2032           prompt for file deletion a few hundred times (especially the
2033           subversion files, which have ro permissions so it asks for
2034           confirmation), thanks to Simon McAuliffe;
2035           added {} + option to find in order to remove multiple files from a
2036           single rm commad
2037
2038 2007-02-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2039
2040         * device/include/mcs51/SST89x5xRDx.h: Added.
2041
2042 2007-02-02 Raphael Neider <rneider AT web.de>
2043
2044         * src/pic/glue.c (emitSymbolSet): check sym->etype before use
2045         * src/regression/Makefile: use --no-pcode-opt, ignore failing tests
2046
2047 2007-02-01 Raphael Neider <rneider AT web.de>
2048
2049         * src/pic/glue.c (picglue,emitSymbolSet,showAllMemmaps): emit the
2050           config words again
2051
2052 2007-01-31 Borut Razem <borut.razem AT siol.net>
2053
2054         * support/Util/dbuf_string.h: added ATTRIBUTE_PRINTF to dbuf_printf()
2055           if compiled with GCC. Thanks to Raphael Neider
2056
2057 2007-01-31 Raphael Neider <rneider AT web.de>
2058
2059         * src/pic/pcode.c (isValidIdChar,bankCompare): fuzzy matching of
2060             operand names, handles name and (name + n) for all n,
2061           (sameBank): restructured, also check bank allocation policy,
2062         * src/pic/glue.c (emitPseudoStack): fixed printf arguments,
2063           (pic14_operandsAllocatedInSameBank): check whether to operands
2064             will be allocated into the same bank (i.e., section) to reduce
2065             BANKSEL overhead, queried from pcode.c:sameBank,
2066           (pic14printLocals): reintroduced clustering registers into a single
2067             section: all compiler generated symbols will now reside in one
2068             bank (per file), reducing BANKSEL overhead and code size,
2069           (showAllMemmaps): use local dbuf where possible
2070
2071 2007-01-29 Raphael Neider <rneider AT web.de>
2072
2073         * src/pic/gen.c (popGetExternal): simplified, mark symbol as used,
2074           (call_libraryfunc): retrieve/create symbol and mark as used,
2075           (genFunction): mark defined functions as non-extern and add again
2076            to code memmap for later output
2077         * src/pic/glue.c (emitPseudoStack): put into own subroutine,
2078           (pic14printLocals): reworked for new symbol emission,
2079           (emitIfNew,pic14_constructAbsMap,emitIvalLabel,emitIvals,emitInitVal,
2080           showAllMemmaps): reworked symbol output using dbufs, added handling
2081             of string literals (still incomplete),
2082           (picglue): removed symbol emission, moved into showAllMemmaps,
2083           (emitSymbolSet): new workhorse for symbol output,
2084           (pic14emitMaps,pic14printPublics,pic14printExterns): commented out
2085
2086 2007-01-29 Borut Razem <borut.razem AT siol.net>
2087
2088         * src/SDCCmain.c, src/SDCCutil.c: dbuf_splitFile: file extension
2089           component contains the extension separator.
2090
2091 2007-01-28 Borut Razem <borut.razem AT siol.net>
2092
2093         * sim/ucsim/cmd.src/cmdutil.cc: NUL device is detected as CG_FILE type
2094           on WIN32
2095         * src/SDCCdwarf2.c, src/SDCCglobl.h, src/SDCCmain.c, src/SDCCutil.c,
2096           src/SDCCutil.h, src/avr/gen.c, src/ds390/gen.c, src/hc08/gen.c,
2097           src/mcs51/gen.c, src/pic/device.c, src/pic/gen.c, src/pic/pcode.c,
2098           src/pic/pcodepeep.c, src/pic/ralloc.c, src/pic16/device.h,
2099           src/pic16/gen.c, src/pic16/main.c, src/pic16/pcode.c,
2100           src/pic16/pcodepeep.c, src/pic16/ralloc.c, src/xa51/gen.c,
2101           src/z80/gen.c, support/Util/MySystem.c:
2102           accept slash and backslash as directory separator on WIN32 and
2103           Cygwin ports
2104
2105 2007-01-28 Raphael Neider <rneider AT web.de>
2106
2107         * src/pic16/devices.inc,
2108         * device/include/pic16/pic18f[24][23]21.h,
2109         * device/include/pic16/pic18fregs.h,
2110         * device/lib/pic16/libdev/pic18f[24][23]21.c,
2111         * device/lib/pic16/pics.all: added support for the 18f[24][23]21 family
2112         * device/lib/pic16/libio/adc.ignore,
2113         * device/lib/pic16/libio/i2c.ignore,
2114         * device/lib/pic16/libio/usart.ignore: do not build I/O lib for new
2115           family, as gputils do not yet support the devices
2116         * device/lib/pic16/Makefile.subdir: ignore errors on install
2117         * support/scripts/inc2h-pic16.pl: script to generate pic16 device
2118           headers and libraries from gputils .inc files
2119
2120 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
2121
2122         * doc/sdccman.lyx: add printf_fast_f precision limitation note
2123
2124 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
2125
2126         * doc/sdccman.lyx: add printf benchmarks
2127
2128 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
2129
2130         * device/lib/printf_fast.c: fix %c, char promoted to int
2131         * device/lib/printf_tiny.c: fix %c, char promoted to int
2132
2133 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
2134
2135         * device/lib/printf_fast.c: fix float overflow check, bug #1525093
2136
2137 2007-01-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2138
2139         * support/regression/tests/swap.c: 64 bit hosts failed
2140         * doc/sdccman.lyx: added preliminary mcs51 printf feature matrix
2141
2142 2007-01-25 Raphael Neider <rneider AT web.de>
2143
2144         * src/pic/pcode.c (sameBank,FixRegisterBanking): optimize banksels
2145           based on absolute register address, patch by Alex Blond
2146
2147 2007-01-22 Raphael Neider <rneider AT web.de>
2148
2149         * src/pic/glue.c (pic14emitRegularMap): mark initialized symbols as
2150           emitted, do not emit them again...
2151
2152 2007-01-22 Raphael Neider <rneider AT web.de>
2153
2154         * src/regression/bank1.c, src/regression/compare6.c,
2155           src/regression/add.c: cosmetic changes
2156         * src/pic/pcode.h: moved GPTRTAG_* here from gen.c
2157         * src/pic/gen.c: fixed global zero and one,
2158           (aopForSym): removed unued code,
2159           (aopGet): assert aop is defined, check and use `index' of
2160             pCodeImmd operands (fixes #1630908),
2161         * src/pic/pcode.c (get_op): added output of generic pointer tag,
2162           (register_reassign): prevent accidental register unification,
2163           (ReuseReg): cosmetic changes (also above)
2164         * src/pic/glue.c (pic14_constructAbsMap,pic14emitRegularMap,
2165           pic14emitStaticSeg): do not emit initialized data,
2166           (printIval*): replaced with working versions,
2167           (pic14createInterruptVect,picglue): use idata for initialized data,
2168             now init data should work in all modules (not only main()),
2169         * device/lib/pic/libsdcc/idata.c: NEW, handle initialized data
2170
2171 2007-01-21 Borut Razem <borut.razem AT siol.net>
2172
2173         * sim/ucsim/configure.in: introduced macro DD_COPT_NO_IGNORE,
2174           use -fPIC or -fpic if they are supported and not ignored
2175         * src/SDCCval.c: fixed bug introduced by me in rev. #4577
2176         * support/cpp2/libcpp/lex.c: fixed gcc 4.1.1 warnings
2177
2178 2007-01-20 Borut Razem <borut.razem AT siol.net>
2179
2180         * src/SDCC.lex, src/SDCCmain.c, sdc/SDCCglobl.h, doc/sdccman.lyx:
2181           implemented RFE #1470316: allow "$" in variable names
2182
2183 2007-01-20 Raphael Neider <rneider AT web.de>
2184
2185         * device/include/pic/pic14regs.h: reverted accidental wipe of the file
2186
2187 2007-01-20 Raphael Neider <rneider AT web.de>
2188
2189         * device/lib/pic/libdev/devices.txt: device list for mkall.sh
2190         * device/lib/pic/libdev/mkall.sh: script to rebuild all device libs
2191         * device/lib/pic/libdev/pic14ports.txt: device PORT specifications
2192         * support/scripts/inc2h.pl: fixed major .inc parsing bugs,
2193           applied patch from Robert Tate (#1629249) to add PORTs and TRISs
2194         * device/lib/pic/libdev/pic*.c,
2195         * device/include/pic/pic*.h: regenerated with enhanced inc2h.pl
2196         * device/lib/pic/libdev/Makefile.in: show progress
2197
2198 2007-01-19 Bernhard Held <bernhard AT bernhardheld.de>
2199
2200         * doc/sdccman.lyx: updated "configure options" for autoconf 2.6
2201         * support/scripts/sdcc_cygwin_mingw32,
2202         * support/scripts/sdcc_mingw32,
2203         * support/scripts/build.mak: replaced --datadir by --datarootdir for
2204         conformance with autoconf 2.6
2205
2206 2007-01-19 Raphael Neider <rneider AT web.de>
2207
2208         * src/pic/device.c (register_map): fixed list construction
2209         * src/pic/gen.c (genDivOneByte,genModOneByte): accept result > 1 byte,
2210           (genMod): removed case for genModbits,
2211           (genModbits): removed as now unused/unimplemented
2212         * src/pic/glue.c (picglue): prevent name clash with sources 'init.c'
2213
2214 2007-01-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2215
2216         * support/regression/tests/swap.c: added in response to #1638622
2217         * doc/sdccman.lyx: synced version, minor changes
2218
2219 2007-01-18 Borut Razem <borut.razem AT siol.net>
2220
2221         * SDCClabel.c: fixed bug #1638651: wrong linenumber presented in warning,
2222           thanks to Gunther Jehle
2223         * src/asm.c: don't die if the file drfined in #line couldn't be opened
2224         * src/SDCC.lex, src/SDCCglobal.h, src/SDCCicode.c, src/SDCCsymt.c,
2225           src/SDCCval.c: removed redundant definitions of currFname and mylineno;
2226           use filename in lineno instead.
2227         * SDCCast.c: removed MSVC warning C4018: '==' : signed/unsigned mismatch,
2228           print the file name in ast_print()
2229
2230 2007-01-18 Borut Razem <borut.razem AT siol.net>
2231
2232         * support/Util/dbuf_string.c: removed (PTR) cast since it is not
2233           defined in MSVC
2234         * src/SDCC.lex: stringLiteral() returns const char pointer,
2235           EOF detection in stringLiteral(), fixed asmbuf memory leak,
2236           fixed column counting
2237         * src/SDCCval.[ch]: constVal(), value *strVal() and charVal()
2238           accept const char pointer as parameter
2239         * src/SDCCdwarf2.c: corrected buffer size
2240
2241 2007-01-17 Borut Razem <borut.razem AT siol.net>
2242
2243         * support/Util/dbuf_string.c: fixed for amd64
2244
2245 2007-01-15 Borut Razem <borut.razem AT siol.net>
2246
2247         * src/pic16/ralloc.c, src/pic/ralloc.c, src/SDCC.y:
2248           removed terminal symbol ELIPSIS, since it was never generated by the
2249           lexer and it was wrongly used in parameter_identifier_list rule
2250
2251 2007-01-15 Raphael Neider <rneider AT web.de>
2252
2253         * doc/sdccman.lyx: updated PIC14/16 command line args, updated PIC14
2254             code page and data banking description
2255         * src/pic/genarith.c,
2256         * src/pic/gen.h: removed bit arithmetic functions,
2257             updated exit(1) to exit(EXIT_FAILURE)
2258         * device/lib/pic16/libsdcc/stack/stack.S: default to 256 byte stack
2259         * device/include/pic16/pic18f2455.h,
2260         * device/lib/pic16/libdev/pic18f2455.c: added PORTD, LATD, LATE,
2261             TRISD and TRISE, fixed/added some bit names
2262         * device/lib/pic16/libdev/pic18f{2550,4550,4455}.c,
2263         * device/include/pic16/pic18f{2550,4550,4455}.h: simply include
2264             updated pic18f2455.{c,h} instead of duplicating them
2265
2266 2007-01-14 Borut Razem <borut.razem AT siol.net>
2267
2268         * as/mcs51/asnoice.c, as/hc08/asnoice.c: fixed bug #1447412:
2269           Cannot debug files that contain spaces in the path name
2270           by converting spaces in asm file name to underscores
2271
2272 2007-01-13 Borut Razem <borut.razem AT siol.net>
2273
2274         * doc/sdccman.lyx: fixed format errors
2275
2276 2007-01-10 Borut Razem <borut.razem AT siol.net>
2277
2278         * src/SDCC.lex, src/SDCCmain.c: fixed bug #1631895:
2279           codeseg/constseg #pragma fail
2280         * suppoprt/cpp2/Makefile.bcc: reenable Borland C compilation
2281         * suppoprt/cpp2/configure.in, suppoprt/cpp2/libcpp/lex.c,
2282           suppoprt/cpp2/Makefile.in, suppoprt/cpp2/sdcpp-opts,
2283           suppoprt/cpp2/sdcpp.[ch]: house cleaning
2284
2285 2007-01-09 Borut Razem <borut.razem AT siol.net>
2286
2287         * get rid of diagnistic.[ch], pretty-print.[ch],
2288           c-pretty-print.[ch], ... used just for error, warning, ...
2289           message formatting
2290         * suppoprt/cpp2/pretty-print.[ch], suppoprt/cpp2/diagnostic.[ch],
2291           suppoprt/cpp2/diagnostic.def, suppoprt/cpp2/input.h,
2292           suppoprt/cpp2/pretty-print.[ch]:
2293           removed
2294         * suppoprt/cpp2/Makefile.in, suppoprt/cpp2/opts.c,
2295           suppoprt/cpp2/sdcpp-opts.c, suppoprt/cpp2/sdcpp.[ch],
2296           suppoprt/cpp2/sdcpp.dsp:
2297           changed
2298
2299 2007-01-08 Maarten Brock <sourceforge.brock AT dse.nl>
2300
2301         * device/lib/printf_large.c (output_float): removed recursion,
2302           use smaller buffer on stack for mcs51,
2303           fixed bug printing 1.96
2304         * support/regression/tests/snprintf.c: added test
2305
2306 2007-01-07 Borut Razem <borut.razem AT siol.net>
2307
2308         * use dynamic memory buffers instead temporary files
2309         * support/Util/dbuf_string.c, support/Util/dbuf_string.h:
2310           added
2311         * src/Makefile.in, src/SDCC.lex, src/SDCCast.c, src/SDCCast.h,
2312           src/SDCCcse.c, src/SDCCglobl.h, src/SDCCglue.c, src/SDCCglue.h,
2313           src/SDCCicode.c, src/SDCCicode.h, src/SDCCmain.c, src/SDCCmem.c,
2314           src/SDCCmem.h, src/SDCCpeeph.c, src/SDCCpeeph.h, src/SDCCsymt.c,
2315           src/SDCCsymt.h, src/SDCCutil.c, src/asm.c, src/asm.h, src/avr/gen.c,
2316           src/avr/main.c, src/ds390/gen.c, src/ds390/main.c, src/hc08/gen.c,
2317           src/hc08/main.c, src/izt/gen.c, src/mcs51/gen.c, src/mcs51/main.c,
2318           src/pic/device.c, src/pic/gen.c, src/pic/glue.c, src/pic/main.c,
2319           src/pic/ralloc.c, src/pic16/gen.c, src/pic16/glue.c,
2320           src/pic16/main.c, src/pic16/ralloc.c, src/port.h, src/src.dsp,
2321           src/xa51/gen.c, src/xa51/main.c, src/z80/gen.c, src/z80/main.c,
2322           support/Util/dbuf.c, support/Util/dbuf.h:
2323           modified
2324         * .version, sdcc.spec: bumped version to 2.6.4
2325
2326 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
2327
2328         * src/port.h: added TARGET_Z80_LIKE macro
2329         * src/SDCCmain.c (linkEdit): use TARGET_Z80_LIKE,
2330           output PSEG location if --xram-loc or --xstack-loc was used
2331         * as/link/mcs51/lkarea.c (lnksect2): set segment address afterwards
2332
2333 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
2334
2335         * as/as_gbz80.dsp, as/z80/as_gbz80.dsp,
2336         * as/as_z80.dsp,   as/z80/as_z80.dsp,
2337         * as/asx8051.dsp,  as/mcs51/asx8051.dsp,
2338         * sdcc.dsw: moved project files into subdir
2339         * as/hc08/as_hc08.dsp,
2340         * as/hc08/Makefile.bcc,
2341         * as/hc08/Makefile.in,
2342         * as/mcs51/Makefile.bcc,
2343         * as/mcs51/Makefile.in,
2344         * as/z80/Makefile.bcc,
2345         * as/z80/Makefile.in,
2346         * as/link/mcs51/Makefile.bcc: use as/strcmpi.c
2347         * as/hc08/asm.h,
2348         * as/mcs51/asm.h,
2349         * as/z80/asm.h: added as_strcmpi() and as_strncmpi() prototypes
2350         * as/hc08/asmain.c,
2351         * as/hc08/assym.c,
2352         * as/mcs51/asmain.c,
2353         * as/mcs51/assym.c,
2354         * as/z80/assym.c: removed include "strcmpi.h"
2355         * as/hc08/strcmpi.c,
2356         * as/hc08/strcmpi.h,
2357         * as/mcs51/strcmpi.c,
2358         * as/mcs51/strcmpi.h,
2359         * support/Util/strcmpi.c,
2360         * support/Util/strcmpi.h: removed files
2361         * as/strcmpi.c: added as_strncmpi()
2362
2363 2007-01-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2364
2365         * sdcc.dsw: Added some dependencies on project config.dsp
2366
2367 2007-01-05 Maarten Brock <sourceforge.brock AT dse.nl>
2368
2369         * as/link/mcs51/lkarea.c (lnkarea2, lnksect2): replaced [di]seg_ap->a_addr
2370           with [di]ram_start to fix a regresion
2371
2372 2007-01-03 Bernhard Held <bernhard AT bernhardheld.de>
2373
2374         * configure.in: added missing mcs51 in status output
2375         * Makefile.in: add support/regression to SDCC_EXTRA to distclean this
2376         directory
2377         * debugger/mcs51/clean.mk (distclean): remove config.h
2378         * src/clean.mk (clean): remove SDCCy.c, SDCCy.h, SDCClex.c
2379         * support/cpp2/Makefile.in (clean): remove s-options, optionlist,
2380         options.h, s-options-h and options.c
2381         * support/cpp2/clean.mk: unused, removed
2382         * Makefile.common.in,
2383         * main_in.mk,
2384         * as/Makefile.in,
2385         * as/hc08/Makefile.in,
2386         * as/hc08/clean.mk,
2387         * as/mcs51/Makefile.in,
2388         * as/mcs51/clean.mk,
2389         * as/z80/clean.mk,
2390         * as/z80/conf.mk,
2391         * as/z80/Makefile.in,
2392         * as/z80/clean.mk,
2393         * as/link/Makefile.in,
2394         * as/link/hc08/Makefile.in,
2395         * as/link/hc08/clean.mk,
2396         * as/link/mcs51/Makefile.in,
2397         * as/link/mcs51/clean.mk,
2398         * as/link/z80/Makefile.in,
2399         * as/link/z80/clean.mk,
2400         * as/link/z80/conf.mk,
2401         * debugger/mcs51/Makefile.in,
2402         * debugger/mcs51/clean.mk,
2403         * device/include/Makefile.in,
2404         * device/lib/Makefile.in,
2405         * device/lib/mcs51/Makefile.in,
2406         * device/lib/pic/Makefile.in,
2407         * device/lib/pic/Makefile.common.in,
2408         * device/lib/pic/Makefile.subdir,
2409         * device/lib/pic/Makefile.rules,
2410         * device/lib/pic16/libio/Makefile.in,
2411         * device/lib/pic16/Makefile.subdir,
2412         * device/lib/pic16/libdev/Makefile.in,
2413         * device/lib/pic16/Makefile.rules,
2414         * device/lib/pic16/Makefile.common.in,
2415         * sim/ucsim/avr.src/Makefile.in,
2416         * sim/ucsim/main_in.mk,
2417         * sim/ucsim/cmd.src/Makefile.in,
2418         * sim/ucsim/doc/Makefile.in,
2419         * sim/ucsim/gui.src/Makefile.in,
2420         * sim/ucsim/gui.src/obsolete/portmon.src/Makefile.in,
2421         * sim/ucsim/gui.src/serio.src/Makefile.in,
2422         * sim/ucsim/hc08.src/Makefile.in,
2423         * sim/ucsim/libltdl/Makefile.in,
2424         * sim/ucsim/s51.src/Makefile.in,
2425         * sim/ucsim/sim.src/Makefile.in,
2426         * sim/ucsim/sim.src/conf.mk,
2427         * sim/ucsim/xa.src/Makefile.in,
2428         * sim/ucsim/z80.src/Makefile.in,
2429         * src/Makefile.in,
2430         * src/clean.mk,
2431         * src/port.mk,
2432         * support/cpp2/Makefile.in,
2433         * support/librarian/Makefile.in,
2434         * support/librarian/clean.mk,
2435         * support/makebin/Makefile.in,
2436         * support/makebin/clean.mk,
2437         * support/packihx/Makefile.in,
2438         * support/regression/Makefile.in,
2439         * support/regression/ports/ds390/spec.mk,
2440         * support/regression/ports/gbz80/spec.mk,
2441         * support/regression/ports/hc08/spec.mk,
2442         * support/regression/ports/mcs51/spec.mk,
2443         * support/regression/ports/mcs51-large/spec.mk,
2444         * support/regression/ports/mcs51-medium/spec.mk,
2445         * support/regression/ports/mcs51-xstack-auto/spec.mk,
2446         * support/regression/ports/pic14/spec.mk,
2447         * support/regression/ports/pic16/spec.mk,
2448         * support/regression/ports/mcs51-stack-auto/spec.mk,
2449         * support/regression/ports/ucz80/spec.mk,
2450         * support/regression/ports/xa51/spec.mk,
2451         * support/regression/ports/z80/spec.mk: fixed for autoconf 2.6x by
2452         adding a slash after $(top_builddir) and/or adding @datarootdir@
2453         * configure.in,
2454         * debugger/mcs51/configure.in,
2455         * device/lib/pic/configure.in,
2456         * device/lib/pic16/configure.in,
2457         * sim/ucsim/configure.in,
2458         * support/cpp2/configure.in,
2459         * support/packihx/configure.in: changed AC_PREREQ to 2.60
2460         * configure,
2461         * debugger/mcs51/configure,
2462         * device/lib/pic/configure,
2463         * device/lib/pic16/configure,
2464         * sim/ucsim/configure,
2465         * support/cpp2/configure,
2466         * support/packihx/configure: generated with autoconf 2.60
2467
2468 2007-01-02 Maarten Brock <sourceforge.brock AT dse.nl>
2469
2470         * as/link/hc08/lkihx.c (newArea),
2471         * as/link/hc08/lkrloc.c: renamed newArea() to ihxNewArea()
2472
2473 2007-01-02 Borut Razem <borut.razem AT siol.net>
2474
2475         * doc/sdccman.lyx: documented #pragma sdcc_hash
2476         * support/cpp2/sdcpp.c: allow_naked_hash (value of #pragma sdcc_hash)
2477           initialized to 0
2478         * support/cpp2/c-ppoutput.c: fixed warning: no newline at end of file
2479
2480 2007-01-01 Bernhard Held <bernhard AT bernhardheld.de>
2481
2482         * src/SDCCast.c (createDo): backPatchLabels() needs falseLabel in
2483         empty 'while'-loop to work correctly, see regression test 'while.c'
2484         * support/regression/tests/while.c: added
2485
2486 2007-01-01 Borut Razem <borut.razem AT siol.net>
2487
2488         * support/cpp2/libcpp/directives.c, support/cpp2/libcpp/identifiers.c,
2489           support/cpp2/libcpp/init.c, support/cpp2/libcpp/sdcpp-opts.c,
2490           support/cpp2/libcpp/sdcpp.c:
2491           sdcpp specific pragma/directive/option handling moved to sdcpp.c
2492         * doc/sdccman.lyx: reference to the GCC 4.1.1 CPP Manual
2493         * support/cpp2/libcpp/mkdeps.c: synchronized with GCC CPP 4.1.1
2494
2495 2006-12-31 Borut Razem <borut.razem AT siol.net>
2496
2497         * SDCPP synchronized with GCC CPP release version 4.1.1,
2498           currently the latest release:
2499         * support/cpp2/libcpp, support/cpp2/libcpp/include,
2500           support/cpp2/libcpp/include/cpp-id-data.h
2501           support/cpp2/libiberty/fopen_unlocked.c
2502           support/cpp2/libiberty/md5.c
2503           support/cpp2/md5.h
2504           support/cpp2/opt-functions.awk
2505           support/cpp2/opt-gather.awk
2506           support/cpp2/optc-gen.awk
2507           support/cpp2/opth-gen.awk:
2508           added
2509         * support/cpp2/Makefile.in, support/cpp2/auto-host_vc_in.h,
2510           support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
2511           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
2512           support/cpp2/c-pretty-print.h, support/cpp2/cppdefault.c,
2513           support/cpp2/cppdefault.h, support/cpp2/diagnostic.c,
2514           support/cpp2/diagnostic.h, support/cpp2/except.h,
2515           support/cpp2/hwint.h, support/cpp2/input.h,
2516           support/cpp2/intl.h, support/cpp2/move-if-change,
2517           support/cpp2/opts.c, support/cpp2/opts.h,
2518           support/cpp2/output.h, support/cpp2/prefix.c,
2519           support/cpp2/prefix.h, support/cpp2/pretty-print.c,
2520           support/cpp2/pretty-print.h, support/cpp2/sdcpp-opts.c,
2521           support/cpp2/sdcpp.c, support/cpp2/sdcpp.dsp,
2522           support/cpp2/sdcpp.h, support/cpp2/sdcpp.opt,
2523           support/cpp2/sdcppa.dsp, support/cpp2/symcat.h,
2524           support/cpp2/version.c:
2525           modified
2526         * support/cpp2/libcpp/charset.c, support/cpp2/libcpp/directives.c,
2527           support/cpp2/libcpp/errors.c, support/cpp2/libcpp/expr.c,
2528           support/cpp2/libcpp/files.c, support/cpp2/libcpp/identifiers.c,
2529           support/cpp2/libcpp/include/cpplib.h, support/cpp2/libcpp/include/line-map.h,
2530           support/cpp2/libcpp/include/mkdeps.h, support/cpp2/libcpp/include/symtab.h,
2531           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
2532           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/line-map.c,
2533           support/cpp2/libcpp/macro.c, support/cpp2/libcpp/mkdeps.c,
2534           support/cpp2/libcpp/symtab.c, support/cpp2/libcpp/system.h,
2535           support/cpp2/libcpp/traditional.c, support/cpp2/libcpp/ucnid.h,
2536           support/cpp2/libiberty/hashtab.c, support/cpp2/libiberty/hashtab.h:
2537           moved
2538         * support/cpp2/cppcharset.c, support/cpp2/cpperror.c,
2539           support/cpp2/cppexp.c, support/cpp2/cppfiles.c,
2540           support/cpp2/cpphash.c, support/cpp2/cpphash.h,
2541           support/cpp2/cppinit.c, support/cpp2/cpplex.c,
2542           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
2543           support/cpp2/cppmacro.c, support/cpp2/cpptrad.c,
2544           support/cpp2/cppucnid.h, support/cpp2/hashtab.c,
2545           support/cpp2/hashtab.h, support/cpp2/hashtable.c,
2546           support/cpp2/hashtable.h, support/cpp2/line-map.c,
2547           support/cpp2/line-map.h, support/cpp2/mkdeps.c,
2548           support/cpp2/mkdeps.h, support/cpp2/options_vc_in.c,
2549           support/cpp2/options_vc_in.h, support/cpp2/opts.sh,
2550           support/cpp2/system.h:
2551           deleted / moved
2552
2553 2006-12-31 Borut Razem <borut.razem AT siol.net>
2554
2555         * configure.in, configure: fixed bug #1538756: configure dies if bison
2556           and flex are not installed, 2nd try
2557
2558 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
2559
2560         * src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to
2561         400.x for better code in RFE 899102
2562
2563 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
2564
2565         * src/SDCCpeeph.c (deadMove),
2566         * src/port.h,
2567         * src/mcs51/peep.h: renamed 'op' by 'reg'
2568         * src/mcs51/peep.c (isFunc, isCallerSaveFunc): added,
2569         (scan4op): small change for removeDeadMove(), added support for
2570         'callee saves' and/or PACLL function calls,
2571         (removeDeadMove): added, removes superflous 'mov r%1,%2',
2572         (removeDeadPopPush): renamed from mcs51DeadMove(), common parts
2573         left in new dispatcher mcs51DeadMove()
2574         (mcs51DeadMove): dispatcher for removeDeadPopPush() and new
2575         removeDeadMove()
2576         * src/mcs51/peeph.def: added rule 301 removing superflous 'mov r%1,%2'
2577
2578 2006-12-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2579
2580         * support/cpp2/options_vc_in.h, support/cpp2/options_vc_in.c,
2581           support/cpp2/sdcppa.dsp: create 'options.h' and 'options.c' under MSVC.
2582
2583 2006-12-30 Borut Razem <borut.razem AT siol.net>
2584
2585         * support/cpp2/spacs.h: deleted from svn
2586         * configure.in, configure: fixed bug #1538756: configure dies if bison
2587           and flex are not installed
2588
2589 2006-12-29 Maarten Brock <sourceforge.brock AT dse.nl>
2590
2591         * src/z80/gen.c (assignResultValue): fixed bug when registers overlap,
2592           with this z80 passes printf float test when enabled
2593         * support/regression/tests/bug1057979.c: typo disabled ds390 float test
2594
2595 2006-12-28 Borut Razem <borut.razem AT siol.net>
2596
2597         * support/cpp2/config.in, support/cpp2/configure.in,
2598           support/cpp2/configure, support/cpp2/Makefile.in:
2599           fix for the solaris build
2600
2601 2006-12-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2602
2603         * src/SDCC.y (type_specifier2, pointer),
2604         * src/SDCCsymt.h,
2605         * src/SDCCsymt.c (mergeSpec, checkSClass),
2606         * support/Util/SDCCerr.c,
2607         * support/Util/SDCCerr.h: Parse and validate the restrict keyword
2608         * support/valdiag/valdiag.py: Allow test cases to specify
2609           required language standard
2610         * support/valdiag/tests/restrict.c: New file to test restrict keyword
2611         * support/valdiag/tests/tentdecl.c: Supress empty source file error
2612
2613 2006-12-27 Borut Razem <borut.razem AT siol.net>
2614
2615         * support/cpp2/cppmain.c, support/cpp2/mbchar.[ch]: removed
2616         * support/cpp2/libiberty/Makefile.in, support/cpp2/libiberty/sdcpp.dsp:
2617           mbchar removed
2618         * support/cpp2/libiberty/getpwd.c, support/cpp2/sdcpp.h:
2619           fixed for borland C
2620         * support/cpp2/libiberty/Makefile.bcc: updated
2621         * src/pic16/main.c: fixed #pragma udata handling
2622         * src/mcs51/mcs51.dsp: added peep.[ch] to the project
2623
2624 2006-12-26 Bernhard Held <bernhard AT bernhardheld.de>
2625
2626         * src/SDCCpeeph.c: made labelHashEntry global,
2627         made pcDistance, FBYNAME static,
2628         (pcDistance): made static, use isComment and isLabel,
2629         (deadMove): added,
2630         (getLabelRef): added, extracted from labelRefCount(),
2631         (labelRefCount): use new getLabelRef(),
2632         (callFuncByName): made static, added deadMove,
2633         use isComment and isLabel,
2634         (newPeepRule): made static, set isLabel,
2635         (isLabelDefinition): added parameter isPeepRule to allow '%' in
2636         labels from peephole rules,
2637         (buildLabelRefCountHash): speed up by running isLabelDefinition() only
2638         when isComment or isLabel is set
2639         * src/SDCCpeeph.h: added "isLabel" and "visited" to struct lineNode,
2640         added labelHashEntry, isLabelDefinition, labelHash and getLabelRef
2641         to make them global
2642         * src/mcs51/peep.h: added
2643         * src/mcs51/peep.c: added, implements mcs51DeadMove()
2644         * src/port.h: added peep->deadMove to port structure
2645         * src/mcs51/main.c: initialize peep->deadMove with mcs51DeadMove
2646         * src/mcs51/peeph.def: renumbered rule 300 to 400, added new rule 300
2647         deadMove, finally removed no. 1 and 2
2648         * src/mcs51/gen.c,
2649         * src/pic/gen.c,
2650         * src/z80/gen.c,
2651         * src/z80/ralloc.c,
2652         * src/pic16/gen.c,
2653         * src/ds390/gen.c,
2654         * src/hc08/gen.c: mark lines with isComment or isLabel
2655         * sim/ucsim/s51.src/uc390hw.cc: don't waist 65535 ticks before CKRDY
2656         * .version,
2657         * sdcc.spec: bumped version to 2.6.3
2658
2659 2006-12-26 Borut Razem <borut.razem AT siol.net>
2660
2661         * support/cpp2/Makefile.in: added dependency on options.h
2662         * configure: regenerated
2663         * support/cpp2/sdcpp.opt, support/cpp2/move-if-change: svn:eol-style native
2664         * support/cpp2/Makefile.in: added vasprintf.c
2665
2666 2006-12-25 Borut Razem <borut.razem AT siol.net>
2667
2668         * SDCPP synchronized with GCC CPP release version 3.4.6,
2669           the latest release before 4.x:
2670         * support/cpp2/Makefile.in, support/cpp2/config.h,
2671           support/cpp2/configure, support/cpp2/configure.in,
2672           support/cpp2/cppdefault.c, support/cpp2/cppdefault.h,
2673           support/cpp2/cpperror.c, support/cpp2/cppexp.c,
2674           support/cpp2/cppfiles.c, support/cpp2/cpphash.c,
2675           support/cpp2/cpphash.h, support/cpp2/cppinit.c,
2676           support/cpp2/cpplex.c, support/cpp2/cpplib.c,
2677           support/cpp2/cpplib.h, support/cpp2/cppmacro.c,
2678           support/cpp2/cpptrad.c, support/cpp2/except.h,
2679           support/cpp2/hashtable.c, support/cpp2/hashtable.h,
2680           support/cpp2/hwint.h, support/cpp2/intl.h,
2681           support/cpp2/line-map.c, support/cpp2/line-map.h,
2682           support/cpp2/mkdeps.c, support/cpp2/mkdeps.h,
2683           support/cpp2/output.h, support/cpp2/prefix.c,
2684           support/cpp2/prefix.h, support/cpp2/sdcpp.dsp,
2685           support/cpp2/system.h, support/cpp2/version.c:
2686           modified
2687         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
2688           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
2689           support/cpp2/c-pretty-print.h, support/cpp2/cppcharset.c,
2690           support/cpp2/cppucnid.h, support/cpp2/diagnostic.c,
2691           support/cpp2/diagnostic.def, support/cpp2/diagnostic.h,
2692           support/cpp2/hashtab.c, support/cpp2/hashtab.h,
2693           support/cpp2/input.h, support/cpp2/libiberty/getpwd.c,
2694           support/cpp2/libiberty/vasprintf.c, support/cpp2/libiberty/xmemdup.c,
2695           support/cpp2/move-if-change, support/cpp2/opts.c,
2696           support/cpp2/opts.h, support/cpp2/opts.sh,
2697           support/cpp2/pretty-print.c, support/cpp2/pretty-print.h,
2698           support/cpp2/sdcpp.opt, support/cpp2/sdcpp-opts.c,
2699           support/cpp2/win32, support/cpp2/win32/dirent.c,
2700           support/cpp2/win32/dirent.h:
2701           added
2702         * support/cpp2/sdcpp.c: renamed from sdcppmain.c
2703         * support/cpp2/sdcpp.h: renamed from sdcc.h
2704         * sdcppinit.c: deleted
2705
2706 2006-12-23 Borut Razem <borut.razem AT siol.net>
2707
2708         * support/cpp2/cpphash.h, support/cpp2/cpplex.c,
2709           support/cpp2/cpplib.[ch], support/cpp2/sdcppinit.c, doc/sdccman.lyx,
2710           preproc.c: an other try to fix bug #982435: introduced
2711           -pedantic-parse-number command line option and pedantic_parse_number
2712           pragma
2713
2714 2006-12-21 Maarten Brock <sourceforge.brock AT dse.nl>
2715
2716         * as/link/mcs51/lkarea.c (lnkarea2): handle absolute areas, restructured
2717            BSEG handling,
2718           (lnksect2): use --data-loc and --idata-loc as lower bound for ramstart,
2719            corrected overlayed areax addresses, warn about memory overlaps
2720         * as/mcs51/asmain.c (asmbl): create a new area for every .org directive
2721         * src/avr/main.c,
2722         * src/ds390/main.c,
2723         * src/hc08/main.c,
2724         * src/mcs51/main.c,
2725         * src/pic16/main.c,
2726         * src/pic/main.c,
2727         * src/xa51/main.c,
2728         * src/z80/main.c,
2729         * src/port.h: added xabs_name and iabs_name
2730         * src/SDCCglue.c (emitRegularMap): allocate for absolutes with initializer
2731           (glue, emitMaps): create and emit maps d_abs and i_abs
2732         * src/SDCCglue.h: cosmetic changes
2733         * src/SDCCmain.c (setDefaultOptions): idata can start below 0x80
2734         * src/SDCCmem.h,
2735         * src/SDCCmem.c (initMem): added x_abs, i_abs and d_abs
2736           (allocDefault): put absolute, initialized globals in them
2737         * support/regression/tests/absolute.c: added absolute bdata test
2738         * device/lib/printf_large.c (output_float): moved fpBuffer to stack/xdata
2739
2740 2006-12-20 Borut Razem <borut.razem AT siol.net>
2741
2742         * support/cpp2/cpphash.h, support/cpp2/cpplex.c: fixed bug #982435
2743         * support/regression/tests/preproc.c: renamed from bug-1351710.c,
2744           added regression test for bug #982435
2745
2746 2006-12-18 Borut Razem <borut.razem AT siol.net>
2747
2748         * src/SDCCutil.c: fixed a bug in (get_pragma_token)
2749         * src/pic16/main.c, src/SDCC.lex, src/z80/main.c:
2750           small cosmetic changes
2751         * src/SDCC.lex: (stringLiteral) fixed bug #1351710
2752         * support/regression/tests/bug-1351710.c: added regression test
2753
2754 2006-12-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2755
2756         * doc/sdccman.lyx: added the long missed iCode table
2757           "<where is figure II?>", added links to wiki
2758
2759 2006-12-17 Borut Razem <borut.razem AT siol.net>
2760
2761         * doc/sdccman.lyx, src/pic16/main.c, src/pic/main.c, src/port.h,
2762           src/SDCC.lex, src/SDCCutil.[ch], src/z80/main.c,
2763           support/Util/SDCCerr.[ch]: removed deprecated pragmas,
2764           unified table driven pragma handling, pragma argument type checking
2765         * support/Util/dbuf.c: (dbuf_set_size) allow to set size equal to the
2766           current one - version 1.1.3
2767         * src/SDCCmain.c: (setParseWithComma) substituted brain damaged strtok
2768
2769 2006-12-13 Raphael Neider <rneider AT web.de>
2770
2771         * src/pic/device.h: removed AssignedMemory structure and macros
2772         * src/pic/device.c: removed global finalMapping (linker assigns
2773             memory locations),
2774           (register_map): add SFRs to remembered memRanges
2775           (addMemRange,isSFR,dump_map,dump_sfr,mapRegister,assignRegister,
2776           assignFixedRegisters,assignRelocatableRegisters): removed,
2777           (setMaxRAM,validAddress): adapted accordingly,
2778           (pic14_hasSharebank,pic14_getSharedStack): only report and use
2779             reasonably sized sharebanks,
2780         * src/pic/ralloc.c (writeUsedRegs): stripped down (remove?),
2781           (allDefsOutOfRange): removed unused code,
2782         * src/pic/main.c (_process_pragma): removed memmap/maxram pragma
2783             handling
2784         * src/pic/pcode.c (register_reassign): removed recursion warning,
2785             fired far too often,
2786         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap): modified
2787             to use existing pic14_stringInSet() to avoid duplicate symbols,
2788             tidied up the code a bit,
2789           (pic14printLocals): added in symmetry to printExterns, replaces
2790             writeUsedRegs more or less,
2791           (picglue): call new pic14_printLocals(),
2792         * device/include/pic/pic*.h: removed #pragma memmap directives,
2793             information gathered from include/pic/pic14devices.txt
2794         * support/scripts/inc2h.pl: do not emit #pragma memmap lines
2795
2796 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
2797
2798         * device/include/mcs51/C8051F520.h: fixed buggy CPT0MX
2799
2800 2006-12-11 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2801
2802         * device/include/mcs51/cc2430.h: fixed missing ';'
2803
2804 2006-12-10 Raphael Neider <rneider AT web.de>
2805
2806         * device/lib/pic16/libc/stdio/vfprintf.c,
2807         * device/lib/pic16/libc/stdio/printf_small.c,
2808         * device/lib/pic16/libc/stdio/printf_timy.c: pop int from stack for
2809           char arguments, as char varargs are cast to int by the caller,
2810           hopefully fixes #1604915 (other device libraries are still affected)
2811
2812 2006-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2813
2814         * src/mcs51/ralloc.c (packRegsForAssign),
2815         * src/hc08/ralloc.c (packRegsForAssign): fixed bug #1605880
2816
2817 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
2818
2819         * device/include/malloc.h: removed init_dynamic_memory
2820         * device/lib/malloc.c: made init_dynamic_memory static and automatically
2821           call it once from malloc. Also use _sdcc_heap[] from _heap.c
2822         * device/lib/_heap.c: new, added, contains _sdcc_heap[]
2823         * device/lib/libsdcc.lib,
2824         * device/lib/Makefile.in,
2825         * support/regression/ports/mcs51-xstack-auto/spec.mk: added _heap.c
2826         * doc/sdccman.lyx: documented use of new _heap.c
2827         * support/regression/tests/malloc.c: removed init_dynamic_memory
2828         * src/cdbFile.c(spacesToUnderscores): new function,
2829           (cdbWriteEndFunction, cdbWriteCLine): use spacesToUnderscores, fixes bug
2830           1068030
2831         * device/include/tinibios.h: removed defines for putchar and getchar
2832         * device/lib/ds390/Makefile.in: added putchar.c
2833         * device/lib/ds390/putchar.c: new, added, fixes bug 1465671
2834
2835 2006-12-09 Borut Razem <borut.razem AT siol.net>
2836
2837         * support/cpp2/sdcc.h: prevent multiple inclusion
2838         * support/cpp2/options.h: deleted
2839
2840 2006-12-08 Borut Razem <borut.razem AT siol.net>
2841
2842         * support/cpp2/sdcc.h: removed x*alloc() macros
2843         * support/cpp2/libiberty.h: uncommented out x*alloc() declarations
2844         * support/cpp2/Makefile.bcc, support/cpp2/Makefile.in,
2845           support/cpp2/sdcpp.sdc: x*alloc files added to the project
2846         * support/cpp2/system.h: moved #include "sdcc.h"
2847         * support/cpp2/libiberty/xexit.c, support/cpp2/libiberty/xmalloc.c,
2848           support/cpp2/libiberty/xstrdup.c, support/cpp2/libiberty/xstrerror.c:
2849           added
2850         * support/cpp2/sdcppinit.c: added -isysroot, -fsigned-char,
2851           -funsigned-char options
2852         * support/cpp2/sdcppmain.c: fixed bug 1611411
2853
2854 2006-12-07 Borut Razem <borut.razem AT siol.net>
2855
2856         * support/cpp2/cpplib.c: reverted sdcpp special handling of _Pragma()
2857           directive
2858
2859 2006-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
2860
2861         * src/SDCCsymt.c (addDecl): fixed bug 1609244
2862         * src/SDCCmain.c (linkEdit): fixed bug 1609279
2863         * doc/sdccman.lyx,
2864         * .version: bumped to 2.6.2 because a) it's been a while
2865           b) the linker sources have moved c) the preprocessor is upgraded
2866
2867 2006-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2868
2869         * support/regression/tests/snprintf.c: some checks
2870         * lib/src/printf_large.c: %bc: read char instead of int from stack
2871
2872 2006-12-03 Maarten Brock <sourceforge.brock AT dse.nl>
2873
2874         * device/include/mcs51/cc2430.h: inserted _XPAGE
2875
2876 2006-12-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2877
2878         * device/include/mcs51/cc2430.h: added
2879
2880 2006-12-02 Maarten Brock <sourceforge.brock AT dse.nl>
2881
2882         * device/include/asm/default/features.h,
2883         * device/include/asm/ds390/features.h,
2884         * device/include/mcs51/at89s53.h,
2885         * device/include/ser.h,
2886         * device/include/ser_ir.h,
2887         * device/include/serial.h: changed keywords to double underscore variants,
2888           fixes bug 1590261 some more, thanks Steven Borley
2889
2890 2006-12-01 Raphael Neider <rneider AT web.de>
2891
2892         * src/pic/pcode.c (register_reassign): do not crash on recursive code
2893           but emit warning (recursion is not supported for pic14)
2894
2895 2006-11-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2896
2897         * src/mcs51/peeph.def: added 101.a,b (moves to int/long xdata)
2898         * doc/sdccman.lyx: various small changes, acknowledged Sourceforge
2899
2900 2006-11-30 Raphael Neider <rneider AT web.de>
2901
2902         * src/pic/device.c (dump_sfr): always emit symbols
2903         * src/pic/glue.c (pic14printPublics): fixed typo
2904
2905 2006-11-30 Raphael Neider <rneider AT web.de>
2906
2907         * src/pic/device.c (create_pic,ram_map): add memRange entries to PIC
2908           (pic14_getSharebankSize, pic14_getSharebankAddress): replaced with
2909           (pic14_hasSharebank,pic14_isShared,pic14_allRAMShared,
2910            pic14_getSharedStack): NEW, evaluate the memRange entries to locate
2911            a sharebank, use a non-shared bank for the stack if none available
2912         * src/pic/device.h (struct memRange): added linked list next field,
2913           added prototypes for above functions
2914         * src/pic/ralloc.c (initStack): handle shared and banked stacks,
2915           (typeRegWithIdx): accept fixed and unfixed stack registers
2916         * src/pic/pcode.c (pCodeInitRegisters): use new functions to create
2917           the stack, handle shared and banked stack (except for WSAVE),
2918           (insertBankSel): removed useless optimization (will never fire),
2919           (FixRegisterBanking): added optimization for devices with only one
2920           possibly aliased bank of memory, like 16f84
2921         * src/pic/glue.c (pic14_constructAbsMap): back to udata_ovr, as some
2922           devices have no SHAREBANK in the linker script
2923         * device/include/pic/pic14devices.txt: documented memmap
2924         * device/lib/pic/libdev/Makefile.in: removed --stack-loc again
2925
2926 2006-11-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2927
2928         * src/hc08/gen.c (transferRegReg, loadRegFromAop, forceStackedAop,
2929           storeRegToAop, freeAsmop, genPlusIncr, genPlus, genPointerGetSetOfs,
2930           genAnd, genOr, genXor, genLeftShiftLiteral, genRightShiftLiteral,
2931           genhc08Code): switched most of the D (debug) macros to DD (detailed
2932           debug) macros to better control clutter in the generated .asm file.
2933         * src/hc08/gen.c: (forceStackedAop, genUminus, genLeftShift,
2934           genRightShift): fixed bug with non-constant bit shift stored to
2935           a volatile result (SF Open Discussion forum thread #1616749).
2936           Single byte case is not yet optimized.
2937
2938 2006-11-28 Maarten Brock <sourceforge.brock AT dse.nl>
2939
2940         * device/include/asm/mcs51/features.h,
2941         * device/include/malloc.h,
2942         * device/include/stdio.h: changed keywords to double underscore variants,
2943           fixes bug 1590261
2944
2945 2006-11-27 Borut Razem <borut.razem AT siol.net>
2946
2947         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
2948           support/cpp2/Makefile.in, support/cpp2/cppfiles.c,
2949           support/cpp2/output.h, support/cpp2/cppinit.c,
2950           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
2951           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
2952           support/cpp2/cppdefault.c, support/cpp2/system.h,
2953           support/cpp2/cpphash.h, support/cpp2/cpplex.c,
2954           support/cpp2/cppdefault.h, support/cpp2/mbchar.c,
2955           support/cpp2/prefix.c, support/cpp2/except.h,
2956           support/cpp2/hwint.h, support/cpp2/cppmacro.c,
2957           support/cpp2/line-map.h, support/cpp2/sdcpp.dsp,
2958           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
2959           support/cpp2/version.c, support/cpp2/cppmain.c,
2960           support/cpp2/version.h, support/cpp2/hashtable.c,
2961           support/cpp2/cpperror.c:
2962           synchronized with GCC CPP release version 3.3.6,
2963           the latest where cppmain.c still exists.
2964         * support/cpp2/cpptrad.c, support/cpp2/sdcppmain.c,
2965           support/cpp2/sdcppinit.c: added
2966
2967 2006-11-27 Borut Razem <borut.razem AT siol.net>
2968
2969         * support/cpp2/cpplex.c:
2970           fixed _asm ... _endasm handling bug, introduce with GCC CPP
2971           synchronization
2972         * support/cpp2/cpplib.c: removed definitions of unused variables
2973
2974 2006-11-26 Borut Razem <borut.razem AT siol.net>
2975
2976         * support/cpp2/libiberty.h: commented out x*alloc() declarations
2977           since they are redefined by macros in support/cpp2/sdcc.h
2978         * support/cpp2/sdcc.h: x*alloc macro redefinition
2979
2980 2006-11-25 Borut Razem <borut.razem AT siol.net>
2981
2982         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
2983           support/cpp2/configure, support/cpp2/Makefile.in,
2984           support/cpp2/cppfiles.c, support/cpp2/output.h,
2985           support/cpp2/cppinit.c, support/cpp2/cpplib.c,
2986           support/cpp2/config.h, support/cpp2/cpplib.h,
2987           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
2988           support/cpp2/cppdefault.c, support/cpp2/config.in,
2989           support/cpp2/system.h, support/cpp2/cpplex.c,
2990           support/cpp2/cpphash.h, support/cpp2/mbchar.c,
2991           support/cpp2/cppdefault.h, support/cpp2/prefix.c
2992           support/cpp2/hwint.h, support/cpp2/mbchar.h,
2993           support/cpp2/prefix.h, support/cpp2/cppmacro.c,
2994           support/cpp2/configure.in, support/cpp2/intl.h,
2995           support/cpp2/sdcpp.dsp, support/cpp2/acconfig.h,
2996           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
2997           support/cpp2/version.c, support/cpp2/cppmain.c,
2998           support/cpp2/ansidecl.h, support/cpp2/libiberty.h,
2999           support/cpp2/hashtable.c, support/cpp2/aclocal.m4,
3000           support/cpp2/cpperror.c,
3001           support/cpp2/libiberty/safe-ctype.c,
3002           support/cpp2/libiberty/safe-ctype.h,
3003           support/cpp2/libiberty/splay-tree.c,
3004           support/cpp2/libiberty/obstack.c,
3005           support/cpp2/libiberty/lbasename.c,
3006           support/cpp2/libiberty/splay-tree.h,
3007           support/cpp2/libiberty/obstack.h:
3008           synchronized with GCC CPP release version 3.2.3,
3009           the latest before integration of cpp into gcc
3010         * support/cpp2/except.h, support/cpp2/line-map.c,
3011           support/cpp2/line-map.h,
3012           support/cpp2/libiberty/hex.c,
3013           support/cpp2/libiberty/concat.c,
3014           support/cpp2/libiberty/filenames.h: added
3015         * support/cpp2/intl.c: deleted
3016
3017 2006-11-24 Borut Razem <borut.razem AT siol.net>
3018
3019         * src/SDCC.y: enabled compilation of empty source file
3020         * support/Util/SDCCerr.[ch]: added sdcc warning 190 -
3021           "ISO C forbids an empty source file"
3022         * device/lib/_startup.c, device/lib/printf_tiny.c: disable warning 190
3023           if all the code is ifdefed out.
3024
3025 2006-11-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3026
3027         * src/hc08/gen.c (genPcall): fix for bug #1601032
3028
3029 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
3030
3031         * device/include/mcs51/c8051f000.h, device/include/mcs51/C8051F000.h,
3032         * device/include/mcs51/c8051f018.h, device/include/mcs51/C8051F018.h,
3033         * device/include/mcs51/c8051f020.h, device/include/mcs51/C8051F020.h,
3034         * device/include/mcs51/c8051f040.h, device/include/mcs51/C8051F040.h,
3035         * device/include/mcs51/c8051f060.h, device/include/mcs51/C8051F060.h,
3036         * device/include/mcs51/c8051f120.h, device/include/mcs51/C8051F120.h,
3037         * device/include/mcs51/c8051f200.h, device/include/mcs51/C8051F200.h,
3038         * device/include/mcs51/c8051f300.h, device/include/mcs51/C8051F300.h,
3039         * device/include/mcs51/c8051f310.h, device/include/mcs51/C8051F310.h,
3040         * device/include/mcs51/c8051f320.h, device/include/mcs51/C8051F320.h,
3041         * device/include/mcs51/c8051f326.h, device/include/mcs51/C8051F326.h,
3042         * device/include/mcs51/c8051f330.h, device/include/mcs51/C8051F330.h,
3043         * device/include/mcs51/c8051f340.h, device/include/mcs51/C8051F340.h,
3044         * device/include/mcs51/c8051f350.h, device/include/mcs51/C8051F350.h,
3045         * device/include/mcs51/c8051f410.h, device/include/mcs51/C8051F410.h:
3046           Renamed to all upper case as per the standard set by SiLabs
3047
3048 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
3049
3050         * device/include/mcs51/C8051F520.h: new, added
3051         * device/include/mcs51/compiler.h: added link about predefined macros
3052
3053 2006-11-23 Raphael Neider <rneider AT web.de>
3054
3055         * src/regression/Makefile: add -L path to fresh library
3056         * src/regression/simulate: emphasize FAILED output
3057         * src/regression/create_stc: output _failures from gpsim
3058         * src/regression/compare4.c,
3059         * src/regression/rotate6.c: fixed char literals,
3060           all compile, all run =8-D
3061
3062         * src/pic/pcode.h: added isPCASMDIR macro
3063         * src/pic/gen.c (genAnd): fixed bit offset
3064         * src/pic/ralloc.c (allocNewDirReg,allocDirReg,allocRegByName,
3065           packBits): unified register numbering schemes,
3066           (newReg): do not insert stack registers into hash table,
3067           (initStack): unpinned pseudo stack, simplified,
3068           (typeRegWithIdx): fixed retrieval of stack registers,
3069         * src/pic/pcode.c (addpCodeComment,sameBank): added,
3070           (pCodeReplace): removed invalid assertion,
3071           (insertPCodeInstruction): fixed newly added labels,
3072           (insertBankSwitch,BankSelect,IsBankChange,DoBankSelect,
3073           FixRegisterBankingInFlow,compareBankFlow,FixBankFlow,
3074           DumpFlow): removed unsed (broken?) code,
3075           (insertBankSel): prevent STATUS from being BANKSELed,
3076           (FixRegisterBanking): rewritten from scratch, implemented generic
3077             optimizations (suppress BANKSELs to same register and to registers
3078             present in all banks),
3079           (AnalyzeBanking): update flow after BANKSELection
3080
3081         * src/pic/glue.c (pic14_constructAbsMap): emit pseudo stack in
3082             sharebank, let linker place it, mark STKxx symbols as emitted
3083
3084 2006-11-21 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3085
3086         * src/regression/arrays.c,
3087         * src/regression/bank1.c,
3088         * src/regression/bool2.c,
3089         * src/regression/compare7.c,
3090         * src/regression/compare8.c,
3091         * src/regression/compare9.c,
3092         * src/regression/compare10.c,
3093         * src/regression/configword.c,
3094         * src/regression/for.c,
3095         * src/regression/mult1.c,
3096         * src/regression/pointer1.c,
3097         * src/regression/rotate6.c,
3098         * src/regression/string1.c,
3099         * src/regression/struct1.c,
3100         * src/regression/Makefile: make PIC14 regression tests run again
3101           (3 fail, 6 won't compile)
3102
3103 2006-11-21 Raphael Neider <rneider AT web.de>
3104
3105         * device/include/pic16/pic18f4550.h,
3106         * device/include/pic16/pic18f4455.h,
3107         * device/lib/pic16/libdev/pic18f4550.c,
3108         * device/lib/pic16/libdev/pic18f4455.c: fixed #1578591 and #1595144
3109         * configure.in: removed superfluous closing bracket
3110
3111 2006-11-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3112
3113         * device/lib/expf.c: Fixed bug 1599523: result of expf(x) is
3114           always positive.
3115
3116 2006-11-21 Raphael Neider <rneider AT web.de>
3117
3118         * src/pic/device.{c,h}: added pic14_getPIC()
3119         * src/pic/gen.c (continueIfTrue,jumpIfTrue): added PIC code,
3120           (genAnd): added PIC code for one case, fixes #1597044
3121         * src/pic/pcode.c (BankSelect): Ohoh, added generic optimization for
3122           SFRs that are present in all banks (e.g., STATUS)
3123
3124 2006-11-20 Raphael Neider <rneider AT web.de>
3125
3126         * src/pic/pcode.c: changed inverted ops for DECFSZ/DECFSZW and
3127           INCFSZ/INCFSZW and declared them as changing Z bit,
3128           (insertPCodeInstruction): correctly invert the above instructions,
3129           fixes #1599333,
3130           (DoBankSelect): don't panic on po_immediates
3131
3132 2006-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
3133
3134         * as/link/aslink.h,
3135         * as/link/mcs51/lkihx.c (newArea),
3136         * as/link/mcs51/lkrloc.c: renamed newArea() to ihxNewArea()
3137         * as/link/mcs51/lkihx.c (ihx): output reset vector as start address
3138
3139 2006-11-11 Raphael Neider <rneider AT web.de>
3140
3141         * src/pic/pcode.c (newpCodeOpBit): search SymbolTab for referenced
3142           bitfield symbols, fixes #1579535 (once more...).
3143
3144 2006-11-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3145
3146         * support/regression/generate-cases.py,
3147         * support/regression/fwk/include/testfwk.h,
3148         * support/regression/fwk/lib/testfwk.c: used code pointers,
3149           (about 50kByte less code generated for mcs51)
3150
3151 2006-11-06 Borut Razem <borut.razem AT siol.net>
3152
3153         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
3154           debugger/mcs51/configure: fixed failed check because the function
3155           rl_function_of_keyseq isn't in Readline 5.2. Thanks to Ilya Goldberg
3156           who submitted the patch for gpsim.
3157         * debugger/mcs51/configure.in: removed the result message
3158         * debugger/mcs51/Makefile.in: fixed the config.status warning
3159           "... seems to ignore the --datarootdir setting"
3160
3161 2006-11-03 Maarten Brock <sourceforge.brock AT dse.nl>
3162
3163         * device/include/mcs51/c8051f020.h,
3164         * device/include/mcs51/c8051f040.h,
3165         * device/include/mcs51/c8051f060.h,
3166         * device/include/mcs51/c8051f120.h: added PS0, fixed bug 1589279
3167         * src/z80/gen.c (gencjneshort),
3168         * src/z80/peeph.def: applied patch 1571373, thanks Philipp Krause
3169
3170 2006-10-31 Borut Razem <borut.razem AT siol.net>
3171
3172         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
3173           debugger/mcs51/configure: get readline version
3174
3175 2006-10-30 Borut Razem <borut.razem AT siol.net>
3176
3177         * debugger/mcs51/sdcdb.c: replaced hardcoded "/" with DIR_SEPARATOR_STRING
3178         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
3179           debugger/mcs51/configure: locate readline even when cross compiling
3180         * support/scripts/sdcc.nsi: include readline5.dll into the setup package
3181
3182 2006-10-29 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3183
3184         * device/include/mcs51/serial_IO.h: putchar() and getchar() using
3185           serial port.
3186
3187 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
3188
3189         * device/include/malloc.h,
3190         * device/lib/calloc.c,
3191         * device/lib/free.c,
3192         * device/lib/malloc.c,
3193         * device/lib/realloc.c: moved definition of struct into sources
3194         * support/regression/tests/malloc.c: use void* for init_dynamic_memory()
3195
3196 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
3197
3198         * as/asx8051.dsp: corrected output directories
3199         * as/link/hc08: new directory for hc08 linker
3200         * as/hc08/aslink.h,             as/link/aslink.h,
3201         * as/hc08/aslink.mak,           as/link/hc08/aslink.mak,
3202         * as/hc08/clean.mk,             as/link/hc08/clean.mk,
3203         * as/hc08/link_hc08.dsp,        as/link/hc08/link_hc08.dsp,
3204         * as/hc08/lkaomf51.c,           as/link/hc08/lkaomf51.c,
3205         * as/hc08/lkarea.c,             as/link/hc08/lkarea.c,
3206         * as/hc08/lkdata.c,             as/link/hc08/lkdata.c,
3207         * as/hc08/lkelf.c,              as/link/hc08/lkelf.c,
3208         * as/hc08/lkihx.c,              as/link/hc08/lkihx.c,
3209         * as/hc08/lklibr.c,             as/link/hc08/lklibr.c,
3210         * as/hc08/lkmain.c,             as/link/hc08/lkmain.c,
3211         * as/hc08/lkmem.c,              as/link/hc08/lkmem.c,
3212         * as/hc08/lkrloc.c,             as/link/hc08/lkrloc.c,
3213         * as/hc08/lks19.c,              as/link/hc08/lks19.c,
3214         * as/hc08/Makefile.aslink,      as/link/hc08/Makefile.aslink,
3215         * as/hc08/Makefile.bcc,         as/link/hc08/Makefile.bcc,
3216         * as/hc08/Makefile.in,          as/link/hc08/Makefile.in,
3217         * as/link/hc08/conf.mk,
3218         * configure,
3219         * configure.in,
3220         * Makefile.in,
3221         * sdcc.dsw: moved hc08 linker to as/link/hc08
3222         * as/hc08/lkeval.c,     as/link/mcs51/lkeval.c,     as/link/lkeval.c,
3223         * as/hc08/lkhead.c,     as/link/mcs51/lkhead.c,     as/link/lkhead.c,
3224         * as/hc08/lklex.c,      as/link/mcs51/lklex.c,      as/link/lklex.c,
3225         * as/hc08/lklist.c,     as/link/mcs51/lklist.c,     as/link/lklist.c,
3226         * as/hc08/lknoice.c,    as/link/mcs51/lknoice.c,    as/link/lknoice.c,
3227         * as/hc08/lksym.c,      as/link/mcs51/lksym.c,      as/link/lksym.c,
3228         * as/link/mcs51/aslink.dsp,
3229         * as/link/mcs51/Makefile.in: factored out the common files
3230         * as/hc08/lkstore.c: deleted, use the one already in as/link/
3231         * as/clean.mk: extra cleaning common files
3232         * as/link/mcs51/strcmpi.c,      as/strcmpi.c: moved
3233         * as/link/mcs51/strcmpi.h: deleted, moved protoype to aslink.h
3234         * as/mcs51/asm.h: include sdccconf.h or sdcc_vc.h
3235
3236 2006-10-29 Raphael Neider <rneider AT web.de>
3237
3238         * src/pic/ralloc.c (newReg): create aliases for registers with
3239           multiple names to fix #1579535 and #1584001,
3240           (regWithIdx,dirregWithName): resolve aliases on lookup
3241         * src/pic/pcode.c (DoBankSelect): die with error message on failing
3242           bankselect
3243         * device/lib/pic/libdev/Makefile.in: move pseudo stack down to 0x4f
3244           to prevent build errors on small devices
3245
3246 2006-10-28 Raphael Neider <rneider AT web.de>
3247
3248         * src/pic/gen.c (genFunction,genCall): drop "same code page"
3249           assumption within interrupt handlers, fixes #1584940
3250         * src/pic/glue.c (pic14_constructAbsMap): mark absolute symbols as
3251           "emitted" to avoid emitting them again in udata
3252
3253 2006-10-27 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3254
3255         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
3256         Removed.
3257
3258 2006-10-26 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3259
3260         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
3261         Initialize uart only if SM0 and SM1 are zero.  Also, use flag to turn
3262         on/off CR to CRLF conversion.
3263
3264 2006-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3265
3266         * doc/sdccman.lyx: updated IRQ section
3267
3268 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3269
3270         * device/lib/serial_io.c: removed
3271         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c
3272         replacements for serial_io.c
3273
3274 2006-10-24 Maarten Brock <sourceforge.brock AT dse.nl>
3275
3276         * src/z80/main.c (_process_pragma, _parseOptions): fixed bug 1583318
3277
3278 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3279
3280         * device/lib/serial_io.c: Default putchar() and getchar() for
3281           mcs51 uses serial port.
3282
3283 2006-10-23 Maarten Brock <sourceforge.brock AT dse.nl>
3284
3285         * src/mcs51/gen.c (movc): improved check for 0 and 1, see RFE 1582704
3286
3287 2006-10-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3288
3289         * support/regression/ports/mcs51/support.c: smaller
3290         _sdcc_external_startup()
3291         * device/lib/mcs51/crtxclear.asm: don't check high byte of l_PSEG
3292
3293 2006-10-20 Maarten Brock <sourceforge.brock AT dse.nl>
3294
3295         * device/lib/gbz80/crt0.s,
3296         * device/lib/gbz80/crt0_rle.s,
3297         * device/lib/gbz80/div.s,
3298         * device/lib/gbz80/fstubs.s,
3299         * device/lib/gbz80/heap.s,
3300         * device/lib/gbz80/mul.s,
3301         * device/lib/gbz80/putchar.s,
3302         * device/lib/gbz80/stubs.s,
3303         * device/lib/z80/crt0.s,
3304         * device/lib/z80/crt0_rle.s,
3305         * device/lib/z80/div.s,
3306         * device/lib/z80/fstubs.s,
3307         * device/lib/z80/heap.s,
3308         * device/lib/z80/mul.s,
3309         * device/lib/z80/putchar.s,
3310         * device/lib/z80/stubs.s: reverted, I was mistaken
3311
3312 2006-10-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3313
3314         * src/mcs51/peeph.def: peephole 238.x added check for notvolatile
3315         * support/regression/ports/mcs51/support.c: removed race
3316         condition on TI in _putchar allowing to use serial port mode 0
3317
3318 2006-10-20 Borut Razem <borut.razem AT siol.net>
3319
3320         * debugger/mcs51/sdcdb.c: replaced isblank() with isspace()
3321
3322 2006-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
3323
3324         * device/lib/gbz80/crt0.s,
3325         * device/lib/gbz80/crt0_rle.s,
3326         * device/lib/gbz80/div.s,
3327         * device/lib/gbz80/fstubs.s,
3328         * device/lib/gbz80/heap.s,
3329         * device/lib/gbz80/mul.s,
3330         * device/lib/gbz80/putchar.s,
3331         * device/lib/gbz80/stubs.s,
3332         * device/lib/z80/crt0.s,
3333         * device/lib/z80/crt0_rle.s,
3334         * device/lib/z80/div.s,
3335         * device/lib/z80/fstubs.s,
3336         * device/lib/z80/heap.s,
3337         * device/lib/z80/mul.s,
3338         * device/lib/z80/putchar.s,
3339         * device/lib/z80/stubs.s: removed all leading underscores from area names
3340
3341 2006-10-17 Maarten Brock <sourceforge.brock AT dse.nl>
3342
3343         * support/regression/ports/mcs51/support.c: use highest baudrate so the
3344           regression tests are not waiting in the simulator for simulated
3345           transmission of debug output
3346
3347 2006-10-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3348
3349         * device/lib/printf_large.c: slightly smaller
3350         * doc/sdccman.lyx: do not use spaces within html links
3351
3352 2006-10-16 Borut Razem <borut.razem AT siol.net>
3353
3354         * configure.in, configure, sdccconf_in.h, src/SDCCglobal,
3355           debugger/mcs51/Makefile.in, debugger/mcs51/sdcdb.[ch],
3356           debugger/mcs51/aclocal.m4, debugger/mcs51/acinclide.m4,
3357           debugger/mcs51/config.h.in, debugger/mcs51/configure.in,
3358           debugger/mcs51/configure:
3359           [ 1185668 ] add gnu readline support to sdcdb - enabled
3360
3361 2006-10-16 Raphael Neider <rneider AT web.de>
3362
3363         * src/pic/pcode.c (BankSelect): another fix on (partial) BANKSELs,
3364           fixes #1577882, removes close to all banking optimizations
3365
3366 2006-10-15 Maarten Brock <sourceforge.brock AT dse.nl>
3367
3368         * src/SDCCsymt.c (checkSClass): no error for uninitialised absolute
3369           variables in code memory
3370         * support/regression/tests/absolute.c: added test for this
3371
3372 2006-10-15 Raphael Neider <rneider AT web.de>
3373
3374         * src/pic/pcode.c (InsertBankSel): suppress BANKSELs for one bank
3375           devices,
3376           (BankSelect): emit BANKSEL before touching linker-placed regs,
3377           fixes #1570934
3378
3379 2006-10-10 Raphael Neider <rneider AT web.de>
3380
3381         * src/SDCCmain.c (optionsTable): accept --stack-size for PICs,
3382         * src/pic/device.c (pic14_getSharebankSize,pic14_getSharebankAddress),
3383         * src/pic/main.c (_pic14_parseOptions),
3384         * src/pic/main.h: mostly reverted to previous state, now use results
3385             from SDCCmain.c's argument parsing
3386
3387 2006-10-10 Borut Razem <borut.razem AT siol.net>
3388
3389         * debugger/mcs51/break.[ch], debugger/mcs51/cmd.c,
3390           debugger/mcs51/sdcdb.[ch], debugger/mcs51/simi.c:
3391           [ 1185668 ] add gnu readline support to sdcdb -
3392           prepared for READLINE, not enabled yet,
3393           thanks to <tal.bav AT gmail.com>
3394
3395 2006-10-10 Raphael Neider <rneider AT web.de>
3396
3397         * src/pic16/pcode.c (pic16_pCode2str): use isACCESS_BANK macro
3398         * src/pic16/devices.inc,
3399         * device/include/pic16 (pic18f[24]620.h),
3400         * device/include/pic18fregs.h,
3401         * device/lib/pic16/pics.all,
3402         * device/lib/pic16/libdev/pic18f[24]{620,525}.c): added support for
3403             18f2620, 18f4620, 18f2525, and 18f4525 devices, thanks to
3404             Gary Plumbridge and Anton Strobl
3405
3406 2006-10-10 Raphael Neider <rneider AT web.de>
3407
3408         * src/pic/main.c (_pic14_parseOptions): added --stack-loc=NUM and
3409           --stack-siz=NUM options to configure the argument passing stack
3410         * src/pic/main.h: added stackLocation and stackSize to pic14_options_t
3411         * src/pic/device.c (mapRegister): catch out-of-memory SIGSEGVs,
3412           (pic14_getSharebankSize): obey --stack-siz=NUM,
3413           (pic14_getSharebankAddress): obey --stack-loc=NUM
3414
3415 2006-10-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3416
3417         * doc/sdccman.lyx: added to the manual
3418         * doc/figures/ddd_example.png: added (neither pdflatex nor
3419         most browsers seem to like the .eps file)
3420
3421 2006-10-06 Bernhard Held <bernhard AT bernhardheld.de>
3422
3423         * src/SDCCglue.c (tempfileandname): changed un*x tmp search paths
3424         to /tmp and /var/tmp acc. LSB
3425         * src/SDCCast.c (addCast): Fixed bug 1571231: promote in case of
3426         RESULT_TYPE_IFX
3427         * support/regression/tests/onebyte.c: added test
3428
3429 2006-10-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3430
3431         * src/mcs51/gen.c: emitcode for "add a,0x%02x" requires only 8 bits.
3432
3433 2006-10-05 Borut Razem <borut.razem AT siol.net>
3434
3435         * partially fixed [ 1570701 ] peephole - not replacing code from multiline macros,
3436           thanks to dfulab:
3437           - sdcc.dsw: changed property eol-style to CRLF
3438           - support/scripts/resource.rc: replaced references to "afxres.h" with "winres.h"
3439
3440 2006-10-04 Raphael Neider <rneider AT web.de>
3441
3442         * device/include/pic/{pic16f84.h,pic16f84a.h},
3443         * device/lib/pic/libdev/{pic16f84.c,pic16f84a.c}: added PORT[AB]_bits
3444           from patch #1522504, thanks to Robas Teodor
3445
3446 2006-10-02 Maarten Brock <sourceforge.brock AT dse.nl>
3447
3448         * as/link/z80/lkarea.c: essentially reverted lnksect() to #4380 which
3449           fixes bug 1566015
3450
3451 2006-10-01 Maarten Brock <sourceforge.brock AT dse.nl>
3452
3453         * src/pic16/glue.c (pic16emitMaps),
3454         * src/pic/glue.c (pic14emitMaps): hopefully fixed bug 1568779
3455         * device/lib/gets.c: fixed bug 1568829,thanks Philipp Krause
3456         * device/lib/pic16/libc/string/memcpypgm2ram.c,
3457         * device/lib/pic16/libc/string/memcpyram2ram.c: fixed bug 1568836, thanks
3458           Philipp Krause
3459         * as/mcs51/asmain.c (asmbl, newdot): fixed problems with absolute areas
3460         * as/link/mcs51/lkmem.c (summary2): reverted, do do count abs segments
3461
3462 2006-09-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3463
3464         * support/librarian/sdcclib.c: Added option -l.
3465         * as/link/mcs51/lkmem.c: don't use absolute segments to compute memory
3466           usage totals.
3467         * device/lib/make51lib.bat: added.  Allows building mcs51 libraries easily
3468           using Windows command prompt.
3469
3470 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
3471
3472         * device/lib/libsdcc.lib: added module rand
3473         * src/ds390/ralloc.c (rematStr),
3474         * src/hc08/ralloc.c (rematStr),
3475         * src/mcs51/ralloc.c (rematStr),
3476         * src/z80/ralloc.c (rematStr): made output more consistent
3477         * src/mcs51/gen.c: cosmetic changes
3478
3479 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
3480
3481         * src/port.h: added mem.cabs_name to PORT
3482         * src/ds390/main.c,
3483         * src/hc08/main.c,
3484         * src/mcs51/main.c,
3485         * src/pic16/main.c,
3486         * src/pic/main.c,
3487         * src/xa51/main.c,
3488         * src/z80/main.c: added cabs_name initializers
3489         * src/SDCCglue.c (emitStaticSeg): allocate and initialize absolute
3490           constants
3491           (emitMaps): emit absolutes in code memory into cabs_name
3492         * src/SDCCmem.c,
3493         * src/SDCCmem.h: added memory map c_abs and defined CABS_NAME
3494         * src/ds390/gen.c (genCodePointerGet): fixed bug if left is a literal
3495         * support/regression/fwk/include/testfwk.h: added define for at
3496         * support/regression/tests/absolute.c: added, new
3497
3498 2006-09-29 Maarten Brock <sourceforge.brock AT dse.nl>
3499
3500         * src/mcs51/gen.c (genPlusIncr, genMinusDec, genAddrOf): small
3501           optimizations, see also patch 887161 by Stas Sergeev
3502         * src/mcs51/peeph.def(104, 207, 209, 212): disabled as they do not seem
3503           to be necessary anymore,
3504           (102, 103, 104, 127): renamed all occurances of bp to _bp
3505
3506 2006-09-27 Maarten Brock <sourceforge.brock AT dse.nl>
3507
3508         * device/include/mcs51/at89c51snd1c.h: fixed MSK_SREQ definition
3509           thanks Weston T. Schmidt for patch 1555221
3510         * src/mcs51/peeph.def: renamed rule 257 to 257.a, added 257.b
3511         * src/SDCCicode.c(geniCodeMultiply): small optimization
3512
3513 2006-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
3514
3515         * device/include/stdlib.h: added rand prototypes
3516         * device/lib/rand.c: new, added
3517         * device/lib/Makefile.in: added rand.c
3518         * src/z80/peeph.def,
3519         * src/z80/peeph-gbz80.def,
3520         * src/z80/peeph-z80.def: updated conditonals, fixed bug 1565908
3521
3522 2006-09-20 Raphael Neider <rneider AT web.de>
3523
3524         * device/lib/pic16/libio/i2c/i2cnack.c (i2c_nack): fixed ACKDT bit
3525
3526 2006-09-19 Maarten Brock <sourceforge.brock AT dse.nl>
3527
3528         * as/link/aslink.h: cosmetic changes
3529         * as/link/mcs51/Makefile.in,
3530         * as/link/z80/Makefile.in: fixed build on CF where VPATH is used
3531
3532 2006-09-17 Maarten Brock <sourceforge.brock AT dse.nl>
3533
3534         * as/link/aslink.h,
3535         * as/link/mcs51/aslink.h,
3536         * as/link/z80/aslink.h: merged and moved to as/link/
3537         * as/link/lkstore.c,
3538         * as/link/mcs51/lkstore.c: moved to as/link/
3539         * as/link/clean.mk: remove *.o
3540         * as/link/mcs51/alloc.h: deleted
3541         * as/link/mcs51/lkarea.c: added lnksect prototype
3542         * as/link/mcs51/lkdata.c,
3543         * as/link/mcs51/lklex.c,
3544         * as/link/mcs51/lkmain.c: renamed as_getline to lk_getline
3545         * as/link/mcs51/lkmem.c,
3546         * as/link/mcs51/lknoice.c: removed include strcmpi.h
3547         * as/link/mcs51/lksym.c: include stdlib.h instead of malloc.h or alloc.h
3548         * as/link/mcs51/aslink.dsp,
3549         * as/link/mcs51/Makefile.aslink,
3550         * as/link/mcs51/Makefile.bcc,
3551         * as/link/mcs51/Makefile.in: updated for moved files
3552         * as/link/z80/lkarea.c,
3553         * as/link/z80/lkhead.c,
3554         * as/link/z80/lklex.c,
3555         * as/link/z80/lklibr.c,
3556         * as/link/z80/lklist.c,
3557         * as/link/z80/lkmain.c,
3558         * as/link/z80/lkrloc.c,
3559         * as/link/z80/lksym.c: synced with mcs51
3560         * as/link/z80/lkdata.c,
3561         * as/link/z80/lkeval.c,
3562         * as/link/z80/lkihx.c,
3563         * as/link/z80/lks19.c: cosmetic changes
3564         * as/link/z80/Makefile.in,
3565         * as/link/z80/linkgbz80.dsp,
3566         * as/link/z80/linkz80.dsp: updated for moved files
3567
3568 2006-09-16 Borut Razem <borut.razem AT siol.net>
3569
3570         * debugger/mcs51/sdcdb.c: partially fixed
3571           [ 1203664 ] sdcdb fails to open files w. two "." periods
3572         * debugger/mcs51/simi.c, debugger/mcs51/symtab.c,
3573           debugger/mcs51/symtab.h: fixed indenting
3574         * configure.in, configure: up to date with latest Maarten's changes
3575
3576 2006-09-15 Maarten Brock <sourceforge.brock AT dse.nl>
3577
3578         as/link/mcs51
3579         as/aslink.dsp,                  as/link/mcs51/aslink.dsp,
3580         as/link/mcs51/aslink.h,         as/mcs51/aslink.h,
3581         as/link/mcs51/aslink.mak,       as/mcs51/aslink.mak,
3582         as/link/mcs51/lkaomf51.c,       as/mcs51/lkaomf51.c,
3583         as/link/mcs51/lkarea.c,         as/mcs51/lkarea.c,
3584         as/link/mcs51/lkdata.c,         as/mcs51/lkdata.c,
3585         as/link/mcs51/lkeval.c,         as/mcs51/lkeval.c,
3586         as/link/mcs51/lkhead.c,         as/mcs51/lkhead.c,
3587         as/link/mcs51/lkihx.c,          as/mcs51/lkihx.c,
3588         as/link/mcs51/lklex.c,          as/mcs51/lklex.c,
3589         as/link/mcs51/lklibr.c,         as/mcs51/lklibr.c,
3590         as/link/mcs51/lklist.c,         as/mcs51/lklist.c,
3591         as/link/mcs51/lkmain.c,         as/mcs51/lkmain.c,
3592         as/link/mcs51/lkmem.c,          as/mcs51/lkmem.c,
3593         as/link/mcs51/lknoice.c,        as/mcs51/lknoice.c,
3594         as/link/mcs51/lkrloc.c,         as/mcs51/lkrloc.c,
3595         as/link/mcs51/lks19.c,          as/mcs51/lks19.c,
3596         as/link/mcs51/lkstore.c,        as/mcs51/lkstore.c,
3597         as/link/mcs51/lksym.c,          as/mcs51/lksym.c,
3598         as/link/mcs51/Makefile.aslink,  as/mcs51/Makefile.aslink,
3599         as/link/mcs51/alloc.h,
3600         as/link/mcs51/clean.mk,
3601         as/link/mcs51/conf.mk,
3602         as/link/mcs51/Makefile.bcc,
3603         as/link/mcs51/Makefile.in,
3604         as/link/mcs51/readme.390,
3605         as/link/mcs51/strcmpi.c,
3606         as/link/mcs51/strcmpi.h,
3607         as/mcs51/clean.mk,
3608         as/mcs51/Makefile.bcc,
3609         as/mcs51/Makefile.in,
3610         configure,
3611         Makefile.in,
3612         sdcc.dsw: moved mcs51 linker to as/link/mcs51
3613
3614 2006-09-14 Maarten Brock <sourceforge.brock AT dse.nl>
3615
3616         * as/link,
3617         * as/link/Makefile.in,
3618         * as/link/z80/linkgbz80.dsp,
3619         * as/link/z80/linkz80.dsp,
3620         * configure,
3621         * link,
3622         * link/clean.mk,
3623         * link/Makefile.in,
3624         * link/README,
3625         * link/z80,
3626         * link/z80/aslink.h,
3627         * link/z80/clean.mk,
3628         * link/z80/conf.mk,
3629         * link/z80/linkgbz80.dsp,
3630         * link/z80/linkz80.dsp,
3631         * link/z80/lkarea.c,
3632         * link/z80/lkdata.c,
3633         * link/z80/lkeval.c,
3634         * link/z80/lkgb.c,
3635         * link/z80/lkgg.c,
3636         * link/z80/lkhead.c,
3637         * link/z80/lkihx.c,
3638         * link/z80/lklex.c,
3639         * link/z80/lklibr.c,
3640         * link/z80/lklist.c,
3641         * link/z80/lkmain.c,
3642         * link/z80/lkrloc.c,
3643         * link/z80/lks19.c,
3644         * link/z80/lksym.c,
3645         * link/z80/Makefile.in,
3646         * Makefile.in,
3647         * sdcc.dsw: moved link/ to as/link/
3648
3649 2006-09-11 Maarten Brock <sourceforge.brock AT dse.nl>
3650
3651         * as/mcs51/i51mch.c (machine): fixed warning
3652
3653 2006-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
3654
3655         * as/mcs51/i51mch.c (machine): S_DJNZ fixed bug 1554318
3656
3657 2006-09-09 Borut Razem <borut.razem AT siol.net>
3658
3659         * debugger/mcs51/sdcdb.c, debugger/mcs51/simi.c:
3660           sdcdb WIN32 native port
3661         * src/clean.mk: fixed
3662
3663 2006-09-08 Borut Razem <borut.razem AT siol.net>
3664
3665         * doc/sdccman.lyx: SDCDB and ucSim are available on Win32 platforms.
3666
3667 2006-09-08 Raphael Neider <rneider AT web.de>
3668
3669         * src/pic16/main.c (_pic16_linkEdit,pic16_linkCmd),
3670         * src/pic/main.c(_pic14_do_link, linkCmd): pass "-w" and "-r"
3671             to gplink to disable processor mismatch warning and to allow
3672             the use of devices with only aliased (shared) memory banks,
3673           (_pic16_genAssemblerPreamble): include pXXX.inc on --mplab-comp
3674
3675 2006-09-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3676
3677         * doc/sdccman.lyx: Some re-formating plus example on using
3678           #pragma preproc_asm +/-
3679
3680 2006-09-07 Borut Razem <borut.razem AT siol.net>
3681
3682         * support/scripts/sdcc.nsi: added SDCDB executables in a separate
3683           section
3684
3685 2006-09-06 Borut Razem <borut.razem AT siol.net>
3686
3687         * support/scripts/sdcc.nsi: fixed Error: unterminated string parsing
3688           line at sdcc.nsi:153
3689         * sdcc/debugger/mcs51/simi.c: argsToCmdLine() fixes
3690
3691 2006-09-05 Borut Razem <borut.razem AT siol.net>
3692
3693         * configure.in, configure: support for winsock2
3694         * debugger/mcs51/break.h, debugger/mcs51/cmd.c,
3695           debugger/mcs51/cmd.h, debugger/mcs51/sdcdb.c,
3696           debugger/mcs51/sdcdb.h, debugger/mcs51/simi.c,
3697           debugger/mcs51/simi.h, debugger/mcs51/symtab.c,
3698           debugger/mcs51/symtab.h: sdcdb WIN32 native port
3699
3700 2006-09-05 Maarten Brock <sourceforge.brock AT dse.nl>
3701
3702         * src/SDCCopt.c (cnvToFcall): fixed bug 1551947 by updating OP_USES
3703           and OP_DEFS
3704         * support/regression/tests/bug1551947.c: new, added
3705         * src/SDCCsymt.h: strings are char* not byte*
3706
3707 2006-09-05 Raphael Neider <rneider AT web.de>
3708
3709         * device/lib/pic16/libdev/pic18f4550.c,
3710           device/include/pic16/pic18f4550.h: added PORTD/TRISD
3711             declarations/definitions from patch #1520949
3712
3713 2006-09-05 Raphael Neider <rneider AT web.de>
3714
3715         * src/pic16/gen.c (genPackBits): fix assignment to 8-bit,
3716           byte-aligned bitfields, fixes #1539278
3717
3718 2006-09-05 Raphael Neider <rneider AT web.de>
3719
3720         * src/pic/gen.c (genReceive): skip unreferenced arguments,
3721           fixes #1544120
3722
3723 2006-09-04 Borut Razem <borut.razem AT siol.net>
3724
3725         * support/scripts/sdcc.nsi: move ucSim executables to a separate section
3726         * support/scripts/sdcc_cygwin_mingw32: don't disable ucsim,
3727           -mno-cygwin is a part of the compiler name
3728         * support/scripts/sdcc_mingw32: don't disable ucsim
3729
3730 2006-09-03 Borut Razem <borut.razem AT siol.net>
3731
3732         * sdcc.spec: corrected for 2.6.0. Thanks to Christer Weinigel.
3733         * device/lib/Makefile.in device/lib/clean.mk: small but essential corrections
3734
3735 2006-09-03 Raphael Neider <rneider AT web.de>
3736
3737         * src/pic/ralloc.c,
3738         * src/pic/pcode.c (InitReuseRegs): allocate registers with pseudo
3739           indices >= 0x1000 to disambiguate them from fixed regs __at(addr),
3740           fixes #1550049
3741
3742 2006-09-01 Borut Razem <borut.razem AT siol.net>
3743
3744         * sim/ucsim/cmd.src/cmdutil.cc: #include <sys/time.h> and <unistd.h>
3745           to make ppc-osx happy
3746
3747 2006-08-31 Borut Razem <borut.razem AT siol.net>
3748
3749         * sim/ucsim/cmd.src/newcmdposix.cc: #include <assert.h>
3750         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
3751         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
3752         * support/regression/ports/ds390/spec.mk,
3753           support/regression/ports/mcs51/spec.mk,
3754           support/regression/ports/xa51/spec.mk: introduced DEV_NULL variable.
3755           To run regression tests in mingw environment:
3756           make DEV_NULL=NUL CC=gcc
3757
3758 2006-08-30 Borut Razem <borut.razem AT siol.net>
3759
3760         * sim/ucsim/cmd.src/newcmdposix.cc, sim/ucsim/cmd.src/newcmdposixcl.h,
3761           sim/ucsim/cmd.src/newcmdwin32.cc, sim/ucsim/cmd.src/newcmdwin32cl.h,
3762           sim/ucsim/app.cc, sim/ucsim/appcl.h, sim/ucsim/configure,
3763           sim/ucsim/configure.in, sim/ucsim/ddconfig_in.h, sim/ucsim/error.cc,
3764           sim/ucsim/errorcl.h, sim/ucsim/option.cc, sim/ucsim/optioncl.h,
3765           sim/ucsim/utils.cc, sim/ucsim/utils.h, sim/ucsim/cmd.src/Makefile.in,
3766           sim/ucsim/avr.src/avr.cc, sim/ucsim/avr.src/avrcl.h,
3767           sim/ucsim/cmd.src/bp.cc, sim/ucsim/cmd.src/bpcl.h,
3768           sim/ucsim/cmd.src/cmdconf.cc, sim/ucsim/cmd.src/cmdgui.cc,
3769           sim/ucsim/cmd.src/cmdmem.cc, sim/ucsim/cmd.src/cmdset.cc,
3770           sim/ucsim/cmd.src/cmdsetcl.h, sim/ucsim/cmd.src/cmdstat.cc,
3771           sim/ucsim/cmd.src/cmduc.cc, sim/ucsim/cmd.src/cmduccl.h,
3772           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
3773           sim/ucsim/cmd.src/command.cc, sim/ucsim/cmd.src/commandcl.h,
3774           sim/ucsim/cmd.src/get.cc, sim/ucsim/cmd.src/getcl.h,
3775           sim/ucsim/cmd.src/info.cc, sim/ucsim/cmd.src/newcmd.cc,
3776           sim/ucsim/cmd.src/newcmdcl.h, sim/ucsim/cmd.src/set.cc,
3777           sim/ucsim/cmd.src/show.cc, sim/ucsim/cmd.src/timer.cc,
3778           sim/ucsim/hc08.src/hc08.cc, sim/ucsim/hc08.src/hc08cl.h,
3779           sim/ucsim/s51.src/Makefile.in, sim/ucsim/s51.src/interrupt.cc,
3780           sim/ucsim/s51.src/interruptcl.h, sim/ucsim/s51.src/pca.cc,
3781           sim/ucsim/s51.src/pcacl.h, sim/ucsim/s51.src/port.cc,
3782           sim/ucsim/s51.src/portcl.h, sim/ucsim/s51.src/serial.cc,
3783           sim/ucsim/s51.src/serialcl.h, sim/ucsim/s51.src/timer0.cc,
3784           sim/ucsim/s51.src/timer0cl.h, sim/ucsim/s51.src/timer1.cc,
3785           sim/ucsim/s51.src/timer1cl.h, sim/ucsim/s51.src/timer2.cc,
3786           sim/ucsim/s51.src/timer2cl.h, sim/ucsim/s51.src/uc390.cc,
3787           sim/ucsim/s51.src/uc390cl.h, sim/ucsim/s51.src/uc390hw.cc,
3788           sim/ucsim/s51.src/uc390hwcl.h, sim/ucsim/s51.src/uc51.cc,
3789           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/wdt.cc,
3790           sim/ucsim/s51.src/wdtcl.h, sim/ucsim/sim.src/hw.cc,
3791           sim/ucsim/sim.src/hwcl.h, sim/ucsim/sim.src/mem.cc,
3792           sim/ucsim/sim.src/memcl.h, sim/ucsim/sim.src/obsolete.cc,
3793           sim/ucsim/sim.src/obsolete.h, sim/ucsim/sim.src/sim.cc,
3794           sim/ucsim/sim.src/simcl.h, sim/ucsim/sim.src/stack.cc,
3795           sim/ucsim/sim.src/stackcl.h, sim/ucsim/sim.src/test_mem_speed.cc,
3796           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
3797           sim/ucsim/xa.src/xa.cc, sim/ucsim/xa.src/xacl.h,
3798           sim/ucsim/z80.src/z80.cc, sim/ucsim/z80.src/z80cl.h:
3799           ucsim WIN32 native port
3800
3801 2006-08-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3802
3803         * doc/sdccman.lyx: added note on dynamic memory heap initialization
3804
3805 2006-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
3806
3807         * src/mcs51/gen.c (genAnd, genOr, genXor): fixed bug 1546986
3808         * src/ds390/gen.c (aopGetUsesAcc): handle AOP_DPTR2 and AOP_DPTRn too
3809
3810 2006-08-26 Maarten Brock <sourceforge.brock AT dse.nl>
3811
3812         * src/ds390/gen.c (genAnd, genOr, genXor): fixed bug 1546986
3813         * support/regression/tests/bug1546986.c: new, added
3814         * as/mcs51/.cvsignore,
3815         * debugger/mcs51/.cvsignore,
3816         * src/.cvsignore: deleted
3817
3818 2006-08-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3819
3820         * device/include/mcs51/P89c51RD2.h: fixed bug 1546936 (error in sbit
3821           definitions)
3822
3823 2006-08-20 Borut Razem <borut.razem AT siol.net>
3824
3825         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h:
3826           removed cl_listen_console::match(), cl_console::match(),
3827           restructured cl_commander::proc_input()
3828
3829 2006-08-16 Borut Razem <borut.razem AT siol.net>
3830
3831         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h,
3832           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
3833           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/uc.cc: code cleaning
3834
3835 2006-08-14 Borut Razem <borut.razem AT siol.net>
3836
3837         * support/regression/Makefile.in,
3838           support/regression/ports/pic14/gpsim.cmd,
3839           support/regression/ports/pic14/spec.mk,
3840           support/regression/ports/pic14/support.c:
3841           added pic14 regression test
3842
3843 2006-08-14 Maarten Brock <sourceforge.brock AT dse.nl>
3844
3845         * as/doc/asxhtm.html: documented changed ABS behaviour
3846         * as/doc/README: fixed some typos
3847
3848 2006-08-13 Maarten Brock <sourceforge.brock AT dse.nl>
3849
3850         * support/regression/tests/float_trans.c: disabled test if __STDC_IEC_559__
3851           not defined on host
3852
3853 2006-08-12 Borut Razem <borut.razem AT siol.net>
3854
3855         * support/regression/fwk/include/testfwk.h,
3856           support/regression/fwk/lib/testfwk.c,
3857           support/regression/generate-cases.py,
3858           support/regression/Makefile.in:
3859           regression test framework does not depend on function pointers and
3860           variable arguments
3861
3862 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
3863
3864         * device/include/stddef.h: c temporary hack to fix bug 1518273
3865
3866 2006-08-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3867
3868         * device/include/mcs51/cc2510fx.h: added
3869         * src/z80/z80.dsp, src/gbz80/gbz80.dsp: added support/Util/strcmpi.ch
3870           to projects.
3871
3872 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
3873
3874         * as/z80/assym.c (mlookup): ignore case when looking up mnemonics
3875         * as/z80/Makefile.in: added strcmpi.c
3876         * as/z80/z80adr.c: added upper case registers and lower case conditionals
3877         * support/Util/strcmpi.ch: added with intention to remove from mcs51/hc08
3878
3879 2006-08-08 Maarten Brock <sourceforge.brock AT dse.nl>
3880
3881         * device/lib/gbz80/asm_strings.s,
3882         * device/lib/gbz80/crt0_rle.s,
3883         * device/lib/gbz80/div.s,
3884         * device/lib/gbz80/mul.s,
3885         * device/lib/gbz80/shift.s,
3886         * device/lib/z80/asm_strings.s,
3887         * device/lib/z80/crt0_rle.s,
3888         * device/lib/z80/div.s,
3889         * device/lib/z80/mul.s,
3890         * device/lib/z80/shift.s: changed to all lower case menmonics except the
3891           flags which are all upper case
3892
3893 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
3894
3895         * as/z80/asm.h: made CASE_SENSITIVE 1
3896         * link/z80/aslink.h: made CASE_SENSITIVE 1
3897         * src/z80/gen.c (throughout): made all conditionals upper case
3898         * support/regression/tests/bug1503067.c: new
3899
3900 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
3901
3902         * src/z80/gen.c (aopPut): fixed bug !*ixy should be !*iyx,
3903           (shiftIntoPair): added case 2 for PAIR_IY,
3904           (setupToPreserveCarry): replaced parameters with iCode and check if
3905            PAIR_DE is in use to fix bug 1399290,
3906           (genPlus, genMinus): updated call to setupToPreserveCarry
3907         * support/regression/tests/bug1399290.c: new
3908
3909 2006-08-06 Maarten Brock <sourceforge.brock AT dse.nl>
3910
3911         * device/lib/Makefile.in (Z80SOURCES): enabled float support
3912         * sim/ucsim/z80.src/inst.cc (inst_rst): generate breakpoint on RST8,ACC==0
3913         * src/ds390/gen.c (shiftRLong),
3914         * src/hc08/gen.c (shiftLLong, shiftRLong): fixed bug 1533966
3915         * src/mcs51/gen.c (sameReg): changed to sameByte,
3916           (xch_a_aopGet): new,
3917           (shiftL2Left2Result, shiftR2Left2Result, shiftRLeftOrResult, shiftLLong,
3918            shiftRLong): fixed bug 1533966
3919         * src/z80/gen.c (shiftR2Left2Result, shiftL2Left2Result, genlshTwo,
3920           genLeftShiftLiteral, genrshTwo, genRightShiftLiteral): fixed bug 1533966
3921         * support/regression/Makefile.in: disabled z80, enabled ucz80
3922         * support/regression/tests/float_trans.c: enabled test for z80 and host
3923         * support/regression/tests/shifts2.c: new, for testing bug 1533966
3924
3925 2006-08-01 Borut Razem <borut.razem AT siol.net>
3926
3927         * src/mcs51/gen.c, src/dc390/gen.c: fixed warning:
3928           comparison is always false due to limited range of data type
3929           on PPC64 machine (openpower-linux1) where "char = unsigned char"
3930
3931 2006-08-01 Maarten Brock <sourceforge.brock AT dse.nl>
3932
3933         * sim/ucsim/hc08.src/hc08mac.h: removed faulty and unused add_u16_disp
3934         * sim/ucsim/hc08.src/hc08.cc: removed faulty and unused int8
3935         * sim/ucsim/z80.src/z80mac.h (add_u16_disp): use explicit signed char cast
3936         * sim/ucsim/z80.src/z80.cc: removed faulty and unused int8
3937
3938 2006-07-31 Borut Razem <borut.razem AT siol.net>
3939
3940         * sim/ucsim/configure, sim/ucsim/cmd.src/newcmdcl.h,
3941           sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/cmdutil.cc,
3942           sim/ucsim/z80.src/Makefile.in, sim/ucsim/configure.in,
3943           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/hc08.src/hc08.cc,
3944           sim/ucsim/ddconfig_in.h, sim/ucsim/s51.src/Makefile.in,
3945           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/serialcl.h,
3946           sim/ucsim/s51.src/uc51.cc, sim/ucsim/s51.src/serial.cc,
3947           sim/ucsim/app.cc, sim/ucsim/avr.src/Makefile.in:
3948           enable ucsim mingw compilation. Serial port is disabled,
3949           since it uses termios.h API, which is not available on native
3950           WIN32
3951
3952 2006-07-31 Borut Razem <borut.razem AT siol.net>
3953
3954         * Small Device C Compiler 2.6.0 released
3955         * support/scripts/sdcc.nsi: added FULL_DOC option
3956         * .version, doc/sdccman.lyx: changed sdcc version to 2.6.1
3957
3958 2006-07-28 Borut Razem <borut.razem AT siol.net>
3959
3960         * support/scripts/sdcc.nsi: remove $INSTDIR/include/asm/pic16/*.h
3961         * doc/INSTALL.txt: updated
3962
3963 2006-07-27 Borut Razem <borut.razem AT siol.net>
3964
3965         * device/lib/pic/Makefile.in, device/lib/pic/Makefile.subdir,
3966           device/lib/pic/libdev/Makefile.in: fixed bug
3967           [ 1438354 ] pic libsdcc: distclean doesn't work
3968         * device/lib/pic16/Makefile.in, device/lib/pic16/Makefile.subdir,
3969           device/lib/pic16/libio/Makefile.in: fixed bug
3970           [ 1438344 ] pic16 lib: clean doesn't work properly
3971         * doc/knownbugs.html removed [ 1438354 ] and [ 1438344 ] from the list
3972
3973 2006-07-26 Maarten Brock <sourceforge.brock AT dse.nl>
3974
3975         * device/lib/pic/libsdcc/fsdiv.c,
3976         * device/lib/pic/libsdcc/fsmul.c,
3977         * device/lib/pic16/libsdcc/float/fsdiv.c,
3978         * device/lib/pic16/libsdcc/float/fsmul.c,
3979         * device/lib/_fsdiv.c,
3980         * device/lib/_fsmul.c: bugfix, handle too large and too small numbers
3981         * support/regression/tests/bug1520966.c: added
3982         * doc/knownbugs.html: removed [ 1520966 ] from the list
3983
3984 2006-07-25 Borut Razem <borut.razem AT siol.net>
3985
3986         * configure.in, configure, sdccconf_in.h: fixed bug
3987           [ 1519095 ] regression test onebyte.c fails on ppc64 host
3988         * doc/knownbugs.html: removed [ 1519095 ] from the list
3989
3990 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
3991
3992         * doc/knownbugs.html: added, contains list of known bugs at release
3993         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
3994
3995 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
3996
3997         * device/include/mcs51/compiler.h: added SFRX for xdata based special
3998           function registers and corrected defaults with additional warning
3999         * device/lib/malloc.c: cosmetic changes
4000         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
4001         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
4002           (fillGaps): and used it
4003
4004 2006-07-20 Raphael Neider <rneider AT web.de>
4005
4006         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
4007           output unless SDCCPICDEBUG is set
4008         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
4009           output if SILENT is set
4010
4011 2006-07-11 Borut Razem <borut.razem AT siol.net>
4012
4013         * doc/README.txt: updated
4014
4015 2006-07-10 Borut Razem <borut.razem AT siol.net>
4016
4017         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
4018           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
4019           in WIN32 installation
4020         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
4021           release candidate 1
4022
4023 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
4024
4025         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
4026         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
4027
4028 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
4029
4030         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
4031
4032 2006-07-06 Borut Razem <borut.razem AT siol.net>
4033
4034         * support/regression/tests/bitfields.c:
4035           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
4036         * support/regression/tests/constantRange.c:
4037           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
4038
4039 2006-07-04 Borut Razem <borut.razem AT siol.net>
4040
4041         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
4042           src/port.mk,
4043           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
4044           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
4045           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
4046           reverted changes from 2006-07-03
4047         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
4048         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
4049           added CPPFLAGS, used by the host port
4050
4051 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
4052
4053         * support/regression/valdiag/tests/switch.c,
4054         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
4055         * support/regression/tests/libmullong.c: fixed for host
4056         * support/regression/ports/host/spec.mk: disable all warnings for host,
4057         SDCC runs with --less-pedantic too
4058
4059 2006-07-03 Borut Razem <borut.razem AT siol.net>
4060
4061         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
4062           defined CPPFLAGS
4063         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
4064         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
4065           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
4066           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
4067           include ../port.mk
4068         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
4069           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
4070           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
4071           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
4072
4073 2006-07-02 Raphael Neider <rneider AT web.de>
4074
4075         * src/pic16/devices.inc,
4076         * device/include/pic16/pic18fregs.h,
4077         * device/include/pic16/pic18f4550.h,
4078         * device/lib/pic16/pics.all,
4079         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
4080
4081 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
4082
4083         * as/hc08/lkaomf51.c (OutputName),
4084         * as/mcs51/lkaomf51.c (OutputName),
4085         * as/z80/asmain.c (asmbl),
4086         * src/ds390/main.c (asmLineNodeFromLineNode),
4087         * src/hc08/ralloc.c (hc08_assignRegisters),
4088         * src/mcs51/main.c (asmLineNodeFromLineNode),
4089         * src/xa51/ralloc.c (checkRegMask),
4090         * src/xa51/gen.c (emitcode),
4091         * src/z80/gen.c (_emit2),
4092         * src/SDCCast.c (searchLitOp),
4093         * src/SDCCglobl.h,
4094         * support/packihx/packihx.c,
4095         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
4096         * src/ds390/gen.c (aopPutUsesAcc),
4097         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
4098         * support/regression/tests/libmullong.c (mullong_wrapper),
4099         * src/SDCCsymt.c (powof2),
4100         * src/SDCCast.c,
4101         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
4102         * src/SDCCsymt.h: added TYPE_TARGET_*
4103         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
4104         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
4105         SDCCast because 1) header problems 2) this is the right place
4106         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
4107         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
4108         prototype
4109
4110 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
4111
4112         * src/SDCCicode.h: removed buggy semicolon in unused macro
4113         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
4114         search for previous definiton of auto symbols too,
4115         (findPrevUse): fixed logic of emitWarnings
4116
4117 2006-06-26 Raphael Neider <rneider AT web.de>
4118
4119         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
4120           PCLATH and PCLATU on interrupts, potentially fixes #1505141
4121
4122 2006-06-25 Raphael Neider <rneider AT web.de>
4123
4124         * device/lib/pic/libm: NEW, added math library functions
4125         * device/lib/pic/libsdcc: NEW; added float support functions
4126         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
4127         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
4128           NEW, added math related headers
4129         * device/include/asm/pic/features.h: NEW
4130         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
4131           (popGet): allow larger offsets for AOP_PCODE,
4132           (genDataPointerSet): handle literals explicitly, more debug output,
4133           (genAssign): fixed for float using aopLiteral ;-)
4134         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
4135           GOTO initialisation routine
4136         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
4137           flag on registers, fixes #1469043 (local variables do not work)
4138         * src/pic/main.c (_pic14_do_link),
4139         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
4140           available
4141
4142 2006-06-25 Borut Razem <borut.razem AT siol.net>
4143
4144         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
4145           characters printed (not including the trailing '\0' used to end
4146           output to strings). Problem detected in regression test bug-927659.c.
4147           NOTE: printf() family functions should return int instead
4148           unsigned int!
4149         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
4150           specifier are printed as themselves
4151         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
4152           support flags, width and precision specifiers
4153
4154 2006-06-24 Borut Razem <borut.razem AT siol.net>
4155
4156         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
4157           to the list of sdcc tagrets not supporting bit type
4158         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
4159           testfor pic16 due to bug:
4160           [ 1511794 ] pic16: regression test bug-895992.c fails
4161
4162 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
4163
4164         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
4165         * src/SDCCglue.c (initPointer), fixed bug 1496419
4166         * support/regression/tests/bug1496419.c: new, added
4167
4168 2006-06-22 Borut Razem <borut.razem AT siol.net>
4169
4170         * support/regression/ports/pic16/support.c: use gpsim usart module from
4171           libgpsim_modules library
4172
4173 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
4174
4175         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
4176         IP0H to IPH0.
4177
4178 2006-06-19 Raphael Neider <rneider AT web.de>
4179
4180         * src/pic/glue.h,src/pic16/glue.h: added prototypes
4181         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
4182           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
4183           (pic14printExterns,pic14printPublics,pic16printPublics,
4184           pic16_printExterns): use new functions to emit symbols
4185           (picglue,pic16glue): emit publics before emitting externs
4186         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
4187           locally defined functions to avoid bug #1443651
4188         * support/regression/tests/bug-716242.c: removed pic16 workaround
4189         * support/regression/ports/pic16/spec.mk: ignore errors during build
4190
4191 2006-06-19 Raphael Neider <rneider AT web.de>
4192
4193         * src/pic/glue.h: added pic14aopLiteral prototype
4194         * src/pic/glue.c (pic14aopLiteral): return unsigned int
4195         * src/pic/gen.c: removed stdint.h dependency
4196           (aopGet): use Safe_strdup()
4197           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
4198           (genDataPointerSet): use pic14aopLiteral()
4199         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
4200           for pic16; thanks to Bernhard and Maarten
4201
4202 2006-06-18 Borut Razem <borut.razem AT siol.net>
4203
4204         * support/regression/tests/structflexarray.c: flexible array members
4205           not supported by gcc < 3
4206         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
4207           GUI tool by default
4208         * src/pic/gen.c: don't include [p]strdin.h on solaris
4209         * support/Util/pstdint.h: addad svn attributes
4210         * support/regression/tests/constantRange.c,
4211           support/regression/tests/rotate.c: include inttypes.h instead
4212           stdint.h on solaris, addad svn attributes
4213
4214 2006-06-18 Raphael Neider <rneider AT web.de>
4215
4216         * src/SDCCsymt.c (initCSupport): change return type of divschar to
4217           int for PIC16
4218         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
4219           (pic16_genMinusBits): simplified sign-extension
4220           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
4221             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
4222             adjusted to correctly handle mixed-signed operands, disabled
4223             now unused multiplciation routines
4224         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
4225           (assignResultValue): added argument denoting the size of the result
4226             as returned by the function (fixes upcasts in assigning from
4227             function calls: char foo(); int i = foo();)
4228           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
4229             function result to assignResultValue
4230           (genMult): disabled inlined multiplication code
4231           (genDiv): augmented to also handle the modulus operator, fixed to
4232             handle mixed-signed operands correctly
4233           (genMod): simply call genDiv, disabled unused code
4234           (genAssign): fixed missing (sign-)extension on result
4235         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
4236             valid char operands, allow signed operands for native code, added
4237             division and modulo operator handling
4238         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
4239
4240         As a consequence, onebyte.c (if split into two files) and muldiv.c
4241         pass regression tests.
4242
4243 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4244
4245         * doc/Makefile.in: two runs of makeindex seem needed to get
4246         correct page references in the index of sdccman.pdf
4247         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
4248
4249 2006-06-17 Borut Razem <borut.razem AT siol.net>
4250
4251         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
4252
4253 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4254
4255         * doc/sdccman.lyx: updated, added (porting source code, debugging),
4256         mentioned ec2drv and paulmon
4257
4258 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
4259
4260         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
4261           consecutive abs areas
4262           (find_empty_space, allocate_space): added map to handle codemap or
4263            xdatamap,
4264           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
4265            absolute idata and xdata
4266         * as/mcs51/lkmem.c (summary2): updated legend
4267
4268 2006-06-16 Raphael Neider <rneider AT web.de>
4269
4270         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
4271
4272 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
4273
4274         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
4275           1208515
4276         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
4277
4278 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
4279
4280         * src/port.h (struct PORT): added field gp_tags, to hold the tag
4281         value of generic pointers,
4282         * src/avr/main.c,
4283           src/ds390/main.c,
4284           src/hc08/main.c,
4285           src/izt/i186.c,
4286           src/izt/tlcs900h.c,
4287           src/mcs51/main.c,
4288           src/pic/main.c,
4289           src/pic16/main.c,
4290           src/xa51/main.c,
4291           src/z80/main.c: PORT structure, added elements for gp_tags field,
4292         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
4293         fields in the PORT structure of each port,
4294         * src/SDCCast.c (decorateType): allow processing of generic pointers
4295         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
4296         S_FIXED symbols
4297
4298 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
4299
4300         * link/z80/lkgb.c,
4301         * link/z80/lkgg.c,
4302         * src/pic16/gen.c,
4303         * src/pic16/main.c,
4304         * src/pic16/pcode.c,
4305         * src/pic/main.c,
4306         * src/pic/pcoderegs.c,
4307         * src/SDCCicode.c,
4308         * src/SDCCmain.c,
4309         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
4310           bug 1504689 on minGW
4311
4312 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4313
4314         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
4315
4316 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
4317
4318         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
4319
4320 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
4321
4322         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
4323           for optimization
4324
4325 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
4326
4327         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
4328         to a char variable. Fixed bug #1504211
4329         * device/include/pic16/adc.h,
4330         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
4331         and fixed bug #1364390
4332
4333 2006-06-10 Borut Razem <borut.razem AT siol.net>
4334
4335         * CVSROOT: removed the CVS left-over
4336
4337 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
4338
4339         * as/hc08/asmain.c (asexit),
4340         * as/hc08/lkmain.c (lkexit),
4341         * as/mcs51/asmain.c (asexit),
4342         * as/mcs51/lkmain.c (lkexit),
4343         * src/SDCCglue.c (DEFSETFUNC),
4344         * src/SDCCmain.c (linkEdit, assemble),
4345         * support/librarian/sdcclib.c (AddRel),
4346           replaced unlink() by standard C remove()
4347         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
4348         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
4349           gatherImplicitVariables): new, added to fix bug 608752,
4350           (createFunction): added gatherImplicitVariables()
4351         * src/SDCCast.h: added createRMW prototype
4352         * src/SDCCsymt.h (struct symbol): added infertype
4353         * support/regression/tests/bug608752.c: new, added
4354
4355 2006-06-10 Raphael Neider <rneider AT web.de>
4356
4357         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
4358           multibyte dummy reads (fixes #1503234)
4359
4360 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
4361
4362         * device/include/mcs51/compiler.h: new, added header file to enable
4363           creating common sfr definition header files for different compilers
4364
4365 2006-06-05 Raphael Neider <rneider AT web.de>
4366
4367         * src/pic16/{pcode.h,genarith.c}:
4368           introduced pCodeOp combining any two pCodeOps (previously only
4369           two register operands could be combined), removed pcop2 from
4370           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
4371         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
4372         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
4373           rewritten to use new PO_TWO_OPS
4374         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
4375         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
4376           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
4377           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
4378           (pic16_get_op): embraced return arg to allow #define return(x),
4379             added new case for combined opcodes
4380           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
4381           (pic16_pCode2str,pic16_getRegFrompCodeOp,
4382            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
4383
4384 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
4385
4386         * src/SDCCval.c (checkConstantRange): added
4387         * src/SDCCval.h: added checkConstantRange
4388         * support/Util/SDCCerr.c,
4389         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
4390         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
4391         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
4392         * src/SDCCast.c (decorateType): added checkConstantRange,
4393         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
4394         can be emitted with the correct always true/false warning,
4395         added optimization for double '!';
4396         result of decorateType() must be assigned back to the tree, because
4397         decorateType() can change the tree
4398         * src/SDCCicode.c (geniCodeLogic),
4399         (geniCodeAssign): replaced new checkConstantRange, added warnings,
4400         (checkConstantRange): removed, it was only a fragment which never
4401         emitted a warning
4402         * src/SDCCsymt.c (computeType): fixed promotion for
4403         "-1 < (unsigned bit) b"
4404         * src/pic/ralloc.c (packRegsForAssign),
4405         * src/pic16/ralloc.c (packRegsForAssign),
4406         * src/hc08/ralloc.c (packRegsForAssign),
4407         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
4408         from mcs51
4409         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
4410         * support/regression/tests/constantRange.c: added
4411         * support/valdiag/tests/constantRange.c: added
4412         * support/valdiag/valdiag.py: added -DPORT_HOST=1
4413
4414 2006-06-02 Borut Razem <borut.razem AT siol.net>
4415
4416         * support/regression/ports/pic16/support.c: increase stack size
4417           to 255 bytes
4418         * support/regression/Makefile.in: sort tests by name so that the
4419           resutlts can be compared on different machines / platforms
4420
4421 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
4422
4423         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
4424         * src/ds390/gen.c (emitLabel): new, added,
4425           (genDjnz): fixed stack overflow bug,
4426           (throughout): cosmetic changes to sync with mcs51/gen.c,
4427           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
4428         * src/mcs51/gen.c (genEndFunction): small optimization,
4429           (throughout): cosmetic changes to sync with ds390/gen.c
4430
4431 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
4432
4433         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
4434           (_print_format): fixed printing pointers
4435         * src/mcs51/gen.c (emitLabel, movb): new, added,
4436           (genAssign): small optimization,
4437           (genDjnz): fixed stack overflow bug,
4438           (throughout): replaced sprintf with SNPRINTF,
4439           replaced mcs51_regWithIdx with REG_WITH_INDEX,
4440           replaced emitcode("mov", "b,...") with MOVB(...),
4441           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
4442           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
4443         * src/mcs51/peeph.def: added rules 140 and 264
4444         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
4445           so they may get optimized into registers
4446
4447 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
4448
4449         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
4450           immediately when encountered,
4451           (printUsage): always use stderr even on windows
4452
4453 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
4454
4455         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
4456         (processParms): fixed bug #1247551
4457         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
4458         parseCmdLine, main): print '--version' to stdout,
4459         print 'help' to stdout if --help is given,
4460         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
4461         arguments are given; fixed --help
4462
4463 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
4464
4465         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
4466         * support/regression/tests/bug-1493710.c: added
4467
4468 2006-05-27 Borut Razem <borut.razem AT siol.net>
4469
4470         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
4471           static instead auto
4472         * support/regression/ports/pic16/support.c: increase stack size
4473           from default 64 bytes to 128 bytes
4474         * support/regression/tests/staticinit.c,
4475           support/regression/tests/float.c: regression tests fully enabled
4476           for pic16 port by putting the initialized data arrays into the code
4477           section
4478         * support/regression/ports/pic16/spec.mk: don't link default libraries.
4479           This was changed by mistake in the previous version.
4480
4481 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
4482
4483         * src/pic16/gen.c (genFunction, genEndFunction): some
4484         beautifications, fixed bug with falsely restoring FSR2 in large
4485         stack model, thanks to Beau E. Cox for reporting the bug
4486
4487 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
4488
4489         * debugger/mcs51/break.c,
4490         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
4491           use %p to print pointers, made address variables unsigned
4492         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
4493         * debugger/mcs51/symtab.c (parseSymbol): must return something
4494         * src/mcs51/gen.c (aopForSym): small optimization,
4495            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
4496           (freeAsmop): added missing break,
4497           (aopPut): removed parameter bvolatile, determine it inside the function,
4498           (saveRegisters, unsaveRegisters): small optimization,
4499           (genIpush): removed pointless check,
4500           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
4501           replaced sprintf with SNPRINTF,
4502           replaced strcpy with strncpyz,
4503           updated aopPut calls,
4504           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
4505         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
4506
4507 2006-05-24 Borut Razem <borut.razem AT siol.net>
4508
4509         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
4510           modification of test for the pic16 port, put the array to the code
4511           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
4512
4513 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
4514
4515         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
4516         * support/Util/pstdint.h: added
4517
4518 2006-05-22 Borut Razem <borut.razem AT siol.net>
4519
4520         * src/regression/Makefile: removed bool2.c test, added -q linker option
4521         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
4522           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
4523           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
4524           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
4525           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
4526           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
4527           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
4528           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
4529           define SUPPORT_BIT_TYPES 0, removed unused bit variables
4530
4531 2006-05-22 Raphael Neider <rneider AT web.de>
4532
4533         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
4534           bug #1492360 (problematic due to generic pointers, see code)
4535
4536 2006-05-22 Borut Razem <borut.razem AT siol.net>
4537
4538         * support/regression/ports/pic16/specs.mk: removed stack size linker
4539           directive
4540         * support/regression/tests/array.c,
4541           support/regression/tests/bitopcse.c,
4542           support/regression/tests/bug-908454.c,
4543           support/regression/tests/malloc.c: modified for pic16 regression test
4544         * support/regression/tests/bitfields.c:
4545           pic16 - excluded bitfileds of size > 8
4546         * support/regression/tests/bp.c: pic16 - reduced data size
4547         * support/regression/tests/bug-221100.c: pic16 - reduced data size
4548         * support/regression/tests/bug-460010.c:
4549           pic16 - used the absolute address the fits in memory
4550         * support/regression/tests/bug-716242.c:
4551           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
4552         * support/regression/tests/float.c:
4553           pic16 - excluded - data size too big
4554         * support/regression/tests/onebyte.c:
4555           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
4556         * support/regression/tests/shifts.c:
4557           pic16 - function names probably have to differ in first X characters
4558           (gpasm limitation?)
4559         * support/regression/tests/staticinit.c:
4560           pic16 - excluded some tests due error: no target memory available for
4561           section ".idata"
4562
4563 2006-05-22 Borut Razem <borut.razem AT siol.net>
4564
4565         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
4566           second try. Thanks Stas Sergeev once more.
4567
4568 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
4569
4570         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
4571           (genLeftShift, genRightShift): fixed bug 1491627
4572         * src/hc08/peeph.def (rules 7, 8.x): added
4573         * support/regression/tests/shifts.c (ShiftLeftByParam,
4574           ShiftRightByParam, testShiftByParam): added to test variable shifting
4575
4576 2006-05-20 Raphael Neider <rneider AT web.de>
4577
4578         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
4579         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
4580           (allocReg): add only new registers to dynAllocRegs,
4581           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
4582             #1489055, #1445850, and probably #1483693
4583
4584 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
4585
4586         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
4587         bug in for-loop that didn't emit the last of CONFIG and ID registers
4588
4589 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
4590
4591         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
4592           with offset
4593         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
4594           1489016, 1434401 and 1490124
4595         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
4596           1489016, 1434401 and 1490124
4597
4598 2006-05-17 Borut Razem <borut.razem AT siol.net>
4599
4600         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
4601           thanks Stas Sergeev
4602
4603 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
4604
4605         * device/include/mcs51/P89c51RD2.h,
4606         * device/include/mcs51/P89LPC901.h,
4607         * device/include/mcs51/P89LPC922.h,
4608         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
4609
4610 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
4611
4612         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
4613         to fix missing stack pragma in compiled binary object file,
4614
4615 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
4616
4617         * support/packihx/configure.in,
4618         * support/packihx/configure: removed warning, autoconf >= 2.5x can
4619         determine sizeof basic types even while cross compiling
4620
4621 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
4622
4623         * src/avr/gen.c (aopop),
4624         * src/ds390/gen.c (aopOp),
4625         * src/hc08/gen.c (aopOp),
4626         * src/mcs51/gen.c (aopop),
4627         * src/pic16/gen.c (pic16_aopOp),
4628         * src/pic/gen.c (aopOp),
4629         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
4630         if size of operand is smaller than spill location
4631
4632 2006-05-12 Borut Razem <borut.razem AT siol.net>
4633
4634         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
4635           have to have CR/LF line endings even if they are checked out on *nix
4636           or on WIN32 in cygwin binmode
4637
4638 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
4639
4640         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
4641         * device/include/ds80c390.h: added sfr16 definitions
4642         * src/ds390/gen.c,
4643         * src/ds390/gen.h,
4644         * src/ds390/main.c,
4645         * src/ds390/ralloc.c,
4646         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
4647           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
4648           bit returning functions
4649         * support/regression/tests/sfr16.c: enabled test on ds390
4650
4651 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4652
4653         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
4654         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
4655
4656 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
4657
4658         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
4659         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
4660           (cl_address_space constructor): removed expensive initialization,
4661           (cl_address_space::get_cell): extended for late initialization,
4662           (cl_address_space::*): use late initialization,
4663           (cl_address_decoder::activate): removed expensive initialization,
4664           This reduced regression test running time by 25%
4665
4666 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
4667
4668         * packihx/,
4669         * configure.in,
4670         * configure,
4671         * sdcc.dsw,
4672         * Makefile.bcc,
4673         * Makefile.in,
4674         * support/packihx/Makefile.in,
4675         * support/packihx/clean.mk,
4676         * support/packihx/Makefile.bcc,
4677         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
4678
4679 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4680
4681         * src/SDCCval.c (valNot): fix for regression test failure
4682           of not.c on big endian hosts
4683
4684 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
4685
4686         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
4687
4688 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
4689
4690         * device/lib/mcs51/Makefile.in: changed string comparison operator
4691           to = for POSIX compliance; == is bash extension
4692
4693 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
4694
4695         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
4696           kosmonaut_pirx
4697
4698 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
4699
4700         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
4701         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
4702         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
4703         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
4704         bug report #1478657,
4705
4706 2006-05-05 Borut Razem <borut.razem AT siol.net>
4707
4708         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
4709           making the html
4710
4711 2006-05-02 Borut Razem <borut.razem AT siol.net>
4712
4713         * doc/Makefile.in: removed *.ind dependency since there is no rule to
4714           create *.ind, which made make to fail if invoked with -j 2
4715
4716 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
4717
4718         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
4719           Hubert Sack for patch 1479782
4720
4721 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
4722
4723         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
4724
4725 2006-05-01 Raphael Neider <rneider AT web.de>
4726
4727         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
4728           (create_pic): store only prefix-free device name,
4729           (init_pic): check for device names with "16" prefix,
4730           (list_valid_pics),
4731         * src/pic/device.h (struct PIC_device),
4732         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
4733             stored device name,
4734         * device/include/pic/pic12f{635,675,629,683}.h,
4735         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
4736         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
4737         * device/include/pic/pic16f505.h,
4738         * device/lib/pic/libdev/pic16f505.c: removed
4739         * device/include/pic/pic14devices.txt: added support for pic12f
4740             devices, removed unsupported non 16-bit devices
4741             [above changes provided by patch from Zik Saleeba]
4742         * src/pic/*, src/pic16/*, device/include/pic16/*,
4743           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
4744
4745 2006-05-01 Borut Razem <borut.razem AT siol.net>
4746
4747         * configure.in, configure, doc/Makefile.in:
4748           sync with nightly build makefile - latex, dvipdf and dvips
4749           not needed any more
4750
4751 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
4752
4753         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
4754         in the library source
4755
4756 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
4757
4758         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
4759
4760 2006-04-28 Raphael Neider <rneider AT web.de>
4761
4762         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
4763         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
4764           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
4765         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
4766
4767 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
4768
4769         * device/lib/pic/libdev/Makefile.in,
4770         * device/lib/hc08/Makefile.in,
4771         * device/lib/gbz80/Makefile.in,
4772         * device/lib/z80/Makefile.in,
4773         * device/lib/ds390/Makefile.in,
4774         * device/lib/ds400/Makefile.in: added srcdir to include search path,
4775         thanks to Borut for the bug report
4776         * configure.in,
4777         * configure: always create doc/Makefile independent from --enable-doc
4778         * Makefile.in: always install from directory doc independent from
4779         --enable-doc
4780         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
4781         removed
4782         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
4783         * doc/Makefile.in: install *.txt if present
4784         * device/include/Makefile.in (install): added installation of pic/*.inc
4785         and pic/*.txt files again, they were erroneously removed
4786
4787 2006-04-28 Raphael Neider <rneider AT web.de>
4788
4789         * src/pic/{gen.c,main.h,pcode.c},
4790         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
4791             concerning signedness with casts
4792
4793 2006-04-28 Raphael Neider <rneider AT web.de>
4794
4795         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
4796             definition of an interrupt handler,
4797         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
4798             interrupt handler stuff from picglue() to separate routine,
4799           (picglue): enabled definition of intr handlers in files w/o main()
4800
4801 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
4802
4803         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
4804           compilation with MSVC 2005 Express Edition (VC8)
4805
4806 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
4807
4808         * device/lib/Makefile: fixed build of gbz80 lib
4809
4810 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
4811
4812         * support/regression/tests/bug-460010.c,
4813         * support/regression/tests/bug-524691.c,
4814         * support/regression/tests/bug-716242.c: removed conditional defines
4815           that are already in testfwk.h
4816
4817 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
4818
4819         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
4820           (AccAXRsh1): added, shift right by 1,
4821           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
4822            AccAXLrl1
4823         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
4824
4825 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
4826
4827         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
4828         remove cast to same type
4829         * src/SDCCast.c (decorateType): fix for RFE 1475742,
4830         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
4831         * as/z80/Makefile,
4832         * link/z80/Makefile: removed, they have moved to
4833         Makefile.in files
4834         * configure,
4835         * configure.in: replaced duplicate message about ucsim by missing sdcpp
4836         * install-sh: fix bug #1204398 by setting umask 0022
4837         * device/lib/Makefile: separate build of z80 and gbz80 lib
4838
4839 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
4840
4841         Enabled VPATH feature: changed nearly all Makefiles (149 files).
4842         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
4843
4844         One basic decision: e.g. src/clean.mk includes further files. In order
4845         to make this work there are two solutions:
4846         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
4847           run configure on them. This way they can use
4848           'include $(srcdir)/port-clean.mk'
4849         - always include clean.mk by the Makefile at the same level. To avoid
4850           that `make clean` tries to include and build Makefile.dep the
4851           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
4852           implemented, because now even `make uninstall` doesn't create
4853           Makefile.in. clean.mk could be eliminated by pasting it in
4854           Makefile.in.
4855
4856         * debugger/mcs51/Makefile.in: build own objects from library sources
4857         (SLIB, SDCC) in current directory
4858
4859         * configure, configure.in: renamed --disable-device-lib-build in
4860         --disable-device-lib; added --enable-doc, the required tools are
4861         searched by configure; added result message; the toolchain for the
4862         belonging ports are now only built, if the port is enabled.
4863
4864         * support/regression/*: all output is written in directory gen, because
4865         the fwk and ports directories don't livet in the build tree using vpath
4866
4867         * doc/sdccman.lyx: renamed --disable-device-lib-build to
4868         --disable-device-lib, added --enable-doc, added section VPATH
4869
4870         * sim/ucsim/configure.in,
4871         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
4872         z80 are enabled by default
4873
4874 2006-04-24 Raphael Neider <rneider AT web.de>
4875
4876         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
4877             to config word, "pic14_"-prefixed some extern functions
4878           (pic14_emitConfigWord): emit __config directive(s) if assignment to
4879             config word has been found
4880         * src/pic/device.h: added prototypes
4881         * src/pic/pcode.c: added "pic14_"-prefix where needed
4882         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
4883             fixup
4884         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
4885             words,
4886           (pic14emitRegularMap): ignore config words,
4887           (pic14createInterruptVect): moved generating __config directives away
4888           (picglue): have __config directives emitted
4889
4890 2006-04-24 Borut Razem <borut.razem AT siol.net>
4891
4892         * doc/Makefile: sync with nightly build makefile
4893
4894 2006-04-24 Raphael Neider <rneider AT web.de>
4895
4896         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
4897             registers that have not been assigned proper liveranges,
4898             fixes #1469504 and #1474602,
4899           (pCodeRegOptimizeRegUsage): fixed typo in comment
4900
4901 2006-04-24 Borut Razem <borut.razem AT siol.net>
4902
4903         * device/examples/main8051.c: deleted - it was removed from CVS
4904           24.mar.2000 and after that modified 18.feb.2001, so it reappered
4905           after the transition to Subversion
4906         * src/SDCCalloc.h: deleted - it was removed  from CVS
4907           3.feb.2001 and after that modified 18.feb.2001, so it reappered
4908           after the transition to Subversion
4909         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
4910           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
4911           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
4912           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
4913
4914 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
4915
4916         * as/asx8051.dsp: added mcs51/strcmpi.h
4917         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
4918         * as/hc08/aslink.h: updated lnksect prototype
4919         * as/hc08/asm.h,
4920         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
4921         * as/hc08/asmain.c,
4922         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
4923           (newdot): handle A_ABS
4924         * as/hc08/asout.c,
4925         * as/mcs51/asout.c (outarea): output address
4926         * as/hc08/lkaomf51.c,
4927         * as/mcs51/lkaomf51.c: disabled unused array UsageType
4928         * as/hc08/m08pst.c,
4929         * as/mcs51/i51pst.c,
4930         * as/z80/z80pst.c: "ABS" is not A_OVR
4931         * as/hc08/lkarea.c (newarea): read a_addr,
4932           (lnkarea): added codemap array, sort absolute areas to the front,
4933            combine all GSINITx/GSFINAL,
4934           (find_empty_space, allocate_space): new functions,
4935           (lnksect): return next address, handle absolute sections
4936         * as/mcs51/lkarea.c (newarea): read a_addr,
4937           lnksect2 prototype changed,
4938           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
4939           (find_empty_space, allocate_space): new, factored out of lnksect2,
4940           (lnksect2): return next address, handle absolute sections
4941         * as/hc08/lkhead.c,
4942         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
4943         * as/hc08/lklibr.c (addfile, fndsym),
4944         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
4945           index out of range and detect both '\' and '/'
4946         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
4947         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
4948           regression tests (ds390 cannot return bool yet)
4949         * doc/sdccman.lyx: changed version number, document changed --no-peep,
4950           document critical interrupts on z80, document changed SDCC define
4951         * src/asm.c (_asxxxx_mapping): fixed .org directive,
4952           (_a390_mapping): added .org directive
4953         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
4954           (genMultOneByte): fixed warnings
4955         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
4956           ones
4957         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
4958         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
4959           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
4960         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
4961         * src/pic16/main.c: removed newReg prototype
4962         * src/pic16/pcode.c,
4963         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
4964           warnings
4965         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
4966           ones
4967         * src/pic16/ralloc.c
4968         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
4969           to fix warnings
4970         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
4971           from short to PIC_OPTYPE
4972         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
4973         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
4974           optype from short to PIC_OPTYPE
4975         * src/port.h: made int_size unsigned to fix warnings
4976         * src/SDCC.y: fixed warning on MSVC
4977         * src/SDCCicode.c (getArraySizePtr): return unsigned int
4978         * src/SDCCopt.c (convertToFcall): fixed warnings
4979         * src/SDCCsymt.h: removed double prototype for genSymName
4980         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
4981           offset int to fix warnings
4982
4983 2006-04-22 Borut Razem <borut.razem AT siol.net>
4984
4985         * doc/sdccman.lyx, */Makefile, */Makefile.in:
4986           references to CVS replaced with Subversion
4987
4988 2006-04-21 Borut Razem <borut.razem AT siol.net>
4989
4990         * doc/sdccman.lyx, */Makefile, */Makefile.in:
4991           references to CVS replaced with Subversion
4992
4993 2006-04-19 Borut Razem <borut.razem AT siol.net>
4994
4995         * src/version.awk: adapted for svn
4996         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
4997           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
4998           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
4999           /binutils-avr/etc/*.vi, *.jin: removed all properties
5000           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
5001
5002 2006-04-19 Borut Razem <borut.razem AT siol.net>
5003
5004         * CVS to Subversion migration completed
5005
5006 2006-04-18 Borut Razem <borut.razem AT siol.net>
5007
5008         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
5009           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
5010
5011 2006-04-17 Borut Razem <borut.razem AT siol.net>
5012
5013         * device/include/Makefile.in: added pic/*.inc to the installation
5014
5015 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
5016
5017         * support/regression/collate-results.py: fixed output in case of
5018         a valdiag error
5019         * support/regression/generate-cases.py: fixed splitting of pathnames
5020         with dots
5021         * as/hc08/lklibr.c (addfile),
5022         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
5023
5024 2006-04-11 Raphael Neider <rneider AT web.de>
5025
5026         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
5027         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
5028         * src/pic16/pcode.c (assignValnums): fixed #1460578
5029
5030 2006-04-11 Raphael Neider <rneider AT web.de>
5031
5032         * device/lib/pic/libdev/*.c,
5033         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
5034           fixes #1468739, enables compilation in --std-c99 mode
5035         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
5036
5037 2006-04-11 Raphael Neider <rneider AT web.de>
5038
5039         * src/pic/device.c (find_device): removed debug output
5040           (list_valid_pics): enabled verbose listing of supported devices
5041         * device/include/stdbool.h: define bool as char for pic14/16 as well
5042
5043 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5044
5045         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
5046
5047 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
5048
5049         * .version: bumped version to 2.5.6
5050         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
5051
5052 2006-04-06 Raphael Neider <rneider AT web.de>
5053
5054         * .version: bumped version to 2.5.6 (pic14 ABI changed)
5055         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
5056         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
5057           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
5058             pic14_constructAbsMap
5059           (pic14printPublics): declare absolute global symbols as global
5060           (pic14createInterruptVect),
5061         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
5062           (newReg): assume new registers unused, use correct name in
5063             hashtable (reg->name instead of name), more debugLog output
5064         * src/pic/device.h (PIC_device): added fields for verbose output
5065         * src/pic/device.c: moved device definition to pic14devices.txt,
5066             added routines for runtime parsing of pic14devices.txt,
5067             added support for second config word
5068         * src/pic/main.c (_process_pragma): removed #pragma maxram,
5069           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
5070           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
5071           (_pic14_parseOptions): moved pCodeInitRegisters here
5072           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
5073         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
5074           (pCodeInitRegisters): rewrapped comments, perpared new approach to
5075             handling the pseudo stack
5076         * device/lib/Makefile.in: ignore failures in objects-pic16,
5077         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
5078         * device/lib/pic/NEWS: document new dependency on picXXX.lib
5079         * device/lib/pic/Makefile.subdir,
5080         * device/lib/pic16/Makefile.subdir: improved clean rules
5081         * device/lib/pic/libdev/: NEW, pic14 device libraries
5082         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
5083         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
5084         * device/include/Makefile.in: create subdir and install pic14 headers
5085         * device/include/pic/p16f_common.inc: removed unused declarations
5086         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
5087             PICs from inc2h.pl v1.6,
5088             replaced BIT_AT macros with struct declarations
5089         * device/include/pic/pic14devices.txt: definition of supported devices,
5090             all above improvements contributed by Zik Saleeba, thanks
5091         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
5092         * support/scripts/sdcc.nsi: also install pic14 device libraries and
5093             headers
5094
5095 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
5096
5097         * device/include/mcs51/c8051f410.h: added interrupt numbers,
5098         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
5099           thanks to Charles Olds
5100
5101 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5102
5103         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
5104
5105 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
5106
5107         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
5108         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
5109         * support/regression/bug1464657.c: added, new test
5110
5111 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
5112
5113         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
5114           version number
5115
5116 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
5117
5118         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
5119           --no-peep and --peep-file <file> are used don't use default rules but
5120           do use the <file>
5121
5122 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
5123
5124         * src/mcs51/gen.c (genCall): fixed bug 1457608
5125
5126 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5127
5128         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
5129         changes seem to cause (trigger?) problems with the build system.
5130
5131 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
5132
5133         * src/SDCCpeeph.c (operandsLiteral): new, added,
5134           (callFuncByName): inserted operandsLiteral
5135         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
5136
5137 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5138
5139         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
5140         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
5141
5142 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
5143
5144         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
5145           implemented patch 1120823 Thanks to Willy De la Court (normal
5146           interrupts need an interrupt number now if they are made critical),
5147           and enabled nesting of critical functions though not for gbz80
5148           (genCritical, genEndCritical): added functions
5149           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
5150         * src/z80/mappings.i: added "ei" to all mappings
5151
5152 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5153
5154         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
5155         submitted by the Debian SDCC maintainer Aurelien Jarno:
5156         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
5157         archive with gcc 4.1 on mips and wrote the patch"
5158
5159 2006-03-16 Raphael Neider <rneider AT web.de>
5160
5161         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
5162           the left operand is shorter than the result (c* = lit-c* + int),
5163           fixes bug #1450796
5164         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
5165           OP_SYMBOL
5166
5167 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
5168
5169         * src/.version: increased version number to 2.5.5
5170         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
5171         linking is done manually in pic16 port's _linkEdit,
5172         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
5173         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
5174         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
5175         allocate asmop as AOP_ACC,
5176         (aopForRemat): added parameter 'bool result' in function declaration,
5177         (pic16_aopGet): return AOP_ACC when accessing WREG,
5178         (pic16_popGetTempReg): minor modification,
5179         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
5180         'pic16_allocWithIdx',
5181         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
5182         calling function in absolute addresses,
5183         (genAssign): take into account AOP_ACC asmop,
5184         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
5185         * src/pic16/pcoderegs.c: some debug functions and lines added,
5186         * src/pic16/ralloc.c (decodeRegType): added but commented out,
5187         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
5188         register too,
5189         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
5190         call to allocReg, not by manually allocating a new one,
5191         (pic16_assignRegisters): now before going through the register
5192         allocating functions mark all registers as free. This eliminates some
5193         side effects resulting from peephole parser done earlier in the backbone
5194
5195 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
5196
5197         * src/SDCCicode.c (geniCodeLogic),
5198         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
5199
5200 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
5201
5202         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
5203           (genSend): bugfix, do not allocate and free twice,
5204           (shiftRLong): handle partially overlapping aops
5205         * support/regression/tests/bitopcse.c: fixed warning redefined idata
5206
5207 2006-03-08 Borut Razem <borut.razem AT siol.net>
5208
5209         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
5210           for pic16
5211
5212 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
5213
5214         * support/regression/tests/bug1409955.c: new, added
5215         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
5216         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
5217           (aopForSym, aopOp): increment asmop.allocated if reused,
5218           (freeAsmop): decrement asmop.allocated and check for zero instead of
5219           using asmop.freed,
5220           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
5221           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
5222            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
5223            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
5224            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
5225            genSignedRightShift, genRightShift, genDataPointerGet,
5226            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
5227            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
5228             in reverse order from allocation,
5229           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
5230             added swappedLR to keep track
5231         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
5232           pdata & code for GCC, z80, gbz80 & hc08
5233         * support/regression/tests/zeropad.c: moved defines to testfwk.h
5234
5235 2006-03-08 Raphael Neider <rneider AT web.de>
5236
5237         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
5238
5239 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
5240
5241         * device/include/mcs51/c8051f410.h: new SiLabs mcu
5242         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
5243         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
5244
5245 2006-03-06 Borut Razem <borut.razem AT siol.net>
5246
5247         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
5248           made the linker quiet
5249
5250 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
5251
5252         * src/pic16/gen.c (genPcall): fixed bug #1443644
5253         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
5254         which dumps before the function entry point a data byte which represents
5255         the number of the local variables used by the specified function, added
5256         'xinst' for initial support for Extended Instruction Support,
5257         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
5258         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
5259         port->fun_prefix anymore (may change later),
5260         (genFunction, genEndFunction): do not store/restore local registers for
5261         _main (this should take care the --main-return command line option in
5262         the future),
5263         (genOr): removed some legacy pic-port instructions,
5264         * src/pic16/genarith.c (genAddLit): re-enabled old code because
5265         performing operations with SFR's causes data to be written more than
5266         once to each SFR. Perhaps SFRs should be handled in special cases...
5267         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
5268         pcode.h
5269         * src/pic16/main.c (_process_pragma): stack bound checking did not take
5270         into account for stack starting position,
5271         (struct OPTIONS pic16_optionsTable): added command line argument
5272         --extended or -y for Extended Instruction Support,
5273         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
5274         (deassignLRs): *** perhaps the most important change, old 'for' code
5275         (commented out for reference), didn't account for some registers which
5276         were left marked 'not free' after a pointer operation. The change
5277         reduces register usage a lot in some cases
5278
5279 2006-03-04 Borut Razem <borut.razem AT siol.net>
5280
5281         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
5282           _clean
5283         * support/regression/tests/bug-524697.c: decreased array size for
5284           mcs51 to fit into the internal RAM
5285         * support/regression/Makefile.in: a little bit more verbose
5286
5287 2006-03-03 Borut Razem <borut.razem AT siol.net>
5288
5289         * support/regression/fwk/lib/testfwk.c,
5290           support/regression/fwk/include/testfwk.h: introduced function
5291           _prints(), nonrecursive _printn(), call _initEmu() from main()
5292         * support/regression/ports/gbz80/support.asm,
5293           support/regression/ports/ucz80/support.asm,
5294           support/regression/ports/z80/support.asm,
5295           support/regression/ports/ds390/support.c,
5296           support/regression/ports/hc08/support.c,
5297           support/regression/ports/host/support.c,
5298           support/regression/ports/mcs51/support.c,
5299           support/regression/ports/xa51/support.c: added empty _initEmu()
5300           function
5301         * support/regression/ports/pic16/gpsim.cmd,
5302           support/regression/ports/pic16/spec.mk,
5303           support/regression/ports/pic16/support.c,
5304           support/regression/Makefile.in: added pic16 regression test
5305
5306 2006-03-01 Raphael Neider <rneider AT web.de>
5307
5308         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
5309           genConstPointerGet): use safe way of generating MOVFF to cover
5310             literals as well as registers, fixes bug #1440527
5311         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
5312             dereference
5313           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
5314             more correctly, fixes bug #1232186
5315           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
5316         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
5317             gplink guess the correct processor in more cases, applied patch
5318             from Till Riedel attached to and fixing bug #1436552
5319
5320 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5321
5322         * support/regression/tests/array.c: added, contains check for #1434401
5323         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
5324
5325 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
5326
5327         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
5328         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
5329         * device/include/mcs51/c8051f326.h,
5330         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
5331         * device/include/mcs51/c8051f000.h,
5332         * device/include/mcs51/c8051f018.h,
5333         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
5334           PCON_IDLE,PCON_STOP and added sfr16 definitions
5335
5336 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
5337
5338         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
5339           genGetWord): fixed bug 1409955
5340
5341 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
5342
5343         * device/include/hc08/mc68hc908gp32.h,
5344         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
5345
5346 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
5347
5348         * src/SDCCast.c (constExprValue): return NULL if not a value
5349         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
5350         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
5351         * support/regression/tests/bitfields.c: enabled signed bitfield for all
5352
5353 2006-02-13 Borut Razem <borut.razem AT siol.net>
5354
5355         * src/regression/ptrarg.c: added, fails due to bug #1430967
5356         * src/regression/Makefile: ptrarg.c added, ...
5357
5358 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
5359
5360         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
5361         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
5362
5363 2006-02-11 Borut Razem <borut.razem AT siol.net>
5364
5365         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
5366           print "Processor: xxx" message to stdout only if --verbose
5367
5368 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
5369
5370         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
5371         * support/regression/tests/bug1426356.c: added
5372         * support/regression/tests/bitfields.c: removed 2 tests
5373
5374 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
5375
5376         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
5377         * device/include/mcs51/c8051f330.h,
5378         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
5379           PCON_IDLE,PCON_STOP and added sfr16 definitions
5380         * device/lib/_divsint.c,
5381         * device/lib/_divuint.c,
5382         * device/lib/_divulong.c,
5383         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
5384           register bank bug for small stackauto
5385
5386 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
5387
5388         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
5389
5390 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
5391
5392         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
5393         * all.dsp: corrected several bin paths
5394         * device/include/mcs51/c8051f120.h,
5395         * device/include/mcs51/c8051f300.h,
5396         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
5397           to PCON_IDLE,PCON_STOP
5398         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
5399         * device/lib/printf_large.c (output_float): fixed bug 1388703
5400         * support/regression/tests/bug1057979.c: added test for bug 1388703
5401
5402 2006-02-08 Raphael Neider <rneider AT web.de>
5403
5404         * src/pic/pcode.c (pciTRIS): fixed typo,
5405           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
5406           (LinkFlow): fixed handling of flows that end in a call,
5407           (ReuseReg): perform safety check earlier
5408         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
5409             to work with flows at the beginning of a pBlock,
5410             fixes #1426557 (Symbol not previously defined),
5411           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
5412             usage information
5413           (RemoveUnusedRegisters): update register usage info
5414         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
5415             created, reuse existing ones instead
5416         * src/pic/gen.c (genPcall): fixed #1424719
5417
5418 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
5419
5420         * link/z80/lkmain.c,
5421         * link/z80/lklex.c,
5422         * link/z80/lkdata.c,
5423         * link/z80/aslink.h: fixed build on current cygwin:
5424         replaced getline() by lk_getline()
5425
5426 2006-02-01 Borut Razem <borut.razem AT siol.net>
5427
5428         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
5429           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
5430           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
5431           src/regression/bool1.c, src/regression/bool2.c,
5432           src/regression/bool3.c, src/regression/call1.c,
5433           src/regression/compare.c, src/regression/compare10.c,
5434           src/regression/compare2.c, src/regression/compare3.c,
5435           src/regression/compare4.c, src/regression/compare5.c,
5436           src/regression/compare6.c, src/regression/compare7.c,
5437           src/regression/compare8.c, src/regression/compare9.c,
5438           src/regression/configword.c, src/regression/for.c,
5439           src/regression/inline.c, src/regression/mult1.c,
5440           src/regression/nestfor.c, src/regression/or1.c,
5441           src/regression/pointer1.c, src/regression/ptrfunc.c,
5442           src/regression/rotate1.c, src/regression/rotate2.c,
5443           src/regression/rotate3.c, src/regression/rotate4.c,
5444           src/regression/rotate5.c, src/regression/rotate6.c,
5445           src/regression/rotate7.c, src/regression/string1.c,
5446           src/regression/struct1.c, src/regression/sub.c,
5447           src/regression/sub2.c, src/regression/switch1.c,
5448           src/regression/while.c, src/regression/xor.c,
5449           src/regression/create_stc, src/regression/simulate,
5450           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
5451           regression tests
5452         * src/regression/gpsim_assert.h: added
5453
5454 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
5455
5456         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
5457         ((void (code *) (void)) 0) ();
5458         * as/hc08/aslex.c,
5459         * as/hc08/aslink.h,
5460         * as/hc08/asm.h,
5461         * as/hc08/asmain.c,
5462         * as/hc08/lkdata.c,
5463         * as/hc08/lklex.c,
5464         * as/hc08/lkmain.c,
5465         * as/mcs51/aslex.c,
5466         * as/mcs51/aslink.h,
5467         * as/mcs51/asm.h,
5468         * as/mcs51/asmain.c,
5469         * as/mcs51/lkdata.c,
5470         * as/mcs51/lklex.c,
5471         * as/mcs51/lkmain.c,
5472         * as/z80/aslex.c,
5473         * as/z80/asm.h,
5474         * as/z80/asmain.c: fixed build on current cygwin:
5475         replaced getline() by as_getline()
5476
5477 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
5478
5479         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
5480         declarator in the symbol chain
5481         * src/SDCCsymt.h,
5482         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
5483         parameter list for function pointers
5484         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
5485         * support/regression/tests/bug-716242.c: added
5486
5487 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
5488
5489         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
5490         offset if possible
5491         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
5492
5493 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
5494
5495         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
5496         inifinitely recurseable, added static
5497         * support/regression/tests/bug-1408066.c: added
5498
5499 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
5500
5501         * src/SDCCicode.h,
5502         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
5503         renamed, added possibility to create "postLoopLbl"-labels
5504         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
5505         newiTempLoopHeaderLabel
5506         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
5507         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
5508         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
5509         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
5510         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
5511         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
5512         (basicInduction): fixed bug #136564, made static,
5513         (loopInduction): changed parameter of basicInduction, made static,
5514         (addPostLoopBlock): added
5515         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
5516         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
5517         findLoopEndSeq
5518         * support/regression/tests/bug-136564.c: added
5519         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
5520         --std-sdcc99 to LIBSDCCFLAGS
5521
5522 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
5523
5524         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
5525         while loop
5526         * support/regression/tests/bug-1406131.c: added
5527
5528 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
5529
5530         * src/SDCCast.c (decorateType): fix promotion of unary minus
5531         * src/SDCCsymt.c (computeType): beautified
5532         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
5533         (valUnaryPM, valComplement): fix sign and promotion,
5534         (valNot): ANSI: result type is int (SDCC: unsigned char)
5535         * support/regression/tests/uminus.c: speedup by removing superflous
5536         test case 'int'
5537         * support/regression/tests/onebyte.c: added promotion and signedness
5538         tests for unary minus
5539         * support/regressions/tests/bug-477927.c: disable warning about
5540         uninitialized variables
5541         * support/regression/tests/not.c: added
5542
5543 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
5544
5545         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
5546         * src/mcs51/gen.c (gen51Code): show final register usage after
5547         fillGaps in asm with --i-code-in-asm
5548         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
5549         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
5550         incUsed, rliveClear, adjustIChain): made static,
5551         (setFromRange): excluded because it's unused,
5552         (findPrevUseSym, markWholeLoop): added,
5553         (findPrevUse): rewritten; fixes bug 895992; now a complete search
5554         through all branches of predecessors enables sdcc to emit the warning
5555         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
5556         (rlivePoint): made static, added parameter emitWarnings which is only
5557         true during the first run out of two,
5558         (findRecursiveSucc, findRecursivePred): removed,
5559         (computeLiveRanges): made static, added parameter emitWarnings,
5560         (dumpIcRlive): added for debugging only
5561         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
5562         removed prototype of setFromRange()
5563         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
5564         in call of computeLiveRanges()
5565         * support/regression/tests/bug-895992.c: added
5566         * support/regression/tests/bug-971834.c: added
5567         * support/valdiag/tests/bug-895992.c: added
5568         * support/valdiag/tests/bug-971834.c: added
5569
5570 2005-12-18 Raphael Neider <rneider AT web.de>
5571
5572         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
5573           (genUnpackBits): improved code for direct operands,
5574           (genPackBits): improved code for literal assignment to bitfields
5575             and for direct destination operands (no FSR indirection),
5576             prevented redundant AND, fixes #1362800,
5577           (AccLsh): added parameter to disable masking of the result
5578         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
5579           skip instructions with side-effects (like incfsz),
5580           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
5581         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
5582         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
5583           fixes #1375263
5584
5585 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
5586
5587         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
5588         volatile variables as spill location
5589
5590 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
5591
5592         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
5593         replacing literals
5594         * support/regression/tests/bug-1376320.c: added
5595
5596 2005-12-08 Raphael Neider <rneider AT web.de>
5597
5598         * src/pic/device.c: renamed is_shared to pic14_is_shared
5599         * src/pic/gen.c (genIfx): re-enabled handling of sbits
5600         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
5601           (is_valid_identifier): added for above workaround
5602
5603 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
5604
5605         * device/lib/Makefile.in: fixed to enable port-specific-objects
5606         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
5607           char, thanks Hubert Sack
5608         * doc/sdccman.lyx: documented --xstack-loc,
5609           elaborated a bit more on interrupts and pitfalls,
5610           removed "setjmp/longjmp unsupported",
5611           documented some unsupported C99 features
5612         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
5613         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
5614           if, thanks Hubert Sack
5615         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
5616         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
5617           make make_library
5618         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
5619           regression tests can report resource usage (rfe 700441)
5620         * support/regression/collate-results.py: report resource usage
5621         * support/regression/ports/ds390/spec.mk,
5622         * support/regression/ports/hc08/spec.mk,
5623         * support/regression/ports/mcs51/spec.mk,
5624         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
5625         * support/regression/ports/ds390/uCsim.cmd,
5626         * support/regression/ports/hc08/uCsim.cmd,
5627         * support/regression/ports/mcs51/uCsim.cmd,
5628         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
5629         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
5630           library, use the default one
5631         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
5632           building the library
5633
5634 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
5635
5636         * config.dsp: added dependency on .version and configure_vc.awk
5637         * device/include/setjmp.h: updated for --stack-auto and --xstack
5638         * device/include/mcs51/at89c51snd1c.h: corrected line endings
5639         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
5640         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
5641         * device/lib/libsdcc.lib: added _setjmp
5642         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
5643           (decorateType): fixed bug 1372851,
5644           (optimizeGetHbit): fixed warning
5645         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
5646           array initialisation
5647         * support/regression/tests/bug1057979.c: added test for bug 1358192
5648         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
5649
5650 2005-12-03 Borut Razem <borut.razem AT siol.net>
5651
5652         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
5653           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
5654
5655 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
5656
5657         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
5658         createIval): implement symbol independant "flexible array member",
5659         (createIvalCharPtr): implemented flexible array initialisation with a
5660         string
5661         * src/SDCCsymt.c (copyStruct): removed,
5662         (getSize): fixed misleading comment,
5663         (getAllocSize): removed, the additional allocation size is now in
5664         sym->flexArrayLength,
5665         (checkStructFlexArray): new, syntax checks for flexible array members,
5666         (compStructSize): added syntax checks for "flexible array members"
5667         (copyStruct): removed,
5668         (copyLinkChain): removed inefficient fix for bug 770487
5669         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
5670         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
5671         symbol->flexArrayLength
5672         * src/SDCCerr.c,
5673         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
5674         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
5675         * support/regression/tests/structflexarray.c: added
5676         * support/valdiag/tests/structflexiblearray.c: added
5677
5678 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
5679
5680         * src/SDCCast.c (decorateType): fixed bug 1368489
5681         * support/Util/SDCCerr.c,
5682         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
5683
5684 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5685
5686         * device/include/mcs51/at89c51snd1c.h: added file submitted by
5687           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
5688
5689 2005-11-27 Borut Razem <borut.razem AT siol.net>
5690
5691         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
5692           support/cpp2/mkdeps.h: added command line option
5693           -obj-ext=<extension> to SDCPP to define object file externion, used
5694           for generation of make dependencies (-M)
5695         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
5696
5697 2005-11-26 Borut Razem <borut.razem AT siol.net>
5698
5699         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
5700           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
5701           added pic and pic16 libraries
5702
5703 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5704
5705         * device/include/float.h: Corrected typo in prototype of __fsgt
5706
5707 2005-11-25 Borut Razem <borut.razem AT siol.net>
5708
5709         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
5710           added creation of model-mcs51-stack-auto libraries
5711
5712 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
5713
5714         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
5715         and fields-list too
5716         * src/SDCCast.c (createIvalArray): removed obsolete comment
5717
5718 2005-11-24 Borut Razem <borut.razem AT siol.net>
5719
5720         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
5721           added missing device/lib/mcs51/crt*.asm sources
5722
5723 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
5724
5725         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
5726
5727 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
5728
5729         * device/lib/_fs2schar.c,
5730         * device/lib/_fs2sint.c,
5731         * device/lib/_fs2slong.c: optimized inline asm
5732
5733 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5734
5735         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
5736           Better handling of floats between -1.0 and 0.0.
5737
5738 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5739
5740         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
5741           (the missing "if"s prohibited removal of redundant labels)
5742
5743 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5744
5745         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
5746           Properly convert floats between -1.0 and 0.0 to long, int, and char
5747           types (max integer value of negative floats tends to zero).
5748         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
5749           Removed changes made so to work properly with floats between
5750           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
5751           and _fs2char.c
5752
5753 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
5754
5755         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
5756         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
5757         (genCast) cosmetic change
5758         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
5759         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
5760         from mcs51
5761         * support/regression/tests/bitfields (testSignedBitfields): added
5762
5763 2005-11-18 Borut Razem <borut.razem AT siol.net>
5764
5765         * sdcc/device/lib/Makefile.in: remove all unnecessary files
5766         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
5767           introduced SILENT option to make building of pic16 libraries less
5768
5769 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5770
5771         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
5772           Now they work properly with floats between -1.0 and 0.0
5773         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
5774
5775 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
5776
5777         * src/SDCCicode.c (printOperand): added missing else
5778
5779 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
5780
5781         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
5782         reformatted for better readability
5783         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
5784         signed bitfields
5785
5786 2005-11-17 Borut Razem <borut.razem AT siol.net>
5787
5788         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
5789           introduced SILENT option to make building of pic16 libraries less
5790           verbose - used for nightly snapshot build
5791         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
5792           available on Win32 platforms.
5793         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
5794           medium, large, pic and pic16
5795
5796 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5797
5798         * device/lib/printf_large.c: Temporary patch for bug 1358192:
5799           printf("%f"...) sets fraction to zero.
5800
5801 2005-11-16 Raphael Neider <rneider AT web.de>
5802
5803         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
5804           fixes #1357221
5805         * src/pic/gen.c (genIfx): implemented for CARRY bit
5806         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
5807           to generic pointers, fixes #1357332,
5808           (pic16_movLit2f): NEW,
5809           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
5810
5811 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
5812
5813         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
5814
5815 2005-11-11 Raphael Neider <rneider AT web.de>
5816
5817         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
5818         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
5819           compute pointer's type from operand,
5820           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
5821           improved single bit reads, fixes bug #1353379
5822
5823 2005-11-09 Borut Razem <borut.razem AT siol.net>
5824
5825         * support/scripts/sdcc.nsi: added lib/pic to the package
5826
5827 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
5828
5829         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
5830
5831 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
5832
5833         * support/regression/tests/bug1348008.c: added
5834         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
5835         * support/regression/tests/bug1337835.c: updated comment
5836
5837 2005-11-06 Borut Razem <borut.razem AT siol.net>
5838
5839         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
5840           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
5841           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
5842           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
5843           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
5844           dynamic construction of cl_error_class and derivates - 2.nd try
5845
5846 2005-11-05 Borut Razem <borut.razem AT siol.net>
5847
5848         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
5849           bug, which caused Bus Errors on sparc solaris
5850
5851 2005-11-04 Borut Razem <borut.razem AT siol.net>
5852
5853         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
5854           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
5855           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
5856           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
5857           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
5858           and derivates to resolve the initialization problem on OSX
5859
5860 2005-11-02 Borut Razem <borut.razem AT siol.net>
5861
5862         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
5863           corrected typo - #include <winsock2.h>
5864
5865 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
5866
5867         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
5868           (_asxxxx_mapping): added org directive for future enhancements
5869
5870 2005-11-01 Borut Razem <borut.razem AT siol.net>
5871
5872         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
5873           enabled sockets on WIN32
5874         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
5875
5876 2005-10-31 Borut Razem <borut.razem AT siol.net>
5877
5878         * support/regression/generate-cases.py: escape backslashes in {testcase}:
5879           WIN32 backslash path delimiters should be escaped when used in C strings
5880         * support/regression/tests/bitfields.c: exclude failing assertions for
5881           __CYGWIN32__ and __MINGW32__ hosts
5882
5883 2005-10-30 Borut Razem <borut.razem AT siol.net>
5884
5885         * src/SDCCutil.c: corrected double comparison typo
5886
5887 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
5888
5889         * device/lib/medium/Makefile: added for new memory model medium
5890         * device/include/asm/mcs51/features.h: updated for medium/pdata
5891         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
5892           added Multiply & Accumulate sbit's and MAC0_PAGE define
5893         * device/include/mcs51/c8051f300.h: added sfr16 definitions
5894         * device/include/mcs51/c8051f310.h: added sfr16 definitions
5895         * device/lib/_mullong.c: update for medium model
5896         * device/lib/incl.mk: added medium model
5897         * doc/sdccman.lyx: documented medium model
5898         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
5899         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
5900         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
5901         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
5902           (allocParms): set SCLS and OCLS to pdata for medium model
5903         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
5904           for pdata,
5905           (powof2): return <0 if not power of 2
5906         * src/avr/gen.c (genBitWise): use updated powof2
5907         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
5908           (shiftR2Left2Result): small optimization in setup, save acc when storing,
5909           (shiftLLeftOrResult): use B if necessary
5910         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
5911         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
5912         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
5913         * support/regression/Makefile.in: added test-mcs51-medium
5914         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
5915
5916 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
5917
5918         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
5919         specifier unsigned
5920         * device/lib/time.c (mktime): fixed bug 1334315
5921
5922 2005-10-28 Raphael Neider <rneider AT web.de>
5923
5924         * device/include/pic/p16f_common.inc: added common declarations
5925         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
5926
5927 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
5928
5929         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
5930           (aopPutUsesAcc): added to predict accumulator use,
5931           (assignResultValue): save acc if necessary,
5932           (genMinusDec): store result if indirectly addressed,
5933           (genDivOneByte):  save acc if necessary,
5934           (movLeft2Result): bugfix if left already in acc,
5935           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
5936             attention to accumulator use (esp. pdata),
5937           (genReceive): receive pdata correctly
5938         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
5939         * src/SDCCicode.h: added isOperandInPagedSpace prototype
5940
5941 2005-10-27 Raphael Neider <rneider AT web.de>
5942
5943         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
5944
5945 2005-10-27 Raphael Neider <rneider AT web.de>
5946
5947         * .version: changed version to 2.5.4
5948         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
5949         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
5950           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
5951             arithmetics support routines
5952         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
5953         * device/lib/Makefile.in: also create installdir for pic
5954
5955         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
5956           pic14 port as well
5957         * src/pic/device.c (dump_sfr): rewritten to delegate register
5958           placement to the linker (use `extern sym' rather than sym EQU addr),
5959           (validAddress): fixed to check last specified address
5960         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
5961           (popGetLit): truncate literal value to 8 bit,
5962           (popGet): moved assert to more appropriate place
5963           (popGetExternal): create pCode operand from and mark the according
5964             symbol as being `extern'
5965           (popGetAddr): added sanity check on immediate's offset, provide
5966             GPOINTER tag on demand
5967           (aopPut): fixed for immediates,
5968           (mov2w_op): move operand's address or contents to WREG (depending on
5969             operand type), safer variant of mov2w,
5970           (movwf,call_libraryfunc): NEW, handy abbreviations,
5971           (get_argument_pcop,get_return_val_pcop,pass_argument,
5972           get_returnvalue): interface for accessing function parameters and
5973             return values,
5974           (assignResultValuei,genRet): use new parameter/return value interface
5975           (pic14_getDataSize): back to old version handling generic pointers,
5976           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
5977             provided implementation and/or fixed old one,
5978           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
5979             calls, removed legacy 8051 reference code
5980           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
5981           (loadSignToC): NEW, move the operands sign bit to CARRY,
5982           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
5983             genRightShiftSigned, accepts negative shift counts,
5984           (setup_fsr): load FSR and adjust IRP (indirect memory access),
5985           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
5986             generic pointers, __data pointers and __code pointers,
5987           (genUnpackBits,genPackBits): rewritten to work with generic pointers
5988             and signed bitfields, limit bitfields to 8 bit,
5989           (genDataPointerGet): fixed number of bytes read,
5990           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
5991           (genPointerGet,genPointerSet): fixed handling of __code pointers,
5992             pointers to constant data are no longer assumed to point to __code
5993             space, removed invalid pointer types,
5994           (bitpatternFromVal): retrieve the PICs representation of an integer
5995             or float literal,
5996           (genDataPointerSet): fixed assigning to po_immediate operands,
5997           (genGenPointerSet): implemented as library call,
5998           (genIfx): fixed incorrect condition,
5999           (genAddrOf): limit generic pointers' addresses to 2 bytes,
6000             provide GPOINTER tag according to destination's storage class,
6001           (genCast): added code to handle casting to generic pointers, added
6002             sign-/zero extension of the result
6003           (aop_isLitLike,op_isLitLike): fixed handling of immediates
6004         * src/pic/gen.h: added macros to access IRP bit in STATUS register
6005         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
6006           extend the result
6007         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
6008           address/register resides in the shared banks
6009           (emitSymbolToFile): improved to handle global and `pinned' symbols,
6010             put all variables into separate sections (have the linker arrange
6011             them)
6012           (picglue): put init code and interrupt handlers in separate sections
6013         * src/pic/main.c: added port specific options table, modified to PORT
6014           structure to make GPOINTERs 3 byte, added pic14_options
6015           (_pic14_do_link): private linking routine (update paths to libraries,
6016             add libsdcc.lib by default)
6017         * src/pic/main.h: declare pic14_options
6018         * src/pic/pcode.c: fixed instructions i/o relations,
6019           (RegCond): reverted to correct version,
6020           (newpCodeOpLit): truncate literals to 8 bit,
6021           (genericPrint): added debug output,
6022           (getRegFromInstruction): fixed for various operand types, simplified
6023           (BuildFlow): fixed broken handling of isntructions with labels
6024           (LinkFlow): start at last instruction in flow (skip trailing comments),
6025             pass the flow on to the next instruction after CALL
6026           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
6027           (insertPCodeInstruction): fixed inserting after a skip instruction,
6028           (DoBankSelect): fixed for labeled instructions
6029           (OptimizepBlock): honor --nopeep switch
6030           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
6031         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
6032         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
6033           (pCodeOptime2pCodes): allow disabling this optimization via
6034             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
6035             but is still buggy), started implementation of a dataflow based
6036             pCode optimization (CSE + dead code elimination)
6037           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
6038         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
6039           names are independant of the stack location and therefore portable across
6040           devices
6041
6042 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
6043
6044         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
6045           (selectSpil): fixed bug 1337835 by not spilling bit variables
6046         * support/regression/tests/bug1337835.c: added test for this bug
6047         * src/mcs51/peeph.def: restart after rule 3.c,
6048           addded rules 263.x to optimize loading constants
6049
6050 2005-10-26 Raphael Neider <rneider AT web.de>
6051
6052         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
6053         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
6054           (genAssign): emit warning when casting literals to generic pointer
6055             type, also applies when taking the address of a fixed variable,
6056           (genCast): improved casting to generic pointers
6057         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
6058           extern variables, added verbose error message
6059         * device/include/pic16/{string.h,errno.h}: added #pragma library c
6060
6061 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
6062
6063         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
6064         carry must be complemented too
6065         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
6066         could be emitted by genMinus
6067         * src/SDCCval.c (constVal): fixed bug 1305065
6068
6069 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
6070
6071         * src/SDCCast.c (addCast): added promotion for bit variables
6072         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
6073         promotion casts + optimisation
6074         (optimizeGetWord): fix warning 'i' might be used uninitialized
6075         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
6076         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
6077
6078 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
6079
6080         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
6081         all chars are promoted to int; promotion should be handled in SDCCast.c
6082
6083 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6084
6085         * device/lib/_strcmp.c: Fixed bug 1326457
6086
6087 2005-10-11 Raphael Neider <rneider AT web.de>
6088
6089         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
6090         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
6091
6092 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
6093
6094         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
6095         * support/regression/tests/sfr16.c: added test for the sfr32 bug
6096
6097 2005-10-04 Raphael Neider <rneider AT web.de>
6098
6099         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
6100           device/lib/pic16/pics.all: added pic18f1320
6101         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
6102
6103 2005-09-30 Raphael Neider <rneider AT web.de>
6104
6105         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
6106         * src/pic16/devices.inc: NEW, provides device descriptions
6107         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
6108
6109 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
6110
6111         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
6112           GETHBIT
6113
6114 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
6115
6116         * doc/sdccman.lyx: updated Highest Order Bit documentation,
6117           documented Any Order Bit, Higher Order Byte and Higher Order Word
6118         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
6119         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
6120           (optimizeGetAbit): new, to get any bit, not only the high bit,
6121           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
6122           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
6123           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
6124           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
6125             RIGHT_OP: also try GETBYTE, GETWORD optimization,
6126             GETABIT, GETBYTE, GETWORD: decorate them,
6127           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
6128           (ast_print): added GETABIT, GETBYTE, GETWORD
6129         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
6130         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
6131           (geniCodeBinary): new generic binary icode,
6132           (ast2iCode): added GETABIT, GETBYTE, GETWORD
6133         * src/port.h: updated comment for PORT.hasExtBitOp
6134         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
6135           (genGetByte): new, to get a single byte,
6136           (genGetWord): new, to get a word from a long,
6137           (gen51Code): added GETABIT, GETBYTE, GETWORD
6138         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
6139
6140 2005-09-23 Raphael Neider <rneider AT web.de>
6141
6142         * configure.in, configure: have device/lib/pic configured
6143         * device/lib/Makefile.in: added model-pic14
6144         * device/lib/clean.mk: added pic/ to clean rule
6145         * device/lib/pic: added rudimentary pic14 library providing support
6146           functions for multiplication/division/generic pointer access
6147         * src/SDCCopt.c (convilong): mark support functions as extern
6148           for pic14 port as well
6149         * src/pic/gen.c (genMult): added assertions,
6150           (genpic14Code): emit warning on unhandled iCodes
6151         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
6152         * src/pic/pcode.c (pCodeOpCopy),
6153         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
6154           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
6155           SFR_REGISTER}), made safe for future extensions
6156         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
6157           instructions even if preceeded by SKIP instructions (also remove
6158           them); removed unused code
6159         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
6160           prevents leaving parts of the structure uninitialized after copying
6161
6162 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
6163
6164         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
6165           ago by me
6166         * support/regression/tests/addsub.c: added test for the bug
6167
6168 2005-09-21 Raphael Neider <rneider AT web.de>
6169
6170         * device/include/pic16/pic18f1220.h,
6171           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
6172         * device/lib/pic16/Makefile.rules: added missing opening paren
6173         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
6174           are provided in genutils.c,
6175           (genUminusFloat,genUminus,genCmpEq): added asserts on different
6176           operand/result sizes,
6177           (genCmp): assert on NULL pointers first, then check deref'ed values
6178         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
6179           result size
6180
6181 2005-09-18 Raphael Neider <rneider AT web.de>
6182
6183         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
6184           as these are now unused,
6185           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
6186         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
6187           local, avoids uninitialized pointer dereference on r->name
6188         * src/pic16/ralloc.c (newReg): fixed indentation
6189
6190 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
6191
6192         * src/SDCCval.c (constVal): fixed bug 730366
6193         * support/Util/SDCCerr.c,
6194         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
6195
6196 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
6197
6198         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
6199
6200 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
6201
6202         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
6203
6204 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
6205
6206         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
6207           (hex2dec): made hex_digit unsigned char, removed ascii dependance
6208         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
6209           (hex2dec): made hex_digit unsigned char, removed ascii dependance
6210         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
6211         * packihx/packihx.c (hexDigit): made c unsigned char
6212         * as/mcs51/lklibr.c (fndsym),
6213         * link/z80/lkgb.c (gb),
6214         * link/z80/lklibr.c (fndsym),
6215         * link/z80/lkrloc.c (relr),
6216         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
6217         * src/SDCC.lex (checkCurrFile, process_pragma),
6218         * src/SDCCglue.c (spacesToUnderscores),
6219         * src/SDCCmain.c (setParseWithComma, processFile),
6220         * src/asm.c (tvsprintf, printCLine),
6221         * src/avr/gen.c (emitcode, aopPut),
6222         * src/ds390/gen.c (emitcode),
6223         * src/hc08/gen.c (emitcode, emitinline),
6224         * src/mcs51/gen.c (emitcode, genInline),
6225         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
6226           tokenizeLineNode),
6227         * src/pic/ralloc.c (debugLog),
6228         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
6229           tokenizeLineNode),
6230         * src/pic16/ralloc.c (debugLog),
6231         * src/z80/main.c (_process_pragma):
6232            made all ctype.h function calls safe
6233         * src/SDCCopt.c: include math.h for fabs
6234         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
6235           and used them throughout the code to make ctype.h function calls safe
6236         * src/ds390/main.c (asmLineNodeFromLineNode),
6237         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
6238         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
6239            unsigned char*
6240         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
6241           (newpCodeAsmDir): made ctype.h function calls safe
6242         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
6243           pic16_emitcode):  made lbp unsigned char*
6244         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
6245           (pic16_newpCodeAsmDir): made ctype.h function calls safe
6246         * src/xa51/gen.c (emitcode),
6247         * src/z80/gen.c (_emit2): made lbp unsigned char*
6248         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
6249            char*
6250
6251 2005-09-05 Raphael Neider <rneider AT web.de>
6252
6253         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
6254           access bank splitpoint
6255
6256 2005-09-05 Raphael Neider <rneider AT web.de>
6257
6258         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
6259
6260 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
6261
6262         * .version: changed to version 2.5.3
6263         * doc/sdccman.lyx: changed version to 2.5.3,
6264           documented --codeseg and --constseg and pragma codeseg and constseg,
6265           documented bit parameters (reentrant) and bit returning
6266         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
6267            currFunc->recvSize, but is this ok for all ports?
6268           (ast2iCode): result of ~ on unsigned char must be cast to int for
6269            bool to work
6270         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
6271           function pointers in bit space
6272         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
6273           (processFuncArgs): call port.reg_parm() with reentrancy info
6274         * src/port.h,
6275         * src/avr/main.c,
6276         * src/ds390/main.c,
6277         * src/hc08/main.c,
6278         * src/pic/main.c,
6279         * src/pic16/main.c,
6280         * src/xa51/main.c,
6281         * src/z80/main.c: port.reg_parm prototype extended with
6282           "bool reentrant" parameter
6283         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
6284           options.stackAuto for allocating bit register parameters
6285         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
6286           (genSend): set BitBankUsed if it is,
6287           (selectRegBank): factored out of genCall for use in genPcall,
6288           (genCall): removed redundant dtype assignmen, use selectRegBank,
6289           (genPcall): handle returning in Carry properly, save in F0 if needed,
6290           (genReceive): handle bit register parameters
6291         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
6292           (mcs51_assignRegisters): enable bit registers for all reentrant
6293            functions and don't set BitBankUsed unconditionally
6294         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
6295         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
6296         * support/regression/tests/funptrs.c: added tests for BOOL and for return
6297
6298 2005-08-27 Borut Razem <borut.razem AT siol.net>
6299
6300         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
6301         ppc-osx (Darwin) does not support -u option. It seems that it is
6302         supported only on Linux - GNU cp
6303
6304 2005-08-25 Borut Razem <borut.razem AT siol.net>
6305
6306         * sim/ucsim/gui.src/serio.src/Makefile.in,
6307           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
6308           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
6309           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
6310           install and strip, since the strip at /usr/ccs/bin should be used
6311           on solaris
6312
6313 2005-08-24 Borut Razem <borut.razem AT siol.net>
6314
6315         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
6316
6317 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
6318
6319         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
6320         ffffffffu
6321
6322 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
6323
6324         * as/mcs51/aslink.h: completed lkrloc.c prototypes
6325         * as/mcs51/lkmain.c (link_main): fixed warning
6326         * device/include/stdbool.h: ds390 has no advanced bit support yet
6327         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
6328         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
6329         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
6330           and updated their macros
6331         * src/SDCCval.c (constVal): updated comment for renamed b_long
6332
6333 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
6334
6335         * as/mcs51/asdata.c: changed ctype['['] to BINOP
6336         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
6337           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
6338           (oprio): set priority for '['
6339         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
6340            and adb_24_bit
6341         * as/mcs51/asm.h: added defines R_BIT and S_BIT
6342         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
6343         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
6344         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
6345           added overlayable BIT_BANK area
6346         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
6347           (summary2): explain 'T' in legenda
6348         * as/mcs51/lkrloc.c: replaced old K&R style,
6349           (relr): added R_BIT processing,
6350           (errmsg): added "Bit-addressable relocation error",
6351           (adb_bit): added for converting from byte- to bit-addressable space,
6352           (adb_24_bit): added for converting from byte- to bit-addressable space
6353         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
6354            used in reentrant functions now even as return value
6355         * device/lib/_gptrput.c (_gptrput): removed obsolete code
6356         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
6357           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
6358         * src/SDCCglobl.h: added indicator BitBankUsed
6359         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
6360            the bit registers b0-b7
6361         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
6362           (geniCodeCast): fixed bug 1263853,
6363           (geniCodeLogicAndOr): put result in bool or char,
6364           (geniCodeReceive): added parameter func for accessing the return type,
6365           (geniCodeFunctionBody): pass func to geniCodeReceive
6366         * src/SDCCmain.c: added indicator BitBankUsed
6367         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
6368         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
6369           (checkSClass): don't put automatic bool/bit on stack,
6370           (checkFunction): removed check on function cannot return bit
6371         * src/SDCCsymt.h: added newBoolLink prototype
6372         * src/mcs51/gen.c (rb1regs): added bit registers,
6373           (movc): created for assigning to carry,
6374           (pushReg, popReg): created for pushing registers,
6375           (sameRegs): check both AOP_REG and AOP_CRY types,
6376           (aopOp): handle bit registers,
6377           (aopPut): optimization no self-assign,
6378           (saveRegisters): push reg->base (bits) only once for bit registers,
6379            and use pushReg,
6380           (unsaveRegisters): pop reg->base only once and use popReg,
6381           (assignResultValue): added parameter func and return in carry for bits,
6382           (genIpush): optimization no reload in A if not changed,
6383           (genSend): bit parameters in reentrant functions are passed in bit
6384            registers by first assigning to bits in B, then save registers and
6385            copy B to bits,
6386           (genCall): handle returning in Carry properly, save it in F0 if needed,
6387           (genPcall): updated assignResultValue call, this is not safe yet for bit
6388            returning function !!!
6389           (genFunction): don't generate equ's for bit registers and use pushReg,
6390           (genEndFunction): take care of bit returning functions and use popReg,
6391           (genRet): return bit in Carry,
6392           (genIfx): optimize bit registers and other directly addressable bits,
6393           (genReceive): updated assignResultValue call
6394         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
6395           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
6396            registers when using stack-auto
6397         * src/mcs51/ralloc.c (_G): added allBitregs,
6398           (regs8051): added the bit registers,
6399           (createStackSpil): use macro IS_BIT,
6400           (getRegBit): added to allocate a bit register, else spill,
6401           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
6402           (updateRegUsage): factored out to ease stepping while debugging,
6403           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
6404            also allocate bit registers,
6405           (fillGaps): handle bit registers,
6406           (findAllBitregs): added to create bit vector with all bit registers,
6407           (mcs51_allBitregs): returns this bit vector,
6408           (mcs51_assignRegisters): when using stack-auto use bit registers for
6409            passing parameters and creating local variables
6410         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
6411
6412 2005-08-22 Borut Razem <borut.razem AT siol.net>
6413
6414         * device/lib/Makefile.in: replaced find option -or with -o
6415           to make it run on solaris
6416
6417 2005-08-22 Raphael Neider <rneider AT web.de>
6418
6419         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
6420           fixes #1265442 (crash on Solaris)
6421
6422 2005-08-20 Borut Razem <borut.razem AT siol.net>
6423
6424         * configure, configure.in: added tests for libsocket and libnsl libraries,
6425           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
6426           from support/regression/Makefile.in
6427         * support/regression/Makefile.in: added
6428         * device/lib/pic16/Makefile.common.in: force make to use bash shell
6429         * sim/ucsim/libtool: regenerated on sparc-solaris
6430         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
6431           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
6432           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
6433           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
6434           sparc-solaris, which doesn't use GNU ld linker
6435         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
6436         * as/Makefile: find on sparc-solaris does not support -maxdepth option
6437
6438 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
6439
6440         * src/mcs51/peeph.def: updated comments
6441
6442 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6443
6444         * device/lib/_gptrget.c,
6445         * device/lib/_gptrput.c: slightly shorter
6446         * doc/sdccman.lyx: incremented version
6447         * src/mcs51/peeph.def: moved peephole comments to the line of first
6448           change to better keep line correlation, reanimated 186.e
6449         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
6450
6451 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
6452
6453         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
6454           David Saxton with quotes around file name.
6455
6456 2005-08-15 Borut Razem <borut.razem AT siol.net>
6457
6458         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
6459           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
6460           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
6461           make tests run on x86_64 platform
6462
6463 2005-08-13 Raphael Neider <rneider AT web.de>
6464
6465         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
6466           as it might be executed DURING a build (parallel make is wonderful)
6467
6468 2005-08-13 Raphael Neider <rneider AT web.de>
6469
6470         * device/lib/Makefile.in (port-specific-objects-pic16):
6471           revert to cp $(PORT)/bin/*.* $(PORTDIR)
6472         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
6473           dependency
6474         * device/lib/pic16/Makefile.rules: build subdirs before creating
6475           the library, removed builddir rule, create $(builddir) early in
6476           recurse rule, use empty recurse rule for leaf directories
6477         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
6478           mkdir errors (race condition), removed duplicate suffix "hex"
6479           from clean rules
6480         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
6481         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
6482           prevents mkdir -p from aborting on Alpha
6483
6484 2005-08-12 Raphael Neider <rneider AT web.de>
6485
6486         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
6487           db-statements in order to allow for arrays of pointers in code
6488           sections to be placed without interspersed 0-padding, fixes
6489           bug #1256215
6490         * (emitStatistics): fixed division by zero for pic18f1220
6491         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
6492           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
6493         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
6494         * (pic16_pCodeConstString): keep track of already emitted string
6495           literals to prevent "duplicate definitions of symbol _str_NR"
6496         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
6497           debug message
6498         * device/lib/Makefile.in: ignore failing PIC16 library builds
6499         * device/lib/pic16/Makefile: do not build if gputils are missing
6500         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
6501
6502 2005-08-10 Raphael Neider <rneider AT web.de>
6503
6504         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
6505           my last commit)
6506
6507 2005-08-10 Raphael Neider <rneider AT web.de>
6508
6509         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
6510           Rokas' patch to add the new fixed point type "__fixed16x16"
6511         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
6512           functions for __fixed16x16 arithmetics
6513         * device/lib/pic16: reimplemented the build system to support
6514           a separate build directory, better handling of libio (create
6515           the library in a separate subdir for each architecture) and
6516           easier configuration (centralized in Makefile.common)
6517
6518 2005-08-07 Raphael Neider <rneider AT web.de>
6519
6520         * src/pic16/gen.c (genrshTwo): fixed sign extension
6521         * src/pic16/device.c: added pic18f2320, 4220 and 4320
6522         * device/include/pic16/pic18f2220.h: changed some bit definitions,
6523           added T0CONbits
6524         * device/include/pic16/pic18f4220.h: NEW, header for
6525           pic18f4220 and pic18f4320
6526         * device/include/pic16/pic18fregs.h: added new devices,
6527           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
6528         * device/include/pic16/signal.h: resolved name clashes
6529           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
6530           to also allow testing for interrupt enable bits, added
6531           comments on how to use the macros
6532         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
6533         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
6534           register definitions for the devices
6535         * device/lib/pic16/pics.all: added new devices
6536         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
6537           allocated memory
6538         * device/lib/pic16/libc/stdlib/memfree: do not count
6539           the block header as free memory
6540         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
6541           simplified and added missing end-of-blocklist-marker
6542           (reported by Peter Onion, fixes #1252814)
6543         * (_mergeHeapBlock): fixed loop condition
6544         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
6545           len==0, restructured code
6546         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
6547           up a bit, reduced bitfield accesses, prevent endless loops
6548           in case of heap corruption
6549         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
6550           "unreferenced arguments/must return a value" warnings
6551         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
6552           replaced BAUDREG with SPBRG
6553         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
6554           device/lib/pic16/debug/gstack/gstack.c: replaced
6555           _naked, _asm, _endasm with __naked, __asm, __endasm
6556
6557 2005-08-05 Raphael Neider <rneider AT web.de>
6558
6559         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
6560           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
6561
6562 2005-08-05 Borut Razem <borut.razem AT siol.net>
6563
6564         * device/lib/Makefile.in: added missing ';'
6565         * configure: removed ^M characters
6566
6567 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6568
6569         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
6570           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
6571           License
6572
6573 2005-08-04 Borut Razem <borut.razem AT siol.net>
6574
6575         * configure.in: pic16 libraries build 2nd try - enable running
6576           configure in device/lib/pic16
6577         * configure: regenerated from configure.in
6578         * device/lib/Makefile.in: create $(PORT)/bin directory
6579
6580 2005-08-03 Raphael Neider <rneider AT web.de>
6581
6582         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
6583           to get/set values via pointers
6584         * (genUnpackBits,genPackBits): changed detection of
6585           ptr->bitfield vs. sym.bitfield, fixed access via generic
6586           pointers, removed dead (wrong) code for multibyte bitfields
6587         * (genNearPointerGet, genGenPointerGet): removed useless code,
6588           fixed bitfield detection, fixes #1250594
6589         * (genNearPointerSet): removed useless code
6590         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
6591           and introduced macro pic16_emitpcode that conditionally emits
6592           the origin of the following pCode (useful for debugging SDCC)
6593         * src/pic16/pcode.c: changed (and disabled) some debug outputs
6594         * (createDefmap): fixed handling of LFSR for --optimize-df
6595
6596 2005-08-02 Borut Razem <borut.razem AT siol.net>
6597
6598         * device/lib/Makefile.in: pic16 libraries build enabled since
6599           gputils-0.13.2 are now localy installed at sourceforge's compile farm
6600
6601 2005-08-02 Raphael Neider <rneider AT web.de>
6602
6603         * src/pic16/gen.c (genPackBits): removed deprecated warning
6604         * (genGenPointerSet): fixed bitfield detection
6605
6606 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6607
6608         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
6609
6610 2005-07-31 Raphael Neider <rneider AT web.de>
6611
6612         * device/lib/pic16/libdev/pic18f458.c,
6613           device/include/pic16/pic18f458.h: added missing T0CONbits
6614
6615 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
6616
6617         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
6618
6619 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
6620
6621         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
6622
6623 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6624
6625         * device/include/mcs51/at89c51ed2.h: added.
6626
6627 2005-07-23 Raphael Neider <rneider AT web.de>
6628
6629         * src/pic/gen.h: added emitpcode macro for debugging
6630         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
6631           and replace by macro adding debug information on demand
6632         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
6633         * (gencjne): tried to fix; replaced with correct (slower) code
6634         * (gen{Unp,P}ackBits): fixed single bit access
6635         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
6636         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
6637           previous instruction
6638         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
6639           register has to be handled with care (forbidding movement
6640           of assignments/uses, removing assignments completely, ...)
6641         * (pCodeOptime2pCodes): make use of regIsSpecial
6642         * added lots of debugging output (commented out)
6643         * src/pic/rallloc.c (deassignLRs): prevent operand registers
6644           from being reused as result UNLESS it is known to work
6645
6646 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
6647
6648         * support/Util/dbuf.h: include <stddef.h> for size_t
6649         * .version: changed to version 2.5.2
6650
6651 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6652
6653         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
6654
6655 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6656
6657         * src/hc08/gen.c (genMinus): fixed bug #1241835,
6658           (genModOneByte): removed needless psha/pula
6659
6660 2005-07-22 Raphael Neider <rneider AT web.de>
6661
6662         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
6663           have PIC14 handled like PIC16, fixes broken pic14 linker calls
6664         * src/pic/gen.c (resolveIfx): do not "invent" labels
6665         * (genSkipc): changed to positive logic
6666         * (genSkipCond): removed as no longer needed
6667         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
6668           backport from PIC16
6669         * (genLeftShift): check operands are in different registers
6670         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
6671           INCF does not update CARRY...
6672         * src/pic/main.c: fixed _linkCmd
6673         * src/pic/pcode.c (unlinkpCode): added inactive code
6674         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
6675           alive (do not assign result and operand overlapping registers)
6676
6677 2005-07-22 Raphael Neider <rneider AT web.de>
6678
6679         * src/pic/device.c (dump_sfr): replaced register declaration with
6680           call to emitSymbolToFile() to avoid duplicate symbols
6681         * (assignRelocatableRegisters): do not declare external symbols
6682         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
6683           right (take size of type, not etype)
6684         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
6685         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
6686         * (packRegsForAccUse): disabled assignment of WREG as
6687           the result reg to prevent occurence of just fixed #1235003,
6688           fixes #1242954
6689         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
6690           symbols (avoids duplicate symbols in .asm file)
6691         * (pic14emitRegularMap): use emitSymbolToFile()
6692         * src/pic/gen.c (aopOp): fixed spillLocation handling
6693         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
6694         * (genDataPointerSet): removed unneccessary variables/output
6695
6696 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
6697
6698         * as/mcs51/lkarea.c: enlarged codemap for banked memory
6699         * device/lib/mcs51/crtbank.asm: added # to 0x0F
6700
6701 2005-07-21 Raphael Neider <rneider AT web.de>
6702
6703         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
6704           architecture cannot handle them efficiently, fixes bug #1235003
6705         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
6706           check for empty sets before using them (fixes bug #1232190)
6707
6708 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
6709
6710         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
6711           (lnksect2): generate warnings for memory overlap
6712         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
6713           constseg to set the name of these segments so you can instruct the linker
6714           to place them in banks
6715         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
6716         * src/SDCCglobl.h: added MODEL_HUGE to enum,
6717           added code_seg and const_seg to options
6718         * src/SDCCglue.c (emitMaps): use options.const_seg,
6719           (createInterruptVect): put interrupt vectors in segment HOME,
6720           (glue): put HOME before static segment and put the main glue in HOME,
6721           (glue): use options.code_seg
6722         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
6723         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
6724           these segments so you can instruct the linker to place them in banks
6725           (linkEdit): use code_loc for HOME segment which should be the first
6726           segment in code memory now
6727         * src/SDCCmem.c: fixed more stuff like bug 1238386
6728         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
6729           (changePointer): don't change function pointers to code pointers for
6730           banked functions,
6731           (compareType): added exceptional check for banked function pointers
6732         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
6733         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
6734           after static in code memory
6735         * src/mcs51/gen.c: added aopLiteralLong prototype,
6736           (aopForSym): use getSize for functions,
6737           (genCall): generate banked calls over one trampoline __sdcc_banked_call
6738           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
6739           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
6740           the segment,
6741           (genPcall): use call for literal function pointers and generate banked
6742           calls over the one trampoline so there's only one place for the user to
6743           modify according to his/hers hardware,
6744           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
6745           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
6746         * src/mcs51/main.c: added keyword banked,
6747           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
6748         * support/Util/SDCCerr.c,
6749         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
6750           needed for passing the bank and address to the trampoline
6751         * device/lib/mcs51/crtbank.asm: added for bankswitching
6752         * device/lib/mcs51/Makefile: added crtbank
6753
6754 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6755
6756         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
6757           for fields at offset 0 of a struct or union as reported
6758           on 2005-07-07 in the developer mailing list.
6759
6760 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
6761
6762         * src/SDCCmem.c: fixed bug 1238386
6763
6764 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6765
6766         * src/mcs51/peeph.def: added labelrefcounting for peepholes
6767           (patch #1144962), added peephole 300, enabled 259.x
6768         * doc/sdccman.lyx: removed screenshot and provided link instead
6769
6770 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6771
6772         * doc/sdccman.lyx: added section about debugging with ddd
6773         * doc/figures/ddd_example.eps: screenshot of debugging session
6774
6775 2005-07-04 Raphael Neider <rneider AT web.de>
6776
6777         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
6778           like CODE pointers, fixes #1115683
6779         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
6780           call, fixes bugs #1232211, #1228110,
6781           fixed wrong casts to pCodeFlow from pCodeInstructions
6782
6783 2005-07-04 Raphael Neider <rneider AT web.de>
6784
6785         * src/pic/gen.c (popGet): changed assert to allow for
6786           bit operands
6787         * (popGetAddr): changed signature to provide
6788           an additional index, patched all call sites
6789         * (genCmpEq): handle literal-like operands correctly
6790         * (genAddrOf): added sanity checks on __code/__data pointers
6791         * (genAssign): added handling of symbols from __code section
6792         * (gencjne): do not generate code for comparisons whose result
6793           is neither stored nor used, fixes bug #1171114
6794         * (AccLsh, AccRsh): operate on operand instead of WREG
6795         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
6796           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
6797           by known count
6798         * rewrote complete shift-by-literal logic, commented unused
6799           functions out
6800         * (genConstPointerGet): get multiple bytes (if result size > 1),
6801           fixed handling of non-immediate addresses
6802         * (genPointerGet): handle CODE pointers like CONST pointers
6803         * (genpic14Code): insert C-SRC lines as Cource-pCodes
6804         * ({aop,op}_isLitLike): NEW, single place to decide whether an
6805           operand is to be treated as a literal or not
6806         * (mov2w,genPcall,genCmpEq),
6807           src/pic/genarith.c: use aop_isLitLike() to decide between
6808           literal/register contents
6809         * (addSign): added missing offset
6810         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
6811           only emit comment in debug-mode,
6812           use {aop,op}_isLitLike throughout the file
6813         * src/pic/glue.c: fix initializers for pointers (work in progress)
6814         * src/pic/pcode.c (get_op): honor index on _const symbols
6815         * ({reset,dump}pCodeStatistics): NEW, estimate code size
6816         * (dumppBlock): added pCode size estimation
6817         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
6818           check for IS_SYMOP before OP_SYMBOL'ing
6819         * fixed indentation, compacted switch-statements
6820         * (allocReg): find free register and allocate it instead of
6821           allocating new registers all the time
6822         * (deassignLRs): prevent POINTER_GET's from being assigned the same
6823           registers as its operands (necessary only for multibyte GETs)
6824
6825 2005-07-01 Raphael Neider <rneider AT web.de>
6826
6827         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
6828           debugging .asm-output macros FENTRY + FEXIT
6829         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
6830           way... I wonder...
6831         * (emitpComment): NEW, printf to pCode
6832         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
6833           offset handling
6834         * (popGetAddr): NEW, variant of popGet to access an immediates
6835           high(er) bytes instead of the n'th byte of memory they reference,
6836           replaced popGet with popGetAddr where neccessary
6837         * (genDataPointerGet): reactivated and fixed implementation
6838         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
6839           accesses
6840         * (genDataPointerSet): fixed multibyte assignments
6841         * (genpic14Code): fixed --i-code-in-asm handling
6842         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
6843         * (genPlus): fixed index-out-of-bounds error
6844         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
6845         * src/pic/ralloc.c: added debugging output macro FENTRY2
6846         * (spillThis): fixed indentation, enbraced for-body for clarity
6847         * (rematStr): commented out as now unused
6848         * (regTypeNum): commented out special spill case (overwrites
6849           arbitrary values)
6850         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
6851
6852 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
6853
6854         * doc/sdccman.lyx: documented sfr16/sfr32,
6855           added example for using storage class with function pointers
6856         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
6857
6858 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
6859
6860         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
6861         * device/lib/_itoa.c,
6862         * device/lib/_ltoa.c: optimized codesize
6863         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
6864           but don't know how to suppress the double warning.
6865         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
6866         * support/Util/SDCCerr.c,
6867         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
6868
6869 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
6870
6871         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
6872           fixed old K&R prototypes
6873         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
6874         * device/lib/_gptrget.c,
6875         * device/lib/_gptrgetc.c,
6876         * device/lib/_gptrput.c: changed versions for new memory indicator values,
6877           also new versions for small generic pointers and banked generic pointers
6878         * src/port.h: added const_name
6879         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
6880         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
6881         * src/SDCCcse.c (findPrevIc): check all associative operators
6882         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
6883         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
6884         * src/SDCCmem.c: updated comments,
6885           set far-space to 0 for pdata, results in optimized code
6886         * src/SDCCmem.h: added macro CONST_NAME
6887         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
6888           moving the info into the highest bits, see also gptrget/gptrput
6889         * src/src.dsp: added sdcc.ico to project files
6890         * src/avr/gen.c (genCast): fixed bug 0x%d
6891         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
6892         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
6893           relation between ptr_type and DCL_TYPE,
6894           (genCast): fixed bug 0x%d
6895         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
6896           (CODE)" for const_name
6897         * src/hc08/gen.c (genCast): fixed bug 0x%d
6898         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
6899           (hc08_port): added "CONST (CODE)" for const_name
6900         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
6901           (aopForRemat, adjustArithmeticResult): disconnected direct relation
6902           between ptr_type and DCL_TYPE,
6903           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
6904           operand* and took AOP() inside function so sfr-ness can be checked,
6905           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
6906           new prototype,
6907           (genFunction, genEndFunction): optimized stack setup,
6908           (genMinus): optimized for literals with ending zeroes (in bytes),
6909           (genCast): fixed bug 0x%d
6910         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
6911           (mcs51_port): added "CONST (CODE)" for const_name
6912         * src/mcs51/peeph.def: made rule 226 more generic
6913         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
6914         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
6915         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
6916         * src/z80/main.c (z80_port): added NULL for const_name,
6917           (gbz80_port): added NULL for const_name
6918         * support/regression/tests/bug663539.c,
6919         * support/regression/tests/sfr16.c: new tests
6920
6921 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6922
6923         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
6924
6925 2005-06-24 Raphael Neider <rneider AT web.de>
6926
6927         * device/lib/pic16/libdev/pic18f[68][567]20.c:
6928           corrected typos...
6929         * device/include/pic16/signal.h: added USBIF
6930           and SIG_USB
6931
6932 2005-06-24 Raphael Neider <rneider AT web.de>
6933
6934         * device/lib/pic16/libdev/pic18f2455.c,
6935           device/include/pic16/pic18f2455.h: NEW
6936         * device/include/pic16/pic18fregs.h,
6937           device/lib/pic16/pics.all,
6938           src/pic16/device.c: added 18f2455
6939         * device/lib/pic16/libdev/pic18f[68][567]20.c,
6940           device/include/pic16/{pic18f[68][567].h,usart.h}:
6941           replaced MULTIPLE_USARTS define with more relaible
6942           compatibility sfrs (for USART access)
6943
6944 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
6945
6946         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
6947           and the output asm file line is printed on two lines.
6948
6949 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6950
6951         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
6952           BGT, BLE, BHI, and BLS instructions
6953         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
6954           genCmpEq): removed
6955         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
6956           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
6957           fixes bug #1216342
6958         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
6959
6960 2005-06-15 Raphael Neider <rneider AT web.de>
6961
6962         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
6963         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
6964         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
6965           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
6966           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
6967
6968 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6969
6970         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
6971           Marcel Telka in bug #1215704
6972
6973 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
6974
6975         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
6976           located in shared memory bank.
6977
6978 2005-05-31 Raphael Neider <rneider AT web.de>
6979
6980         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
6981           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
6982           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
6983
6984 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
6985
6986         * device/lib/_strncpy.c: fixed the fix
6987
6988 2005-05-26 Raphael Neider <rneider AT web.de>
6989
6990         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
6991           initializers with \0, bug #1208187
6992         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
6993           intializers with \0, bug #1208187
6994
6995 2005-05-26 Raphael Neider <rneider AT web.de>
6996
6997         * src/pic16/glue.c (pic16_printIvalChar): fixed string
6998           initializers with \0, bug #1208187
6999         * src/pic16/main.c (_process_pragma): added sanity checks
7000           for stack position and size, emit warnings when appropriate
7001
7002 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
7003
7004         * device/lib/_strncpy.c: fixed not filling with \0
7005
7006 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7007
7008         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
7009           createFunction),
7010         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
7011           compound_statement),
7012         * src/SDCCsymt.h,
7013         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
7014
7015 2005-05-24 Raphael Neider <rneider AT web.de>
7016
7017         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
7018
7019 2005-05-24 Raphael Neider <rneider AT web.de>
7020
7021         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
7022           TRISE definitions, closes bug #1162453
7023
7024 2005-05-22 Raphael Neider <rneider AT web.de>
7025
7026         * src/pic16/main.c (_process_pragma): check for missing
7027           arguments to pragmas code and udata
7028         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
7029           consistency fixes to match other headers (thanks to Jim Paris)
7030         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
7031
7032 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
7033
7034         * src/SDCCicode.c (isOperandEqual): fixed missing ;
7035
7036 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
7037
7038         * support/regression/tests/bug1198642.c: new test
7039         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
7040         * src/SDCCcse.c (findPrevIc): added comment, please have a look
7041         * support/scripts/resource.h,
7042         * support/scripts/resource.rc,
7043         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
7044         * support/scripts/sdcc.ico: added 32x32 icon
7045
7046 2005-05-18 Raphael Neider <rneider AT web.de>
7047
7048         * device/lib/pic16/libdev/pic18f*.c,
7049         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
7050           keywords to "__sfr" and "__at (X)"
7051         * device/include/pic16/pic18fregs.h: added pic18f4520
7052         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
7053           #1203088 (MPLAB compatibility)
7054
7055 2005-05-17 Raphael Neider <rneider AT web.de>
7056
7057         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
7058         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
7059         * device/lib/pic16/pics.all: added new devices
7060         * src/pic16/device.c: added support for pic18f4520
7061
7062 2005-05-16 Raphael Neider <rneider AT web.de>
7063         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
7064         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
7065         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
7066           convenience function for bit access
7067
7068 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
7069
7070         * device/lib/printf_large.c: fixed bug 1193299
7071         * support/regression/tests/bug1057979.c: added test %3.3s
7072
7073 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7074
7075         * device/include/mcs51/8051.h,
7076         * device/include/mcs51/8052.h: made parseable with lint
7077         * device/include/mcs51/lint.h: added include file for (sp)lint
7078         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
7079         * doc/cdbfileformat.lyx,
7080         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
7081
7082 2005-05-14 Raphael Neider <rneider AT web.de>
7083
7084         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
7085         * device/lib/pic16/libc/stdlib/itoa.c (new)
7086         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
7087         * device/lib/pic16/libio/Makefile: exclude subdir according to
7088           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
7089         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
7090         * src/pic16/gen.c (genFunction): prevent annoying warning
7091         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
7092           nameclashes on BeOS
7093         * support/cpp2/cppmain.c (cpp_output_string): new
7094         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
7095           fixes bug 1116802
7096
7097 2005-05-13 Borut Razem <borut.razem AT siol.net>
7098
7099         * src/SDCCmain.c (linkEdit): fixed bug 1195202
7100
7101 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7102
7103         * .version: changed to version 2.5.1; back to bleeding edge development
7104
7105 2005-05-11 Borut Razem <borut.razem AT siol.net>
7106
7107         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
7108           generate PDF version 1.3 documents
7109
7110 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7111
7112         * .version: changed to version 2.5.0
7113
7114 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7115
7116         * doc/sdccman.lyx: updated weblinks, index and smaller updates
7117
7118 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7119
7120         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
7121         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
7122         well as many smaller updates.
7123         * .version: changed to version 2.5.0-pre1
7124
7125 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7126
7127         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
7128
7129 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
7130
7131         * support/regression/tests/bug1185672.c: added
7132         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
7133           bug 1185672
7134         * src/mcs51/gen.c (genCall): added comments, made it look safer
7135         * src/mcs51/gen.c (genEndFunction): simplified
7136
7137 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
7138
7139         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
7140
7141 2005-04-14 Borut Razem <borut.razem AT siol.net>
7142
7143         * fixed bug 1045046 - SIGSEGV with really simple code?:
7144           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
7145           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
7146
7147 2005-04-14 Borut Razem <borut.razem AT siol.net>
7148
7149         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
7150           src/pic16/device.h: temporarily disabled experimental #inline pragma
7151           for 2.5.0 release
7152
7153 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
7154
7155         * device/include/z80/stdio.h,
7156         * device/include/z80/string.h: removed these highly incomplete files so
7157           SDCC can use the default ones in device/include/
7158
7159 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7160
7161         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
7162         gcc warning.
7163         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
7164         fix sdcpp warnings.
7165
7166 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
7167
7168         * device/include/malloc.h: removed redundant __reentrant prototypes
7169         * device/lib/_mullong.c: added working xstack variant in asm (C version
7170           doesn't pass regression tests)
7171         * device/lib/bpx.c: used __data and made bpx char for mcs51
7172         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
7173           (createFunction): fixed bug with xstackPtr
7174         * src/SDCCcse.c: corrected comments
7175         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
7176           (killDeadCode, eBBlockFromiCode): removed unused code
7177         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
7178           corrected comments
7179         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
7180           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
7181           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
7182           (genModOneByte): fixed warning in MSVC
7183         * src/mcs51/main.c (): added comments
7184         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
7185
7186 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
7187
7188         * src/SDCCmain.c (linkEdit): oops, changed one line too many
7189
7190 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
7191
7192         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
7193
7194 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
7195
7196         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
7197         characters arrays of larger size than the declared one.
7198
7199 2005-04-10 Borut Razem <borut.razem AT siol.net>
7200
7201         * src/pic/gen.c (genInline),
7202           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
7203           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
7204           (findNextInstruction), (findPrevInstruction),
7205           (findInstructionUsingLabel),
7206           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
7207         * src/pic/pcode.c (findLabel): added missing '\n'
7208         * src/src.dsp: added SDCCdwarf2.c to the project
7209
7210 2005-04-09 Borut Razem <borut.razem AT siol.net>
7211
7212         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
7213
7214 2005-04-08 Raphael Neider <rneider AT web.de>
7215
7216         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
7217           into the chain after a given one) and mergeDefmapSymbols (combine
7218           defmap entries for each symbol per pcode)
7219         * (createDefmap): have defmap entries merged in the end
7220         * (defmapReplaceSymRef): split defmap entries covering two accesses to
7221           a symbol before replacing one access type's symbol, merge symbols in
7222           the end (replacement symbol might already have an entry)
7223         * (assignValnums): keep reference to written WREG intact
7224
7225 2005-04-08 Raphael Neider <rneider AT web.de>
7226
7227         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
7228           Alpha)
7229
7230 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
7231
7232         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
7233         bytes
7234
7235 2005-04-07 Raphael Neider <rneider AT web.de>
7236
7237         * device/include/pic16/usart.h: added compatibility defines for
7238           devices with more than one USART
7239         * device/include/pic16/pic18f[68][567]20.h: activated above defines
7240
7241 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
7242
7243         * device/lib/Makefile.in: updated for port specific include
7244
7245 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
7246
7247         * support/regression/ports/mcs51/spec.mk: added mcs51 include
7248
7249 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
7250
7251         * device/include/8051.h,
7252         * device/include/8052.h,
7253         * device/include/at89S8252.h,
7254         * device/include/at89c55.h,
7255         * device/include/at89x051.h,
7256         * device/include/at89x51.h,
7257         * device/include/at89x52.h,
7258         * device/include/mcs51reg.h,
7259         * device/include/reg51.h,
7260         * device/include/reg764.h,
7261         * device/include/regc515c.h,
7262         * device/include/sab80515.h: (re)moved these 12 files
7263         * device/include/mcs51/8051.h,
7264         * device/include/mcs51/8052.h,
7265         * device/include/mcs51/at89S8252.h,
7266         * device/include/mcs51/at89c55.h,
7267         * device/include/mcs51/at89x051.h,
7268         * device/include/mcs51/at89x51.h,
7269         * device/include/mcs51/at89x52.h,
7270         * device/include/mcs51/mcs51reg.h,
7271         * device/include/mcs51/reg51.h,
7272         * device/include/mcs51/reg764.h,
7273         * device/include/mcs51/regc515c.h,
7274         * device/include/mcs51/sab80515.h: and added them here
7275
7276 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
7277
7278         * device/include/stdarg.h: changed SDCC specific keywords to double
7279           underlined form.
7280         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
7281           mcs51 and ds390.
7282         * device/include/hc08/mc68hc908gp32.h,
7283         * device/include/hc08/mc68hc908jb8.h,
7284         * device/include/hc08/mc68hc908jkjl.h,
7285         * device/include/hc08/mc68hc908qy.h: fixed comments
7286         * device/include/mcs51/README: updated
7287         * device/include/mcs51/c8051f120.h: added PINRSF
7288         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
7289         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
7290           amidst code. Also inline is not supported.
7291
7292 2005-04-06 Raphael Neider <rneider AT web.de>
7293
7294         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
7295         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
7296           callers stack/frame pointers
7297
7298 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
7299
7300         * device/include/pic16/usart.h: added, missing in previous commit,
7301         * device/include/pic16/adc.h: fixed typo,
7302         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
7303         commit,
7304         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
7305         <p18fxxx.inc>
7306         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
7307         uninitialized because a bug appears with gplink
7308         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
7309         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
7310         complains for unrecognised option
7311
7312 2005-04-05 Raphael Neider <rneider AT web.de>
7313
7314         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
7315           structs as well (using memcpy)
7316         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
7317           on ISRs (GOTO has no label)
7318         * src/pic16/device.h: added OF_OPTIMIZE_DF
7319         * src/pic16/main.c: added compiler switch --optimize-df to enable the
7320           new data flow analysis/optimization
7321         * src/pic16/pcode.c: added (prototypes for and implementation of)
7322           dataflow analysis functions, fixed pCodeInstructions' inCond and
7323           outCond values, made RCALL a branch instruction
7324         * (pic16_unlinkpCode): keep C line if possible
7325         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
7326           C line moved if possible
7327         * (pic16_getRegFrompCodeOp): NEW, improved version of...
7328         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
7329           to use new pic16_getRegFrompCodeOp (works for more SFRs)
7330         * (pic16_BuildFlow): fixed skip instructions with label (did not start
7331           new flow)
7332         * (pic16_getJumptabpCode): NEW, needed in...
7333         * (LinkFlow): fixed handling of jumptables, calls and conditional
7334           branches
7335         * (pic16_InsertCommentAfter): NEW
7336         * (pic16_pCodeReplace): made verbose and flow preserving
7337         * (AnalyzeFlow): added call to data flow analysis
7338         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
7339         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
7340         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
7341
7342 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7343
7344         * src/SDCCast.c (decorateType): fixed bug #1105626
7345
7346 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
7347
7348         * device/include/asm/pic16/features.h,
7349         * pic18f*.h headers,
7350         * device/include/pic16/adc.h,
7351         * device/include/pic16/delay.h,
7352         * device/include/pic16/i2c.h,
7353         * device/include/pic16/malloc.h,
7354         * device/include/pic16/stdio.h,
7355         * device/include/pic16/stdlib.h,
7356         * device/include/pic16/string.h,
7357         * device/lib/pic16/libc/stdio/printf_tiny.c,
7358         * device/lib/pic16/libc/stdio/printf_small.c,
7359         * device/lib/pic16/libc/stdio/strmgpsim.c,
7360         * device/lib/pic16/libc/stdio/strmmssp.c,
7361         * device/lib/pic16/libc/stdio/strmusart.c,
7362         * device/lib/pic16/libc/stdio/vfprintf.c,
7363         * device/lib/pic16/libc/stdlib/ltoa.c,
7364         * device/lib/pic16/libc/stdlib/putchar.c,
7365         * device/lib/pic16/libc/stdlib/x_ftoa.c,
7366         * device/lib/pic16/libc/stdlib/memchrpgm.c,
7367         * device/lib/pic16/libc/stdlib/memchrram.c,
7368         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
7369         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
7370         * device/lib/pic16/libio/adc/adcbusy.c,
7371         * device/lib/pic16/libio/adc/adcread.c,
7372         * device/lib/pic16/libio/adc/adcsetch.c,
7373         * device/lib/pic16/libio/usart/ubaud.c,
7374         * device/lib/pic16/libio/usart/ubusy.c,
7375         * device/lib/pic16/libio/usart/udrdy.c,
7376         * device/lib/pic16/libio/usart/uopen.c,
7377         * device/lib/pic16/libio/usart/uputc.c,
7378         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
7379         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
7380         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
7381         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
7382         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
7383         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
7384         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
7385         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
7386         specific keywords to double underlined form,
7387         * device/lib/pic16/libc/Makefile.rules,
7388         * device/lib/pic16/libsdcc/Makefile.rules,
7389         * device/lib/pic16/libm/Makefile,
7390         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
7391         to compile with C standard set in Makefile.common
7392         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
7393         rand.c and crc.c in compilation process,
7394         * device/lib/pic16/libsdcc/int/divuint.c,
7395         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
7396         `c' from signed to unsigned,
7397         * device/lib/pic16/startup/crt0.c,
7398         * device/lib/pic16/startup/crt0i.c,
7399         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
7400         keywords to double underlined form, bug fixes in _do_cinit function
7401         which prevented the correct initialization of the .idata segment,
7402         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
7403         core to enter a infinite loop
7404         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
7405
7406 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7407
7408         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
7409
7410 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7411
7412         * device/include/Makefile.in: add support for hc08 subdirectory
7413         * device/include/hc08/: new subdirectory
7414         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
7415         Lucas Loizaga, thanks!
7416         * device/include/hc08/mc68hc908qy.h,
7417         * device/include/hc08/mc68hc908gp32.h,
7418         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
7419         their own directory. Changed internal macro names to use the compiler
7420         reserved namespace. Changed SDCC specific keywords to double
7421         underlined form.
7422         * device/include/math.h,
7423         * device/include/malloc.h,
7424         * device/include/stdarg.h,
7425         * device/include/stdbool.h
7426         * device/include/string.h,
7427         * device/include/tinibios.h,
7428         * device/include/ds400rom.h,
7429         * device/include/8051.h,
7430         * device/include/8052.h,
7431         * device/include/80c51xa.h,
7432         * device/include/at89c55.h,
7433         * device/include/at89S8252.h,
7434         * device/include/at89x51.h,
7435         * device/include/at89x52.h,
7436         * device/include/ds80c390.h,
7437         * device/include/reg764.h,
7438         * device/include/regc515c.h,
7439         * device/include/sab80515.h,
7440         * device/include/mcs51/c8051f000.h,
7441         * device/include/mcs51/c8051f018.h,
7442         * device/include/mcs51/c8051f020.h,
7443         * device/include/mcs51/c8051f040.h,
7444         * device/include/mcs51/c8051f060.h,
7445         * device/include/mcs51/c8051f120.h,
7446         * device/include/mcs51/c8051f300.h,
7447         * device/include/mcs51/c8051f310.h,
7448         * device/include/mcs51/c8051f320.h,
7449         * device/include/mcs51/c8051f330.h,
7450         * device/include/mcs51/c8051f350.h,
7451         * device/include/z180.h: Changed SDCC specific keywords to double
7452         underlined form.
7453
7454 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
7455
7456         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
7457         18F4455,
7458         * (pic16_assignConfigWordValue): disable testing of configuration
7459         register value with config mask,
7460         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
7461         function with port->fun_prefix,
7462         * (genFunction): when generating a naked interrupt function never
7463         create an absolute segment placed in interrupt vector address, place
7464         the actual interrupt function at IVA instead, when an interrupt
7465         function is generated with unspecified interrupt then do not create
7466         the absolute section,
7467         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
7468         code for generating a call to generic pointer get/put function with
7469         a call to function pic16_callGenericPointer(),
7470         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
7471         the call to the generic pointer get/put functions with prefixing the
7472         function name with port->fun_prefix,
7473         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
7474         * src/pic16/main.c (_process_pragma): prefix function with
7475         port->fun_prefix,
7476         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
7477         calling assembler, old 18Fxxxx macro is deprecated,
7478         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
7479         PC_ASMDIR in while condition,
7480         * (findInstruction): add PC_ASMDIR in while condition,
7481         * (buildCallTree): prefix main with port->fun_prefix,
7482         * (pic16_pCode2str): fixed bug that didn't emit the memory access
7483         identifier for variable with banked access in instructions BTFSS,
7484         BTFSC, BCF, BSF, BTG
7485         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
7486         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
7487         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
7488         perform optimization when enviroment variable NO_REG_OPT is set,
7489         * (insideLRBlock): NEW, return 1 if register is inside an
7490         INF_LOCALREGS block,
7491         * (RemoveRegFromLRBlock): remove a register that is completely
7492         eliminated by register optimization, but it is still left in local
7493         register store/restore in/from stack block,
7494         * (Remove2pcodes): after removing register, check to see if it
7495         should be removed from local register store/restore in/from stack
7496         block,
7497         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
7498         DUMMY_READ_VOLATILE,
7499
7500         * device/include/pic16/adc.h: minor prototype modifications and
7501         update,
7502         * device/include/pic16/malloc.h: added GPL notice various
7503         modifications,
7504         * device/include/pic16/stdint.h: NEW, standard header for ints
7505         * device/include/pic16/delay.h: NEW, header for delay functions,
7506         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
7507         delay1mtcy,
7508         * device/include/pic16/signal.h: NEW, header providing helper macros
7509         for implementing signal handlers,
7510         * device/include/pic16/stdio.h: added prototypes for functions,
7511         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
7512         prototypes for stdin and stdout, added macro PUTCHAR to
7513         automatically implement putchar function prototype,
7514         * device/include/pic16/usart.h: modified and updated USART library,
7515         * device/lib/pic16/libio/adc/,
7516         * device/lib/pic16/libio/i2c: some modifications to improve library
7517         performance,
7518         * device/lib/pic16/libc/stdio/: modifications for the new printf*
7519         family of functions,
7520         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
7521         family of functions and other sources,
7522         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
7523         of the PIC18Fxx[28] devices,
7524         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
7525         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
7526         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
7527         _do_cinit function, because the previous failed when local variables
7528         where not placed in the same memory bank,
7529         * device/lib/pic16/libsdcc/char/: various modifications to improve
7530         library performance,
7531         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
7532         information on the new functions of the c library and more...
7533
7534 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7535
7536         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
7537
7538 2005-03-26 Raphael Neider <rneider AT web.de>
7539
7540         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
7541           if condition == CARRY)
7542         * (genCmp): adapted to new genSkipc semantics
7543         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
7544           on rIfx (genCmp was broken)
7545
7546 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7547
7548         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
7549         * src/z80/main.c (_keywords[]),
7550         * src/SDCCglobal.h (struct options),
7551         * src/SDCC.y,
7552         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
7553         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
7554         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
7555         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
7556         always available in leading double underscore form. The C99 support is
7557         mostly missing, but it's a start.
7558         * support/regression/tests/bug-227710.c: fixed nonconforming use of
7559         reserved identifier "__data".
7560
7561 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
7562
7563         * src/mcs51/peeph.def: fixed bug 1170013
7564
7565 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
7566
7567         * device/include/mcs51reg.h: fixed bug 842007
7568
7569 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7570
7571         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
7572         last time.
7573
7574 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7575
7576         * src/port.h (struct PORT),
7577         * src/avr/ralloc.c (avr_assignRegisters),
7578         * src/avr/main.c,
7579         * src/ds390/ralloc.c (ds390_assignRegisters),
7580         * src/ds390/main.c,
7581         * src/hc08/ralloc.c (hc08_assignRegisters),
7582         * src/hc08/main.c,
7583         * src/mcs51/ralloc.c (mcs51_assignRegisters),
7584         * src/mcs51/main.c,
7585         * src/pic/ralloc.c (pic14_assignRegisters),
7586         * src/pic/main.c,
7587         * src/pic16/ralloc.c (pic16_assignRegisters),
7588         * src/pic16/main.c,
7589         * src/xa51/ralloc.c (xa51_assignRegisters),
7590         * src/xa51/main.c,
7591         * src/z80/ralloc.c (z80_assignRegisters),
7592         * src/z80/ralloc.h,
7593         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
7594         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
7595         * src/SDCCcse.h,
7596         * src/SDCCdflow.c (computeDataFlow),
7597         * src/SDCCdflow.h,
7598         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
7599         * src/SDCCloop.h,
7600         * src/SDCCcflow.c (*),
7601         * src/SDCCcflow.h,
7602         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
7603         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
7604         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
7605         immedDom() returning wrong block; probably fixes bug #1160833)
7606
7607 2005-03-20 Borut Razem <borut.razem AT siol.net>
7608
7609         * support/scripts/inc2h.pl: WIN32 port
7610
7611 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
7612
7613         * device/lib/makefile.in: added abs.c and labs.c
7614
7615 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
7616
7617         * device/include/stdint.h: added
7618         * device/lib/abs.c: added
7619         * device/lib/labs.c: added
7620         * device/include/stdlib.h: added abs() and labs() prototypes
7621         * device/lib/libsdcc.lib: added abs and labs
7622         * device/include/float.h,
7623         * device/lib/_fsmul.c,
7624         * device/lib/printf_fast.c,
7625         * device/lib/printf_tiny.c: updated comments
7626
7627 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7628
7629         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
7630         bug #1164313
7631
7632 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7633
7634         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
7635         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
7636
7637 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
7638
7639         * device/lib/printf_large.c: removed inline assembly for portability and
7640           readability. Use printf_fast if speed or size are more important.
7641         * src/pic16/gen.c: removed conditions around use of DEBUGpc
7642         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
7643
7644 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
7645
7646         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
7647         prevent compiler warning
7648
7649 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
7650
7651         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
7652         moved to level 0 and declared as static. Also they are explicit
7653         placed in access bank. This was necessery because some times they
7654         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
7655         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
7656         optimizations. Currently only compare to unsigned char is implemented,
7657         * src/pic16/gen.c: added fReturnIdx array,
7658         * (struct resolvedIfx) is moved to gen.h and made public,
7659         * (struct _G): added sregsAlloc and sregsAllocSet fields,
7660         * (aopForSym): added an optimization to directly store in stack of
7661         the operand of a SEND iCode,
7662         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
7663         but as registers instead (AOP_REG) using the fReturnIdx array,
7664         * (pic16_freeAsmop): remove the freed register from the
7665         _G.sregsAlloc field,
7666         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
7667         a compare of 'WREG',
7668         * (pic16_popGetTempRegCond): changed function prototype, now
7669         function takes also a bitVector argument v which holds the current
7670         set of registers that are allocated for stack access by aopForSym,
7671         registers allocated in aopForSym for accessing stack symbols are not
7672         any more part of the functions usedRegs field,
7673         * (genCall): some times aopOp is called for a stack variable to be
7674         send, aopForSym might perform the push, if this is true make sure
7675         that genCall doesn't push the variable twice by testing _G.resDirect,
7676         * (genFunction): changed testing for unspecified interrupt number
7677         from 256 to INTNO_UNSPEC,
7678         * modified selection scheme of frame pointer generation. Previously
7679         if function did use local registers a frame pointer was generated,
7680         now a frame pointer is generated only if function has arguments
7681         (that need PLUSW2 register access), or has stack arguments, or the
7682         compiler is not instructed to omit the frame pointer,
7683         * (genEndFunction): before restoring local registers that were saved
7684         in the function preamble, also restore the registers that *might*
7685         have been allocated for stack access,
7686         * (genRet): removed some old comments,
7687         * (genCmp, the active (RN's) version): added a call to the
7688         pic16_genCmp_special function to perform the compare with a more
7689         robust and optimized way,
7690         * (genInline): a feature has been added in inline code generation,
7691         which allows a wildcard variable substitution when writing inline
7692         assembly. Code is incomplete and experimental therefore undocumented,
7693         * (genCast): changed order of aopOp for result and right to allow
7694         aopForSym to directly load the result if possible,
7695         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
7696         perform an optimized compare on some selected special occasions,
7697         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
7698         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
7699         generate an IVT any more,
7700         * src/pic16/main.c (pic16_optionsTable): added command line option
7701         --optimize-cmp,
7702         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
7703         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
7704         macros,
7705         * src/pic16/NOTES: Raphael Neider added in list of active developers
7706         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
7707         jumptable_end to prevent bug #,
7708         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
7709         inCond and outCond fields,
7710         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
7711         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
7712         turn off register spilling,
7713         * (packRegsForOneUse): synced with other ports' versions although it
7714         is not used currently,
7715         * (pic16_packRegisters): added an optimization while reading
7716         structure bitfields, some registers may be saved (malloc code is
7717         decreased by 80 bytes)
7718
7719 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
7720
7721         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
7722         left is a bitfield, if yes, then don't optimize assignment. Perhaps
7723         this can be optimized more?
7724
7725 2005-03-10 Raphael Neider <rneider AT web.de>
7726
7727         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
7728           genNearPointerGet): (hopefully) fixed access to bitfields via
7729           pointers (p->bitN = x; and x = p->bitN; failed)
7730
7731 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
7732
7733         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
7734
7735 2005-03-09 Raphael Neider <rneider AT web.de>
7736
7737         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
7738
7739 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
7740
7741         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
7742         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
7743           (regTypeNum): set REG_BIT type if necessary
7744         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
7745         * support/regression/tests/critical.c: check bug 1144613
7746
7747 2005-03-02 Raphael Neider <rneider AT web.de>
7748
7749         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
7750
7751 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7752
7753         * src/avr/ralloc.c (serialRegAssign),
7754         * src/ds390/ralloc.c (serialRegAssign),
7755         * src/hc08/ralloc.c (serialRegAssign),
7756         * src/mcs51/ralloc.c (serialRegAssign),
7757         * src/pic/ralloc.c (serialRegAssign),
7758         * src/pic16/ralloc.c (serialRegAssign),
7759         * src/xa51/ralloc.c (serialRegAssign),
7760         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
7761
7762 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
7763
7764         * src/SDCCast.c (decorateType): fixed bug 1124787
7765
7766 2005-02-20 Hubert Sack <sack AT digiplan.de>
7767         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7768
7769         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
7770         patch #1121755
7771
7772 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7773
7774         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
7775         to keep the correct label reference count when adding/removing references
7776         to labels. A peephole file using this is appended to patch #1144962.
7777
7778 2005-02-14 Raphael Neider <rneider AT web.de>
7779
7780         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
7781         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
7782         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
7783           retrievals of result operand's value on assignment
7784
7785 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
7786
7787         * device/include/pic16/string.h: modified prototype for memccpy()
7788         to memccpy(void *, void *, char, size_t)
7789         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
7790         check whether to omit frame pointer or not,
7791         * (genInline): convert all occurences of "\n" to LF in inline
7792         assembler blocks, this helps formatting the inline text,
7793         * (pic16_loadFSR0): modified prototype,
7794         * (genNearPointerGet, genNearPointerSet): reorganization of code,
7795         removed some 8051 legacy code,
7796         * (genPackBits): enabled handling bitfields exceeding one byte in size,
7797         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
7798         before allocating temporary registers in functions,
7799
7800 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
7801
7802         * support/regression/tests/bitvars.c: corrected the "fix"
7803
7804 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
7805
7806         * support/regression/tests/bitvars.c,
7807         * support/regression/tests/bitwise.c,
7808         * support/regression/tests/rotate.c: "fixed" problems on Alpha
7809
7810 2005-02-10 Raphael Neider <rneider AT web.de>
7811
7812         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
7813           different size for Alpha
7814         * src/pic16/gen.c (genCmpEq) : improved compare with 0
7815
7816 2005-02-09 Raphael Neider <rneider AT web.de>
7817
7818         * src/SDCC.lex(doPragma) : save and restore warning options as well
7819           (also added new stack plus clone- and copyAndFreeSDCCERRG())
7820         * have #pragma less_pedantic set the errorlevel to WARNING
7821           (fixes #1117001)
7822         * (cloneOptimize) : fixed wrong malloc's size
7823         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
7824           facilitate correct handling of #pragma (save|restore)
7825
7826 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
7827
7828         * src/mcs51/gen.c: removed non-standard C nameless struct/union
7829
7830 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
7831
7832         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
7833
7834 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
7835
7836         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
7837
7838 2005-02-02 Raphael Neider <rneider AT web.de>
7839
7840         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
7841         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
7842         * (pic16_storeForReturn): fixed to allow returning function pointers
7843         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
7844         * device/include/pic16/{stddef.h,stdbool.h}: added
7845
7846 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
7847
7848         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
7849
7850 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
7851
7852         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
7853         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
7854          appeared to be required
7855
7856 2005-01-31 Borut Razem <borut.razem AT siol.net>
7857
7858         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
7859           include/mcs51 and include/z80 directories to the package
7860
7861 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7862
7863         * src/hc08/gen.c (genFunction): fixed bug #1112752
7864
7865 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7866
7867         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
7868
7869 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7870
7871         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
7872
7873 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
7874
7875         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
7876
7877 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
7878
7879         * device/include/c8051fxxx.h: removed these 6 files
7880         * device/include/mcs51/c8051fxxx.h: added these 11 new files
7881
7882 2005-01-26 Raphael Neider <rneider AT web.de>
7883
7884         * src/pic16/gen.c (genAssign): fixed assignment from longs
7885           in codespace (were cut to three bytes)
7886         * (genDummyRead): implemented (except for CODESPACE...),
7887           fixed bug #1108575
7888         * src/pic16/glue.c (emitStatistics): beautified
7889         * device/lib/pic16/libm/Makefile: added include path
7890
7891 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7892
7893         * src/z80/gen.c (aopPut): fixed bug #1103902
7894
7895 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7896
7897         * device/lib/expf.c: fixed bug #1095792
7898
7899 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
7900
7901         * device/lib/pic16/libm: added Math library sources
7902
7903 2005-01-24 Raphael Neider <rneider AT web.de>
7904
7905         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
7906           to enable upcast to pCodeOpReg2 (there is no type tag to
7907           differenciate the two and pic16_popGet2p cast into PCOR2)
7908         * src/pic16/main.c (_process_pragma): fixed another malloc bug
7909           (sizeof(sectNames) changed to sizeof(sectName))
7910           Both patches fix segfaults under MinGW.
7911
7912 2005-01-23 Raphael Neider <rneider AT web.de>
7913
7914         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
7915           Safe_[mc]?alloc()'ed variables
7916         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
7917           of (byte sized) temporaries (assign them to WREG for now)
7918         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
7919           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
7920           this might fix SIGSEGVs on MinGW...
7921         * src/SDCCopt.c (killDeadCode): restored original behaviour
7922           (volatile operands might get thrown away though)
7923
7924 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
7925
7926         * src/pic16/gen.c: fixed bug #1106975,
7927         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
7928         pointer update, INTCON is saved, global interrupts are disabled and
7929         restored after updateing TOS.
7930         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
7931         * added function attribute 'shadowregs' to take advantage of shadow
7932         registers,
7933         * added function attribute 'wparam' as an alternative to the wparam
7934         pragma,
7935         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
7936         user declares a non-ISR function as 'shadowregs',
7937         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
7938
7939 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
7940
7941         * .version: bumped version number to 2.4.8
7942         * device/lib/pic16/pics.all: list of PIC18F devices supported by
7943         pic16 port,
7944         * device/lib/pic16/libio/i2c/: I2C module support library,
7945         * device/include/pic16/i2c.h: I2C support library header,
7946         * device/lib/pic16/libc/stdio/: standard IO support sources,
7947         * (printf_small.c): printf_small() source, supports float print,
7948         * (printf_tiny.c): printf_tiny() source, does not support floats,
7949         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
7950         enable global optimizations for entire library source, other
7951         Makefiles in the source tree are also modified to reflect this,
7952         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
7953         function,
7954         * doc/sdccman.lyx: updated to reflect new changes,
7955         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
7956         sym->onStack if-case,
7957         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
7958         sbit, idata, _idata, xdata, _xdata,
7959         * added pragma library, to link an external library, (see doc),
7960         * removed command line options, --pomit-config-words, --pomit-ivt,
7961         --pleave-reset-vector,
7962         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
7963         when calling assembler to reflect memory model used, also define
7964         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
7965         reflect stack model used,
7966         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
7967         on stack return NULL,
7968
7969 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
7970
7971         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
7972           of the operands is volatile. Fixes #1020220
7973
7974 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
7975
7976         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
7977         * (OptimizeRegUsage): make sure that there is really no other flow where
7978           the first pCode is used
7979
7980 2005-01-22 Raphael Neider <rneider AT web.de>
7981
7982         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
7983           to fix #1106967 (pCode->seq are not set up correctly)
7984
7985 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7986
7987         * src/SDCCglue.c (glue): make sure code area is declared before the
7988         static initialization area.
7989
7990 2005-01-21 Raphael Neider <rneider AT web.de>
7991
7992         * device/lib/Makefile.in: fixed test for pic16 install dir
7993         * device/lib/pic16/*/Makefile*: modified compile flags to enable
7994           optimizations
7995         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
7996           added --optimize-goto compiler switch and pragma wparam documentation
7997         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
7998         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
7999           and PRODH closing bug #1071770 (peephole optimizer)
8000
8001 2005-01-19 Raphael Neider <rneider AT web.de>
8002
8003         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
8004           cmdLine buffers (used when calling sdcpp...) are large enough
8005           (MAX_PATH=256 truncates arguments leading to system halts when
8006           used in MinGW...)
8007         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
8008         * (genUminus): rewritten to for efficiency
8009         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
8010           used uninitialized in some cases)
8011         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
8012           copy the third byte from the int -- now assumes 0x80 (data memory)
8013         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
8014           operands (genAddLit expects the iCode's operands to swapped as
8015           well), fixed leftover bytes (crashed for short left operands)
8016         * (pic16_genMinusDec): performance improvements, removed false
8017           PIC14 emitSKPNCs
8018         * (pic16_genMinus): fixed to cope with differently sized operands
8019         * src/pic16/glue.c (pic16_glue): added new banksel optimization
8020           for --obanksel > 1
8021         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
8022         * src/pic16/graph.[ch]: implementation of directed graphs, used by
8023           new banksel optimization
8024         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
8025           analysis for temporary registers (segfaults...)
8026         * src/pic16/peeph.def: added rule
8027
8028 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
8029
8030         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
8031         which converts a float number to its ASCII representation
8032         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
8033         functions to convert the fractional and integer part of a float to ASCII,
8034         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
8035         realloc.c): added _MALLOC_SPEC to explicit place variables in data
8036         ram
8037         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
8038         _STATMEM macros,
8039         * device/include/pic16/adc.h: added GPL info,
8040         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
8041         a pCodeOp as tested operand,
8042         * (genNearPointerGet): optimized bit testing, does not use
8043         intermediate register for bit value, test directly instead with
8044         BTFSS, BTFSC, works only for single bits,
8045         * (genpic16Code): dump the name of the iCode in the asm,
8046         * src/pic16/ralloc.c (decodeOp): removed static declaration and
8047         renamed to pic16_decodeOp,
8048         * (serialRegAssign): do not allocate a temporary register for iCode
8049         sequences that test a single bit for 1/0
8050
8051 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
8052
8053         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
8054         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
8055         access stack and frame pointers. They are initially assigned to
8056         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
8057         accessing SFRs. Updated all occurences of modification of stack or
8058         frame pointer in gen.c and pcode.c,
8059         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
8060         assigning of a literal value to pointers,
8061         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
8062         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
8063         selected
8064
8065 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
8066
8067         * doc/sdccman.lyx: update documentation about stack pragma, added
8068         some info for stack memory models
8069
8070 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8071
8072         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
8073
8074 2005-01-08 Raphael Neider <rneider AT web.de>
8075
8076         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
8077           udata sections to fix bug #1097823
8078
8079 2005-01-05 Raphael Neider <rneider AT web.de>
8080
8081         * src/pic16/gen.c (genGenericShift): added handling of differently
8082           sized left operand and result
8083
8084 2005-01-04 Raphael Neider <rneider AT web.de>
8085
8086         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
8087         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
8088           to hold the condition bit)
8089         * added new version of genCmp (old code available via #define)
8090         * added new version of genShiftLeft/genShiftRight in a generic
8091           way, now supports shifting by negative values
8092         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
8093           shiftCount (expected by genGenericShift)
8094         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
8095         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
8096           dump
8097         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
8098           is an invalid literal too...)
8099
8100 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
8101
8102         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
8103         from Raphael Neider,
8104         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
8105         for 8-bit literals. This fixes some literal operands which are sign
8106         extended to 16-bits ints when instruction needs only 8-bits.
8107
8108 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
8109
8110         * device/lib/logf.c: added mcs51 assembly version
8111         * device/lib/expf.c: added mcs51 assembly version
8112         * device/lib/_logexpf.c: new shared asm code for expf and logf
8113         * device/include/math.h: add defines for assembly math library
8114         * device/lib/Makefile.in: build new _logexpf.c
8115         * device/lib/libfloat.lib: use new _logexpf.c
8116
8117 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
8118
8119         * src/pic/device.c
8120         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
8121           device types which have less than 0x7f registers.
8122
8123 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
8124
8125         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
8126
8127 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
8128
8129         * device/lib/printf_fast.c: only build on supported arch.
8130         * device/lib/printf_tiny.c: only build on supported arch.
8131         * device/lib/printf_fast_f.c: only build if asm float lib
8132         * device/lib/_fsget1arg.c: only build if asm float lib
8133         * device/lib/_fsget2args.c: only build if asm float lib
8134         * device/lib/_fsnormalize.c: only build if asm float lib
8135         * device/lib/_fsreturnval.c: only build if asm float lib
8136         * device/lib/_fsrshift.c: only build if asm float lib
8137         * device/lib/_fsswapargs.c: only build if asm float lib
8138         * device/include/stdio.h: don't provide print_fast,
8139           print_fast_f, print_tiny prototypes if --xstack used
8140
8141 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
8142
8143         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
8144         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
8145           to the SOURCES
8146
8147 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
8148
8149         * device/lib/printf_fast_f.c: same as printf_fast, but
8150           with floating point enabled
8151         * device/lib/printf_fast.c: minor tweaks
8152         * device/include/stdio.h: add printf_fast_f
8153
8154 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
8155
8156         * src/SDCCmain.c: make --float-reent default for mcs51
8157         * device/lib/_fsadd.c: added mcs51 assembly version
8158         * device/lib/_fssub.c: added mcs51 assembly version
8159         * device/lib/_fsmul.c: added mcs51 assembly version
8160         * device/lib/_fsdiv.c: added mcs51 assembly version
8161         * device/lib/_fseq.c: added mcs51 assembly version
8162         * device/lib/_fsneq.c: added mcs51 assembly version
8163         * device/lib/_fsgt.c: added mcs51 assembly version
8164         * device/lib/_fslt.c: added mcs51 assembly version
8165         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
8166         * device/lib/Makefile.in: add _fscmp to build
8167         * device/lib/libfloat.lib: add _fscmp to build
8168
8169 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
8170
8171         * device/lib/_fs2slong.c: added mcs51 assembly version
8172         * device/lib/_fs2sint.c: added mcs51 assembly version
8173         * device/lib/_fs2schar.c: added mcs51 assembly version
8174         * device/lib/_fs2ulong.c: added mcs51 assembly version
8175         * device/lib/_fs2uint.c: added mcs51 assembly version
8176         * device/lib/_fs2uchar.c: added mcs51 assembly version
8177         * device/lib/_slong2fs.c: added mcs51 assembly version
8178         * device/lib/_sint2fs.c: added mcs51 assembly version
8179         * device/lib/_schar2fs.c: added mcs51 assembly version
8180         * device/lib/_ulong2fs.c: added mcs51 assembly version
8181         * device/lib/_uint2fs.c: added mcs51 assembly version
8182         * device/lib/_uchar2fs.c: added mcs51 assembly version
8183         * device/include/float.h: added #define to select asm vs c
8184
8185 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
8186
8187         * device/lib/printf_fast.c: improvements to float output
8188         * device/include/float.h: add defines for assembly float library
8189         * device/lib/_fsget1arg.c: receive 1 float arg
8190         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
8191         * device/lib/_fsnormalize.c: normalize a float
8192         * device/lib/_fsreturnval.c: return float, various helper routines
8193         * device/lib/_fsrshift.c: right shift a float's mantissa
8194         * device/lib/_fsswapargs.c: swap 2 floats
8195         * device/lib/Makefile.in: build these 6 new files for mcs51
8196         * device/lib/libfloat.lib: add these 6 files to the library
8197
8198 2004-12-26 Borut Razem <borut.razem AT siol.net>
8199
8200         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
8201           built by gcc 3.4.2
8202
8203 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
8204
8205         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
8206           and fully reentrant and register bank neutral.
8207         * device/lib/printf_fast.c: added float (not enabled by default),
8208           added compact/slower integer (also not enabled by default),
8209           improved size/speed of fast integer code, other minor changes
8210         * device/include/stdio.h, device/lib/Makefile.in,
8211           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
8212
8213 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
8214
8215         * src/pic16/pcode.c: declaring variables other than at the start of a
8216           block is not supported in C by VC6.
8217
8218 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
8219
8220         * applied a previous patch from Raphael Neider that wasn't included
8221         in the previous commits, which fixes infinite loops within jumptable
8222         improvements,
8223         * made some fixes that previous patches introduced
8224
8225 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
8226
8227         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
8228         that fixes an issue with AOP_PCODE asmop's offset,
8229         * (pic16_popCopyReg): update instance field too,
8230         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
8231         function of pic port,
8232         * (genCmp, genAnd, genAssign),
8233         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
8234
8235 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
8236
8237         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
8238         variables initial values to idata section,
8239         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
8240         variables in some functions. This utilizes parmBytes field of iCode
8241         structure to hold the offset of the variable in stack. (might be
8242         able to use the stack field too?)
8243         * applied patch from Raphael Neider # ### , # ###
8244         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
8245         variable initial values in idata section,
8246         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
8247         for static variables with initial value
8248         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
8249         applied fix in while loop from Raphael Neider.
8250
8251 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
8252
8253         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
8254         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
8255         * src/ds390/ralloc.c (serialRegAssign): spill bits
8256         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
8257         * support/Util/SDCCerr.c,
8258         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
8259         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
8260         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
8261
8262 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
8263
8264         * device/include/sdcc-lib.h: inserted LGPL, added includes
8265           asm/ds390/features.h and asm/mcs51/features.h
8266         * device/include/asm/default/features.h,
8267         * device/include/asm/gbz80/features.h,
8268         * device/include/asm/z80/features.h: added empty _AUTOMEM
8269           and _STATMEM
8270         * device/include/asm/ds390/features.h,
8271         * device/include/asm/mcs51/features.h: added files with defines for
8272           _AUTOMEM and _STATMEM indicating automatic and static storage class
8273         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
8274         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
8275         * src/SDCCicode.c (geniCodeCast),
8276         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
8277         * src/SDCCloop.c (loopInduction): removed unused variable lr
8278         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
8279           to convertToFcall to include char modulo (RFE 1065037), added check
8280           if left operand is unsigned and use abs of literal value
8281         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
8282           as it doesn't work after conversion from peephole.def to peephole.rul
8283         * src/mcs51/gen.c (toBoolean): added check for size,
8284           (genModOneByte): optimized code for signed char modulo a literal
8285           power of 2 (thanks to Hubert Sack),
8286           (genRRC): removed unnecessary "clr c",
8287           (genRLC): replaced "add a,acc" with cheaper "rlc a"
8288         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
8289           jump optimization,
8290           swapped rules 256.c and 256.d,
8291           extended 256.d by using new multiple checks (thanks Erik),
8292           added rules 256.e and 256.f,
8293           updated rule 261.a and 261.b to new generated code
8294         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
8295
8296 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8297
8298         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
8299           induction related bugs, including first part of bug #1074377
8300
8301 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
8302
8303         * applied patch from bug-report #1076292,
8304         * applied patches for genAnd and Goto-optimizations for Raphael
8305         Neider,
8306         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
8307         dump a less iCode information,
8308         * src/pic16/device.h (pic16_options_t): added field debgen,
8309         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
8310         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
8311         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
8312         puclic,
8313         * (various functions): added macros FENTRY and FENTRY2 to functions,
8314         to emit function prologue,
8315         * (various functions): fixed indentation,
8316         * (genNearPointerGet): fixed loading of FSR0,
8317         * (genPackBits): applied patch from Raphael Neider to fix updating
8318         of FSR0 and touching only the modified bits,
8319         * src/pic16/genarith.c (various functions): added macros FENTRY to
8320         emit function prologue in comments,
8321         * src/pic16/pcode.h: added functions debugf2, debugf3,
8322         * src/pic16/ralloc.c: partial fix for packForPush caused
8323         segmentation fault,
8324
8325 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8326
8327         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
8328           <stsp AT users.sourceforge.net> with reversed byte order
8329         * support/regression/tests/rotate.c: added (ds390 skips some tests)
8330
8331 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8332
8333         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
8334           bug #1074377
8335         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
8336         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
8337
8338 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
8339
8340         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
8341
8342 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8343
8344         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
8345           conditions,
8346           (setFromConditionArgs): friendly operand parser for peephole rules,
8347           (operandBaseName, operandsNotRelated): new peephole condition
8348           "operandsNotRelated" -- similar to "operandsNotSame", but takes
8349           architecture specific register naming into account, handles n-way
8350           comparisons, and supports quoted literals
8351         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
8352
8353 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8354
8355         * src/mcs51/peeph.def: fixed bug #1076940
8356
8357 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
8358
8359         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
8360
8361 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8362
8363         Adding support for replacing ljmps with sjmps in jumptables
8364         generated for switch statements. For now you need to set the
8365         environment variable SDCC_SJMP_JUMPTABLE to enable this.
8366         Now 4 algorithms for mcs51 jumptable generation are used:
8367         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
8368         addresses loaded pc-relative for up to 112 cases and stack-pushing
8369         target addresses loaded with offset from dptr for up to 256 cases.
8370
8371         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
8372         * src/mcs51/main.c: adapted constants for switch table generation
8373         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
8374
8375 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
8376
8377         * device/lib/printf_large.c (_print_format): fixed bug 1073386
8378         * support/regression/tests/bug1057979.c: added test for bug 1073386
8379
8380 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
8381
8382         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
8383         compilers
8384
8385 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
8386
8387         * src/pic16/device.h,
8388         * src/pic16/genarith.c,
8389         * src/pic16/glue.c,
8390         * src/pic16/main.c,
8391         * src/pic16/pcode.c: applied patches #1068154 and #1070213
8392
8393 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
8394
8395         Large cummulative patch for pic16 port.
8396         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
8397         to call when a stack overflow occurs,
8398         * (malloc.h): added CVS Id tag,
8399         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
8400         variable,
8401         * added libc directory. The current version of LibC contains string
8402         functions, ctype functions and macros and some functions of the
8403         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
8404         be extensively tested in the future. Standard disclaimer here.
8405         Library is not automatically build yet. But one can build it by
8406         invoking 'make' inside the libc directory.
8407         * added ADC library under libio. Preliminary version yet.
8408
8409         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
8410         * src/pic16/gen.c (aopForRemat): asmop size is filled by
8411         aopForRemat() now and not by pic16_aopOp(),
8412         * (pic16_popGetTempReg): removed warning messgae when allocating
8413         temporary registers, its a buggy feature and will be removed,
8414         * (pic16_popGet): set register instance field in AOP_CRY,
8415         * (pic16_outBitC): fixed for results in size greater than 1,
8416         * (genUminusFloat): fixed for pic16, ported code from mcs51,
8417         * (pic16_storeForReturn): optimized return of 0,
8418         * (genCmp): experimental code for new genCmp which uses PIC18's
8419         special compare&skip instructions. Initial tests fail some times
8420         with variables grater than 1 byte in size, so new code is disabled,
8421         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
8422         a single bit,
8423         * (genCast): began a fix to optimize the casting of a bit to another
8424         bit, now assigning a bitfield to another bitfield will fail, sorry,
8425         * src/pic16/main.c: disabled the use of lr-support feature,
8426         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
8427         * added some function prototypes, added function _debugf prototype,
8428         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
8429         bits with offset (case PO_GPR_BIT),
8430         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
8431         command line,
8432         * (isBankInstruction): modified to return 0 for no banking instruction,
8433         and 1 for banking instruction,
8434         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
8435         caused stop processing pCodes after a inline assembly block,
8436         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
8437         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
8438         registers when it shouldn't,
8439         * src/pic16/ralloc.c (allocReg): add preliminary support for
8440         supporting a limited set of temporary registers,
8441
8442 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8443
8444         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
8445           genDataPointerSet): ensure assignments always copy in MSB to LSB
8446           order,
8447           (loadRegFromAop): recognize CLRH optimization,
8448           (genFunction): optimize RECEIVE iCodes in reentrant functions
8449
8450 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8451
8452         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
8453           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
8454           selected.
8455         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
8456         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
8457           contiguous with data
8458
8459 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8460
8461         * device/lib/_gptrget.c (_gptrget),
8462         * device/lib/_gptrgetc.c (_gptrgetc),
8463         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
8464           instead of sjmp to ret
8465         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
8466           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
8467
8468 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
8469
8470         * .version: bumped version to 2.4.7
8471         * device/lib/_gptrget.c (_gptrget): is now _naked
8472         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
8473         * device/lib/_gptrput.c (_gptrput): is now _naked
8474         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
8475           (createFunction): fixed xstack
8476         * src/SDCCglue.c (emitMaps): set allocation required for bit area
8477         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
8478           or bit either,
8479           (geniCodeCritical): store original interrupt state in an iTemp bit
8480           var unless stack-auto
8481         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
8482         * src/SDCCmain.c (setIncludePath): added include/target to search path
8483         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
8484         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
8485           prototype,
8486           (processFuncArgs): put bit vars in bit area
8487         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
8488           unsaveRBank): fixed xstack,
8489           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
8490           (genFunction, genEndFunction): fixed xstack,
8491           (genAssign): optimization don't walk backwards through mem
8492         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
8493         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
8494         * support/regression/Makefile: also make library (for stack-auto) when
8495           making "all" and added "test-mcs51-xstack-auto"
8496         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
8497         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
8498         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
8499         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
8500         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
8501           make-library by MAKE_LIBRARY
8502         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
8503           regression tests for xstack
8504         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
8505         * support/regression/tests/critical.c: test for critical on mcs51
8506
8507 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8508
8509         * support/regression/ports/ucz80/spec.mk: use include and lib files from
8510           built version of sdcc instead of installed version
8511
8512 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
8513
8514         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
8515         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
8516           vprintf.c now
8517         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
8518         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
8519           WARNING: remove device/lib/build/z80/printf.o by hand when
8520           updating from previous build!
8521         * device/lib/z80/printf.c: updated comment
8522         * support/regression/tests/bug1057979.c: test all ports now
8523         * support/regression/tests/bug1065458.c: file added
8524
8525 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8526
8527         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
8528           *_start and *_end symbols for static functions
8529
8530 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
8531
8532         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
8533           and search crt0.o in all library paths,
8534           (setIncludePath): proper handling of --nostdinc,
8535           (setLibPath): proper handling of --nostdlib
8536         * support/regression/Makefile,
8537         * support/regression/ports/ds390/spec.mk,
8538         * support/regression/ports/gbz80/spec.mk,
8539         * support/regression/ports/hc08/spec.mk,
8540         * support/regression/ports/mcs51/spec.mk,
8541         * support/regression/ports/mcs51-large/spec.mk,
8542         * support/regression/ports/mcs51-stack-auto/spec.mk,
8543         * support/regression/ports/z80/spec.mk: use include and lib files from
8544           built version of sdcc instead of installed version
8545         * doc/sdccman.lyx: fixed typo in --nostdinc
8546
8547 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
8548
8549         * src/pic/pcode.c,
8550         * src/pic/device.c,
8551         * src/pic/ralloc.c,
8552         * src/pic/gen.c : added support to generate code for struct bit fields.
8553
8554 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
8555
8556         * as/xa51/xa_version.h,
8557         * device/include/errno.h,
8558         * device/include/regc515c.h,
8559         * device/lib/_itoa.c,
8560         * device/lib/_ltoa.c,
8561         * device/lib/ser_ir_cts_rts.c,
8562         * sim/ucsim/xa.src/glob.cc,
8563         * sim/ucsim/xa.src/inst_gen.cc,
8564         * sim/ucsim/xa.src/xa_bit.cc,
8565         * sim/ucsim/xa.src/xa_sfr.cc,
8566         * sim/ucsim/z80.src/inst_dd.cc,
8567         * sim/ucsim/z80.src/inst_fdcb.cc,
8568         * support/scripts/keil2sdcc.pl,
8569         * src/pic16/pic16.dsp,
8570         * src/pic16/pic16a.dsp: corrected cvs line endings
8571         * device/lib/printf_large.c: fixed bug 1057979
8572         * src/pic16/gen.c: fixed non-C standard code
8573         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
8574         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
8575         * support/regression/ports/mcs51/support.c: reload T1 asap
8576         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
8577           pdata use and clear idata startup behaviour
8578         * support/regression/tests/bug1057979.c: added
8579
8580 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
8581
8582         * device/examples/ds390/ow390/ad26.h,
8583         * device/examples/ds390/ow390/cnt1d.h,
8584         * device/examples/ds390/ow390/crcutil.c,
8585         * device/examples/ds390/ow390/ownet.h,
8586         * device/examples/ds390/ow390/owsesu.c,
8587         * device/examples/ds390/ow390/swt12.h,
8588         * device/examples/ds390/ow390/swtoper.c,
8589         * device/examples/ds390/ow390/temp10.h,
8590         * device/examples/ds390/ow390/thermodl.c,
8591         * device/examples/ds390/tinitalk/tinitalk.dsp,
8592         * device/examples/ds390/tinitalk/tinitalk.dsw,
8593         * device/examples/mcs51/clock/hw.h,
8594         * device/examples/mcs51/simple2/go.bat,
8595         * device/examples/serialcomm/windows/serial.h,
8596         * device/examples/xa51/dummy.c,
8597         * device/examples/xa51/hello.c,
8598         * device/include/80c51xa.h,
8599         * device/include/at89x051.h: corrected cvs line endings
8600
8601 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
8602
8603         * src/pic16/main.c (options): added command line --gstack, to trace
8604         stack over/under flows,
8605         * added pragma 'wparam' to allow passing first byte of function
8606         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
8607         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
8608         call to __gstack_test function and sets up the symbol as extern,
8609         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
8610         * popaop): added call to pic16_testStackOverflow,
8611         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
8612         wparamList list,
8613         * (genCall, genPcall): now all parameters are passed via stack
8614         except in functions that are pass to wparam pragma in which WREG is
8615         used too,
8616         * (genPcall): REENTRANT flag is checked to see if variable prototype
8617         contains reentrant keyword, don't call a non-reentrant function, via
8618         a reentrant function pointer or vice versa, functions are never
8619         passed via WREG,
8620         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
8621         D.Winkler,
8622         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
8623         SIGSEGV when accessing a NULL register stucture,
8624         * (pic16_printGPointerType): modified to handle UPPER modifier for
8625         function initializers, changed prototype of function to simpler one,
8626         * (pic16_printIvalFuncPtr): check to see if function is already
8627         added in externs list,
8628         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
8629         optimized a move from W to SFR with a move to the same register
8630         later after a CALL,
8631         * device/lib/pic16/debug: NEW directory, contains debug features
8632         which are enabled when linking with libdebug.lib, currently command
8633         line option --gstack enables stack pointer tracing for over/under
8634         flow, corresponding sources are in debug/gstack
8635
8636 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
8637
8638         * doc/sdccman.lyx: updated SDCC version,
8639         * (PIC16 port): update list of command line options,
8640         * src/pic16/device.h (structure pic16_options_t): added field gstack
8641         to enable stack overflow tracing on push/pops,
8642         * src/pic16/device.c (statistics structure): added statistics
8643         structure,
8644         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
8645         pic16_dump_int_registers): increase statistics counters for each
8646         * variable which is encountered
8647         * (pic16_dump_usection): emit each .udata variable to its own udata
8648         section,
8649         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
8650         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
8651         parameters via stack, otherwise use old scheme,
8652         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
8653         assembler output file,
8654         * src/pic16/main.c: added command line options --gstack to enable
8655         push/pop tracing for stack overflow,
8656         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
8657         instructions): added size of each instruction,
8658         * (pic16_countInstruction): estimate size of instructions in
8659         the_pFile list, inline assembly blocks are not counted,
8660         * (pic16_FixRegisterBanking): trace previous register usage, when
8661         banksel optimizations is greater than 0, don't emit a redudant
8662         banksel directive,
8663
8664 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
8665
8666         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
8667         * src/pic16/ralloc.c : applied same fix for pic16.
8668         * src/pic/gen.c : tidied it up a little.
8669
8670 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8671
8672         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
8673         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
8674
8675 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8676
8677         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
8678
8679 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8680
8681         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
8682         non-reentrant function __modsint in the interrupt function (thus
8683         corrupting math operations during serial I/O)
8684         * device/lib/ser_ir.c: as above, changed buffersize
8685         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
8686         256.c,d for zeroing
8687         * doc/Makefile: added option -t for rsync
8688
8689 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8690
8691         * src/SDCCast.h (struct ast),
8692         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
8693
8694 2004-10-20 Borut Razem <borut.razem AT siol.net>
8695
8696         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
8697         package
8698
8699 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
8700
8701         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
8702         makefile targets,
8703         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
8704         support functions to replace long sequences of MOVFF's from access
8705         bank registers to stack and vice versa,
8706         * src/pic16/device.h: added new field opt_flags, where optimization
8707         flags can be set to enable certain features,
8708         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
8709         * pBlock, (genFunction, genEndFunction): surroung loop for
8710         saving/loading used registers in stack with PC_INFO pCodes,
8711         INF_LREGS. Code in between can then be optimized by pCode optimizer
8712         to support function calls,
8713         * (genDataPointerSet): fixed bug which loaded float fields in
8714         structures with corrupt data,
8715         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
8716         in a standard way debug info on stderr. Feature used for developing
8717         and debugging only,
8718         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
8719         obsolete chunks of code,
8720         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
8721         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
8722         * pic16/src/pcode.c (pic16_newpCodeInfo,
8723         * (pic16_newpCodeOpLocalRegs),
8724         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
8725         feature,
8726         * (pic16_pCodeConstString): printing of the initial value of a
8727         symbol as a comment is inhibited since parsing was already done by
8728         copyStr and output is corrupt,
8729         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
8730
8731 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8732
8733         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
8734
8735 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
8736
8737         * as/mcs51/lkarea.c: removed old K&R style,
8738           (lnksect): changed check on boundary error,
8739           (lnksect2): changed check on boundary error,
8740           (lnksect2): extend XSTK to end of page if size = 1
8741         * as/mcs51/lkmain.c: removed old K&R style,
8742           (Areas51): create l_IRAM symbol
8743         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
8744         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
8745           model-mcs51-stack-auto, added model-mcs51-xstack-auto
8746         * device/lib/_mullong.c: added version to be compiled with xstack
8747         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
8748         * device/lib/mcs51/crtxclear.asm: clear pdata as well
8749         * device/lib/mcs51/crtxstack.asm: fixed comment
8750         * src/SDCCglue.c: maxInterrupts defaults to 0,
8751           (emitMaps): added pdata,
8752           (createInterruptVect): (re)moved default,
8753           (glue): added pdata,
8754           (glue): moved __start__xstack to XSTK with default size 1
8755         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
8756           and options.float_rent when options.stackAuto is set,
8757           (linkEdit): only write XDATA_NAME if provided on command line
8758         * src/SDCCmem.h,
8759         * src/SDCCmem.c: added pdata
8760         * src/port.h: added pdata_name to PORT
8761         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
8762           (saveRegisters, unsaveRegisters): removed usage of B,
8763           (genMinus): fixed accumulator clash,
8764           (genJumpTab): added comment, this needs another look
8765         * src/mcs51/gen.c: added check for "B in use" paranoia,
8766           added pushB() and popB()
8767         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
8768           chance
8769         * src/avr/main.c,
8770         * src/ds390/main.c,
8771         * src/hc08/main.c,
8772         * src/mcs51/main.c,
8773         * src/pic/main.c,
8774         * src/pic16/main.c,
8775         * src/xa51/main.c,
8776         * src/z80/main.c: (reset_regparms) made void parameter explicit and
8777           added PSEG (PAG,XDATA) or NULL to port specifier
8778         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
8779         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
8780           (_mcs51_genInitStartup): removed __start__xstack equ,
8781           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
8782         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
8783         * src/z80/gen.c (_rleAppend): fixed warnings
8784         * support/regression/tests/zeropad.c: added pdata test
8785         * .version: bumped to 2.4.6
8786
8787 2004-10-17 Borut Razem <borut.razem AT siol.net>
8788
8789         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
8790         as a part of nightly build
8791
8792 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
8793
8794         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
8795         WREG holds the first byte function parameters,
8796         * (aopForSym): take special case for symbols which are in FARSPACE
8797         but in CODESPACE too,
8798         * (assignResultValue): modified to take into account _G.useWreg,
8799         * (genCall): don't use wreg for parameter passing when function is
8800         declared as reentrant, too, added optimization INCF to stack
8801         pointer when stack parameter count is 1,
8802         * (genFunction, genEndFunction): refurnished and fixed to not using
8803         wreg for passing parameters when function has varargs or is
8804         reentrant, fixed bug with symbol name compare for generating
8805         functions in absolute address,
8806         * (pic16_storeForReturn): refurnished,
8807         * (genCmp): began writing a new version of the function, not ready
8808         yet, therefore it is disabled,
8809         * (genAssign): do not read code memory when assigning a function to
8810         a pointer function,
8811         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
8812         array of characters, not pointer,
8813         * (pic16initialComments): in debug mode emit an .ident directive for
8814         the assembler,
8815         * (_process_pragma): emit a new warning type (internal to pic16)
8816         when setting stack to default length, emit a similar warning when
8817         placing a function at absolute address and address is not word aligned
8818         * (_pic16_parseOptions): added 'return TRUE' statement,
8819         * (_pic16_linkEdit): if compiling a source, then add the source's
8820         file object, first in the list of objects to link,
8821
8822 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
8823
8824         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
8825         * src/pic/main.c : removed VC warning.
8826         * src/pic/gen.c : changed comment.
8827
8828 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
8829
8830         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
8831         reference to a deprecated symbol _GPTRREG was causing failure to
8832         link. Thanks G. M. Gallant for the info.
8833
8834 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
8835
8836         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
8837         comments for Bugs item #954788.
8838
8839 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
8840
8841         * src/pic16/device.c (pic16_dump_gsection,
8842         * pic16_groupRegistersInSection): handle symbols declared to be in
8843         access bank differently,
8844         * src/pic16/gen.c (struct _G): added field resDirect,
8845         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
8846         send values read from stack directly to result and don't allocate
8847         temporary values,
8848         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
8849         same registers,
8850         * (pic16_sameRegsOfs): NEW,
8851         * (freeAsmop): if _G.resDirect is set then do not mark registers as
8852         free because they were not allocated from temporary pool,
8853         * pic16_popRegFromString): workaround to fix a problem with
8854         allocating variables twice or never,
8855         * (genGenPointerGet): using PRODL instead of FSR0H,
8856         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
8857         instead of FSR0H,
8858         * (genAssign): take advantage of the _G.resDirect flag,
8859         * (genCast): around line 11844, use mov2f instead of directly
8860         MOVFF'ing between operands to account for literal values,
8861         * src/pic16/genutils.c: some new debug functions for gpsim have been
8862         added,
8863         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
8864         float with integer part only,
8865         * src/pic16/main.c (_process_pragma): handle pragma udata access to
8866         place variables in access bank
8867         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
8868         updated sources to reflect recent changes in gen.c
8869
8870 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
8871
8872         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
8873         sources that searched for headers in installation path, now the
8874         device/include/pic16 is used,
8875         * src/pic16/glue.c (pic16glue),
8876         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
8877         .line directives if not in debug mode, this suppresses assembler's
8878         warnings for ignored directives
8879
8880 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
8881
8882         * src/port.h: made reset_regparms prototype void parameter explicit.
8883         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
8884         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
8885         * doc/sdccman.lyx: documented warning disabling and how to use
8886           printf_large to make it print floats.
8887         * device/include/stdbool.h: NEW
8888         * device/lib/_atof.c,
8889         * device/lib/_divuint.c,
8890         * device/lib/_divulong.c,
8891         * device/lib/expf.c,
8892         * device/lib/printf_large.c,
8893         * device/lib/sincosf.c,
8894         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
8895         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
8896           a completely reentrant lib.
8897
8898 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
8899
8900         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
8901         * device/include/pic16/stdio.h: fixed bug with colon
8902
8903 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
8904
8905         * device/include/pic16/stdio.h,
8906         * device/include/pic16/stdlib.h,
8907         * device/include/pic16/math.h: NEW
8908         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
8909         declared as _naked to reduce overhead
8910         * device/lib/Makefile.in (target port-specific-objects-pic16):
8911         changed * to *.* so to ignore the CVS directory,
8912         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
8913         stacked variables back in stack,
8914         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
8915         corruption
8916
8917 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
8918
8919         * .version: bumped version number to 2.4.5
8920         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
8921         * support/Util/SDCCerr.c (messages structure): added entry for
8922         W_POSSBUG2
8923
8924         Large cumulative patch for pic16 port and libraries.
8925         * device/include/pic16/sdcc-lib.h,
8926         * device/include/pic16/stdarg.h,
8927         * device/include/asm/pic16/features.h,
8928         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
8929         * device/include/pic16/float.h: changes reentrant keyword with
8930         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
8931         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
8932         updated target build-libraries to include objects from gptr,
8933         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
8934         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
8935         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
8936         all function headings,
8937         * src/SDCCmain.c: added global parameter userIncDirsSet,
8938         * (parseCmdLine): when option -I is encountered add directory to
8939         userIncDirsSet too,
8940         * src/version.awk: added space between control and long,
8941         * src/pic16/NOTES: added some notes for the port,
8942         * src/pic16/gen.c: added prototype for mov2fp function,
8943         * (fReturnpic16[]): properly named return value registers,
8944         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
8945         * (aopForSym): added code to handle symbols with onStack flag set,
8946         symbols onStack are allocated PTRSIZE bytes,
8947         * (aopFreeAsmop): handles special case where asmops are stack objects,
8948         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
8949         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
8950         added argument lock to trace flaws in allocating temporary registers
8951         when developing port,
8952         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
8953         * (pic16_popRegFromString): reenabled allocating a direct register
8954         from string,
8955         * (assignResultValue): various beautifications,
8956         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
8957         referenced function argument,
8958         * (genIpush): reenabled to allow stacked arguments, handles only
8959         ic->parmPush iCodes,
8960         * (genCall, genPcall): major changes to allow for variable argument
8961         functions, fixed a bug with falsely restoring stack pointer after
8962         returning from call,
8963         * (genFunction): pending code for critical function,
8964         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
8965         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
8966         * (genNearPointerGet): fixed bug with indirect reading, was always
8967         reading from INDF0
8968         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
8969         pointers,
8970         * (genAddrOf): rewrote code to take address of a stacked function parameter
8971         * (genCast): fixed casting to generic pointer type,
8972         * src/pic16/gen.h: added AOP_STA,
8973         * (struct asmop): added field stk,
8974         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
8975         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
8976         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
8977         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
8978         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
8979         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
8980         generic pointers,
8981         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
8982         and library paths,
8983         * (pic16_port structure): generic pointer size is set to 3,
8984         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
8985         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
8986         compiler warning,
8987         * src/pic16/ralloc.c (allocReg): prevent allocating register when
8988         operand is an iTemp,
8989
8990 2004-09-24 Martin Helmling <mh AT octo-soft.de>
8991
8992         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
8993         * debugger/mcs51/simi.c: addapt new syntax of s51
8994
8995 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
8996
8997         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
8998         * src/pic16/pcode.c: commented out some calls to free() in order to
8999         fix bug #989576,
9000
9001 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9002
9003         * src/SDCCicode.h,
9004         * src/SDCCicode.c (isiCodeInFunctionCall),
9005         * src/avr/ralloc.c (selectSpil),
9006         * src/pic/ralloc.c (selectSpil),
9007         * src/pic16/ralloc.c (selectSpil),
9008         * src/ds390/ralloc.c (selectSpil),
9009         * src/hc08/ralloc.c (selectSpil),
9010         * src/xa51/ralloc.c (selectSpil),
9011         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
9012         stack in the middle of a function call sequence (fixes bug #1020268)
9013         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
9014         costs associated with the minimum switch case.
9015
9016 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9017
9018         * src/SDCC.lex: fixed bug #1030549
9019
9020 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9021
9022         * src/SDCCcse.h (struct cseDef),
9023         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
9024         over a function call if the CSE is derived from a symbol whose
9025         address has been taken (fixes bug #1029883)
9026         * support/regression/tests/bug-1029883: a new regression test for
9027         this bug
9028
9029 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9030
9031         * src/hc08/gen.c (emitinline): fixed bug #1029778
9032         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
9033         to a cast object is no longer a syntax error ("fixes" bug #1030006,
9034         and starts toward RFE #905167)
9035
9036 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
9037
9038         * src/pic16/gen.c (mov2f): New function to move an operand to
9039         another without considering if it is a literal or a register,
9040         * (pic16_sameRegs): don't check if they are both AOP_REG,
9041         * (AccRsh): removed andmask=0 lines,
9042         * (genLeftShift): duplicated to be improved in future versions,
9043         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
9044         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
9045         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
9046         * (pic16initMnemonics): added initialization for POC_INFSNZW,
9047         * (insertBankSwitch): fixed inserting banksel directives algorithm
9048         for instructions that follow a skip instruction, this fixes a report
9049         for broken subtraction code generation,
9050         * src/pic16/ralloc.c (deassignLRs): do not free register if current
9051         iCode is a left op, just in case result and right share the same
9052         registers
9053
9054 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9055
9056         * src/hc08/main.c,
9057         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
9058         preservation of HX
9059         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
9060         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
9061         on 2004-09-12; it was buggy
9062
9063 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
9064
9065         * src/SDCCsymt.h: removed RESULT_CHECK
9066         * src/SDCCast.c,
9067         * src/SDCCglue.c,
9068         * src/SDCCval.c,
9069         * src/pic/glue.c,
9070         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
9071
9072 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
9073
9074         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
9075         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
9076         configuration values no more rejected by compiler, they are assigned
9077         to configuration registers with a warning message instead,
9078         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
9079         the for-loop so last conf register is emitted too,
9080         * (_pic16_initPaths): link library libsdcc.lib by default,
9081         * (_hasNativeMulFor): modified test for multiplication according to
9082         Raphael Neider's remarks. Integer multiplication is also done with
9083         support functions,
9084         * device/include/pic16/pic18fregs.h: corrected type error in while
9085         testing and including 18f6720 header file
9086
9087 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
9088
9089         * src/pic16/device.h (pic16_options): removed field use_crt,
9090         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
9091         until an optimization to handle single bits is added,
9092         * (pic16_loadFSR0): moved before genUnpackBits,
9093         * (genAnd): some white lines removed,
9094         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
9095         leave_reset flags in pic16_options when using crt modules,
9096
9097 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
9098
9099         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
9100           for bugs 898889 & 979599. Also used some safer print instructions.
9101
9102 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
9103
9104         * src/pic16/device.h (pic16_options_t): added field use_crt,
9105         crt_name, no_crt,
9106         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
9107         catch a probable future bug,
9108         * src/pic16/gen.c: aopIdx function commented out,
9109         * (genAssign): commented out old code which used aopIdx,
9110         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
9111         code, added if conditionals to take into account the --use-crt
9112         command line options,
9113         * src/pic16/main.c (pic16_optionsTable): added new command line
9114         options, --use-crt= and --no-crt,
9115         * (_pic16_linkEdit): now the proper crt object is added in the
9116         linker command line except than when --no-crt is specified,
9117         * src/pic16/pcode.c,
9118         * src/pic16/pcode.h: added some structures and functions for a new
9119         optimization scheme to compansate for instruction overhead between
9120         same iCodes, this scheme is currently under development and is not
9121         working in any way,
9122         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
9123         to && operator,
9124         * device/lib/pic16/startup/crt0i.c,
9125         * device/lib/pic16/startup/crt0iz.c: added global char variable
9126         __uflags to force the generation of an idata section
9127
9128 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
9129
9130         * doc/Makefile,
9131         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
9132         * doc/sdccman.lyx: updated sdcc version to 2.4.4
9133
9134 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9135
9136         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
9137         Frieder) and clarified the default code optimization mode
9138
9139 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9140
9141         * src/SDCC.lex (doPragma, process_pragma),
9142         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
9143         "opt_code_size", and "opt_code_balanced"
9144         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
9145         regrouped options by category, added support for category headers
9146         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
9147         and "--opt-code-size"
9148         * doc/sdccman.lyx: documented these new options and pragmas
9149         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
9150         preference into account
9151
9152 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
9153
9154         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
9155           geniCodePreDec): Fixed bug 904237 by generating a warning
9156         * src/SDCCerr.h,
9157         * src/SDCCerr.c: added warning W_SIZEOF_VOID
9158
9159 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
9160
9161         * src/pic/device.c : When no max ram set validate full memory range.
9162         * src/pic/pcode.c,
9163         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
9164
9165 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
9166
9167         * device/lib/_gptrget.c,
9168         * device/lib/_gptrput.c: updated comment
9169         * device/lib/calloc.c,
9170         * device/lib/free.c,
9171         * device/lib/malloc.c,
9172         * device/lib/realloc.c: added LGPL, made them reentrant-safe
9173         * src/SDCCcse.c (cseBBlock),
9174         * src/SDCCicode.c (printOperand, geniCodeArray),
9175         * src/SDCCicode.h (struct operand): fixed bug 868103
9176         * support/regression/tests/bug-868103.c: added
9177         * src/SDCCast.c (searchLitOp),
9178         * src/SDCCcse.h (struct cseDef),
9179         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
9180         * src/SDCCicode.h (struct operand),
9181         * src/SDCCsymt.h (struct sym_link),
9182         * src/avr/gen.c (hasInc),
9183         * src/ds390/gen.c (hasInc),
9184         * src/hc08/gen.c (genPlusIncr, hasInc),
9185         * src/mcs51/gen.c (hasInc),
9186         * src/pic16/glue.c (pic16_printIvalChar),
9187         * src/pic16/ralloc.c (regWithIdx),
9188         * src/xa51/gen.c (hasInc) : removed warnings
9189         * src/SDCCast.c (createBlock): added comment ???
9190         * src/hc08/ralloc.c: updated comments
9191
9192 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9193
9194         * doc/sdccman.lyx: updated section on switch statements, added
9195         section about semaphore locking
9196         * doc/Makefile: added option -info for latex2html
9197         * device/lib/_gptrget.c,
9198         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
9199
9200 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
9201
9202         * src/pic/device.h,
9203         * src/pic/device.c,
9204         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
9205          maxram is less than 0x100.
9206
9207 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
9208
9209         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
9210
9211 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9212
9213         * src/port.h,
9214         * src/mcs51/main.c,
9215         * src/ds390/main.c,
9216         * src/z80/main.c,
9217         * src/hc08/main.c,
9218         * src/pic/main.c,
9219         * src/pic16/main.c,
9220         * src/avr/main.c,
9221         * src/xa51/main.c
9222         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
9223         a jump table is the best form for a switch statement, including
9224         automatic insertion of missing cases to make the case range
9225         continuous. Developed in collaboration with Frieder Ferlemann.
9226
9227 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9228
9229         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
9230         accumulator result if it needs sign extension
9231
9232 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
9233
9234         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
9235
9236 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
9237
9238         * device/lib/gbz80/printf.c,
9239         * device/lib/z80/printf.c: removed define for NULL
9240
9241 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
9242
9243         * as/xa51/xa_link.c,
9244         * device/examples/ds390/ow390/ad26.c,
9245         * device/examples/ds390/ow390/cnt1d.c,
9246         * device/examples/ds390/ow390/counter.c,
9247         * device/examples/ds390/ow390/ds2480.h,
9248         * device/examples/ds390/ow390/ds2480ut.c,
9249         * device/examples/ds390/ow390/findtype.c,
9250         * device/examples/ds390/ow390/gethumd.c,
9251         * device/examples/ds390/ow390/owllu.c,
9252         * device/examples/ds390/ow390/ownetu.c,
9253         * device/examples/ds390/ow390/swt12.c,
9254         * device/examples/ds390/ow390/swtloop.c,
9255         * device/examples/ds390/ow390/temp.c,
9256         * device/examples/ds390/ow390/temp10.c,
9257         * device/examples/ds390/ow390/thermo21.c,
9258         * device/examples/ds390/ow390/tinilnk.c,
9259         * device/examples/ds390/ow390/tstfind.c,
9260         * device/examples/serialcomm/windows/serial.cpp,
9261         * device/examples/serialcomm/windows/test_serialcomm.cpp,
9262         * device/include/reg51.h: fixed line endings for cvs
9263
9264 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9265
9266         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
9267         packRegsForAccUse, packRegisters): new accumulator register
9268         packing algorithm
9269         * support/regression/ports/hc08/support.c (_putchar): suppress
9270         warning of unused variable
9271         * src/SDCCicode.c: added SWAP entry to codeTable
9272
9273 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
9274
9275         * device/lib/sprintf.c: forgot to add this file before previous commit
9276
9277 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
9278
9279         * src/pic16/gen.c (genPackBits): added operand right in function
9280         parameters, load result directly if p_type is POINTER (that is
9281         called by genNearPointerSet)
9282         * (genUnPackBits): added operand left in function parameters,
9283         * (genNearPointerGet, genNearPointerSet): prevent the loading of
9284         FSR0 if accessing bitfields,
9285
9286 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
9287
9288         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
9289           _print_format; updated printf, sprintf, vsprintf
9290         * device/include/asm/default/features.h: corrected comment/define
9291         * device/lib/Makefile.in: added sprintf.c
9292         * device/lib/libsdcc.lib: added sprintf module
9293         * device/lib/printf_large.c,
9294         * device/lib/vprintf.c,
9295         * device/lib/sprintf.c: totally refactored printf_large and vprintf
9296           into these 3 files
9297         * support/regression/Makefile: changed ALL_PORTS into a usefull default
9298         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
9299         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
9300           hc08 test
9301         * support/regression/tests/zeropad.c: define idata as data for hc08
9302
9303 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9304
9305         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
9306         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
9307         labels are referenced at least once (even if a reference is not found)
9308         * src/hc08/gen.c (emitcode): set isComment flag for comments
9309         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
9310         loads), rules 6a..6b (optimize jumps to return)
9311
9312 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9313
9314         * device/lib/acosf.c (acosf),
9315         * device/lib/asinf.c (asinf),
9316         * device/lib/atanf.c (atanf),
9317         * device/lib/ceilf.c (ceilf),
9318         * device/lib/cosf.c (cosf),
9319         * device/lib/coshf.c (coshf),
9320         * device/lib/cotf.c (cotf),
9321         * device/lib/fabsf.c (fabsf),
9322         * device/lib/floorf.c (floorf),
9323         * device/lib/log10f.c (log10f),
9324         * device/lib/logf.c (logf),
9325         * device/lib/sinf.c (sinf),
9326         * device/lib/sinhf.c (sinhf),
9327         * device/lib/sqrtf.c (sqrtf),
9328         * device/lib/tanf.c (tanf),
9329         * device/lib/tanhf.c (tanhf),
9330         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
9331         replaced all instances of "reentrant" in the library functions
9332         defined in math.h with this macro.
9333         * support/regression/tests/float_trans.c: reenabled test for hc08
9334
9335 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
9336
9337         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
9338         erroneously deleted
9339
9340 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9341
9342         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
9343         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
9344         multi-byte volatile operands are used
9345         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
9346         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
9347         initialization to area GSINIT0 so that it would always precede
9348         any static initializers in GSINIT
9349         * support/regression/tests/zeropad.c: fixed idata define for hc08
9350         * support/regression/tests/bug-927659.c,
9351         * support/regression/tests/float_trans.c: disabled tests for hc08
9352         pending missing library routines
9353         * .version: increased version number to 2.4.4 - hc08 port now passes
9354         regression tests
9355
9356
9357 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
9358
9359         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
9360         * Makefile.common.in,
9361         * as/Makefile,
9362         * as/hc08/Makefile.in,
9363         * as/mcs51/Makefile.in,
9364         * as/z80/Makefile.in,
9365         * debugger/mcs51/Makefile.in,
9366         * device/include/Makefile.in,
9367         * device/lib/Makefile.in,
9368         * doc/Makefile,
9369         * link/Makefile,
9370         * link/z80/Makefile.in,
9371         * packihx/Makefile.in,
9372         * sim/ucsim/main_in.mk,
9373         * sim/ucsim/avr.src/Makefile.in,
9374         * sim/ucsim/doc/Makefile.in,
9375         * sim/ucsim/gui.src/serio.src/Makefile.in,
9376         * sim/ucsim/hc08.src/Makefile.in,
9377         * sim/ucsim/s51.src/Makefile.in,
9378         * sim/ucsim/xa.src/Makefile.in,
9379         * sim/ucsim/z80.src/Makefile.in,
9380         * src/Makefile.in,
9381         * support/cpp2/Makefile.in,
9382         * support/librarian/Makefile,
9383         * support/makebin/Makefile: added DESTDIR to the install path proposed
9384         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
9385         * doc/sdccman.lyx: added DESTDIR documentation
9386
9387 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
9388
9389         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
9390         instruction for interrupt handlers, use fast returns when returning
9391         from high priority interrupts
9392
9393 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9394
9395         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
9396         code generation
9397         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
9398         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
9399         bugs, ported much of Bernhard's code from mcs51
9400         * src/mcs51/gen.c (genSend),
9401         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
9402         than one when calling a reentrant function
9403         * device/lib/_mullong.c: defined an alternate struct layout for big
9404         endian ports (hc08)
9405
9406 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9407
9408         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
9409         test
9410
9411 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9412
9413         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
9414         are sane and complete before asking the port its prefered parameter
9415         passing method (fixes bug #1017633)
9416         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
9417         and _ret3
9418
9419 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9420
9421         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
9422         problem in bitfields >= 8 bits.
9423
9424 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
9425
9426         * src/SDCCsymt.c: undid changes that were not meant to be committed
9427
9428 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
9429
9430         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
9431
9432 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
9433
9434         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
9435           copied and wrong bit got inverted
9436
9437 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9438
9439         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
9440         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
9441         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
9442         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
9443         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
9444         assignments to bitfields at known addresses
9445         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
9446         reads from bitfields at known addresses
9447         * src/hc08/ralloc.c (packRegisters),
9448         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
9449         genhc08Code): optimize pointer get values used as conditionals
9450         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
9451         and branch
9452
9453 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9454
9455         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
9456         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
9457         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
9458         as conditionals
9459
9460 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9461
9462         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
9463
9464 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9465
9466         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
9467         related problems
9468
9469 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
9470
9471         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
9472
9473 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9474
9475         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
9476         mcs51 port
9477
9478 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
9479
9480         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
9481
9482 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9483
9484         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
9485         cases use more compact code.
9486
9487 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
9488
9489         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
9490
9491 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9492
9493         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
9494
9495 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9496
9497         * src/SDCCsymt.h,
9498         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
9499         parameter of changePointer() from symbol* to sym_link*
9500         * src/SDCCast.c (decorateType): call changePointer() for CAST op
9501         * src/SDCCsymt.c (compareType): void* type is castable to other
9502         pointers, but not necesarily an exact match.
9503         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
9504         is no longer blindly treated as an exact match.
9505         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
9506
9507 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
9508
9509         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
9510
9511 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
9512
9513         * src/pic/gen.c,
9514         * src/pic/pcode.c,
9515         * src/pic/ralloc.h,
9516         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
9517
9518 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
9519
9520         * src/pic/device.c,
9521         * src/pic/device.h,
9522         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
9523
9524 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9525
9526         * src/mcs51/gen.c (emitcode): fixed bug #992819
9527
9528 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
9529
9530         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
9531           there's no need to make it worse
9532
9533 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9534
9535         * src/mcs51/ralloc.c (deassignLR),
9536         * src/ds390/ralloc.c (deassignLR),
9537         * src/hc08/ralloc.c (deassignLR),
9538         * src/z80/ralloc.c (deassignLR),
9539         * src/pic/ralloc.c (deassignLR),
9540         * src/pic16/ralloc.c (deassignLR),
9541         * src/avr/ralloc.c (deassignLR),
9542         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
9543         rlivePoint): fixed another part of bug #971834
9544
9545 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9546
9547         * src/z80/main.c: enabled "critical" keyword
9548         * src/z80/mappings.i,
9549         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
9550         functions (fixes bug #979646)
9551         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
9552
9553 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9554
9555         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
9556           such as c:\mydir.
9557
9558 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
9559
9560         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
9561           doesn't disable too much optimizations
9562
9563 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
9564
9565         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
9566
9567 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
9568
9569         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
9570
9571 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
9572
9573         * src/pic/gen.c tidied up tabs
9574         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
9575         * src/pic/main.c tidied up tabs
9576         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
9577         * src/pic/pcoderegs.c tidied up tabs
9578         * src/pic/ralloc.c tidied up tabs
9579
9580 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
9581
9582         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
9583         to S_FIXED for pic16 port and when symbol is not in level 0,
9584         allocate for S_REGISTER storage class and pic16 port, too,
9585         * src/pic16/device.h: prototype for checkSym,
9586         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
9587         * (pic16_assignConfigWordValue): test the value and the mask to
9588         validate that the value is suitable for the configuration word,
9589         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
9590         collect extern declared symbols, don't emit symbol twice, check
9591         first if symbol is in publics set first,
9592         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
9593         * added command line '--fstack' which enables an experimental
9594         feature for stack access, too buggy to be used yet...
9595         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
9596         * (pic16_allocDirReg): when register has storage class S_REGISTER
9597         allocate in pic16_dynAccessRegs,
9598         * device/include/pic16/pic18f????.h: modified configuration word
9599         naming convention, words started as CONFIG0H but should be CONFIG1H
9600
9601 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
9602
9603         * device/include/mcs51reg.h: fixed bug 970993
9604
9605 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
9606
9607         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
9608         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
9609         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
9610         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
9611         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
9612         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
9613           error/warning numbers,
9614           added function setWarningDisabled()
9615         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
9616         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
9617           _memcmp.c _memmove.c calloc.c realloc.c free.c
9618         * support/regression/tests/malloc.c: added tests for new functionality
9619         * support/regression/tests/zeropad.c: added tests for truncated initializers
9620           and initialized char arrays starting with '\x0'
9621         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
9622
9623 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
9624
9625         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
9626
9627 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9628
9629         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
9630         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
9631         peephole 177.e. Thanks to anonymous
9632
9633 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
9634
9635         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
9636         function isn't used in the source but referenced as a
9637         variable initializer then declare it as extern in .asm file
9638
9639 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
9640
9641         * .version: increased version number to 2.4.3
9642
9643         Adding version extension according to ChangeLog CVS revision
9644         * src/Makefile.in (target all): added dependency 'version.h'
9645         * (rule version.h): added rule to create version.h from ChangeLog,
9646         * (rule dep): added dependency version.h,
9647         * src/version.awk: AWK script to create version.h
9648         * src/SDCCdwarf2.c (dwWriteModule),
9649         * src/SDCCglue.c (initialComments),
9650         * src/SDCCmain.c (printVersionInfo): modified to write after
9651         version string the version extension number,
9652         * src/SDCCutil.c: included "version.h"
9653         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
9654         number,
9655         * src/SDCCutil.h: added prototype for getBuildNumber
9656
9657         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
9658         includeDirsSet, too,
9659         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
9660         const char [] is found in function prototype...
9661
9662         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
9663         moving to WREG with source is already in WREG,
9664         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
9665         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
9666         * (aopForSym): stack'ed symbols are partially supported, added
9667         if-clause to support symbols in FARSPACE,
9668         * (sameRegs): added test for AOP_ACC to see if registers are same,
9669         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
9670         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
9671         * (pic16_popRegFromString): will not allocate a new register if it
9672         doesn't find one by name, bug may have introduced...
9673         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
9674         * (genIpush): revived to use pic16 port's stack,
9675         * (genAddrOf): added incomplete case for stack'ed operand,
9676         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
9677         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
9678         can handle multibyte operands,
9679         * src/pic16/glue.c (pic16_printIval*): some debug info added,
9680         * (pic16initialComments): added message for MPLAB compatibility
9681         mode enabled,
9682         * src/pic16/main.h: prototype for pic16_mplab_comp,
9683         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
9684         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
9685         * (_pic16_linkEdit): NEW, handles link stage, transferred here
9686         because of increased complexity of procedure,
9687         * (_process_pragma): stack pragma changed to format 'stack pos len',
9688         emit symbol '_stack_end' to conform with gplink,
9689         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
9690         to search for register,
9691         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
9692         PO_GPR_REGISTER,
9693         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
9694         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
9695         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
9696         case for PO_GPR_REGISTER,
9697         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
9698         dies, the new era is ahead !...
9699         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
9700         pic16_dynInternalRegs,
9701         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
9702         * (pic16_allocDirReg): minor optimizations and bug fixes,
9703         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
9704
9705         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
9706         load stack and frame pointer with address of 'stack_end' symbol
9707
9708 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
9709
9710         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
9711         without source code but only variable initializers
9712
9713 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
9714
9715         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
9716         external are not declared as extern to reduce overhead while linking
9717
9718 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
9719
9720         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
9721
9722 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
9723
9724         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
9725           Yee Keat for the patch
9726         * src/SDCCast.c (decorateType): fixed bug #979599
9727         * src/ds390/gen.h: removed local fReturnSizeDS390
9728         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
9729         * src/ds390/gen.c (genAnd, genOr, genXor),
9730         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
9731
9732 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
9733
9734         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
9735         add relFilesSet to $3, manipulate $2 to handle linking of object
9736         files without source files in command line,
9737         * device/include/pic16 (all headers): added ID location macros,
9738         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
9739         entries for ID location bytes,
9740         * (pic16_assignIdByteValue): NEW,
9741         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
9742         added field dumpcalltree to pic16_options_t,
9743         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
9744         is used instead of pic16_Gstack_base_addr, check if (ifx) before
9745         emitting rFalseIfx label after check_carry label,
9746         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
9747         pic16_emitDIRegs), NEW
9748         * (pic16glue): dump .calltree file when option --calltree found,
9749         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
9750         * (_pic16_genAssemblerPreamble): emit ID locations after
9751         configuration registers,
9752         * (pic16_linkCmd): modifications of the link command,
9753         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
9754         * (pic16_pCodeInitRegisters): don't init stack registers,
9755         * (pic16_findPrevInstruction): fixed bug,
9756         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
9757         bug with immediate registers,
9758         * (buildCallTree): traces stack push and pop,
9759         * (pct2): dump also stack usage for each function,
9760         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
9761         * (pic16_allocDirReg): various modifications,
9762         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
9763         fixed to 1,
9764
9765 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
9766
9767         * src/pic16/pcode.c: removed buggy double colon
9768
9769 2004-07-01 Borut Razem <borut.razem AT siol.net>
9770
9771         * support/scripts/sdcc.nsi: added include/pic16 to setup
9772
9773 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
9774
9775         * device/lib/Makefile.in: fixed bug in target objects-pic16,
9776         * device/lib/pic16/Makefile: prefixed with dash (-) command under
9777         target 'clean',
9778         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
9779         specific command line arguments. Also added sample lkr script
9780         for placing a variable at a specific memory bank.
9781         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
9782         at a specific memory bank,
9783         * (pic16_dump_isection): fixed bug which caused string literals to
9784         be omitted when dumping idata section,
9785         * (pic16_groupRegistersInSection): added code to handle registers
9786         in specific memory banks,
9787         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
9788         public, all references are renamed too,
9789         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
9790         AOP_DPTR2,
9791         * (pic16_storeForReturn): added case to handle when dest is WREG,
9792         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
9793         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
9794         pic16_rel_udata, check to see if that register is marked as being
9795         a member of a specific memory bank,
9796         * (pic16_printIvalCharPtr): added code to add string literals either
9797         to code or the idata sections,
9798         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
9799         also accept the 'udata' pragma,
9800         * src/pic16/main.h: new structure types sectName and sectSym
9801         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
9802         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
9803         * (pic16_findPrevInstruction): fixed, it returned nothing,
9804         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
9805         instruction combinations,
9806         * (pic16_FixRegisterBanking): heavily reorganised,
9807         * (pic16_AnalyzeBanking): if generating banksel directives is
9808         disabled, then don't call FixRegisterBanking at all,
9809         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
9810         completely removed,
9811         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
9812
9813 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
9814
9815         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
9816         Phuah Yee Keat <yk.phuah AT nestac.com>
9817
9818 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
9819
9820         * src/pic16/glue.c (pic16createInterruptVect): function now emits
9821         correctly the IVT even if it is relocated to some other location
9822
9823 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
9824
9825         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
9826         * device/include/pic16/pic18f2220.h: NEW,
9827         * device/lib/pic16/libdev/pic18f2220.c: NEW,
9828         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
9829         * src/pic16/device.c (struct Pics16): added info for 18f2220,
9830         * src/pic16/device.h (struct pic16_options): added ivt_loc and
9831         nodefaultlibs, ivt_loc is the location of the interrupt vector
9832         table, and nodefaultlibs signs that default libraries should not be
9833         linked in link stage,
9834         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
9835         according to --ivt-loc argument,
9836         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
9837         when pragma stack is found,
9838
9839 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9840
9841         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
9842         256 (range check), 257 (do while), 258.a-f (bit banging
9843         f.e. on 3-wire SPI bus)
9844
9845 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9846
9847         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
9848         variables used exclusively within a loop
9849
9850 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
9851
9852         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
9853
9854 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9855
9856         * src/SDCClrange.c (computeClash): fixed bug #971834
9857
9858 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9859
9860         * src/mcs51/gen.c (genCmp): fixed bug #975903
9861         * src/hc08/gen.c (operandsEqu),
9862         * src/ds390/gen.c (operandsEqu),
9863         * src/z80/gen.c (operandsEqu),
9864         * src/pic/gen.c (operandsEqu),
9865         * src/pic16/gen.c (operandsEqu),
9866         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
9867         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
9868
9869 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9870
9871         * src/SDCCcse.c (cseBBlock): fixed bug #966963
9872
9873 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
9874
9875         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
9876         default case in switch statement,
9877         * glue.c (pic16_initPointer): expr is initialised via decoarteType
9878         to eliminate problem with initialisation of pointers, but problem
9879         still exists,
9880         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
9881         * (emitStaticSegment): removed various lines emitting debug info,
9882         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
9883         added processor registers for utilizing EEPROM,
9884         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
9885         configurable and set 8
9886
9887 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
9888
9889         * .version: increased version number to 2.4.2,
9890
9891         Cumulative patch for pic16 port
9892         * src/pic16/device.c: changed scheme to dump initial values for
9893         variables in idata segment, all print_idata* functions were removed,
9894         now the pic16_printIval* will be called,
9895         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
9896         * _pic16_printPointerType, pic16_printPointerType,
9897         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
9898         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
9899         NEW, similar to the respective functions in SDCCglue.c,
9900         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
9901         way, emitting hex bytes,
9902         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
9903
9904 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9905
9906         * src/avr/ralloc.c (serialRegAssign),
9907         * src/xa51/ralloc.c (serialRegAssign),
9908         * src/pic/ralloc.c (serialRegAssign),
9909         * src/pic16/ralloc.c (serialRegAssign),
9910         * src/hc08/ralloc.c (serialRegAssign),
9911         * src/z80/ralloc.c (serialRegAssign),
9912         * src/ds390/ralloc.c (serialRegAssign),
9913         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
9914
9915 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9916
9917         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
9918         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
9919
9920 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
9921
9922         Cumulative patch for pic16 port:
9923         * src/pic16/device.h (typedef PIC16_device) modified fields for
9924         defining microcontrollers,
9925         * src/pic16/device.c: added new info for all devices in Pics16 array,
9926         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
9927         to be optimised out by the pCode optimiser,
9928         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
9929         specially, bug reported by G.M. Gallant,
9930         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
9931         as force'd so that cannot be optimised out by pCode optimiser,
9932         * src/pic16/pcode.c,
9933         * src/pic16/pcodepeeph.c,
9934         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
9935         they are disabled by default, but can be enabled explicit with
9936         command argument --denable-peeps, for testing,
9937         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
9938         --pomit-ivt in COMPILE_FLAGS
9939
9940 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
9941
9942         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
9943           compilation on MSVC
9944
9945 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
9946
9947         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
9948
9949 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9950
9951         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
9952         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
9953
9954 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
9955
9956         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
9957         would only assign 0x300001 register.
9958
9959 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
9960
9961         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
9962         in COMPILE_FLAGS. Thanks to G. Gallant for report.
9963
9964 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9965
9966         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
9967         for ds80c400
9968         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
9969         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
9970         added peephole 254 (left shift), 255 (jump table)
9971
9972 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
9973
9974         * device/lib/Makefile.in: removed comment line with model-pic16,
9975         * (target port-specific-objects-pic16): the libraries and objects
9976         are copied to the build directory form the device/lib/pic16/bin
9977         directory
9978
9979         Cumulative patch concerning pic16 port:
9980         * library directory has been re-organized,
9981         * added support for PIC18F1220,
9982         * added headers and library sources for chips 18f1220,18f6520,
9983         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
9984
9985         * configuration registers setting has changed, now each supported
9986         device has a complete description of the registers it uses,
9987         * all initialisations are moved to idata sections, these section
9988         can be absolute or relocatable,
9989         * fixed initialisation of codespace variables,
9990         * fixed warning about PCLATU and gpsim,
9991         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
9992         * (genAssign): use table reads when assigning from variables in codespace,
9993         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
9994         char/int variables placed in codespace,
9995         * (pic16_emitConfigRegs): NEW, emits a list with configuration
9996         registers set in .asm file, no need for --pomit-config-words anymore,
9997         * (pic16glue): some 8051 legacy segments are commented out
9998         (to be removed completely),
9999         * added support for alternative assembler and linker with --asm=
10000         and --link= command line arguments,
10001         * peepholes are disabled automatically in the port, no need to
10002         specify on command line,
10003         * port supports natively char/int/long multiplication, but converts
10004         all divisions to support functions,
10005         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
10006         to the file set in variable $2,
10007         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
10008         strings in ASCII format and not in hex,
10009         * ralloc.c (serialRegAssign): added a triplet of conditional calls
10010         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
10011         allocate proper register if iCodes aren't temporary,
10012
10013 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
10014
10015         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
10016
10017 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
10018
10019         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
10020         is commented out
10021
10022 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10023
10024         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
10025         computed address is reused
10026         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
10027         multi-byte bitfields
10028
10029 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
10030
10031         * src/z80/gen.c: (genArrayInit): must check for pointers too
10032
10033 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
10034
10035         * support/regression/tests/zeropad.c: never meant to commit the
10036           nestedstruct test: removed, added check for GCC version
10037
10038 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
10039
10040         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
10041         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
10042         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
10043           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
10044           bugs 928906 and 954082 half-empty initializers
10045         * src/SDCCsymt.h,
10046         * src/SDCCsymt.c (getAllocSize): added for above fix
10047         * src/z80/gen.c (genArrayInit): fixed bug 741044
10048         * support/regression/tests/zeropad.c: added tests
10049
10050 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
10051
10052         * src/pic16/device.c (pic16_dump_section): corrected bug which
10053         caused some symbols of the libraries to be misplaced
10054
10055 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
10056
10057         * src/pic16/glue.c,
10058         * src/pic16/ralloc.h,
10059         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
10060         to fix conflict with pic port
10061
10062 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
10063
10064         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
10065         externs configuration variables,
10066         * src/pic16/ralloc.h,
10067         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
10068         prototype in header, commented out some debug messages
10069
10070 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
10071
10072         * src/pic16/glue.c,
10073         * src/pic16/main.c,
10074         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
10075         for gpasm COFF object generation. Thanks to D. Hawkins for
10076         his patch info
10077
10078 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10079
10080         * src/ds390/main.c,
10081         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
10082         Brock for spotting this)
10083         * src/ds390/gen.c (genEndFunction),
10084         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
10085         interrupt handler and critical. Disable push/pop optimizations when
10086         peephole optimizations disabled.
10087
10088 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
10089
10090         Updated pic16 library sources and headers.
10091         * device/lib/pic16/pic18f*/ ,
10092         * device/include/pic16/*.h: modified to handle structured SFR
10093         definitions
10094
10095 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
10096
10097         * src/port.h (PORT structure): added hook initPaths, now each
10098         port can declare its own default search paths,
10099         which can been seen with the --print-search-dirs option,
10100         see pic16 port for example,
10101         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
10102         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
10103         * (doPrintSearchDirs): NEW, replaces in a central manner the
10104         printing of search dirs which was split in set*Paths functions,
10105         * (main): added call to port->initPaths and doPrintSearchDirs,
10106         * src/avr/main.c,
10107         * src/ds390/main.c,
10108         * src/hc08/main.c,
10109         * src/izt/i186.c,
10110         * src/izt/tlcs900h.c,
10111         * src/mcs51/main.c,
10112         * src/pic/main.c,
10113         * src/pic16/main.c: modified port structures to reflect addition of
10114         initPaths hook,
10115
10116         * src/pic16/device.c (regCompare): registers are finally sorted by name,
10117         * (pic16_dump_section): for registers in same address reserve memory once,
10118         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
10119         to no_banksel,
10120         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
10121         result is greater in size than right or left,
10122         * (pic16_genUMult8X8_8): there are some cases where the result can
10123         be 16 bits size, so handle these,
10124         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
10125         * (pic16_outBitC): modified to emit pcodes,
10126         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
10127         or not,
10128         * (genDivOneByte): implemented algorithm to divide 8-bits,
10129         * (genCmp): uncommented goto, but issues still exist,
10130         * (genAnd): fixed a bug with variables >8bits,
10131         * (genPackBits): optimization added that uses BCF/BSF to change a
10132         single bit,
10133         * (genAssign): fixed bug when assigning floating point literals,
10134         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
10135         __sdcc_gsinit_startup label,
10136         * src/pic16/main.c (_pic16_init): removed search directory
10137         initialisations,
10138         * (_pic16_initPaths): NEW, used to initialise search directories,
10139         * (_hasNativeMulFor): support functions for all except char/int
10140         multiplication, and char division,
10141         * (PIC16_port struct): modified entry for native mul support,
10142         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
10143         no_banksel option,
10144         * (buildCallTree): call to register_usage is ifdef'ed out,
10145
10146 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10147
10148         * device/include/string.h: applied Stas Sergeev's patch to make this
10149         header file compatible with the preprocessor -Wundef option
10150         * src/SDCCmain.c (main): abort compilation if preprocessor reports
10151         failure (fixes bug #941458)
10152
10153 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10154
10155         * src/SDCCopt.c (killDeadCode): fixed bug #907733
10156         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
10157         that the variable, not the function, should be static
10158         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
10159         to be consistent with non-literal case
10160
10161 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10162
10163         * src/SDCCast.c (isConformingBody): fixed bug #949967
10164         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
10165         convilong): fixed bug #952086
10166
10167 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10168
10169         * src/SDCCmem.c (allocVariables): fixed bug #955321
10170
10171 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10172
10173         * src/hc08/main.c (_hc08_genAssemblerEnd),
10174         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
10175         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
10176         completely eliminated the use of a temporary file
10177         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
10178         when more than one file linked
10179         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
10180
10181 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10182
10183         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
10184         which fixes bug #543481
10185         * support/regression/tests/bug-751703.c: fixed comments left from a
10186         cut and paste error
10187         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
10188         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
10189         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
10190         scopes
10191         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
10192         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
10193         are now changed to underscores in moduleName
10194
10195 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10196
10197         * as/mcs51/lkmem.c: better fix for bug #954173
10198
10199 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
10200         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10201
10202         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
10203         * device/include/c8051f000.h,
10204         * device/include/c8051f120.h,
10205         * device/include/c8051f300.h,
10206         * device/include/c8051f310.h,
10207         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
10208         PWM16) and detab'ed
10209
10210 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10211
10212         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
10213         and mailing lists, doc'ed --no-peep-comments, removed reference
10214         to knoppix (newest version has no LyX/LaTeX), other minor changes
10215         * src/SDCCglue.c (glue): save 2 bytes stack space with
10216         option --main-return. The ljmp could probably be avoided too
10217
10218 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10219
10220         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
10221
10222 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10223
10224         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
10225         * src/SDCCopt.c (isLocalWithoutDef),
10226         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
10227         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
10228         (credit to Maarten Brock for patch #949363, on which this is based)
10229         * support/regression/tests/bug-751703.c: some test cases of extern used
10230         within inner scopes.
10231
10232 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10233
10234         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
10235         SPEC_STRUCT
10236         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
10237         struct definitions
10238         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
10239         dwWriteLabel): fix to create valid debugger symbols even when
10240         the module name has non-alphanumeric symbols in it
10241         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
10242         when a variable's allocation has been optimized away
10243
10244
10245 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10246
10247         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
10248         * src/hc08/main.c,
10249         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
10250         * src/mcs51/main.c,
10251         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
10252         * src/ds390/main.c,
10253         * src/z80/gen.c (z80_emitDebuggerSymbol),
10254         * src/z80/main.c,
10255         * src/pic/gen.c (pic14_emitDebuggerSymbol),
10256         * src/pic/main.c,
10257         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
10258         * src/pic16/main.c,
10259         * src/avr/gen.c (avr_emitDebuggerSymbol),
10260         * src/avr/main.c,
10261         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
10262         * src/xa51/main.c,
10263         * src/SDCCdebug.c (emitDebuggerSymbol),
10264         * src/SDCCdebug.h,
10265         * src/port.h: added a debugger struct to the port struct. Added a
10266         callback for defining debugger symbols
10267
10268         * src/SDCCast.c (createLabel),
10269         * src/SDCC.y (labeled_statement): mark all compiler generated labels
10270         with isitmp = 1
10271         * src/SDCCicode.h,
10272         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
10273         iCode back to the ast for the function
10274
10275         * src/hc08/ralloc.c (hc08_assignRegisters),
10276         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
10277         unneeded fields from the regs struct.
10278         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
10279         pushReg() & pullReg() functions instead of emitcode()
10280
10281         * src/hc08/gen.c (genLabel, genhc08Code),
10282         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
10283
10284         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
10285         debugger hooks
10286
10287         * src/hc08/gen.c (genEndFunction, genhc08Code),
10288         * src/hc08/gen.h,
10289         * src/mcs51/gen.c (genEndFunction, gen51Code),
10290         * src/mcs51/gen.h,
10291         * src/ds390/gen.c (genEndFunction, gen390Code),
10292         * src/ds390/gen.h,
10293         * src/z80/gen.c (genEndFunction, genZ80Code),
10294         * src/z80/gen.h,
10295         * src/z80/z80.h,
10296         * src/pic/gen.c (genEndFunction, genpic14Code),
10297         * src/pic/gen.h,
10298         * src/pic16/gen.c (genEndFunction, genpic16Code),
10299         * src/pic16/gen.h,
10300         * src/avr/gen.c (genEndFunction, genAVRCode),
10301         * src/avr/gen.h,
10302         * src/xa51/gen.c (genEndFunction, genXA51Code),
10303         * src/xa51/gen.h,
10304         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
10305         specific code to cdbFile.c and out of the backend code generators
10306
10307         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
10308         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
10309         starting address is now 0
10310
10311         * as/hc08/asm.h,
10312         * as/hc08/m08pst.c,
10313         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
10314         assembler directive for DWARF support
10315         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
10316
10317         * src/src.dsp,
10318         * src/Makefile.in,
10319         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
10320
10321 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10322
10323         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
10324         and inappropriate peephole optimization in jump tables
10325
10326 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10327
10328         * as/hc08/m08pst.c,
10329         * src/SDCCglue.c: sdccopt works for the hc08 port now
10330
10331 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
10332
10333         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
10334
10335 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10336
10337         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
10338
10339 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10340
10341         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
10342         rules
10343         * src/SDCCmain.c,
10344         * src/SDCCglobl.h,
10345         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
10346         comments from the peephole optimizer replacement rules
10347         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
10348         symbols
10349         * src/SDCCcse.c (updateSpillLocation),
10350         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
10351         equivalents
10352         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
10353         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
10354         objects far pointers
10355
10356 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10357
10358         * src/SDCCsymt.h: a missing part of my last change
10359         * src/pic/ralloc.c (regTypeNum),
10360         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
10361
10362 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10363
10364         * src/SDCCicode.h,
10365         * src/SDCCicode.c (aggrToPtrDclType),
10366         * src/SDCCptropt.h,
10367         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
10368         ptrPseudoSymConvert),
10369         * src/pic/ralloc.c (regTypeNum),
10370         * src/pic16/ralloc.c (regTypeNum),
10371         * src/hc08/ralloc.c (regTypeNum),
10372         * src/ds390/ralloc.c (regTypeNum),
10373         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
10374         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
10375
10376 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10377
10378         * link/z80/lkmain.c (afile),
10379         * as/hc08/lkmain.c (afile),
10380         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
10381         prevent a pointer problem when a filename has no directory and
10382         no extension specified.
10383
10384 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10385
10386         * link/z80/lkmain.c (afile): allow periods in directory names
10387         * link/z80/lkmain.c (afile),
10388         * as/mcs51/lkmain.c (afile),
10389         * as/hc08/lkmain.c (afile): allow linker script file to have an
10390         extension other than ".lnk"
10391         * link/z80/lklex.c (getfid),
10392         * link/z80/lkmain.c (parse),
10393         * as/mcs51/lklex.c (getfid),
10394         * as/mcs51/lkmain.c (parse),
10395         * as/hc08/lklex.c (getfid),
10396         * as/hc08/lkmain.c (parse): Support comments in the linker script
10397         file on lines by themselves and after filenames
10398
10399 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10400
10401         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
10402
10403 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10404
10405         * src/z80/peeph-z80.def: removed some peephole rules that don't
10406         work with multibyte arithmetic (fixed bug #937126)
10407         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
10408         to registers and not global variables
10409         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
10410         geniCodePreInc, geniCodePostDec, geniCodePreDec,
10411         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
10412         checking for assignments not internally generated (fixed bug #931895)
10413         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
10414         structure member (fixed bug #930072)
10415
10416 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10417
10418         * src/SDCCmain.c (linkEdit),
10419         * src/hc08/main.c (_hc08_parseOptions),
10420         * as/hc08/Makefile.in,
10421         * as/hc08/aslink.h,
10422         * as/hc08/asm.h,
10423         * as/hc08/m08pst.c,
10424         * as/hc08/lkrloc.c (relr, rele),
10425         * as/hc08/lkarea.c (lnkarea)
10426         * as/hc08/lkmain.c (afile, parse),
10427         * as/hc08/lkelf.c: support for ELF output
10428         * as/hc08/lks19.c (s19),
10429         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
10430
10431 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10432
10433         * as/mcs51/lkihx.c: Fixed bug #899105.
10434
10435 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10436
10437         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
10438         .dsp files from Unix to DOS.
10439
10440 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10441
10442         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
10443         function pointers; we have been compliant for several months now.
10444         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
10445         change that was accidently commented out
10446         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
10447         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
10448         bug #922319
10449
10450 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10451
10452         * src/hc08/gen.c: output of all of the internal debugging information
10453         is now controlled by the D() macro; it is disabled by default
10454
10455 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10456
10457         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
10458         harder to keep the same registers during a CAST iCode
10459         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
10460         long via int can be done in a single cast, if the signedness is
10461         correct.
10462         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
10463         putchar() in tinibios.c in ds390's library
10464
10465 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
10466
10467         * src/SDCCast.c (decorateType): fixed bug #898889,
10468         cast result of a literal complement too
10469         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
10470         fixed check for bitfields
10471
10472 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
10473
10474         * src/SDCCicode.c (geniCodeLogic): made it static,
10475         (geniCodeLogicAndOr): added in order to fix bug #905492,
10476         (ast2iCode): fixed bug #905492
10477         * support/regression/tests/bug-905492.c: added
10478         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
10479         (processParms): fixed bug #927659: don't copy parms, this will clear
10480         decorated flag
10481         * support/regression/tests/bug-927659.c: added
10482
10483 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
10484
10485         * src/SDCCast.c (addCast): don't cast float to char
10486         * device/lib/libsdcc.lib: added _memmove
10487
10488 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
10489
10490         * device/lib/large/Makefile: fixed parallel execution by
10491         replacing `make` by `$(MAKE)`
10492
10493 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10494
10495         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
10496         offsets (fixes bug #923936)
10497
10498 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
10499
10500         * device/lib/small/Makefile: fixed parallel execution by
10501         replacing `make` by `$(MAKE)`
10502
10503 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
10504
10505         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
10506
10507 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
10508
10509         * src/pic/gen.c (genCpl): multi-byte complements were not working.
10510         * src/regression/Makefile: Regression test was not running.
10511
10512 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
10513
10514         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
10515         complement if possible
10516         * src/SDCCval.c (valComplement),
10517         * src/SDCCicode.c (operandOperation): fixed complement of literal
10518         * support/regression/tests/onebyte.c (testComplement): added
10519
10520 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
10521
10522         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
10523         return an optimized tree; actually replace actParm with the new tree
10524         * src/SDCCast.h: added some parantheses to remove side effects
10525         * support/regression/tests/bug-920866.c
10526
10527 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
10528         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
10529         Bit operands were not being handled properly in the pic14 port.
10530         (now src/regression/add.c passes again).
10531
10532 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10533
10534         * src/SDCC.y (labeled_statement): case and default no longer require
10535         a following statement (RFE #893037)
10536
10537 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10538
10539         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
10540         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
10541         disabled (fixes bug #916294)
10542         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
10543         "mov a,acc"; patch provided by Lenny Story
10544         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
10545
10546 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10547
10548         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
10549         functions
10550         * src/ds390/gen.c (genFunction, genEndFunction),
10551         * src/ds390/ralloc.c (ds390_assignRegisters),
10552         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
10553         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
10554         pushed if there are parameters passed on the stack. Also, a cleaner
10555         way to decide if r0/r1 should be pushed/popped. (Together they fix
10556         bug #918693)
10557
10558 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10559
10560         * doc/sdccman.lyx,
10561         * device/lib/mcs51/crtpagesfr.asm,
10562         * device/lib/mcs51/crtxinit.asm,
10563         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
10564         to avoid confusion with Si Lab's SFRPAGE register.
10565
10566 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10567
10568         * src/SDCCglue.c (emitMaps): allow public sfr variables
10569         * src/SDCCglue.c (initialComments): include compiler build date
10570         with compiler version and put the timestamp of the generated
10571         assembly file on a serperate line to be less confusing.
10572         * src/port.h: added genInitStartup hook
10573         * src/avr/main.c,
10574         * src/ds390/main.c,
10575         * src/hc08/main.c,
10576         * src/pic/main.c,
10577         * src/pic16/main.c,
10578         * src/xa51/main.c,
10579         * src/z80/main.c: genInitStartup initialize as NULL (default to
10580         historical behaviour)
10581         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
10582         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
10583         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
10584         library instead of hard coding it into the compiler.
10585         * support/regression/ports/mcs51-stack-auto/spec.mk,
10586         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
10587         * device/lib/mcs51/Makefile,
10588         * device/lib/small/Makefile,
10589         * device/lib/large/Makefile,
10590         * device/lib/mcs51/crtpagesfr.asm,
10591         * device/lib/mcs51/crtstart.asm,
10592         * device/lib/mcs51/crtxclear.asm,
10593         * device/lib/mcs51/crtxinit.asm,
10594         * device/lib/mcs51/crtclear.asm,
10595         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
10596         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
10597         and into user configurable files.
10598         * device/lib/clean.mk: clean mcs51 directory too
10599         * support/regression/tests/longlit.c: added static to T1 declaration
10600         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
10601         accesses in the initialization code
10602
10603 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10604
10605         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
10606         OSCTRIMVAL as noted in bug #916008
10607
10608 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10609
10610         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
10611         in loops with multiple exits (reported as incorrect registers
10612         used by Martin Helmling in Sdcc-user list)
10613
10614 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10615
10616         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
10617         made ds390 register extensions look less like error messages
10618
10619 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10620
10621         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
10622         reported by Adam Wozniak in Sdcc-user list
10623
10624 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
10625
10626         * src/SDCCast.c (decorateType): fixed with bug and promotion in
10627         arithmetic optimizations, added debug output
10628
10629 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
10630
10631         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
10632         * sdcc.spec: updated and split sdcc into 3 rpms
10633         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
10634         needed for literals of LEFT_OP and '+'
10635         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
10636         introduced RESULT_TYPE_NOPROM
10637         (geniCodeMultiply): fixed logic for decision if mul is optimized to
10638         left shift
10639         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
10640         limited promotion to int only for '*'
10641         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
10642
10643 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
10644
10645         * src/pic16/gen.c (genSkip),
10646         (genc16bit2lit), (gencjneshort): commented out
10647         (is_LitOp): new helper function, checks operand type
10648         (genCmpEq): rewritten
10649
10650 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
10651
10652         * support/regression/tests/bug-908454.c: added
10653
10654 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
10655
10656         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
10657         * src/SDCCicode.c (usualBinaryConversions): op needs int type
10658         (geniCodeCast): cosmetic, don't preserve bit storage class
10659         (geniCodeLeftShift): added promotion
10660         (geniCodeLogic): fixed regression
10661         * src/SDCCsymt.c (computeTypeOr): accept bits too
10662         (compareType): 2nd part of fix for bug #908454, needed for bitfields
10663
10664 2004-03-07  Borut Razem <borut.razem AT siol.net>
10665
10666         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
10667
10668 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
10669
10670         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
10671         version of pic16_genPackRegisters which does not check if ic is a
10672         CAST operator,
10673         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
10674         function cause string1.c regression test fails
10675
10676 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
10677
10678         * sim/ucsim/configure.in,
10679         * sim/ucsim/configure,
10680         * sim/ucsim/doc/Makefile.in: use docdir
10681         * src/SDCC.y: fixed sbit atrributes
10682         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
10683         * src/SDCCast.c (decorateType): |^& need special promotion handling
10684         * src/SDCCast.h,
10685         * src/SDCCsymt.h: moved definition of RESULT_TYPE
10686         * src/SDCCsymt.h (computeType),
10687         * src/SDCCicode.c: computeType() needs op
10688         * src/SDCCsymt.c (checkTypeSanity),
10689         * doc/sddman.lyx: "plain" bitfields are unsigned
10690         * src/SDCCsymt.c (computeTypeOr): added
10691         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
10692         |^& ops
10693         * src/SDCCval.c (val*): computeType() needs op
10694         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
10695         * support/regression/tests/onebyte.c: added tests for |^&
10696
10697 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
10698
10699         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
10700         for writing icode into asm output.
10701
10702 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
10703
10704         * src/pic16/device.c: added some debug lines enabled
10705         with macro DEBUG_CHECK,
10706         * src/pic16/genarith.c: more debug in genPlus,
10707         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
10708         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
10709         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
10710         * (aopForSym): onStack symbols are re-placed in data memspace,
10711         and onStack flag is cleared,
10712         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
10713         copy temporary pcodeop,
10714         * (genPcall): added warning for not updating PCLATU,
10715         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
10716         always true for pic16 port,
10717         * (genMultOneWord): NEW, supports integer multiplication,
10718         * (genMult): modified to call genMultOneWord,
10719         * (ifxForOp): added warning when return NULL,
10720         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
10721         flag is set before call to operandFromSymbol for implicit
10722         added structures,
10723         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
10724         options.intlong_rent are set by default,
10725         * (_hasNativeMulFor): modified to allow port generation of integer
10726         multiplication,
10727         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
10728         set regtype to REG_SFR for all registers, restricting seting the
10729         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
10730
10731 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10732
10733         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
10734         more than 500 times in the regression tests
10735
10736 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10737
10738         * support/Util/SDCCerr.h,
10739         * support/Util/SDCCerr.c,
10740         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
10741         enumerator_list),
10742         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
10743         for symbol conflicts.
10744         * support/valdiags/tests/enum.c,
10745         * support/valdiags/tests/tentdecl.c,
10746         * support/valdiags/tests/struct.c: expect possible error messages
10747         referring to original symbol definitions.
10748         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
10749         * src/SDCCsymt.h,
10750         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
10751
10752 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
10753
10754         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
10755
10756 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
10757
10758         * src/pic16/ralloc.c (newReg): fixed bug #908929
10759
10760 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10761
10762         * src/ds390/gen.c: added missing #include "main.h"
10763
10764 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
10765
10766         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
10767         checking if symbol is already in set,
10768         * src/pic16/device.h: prototype for checkAddSym,
10769         * src/pic16/gen.c: (_G): added entry interruptvector,
10770         * (assignResultValue): removed some commented out lines,
10771         * (genFunction): check for ISR via sym->type, absolute section for
10772         interrupt code is created via a new pBlock, the goto instruction is
10773         placed now correctly at the interrupt vector position, changed all
10774         references from ivec to _G.interruptvector,
10775         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
10776         is the interrupt is a high priority one, same for return from ISR,
10777         * src/pic16/glue.c: changed all calls of addSetHead for publics and
10778         externs to calls of checkAddSym,
10779         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
10780         pic16_pcode_verbose flag is set,
10781         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
10782         * src/pic16/pcoderegs.c: message about how many registers are saved
10783         will only be emitted if pic16_pcode_verbose flag is set,
10784
10785 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10786
10787         * src/ds390/ralloc.h,
10788         * src/ds390/ralloc.c (ds390_regWithIdx),
10789         * src/ds390/gen.c (emitcode),
10790         * src/ds390/main.h,
10791         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
10792         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
10793         ds390operandCompare, getRegsRead, getRegsWritten,
10794         initializeAsmLineNode): customized instruction size calculation for
10795         ds390, started basis for some register optimizations
10796         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
10797         corresponding assembly output
10798         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
10799         missing push/pop of r0/r1. Optimized push/pops
10800
10801 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10802
10803         * src/mcs51/main.c (instructionSize): fixed ACALL size
10804         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
10805
10806 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
10807
10808         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
10809         the sorting of rlist with NULL elements
10810         * (print_idataType, print_idata): NEW to create idata sections
10811         * src/pic16/device.h: idataSymSet new variable
10812         * src/pic16/gen.c (genFunction): fixed some bugs in string
10813         comparing, improved the absolute section creation for ISRs,
10814         added FSR0L/FSR0H in registers that are saved in an ISR,
10815         * (genInline): fixed the processing of inline snippets,
10816         now they undergo no process by the peephole optimizer
10817         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
10818         are placed in idataSymSet,
10819         * (pic16emitStaticSeg): extern symbols are added in externs,
10820         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
10821         switching when aboslute variables are placed in access bank memory
10822         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
10823         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
10824         commented out with #if,
10825         * (pic16_packRegisters): reintroduce the check for CAST because some
10826         symbols are not correctly handled,
10827         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
10828         pCodeInstruction instead of pCode,
10829         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
10830         pCodeAsmDir definition,
10831         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
10832         directive, then the argument directive is emitted without the leading
10833         tab, hack for inline labels which must be in the first column,
10834         * (compareLabel,pic16_findNextInstruction),
10835         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
10836         * (insertBankSwitch): modified for the new pCodeAsmDir,
10837
10838 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
10839         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
10840
10841         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
10842         instance,
10843         * (pushSide): commented out with #if,
10844         * (assignResultValue): fixed some typos in saving
10845         registers,
10846         * (genPcall): FIXED and sync'ed with genCall,
10847         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
10848         * (genNearPointerGet): fixed to handle some more cases,
10849         implementation scheme via table reads,
10850         * (genConstPointerGet): modified to access code memory correct,
10851         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
10852         and improved to handle some cases
10853         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
10854         instead of "RETLW" for init data
10855         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
10856         not IN_DIRSPACE, work around to reduce bank switching when aboslute
10857         variables are placed in access bank memory (<0x80 and >=0xf80),
10858         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
10859         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
10860         TBLWT_POSTDEC,TBLWT_PREINC
10861         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
10862         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
10863         directives
10864         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
10865         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
10866         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
10867         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
10868
10869 2004-02-29  Borut Razem <borut.razem AT siol.net>
10870
10871         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
10872         support/Util/findme.h, support/Util/system.h: enhance binary relative
10873         search for lib and include by using findProgramPath()
10874
10875 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10876
10877         * src/SDCCpeeph.h,
10878         * src/SDCCpeeph.c (pcDistance),
10879         * src/port.h,
10880         * src/mcs51/ralloc.h,
10881         * src/mcs51/ralloc.c (mcs51_regWithIdx),
10882         * src/mcs51/main.h,
10883         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
10884         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
10885         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
10886         size calculation port specific, started basis for some register
10887         optimizations
10888         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
10889         missing push/pop of r0/r1. Optimized push/pops
10890         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
10891         * device/lib/_modsint.c (_modsint),
10892         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
10893         and stack version so regression tests pass
10894
10895 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
10896
10897         * src/Makefile.in (dep): include SLIBOBJS in dependency check
10898         * src/SDCCast.c (decorateType): catch another small optimization
10899         with '?' operator
10900         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
10901         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
10902         modified to finally use computeType() all over SDCC,
10903         see Feature Request #877103
10904         * src/SDCCval.h: cosmetic
10905         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
10906         valCompare(); regression tested in muldiv.c
10907         * support/regression/tests/muldiv.c (testMod): mod sign follows
10908         dividend only
10909
10910 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
10911
10912         * src/SDCCast.c (decorateType): fixed bug #902362
10913         * doc/INSTALL.txt: fixed install instructions for win32
10914
10915 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
10916
10917         * device/include/Makefile.in (install): fixed by replacing spaces
10918         by tabs
10919         * doc/README.txt,
10920         * doc/INSTALL.txt: updated for release
10921         * doc/sdccman.lyx: added warning for --xstack being buggy
10922
10923 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
10924
10925         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
10926         to eliminate build warnings.
10927         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
10928
10929 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
10930            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
10931
10932         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
10933         removed -penable-stack, added comment for stack pragma, added
10934         warning for not initializing the stack/frame registers, removed
10935         comment at interrupts section
10936
10937         Stack is made permanent, there is no ability to disable stack usage.
10938         * src/pic16/device.h,
10939         * src/pic16/device.c: removed all references to USE_STACK macro,
10940         * src/pic16/device.c (pic16_dump_section): when no elements in
10941         rlist, free rlist before return,
10942         * (pic16_dump_int_registers): NEW, internal registers are a new set
10943         of general purpose registers reused by each function,
10944         * (checkAddReg): returns 1 if registers is added to set,
10945         * (pic16_groupRegistersInSection): when a registers is of type
10946         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
10947         * src/pic16/device.h: memRange and Assigned Memory are deleted,
10948         SRCASECMP macro is moved here from device.c
10949         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
10950         PO_PCLATU, PO_PRODL, PO_PRODH,
10951         * (pic16_pCodeOpType, genMinus,
10952         changed compares to "a" register, with AOP_ACC,
10953         * (pic16_genPlus): fixed some bugs and indented properly,
10954         * (pic16_addSign): changed size to size+offset in the MOVWF
10955         instruction,
10956         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
10957         multiply 8-bit operand by literal, result is 8-bit,
10958         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
10959         multiply 2 8-bit operand, result is 8-bit,
10960         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
10961         genUMult8X*_16,
10962         * src/pic16/gen.c: changed accUse to contain WREG only,
10963         * (pic16_emitcomment): renamed to pic16_emitpcomment,
10964         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
10965         true, do not use immediate addressing any more unless sym is a
10966         pointer in codespace,
10967         * (aopForRemat): do not use immediate addressing when symbol not in
10968         codespace and when symbol's address is requested,
10969         * (aopOp): for-loop in if(sym->accUse) is modified for the new
10970         accUse size (= 1),
10971         * (aopGet): added case for AOP_ACC and don't return "accumulator
10972         bug" but WREG instead,
10973         * (popGetTempReg): pushes contents of temporary register in stack,
10974         * (popReleaseTempReg): pops contents of temporary register from
10975         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
10976         * (pic16_popGet): separated case AOP_ACC to return register WREG
10977         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
10978         or PO_IMMEDIATE and initializes their instance/offset appropriately,
10979         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
10980         the use of immediate pointers to certain cases only.
10981
10982         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
10983         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
10984         * (assignResultValue, genCall, genRet): modified to use the new
10985         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
10986         genPcall is still broken,
10987         * (genFunction): added code to create 'A' type pBlocks when
10988         interrupt functions are generated, code not extensively tested yet,
10989         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
10990         * (genEndFunction): modified so ISRs pop stored registers from stack,
10991         * (genMultOneByte): cleanup,
10992         * (AccRsh): added flag andmask, to and result with appropriate mask,
10993         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
10994         * (genDataPointerGet): fixed and reenabled its use,
10995         * (genNearDataPointerGet): bugs fixed,
10996         * (genDataPointerSet): bugs fixed,
10997         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
10998         pic16_DumpSymbol, pic16_DumpOp,
10999         * src/pic16/genutils.h: function prototypes for the above functions,
11000         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
11001         pointers,
11002         * (pic16emitRegularMap): many many many improvements, but needs a
11003         major cleanup,
11004         * src/pic16/main.c: enable_stack in pic16_options is removed,
11005         * (_pic16_parseOptions): removed command line options -penable-stack,
11006         * (_process_pragma): emit stack symbol only when stack pragma is
11007         processed,
11008         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
11009         redirected to FSR0L/FSR0H pair,
11010         * (pic16_get_op, pic16_get_op2): modifications and improvements,
11011         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
11012         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
11013         for immediates,
11014         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
11015         * (dumpPicOptype): NEW,
11016         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
11017         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
11018         with movff instruction,
11019         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
11020         added pic16_int_regs, some packRegsFor* functions are commented out,
11021         because produce errors,
11022         * src/pic16/NOTES: minor modifications
11023
11024 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11025
11026         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
11027         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
11028         --pack-iram.
11029         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
11030         * as/mcs51/lkaomf51.c: fixed bug #895763
11031
11032 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
11033
11034         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
11035
11036 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11037
11038         * doc/sdccman.lyx: added details about the HC08 storage classes and
11039         interrupts, fixed the register usage info for z80 & gbz80
11040
11041 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
11042
11043         * doc/sdccman.lyx: added more pic16 port documentation
11044         * device/include/pic16/: added header pic18fregs.h
11045
11046 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
11047
11048         * doc/sdccman.lyx: added Vangelis' contribution
11049
11050 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11051
11052         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
11053         extend to the next CALL or PCALL, not just to the next CALL.
11054
11055 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
11056
11057         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
11058
11059 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11060
11061         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
11062         bug #895752 and a better fix for bug #716790
11063
11064 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11065
11066         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
11067
11068 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11069
11070         * doc/sdccman.lyx: minor changes, minor changed
11071
11072 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
11073
11074         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
11075         which can't handle SDCC_NEWONEBYTEOPS,
11076         (geniCodeMultiply): removed conversion from mult to shift for pic14
11077         and pic16
11078
11079 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11080
11081         * src/hc08/gen.h,
11082         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
11083         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
11084         thus fixing bug #895406
11085
11086 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
11087
11088         * device/lib/_modsint.c,
11089         * device/lib/_modslong.c: sign follows divisor only
11090         * src/hc08/gen.c (genMultOneByte): if result size is 1,
11091         signs or signedness can be ignored
11092         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
11093         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
11094         added optimization for IFX,
11095         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
11096         arguments;
11097         reenabled optimization for IFX, which was removed on 2004-01-11
11098         * src/SDCCast.h: added return type IFX
11099         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
11100         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
11101         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
11102         SDCC_OLDONEBYTEOPS selects the old behaviour
11103         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
11104         changed again and commented promotion rule
11105         * src/SDCCval.c (valDiv): promotion no longer necessary
11106         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
11107         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
11108         rewritten
11109         * support/regression/tests/onebyte.c: added
11110
11111 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
11112
11113         * gen.c (genInline): reverted to old code for assemnling inline
11114         code because of bug reported James Chadd
11115
11116 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
11117
11118         * ralloc.h: missing declarations from previous patch,
11119         seems that patch for ralloc.h was never applied, fixed
11120
11121 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
11122            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
11123
11124         * pcode.c,
11125         * pcode.h,
11126         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
11127         indirect addressing. Marked FSR0 as deprecated
11128         * gen.c (pointerCode): commented out, not needed now
11129         (pic16_popGet2p): new MOVFF helper function
11130         (genGenPointerGet),
11131         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
11132         (shiftRLong): removed duplicate debugging info
11133
11134 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11135
11136         * src/ds390/gen.c (genNearPointerGet),
11137         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
11138         optimization with bits, but not bitfields.
11139         * src/ds390/ralloc.c (packRegisters),
11140         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
11141
11142 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
11143
11144         * src/SDCCcse.c (algebraicOpts): copy operands before modification
11145
11146 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11147
11148         * src/SDCCsymt.h,
11149         * src/SDCCicode.c (operandFromSymbol),
11150         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
11151         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
11152         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
11153         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
11154         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
11155         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
11156         bug #892038
11157         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
11158         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
11159         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
11160         * src/SDCCsymt.c (newSymbol),
11161         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
11162         enumerator_list),
11163         * src/SDCCval.h,
11164         * src/SDCCval.c (newiList): fixed bug #885705
11165
11166 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11167
11168         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
11169         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
11170
11171 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11172
11173         * device/include/c8051f120.h,
11174         * device/include/c8051f300.h,
11175         * device/include/c8051f310.h: added/updated header files for Silicon
11176         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
11177         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
11178         in new section Submitting patches
11179
11180 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11181
11182         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
11183         genFarPointerGet, genCodePointerGet, genGenPointerGet,
11184         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
11185         genGenPointerSet),
11186         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
11187         genFarPointerGet, genCodePointerGet, genGenPointerGet,
11188         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
11189         genGenPointerSet),
11190         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
11191         genFarPointerGet, genCodePointerGet, genGenPointerGet,
11192         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
11193         genGenPointerSet),
11194         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
11195         genFarPointerGet, genCodePointerGet, genGenPointerGet,
11196         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
11197         genGenPointerSet): fixed bug #892400
11198         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
11199         to eliminate build warnings.
11200         * src/SDCCast.c (processParms),
11201         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
11202         fixed bug 751859
11203         * support/valdiag/valdiag.py: added GCC to the list of defines active
11204         when compiling with gcc
11205
11206 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11207
11208         * support/Util/SDCCerr.h,
11209         * support/Util/SDCCerr.c,
11210         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
11211         with an incomplete type (fixed bug #883734)
11212         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
11213
11214 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11215
11216         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
11217
11218 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11219
11220         * src/SDCCast.c (decorateType),
11221         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
11222         function pointer implementation
11223         * support/regression/tests/funptrs.c: added tests to verify both forms
11224         of function pointers work correctly. Added tests to verify parameters
11225         are passed in the correct order.
11226
11227 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
11228
11229         * device.c (regCompare): registers are sorted by ascending
11230         address and increasing size,
11231         * main.c (_pic16_finaliseOptions): removed the declaration
11232         of compiler macro MCU. Now a macro of the format pic18fxxxx
11233         will be defined from the command line
11234
11235 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
11236             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
11237
11238         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
11239         PCOP_RLCF was overwritten!
11240         * gen.c (genSkip): commented out calls to pic16_emitcode,
11241         * (genCmpEQ): fixed "long" compares, only high word did get compared,
11242         * (genlshTwo),
11243         * (genRRC): added debugging info,
11244         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
11245         overwritten while shifting,
11246         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
11247         overwritten while shifting,
11248         * (AccLsh),
11249         * (AccRsh),
11250         * (shiftLLeftOrResult),
11251         * (shiftRLeftOrResult),
11252         * (shiftRLong),
11253         * (shiftLLong): Implemented with pic16_emitpcode
11254         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
11255         * (genLeftShift): Fixed bug, operand for shift by variable always
11256         was "and"ed with 0x0f,
11257         * (genLeftShiftLiteral),
11258         * (genrshTwo),
11259         * (genRightShiftLiteral): added debugging info,
11260         * (genrshFour): added comment,
11261         * (genRightShift): determined signedness from operand "left"
11262         instead of "result"
11263
11264 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11265
11266         * src/SDCCicode.c (geniCodeParms),
11267         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
11268         function pointers, fixed function pointer bugs #861242 and #861896
11269
11270 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11271
11272         * device/include/c8051f000.h,
11273         * device/include/c8051f120.h,
11274         * device/include/c8051f300.h: added header files for Silicon
11275         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
11276
11277 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
11278
11279         * src/SDCCast.c (processParams): added new type flow and restructured
11280         (gatherAutoInit): added new type flow
11281         (addCast): cosmetic changes
11282         (getLeftResultType): added new type flow for array indices, patch
11283         provided by Stas, see FR #877103
11284         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
11285         array index patch by Stas
11286         * src/SDCCast.h: added prototype getResultTypeFromType()
11287         * src/SDCCval.h,
11288         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
11289         * src/pic/glue.c (pic14emitStaticSeg),
11290         * src/pic16/glue.c (pic16emitStaticSeg),
11291         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
11292         for initialization of symbols
11293         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
11294         * support/Util/SDCCerr.h:
11295         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
11296         * .version: bumped version number to 2.3.8
11297         * device/include/Makefile.in (install),
11298         * doc/Makefile (install): changed to 'rm `find ...`' construct to
11299         avoid warnings
11300
11301 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
11302
11303         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
11304         Slade Rich fixed an optimization bug
11305         * src/pic/pcodepeep.c,
11306         * src/pic/pcoderegs.c
11307         * doc/Makefile (install): added test for directory
11308
11309 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11310
11311         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
11312         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
11313         * src/pic/ralloc.c (getRegPtr, getRegGpr),
11314         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
11315         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
11316         * as/mcs51/asexpr.c (term),
11317         * as/hc08/asexpr.c (term): fixed bug #887146
11318
11319 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11320
11321         * src/z80/gen.c (genMult): handle single byte result product
11322         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
11323         DUMMY_READ_VOLATILE (fixed bug #886367)
11324
11325 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
11326
11327         * support/regression/tests/libmullong.c: fixed logic, on little endian
11328         hosts we ended without a mullong_wrapper()
11329
11330 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11331
11332         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
11333         virus/worm forged address usage.
11334
11335 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
11336
11337         Fixed promotion, it should be done on AST level:
11338         * src/SDCCast.c (addCast): added promotion to int
11339         (decorateType): updated call to upCast()
11340         * src/SDCCicode.c (geniCodeLeftShift): removed call to
11341         usualUnaryConversions()
11342
11343 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
11344
11345         * support/regression/tests/literalop.c (mulWrapper): Added a
11346         wrapper to remove integer overflow warnings.
11347
11348         * support/regression/tests/float_trans.c: Made work on host.
11349
11350         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
11351         location of sz80.
11352
11353         * support/regression/generate-cases.py (main): Changed from inline
11354         to a main method.
11355
11356         * doc/Makefile (install): Changed to depth first to get rid of
11357         missing directory install warning.
11358
11359         * as/Makefile (install-doc): Made work on Mac.
11360
11361 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
11362
11363         * src/SDCCast.c: added an additional type flow in decorateType() of
11364         opposite direction, see feature request #860006; it's enabled at runtime
11365         by setting the environment variable SDCC_NEWTYPEFLOW
11366         * src/SDCCast.h: changed prototype of decorateType()
11367         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
11368         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
11369         'char' to 'int' can be omitted, if both operands are 'unsigned char';
11370         see feature request #877103
11371         * src/SDCCval.c: updated call of decorateType()
11372         (valBitwise): fixed bug #882876
11373         (valMinus): added promotion
11374         (valLogicAndOr): result is unsigned
11375         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
11376         * src/SDCCsymt.c (computeType),
11377         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
11378         must not cause an unsigned operation
11379         * src/pic/glue (pic14emitRegularMap),
11380         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
11381
11382 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
11383
11384         * src/pic/pcode.c (PCodeID): commented out left over debug code
11385
11386 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
11387
11388         * support/valdiag/tests/overflow.c: added shift tests
11389         * src/pic/device.c,
11390         * src/pic/gen.c,
11391         * src/pic/gen.h,
11392         * src/pic/glue.c,
11393         * src/pic/main.c,
11394         * src/pic/pcode.c,
11395         * src/pic/pcode.h,
11396         * src/pic/pcodepeep.c,
11397         * src/pic/pcoderegs.c,
11398         * src/pic/ralloc.c,
11399         * src/pic/ralloc.h: applied patch from Slade Rich;
11400         added support for multiple code pages and multiple RAM banks on the
11401         PIC 14 port. The ASM files now no longer simply assume all the
11402         code / RAM are in the same page / bank. This means the linker can
11403         safely allocate code/RAM of separate ASM files to different pages/banks.
11404         * doc/sdccman.lyx: added Slade's tips
11405         * src/mcs51/peeph.def: fixed bug #880768
11406
11407 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11408
11409         * src/hc08/ralloc.c (rematStr): fixed bug #879282
11410         * src/SDCCast.c (decorateType): fixed bug #880197
11411
11412 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
11413
11414         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
11415         getopt.h.
11416
11417         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
11418         strtof is not part of C89 and isn't included with Mac OS X.
11419
11420 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11421
11422         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
11423         shiftL2Left2Result): fixed bug #879326
11424         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
11425         (genMultOneByte): fixed bug in signed vs unsigned multiplication
11426         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
11427         address fetch for clr instruction
11428         * device/lib/hc08/_mulint.c: created optimized assembly version
11429         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
11430
11431 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
11432
11433         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
11434         proposed in FR #877103
11435
11436 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
11437
11438         * src/SDCCval.c (cheapestVal): added missing checks
11439         * src/SDCCicode.c (usualBinaryConversions): fixed condition
11440         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
11441
11442 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
11443
11444         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
11445         equal operands
11446
11447 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
11448
11449         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
11450         loaded with the linker search paths (-L arguments) and the libraries
11451         to be linked with the current source (-l arguments). Changes
11452         currently will affect only the pic16 port.
11453         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
11454         include path the port specific paths and port specific libraries,
11455         * gplink command now contains the $3 argument,
11456         * src/pic16/device.h,
11457         * src/pic16/device.c,: structure PIC_device is made public and
11458         renamed to PIC16_device, the same for variable Pics which is renamed
11459         to Pics16. Updated all references to them.
11460         * src/pic16/glue.c (pic16glue): corrected bug with code
11461         initialization which bypassed the variable initializations block.
11462
11463         * device/lib/pic16/Makefile.rules: removed --penable-stack from
11464         COMPILE_FLAGS and added the --nostdinc option
11465
11466 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11467
11468         * device/include/mc68hc908jb8.h: Register defs for another member
11469         of the hc08 family. Contributed by Bjorn Bringert - thanks!
11470
11471 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
11472
11473         Documenting changes from previous commits.
11474         * configure.in (version 1.56),
11475         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
11476         when generating output files to configure the pic16 library,
11477         but now I've commented it out, since gputils aren't installed in the
11478         SF compile farm, so library won't compile
11479
11480         * device/lib/Makefile.in (version 1.56): initially I've added in
11481         target 'all' the prerequestive 'model-pic16' so it compiled the
11482         pic16 library, but now I've commented it out for the same reasons
11483         above,
11484         * added targets 'model-pic16' and 'objects-pic16' to compile the
11485         library
11486         * added target 'port-specific-objects-pic16' to handle the
11487         generated libraries and copy them into the build/ directory
11488         * added target 'clean-intermediate-pic16' to clean intermediate
11489         files into pic16 directory
11490         * in target 'installdirs' added line to create directory pic16 in
11491         the installation path
11492
11493         * device/include/Makefile.in (version 1.11): in target 'install'
11494         added lines to copy all header files to installation path,
11495         * in target 'installdirs' added line create directory for pic16
11496         headers in the installation path
11497
11498 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
11499
11500         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
11501          a function call
11502
11503 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
11504
11505         * configure,
11506         * device/lib/configure.in,
11507         * device/lib/configure: fixed for autoconf 2.57
11508
11509 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11510
11511         * src/z80/main.c (_parseOptions): fixed the portmode= command line
11512         option so that it actually works. Made it specific to the z80, since
11513         the gbz80 doesn't have these kinds of I/O ports.
11514
11515 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11516
11517         * device/include/z180.h,
11518         * device/lib/_memcpy.c,
11519         * device/lib/_memmove.c,
11520         * device/lib/_mulint.c,
11521         * device/lib/ser_ir.c,
11522         * device/lib/ser_ir_cts_rts.c,
11523         * device/lib/_strcmp.c,
11524         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
11525         * src/z80/main.c (_process_pragma): add support for pragmas bank and
11526         portmode; added deprecation warning for bank= and protmode= forms.
11527         Also, guard against buffer overflow.
11528         * src/z80/gen.c (aopGet): generate better code for sfr banked read
11529
11530 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11531
11532         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
11533         changed interrupt vector table generation to only emit declared vectors.
11534         * device/include/Makefile.in: added missing backslash
11535         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
11536
11537 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
11538
11539         Mainly changes to support compilation of the device libraries
11540         * src/pic16/device.c: stack is allocated via symbol and not
11541         via literal number. The symbol is placed in the corresponding
11542         position of the data ram
11543         * (pic16_dump_section): relocatable and absolute uninitialized
11544         data are now emitted in sorted order to reduce section naming,
11545         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
11546         weren't marked as being in the access bank,
11547
11548 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
11549
11550         Added portion of GNU PIC Library under the directory
11551         device/include/pic16 and device/lib/pic16. These files
11552         contain the declarations of SFRs for the PIC18Fxx2 devices.
11553         The directory is initialized via configure from toplevel.
11554
11555 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
11556
11557         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
11558         the spilllocations to be compared correctly
11559
11560 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
11561
11562         * src/SDCCast.c (decorateType): fixed bug introduced today
11563
11564 2004-01-12  Borut Razem <borut.razem AT siol.net>
11565
11566         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
11567         doc/sdccman.lyx: upper case pragmas are deprecated
11568
11569 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
11570
11571         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
11572         in simpler and even better code
11573
11574 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
11575
11576         * src/SDCCicode.c (operandOperation): fixed bug #874819
11577         * src/SDCCast.c (decorateType): fixed
11578         char foo (unsigned long ul) { return ul > 0; }
11579
11580 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11581
11582         * doc/sdccman.lyx: Moved and added some sections, small changes
11583         all over. Telling LaTeX to be less strict with word spacing
11584         to better keep the right margin. Changed some notes about
11585         maintainance of the ports in section 3.2.1 - is it OK like this?
11586
11587 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
11588
11589         SDCC source changes:
11590         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
11591         convilong): modified to inform the pic16 port that builtin functions
11592         are external
11593
11594         PIC16 PORT specific changes:
11595         * src/pic16/device.c pic16_dump_equates() added,
11596         processor registers declared internally by the port are emitted in
11597         the translation as equates,
11598         * src/pic16/gen.c: inline code is passed unprocessed to the
11599         translation,
11600         * (pic16_popGetLit2): fnuction modified to take second operand as
11601         pCodeOp pointer and not as literal,
11602         * (popRegFromIdx): prefixed with pic16_,
11603         * (pic16_popCombine2): modified to receive already allocated pCode
11604         operands,
11605         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
11606         * (genFunction): initializes local stack frame and pushes on stack
11607         all the registers used by this function,
11608         * (genEndFunction): restores all registers from stack and restores
11609         stack frame,
11610         * src/pic16/glue.c (pic16emitRegularMap): various changes and
11611         improvements,
11612         * (pic16glue): changed the program startup sequence,
11613         * added new dbName code 'A' for functions placed in absolute section
11614         * src/pic16/main.c: added function attribute _naked,
11615         * added pragma 'code' to place a fnuction at an absolute address,
11616         * added command line arguments --debug-ralloc and --pcode-verbose,
11617         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
11618         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
11619         * (pic16_newpCodeOpLit2): modified to take the second operand as
11620         pCodeOp pointer,
11621         * (pic16_printpBlock): modified to emit each function in a separate
11622         section,
11623         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
11624         UPPER for immediate operands,
11625         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
11626         instruction,
11627         * src/pic16/peeph.def: all peepholes with movff are commented out,
11628         because there is a problem in the pcode peep optimizer,
11629         * src/pic16/ralloc.c: the register allocator can now reuse local
11630         function symbols for another function. This saves register usage.
11631         * src/pic16/ralloc.h: added flag isLocal in structure regs,
11632
11633         Added file src/pic16/NOTES with information about program writing on
11634         the current port version.
11635
11636 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11637
11638         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
11639         and peephole 252 (array access)
11640
11641 2004-01-09  Borut Razem <borut.razem AT siol.net>
11642
11643         * src/SDCCmain.c : fixed #872250: -l command line defined library
11644           files are scanned before standard library files
11645
11646 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11647
11648         * src/SDCCast.c (decorateType): fixed bug #874046
11649
11650 2004-01-09  Borut Razem <borut.razem AT siol.net>
11651
11652         * support/scripts/sdcc.nsi: remove previous installation
11653
11654 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11655
11656         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
11657         bytes for last interrupt vector (mcs51)
11658         * sdcc.spec: fixed typo
11659
11660 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11661
11662         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
11663         gen51Code): more efficient parameter receive for --model-large
11664         ("bug" #845294)
11665
11666 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11667
11668         * src/ds390/main.c,
11669         * src/z80/main.c: added missed needLinkerScript flags (more than
11670         one port structure defined in these file)
11671         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
11672         bug #795325
11673
11674 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
11675
11676         * src/SDCCmain.c: removed various references to DEFAULT_PORT
11677         * src/port.h: added flag needLinkerScript in port->linker
11678         structure to inform whether to create a .lnk file or not,
11679         * src/avr/main.c,
11680         * src/ds390/main.c,
11681         * src/hc08/main.c,
11682         * src/mcs51/main.c,
11683         * src/pic/main.c,
11684         * src/pic16/main.c,
11685         * src/xa51/main.c,
11686         * src/z80/main.c: changed appropriately to configure
11687         needLinkerScript flag
11688         * src/pic/gen.c,
11689         * src/pic16/gen.c (genAddrOf): fixed bug #863624
11690         * src/pic/glue.c: added variable udata_section_name to
11691         override default uninitialized data segment definition for
11692         devices only with SHAREBANK memory (reported from Erik Epetrich)
11693         * (pic14emitOverlay): modified to emit a commented overlay segment
11694         directive when no overlay data exist
11695         * (picglue): modified to emit uninitialized data segment
11696         according to udata_section_name
11697         * src/pic/main.c (_pic14_parseOptions): added command line
11698         options --udata-section-name=[name] to override default
11699         udata definition name
11700         * modified _linkCmd and _asmCmd to include compiler passed
11701         arguments via -W option
11702         * src/pic16/main.c: added $l in _asmCmd, changed extension for
11703         object file from '.rel' to '.o' in port->linker structure,
11704         changed size of fptr from 2 to 3 in port structure
11705
11706 2004-01-07  Borut Razem <borut.razem AT siol.net>
11707
11708         * support/scripts/sdcc.nsi: update PATH
11709         * support/scripts/sdcc.ico: craeted
11710
11711 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
11712
11713         * device/include/Makefile.in: fix install
11714         * doc/Makefile: fix install
11715
11716 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11717
11718         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
11719         in bug #860505
11720         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
11721         how the function variable allocation summary is displayed; also
11722         include information about variables allocated to the overlay
11723         segment
11724
11725 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11726
11727         * as/mcs51/lkmain.c: Help about -Y option
11728         * as/mcs51/lkarea.c: Fixed gcc warnings
11729
11730 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
11731
11732         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
11733         fixed warning
11734         * support/valdiag/tests/overflow.c: added
11735         * src/SDCCast.c (decorateType),
11736         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
11737         LEFT_OP (left shift)
11738
11739 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11740
11741         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
11742         (default behaviour).
11743
11744 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11745
11746         A python script to validate compiler diagnostic messages. It can be
11747         used to verify that sdcc complains about bad c source code and
11748         gives a good location of the error.
11749         * support/valdiag/Makefile,
11750         * support/valdiag/valdiag.py,
11751         * support/valdiag/tests/*
11752
11753 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11754
11755         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
11756         * src/SDCCsymt.c (newEnumType),
11757         * src/SDCCsymt.h
11758         * support/Util/SDCCerr.c,
11759         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
11760         enum related bugs.
11761         * support/regression/tests/enum.c: added test for enum values that
11762         require at least 2 bytes of storage.
11763
11764 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
11765
11766         * src/common.h: added ifndef/define/endif macros
11767         around the header file.
11768         Bug reported from Jesus Calvino-Fraga
11769
11770 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
11771
11772         * sdcc.spec: updated
11773         * device/include/Makefile.in: don't install CVS directories
11774         * device/lib/Makefile.in: added removal of CVS directories after install
11775         * doc/Makefile: fixed install, added local_icons
11776         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
11777         * src/mcs51/gen.c (genRightShift): fixed bug #870788
11778         * src/ds390/gen.c (genRightShift): fixed bug #870788
11779         * src/SDCCast.c (decorateType): fixed bug #870781
11780
11781 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
11782
11783         PIC16 port related changes:
11784         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
11785         added variable stackPos,
11786
11787         * gen.c: genCall, assignResultValue: added support for
11788         pushing/retrieving function parameters to/from stack,
11789         genFunction,genEndFunction: setup stack frame for the
11790         generated function,
11791         genAddrOf: will be changed according to bug 863624
11792
11793         * added files genutils.c and genutils.h which contain gen*
11794         debugged and optimised functions extracted from gen.c
11795
11796         * glue.c: added variable 'externs' which holds extern symbols,
11797         pic16emitRegularMap: is modified to properly handle relocatable
11798          symbols under the new scheme,
11799         pic16createInterruptVect: is modified
11800         pic16printPublics: is modified to emit 'global' assembler directives,
11801         added pic16_printExterns to print extern symbols,
11802         pic16glue: initializes stack/frame pointer in the beginning of
11803         the assembly output. Temporary hack, will be corrected later,
11804         because gplink yet does not support stack and SDCC does not
11805         yet support a type of crt0.o object to create the final binary.
11806
11807         * Removed many lines that contain 8051 legacy code.
11808         * The code is finally placed under a 'code' directive.
11809         * Added port specific options.
11810
11811         * _process_pragma: simplified since now we do not need *special*
11812         include file to define SFR registers. But a separate header
11813         will be needed. This will be developed later.
11814         * _pic16_parseOptions: added, parses port specific options:
11815         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
11816         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
11817         --preplace-udata-with=
11818
11819         * _pic16_setDefaultOptions: modified to initialize section names,
11820         but hack is temporarly out of order since it needs improvement.
11821         * _pic16_genAssemblerPreamble: configuration words are emitted by
11822         their address instead of their name. This part is incomplete and
11823         supports only the 18Fxx2 devices. Other devices will emit an error
11824         during assembly since they do not contain the same set of config
11825         registers
11826         * _pic16_genIVT: is modified,
11827
11828         * pcode.c: added definitions for some hardware registers that are needed
11829         for stack support
11830         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
11831         All PCI entries are updated. Now LFSR is supported.
11832         * Removed pic16_pciTRIS is mentioned by mdubuc in source
11833         * added pic16_newpCodeOpLit2 to support instructions with
11834         two literal arguments
11835         * pic16_pCode2str: corrected code that emits assembler instructions
11836         with two literal operands and those that have an access bit modifier
11837         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
11838         this fixes a bug which caused some labels to be lost, when an
11839         assembler directive was added, i.e. banksel,
11840         * pic16_FixRegisterBanking: improved logic that causes the insertion
11841         of bank switching,
11842         * InlineFunction: functions that are called once, are not any more
11843         inlined. This can be a port option in the future,
11844
11845         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
11846
11847         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
11848         hold the corresponding uninitialized symbols,
11849         * pic16_allocProcessorRegister: registers have explicit marked the
11850         accessBank field,
11851         * pic16_allocInternalRegister: registers are explicit marked as
11852         not used,
11853         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
11854         processing list, so bit registers were lost,
11855         *
11856
11857         * ralloc.h: added field 'accessBank' and original symbol operand
11858         in register definition,
11859         * removed the field isMapped from register definition,
11860
11861         ** Several functions have been removed from various sources:
11862         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
11863         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
11864         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
11865         pic16_assignRelocatableRegisters
11866
11867         ** others have been introduced:
11868         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
11869         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
11870
11871 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
11872
11873         * support/scripts/inc2h.pl: changed definition of BIT_AT
11874         to emit 'sbit at' instead of 'bit at'. This was a request.
11875
11876         PIC16 port related preliminary changes:
11877         * gen.c: prefixed function popRegFromString with
11878         pic16_ and all references to it corrected
11879         * pcode.c: all pic16_pc_* hardware registers prefixed
11880         with underscore (_),
11881         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
11882         * ralloc.c: newReg(): when register is REG_SFR then
11883         set address to rIdx,
11884         pic16_allocProcessorRegister(): marks register wasUsed=0
11885         pic16_writeUsedRegs(): added a call to assign processor
11886         registers via pic16_assignFixedRegisters
11887
11888 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11889
11890         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
11891         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
11892         variables in unused register banks.  Also the SSEG is placed
11893         wherever there is enough space for it, and IDATA can be anywhere
11894         in internal RAM.  For now compile using -Wl-Y[stack_size].
11895         The mem file is different for this option as well, since it
11896         makes no sense of talking about DSEG lenght.
11897
11898 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
11899
11900         * src/SDCClrange.c: fixed bug 869095 that caused segfault
11901         in certain cases, e.g. when ROM assignment, patch provided
11902         from Albert den Haan.
11903
11904 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
11905
11906         Many signedness and type propagation fixes:
11907         * src/SDCCicode.c: made geniCodeCast() static
11908         replaced SPEC_ by IS_ (cosmetic)
11909         (operandOperation): fixed div and mod operation
11910         (usualBinaryConversions): added support for promotion of char
11911         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
11912         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
11913         (geniCodeAdd): an array index will stay unsigned, even if promoted
11914         from char to int
11915         (geniCodeArray): ditto
11916         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
11917         * src/SDCCsymt.c (computeType): added more support for char;
11918         promotion of char is selectable by promoteCharToInt, fixed signedness
11919         for all cases
11920         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
11921         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
11922         * src/SDCCval (val*): replaced signedness calculation by
11923         computeType()
11924         rearranged if-branches (cosmetic)
11925         (valShift): added warning W_SHIFT_CHANGED
11926         (valCompare): fixed problem with different types
11927         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
11928         * support/regression/tests/literalop.c: added many cases
11929         * support/regression/tests/ast_constant_folding.c: changed finally to
11930         'unsigned int'
11931         * .version: new year, new version: 2.3.7
11932         * src/SDCCmain.c (main): applied patch #866468
11933         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
11934         provided by Scott Bronson
11935         * doc/sdccman.lyx: updated documentation for sdcdb
11936         updated and added chapter tips
11937
11938 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11939
11940         * src/SDCCsymt.h: missing from yesterday's commits
11941
11942 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11943
11944         * src/SDCC.y (struct_or_union_specifier),
11945         * support/Util/SDCCerr.c,
11946         * support/Util/SDCCerr.h: verify that struct & union tags are used
11947         as declared.
11948
11949 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11950
11951         * src/SDCCglobl.h: missing from yesterday's commits
11952
11953 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11954
11955         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
11956         sft_attributes, struct_declaration, parameter_declaration,
11957         type_name, start_block, declaration_list),
11958         * src/SDCC.lex (check_type): support redefinition of typedef names
11959
11960 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11961
11962         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
11963         aligned xdata arrays. Erik helped me with the if clause.
11964
11965 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11966
11967         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
11968         warning
11969
11970 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11971
11972         * src/SDCCast.h,
11973         * src/SDCCast.c (newAst_),
11974         * src/SDCCicode.h,
11975         * src/SDCCicode.c (ast2iCode, newiCode),
11976         * src/SDCCglobl.h,
11977         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
11978         expr, statement, expression_statement, selection_statement,
11979         iteration_statement, expr_opt, jump_statement): foundation for tracking
11980         sequence points
11981         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
11982         point code too)
11983
11984 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11985
11986         * support/Util/SDCCerr.c,
11987         * src/SDCCast.h,
11988         * src/SDCCast.c (createCase, createDefault, decorateType),
11989         * src/SDCClabel.c (labelUnreach),
11990         * src/SDCC.y (labeled_statement, jump_statement): More improvements
11991         to error messages.
11992         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
11993         (with thanks to Stas Sergeev)
11994         * device/include/time.h,
11995         * device/lib/time.c (CheckTime): suppress unreachable code warning
11996
11997 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11998
11999         * src/SDCCast.c (createIvalCharPtr),
12000         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
12001         bug #753752)
12002         * support/regression/tests/nullstring.c: tests for these two bugs
12003
12004 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12005
12006         * support/Util/SDCCerr.h,
12007         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
12008         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
12009         about storage class and 'at' used inside struct or union
12010         * src/SDCCBBlock.c (iCodeFromeBBlock),
12011         * src/SDCCcse.c (ifxOptimize),
12012         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
12013         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
12014         printIval, emitStaticSeg, emitOverlay),
12015         * src/SDCClabel.c (deleteIfx),
12016         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
12017         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
12018         gatherAutoInit, processParms),
12019         * support/Util/SDCCerr.h,
12020         * support/Util/SDCCerr.c (werrorfl): Support for better error location
12021         reporting for post-parse errors.
12022
12023 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12024
12025         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
12026         implicit casts via union; they don't work on big endian systems
12027         (possible fix for bug #861138)
12028
12029 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12030
12031         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
12032         * src/mcs51/main.c: fixed the fix for bug #737001
12033
12034 2003-12-15  Borut Razem <borut.razem AT siol.net>
12035
12036         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
12037
12038 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12039
12040         * support/makebin/makebin.c: put output in binary mode
12041
12042 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12043
12044         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
12045         xdata and data memory on startup. Set the environment variable
12046         SDCC_NOGENRAMCLEAR to disable this.
12047         * src/mcs51/peephole.def,
12048         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
12049         (allows non-interrupt and interrupt code to safely compete for a resource
12050         without the non-interrupt code having to disable interrupts)
12051
12052 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12053
12054         * src/SDCCicode.c (geniCodeAdd),
12055         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
12056         with valFromType if type might be a pointer and host is big endian).
12057         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
12058         types, not just integer types.
12059         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
12060         multiply defined with mismatching "at" address.
12061
12062 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12063
12064         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
12065         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
12066         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
12067         with embedded nulls (fixed bug #753752)
12068
12069 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12070
12071         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
12072         Apparently this did not see much testing (endless loop)
12073
12074 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12075
12076         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
12077
12078 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12079
12080         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
12081         gracefully handle NULL memmap pointers
12082
12083 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12084
12085         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
12086         instead of deleting the iCode when an operand is volatile
12087         * src/z80/gen.c (genDummyRead),
12088         * src/mcs51/gen.c (genDummyRead),
12089         * src/ds390/gen.c (genDummyRead),
12090         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
12091         not just IC_RIGHT
12092         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
12093         * src/SDCC.y: fixed bug #850420
12094
12095 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12096
12097         Applied z80 i/o port patch from Peter Townson and fixed some operators
12098         to better handle operands in A register.
12099         * device/include/z180.h
12100         * src/SDCC.y
12101         * src/SDCCglue.c
12102         * src/z80/gen.c
12103         * src/z80/gen.h
12104         * src/z80/main.c
12105         * src/z80/peeph-z80.def
12106         * src/z80/peeph.def
12107         * src/z80/z80.h
12108
12109 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12110
12111         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
12112
12113 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12114
12115         * device/lib/hc08/_mullong.c: Removed extra #endif
12116
12117 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12118
12119         * sim/ucsim/hc08.src/inst.cc,
12120         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
12121         carries from x to h
12122         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
12123         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
12124         * device/include/stdarg.h: fixed varargs for hc08
12125         * device/lib/Makefile.in,
12126         * device/lib/hc08/Makefile,
12127         * device/lib/hc08/_mulint.c,
12128         * device/lib/hc08/_mullong.c: fixed some endian problems
12129
12130 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12131
12132         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
12133         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
12134         * device/lib/_gptrget.c,
12135         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
12136
12137 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12138
12139         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
12140         * src/SDCCast.c (astErrors): fixed bug #846007
12141         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
12142
12143 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12144
12145         * src/SDCCast.c (decorateType): disabled a transformation I added in
12146         revision 1.188 (access to fields of a structure at an absolute address);
12147         it breaks with bitfields, extern declarations, and gcse analysis.
12148         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
12149         could be assigned through a pointer, so don't complain.
12150         * src/SDCCast.c (astErrors),
12151         * src/SDCCast.h,
12152         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
12153
12154 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
12155
12156         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
12157         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
12158         output of __config directives, since gpasm now supports them
12159         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
12160         pre-processor macro, i.e. -DMCU=p18f452
12161         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
12162         and modified to handle 'cast' icode similarly to '=' icode
12163         * src/pic16/device.h (typedef struct PIC_device): added field
12164         'extMIface' to indicate that chip has external memory interface
12165         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
12166         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
12167         18F8720
12168
12169 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12170
12171         * src/SDCC.y (pointer): fixed bug #846006
12172         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
12173         * src/SDCCast.c (decorateType): fixed bug #846009
12174         * src/ds390/peeph.def,
12175         * src/ds390/gen.c (genAnd, genOr),
12176         * src/mcs51/peeph.def,
12177         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
12178
12179 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12180
12181         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
12182         * src/SDCCdflow.c
12183         * src/SDCCcse.c
12184         * src/SDCCcse.h
12185         * src/SDCCBBlock.h
12186         * src/SDCCBBlock.c
12187
12188 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
12189
12190         fixed bug #845089
12191         * src/SDCCbitv.h,
12192         * src/SDCCbitv.c: added function to free a bitvector
12193         * src/SDCClrange.h,
12194         * src/SDCClrange.c: added function to recompute the liveranges
12195         * src/avr/ralloc.c,
12196         * src/ds390/ralloc.c,
12197         * src/hc08/ralloc.c,
12198         * src/mcs51/ralloc.c,
12199         * src/pic/ralloc.c,
12200         * src/pic16/ralloc.c,
12201         * src/xa51/ralloc.c,
12202         * src/z80/ralloc.c: recompute the liveranges after register packing
12203
12204 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
12205
12206         * src/SDCCloop.c (newInduction): fixed bug #845630
12207
12208 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12209
12210         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
12211         inadvertantly left behind from my 2003-11-12 change
12212
12213 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12214
12215         Updated headers I neglected to commit yesterday.
12216         * src/SDCClrange.h,
12217         * src/SDCCicode.h
12218
12219 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12220
12221         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
12222         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
12223         * src/SDCCopt.c (eBBlockFromiCode),
12224         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
12225         the creation of the key hash table from the sequencing so it can be used
12226         earlier (for some GCSE bug fixes still pending)
12227
12228 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12229
12230         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
12231         * support/regression/tests/addsub.c: testing genPlus shortcut
12232
12233 2003-11-15  Borut Razem <borut.razem AT siol.net>
12234
12235         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
12236
12237 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12238
12239         * src/SDCCcse.c (cseBBlock): fixed bug #527779
12240         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
12241         ordering is immaterial.
12242         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
12243
12244 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12245
12246         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
12247         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
12248         (SIGSEV) of bug #840381
12249         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
12250         unlink new file before rename if new and old filenames are the same)
12251
12252 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12253
12254         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
12255         uninitialized variables) for the mcs51. Set environment variable
12256         SDCC_GENRAMCLEAR to test.
12257         xdata initialization slightly shorter
12258
12259 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12260
12261         * src/SDCCsymt.h,
12262         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
12263         #838241 & 780691 (basicly the same bug)
12264         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
12265         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
12266
12267 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
12268
12269         * src/SDCCmain.c (linkEdit): "fix" #834252
12270
12271 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12272
12273         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
12274         * src/SDCCast.h,
12275         * src/SDCC.y: fixed bug #819403
12276
12277 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12278
12279         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
12280         the reentrant attribute.
12281         * src/hc08/gen.c (genPackBits): added missing stack readjustment
12282         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
12283         simulation
12284         * src/SDCCast.c (decorateType): fixed bug with storage class not being
12285         updated during pointer dereference; f.e. ~(((char *)1)*) was being
12286         erroneously reduced to a literal.
12287         * src/hc08/ralloc.c (packRegisters, rematStr),
12288         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
12289         some cases
12290
12291 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12292
12293         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
12294         * doc/sdccman.lyx: changed from 'article' to 'book'
12295         * doc/Makefile: readded test_suite_spec and cdbfileformat
12296
12297 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
12298
12299         * device/include/stdlib.h: include malloc.h to comply with ANSI
12300         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
12301
12302 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12303
12304         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
12305         * doc/clean.mk: also remove *.out files
12306         * doc/sdccman.lyx: some additions, larger top/bottom margins
12307
12308 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12309
12310         * src/SDCC.y: fixed bug #837365
12311         * support/regression/tests/bitopcse.c
12312         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
12313         a symbol (might be valop instead)
12314         * device/lib/Makefile.in: added errno.c to HC08SOURCES
12315         * device/lib/clean.mk: added hc08 to the cleaning list
12316
12317 2003-11-04  Borut Razem <borut.razem AT siol.net>
12318
12319         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
12320           made 2003-11-04
12321         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
12322           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
12323           malloc is declared in standard stdlib.h
12324
12325 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12326
12327         * device/lib/hc08/Makefile: need to clean .rel not .o files
12328         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
12329
12330 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12331
12332         * src/port.h,
12333         * src/hc08/main.c,
12334         * src/mcs51/main.c,
12335         * src/ds390/main.c,
12336         * src/z80/main.c,
12337         * src/avr/main.c,
12338         * src/pic/main.c,
12339         * src/pic16/main.c,
12340         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
12341         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
12342         tests (which uses the port's oclsExpense function)
12343         * src/SDCC.y,
12344         * src/SDCCast.c,
12345         * src/SDCCicode.c,
12346         * src/hc08/gen.c,
12347         * src/ds390/gen.c,
12348         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
12349
12350 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12351
12352         * src/SDCCcse.c (ifxOptimize),
12353         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
12354         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
12355         deleting the IFX iCode.
12356         * src/hc08/ralloc.c: reduced unneeded slocs
12357         * src/hc08/gen.c: fixed bug in asmopToBoolean
12358
12359 2003-11-04  Borut Razem <borut.razem AT siol.net>
12360
12361         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
12362           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
12363           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
12364           transferred to configure
12365
12366 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
12367
12368         Use headers defined in the C[++] standards:
12369         * sim/ucsim/gui.src/serio.src/fileio.cc
12370         * sim/ucsim/gui.src/serio.src/frontend.cc
12371         * sim/ucsim/gui.src/serio.src/main.cc
12372         * sim/ucsim/gui.src/serio.src/posix_signal.cc
12373         * support/Util/NewAlloc.c
12374         * as/hc08/lklibr.c
12375         * as/mcs51/lklibr.c
12376         * as/z80/aslist.c
12377         * as/z80/assym.c
12378
12379 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12380
12381         * Added MSVC projects for hc08 assembler and linker:
12382         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
12383         /as/hc08/link_hc08.dsp
12384
12385 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
12386
12387         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
12388
12389 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
12390
12391         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
12392
12393 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12394
12395         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
12396
12397 2003-10-31  Borut Razem <borut.razem AT siol.net>
12398
12399         * support/cpp2/cpplib.h,
12400           support/cpp2/cpplib.c,
12401           support/cpp2/cpplex.c,
12402           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
12403           to switch _asm block preprocessing on / off. Default is
12404           #pragma preproc_asm +
12405
12406 2003-10-31  Borut Razem <borut.razem AT siol.net>
12407
12408         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
12409           when outputting comment blocks (when executed with -C option) and
12410           _asm (SDCPP specific) blocks
12411
12412 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12413
12414         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
12415
12416 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
12417
12418         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
12419
12420 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
12421
12422         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
12423         * src/SDCCast.c (decorateType): fixed bug #832664
12424
12425 2003-10-31  Borut Razem <borut.razem AT siol.net>
12426
12427         * support/cpp2/cpplex.c: fixed for SDCPP:
12428           comments(when executed with -C option) and _asm blocks
12429           were included even if they where in skipped #if block.
12430           Applied solution from GCC cpp 3.3.2
12431
12432 2003-10-31  Borut Razem <borut.razem AT siol.net>
12433
12434         * src/SDCC.lex: sdcc now understands both formats:
12435           '# <line_number> <file_name>' and
12436           '#line <line_number> <file_name>'
12437         * support/cpp2/cppmain.c: sdcpp now generates the standard
12438           '# <line_number> <file_name>' instead of former
12439           '#line <line_number> <file_name>'
12440
12441 2003-10-30  Borut Razem <borut.razem AT siol.net>
12442
12443         * support/cpp2/cpphash.h,
12444         * support/cpp2/cpplib.h
12445         * support/cpp2/cpplex.c,
12446         * support/cpp2/cppmain.c,
12447         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
12448
12449 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12450
12451         Fixed a number of problems revealed by bug #827883.
12452         * src/SDCCloop.c (loopInvariants): Spill location of the
12453         result operand should be recomputed if extracted from
12454         a loop. Also, don't extract assignments of an iTemp
12455         from a literal.
12456         * src/SDCCast.c (isConformingBody): loop reversal should
12457         not occur if the control variable is involved with a
12458         relational operator.
12459
12460 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
12461
12462         * .version: bumped to 2.3.6 to reflect the big improvements
12463         made by Erik and Klaus. Thanks!
12464
12465 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
12466
12467         Replaced the livrange code.
12468         * src/SDCClrange.c: added new LR code
12469         * src/SDCCloop.c,
12470         * src/SDCCBBlock.h: removed remainig parts from old LR code
12471         * src/ds390/ralloc.c,
12472         * src/ds390/gen.c: minor fixes to make it work with new code
12473
12474 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12475
12476         * as/hc08/asm.h,
12477         * as/hc08/lkrloc.c,
12478         * src/hc08/gen.c,
12479         * src/hc08/ralloc.c: Fix various warnings related to the hc08
12480         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
12481         (tweaked fix for bug #818696)
12482
12483 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12484
12485         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
12486
12487 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12488
12489         * src/SDCCmain.c,
12490         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
12491         * src/mcs51/gen.c (gencjneshort),
12492         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
12493         more efficient (per Scott Bronson's suggestion)
12494
12495 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12496
12497         Extended the semantics of the critical keyword to include
12498         individual statements. See RFE #827755 and #799831
12499         * src/SDCC.y
12500         * src/SDCCicode.c
12501         * src/SDCCopt.c
12502         * src/SDCCast.c
12503         * support/Util/SDCCerr.c
12504         * support/Util/SDCCerr.h
12505         * src/mcs51/gen.c
12506         * src/ds390/gen.c
12507         * src/hc08/gen.c
12508
12509 2003-10-19  Borut Razem <borut.razem AT siol.net>
12510
12511         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
12512
12513 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12514
12515         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
12516         Fixed bug #818696
12517         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
12518         and predecrement operand is displayed
12519
12520 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
12521
12522         * src/SDCCval.c (valMinus): fixed bug #826041
12523
12524 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12525
12526         Some hc08 related updates that I missed earlier
12527         * sim/ucsim/stypes.h
12528         * support/regression/ports/hc08/spec.mk
12529
12530 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12531
12532         New target "hc08" for the Motorola 68hc08 family of micros
12533
12534         * configure
12535         * configure.in
12536         * Makefile
12537         * src/hc08/*
12538         * src/SDCCmain.c
12539         * src/port.h
12540         * sim/ucsim/hc08.src/*
12541         * sim/ucsim/configure.in
12542         * src/ucsim/configure
12543         * sim/ucsim/packages_in.mk
12544         * as/hc08/*
12545         * as/Makefile
12546         * device/include/mc68hc908qy.h
12547         * device/lib/hc08/*
12548         * device/lib/Makefile.in
12549         * support/regression/ports/hc08/*
12550         * support/regression/Makefile
12551
12552 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12553
12554         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
12555         regression test
12556         * src/ds390/gen.c (genCast): fixed bug #821957
12557
12558 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
12559
12560         * device/lib/logf.c: "fixed" overlay bug
12561         * support/regression/ports/host/spec.mk: added m library
12562         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
12563         * support/regression/tests/float_trans: added (for Eric)
12564
12565 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
12566
12567         * src/mcs51/gen.c (genCpl): fixed bug
12568         http://sf.net/mailarchive/message.php?msg_id=6263915
12569
12570 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
12571
12572         * src/SDCCast.c (decorateType): added extended constant folding
12573         * src/SDCCsymt.c (computeType): cleanup
12574         * src/SDCCval.c (valShift): minor optimization
12575         * support/regression/tests/ast_constant_folding.c: added
12576
12577 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12578
12579         * src/SDCCmain.c: removed some unintended changes
12580
12581 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12582
12583         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
12584         * src/z80/gen.c: fixed part of bug #817589
12585         * src/SDCCsymt.c (checkFunction): fixed bug #817895
12586
12587 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
12588
12589         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
12590         * src/SDCCcflow.c
12591         * src/SDCCcse.c
12592         * src/SDCCdflow.c
12593         * src/SDCClabel.c
12594         * src/SDCClrange.c
12595         * src/SDCCmem.c
12596         * src/SDCCopt.c
12597         * src/SDCCpeeph.c
12598         * src/SDCCset.c
12599         * src/avr/ralloc.c
12600         * src/ds390/ralloc.c
12601         * src/izt/ralloc.c
12602         * src/mcs51/ralloc.c
12603         * src/pic/ralloc.c
12604         * src/pic16/ralloc.c
12605         * src/xa51/ralloc.c
12606         * src/z80/ralloc.c
12607         * src/z80/gen.c: removed unused label "release:"
12608
12609 2003-10-06  Borut Razem <borut.razem AT siol.net>
12610
12611         * src/SDCC.lex: removed definition of unused variables
12612           save_optimize and save_options
12613
12614 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
12615
12616         * clean.mk: removed '=' in "-maxdepth=1"
12617         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
12618         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
12619
12620 2003-10-06  Borut Razem <borut.razem AT siol.net>
12621
12622         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
12623           my_unput() replaced by unput()
12624
12625 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
12626
12627         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
12628         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
12629         type-punned pointer will break strict-aliasing rules"
12630         Old LR behaviour is again default; Klaus' LR can be choosen by
12631         defining the environment variable LRKLAUS
12632         * src/SDCCBBlock.h
12633         * src/SDCCloop.c
12634         * src/SDCClrange.c
12635         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
12636         * clean.mk: fixed removal of files in bin/CVS/
12637         * device/lib/clean.mk: fixed removal of directories small and large
12638         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
12639         * src/SDCCicode.c,
12640         * src/SDCCval.c: removed superflous test for pedantic
12641
12642 2003-10-05  Borut Razem <borut.razem AT siol.net>
12643
12644         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
12645           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
12646           message "unmatched #pragma SAVE and #pragma RESTORE"
12647
12648 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12649
12650         * doc/sdccman.lyx: various additions and updates (interrupts, inline
12651           assembly, critical functions, atomic, nojtbound)
12652
12653 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
12654
12655         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
12656         * src/SDCCBBlock.h
12657         * src/SDCCloop.c
12658         * src/SDCCloop.h
12659         * src/SDCClrange.c
12660
12661 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12662
12663         * src/z80/gen.h,
12664         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
12665         * src/mcs51/gen.h
12666         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
12667         * src/ds390/gen.h
12668         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
12669         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
12670         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
12671
12672 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12673
12674         * src/z80/gen.c (genRet): fixed bug #524753
12675         * src/z80/gen.c (genCast): fixed internal error on cast from
12676         pointer to long
12677         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
12678         fix for bug #477835 to the z80
12679         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
12680         for tracking iCodes in the peephole optimizer for z80
12681
12682 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12683
12684         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
12685         the other part of bug #814548
12686         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
12687
12688 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
12689
12690         * src/SDCCcse.c: fixed part of bug #814548
12691
12692 2003-09-28  Borut Razem <borut.razem AT siol.net>
12693
12694         * src/asm.c: rewrite of printILine() to use temporary file instead
12695           a pipe
12696         * src/xa51/main.c: commented out declaration of int rewinds
12697
12698 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12699
12700         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
12701
12702 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12703
12704         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
12705         * src/asm.c (printILine): Fixed bug #811015
12706
12707 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12708
12709         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
12710         freeing.
12711
12712 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12713
12714         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
12715         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
12716         to correctly handle general case of AOP_PAIRPTR
12717         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
12718
12719 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12720
12721         * src/mcs51/ralloc.c (fillGaps),
12722         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
12723         register positioning bug)
12724
12725 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
12726
12727         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
12728
12729 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12730
12731         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
12732         genCodePointerGet, genGenPointerGet, genFarPointerSet,
12733         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
12734         (ralloc doesn't intentionally do this now, but perhaps later)
12735         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
12736         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
12737         register positioning bugs (Fixed bug #762602 and #795325)
12738         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
12739         (Fixed bug #808779)
12740         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
12741         lines that --i-code-in-asm generates
12742
12743 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12744
12745         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
12746         trying to fclose a FILE* that was already closed.
12747
12748 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12749
12750         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
12751         of const struct should be treated as if const themselves)
12752
12753 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
12754
12755         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
12756
12757 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12758
12759         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
12760         Unix (/n) and DOS (/r/n) line terminations.
12761
12762 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12763
12764         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
12765         bug #613775
12766
12767 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12768
12769         * src/mcs51/gen.c (genFunction, genEndFunction),
12770         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
12771         and restore of EA so that stack offsets to parameters are
12772         correct when using both critical and reentrant/stack-auto.
12773         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
12774         size (can be triggered in error if sloc is shared between
12775         different sized objects)
12776         * device/include/float.h: fixed macros to explicitly use
12777         unsigned long where needed
12778
12779 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
12780
12781         Feature req. 799831: added code to allow nesting of critical functions
12782         * src/mcs51/gen.c (genFunction, genEndFunction)
12783         * src/ds390/gen.c (genFunction, genEndFunction)
12784
12785 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12786
12787         * src/SDCCsymt.c (sclsFromPtr),
12788         * src/SDCCsymt.h,
12789         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
12790         support for standard C idiom of memory mapped variables; for
12791         example, *((xdata int*)0x1234) = 1 is now internally equivalent
12792         to xdata int at 0x1234 tempvar = 1.
12793         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
12794         provided by Akiya ISHIDA
12795
12796 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
12797
12798         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
12799         * src/SDCCval.c (constVal): added reduction from int to char
12800         * src/SDCCval.c (valMult, valDiv): fixed sign handling
12801         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
12802         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
12803         to ignore the sign
12804         * support/regression/tests/shifts.c: fixed
12805
12806 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12807
12808         * src/z80/gen.c (genXor): Fixed bug #805445
12809
12810 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12811
12812         Fixed bug #621531 (const & volatile confusion in the type chain).
12813         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
12814         refer to the const or volatile state of the pointer itself.
12815
12816         * src/SDCCast.c
12817         * src/SDCCglue.c
12818         * src/SDCCicode.c
12819         * src/SDCCsymt.c
12820         * src/SDCCval.c
12821         * src/SDCC.y
12822         * src/SDCCsymt.h
12823         * src/pic/gen.c
12824         * src/pic/ralloc.c
12825         * src/pic16/gen.c
12826         * src/pic16/ralloc.c
12827         * support/regression/tests/const.c
12828
12829 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12830
12831         When checking for duplicated modules, use absolute paths
12832         instead of relative paths.  Files changed:
12833
12834         * as/mcs51/lklib.c
12835         * link/z80/lklib.c
12836
12837 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12838
12839         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
12840
12841 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12842
12843         * device/include/string.h: added size_t typedef, changed
12844         prototypes to use size_t, eliminated separate reentrant and
12845         non-reentrant declarations, added _memmove declaration
12846         * device/lib/_memcpy.c: changed to use size_t instead of int,
12847         changed /4 to >>2 to avoid division library call
12848         * device/lib/_memcmp.c,
12849         * device/lib/_memset.c,
12850         * device/lib/_strncat.c,
12851         * device/lib/_strncpy.c,
12852         * device/lib/_strncmp.c: changed to use size_t instead of int
12853         * device/lib/_memmove.c: new file (fixed bug #772294)
12854         * device/lib/Makefile.in: added _memmove.c
12855         * device/lib/z80/asm_strings.s: fixed bug #772290
12856         * support/regression/tests/bitfields.c: attempt to fix host assertion
12857         failure on amd64-unknown-linux2.2
12858
12859 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12860
12861         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
12862         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
12863         * as/z80/asmain.c (main): fixed bug #801766
12864
12865 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
12866
12867         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
12868         compilers
12869
12870 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12871
12872         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
12873         reported in bug #800609
12874
12875 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
12876
12877         * Top header beautifications in src/pic16 directory:
12878           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
12879           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
12880           pcoderegs.h, ralloc.c, ralloc.h
12881         * main.c: added top header and GPL license notice
12882         * pcode.c: fixed the if-conditional warning
12883
12884 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
12885
12886         * device/lib/_mullong.c: replaced int by short for gcc
12887
12888 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12889
12890         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
12891         and JUMPTABLE iCodes properly now (worked by accident before)
12892         * src/mcs51/gen.c (leftRightUseAcc),
12893         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
12894         iCode properly now. Use getSize instead of nRegs since a & b
12895         aren't part of the nRegs tally.
12896
12897 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
12898
12899         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
12900         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
12901           before instructions that use the _STATUS register
12902
12903 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
12904
12905         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
12906         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
12907         fetching of the pointer
12908         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
12909         copied from genNearPointerSet()
12910         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
12911         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
12912         If they pop r0/r1 they must be called in the opposite order than aopOp().
12913         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
12914         (resp. --stack-auto), prepared for --xstack
12915
12916 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12917
12918         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
12919
12920 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
12921
12922         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
12923         these ports have their own __sdcc_external_start()
12924
12925 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
12926
12927         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
12928         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
12929         type for bits was changed. It resulted in bit variables becoming
12930         global, which is not permitted in PIC 14 assembly output.
12931
12932 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12933
12934         * doc/sdccman.lyx: various additions and updates. Rearranged sections
12935
12936 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12937
12938         Z80 and MCS51 linkers complaint if a public symbol is defined
12939         in more than one library module:
12940
12941         * as/mcs51/lklib.c
12942         * link/z80/lklib.c
12943         * as/mcs51/Makefile.in
12944
12945 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12946
12947         A few small changes that speed up the peephole optimizer.
12948
12949         * src/SDCCpeeph.c
12950
12951 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12952
12953         Try to make the peephole optimizer smarter by maintaining
12954         an association between the assembly source code and the
12955         iCodes that originated them. Put this information to use
12956         with a new peephole rule condition "notVolatile" so that
12957         the rules can be aggressive yet still safe.
12958
12959         * src/SDCCpeeph.c
12960         * src/SDCCpeeph.h
12961         * src/mcs51/gen.c
12962         * src/mcs51/peeph.def
12963
12964 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12965
12966         Fixed bug #741761
12967
12968         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
12969         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
12970         if the left or right operand symbols have the accuse flag set.
12971
12972 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12973
12974         Changed the type of the result of the ! (NOT) operator to char;
12975         previously it returned the same type as the source. This allows
12976         us to eliminate all the genFloatNot functions (all of its target
12977         implementations were very buggy) since !float can use the same
12978         code as !long now.
12979
12980         * src/SDCCicode.c (ast2iCode): ! returns char
12981         * src/mcs51/gen.c (genNot, genNotFloat),
12982         * src/ds390/gen.c (genNot, genNotFloat),
12983         * src/z80/gen.c (genNot, genNotFloat),
12984         * src/pic/gen.c (genNot, genNotFloat),
12985         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
12986
12987 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
12988
12989         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
12990         1. Interrupt would not compile properly. Ensure PCLATH register is saved
12991            during interrupts. Ensure WSAVE is located at a shared bank address.
12992         2. Fixed page selection in some places
12993         3. Fixed BTFSS/C to where necessary use registers directly and not simply
12994            the registers name strings.
12995         4. Fixed "signed / unsigned compare" compiler warnings.
12996         5. The PIC port manages its own allocation of the general purpose
12997            registers, but makes no attempt to reuse them. As a result when
12998            compiling it soon runs out of general purpose registers. Some
12999            additional code was added to the files pcode.c and device.c to walk
13000            through the function call tree and rename the registers so that they
13001            get reused.
13002
13003         * src/pic/device.c
13004         * src/pic/gen.c
13005         * src/pic/glue.c
13006         * src/pic/pcode.c
13007         * src/pic/pcode.h
13008         * src/pic/ralloc.c
13009         * src/pic/ralloc.h
13010         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
13011         genPlus() & genMinus() when the result is the same as left or right
13012
13013 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13014
13015         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
13016
13017 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13018
13019         Made bitfield a distinct type from bit so that bitfields
13020         convert as per ANSI C and bits retain their traditional
13021         boolean style behaviour. Implemented bitfield support in
13022         the z80 port.
13023
13024         * src/SDCCsymt.h,
13025         * src/SDCCsymt.c,
13026         * src/SDCCast.c,
13027         * src/cdbFile.c,
13028         * src/mcs51/gen.c,
13029         * src/ds390/gen.c: bit v bitfield split
13030         * src/z80/gen.c: New support for bitfields
13031         * support/regression/tests/bitfields.c: reenabled z80,
13032         added more tests
13033
13034 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13035
13036         Rules 246.x, 247.x relate to bitfields, the others speed up
13037         access to xdata mapped I/O devices.
13038
13039         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
13040
13041 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13042
13043         Cleaned up genPackBits and genUnpackBits and added two helper
13044         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
13045         for literal assignments in genPackBits (thanks to Frieder for
13046         reminding me).
13047
13048         * src/mcs51/gen.c
13049         * src/ds390/gen.c
13050
13051 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13052
13053         Fixed bug #748310 (pointer to function type mishandled when the
13054         function name is omitted). Also fixed a SIGSEGV when a function
13055         attribute (reentrant, etc) is used on a non-function or on a
13056         function but misplaced before the parameter list.
13057
13058         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
13059         bug #748310
13060         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
13061         * support/Util/SDCCerr.h,
13062         * support/Util/SDCCerr.c: Added func attr misuse error msg
13063
13064 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
13065
13066         Fixed bug #787649 by anonymous
13067         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
13068         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
13069
13070 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13071
13072         Fixed numerous bitfield problems.
13073
13074         * src/SDCC.y: More bitfield related error checking
13075         * src/SDCCsymt.h,
13076         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
13077         * support/Util/SDCCerr.h,
13078         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
13079         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
13080         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
13081         * support/regression/tests/bitfields.c: tests added
13082
13083 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13084
13085         Made the constant following the "interrupt" keyword optional. If
13086         omitted, the function will not automatically be given an entry
13087         in the interrupt vector table (similar to #pragma NOIV, but
13088         less syntacticly kludgy). The interrupt number is also now
13089         range checked. Also fixed a bug in the high order bit example
13090         in the manual.
13091
13092         * src/SDCC.y
13093         * src/SDCCmem.c
13094         * src/SDCCglue.c
13095         * src/SDCCsymt.h
13096         * support/Util/SDCCerr.c
13097         * support/Util/SDCCerr.h
13098         * doc/sdccman.lyx
13099
13100 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
13101
13102         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
13103         * src/SDCCicode.c (operandOperation): rewritten some ops
13104         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
13105         * src/SDCCsymt.c (computeType): literals are handled the same way as any
13106         other type
13107         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
13108         be re-activated by defining REDUCE_LITERALS)
13109         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
13110         unsigned, but are signed by default
13111         * src/SDCCval.c (constVal): rearranged
13112         * src/SDCCval.c (valMod): preliminary fix
13113         * src/SDCCval.c (valCastLiteral): use TYPE_* types
13114         * support/regression/literalop.c: added, work in progress
13115
13116 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13117
13118         Generate warnings for useless declarations like "char data;"
13119         that don't do what new users expect.
13120
13121         * src/SDCC.y
13122         * support/Util/SDCCerr.h
13123         * support/Util/SDCCerr.c
13124
13125 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
13126
13127         * src/SDCCval.c (valMult): fix overflow detection of negative int
13128
13129 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13130
13131         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
13132
13133         Changes to support big endian targets:
13134
13135         * src/ports.h
13136         * src/SDCCglue.c
13137         * src/avr/main.c
13138         * src/ds390/main.c
13139         * src/izt/i186.c
13140         * src/mcs51/main.c
13141         * src/pic/main.c
13142         * src/pic16/main.c
13143         * src/xa51/main.c
13144         * src/z80/main.c
13145
13146 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
13147
13148         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
13149         * device/lib/time.c: fixed warning "integer overflow in expression"
13150
13151 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
13152
13153         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
13154         * src/SDCCval.c (constVal): changed default to signed; hex and octal
13155         constants are unsigned; added recognition of "u" flag for unsigned
13156         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
13157         * src/SDCCval.c (valDiv, valMod): fixed signdness
13158         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
13159         signedness of modulo, left and right shift
13160         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
13161         * support/Util/SDCCerr.h: added warning W_INT_OVL
13162         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
13163         * src/SDCCast.c (ast_print): improved output of constants
13164
13165 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13166
13167         Fixed some warnings when building with MSVC:
13168
13169         * as/mcs51/asdata.c
13170         * as/z80/asdata.c
13171         * as/mcs51/asm.h
13172         * as/z80/asm.h
13173         * link/z80/aslink.h
13174         * link/z80/lkdata.c
13175         * link/z80/lkeval.c
13176         * link/z80/lkgb.c
13177         * link/z80/lkihx.c
13178         * link/z80/lks19.c
13179         * link/z80/lksym.c
13180         * support/cpp2/cpplib.c
13181         * src/ds390/gen.c
13182         * src/mcs51/gen.c
13183
13184 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
13185
13186         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
13187
13188 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13189
13190         * support/librarian/clean.mk: Do not remove Makefile.
13191         * support/librarian/Makefile: added.
13192
13193 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13194
13195         Added librarian to MSVC build:
13196         * all.dsp
13197         * sdcc.dsw
13198         * support/librarian/librarian.dsp
13199
13200         'configure' not needed for librarian, removed:
13201         * support/librarian/configure
13202         * support/librarian/configure.in
13203         * support/librarian/config_in.h
13204         * support/librarian/Makefile.in
13205
13206         Hopefully these ones built the librarian and the rest of sdcc properly:
13207         * Makefile
13208         * Makefile.common.in
13209
13210         Messed up 'configure', so revert to previous version:
13211         * configure
13212         * configure.in
13213
13214 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
13215
13216         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
13217         there, while the mantissa of a double is "only" 53 bits wide.
13218
13219 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13220
13221         Adding sdcclib to the build.  MSVC project coming soon.
13222         Files added/changed:
13223
13224         * support/librarian/clean.mk
13225         * support/librarian/configure
13226         * support/librarian/configure.in
13227         * support/librarian/config_in.h
13228         * support/librarian/Makefile.bcc
13229         * support/librarian/Makefile.in
13230         * support/librarian/sdcclib.c
13231         * Makefile.bcc
13232         * Makefile
13233         * Makefile.common.in
13234         * configure
13235         * configure.in
13236
13237 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13238
13239         Linker now complaints if linked modules have conflicting options, for
13240         example, one compiled using --model-large and another one compiled with
13241         --model-small.  The following files were modified:
13242
13243         * as/mcs51/asdata.c
13244         * as/mcs51/aslink.h
13245         * as/mcs51/asm.h
13246         * as/mcs51/asmain.c
13247         * as/mcs51/asout.c
13248         * as/mcs51/i51pst.c
13249         * as/mcs51/lkdata.c
13250         * as/mcs51/lklibr.c
13251         * as/mcs51/lkmain.c
13252         * as/z80/asdata.c
13253         * as/z80/asm.h
13254         * as/z80/asmain.c
13255         * as/z80/asout.c
13256         * as/z80/z80pst.c
13257         * link/z80/aslink.h
13258         * link/z80/lkdata.c
13259         * link/z80/lklibr.c
13260         * link/z80/lkmain.c
13261         * src/SDCCglue.c
13262
13263 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13264
13265         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
13266         as/mcs51/lklibr.c: Generate a warning when a library is not found.
13267
13268 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
13269
13270         * src/z80/mappings.i: fix _mul[us][int,long] entries
13271
13272 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13273
13274         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
13275
13276 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
13277
13278         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
13279         * support/regression/tests/bitopcse.c: added
13280         fixed warning:
13281         * src/avr/gen.c:
13282         * src/pic/gen.c:
13283         * src/pic16/gen.c:
13284         * src/z80/gen.c:
13285         * src/xa51/gen.c:
13286
13287 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13288
13289         added support for new library format to z80, gbz80 linkers:
13290         *link/z80/aslink.h
13291         *link/z80/lklex.c
13292         *link/z80/lklib.c
13293         *link/z80/lklist.c
13294
13295 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
13296
13297         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
13298         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
13299
13300 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
13301
13302         added DUMMY_READ_VOLATILE:
13303         * src/SDCC.y:
13304         * src/avr/gen.c:
13305         * src/xa51/gen.c:
13306         * src/z80/gen.c:
13307         * src/pic/gen.c:
13308         * src/pic16/gen.c:
13309         * src/mcs51/gen.c:
13310         * src/ds390/gen.c:
13311         * src/SDCCcse.c (algebraicOpts): many improvements
13312         * src/SDCCcse.h: removed algebraicOpts()
13313         * src/SDCCicode.c (picDummyRead): added
13314
13315 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13316
13317         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
13318         "Insufficient space in data memory".
13319
13320 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13321
13322         * src/mcs51/gen.c: fixed bug #771358
13323         * src/z80/gen.c: fixed bug #759087
13324
13325 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
13326
13327         * src/pic16/glue.c: minor cleanup by Vangelis
13328
13329 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13330
13331         * device/include/regc515c.h: fixed #758477
13332         * device/lib/_gptrget.c: saving some cycles in generic pointer get
13333         * device/lib/_gptrput.c: saved a few bytes
13334         * my tab spacing is 8, yours too?)
13335         * device/lib/_ser.c: process RX bytes earlier than TX bytes
13336         * device/lib/serial.c: process RX bytes earlier than TX bytes
13337         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
13338
13339 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
13340
13341         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
13342
13343 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13344
13345     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
13346
13347 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
13348
13349         * device/lib/Makefile.in: bad fix, reverted to 1.43
13350
13351 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
13352
13353         * device/lib/Makefile.in: added missing z80 object files
13354
13355 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
13356
13357         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
13358         pic16 progress by Vangelis:
13359         * src/SDCCglobl.h:
13360         * src/SDCCmain.c:
13361         * src/pic/Makefile:
13362         * src/pic:
13363         * pic/Makefile:
13364         * pic16/device.c:
13365         * pic16/device.h:
13366         * pic16/gen.c:
13367         * pic16/gen.h:
13368         * pic16/genarith.c:
13369         * pic16/glue.c:
13370         * pic16/main.c:
13371         * pic16/pcode.c:
13372         * pic16/pcode.h:
13373         * pic16/pcodepeep.c:
13374         * pic16/peeph.def:
13375
13376 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13377
13378     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
13379
13380 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13381
13382     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
13383     added gbz80 build to MSVC project.
13384     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
13385     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
13386     from 8051 stuff and setup so it links using a .lnk file.
13387
13388 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13389
13390     * support/librarian/sdcclib.c: sdcc librarian.
13391     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
13392     with sdcclib.
13393
13394 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13395
13396     * as/mcs51/lkmain.c: properly handle extensions in function afile.
13397
13398 2003-07-02  Borut Razem <borut.razem AT siol.net>
13399
13400         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
13401         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
13402         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
13403         src/xa51/main.c, src/z80/main.c:
13404         virtualization of glue() function: each port has it's own glue function,
13405         which is accessed by do_glue function pointer in PORT.general structure
13406
13407 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
13408
13409         * DS800C400 fun, improved ROM interface and tinibios.
13410
13411 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
13412
13413         * More support for DS80C400. Now includes beginning of interface to ROM.
13414
13415 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
13416
13417         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
13418
13419 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13420
13421         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
13422
13423 2003-06-19  Borut Razem <borut.razem AT siol.net>
13424
13425         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
13426
13427 2003-06-19  Borut Razem <borut.razem AT siol.net>
13428
13429         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
13430         fixed Z80 port - crt0.o: cannot open.
13431
13432 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
13433
13434         * support/Util/MySystem.c (merge_command): revert bad fix
13435
13436 2003-06-18  Borut Razem <borut.razem AT siol.net>
13437
13438         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
13439
13440 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13441
13442         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
13443         option --use-stdout sends errors to stdout instead of stderr.
13444
13445 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
13446
13447         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
13448
13449 2003-06-15  Borut Razem <borut.razem AT siol.net>
13450
13451         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
13452         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
13453         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
13454         fixed width array of pointers replaced with sets;
13455         multiple include and lib paths ared transferred to preprocessor and linker
13456         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
13457         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
13458         fixed width array of pointers
13459         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
13460         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
13461         fixupPath(), getPathDifference()
13462         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
13463         fixed width array of pointers
13464
13465 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
13466
13467         * src/pic16/ralloc.c: fix warnings
13468         * src/pic16/pcode.c: fix warning
13469
13470 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
13471
13472          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
13473         know all the details, but essentially this set of changes enable
13474         the pic16 port to generate movff instructions and generate assembler
13475         directives,
13476         * src/SDCCmain.c:
13477         * src/pic16/gen.c:
13478         * src/pic16/glue.c:
13479         * src/pic16/pcode.c:
13480         * src/pic16/device.c:
13481         * src/pic16/main.c:
13482         * src/pic16/pcode.h:
13483         * src/pic16/pcoderegs.c:
13484         * src/pic16/ralloc.c:
13485         * src/pic16/ralloc.h:
13486
13487 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13488
13489         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
13490         added option --vc, so sdcc errors and warnings are compatible with
13491         Microsoft Visual Studio.
13492
13493 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13494
13495         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
13496           device/lib/libfloat.lib: added atof function.
13497
13498 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
13499
13500         * doc/sdccman.lyx: updated to Lyx 1.3
13501         * doc/cdbfileformat.lyx: updated to Lyx 1.3
13502         * doc/test_suite_spec.lyx: updated to Lyx 1.3
13503         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
13504
13505 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
13506
13507         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
13508
13509 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13510
13511         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
13512           additions to the "related tools/documentation" section
13513
13514 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
13515
13516         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
13517
13518 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
13519
13520         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
13521         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
13522
13523 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
13524
13525         * doc/sdccman.lyx: fix double dash and other minor things
13526         * doc/Makefile: fix double dash
13527
13528 2003-05-28  Karl Bongers(patches from Martin Helmling)
13529         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
13530           condition and ignore commands.
13531
13532 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13533
13534         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
13535           is in parts still quite out of date, I did changes as far as I felt makes sense
13536           for a non-native english speaker.
13537           Please feel free to add to the manual or to correct my changes.
13538         * doc/Makefile: undid touching the date of intermediate tex files.
13539
13540 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13541
13542         * doc/sdccman.lyx: Manual has an index now
13543
13544 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
13545
13546         Finalize muluint/mulsint and mululong/mulslong merging:
13547         * device/lib/_mulint.c
13548         * device/lib/_mullong.c
13549         * device/lib/gbz80/mul.s
13550         * device/lib/gbz80/stubs.s
13551         * device/lib/z80/mul.s
13552         * device/lib/z80/stubs.s
13553         * src/SDCCsymt.c (initCSupport)
13554
13555 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13556
13557         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
13558         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
13559           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
13560           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
13561           instead of /Zm500.
13562
13563 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13564
13565         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
13566           the regression tests I'm not brave enough to enable 245.b, 245.c
13567         * doc/sdccman.lyx: added latex preamble for hyperref package.
13568           Using pdflatex this will give you a hyperlinked pdf file with
13569           bookmarks. (prepend '%' before /usepackage if this breaks something)
13570
13571 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13572
13573          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
13574
13575 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
13576
13577         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
13578
13579 2003-05-21    <johan AT balder>
13580
13581         * src/SDCCglue.c (printIval): fixed bug #739934
13582
13583 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
13584
13585         Applied patch from bug 737905 (renamed yylineo to mylineno):
13586         * src/altlex.c
13587         * src/SDCCast.c
13588         * src/SDCglobl.h
13589         * src/SDCC.lex
13590         * src/SDCCsymt.c
13591         * src/SDCCval.c
13592         * src/pic16/pcode.c: Cleaned warnings
13593         * src/pic16/pcodeflow.c: Cleaned warnings
13594         * src/pic16/pcoderegs.c: Cleaned warnings
13595
13596 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
13597
13598         * src/pic16/pcode.c: Cleaned warnings
13599         * src/pic16/pcodepeep.c: Cleaned warnings
13600         * src/pic16/ralloc.c: Cleaned warnings
13601
13602 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
13603
13604         * doc/sdccman.lyx: fixed bug 739745
13605         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
13606
13607 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
13608
13609         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
13610         it can be defined with CFLAGS when running configure
13611         * src/SDCCmain.c: fixed compiling + linking with object files
13612
13613 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
13614
13615         * configure.in: configure for pic16 port,
13616             added --disable-pic16-port
13617         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
13618         * src/SDCCmain.c: linkOptions is changed to set *,
13619             added if/endif conditional macros to remove options help
13620             messages from optionsTable when a port is not configured, added
13621             support for the PIc16 port in the ports table, when executing
13622             the compiler with no port specified on command line, a default
13623             port is selected with the new macro DEFAULT_PORT which is
13624             defined in port.h, in setDefaultOptions() linkOptions is removed
13625             from initialization assignment, since now it is a set,
13626             parseCmdLine uses setParseWithComma for linkOptions, in
13627             linkEdit() linkOptions are accessed with new function indexSet()
13628             which returns the i'th item of a set variable. See SDCCset.c, in
13629             linkEdit() when calling buildCmdLine(), added linkOptions as
13630             last argument. Now users can pass arguments to gplink via the
13631             -Wl option, main() uses pic16glue() to glue up pic16 programs
13632         * src/SDCCpeeph.c: various changes to support pic16
13633         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
13634             return the i'th item of the set
13635         * src/SDCCset.h: added function prototype for indexSet()
13636         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
13637         * src/clean.mk: added pic16 in CLEANALLPORTS variable
13638         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
13639             added macro DEFAULT_PORT
13640         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
13641         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
13642             generated
13643         * src/pic16/glue.c: commented out some error producing lines
13644         * src/pic16/main.c: __config directives are commented out to stop
13645             gpasm complaining and test the linkage with gplink, _linkCmd and
13646             _asmCmd changed to be more gplink and gpasm friendly
13647         * src/pic16/peeph.def: peep rule 3 is commented out, since it
13648             produced an error when parsed, peep rule 12 is added to utilize
13649             movff, but it is commented out since the pCode does not support
13650             yet a command with 2 address arguments
13651
13652 2003-05-18    <johan AT balder>
13653
13654         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
13655         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
13656 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
13657
13658         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
13659   Added feature to script commands from file.
13660
13661 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
13662
13663         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
13664         * src/SDCCutil.c: include ctype.h for win32
13665
13666 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
13667
13668         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
13669
13670 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
13671
13672         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
13673   Fixed so you can set breakpoints prior to run, run does not stop
13674   on entry now.  Add tbreak.  Other enhancements and fixes for use
13675   with ddd.
13676
13677 2003-05-12  Borut Razem <borut.razem AT siol.net>
13678
13679         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
13680
13681 2003-05-11  Borut Razem <borut.razem AT siol.net>
13682
13683         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
13684         the path of bin directory, so that PATH is the only env. variable, which has to be set
13685         in case of standard installation.
13686         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
13687         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
13688         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
13689
13690 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
13691
13692         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
13693         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
13694         temp files are in the port dir; clean the gen/test directory when
13695         generating new test.c
13696         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
13697         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
13698         * support/regression/tests/zeropad.c: added
13699
13700 2003-05-09    <johan AT balder>
13701
13702         * src/SDCCglue.c: fixed bug #597940
13703
13704 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
13705
13706         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
13707   cache sfr, optimize next,step, fix off by one sourceline,
13708   support ddd list function.
13709         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
13710
13711 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
13712
13713         * support/regression/HTMLgen.py: added compare_s2f()
13714         * support/regression/Makefile: redo 1.27
13715         * support/regression/generate-cases.py: redo 1.5
13716
13717 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
13718
13719         * support/regression/tests/float.c: workaround 33 bit hex constant
13720         * support/regression/tests/simplefloat.c: fix division for host
13721
13722 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
13723
13724         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
13725         that tame's the PIC's over-aggressive optimizer.
13726
13727 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13728
13729          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
13730          support for MSVC.
13731
13732 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
13733
13734         Initial support for DS80C400. "Hello world" runs on TINIm400
13735         (with polled I/O).
13736
13737 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
13738
13739          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
13740          * Some notes on ddd usage added in debugger/README
13741          Martin Helmling adding more features and fixes for ddd GUI debugger.
13742          Code added for nexti, stepi, up, down, and other adjustments.
13743
13744 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
13745
13746         * src/pic/pCodepeep.c non-wildcard asmops are now handled
13747         * src/pic/peeph.def Added two rules to optimize carry manipulation
13748         * src/pic/* removed debug printfs
13749
13750 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
13751
13752         * debugger/mcs51/cmd.c: added header newalloc.h
13753
13754 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
13755
13756         * as/Makefile: new EXEEXT
13757         * as/z80/Makefile: remove trailing slash of BUILDIR
13758         * as/z80/clean.mk: new EXEEXT
13759         * Makefile.common.in: add to CFLAGS (and others), don't replace it
13760         * support/cpp2/Makefile.in: new EXEEXT
13761         * src/pic/glue.c (pic14emitRegularMap): fixed warning
13762
13763 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
13764
13765         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
13766         EXEEXT was introduced to fix all related problems with targets
13767         "clean", "install" and "uninstall"; a couple of further flaws
13768         especially with "clean" have been fixed too
13769         * as/mcs51/Makefile.in
13770         * as/mcs51/clean.mk
13771         * as/z80/Makefile
13772         * Makefile
13773         * clean.mk
13774         * debugger/mcs51/Makefile.in
13775         * debugger/mcs51/clean.mk
13776         * link/z80/Makefile
13777         * link/z80/Makefile.in
13778         * link/z80/clean.mk
13779         * link/Makefile
13780         * packihx/Makefile.in
13781         * packihx/clean.mk
13782         * sim/ucsim/Makefile
13783         * sim/ucsim/clean.mk
13784         * sim/ucsim/avr.src/Makefile.in
13785         * sim/ucsim/avr.src/clean.mk
13786         * sim/ucsim/s51.src/Makefile.in
13787         * sim/ucsim/s51.src/clean.mk
13788         * sim/ucsim/xa.src/Makefile.in
13789         * sim/ucsim/xa.src/clean.mk
13790         * sim/ucsim/z80.src/Makefile.in
13791         * sim/ucsim/z80.src/clean.mk
13792         * sim/ucsim/main_in.mk
13793         * sim/ucsim/packages_in.mk
13794         * sim/ucsim/gui.src/Makefile.in
13795         * sim/ucsim/gui.src/serio.src/Makefile.in
13796         * sim/ucsim/gui.src/serio.src/clean.mk
13797         * src/Makefile.in
13798         * src/clean.mk
13799         * support/cpp2/Makefile.in
13800         * support/cpp2/clean.mk
13801         * support/makebin/Makefile
13802         * support/makebin/clean.mk
13803         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
13804         * doc/sdccman.lyx: --program-suffix no longer needed
13805
13806 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
13807
13808          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
13809          Martin Helmling added support for ddd GUI debugger.
13810          Code added to display assembly, set variables, and other commands
13811          to interface to ddd.
13812
13813 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
13814
13815         * as/Makefile: fix target clean
13816         * as/clean.mk: fix target clean
13817         * as/z80/clean.mk: fix target clean
13818
13819 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
13820
13821         * Makefile.common.in: added  AT EXEEXT AT
13822         * configure.in: removed all mingw32 stuff
13823         * configure: rebuilt from configure.in
13824         * doc/sdccman.lyx: updated section "installation"
13825         * support/scripts/sdcc_mingw32: adapted to configure
13826         * support/scripts/sdcc_cygwin_mingw32: added
13827
13828 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
13829
13830         * src/pic Added object file support for the PIC port
13831         * src/pic Applied patch from Craig Franklin (this started the object file support)
13832         * src/regression Updated the PIC regression tests for object files
13833
13834 2003-04-20  Borut Razem <borut.razem AT siol.net>
13835
13836         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
13837           lklex.c: In function `getfid':
13838           lklex.c:203: warning: array subscript has type `char'
13839         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
13840           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
13841         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
13842           stack handling macros
13843
13844 2003-04-19  Borut Razem <borut.razem AT siol.net>
13845
13846         * "handling space characters in file path" task:
13847         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
13848         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
13849         * support/Util/MySystem.h: make it self-sufficient
13850         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
13851           src/z80/main.c, sdcc/as/mcs51/lklex.c:
13852           handling space characters in file path
13853         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
13854           (it will be used by assemblers, which have their own includes, e.g. gpasm)
13855         * support/Util/MySystem.c: handling space characters in executable's path
13856
13857 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
13858
13859         * as/z80/Makefile: fix permanent rebuild of z80
13860         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
13861         * support/regression/tests/bitfields.c: added Johan's bitfields.c
13862
13863 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
13864
13865         * src/SDCCopt.c: add special case optimization to replace modulo by
13866           a power of two with a bitwise AND.
13867
13868 2003-04-18    <johan AT balder>
13869
13870         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
13871
13872 2003-04-17    <johan AT balder>
13873
13874         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
13875         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
13876
13877 2003-04-13  Borut Razem <borut.razem AT siol.net>
13878
13879         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
13880         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
13881           fixed mingw problem in adl_NORMALIZE_PATH
13882
13883 2003-04-12  Borut Razem <borut.razem AT siol.net>
13884
13885         * fixed "#pragma SAVE/RESTORE can not be nested":
13886         * src/SDCC.lex: reworked pragma handling functions
13887         * sdcc/src/SDCCglobl.h: reworked stack handling macros
13888         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
13889
13890 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
13891
13892         * src/SDCCutil.c (pathEquivalent): defined but not used
13893         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
13894         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
13895         * configure: rebuilt from configure.in
13896         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
13897         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
13898         * device/include/Makefile.in: replace sdcc_datadir
13899         * device/lib/Makefile.in: replace sdcc_datadir
13900         * Makefile.common.in: add LDFLAGS from configure
13901         * packihx/Makefile.in: use LDFLAGS
13902         * src/Makefile.in: use LDFLAGS
13903         * support/cpp2/Makefile.in: add LDFLAGS from configure
13904         * support/makebin/Makefile: use LDFLAGS
13905         * .version: bumped version number to 2.3.5
13906
13907 2003-04-12  Borut Razem <borut.razem AT siol.net>
13908
13909         * completed "different paths" task:
13910         * src/SDCCmacro.c: fixed bug in handling quotes
13911         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
13912         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
13913
13914 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
13915
13916         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
13917
13918 2003-04-11 kevin Vigor <kevin AT vigor.nu>
13919
13920         * ds390/gen.c ds390/peeph.def: fix bug 706781
13921
13922 2003-04-11  Borut Razem <borut.razem AT siol.net>
13923
13924         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
13925
13926 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
13927
13928         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
13929         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
13930          set - this bit used to not be set...).
13931         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
13932           bad code in PIC Port
13933         * src/regression/and2.c added to test bug 609268
13934         * src/regression/Makefile added and2.c to regression test
13935
13936
13937 2003-04-08    <johan AT CP255758-A>
13938
13939         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
13940         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
13941         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
13942
13943 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
13944
13945         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
13946         fix bug #487815
13947         * support/cpp2/Makefile.in: fix bug #487815
13948         * configure: rebuilt from configure.in
13949         * Makefile.common.in: docdir changed, new path suffixes
13950         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
13951         * sdcc_vc_in.h: reflect changes from sdccconf.h
13952         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
13953         * src/SDCCutil.h: remove BINDIR hack
13954         * doc/sdccman.lyx: update new path hierarchy
13955
13956 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
13957
13958         * src/SDCCpeeph.c: added okToRemoveSLOC test
13959
13960 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
13961
13962         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
13963
13964 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
13965
13966         * src/SDCCpeeph.c: added labelIsReturnOnly test
13967         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
13968
13969 2003-04-05    <johan AT balder>
13970
13971         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
13972         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
13973         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
13974         * src/SDCCast.c: fixed a warning
13975         * src/SDCCast.h: fixed a warning
13976         * src/SDCCicode.c (operandFromAst): fixed a warning
13977
13978 2003-04-04    <johan AT balder>
13979
13980         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
13981         * src/SDCCast.c (decorateType): fixed bug #715076
13982         * src/SDCC.y: fixed bug #702907
13983
13984 2003-04-03    <johan AT balder>
13985
13986         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
13987         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
13988         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
13989         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
13990         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
13991
13992 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
13993
13994         * _decdptr.c: fix return values
13995         * _gptrget.c: fix return values
13996         * _gptrgetc.c: fix return values
13997         * _gptrput.c: fix return values
13998         * _mulint.c: fix return values
13999         * as/z80/Makefile: fix 'make -j' problem
14000
14001 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
14002
14003         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
14004         * configure.in: big cleanup, updated to autoconf 2.5x
14005         * configure: rebuilt from configure.in
14006         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
14007         * sdcc_vc_in.h: reflect changes from sdccconf.h
14008         * doc/Makefile: fixed a flaw in "make install"
14009
14010 2003-04-02    <johan AT balder>
14011
14012         * src/ds390/gen.c (genCmp): no comments
14013         * src/mcs51/gen.c (genCmp): no comments
14014         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
14015         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
14016
14017 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
14018
14019         * support/regression/generate-cases.py: place generated file in given sub directory
14020         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
14021         * support/regression/Makefile: improvements for 'make -j';
14022         side effect: it's simpler and faster now
14023
14024 2003-03-31  Borut Razem <borut.razem AT siol.net>
14025
14026         * src/z80/main.c: link-{port} and as-{port} defined without path
14027         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
14028
14029 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
14030
14031         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
14032
14033 2003-03-30  Borut Razem <borut.razem AT siol.net>
14034
14035         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
14036           changed type of list parameter to set
14037         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
14038         * src/port.h: changed type of do_assemble() parameter to set
14039         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
14040           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
14041           definition of "cppoutfilename" macro with NULL value in preProcess()
14042         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
14043         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
14044         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
14045           replaced with set *binPathSet
14046         * shash_add() deallocates the item, if allready exsists, before adding the new one
14047         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
14048
14049 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
14050
14051         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
14052           a nested for loop bug in the PIC port
14053         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
14054           for loops
14055
14056 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
14057
14058         * support/Util/dbuf.h: remove C++ stuff to make it portable
14059
14060 2003-03-28  Borut Razem <borut.razem AT siol.net>
14061
14062         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
14063           literal strings in stringLiteral()
14064         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
14065         * src/Makefile.bcc, src/Makefile.in, src/src.dsp: added support/Util/dbuf.c
14066           to the project
14067
14068 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
14069
14070         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
14071
14072 2003-03-26    <johan AT balder>
14073
14074         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
14075         * src/ds390/gen.c (saveRegisters): catched symbol abuse
14076         * src/SDCCast.c (decorateType): fixed " -v < 3"
14077
14078 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
14079
14080         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
14081         Added Lenny Story's debug infrastructure changes:
14082         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
14083         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
14084         * src/cdbFile.c: added
14085         * src/SDCCdebug.c: added
14086         * src/SDCCdebug.h: added
14087         * src/SDCCast.c (createFunction)
14088         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
14089         * src/SDCCmain.c (parseCmdLine, main)
14090         * src/SDCCmem.c (redoStackOffsets)
14091         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
14092         * src/SDCCsymt.h
14093         * src/common.h
14094         * src/avr/gen.c (genAVRCode)
14095         * src/ds390/gen.c (gen390Code)
14096         * src/mcs51/gen.c (gen51Code)
14097         * src/pic/gen.c (genpic14Code)
14098         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
14099         * src/xa51/gen.c (genXA51Code)
14100         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
14101
14102 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
14103
14104         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
14105         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
14106
14107 2003-03-22    <johan AT balder>
14108
14109         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
14110
14111 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
14112
14113         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
14114         * doc/cdbfileformat.lyx: added, written by Lenny Story
14115         * doc/Makefile: added cdbfileformat.lyx
14116         * doc/clean.mk: added cdbfileformat.lyx
14117
14118 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
14119
14120         * src/mcs51/peeph.def: fix bug #705773
14121
14122 2003-03-20    <johan AT balder>
14123
14124         An sfr/sbit can have an "at #" AND an initializer
14125         * src/SDCCsymt.c (checkSClass):
14126         * src/SDCCmem.c (allocGlobal):
14127         * src/SDCCmem.c (allocLocal):
14128         * src/SDCCast.c (createBlock):
14129
14130 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
14131
14132         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
14133
14134 2003-03-16    <johan AT balder>
14135
14136         Undid the hackup of const and volatile, the problem is much bigger
14137         * src/SDCC.y:1.65
14138         * src/SDCCast.c:1.171
14139         * src/SDCCglue.c:1.138
14140         * src/SDCCicode.c:1.146
14141         * src/SDCCsymt.c:1.150
14142         * src/SDCCval.c:1.65
14143
14144 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
14145
14146         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
14147         * src/ds390/gen.c (genAddrOf): fixed bug #704087
14148
14149 2003-03-13    <johan AT balder>
14150
14151         Hackup const and volatile modifiers in type chains a bit:
14152         * src/SDCC.y:1.63
14153         * src/SDCCast.c:1.169
14154         * src/SDCCglue.c:1.136
14155         * src/SDCCicode.c:1.143
14156         * src/SDCCsymt.c1.146
14157         * src/SDCCsymt.h1.59
14158         * src/SDCCval.c:1.63
14159
14160 2003-03-12    <johan AT balder>
14161
14162         * src/SDCCBBlock.h: more LRH debugging junk
14163         * src/SDCCcflow.h: more LRH debugging junk
14164         * src/SDCCloop.c: more LRH debugging junk
14165         * src/SDCC.y (struct_declaration): fixed bug #697590
14166         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
14167         * src/ds390/gen.c (aopForRemat): fixed bug #700031
14168         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
14169
14170 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
14171         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
14172         test function names must now match exactly).
14173         * src/SDCCcse.c: added special case in findCheaperOp to allow
14174         extending a short integer. Makes less awful code for bug 700121 test case.
14175
14176 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14177
14178         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
14179         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
14180
14181 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
14182
14183         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
14184         actually called (operandsNotEqual() was called for all
14185         operandsNotEqualX tests).
14186
14187 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
14188
14189         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
14190         with shorter literals. Fixes bug 700121.
14191
14192 2003-03-11    <johan AT balder>
14193
14194         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
14195
14196 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
14197
14198         * src/SDCCloop.c (mergeRegions): an evil beast is dead
14199         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
14200
14201 2003-03-10  Borut Razem <borut.razem AT siol.net>
14202
14203         * src/SDCCmain.c: pipe preprocessor's output
14204         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
14205         * sdcc_vc_in.h: define pclose as _pclose for WIN32
14206         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
14207         which closes all pipes in pipeSet set
14208         * src/SDCCset.c: free deleted item in function deleteSetItem()
14209         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
14210         moved from z80 to src subproject
14211         * .version: increased version number to 2.3.4
14212
14213 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
14214
14215         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
14216         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
14217         * support/regression/ports/xa51/spec.mk: fix typo
14218
14219 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
14220
14221         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
14222
14223 2003-03-09  Borut Razem <borut.razem AT siol.net>
14224
14225         * src/SDCCmain.c: pipe preprocessor's output
14226         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
14227         * sdcc_vc_in.h: define pclose as _pclose for WIN32
14228         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
14229         which closes all pipes in pipeSet set
14230         * src/SDCCset.c: free deleted item in function deleteSetItem()
14231         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
14232         moved from z80 to src subproject
14233
14234 2003-03-09  Borut Razem <borut.razem AT siol.net>
14235
14236         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
14237         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
14238         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
14239         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
14240         * src/SDCCglobl.h: unification of WIN32 native definitions
14241
14242 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
14243
14244         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
14245
14246 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
14247
14248         * src/configure.in:   check for endianess (even while cross-compiling)
14249         * src/configure:      check for endianess (even while cross-compiling)
14250         * src/configure_in.h: check for endianess (even while cross-compiling)
14251         * src/avr/gen.c:        remove old endianess stuff
14252         * src/mcs51/gen.c:      remove old endianess stuff
14253         * src/ds390/gen.c:      remove old endianess stuff
14254         * src/pic/gen.c:        remove old endianess stuff
14255         * src/pic/genarith.c:   remove old endianess stuff
14256         * src/pic/glue.c:       fix endianess check
14257         * src/pic16/gen.c:      remove old endianess stuff
14258         * src/pic16/genarith.c: remove old endianess stuff
14259         * src/pic16/glue.c:     fix endianess check
14260         * src/xa51/gen.c:       remove old endianess stuff
14261         * src/z80/gen.c:        fix endianess check
14262         * src/SDCCglue.c:       fix endianess check
14263         * src/ds390/peeph.def: fix bug 700036
14264
14265 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
14266
14267         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
14268         * src/configure: find appropriate data-types on host for SDCC's int and long
14269         * src/configure.in: find appropriate data-types on host for SDCC's int and long
14270         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
14271         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
14272
14273 2003-03-07    <johan AT balder>
14274
14275         Just a big NOOP:
14276                 some minor cleanups before the big shot
14277                 OP_DEFS and OP_USES now use Kevin's protection
14278                 new option --nolabelopt
14279
14280         * src/SDCCBBlock.c:
14281         * src/SDCCast.c,:
14282         * src/SDCCcflow.c:
14283         * src/SDCCcse.c:
14284         * src/SDCCicode.c:
14285         * src/SDCCicode.h:
14286         * src/SDCClabel.c:
14287         * src/SDCCloop.c:
14288         * src/SDCCmain.c:
14289         * src/ds390/ralloc.c:
14290         * src/mcs51/ralloc.c:
14291         * src/pic/ralloc.c:
14292         * src/xa51/ralloc.c:
14293         * src/z80/ralloc.c:
14294
14295 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
14296
14297         * src/pic/pcode.c (get_op): fix 64 bit warnings
14298         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
14299         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
14300         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
14301         * support/regression/tests/malloc.c: fix 64 bit warnings
14302
14303 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
14304
14305         * src/mcs51/gen.c (genMinus): fixed bug 696436
14306
14307 2003-03-02  Borut Razem <borut.razem AT siol.net>
14308
14309         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
14310
14311 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
14312
14313         * configure.in: test for mkstemp
14314         * sdccconf_in.h: add HAVE_MKSTEMP
14315
14316 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
14317
14318         * device/include/ctype.h: removed warning while using --stack-auto
14319         * device/include/malloc.h: removed warning while using --stack-auto
14320         * device/include/string.h: removed warning while using --stack-auto
14321
14322 2003-02-23  Borut Razem <borut.razem AT siol.net>
14323
14324         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
14325         because NDEBUG is defined (see man assert)
14326         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
14327
14328 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
14329
14330         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
14331         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
14332
14333 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
14334
14335         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
14336         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
14337
14338 2003-02-18    <johan AT balder>
14339
14340         * as/mcs51/asmain.c (asmbl): module can start with a digit
14341         * as/z80/asmain.c (asmbl): module can start with a digit
14342
14343 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
14344
14345         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
14346         * src/asm.c: fix pipe() for Mingw32
14347
14348 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
14349
14350         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
14351         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
14352         make -V work again; --c1mode reads now from stdin
14353         * doc/sdccman.lyx: added --c1mode
14354         * support/Util/SDCCerr.c: new messages for c1 mode
14355         * support/Util/SDCCerr.h: new messages for c1 mode
14356         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
14357
14358 2003-02-15    <johan AT balder>
14359
14360         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
14361
14362 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
14363
14364         * doc/sdccman.lyx: Environment variables, -o and other minor things
14365
14366 2003-02-14    <johan AT balder>
14367
14368         * src/xa51/main.c: before anyone really tries to use it :)
14369
14370         * Install doc's in share/sdcc/doc
14371         * removed some obsolete files
14372         * Do a proper make distclean and uninstall
14373         M Makefile.common.in
14374         R sdccbuild.sh
14375         M as/Makefile
14376         M device/include/Makefile.in
14377         M device/lib/Makefile.in
14378         M doc/sdccman.lyx
14379         M link/Makefile
14380         M sim/ucsim/doc/Makefile.in
14381         M src/clean.mk
14382         R src/avr/peeph.rul
14383         R src/xa51/peeph.rul
14384         M support/cpp2/Makefile.in
14385         M support/makebin/Makefile
14386
14387
14388 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
14389
14390         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
14391
14392 2003-02-10  Borut Razem <borut.razem AT siol.net>
14393
14394         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
14395         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
14396         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
14397         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
14398         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
14399         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
14400         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
14401         src/z80/Makefile.bcc: Borland Makefile cleanup
14402         * as/z80/Makefile.bcc: Added Borland Makefile
14403         * support/cpp2/borland.h: Removed
14404
14405 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
14406
14407         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
14408         * src/SDCC.lex: new pragma NOIV
14409         * src/SDCCglobl.h: new pragma NOIV
14410         * src/SDCCmem.c: new pragma NOIV
14411
14412 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
14413
14414         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
14415
14416 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
14417
14418         * src/SDCCmain.c: signal handling is switched off by --debug
14419         * doc/Makefile: small fix for install; use clean.mk again
14420         * doc/clean.mk: clean *.pdf and *.html too
14421
14422 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
14423
14424         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
14425         * device/lib/printfl.c: fix a ds390 bug by making it portable
14426         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
14427         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
14428         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
14429         * debugger/mcs51/cmd.c: converted multi-line string literals
14430         * sim/ucsim/globals.cc: converted multi-line string literals
14431         * src/SDCCmain.c: introduced signal handler to remove temp files
14432         * doc/Makefile: small tweaks, implement clean
14433         * doc: removed generated files
14434
14435 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14436
14437         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
14438         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
14439         Address Record is not correctly generated for DS390."
14440
14441 2003-02-02  Borut Razem <borut.razem AT siol.net>
14442
14443         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
14444         * as/mcs51/asm.h: fixed compilation with Borland C
14445         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
14446         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
14447         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
14448         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
14449         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
14450         src/z80/Makefile.bcc: delete $(LIB) only if exist
14451         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
14452
14453 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
14454
14455         * device/include/malloc.h: introduced NULL
14456         * device/include/string.h: introduced NULL
14457         * device/include/stdlib.h: introduced NULL
14458         * device/lib/_memcpy.c: removed NULL
14459         * device/lib/_strcat.c: removed NULL
14460         * device/lib/_strchr.c: removed NULL
14461         * device/lib/_strcmp.c: removed NULL
14462         * device/lib/_strcpy.c: removed NULL
14463         * device/lib/_strcspn.c: removed NULL
14464         * device/lib/_strlen.c: removed NULL
14465         * device/lib/_strncat.c: removed NULL
14466         * device/lib/_strncmp.c: removed NULL
14467         * device/lib/_strncpy.c: removed NULL
14468         * device/lib/_strpbrk.c: removed NULL
14469         * device/lib/_strrchr.c: removed NULL
14470         * device/lib/_strspn.c: removed NULL
14471         * device/lib/_strstr.c: removed NULL
14472         * device/lib/_strtok.c: removed NULL
14473         * device/lib/malloc.c: removed NULL, include own header
14474
14475 2003-02-02    <johan AT balder>
14476
14477         * 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
14478         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
14479         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
14480         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
14481         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
14482         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
14483
14484 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14485
14486         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
14487         area 'DATA'"
14488
14489 2003-02-01    <johan AT balder>
14490
14491         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
14492
14493 2003-01-31    <johan AT CP255758-A>
14494
14495         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
14496
14497 2003-01-30    <johan AT balder>
14498
14499         * src/SDCCBBlock.c: automatic bug detection
14500         * src/SDCCicode.c: automatic bug detection
14501
14502 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14503
14504         * src/SDCCglobl.h:   now --xram-size 0 works
14505         * src/SDCCmain.c:    now --xram-size 0 works
14506
14507 2003-01-29    <johan AT balder>
14508
14509         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
14510
14511 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14512
14513         * as/mcs51/aslink.h: Added options --xram-size and --code-size
14514         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
14515         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
14516         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
14517         * src/SDCCglobl.h:   Added options --xram-size and --code-size
14518         * src/SDCCmain.c:    Added options --xram-size and --code-size
14519
14520 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
14521
14522         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
14523         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
14524
14525 2003-01-27    <johan AT balder>
14526
14527         * src/SDCC.y: fixed bug #613764
14528
14529 2003-01-26    <johan AT balder>
14530
14531         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
14532         * src/SDCCsymt.h: fixed bug #673374
14533         * src/SDCCglue.c: fixed bug #661910
14534         * src/SDCCast.c: fixed bug #458099 and 673374
14535
14536 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
14537
14538         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
14539         * as/mcs51/strcmpi.h: added
14540         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
14541         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
14542         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
14543         * as/mcs51/assym.c: strcmpi -> as_strcmpi
14544         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
14545         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
14546         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
14547         * as/mcs51/Makefile.aslink: new module strcmpi
14548         * as/mcs51/Makefile.asx8051: new module strcmpi
14549         * as/mcs51/Makefil.bcc: new module strcmpi
14550         * as/mcs51/Makefile.in: new module strcmpi
14551         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
14552
14553 2003-01-26    <johan AT balder>
14554
14555         * src/SDCCglue.c: reverted back to 1.124
14556         * src/SDCCast.c: reverted back to 1.156
14557         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
14558
14559 2003-01-25    <johan AT balder>
14560
14561         * src/SDCCglue.c: A better fix for bug #661910
14562         * src/SDCCast.c: A better fix for bug #661910
14563         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
14564
14565 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
14566
14567         * src/Makefile.in: remove spawn.o
14568         * src/SDCCmain.c: remove spawn.h
14569         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
14570         * src/spawn.c: removed
14571         * src/spawn.h: removed
14572         * support/regression/ports/ds390/spec.mk: link with -r
14573
14574 2003-01-24    <johan AT CP255758-A>
14575
14576         * src/ds390/gen.c (aopOp): fixed bug #667458
14577         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
14578         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
14579         (createIvalCharPtr): an ival doesn't always have a storage class anymore
14580
14581 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
14582
14583         * src/mcs51/peeph.def: better assembler identation by Frieder
14584         * src/mcs51/gen.c: better assembler identation by Frieder
14585
14586 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
14587
14588         * as/z80/string.h: removed for gcc 3.2
14589         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
14590         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
14591
14592 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
14593
14594         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
14595         * src/SDCCpeeph.c (replaceRule): fix bug #663503
14596         * support/regression/Makefile: separate temp files for ports
14597         * support/regression/generate-cases.py: separate temp files for ports
14598         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
14599         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
14600
14601 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
14602
14603         * moved tinitalk to device/examples/ds390
14604
14605 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
14606
14607         * as/mcs51/lkmem.c: rflag is for DS390
14608         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
14609         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
14610                          (linkEdit): move mem- and map-files the same way as ihx-files
14611         * src/z80/main.c (_setDefaultOptions): removed --generic
14612         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
14613         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
14614         * src/pic/glue.c (picglue): --c1mode works again
14615         * src/pic16/glue.c (pic16glue): --c1mode works again
14616         * src/asm.c (printCLine): fix #660034
14617
14618 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
14619
14620         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
14621         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
14622         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
14623         * as/mcs51/lkmem (summary): better fix for sp problem
14624         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
14625         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
14626         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
14627                                               remove --stack-after-data
14628
14629 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
14630
14631         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
14632         * src/SDCCutil.c (join): ugly bug: missing '\0'
14633         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
14634
14635 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
14636
14637         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
14638         * src/port.h: typo
14639         * src/pic/main.c (_asmCmd): gpasm supports -o
14640         * src/z80/main.c: more general macros
14641         * device/lib/Makefile.in: remove intermediate files
14642
14643 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
14644
14645         * .version: Bumped version number to 2.3.3
14646         * src/SDCCBBlock.c: new option -o
14647         * src/SDCCglobl.h: new option -o
14648         * src/SDCCglue.c: new option -o
14649         * src/SDCCmain.c: new option -o
14650         * src/asm.c: new option -o
14651         * src/ds390/main.c: new option -o
14652         * src/pic/glue.c: new option -o
14653         * src/pic/pcode.c: new option -o
14654         * src/pic/ralloc.c: new option -o
14655         * src/pic16/glue.c: new option -o
14656         * src/pic16/pcode.c: new option -o
14657         * src/pic16/ralloc.c: new option -o
14658         * src/z80/main.c: new option -o
14659         * device/lib/Makefile.in: use -o
14660         * support/regression/ports/ds390/spec.mk: use -o
14661         * support/regression/ports/gbz80/spec.mk: use -o
14662         * support/regression/ports/mcs51/spec.mk: use -o
14663         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
14664         * support/regression/ports/z80/spec.mk: use -o
14665         * support/regression/ports/ucz80/spec.mk: use -o
14666         * support/regression/ports/xa51/spec.mk: use -o
14667         * support/regression/fwk/lib/timeout.c: fix usage string
14668
14669 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
14670         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
14671
14672 2003-01-07    <johan AT balder>
14673
14674         * src/SDCCast.c (decorateType): fixed bug #600035
14675
14676 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
14677         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
14678         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
14679         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
14680         * src/pic/pcode.c: outcommented unused variable to remove warnings
14681         * src/pic/ralloc.c: outcommented unused variable to remove warnings
14682
14683 2003-01-06    <karl AT turbobit.com>
14684         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
14685    regression tests.
14686
14687 2003-01-06    <johan AT balder>
14688
14689         * src/SDCCicode.c: fixed array add
14690
14691 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
14692         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
14693         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
14694
14695 2003-01-04    <johan AT balder>
14696
14697         * src/SDCCval.c (getNelements): fixed the initialized array of structures
14698
14699 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14700         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
14701
14702 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
14703         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
14704         * support/regression/tests/bug-524697.c: fit mem usage into 8032
14705
14706 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
14707         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
14708
14709 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
14710         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
14711
14712 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
14713         * src/mcs51/main.c: removed {bindir}{sep} from aslink
14714
14715 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14716
14717     * in /sdcc/as/mcs51/ changed these files in order to create an
14718     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
14719     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
14720     following files to include the previous two files: aslink.dsp,
14721     Makefile.aslink, Makefile.bcc, and Makefile.in.
14722
14723     * Changed /sdcc/src/SDCCmain.c so it creates files with extension
14724     .adb instead of .cdb
14725
14726 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14727
14728         * /sdcc/as/mcs51/lklist.c: Now reports memory usage using the
14729         value from option --iram-size.
14730
14731 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14732
14733         * /sdcc/as/mcs51/lklist.c: added boundary check before using
14734         dram[] array.
14735
14736 2002-09-18    <wiml AT hhhh.org>
14737
14738         * SDCClrange.h: exposed setFromRange() and setToRange()
14739         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
14740           packRegsForAccUse() (bug 542397)
14741         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
14742           multiple times and emitting the fetch operations more than once
14743           added aopGetUsesAcc() function to allow binary operators to
14744           fetch their operands in the correct order; made genMinus() emit
14745           compact code for X = LITERAL - Y
14746
14747 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14748         * /sdcc/as/mcs51/lklist.c: Fixed incorrect number of parameters to
14749         sprintf() in line 1267.
14750
14751 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14752         * /sdcc/src/SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
14753         like ports.
14754
14755 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
14756         Changes to aslink (All the changes are marked with 'JCF'):
14757
14758         * /sdcc/as/mcs51/aslink.h: External definition of sflag and
14759         summary().
14760
14761         * /sdcc/as/mcs51/lkarea.c: Computes the size of area BSEG_BYTES from
14762         area BSEG.  Also moves, if possible, the DATA area down into the internal
14763         ram so more space is available.
14764
14765         * /sdcc/as/mcs51/lkdata.c: Definition of memory summary output flag
14766         sflag.
14767
14768         * /sdcc/as/mcs51/lklist.c: For the BSEG area report the size in bits,
14769         not bytes.  Function summary() which creates a memory usage summary
14770         file with extension .mem.  Reports of overlaping stack and small stack
14771         size.  If the space for the stack is less than 16 bytes aslink trows a
14772         warning.
14773
14774         * /sdcc/as/mcs51/lkmain.c: Creation of some of the default areas for
14775         the 8051.  Option 'y' for memory summary output file.
14776
14777         Changes to sdcc (All the changes are marked with 'JCF'):
14778
14779         * /sdcc/src/SDCCglobl.h: External definition of RegBankUsed[4].
14780
14781         * /sdcc/src/SDCCglue.c:  If a register bank is used, creates an
14782         overlaying area for it (uses RegBankUsed[4]).
14783
14784         * /sdcc/src/SDCCmain.c: Definition RegBankUsed[4]; marks register
14785         bank zero as used by default.  By default aslink locates the stack
14786         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
14787         the creation of the .mem file.  Delegates the allocation of data area
14788         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
14789         the begining of the stack area to aslink.
14790
14791         * /sdcc/src/SDCCmem.c:  If a register bank is used, marks it so
14792         glue() in SDCCglue.c creates an area for it.
14793
14794 2002-09-03  Borut Razem <borut.razem AT siol.net>
14795         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
14796         sdcc/src/pic/glue.c:
14797         introduced atexit() handler for teporay files removal in case of
14798         errors, assertions, ...
14799
14800 2002-08-29  Borut Razem <borut.razem AT siol.net>
14801         * sdcc/support/cpp2/auto-host_vc_in.h:
14802         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
14803         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
14804         Maybe there is a similar problem with BORLANDC? It should be checked!
14805
14806         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
14807         corrected improper use of assert: the assignment to clr variable was done inside the assert.
14808         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
14809         was not executed, and the compiler (cl) launched a warning:
14810         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
14811
14812 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
14813         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
14814
14815 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
14816         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
14817
14818         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
14819           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
14820           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
14821           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
14822           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
14823           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
14824           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
14825         - added Release configuration in VS projects
14826         - review of compiler an linker options
14827         - VC .exe files are generated in bin_vc directory, not to interfere
14828           with binaries generated from other projects (cygwin, mingw, bcc ...)
14829
14830         * sdcc/src/yacc.dsp: added
14831
14832         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
14833         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
14834         and insert the version number definitions from .version
14835
14836         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
14837
14838         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
14839         added - genarate auto-host.h using auto-host_vc_in.h as template
14840
14841         * sdcc/sdcc_vc.h,
14842         removed from CVS, generated automatically
14843
14844 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
14845         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
14846
14847 2002-08-11  Borut Razem <borut.razem AT siol.net>
14848         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
14849
14850 2002-08-10  Borut Razem <borut.razem AT siol.net>
14851         * src/SDCCmain.c (main):
14852         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
14853         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
14854         The consequence was that some temporary files were not removed.
14855
14856         * src/SDCCglue.c:
14857         unification of code in functions tempfilename() and tempfile():
14858         function tempnam() is defined in Visual Studio 6.0 and .NET
14859
14860         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
14861
14862         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
14863           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
14864         - removed compiler command line option /WX: Treats all warnings as errors
14865         - update a list of source files, included into the project
14866
14867         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
14868           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
14869         changed project type to Generic Project so that can be correcly converted to VS.NET project
14870
14871         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
14872
14873         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
14874
14875         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
14876
14877         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
14878         added return 0 statements after assert() to make compiler happy
14879
14880         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
14881         added newline in the def file to keep MSC compiler satisfied
14882
14883         * sdcc/src/z80/gen.c:
14884         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
14885           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
14886         - solved MSC error in function aopDump()
14887
14888         * sdcc_vc.h: define PREFIX as "\\sdcc"
14889
14890 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
14891         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
14892
14893 2002-06-22  Scott Dattalo <scott AT dattalo.com>
14894         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
14895         - Rewrote the register banking algorithm.
14896         - Added pCode live-range analysis to registers (for now, only non-used and
14897         singly-used registers optimized away)
14898
14899         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
14900
14901         * 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.
14902
14903 2002-05-10  Scott Dattalo <scott AT dattalo.com>
14904         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
14905
14906 2002-04-22  Michael Hope  <michaelh AT vroom>
14907
14908         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
14909
14910         * configure.in (DD_COPT): Added include support required for gbdk.
14911
14912         * .version: Bumped version number just to increase it.
14913
14914         * src/SDCCmain.c: Added -nostdinc to the default options.
14915
14916 2002-04-15  Michael Hope  <michaelh AT vroom>
14917
14918         * device/lib/z80/printf.c (sprintf): Added.
14919
14920         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
14921
14922         * src/z80/peeph.def: Added transpose redundent load rule.
14923
14924         * src/z80/main.c: Added force callee saves for jaune.
14925
14926         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
14927
14928         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
14929
14930 2002-03-28  Johan Knol  <johan AT balder>
14931
14932         * src/SDCCval.c: fixed bug #532436
14933
14934 2002-03-14  Scott Dattalo <scott AT dattalo.com>
14935         * /src/port.h:
14936         Added "char *Processor" field to the port structure.
14937
14938         * /src/SDCCmain.c:
14939         Added -p option. Allows port dependent processor to be specified.
14940
14941         * all ports:
14942         Initialized the new field char *Processor field to NULL in all ports
14943
14944         * /src/pic/*:
14945         Compiler generated registers for interrupt context saving
14946         were not getting allocated.
14947
14948 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
14949
14950         * /src/SDCCast.c:
14951         Fixed left shift. Will promote the left side of a left shift
14952         if a) left shifting more than size of operand or b) when assigned
14953         to something size > size of left side
14954
14955 2002-03-14  Scott Dattalo <scott AT dattalo.com>
14956         * src/pic/*
14957         tons of changes. Register allocation has been
14958         rewritten. Added customization for the various PICs. Flow
14959         analysis is restructured. ...
14960
14961         * src/pic/device.h:
14962         Added
14963
14964         * src/pic/device.c:
14965         Added. device.c is a PIC port hack to accomodate variations
14966         in PIC devices.
14967
14968 2002-03-13  Michael Hope  <michaelh AT vroom>
14969
14970         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
14971
14972 2002-03-04  johanknol  <johanknol AT manik>
14973
14974         * /src/SDCCval.c: fixed
14975
14976         const unsigned char arr[][2] = { { 0, 1 } };
14977         t18.c:1: error: Initializer element is not constant
14978
14979 2002-03-04  bela  <bela AT manik>
14980
14981         * /device/include/mcs51reg.h:
14982         ds89c420 register definition update
14983
14984 2002-03-03    <johan AT FRIJA>
14985
14986         * support/Util/SDCCerr.c: did something, but don't no why anymore
14987
14988         * support/regression/tests/bug-524691.c: made it a little less shy
14989
14990         * src/SDCCast.c (decorateType): fixed bug #524697
14991
14992         * src/SDCCast.c: made some lineno improvements
14993
14994         * src/SDCCval.c (getNelements): changed warning to error
14995
14996         * src/SDCCglue.c (printIvalArray): changed warning to error
14997
14998         * src/SDCCicode.c: fixed a warning for mingw
14999
15000         * src/SDCCast.c (decorateType): fixed the << promotion for ops
15001
15002         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
15003
15004 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
15005
15006         * src/ds390/peeph.def:
15007         Added some more peephole rules
15008
15009         * src/ds390/gen.c: Various fixes & enhancements
15010
15011         * src/SDCClrange.c, src/SDCClrange.h:
15012         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
15013
15014         * src/ds390/ralloc.c:
15015         various fixes & enhancements (ds390) specific
15016
15017         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
15018         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
15019         from rallocs.
15020
15021         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
15022
15023 2002-03-02    <johan AT FRIJA>
15024
15025         * src/SDCCast.c (decorateType): fixed bug #524708
15026
15027         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
15028
15029         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
15030
15031 2002-03-01  Michael Hope  <michaelh AT vroom>
15032
15033         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
15034
15035         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
15036
15037 2002-03-01    <johan AT FRIJA>
15038
15039         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
15040
15041         * src/SDCCast.c (decorateType): fixed bug #524209
15042
15043         * src/SDCCval.c (valNot): fixed bug #524195
15044
15045 2002-02-26    <johan AT balder>
15046
15047         * src/xa51/gen.c: fixed a warning
15048
15049         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
15050
15051         * src/SDCCast.c (decorateType): fixed bug #522534
15052
15053 2002-02-23    <johan AT balder>
15054
15055         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
15056
15057 2002-02-22    <johan AT balder>
15058
15059         * src/SDCCast.c: fixed bug #514865
15060
15061         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
15062
15063 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
15064
15065         * sdcc/src/SDCCloop.c:
15066         Previous fix was not good. basic blocks that have "break" or "return" are
15067         not really partof a loop , but live ranges used in these blocks should
15068         be live thru the entire loop, so set partOfLoop but don't add them to
15069         loop region
15070
15071 2002-02-21    <johan AT FRIJA>
15072
15073         * src/SDCCcse.c: fixed bug #514308
15074
15075 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
15076
15077         * src/SDCCloop.c:
15078         Fixed BUG #519583. If a conditional block ended in a return/break
15079         statement inside a loop, it was not being considered part of the loop.
15080
15081         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
15082
15083 2002-02-10  Karl Bongers <karl AT turbobit.com>
15084
15085         * debugger/*:
15086         Fixed up SDCDB debugger somewhat.  Updated debugger/README
15087         with lots of comments and notes.
15088
15089         * device/examples/test2.c:
15090         Fix bug, "red" variable not being initialized(compiler complained).
15091
15092         * device/examples/Makefile, examples/test3.c:
15093         Add Makefile in device/examples folder, compiles test3.c
15094         for use as a multiple module SDCDB test case.
15095
15096         * sim/ucsim/cmd.src/cmdset.cc:
15097         Took out debug printfs in ucsim "next" command.
15098
15099         * sim/ucsim/xa.src:
15100         Karl and Johan start ucsim XA support.  Most dissassembly working,
15101         about 75% emulation done(plenty of work remaining).
15102
15103         * sim/ucsim/z80.src:
15104         Add Z80 support to ucsim, add test-ucz80 regression test,
15105         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
15106         Notice z80 compiler fails on examples/test3.c/crc code.
15107
15108 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
15109
15110         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
15111         Added support for --parms-in-bank1
15112
15113         * src/ds390/peeph.def:
15114         added a few more peephole optimzations
15115
15116         * src/ds390/main.c:
15117         1) added __builtin_inp & __builtin_outp used to read in data of given length
15118            from a memory mapped port
15119         2) added __builtin_memcmp
15120         3) added __builtin_swapw swap bytes of a short
15121
15122         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
15123         1) handle multiple send & receives from register bank1
15124         2) ralloc can now allocate DPTR1 to some liveRanges
15125
15126         * src/SDCCsymt.c, src/SDCCsymt.h:
15127         changes to handle multiple sends & receives
15128
15129         * src/SDCCptropt.h:
15130         added some pointer arithmetic optimization
15131
15132         * src/SDCCptropt.c:
15133         added some pointer arithmetic optimizations but not stable yet so not
15134         called from anywhere (will get this working shortly)
15135
15136         * src/SDCCopt.c: fixed for multiple sends & receives
15137
15138         * src/SDCCmain.c:
15139         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
15140         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
15141            set preprocessor defines (depending on options)
15142
15143         * src/SDCCicode.c, src/SDCCicode.h:
15144         changes made to handle multiple sends & receives
15145
15146         * src/SDCCglobl.h:
15147         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
15148
15149         * src/SDCCcse.c, src/SDCCcse.h:
15150         added function findbackward def (to be used in upcoming optimization)
15151
15152         * src/SDCCcflow.c, src/SDCCcflow.h:
15153         added function returnAtEnd - to determine if a basic block terminates with
15154         a RETURN iCode
15155
15156         * src/SDCCast.c, src/SDCCast.h:
15157         added option parms-in-bank1
15158
15159         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
15160         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
15161         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
15162         adjusted for --parms-in-bank1 option
15163
15164         * device/include/string.h:
15165         donot redefine "reentrant" keyword
15166
15167         * device/include/ds80c390.h: Added some more SFRs
15168
15169 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
15170
15171         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
15172
15173 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
15174
15175         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
15176
15177 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
15178
15179         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
15180
15181 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
15182
15183         * Added --xram-movc option
15184
15185 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
15186
15187         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
15188
15189 2002-01-11  Johan Knol
15190
15191         * Added math lib of Jesus Calvino-Fraga
15192
15193 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
15194
15195         * src/SDCCmain.c (processFile): fix processing of ../../src.c
15196         * support/regression/Makefile: new target test-mcs51-stack-auto
15197         * support/regression/ports/mcs51-stack-auto/spec.mk: added
15198
15199 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
15200
15201         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
15202
15203 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
15204
15205         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
15206
15207 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
15208
15209         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
15210
15211         * src/SDCCglue.h: add definition for printIvalChar()
15212
15213 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
15214
15215         * src/SDCCast.c: fix #498138 by Johan
15216
15217         * src/SDCCglue.c: fix #498138 by Johan
15218
15219 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
15220
15221         * support/regression/Makefile: fix clean
15222
15223         * support/regression/ports/ds390/support.c: fix transmission of last character
15224
15225 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
15226
15227         * /sdcc/src/ds390/gen.c:
15228         a) improved computing address of stack variable
15229         b) took out some #if 0 code
15230         c) improved parmBytes adjustment
15231         d) improved genPlusIncr & genMinusIncr
15232         e) genCmp could generate bad code (when left assigned to DPTR)
15233         f) Fixed bug in hasInc
15234
15235         * /sdcc/src/ds390/ralloc.c:
15236         a) packRegsForSupport could mess up live information (Fixed)
15237         b) packRegsDPTRuse could be incorrect for left & right shift
15238
15239         * /sdcc/src/mcs51/ralloc.c:
15240         packRegsForSupport could mess up the live information (Fixed)
15241
15242         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
15243
15244         * /sdcc/src/SDCCast.c:
15245         can reverse a loop even if function call is present as long
15246         as the loop control variable is local & is not passed as parameter
15247
15248 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
15249
15250         * /sdcc/ChangeLog: *** empty log message ***
15251
15252         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
15253         More builtin function additions for TININative
15254
15255         * /sdcc/src/ds390/ralloc.c:
15256         Had broken the regression testsuite
15257
15258         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
15259
15260         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
15261         Added funcattr hasStackParms will be set for reentrant functions when there
15262         are paramteres on the stack, this helps in minimizing frame pointer generation
15263         typeFromStr can handle function pointers now
15264
15265         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
15266         *** empty log message ***
15267
15268 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
15269
15270         * /src/ds390/gen.c, /src/ds390/main.c:
15271         More builtin function additions for TININative
15272
15273         * /src/ds390/ralloc.c:
15274         Had broken the regression testsuite
15275
15276         * /src/SDCCast.c: Fixed a bug in dumptree
15277
15278         * /src/SDCCsymt.c, /src/SDCCsymt.h:
15279         Added funcattr hasStackParms will be set for reentrant functions when there
15280         are paramteres on the stack, this helps in minimizing frame pointer generation
15281         typeFromStr can handle function pointers now
15282
15283         * /doc/builtins.txt, /doc/TININative.txt:
15284         *** empty log message ***
15285
15286
15287 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
15288
15289         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
15290         ALPHA version for -mTININative
15291
15292         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
15293         updated to reflect changes in the port structure
15294
15295         * /src/port.h:
15296         added function do_assemble (similar to do_link) if non-null this function
15297         will be called to do assembly (-mTININative) requires a multi command
15298         assembly
15299         added function genAssemblerEnd will be called to generate assembler Epilogue
15300
15301         * /src/SDCCsymt.c:
15302         added _JavaNative to debug info printing
15303
15304         * /src/SDCCmain.c: added option --tini-libid
15305         added port->do_assemble function (-mTININative) has a multi command assemble
15306
15307         * /src/SDCCglue.c: Disabled "constExpr" check
15308         added port->genAssemblerEnd function
15309
15310         * /src/SDCCglobl.h: Added option --tini-libid value
15311
15312         * /src/SDCCast.h:
15313         tookout optimizeCompare from the header (has no external references)
15314
15315         * /src/SDCCast.c: made one more function "static"
15316
15317 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
15318
15319         * src/z80/mappings.i: Added z80asm support.
15320
15321         * src/z80/main.c: Added z80asm support on --asm=z80asm
15322
15323         * src/z80/gen.c: Fixed asm portability issues.
15324
15325         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
15326
15327         * src/SDCCglue.c (printExterns): Added global/extern split.
15328
15329 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
15330
15331         * support/regression/Makefile: added test for mcs51 model large
15332
15333         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
15334
15335         * support/regression/ports/gbz80/spec.mk: added -mgbz80
15336
15337 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
15338
15339         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
15340
15341 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
15342
15343         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
15344
15345         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
15346
15347 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
15348
15349         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
15350
15351         * support/regression/tests/simplefloat.c: Port to mcs51.
15352
15353 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
15354         * support/regression/tests/bug-485362.c: Added.
15355
15356         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
15357
15358         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
15359
15360         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
15361
15362         * src/z80/gen.c (aopDump): Added a dump function.
15363
15364 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
15365         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
15366
15367         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
15368
15369         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
15370
15371         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
15372
15373         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
15374
15375         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
15376
15377         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
15378
15379         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
15380
15381         * support/regression/ports/ds390/support.c: Use tinibios.
15382
15383         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
15384
15385 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
15386
15387         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
15388         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
15389
15390         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
15391
15392         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
15393
15394 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
15395
15396         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
15397
15398         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
15399         (packRegsForIYUse): Created and optimised.
15400
15401 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
15402
15403         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
15404 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
15405
15406         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
15407
15408         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
15409
15410         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
15411
15412 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
15413
15414         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
15415
15416         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
15417
15418 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
15419
15420         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
15421
15422         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
15423
15424         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
15425
15426 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
15427
15428         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
15429         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
15430         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
15431
15432         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
15433
15434         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
15435         (genNotFloat): Added.
15436         (genUminusFloat): Added.
15437
15438         * device/lib/z80/Makefile: Added floating pt stubs.
15439
15440         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
15441
15442         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
15443
15444         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
15445
15446 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
15447
15448         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
15449
15450         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
15451
15452         * sdcc/support/regression/Makefile: Add port ds390.
15453
15454         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
15455
15456         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
15457
15458         * sdcc/support/regression/ports/ds390/spec.mk: Added.
15459
15460         * sdcc/support/regression/ports/ds390/support.c: Added.
15461
15462         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
15463
15464         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
15465
15466         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
15467
15468 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
15469
15470         * device/include/malloc.h: Added z80 and gbz80 support.
15471
15472         * device/lib/gbz80/heap.s: Added.
15473
15474         * device/lib/z80/heap.s: Added.
15475
15476         * device/lib/malloc.c: Added z80 and gbz80 support.
15477
15478         * support/regression/tests/malloc.c (testMalloc): Added.
15479
15480         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
15481
15482         * support/regression/tests/bug-478094.c: Added.
15483
15484         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
15485
15486 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
15487
15488         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
15489
15490         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
15491
15492         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
15493
15494         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
15495
15496         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
15497
15498 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
15499
15500         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
15501
15502 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
15503
15504         * support/regression/tests/bug-477927.c: Added.
15505
15506         * src/z80/peeph.def: Added minor rules.
15507
15508         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
15509
15510         * src/z80/peeph.def: Added jump optimisation modification.
15511
15512 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
15513
15514         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
15515
15516 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
15517
15518         * support/regression/tests/funptrs.c: Added.
15519
15520 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
15521
15522         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
15523
15524 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
15525
15526         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
15527
15528         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
15529
15530         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
15531         (movLeft2ResultLong): Created.
15532
15533         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
15534         (joinPushes): Added.  Joins two char pushes into a word push.
15535
15536 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
15537
15538         * support/cpp2/Makefile.in (install): Added creation of dest dir.
15539
15540         * support/makebin/Makefile (install): Added creation of dest dir.
15541
15542 2001-10-24 Karl Bongers <karl AT turbobit.com>
15543
15544         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
15545
15546 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
15547
15548         * src/z80/ralloc.c: Turned off faulty pack for one use.
15549
15550         * src/z80/peeph-gbz80.def: Removed redundent restart options.
15551
15552         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
15553
15554 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
15555
15556         * support/regression/Makefile: Improved clean
15557
15558         * support/regression/ports/gbz80/spec.mk: Added clean
15559
15560         * support/regression/ports/host/spec.mk: Added clean
15561
15562         * support/regression/ports/z80/spec.mk: Added clean
15563
15564         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
15565
15566         * support/regression/ports/mcs51/timeout.c: little improvements
15567
15568 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
15569
15570         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
15571
15572         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
15573
15574         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
15575
15576 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
15577
15578         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
15579
15580         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
15581
15582 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
15583         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
15584
15585         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
15586
15587         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
15588
15589         * src/mcs51/main.c (_linkCmd): Added bin path to command.
15590
15591         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
15592
15593         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
15594
15595         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
15596
15597         * support/regression/tests/longor.c: Added.
15598
15599 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
15600
15601         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
15602
15603         * as/mcs51/aslink.h: define PATH_MAX
15604
15605         * as/mcs51/asm.h: define PATH_MAX
15606
15607         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
15608
15609         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
15610
15611         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
15612
15613         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
15614
15615         * src/SDCCglobl.h: define PATH_MAX
15616
15617         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
15618
15619         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
15620
15621 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
15622
15623         * src/z80/gen.c (gencjneshort): Fixed
15624
15625         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
15626
15627 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
15628
15629         * support/regression/tests/bug-469671.c: Added.
15630
15631         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
15632
15633 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
15634
15635         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
15636
15637         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
15638
15639 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
15640
15641         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
15642
15643         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
15644
15645         * src/device/lib/_mullong.c : removed hint: nooverlay bug
15646
15647         * src/device/lib/_divuint.c : removed hint: nooverlay bug
15648
15649         * src/device/lib/_divulong.c: removed hint: nooverlay bug
15650
15651         * src/device/lib/_moduint.c : removed hint: nooverlay bug
15652
15653         * src/device/lib/_modulong.c: removed hint: nooverlay bug
15654
15655 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
15656
15657         * 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.
15658
15659         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
15660
15661         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
15662
15663 2001-10-07    <johan AT FRIJA>
15664
15665         * device/lib/gets.c (gets): fixed the return value.
15666
15667 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
15668         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
15669
15670         * 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.
15671
15672         * 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.
15673
15674         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
15675
15676         * src/pic/gen.c: Removed Safe_strdup.
15677
15678         * configure.in: Added option to enable libgc support.
15679
15680         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
15681         (bitVectUnion): Optimised.
15682         (bitVectIntersect): Optimised.
15683         (bitVectBitsInCommon): Optimised.
15684         (bitVectCplAnd): Optimised.
15685
15686         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
15687
15688 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
15689
15690         * src/SDCCmain.c: distinguish between assembler debug and plain options
15691
15692         * src/avr/main.c:   remove standard assembler options
15693
15694         * src/ds390/main.c: remove standard assembler options
15695
15696         * src/mcs51/main.c: remove standard assembler options
15697
15698         * src/port.h: removed "PENDING" comment
15699
15700 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
15701
15702         * src/device/lib/_mulint.c  : new, with assember functions
15703
15704         * src/device/lib/_mullong.c : new, with assember functions
15705
15706         * src/device/lib/_divuint.c : with assember functions
15707
15708         * src/device/lib/_divsint.c : with assember functions
15709
15710         * src/device/lib/_divulong.c: with assember functions
15711
15712         * src/device/lib/_divslong.c: with assember functions
15713
15714         * src/device/lib/_moduint.c : with assember functions
15715
15716         * src/device/lib/_modsint.c : with assember functions
15717
15718         * src/device/lib/_modulong.c: with assember functions
15719
15720         * src/device/lib/_modslong.c: with assember functions
15721
15722         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
15723
15724         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
15725
15726         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
15727                                       replaced _mululong.c and _mulslong.c by _mullong.c
15728
15729 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
15730
15731         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
15732
15733 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
15734
15735         * src/SDCCglue.c: test, if win32api is available for MINGW
15736
15737 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
15738
15739         * src/SDCCsymt.c: no more _modifier in printTypeChain()
15740         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
15741         * support/regression/ports/gbz80/spec.mk: removed GENERIC
15742         * support/regression/ports/host/spec.mk: removed GENERIC
15743         * support/regression/ports/mcs51/spec.mk: removed GENERIC
15744         * support/regression/ports/z80/spec.mk: removed GENERIC
15745
15746 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
15747
15748         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
15749
15750         * support/regression/tests/bug-467035.c: Created.
15751
15752 2001-10-01    <johan AT FRIJA>
15753
15754         * src/SDCC.y: fixed bug #466586 part 1
15755
15756 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
15757
15758         * SDCCicode.c: z80 has no generic pointers
15759         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
15760
15761 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
15762
15763         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
15764
15765 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
15766
15767         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
15768
15769         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
15770
15771 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
15772
15773         * configure.in: Fixed up so that ucsim is only configured once.
15774
15775         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
15776
15777         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
15778         (getPathDifference): As above.
15779
15780         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
15781
15782         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
15783
15784 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
15785         * .version: Updated to 2.3.1
15786
15787         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
15788         Added copyright header.
15789
15790         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
15791         (assemble): Added support for macro based assembler commands.
15792         (linkEdit): Added support for macro based linker commands.
15793         (preProcess): Changed the pre-processor to use macros.
15794         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
15795         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
15796
15797         * device/lib/z80/crt0.s: Added module name for debugging.
15798
15799 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
15800
15801         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
15802
15803         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
15804
15805         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
15806
15807         * src/Makefile.in: Added SDCCmacro and SDCCutil
15808
15809 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
15810
15811         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
15812
15813 2001-09-16    <johan AT FRIJA>
15814
15815         * 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.
15816
15817 2001-09-15    <johan AT FRIJA>
15818
15819         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
15820         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
15821
15822 2001-09-11    <johan AT FRIJA>
15823
15824         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
15825
15826 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
15827
15828         * support/regression/tests/bug-460444.c: Added test case.
15829
15830         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
15831         (genCast): Added justification for all of the asserts.
15832
15833 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
15834
15835         * support/regression/support.c: _xdata replaced by xdata
15836
15837         * support/regression/spec.mk: removed _generic
15838
15839 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
15840
15841         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
15842
15843         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
15844         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
15845
15846         * src/z80/peeph.def: Added a rule to optimise shift then compare.
15847
15848         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
15849
15850         * support/regression/tests/bug-460010.c: Added test case.
15851
15852         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
15853
15854 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
15855
15856         * support/regression/Makefile: inter-port-clean adjusted for mcs51
15857
15858         * support/regression/testfwk.c: removed workaround for bug #436344
15859
15860         * support/regression/tests/bp.c: use less memory with mcs51
15861
15862         * support/regression/tests/bug-441448.c: use less memory
15863
15864         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
15865
15866         * support/regression/collate-results.py: typo
15867
15868 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
15869
15870         * support/regression/tests/fetchoverlap.c: Added new test case.
15871
15872         * support/regression/tests/bp.c: Added new test case.
15873
15874         * support/regression/tests/bug-448984.c: Added new test case.
15875
15876         * support/regression/tests/pow2shifts.c: Added new test case.
15877
15878         * src/z80/gen.c: Turned off the noise it normally generates for the release.
15879         (genlshTwo): Fixed right shift for count > 8.
15880
15881         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
15882
15883 2001-09-08    <johan AT FRIJA>
15884
15885         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
15886
15887 2001-09-07    <johan AT FRIJA>
15888
15889         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
15890
15891         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
15892
15893 2001-09-06    <johan AT FRIJA>
15894
15895         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
15896         * bernhard noted me at this: "() equals to (void)" (1.38)
15897
15898 2001-09-05    <johan AT FRIJA>
15899
15900         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
15901
15902 2001-09-04    <johan AT FRIJA>
15903
15904         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
15905
15906
15907 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
15908
15909         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
15910
15911 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
15912
15913         * link/z80/aslink.h: Fixed path for PATH_MAX
15914
15915 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
15916
15917         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
15918
15919         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
15920
15921         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
15922
15923         * 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.
15924
15925 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
15926
15927         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
15928         (genCmp): Fixed up genCmp for the GB with longs.
15929
15930         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
15931
15932         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
15933
15934         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
15935
15936         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
15937
15938 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
15939
15940         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
15941
15942 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
15943
15944         * 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.
15945
15946         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
15947
15948 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
15949
15950         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
15951
15952         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
15953
15954 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
15955
15956   * sim/ucsim/configure:    little improvement of Cygwin-detection
15957   * sim/ucsim/configure.in: little improvement of Cygwin-detection
15958   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
15959   * support/regression/tests/bug-221100.c: small changes for mcs51
15960   * support/regression/tests/bug-221168.c: small changes for mcs51
15961   * support/regression/tests/bug-227710.c: small changes for mcs51
15962   * support/regression/tests/staticinit.c: small changes for mcs51
15963   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
15964   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
15965   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
15966
15967 $Revision$