* device/include/stdbool.h: do not define __bool_true_false_are_defined
[fw/sdcc] / ChangeLog
1 2007-07-10 Maarten Brock <sourceforge.brock AT dse.nl>
2
3         * device/include/stdbool.h: do not define __bool_true_false_are_defined
4           and bool for targets that do not fully support it.
5         * support/regression/tests/bug1546986.c,
6         * support/regression/tests/bug1723128.c,
7         * support/regression/tests/bug1734654.c,
8         * support/regression/tests/bug1738367.c,
9         * support/regression/tests/constantRange.c: only use bool if allowed
10
11 2007-07-09 Maarten Brock <sourceforge.brock AT dse.nl>
12
13         * src/mcs51/peep.c (isCallerSaveFunc): fixed bug 1749275, thanks Robert
14           Larice, also handle function pointers
15         * support/regression/tests/bug1749275.c: new, added
16
17 2007-07-03 Borut Razem <borut.razem AT siol.net>
18
19         * src/mcs51/gen.c, src/avr/gen.c, src/pic/gen.c, src/z80/gen.c,
20           src/pic16/gen.c, src/hc08/gen.c, src/ds390/gen.c: fixed RFE
21           #1746528: SDCC should ignore ':' in inline assembler comments
22         * device/include/typeof.h: fixed bug #1747142: typeof.h needs fixing
23
24 2007-07-02 Maarten Brock <sourceforge.brock AT dse.nl>
25
26         * device/include/mcs51/C8051F360.h: fixed bug #1746410, thanks Chris Jones
27         * device/lib/mcs51/crtxclear.asm: do not set __XPAGE unconditionally
28
29 2007-06-29 Borut Razem <borut.razem AT siol.net>
30
31         * src/SDCCmain.c: fixed bug
32           #1744746: SDCC #4867: broken option --xram-size
33
34 2007-06-28 Borut Razem <borut.razem AT siol.net>
35
36         * sim/ucsim/configure.in, sim/ucsim/configure, sim/ucsim/ddconfig_in.h:
37           find out the endianess of host machine for ucsim
38
39 2007-06-27 Borut Razem <borut.razem AT siol.net>
40
41         * support/regression/generate-cases.py: corrected the file name
42           in warning
43         * configure.in, configure, sdccconf_in.h: find out the endianess of
44           host machine
45         * src/SDCC.y: fixed bug #1744146: Crash when compiling array of
46           negative size
47
48 2007-06-27 Gudjon I. Gudjonsson <gudjon AT gudjon.org>
49
50         * device/include/mcs51/p89c66x.h: NXP header file, OK to change licence
51
52 2007-06-26 Borut Razem <borut.razem AT siol.net>
53
54         * support/regression/generate-cases.py: display warning if function
55           list is empty; implemented more flexible rule for detection of
56           testing functions, allowing return type 'void' in the same line as
57           the function name in the function definition
58         * support/regression/tests/bug-1654060.c: corrected test
59         * support/librarian/sdcclib.c: fixed warning:
60           format '%s' expects type 'char *', but argument 2 has type 'int'
61
62 2007-06-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
63
64         * support/librarian/sdcclib.c: Added feature Requests [1510635]
65           Multiple infiles for sdcclib.
66
67 2007-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
68         * src/SDCCast.c (inlineFindMaxBlockno, createFunction): fixed
69           bug 1731741
70
71 2007-06-18 Borut Razem <borut.razem AT siol.net>
72
73         * src/SDCCmain.c: removed option -C since SDCC compiler doesn't know
74           how to handle comments, so they have to be removed by the
75           preprocessor; fixed bug #1738926:SDCC #4852: broken option -V
76         * src/SDCCmain.c, src/SDCCargs.h, src/ds390/main.c, src/mcs15/main.c,
77           src/pic16/main.c, src/pic/main.c, src/z80/main.c,
78           support/Util/SDCCerr.c, support/Util/SDCCerr.h:
79           table driven option hadling
80
81 2007-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
82
83         * src/SDCCast.c (decorateType),
84         * src/SDCCicode.c (geniCodeConditional): moved optimization for '?' from
85           iCode to ast level to fix bug 1738367
86         * support/regression/tests/bug1738367.c: new, added
87
88 2007-06-15 Raphael Neider <rneider AT web.de>
89
90         * src/pic16/devices.inc,
91         * device/lib/pic16/pics.all,
92         * device/include/pic16/pic18fregs.h,
93         * device/include/pic16/pic18f[24][45]20.h,
94         * device/lib/pic16/libdev/pic18f[24][45]20.c: added support for
95           18f2420, 18f2520, and 18f4420 devices, updated 18f4520 definitions
96         * device/lib/pic16/Makefile.in: faster cleanup
97
98 2007-06-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
99
100         * src/mcs51/peeph.def: added 177.i (mov from a is slightly cheaper)
101
102 2007-06-13 Raphael Neider <rneider AT web.de>
103
104         * src/SDCCmain.c: prevent NULL pointer dereference, avoid warning
105
106 2007-06-12 Raphael Neider <rneider AT web.de>
107
108         * support/scripts/inc2h.pl: conditionally emit defines for SFR bits,
109           suppress bit defines if NO_BIT_DEFINES is #define'd
110         * device/include/pic/pic*.h: recreated all headers to include
111           conditional bit defines
112         * device/include/pic/pic16f886.h,
113         * device/include/pic/pic16f887.h: fixed based on newer .inc file
114         * device/include/pic/recreate.sh: script to recreate the complete
115           device library files based on the currently supported devices
116
117 2007-06-12 Borut Razem <borut.razem AT siol.net>
118
119         * src/pic16/main.c, src/SDCCargs.h, SDCCmain.c,
120           support/regression/Makefile.in, support/scripts/build.mak,
121           support/scripts/Makefile.snapshot:
122           use new svn URL scheme
123         * doc/sdccman.lyx: SDCC Wiki moved to
124           http://sdcc.wiki.sourceforge.net/
125
126 2007-06-10 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
127
128         * src/mcs51/peeph.def: disabled rule 132.d to fix #1734654
129         * support/regression/tests/bug1734654.c: added
130
131 2007-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
132
133         * src/SDCCast.c (decorateType): optimized '?' for equal operands
134         * src/SDCCicode.c (geniCodeConditional): optimization for bit result
135           with literal operands
136
137 2007-06-10 Borut Razem <borut.razem AT siol.net>
138
139         * as/link/z80/lklibr.c: fixed mingw build warning
140           lklibr.c:575: warning: implicit declaration of function 'tolower'
141         * src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c,
142           src/z80/main.c: move target specific options from src/SDCCmain.c
143           to src/<target>/main.c
144
145 2007-06-09 Borut Razem <borut.razem AT siol.net>
146
147         * src/z80/gen.c: fixed bug #1294691: nested ifs make compiler crash;
148           removed unused swap_sense; removed outBitCLong, replaced with outBitC
149         * support/regression/tests/bug-1294691.c: added
150
151 2007-06-09 Maarten Brock <sourceforge.brock AT dse.nl>
152
153         * src/SDCCmem.c (allocDefault): removed check sym->level==0 for SPEC_ABSA,
154           can also be static, fixes bug 1733438
155         * src/SDCCsymt.c (checkSClass): static local vars in reentrant funcs can
156           have absolute address too
157           (computeType): added optimization for 'cond ? true : false'
158         * support/regression/tests/absolute.c: added test for static absolute var
159
160 2007-06-08 Raphael Neider <rneider AT web.de>
161
162         * src/regression/Makefile: suppress parallel builds, allow easy
163           switching between pic14/pic16 ports
164         * src/regression/picregs.h: added pic14/16 header file switch
165         * src/regression/{compare7.c,compare8.c,compare9.c,compare10.c,
166           inline.c,nestfor.c,string1.c}: include "picregs.h"
167
168 2007-06-07 Borut Razem <borut.razem AT siol.net>
169
170         * sim/ucsim/*.[ch], sim/ucsim/configure, sim/ucsim/configure.in:
171           permanent solution to suppress GCC 4.2.0 c++ warning:
172           deprecated conversion from string constant to `char *'
173           use 'const char *' where ever required
174         * support/regression/generate-cases.py: implemented more flexible rule
175           for detection of testing functions, allowing white-spaces surrounding
176           the function name and the 'void' parameter.
177         * support/regression/tests/constantRange.c,
178           support/regression/tests/scott-compare3.c: fixed failing regression
179           tests, uncovered by implementation of more flexible rule for detection
180           of testing functions
181
182 2007-06-04 Maarten Brock <sourceforge.brock AT dse.nl>
183
184         * src/SDCCast.c(decorateType): better optimize '!!' and comparisons
185
186 2007-06-04 Borut Razem <borut.razem AT siol.net>
187
188         * configure.in, configure, config_vc.awk: sdcc version number is now
189           stored in configure.in; removed .version
190         * configure.in, configure, sdcc.spec, doc/sdccman.lyx, doc/sdccman.lyx,
191           doc/INSTALL.txt: version bumped to 2.7.2
192         * sim/ucsim/configure.in, sim/ucsim/configure:
193           use "read" to read from .version
194
195 2007-06-03 Borut Razem <borut.razem AT siol.net>
196
197         * */Makefile.in: removed annoying warning:
198           Makefile:xx: Makefile.dep: No such file or directory
199
200 2007-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
201
202         * src/mcs51/gen.c (outBitC, genRet): used IS_OP_RUONLY,
203           (genNot, genXor): used toCarry, also fixes a bug for c = bit ^ val
204         * src/mcs51/ralloc.c: removed IS_OP_RUONLY + some cosmetic changes
205         * src/SDCCast.c (resultTypePropagate): propagate for '!',
206           (decorateType): also optimize comparisons with RESULT_TYPE_BIT,
207           bugfix: only use newBoolLink for bit result type
208         * src/SDCCicode.c (geniCodeLogic): added param tree,
209           bugfix: use newBoolLink if tree is bit type, bug appears when ruonly,
210           (geniCodeLogicAndOr): use IS_BIT,
211           (geniCodeJumpTable, geniCodeSwitch): added NULL param to geniCodeLogic,
212           (ast2iCode): added tree param to geniCodeLogic for comparisons
213         * src/SDCCsymt.h: added IS_OP_RUONLY and IS_OP_ACCUSE
214         * support/regression/tests/bug1723128.c: added test NotZero
215
216 2007-06-01 Borut Razem <borut.razem AT siol.net>
217
218         * SDCPP synchronized with GCC CPP release version 4.2.0,
219           currently the latest release:
220         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
221           support/cpp2/c-ppoutput.c, support/cpp2/cppdefault.c,
222           support/cpp2/cppdefault.h, support/cpp2/except.h,
223           support/cpp2/libcpp/directives.c, support/cpp2/libcpp/expr.c,
224           support/cpp2/libcpp/files.c, support/cpp2/libcpp/include/cpplib.h,
225           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
226           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/macro.c,
227           support/cpp2/libcpp/mkdeps.c, support/cpp2/libiberty/getpwd.c,
228           support/cpp2/libiberty/hashtab.c, support/cpp2/optc-gen.awk,
229           support/cpp2/opth-gen.awk, support/cpp2/opts.c,
230           support/cpp2/opts.h, support/cpp2/output.h,
231           support/cpp2/prefix.c, support/cpp2/sdcpp-opts.c,
232           support/cpp2/sdcpp.dsp, support/cpp2/sdcpp.opt,
233           support/cpp2/system.h, support/cpp2/version.c,
234           support/cpp2/Makefile.in: modified
235         * support/cpp2/opts-common.c: added
236         * device/lib/pic16/libdev/pic18f[24][45]j10.c: fixed svn atrributes
237         * device/lib/pic16/libdev/pic18f[24]5j10.c:
238           search for included source file in local directory
239         * sim/ucsim/configure, sim/ucsim/configure.in:
240           temporary solution to suppress GCC 4.2.0 c++ warning:
241           deprecated conversion from string constant to `char *'
242
243 2007-06-01 Raphael Neider <rneider AT web.de>
244
245         * device/lib/pic/libdev/pic12f683.c,
246         * device/include/pic/pic12f683.h: added GPIO bits
247
248 2007-06-01 Raphael Neider <rneider AT web.de>
249
250         * doc/sdccman.lyx: added --disable-pic16-port, fixed some `--' and
251           quotation marks, clarified role of PIC14 vs. PIC16 ports
252         * src/pic16/devices.inc,
253         * device/include/pic16/pic18fregs.h,
254         * device/include/pic16/pic18f[24][45]j10.h,
255         * device/lib/pic16/pics.all,
256         * device/lib/pic16/libdev/pic18f[24][45]j10.c: added support for
257           18f24j10, 18f25j10, 18f44j10, and 18f45j10
258         * device/lib/pic16/libio/{i2c,adc,usart}.ignore: do not build IO libs
259           for new devices as they are not yet supported by gputils
260
261 2007-05-31 Borut Razem <borut.razem AT siol.net>
262
263         * Small Device C Compiler 2.7.0 released
264         * .version, sdcc.spec, doc/sdccman.lyx, doc/INSTALL.txt:
265           changed sdcc version to 2.7.1
266         * support/scripts/sdcc.nsi: added How to create WIN32 release
267           setup.exe package
268
269 2007-05-29 Maarten Brock <sourceforge.brock AT dse.nl>
270
271         * doc/sdccman.lyx: documented initialization and allocation of absolute
272           variables, bit parameter passing, the need for function pointers to be
273           reentrant and alpha quality support of inline and retrict
274
275 2007-05-26 Borut Razem <borut.razem AT siol.net>
276
277         * support/regression/tests/bug1057979.c, support/regression/tests/malloc.c,
278           support/regression/fwk/include/testfwk.h: fixed compilation on Mac OS x
279         * docs/knownbugs.html: updated
280
281 2007-05-25 Maarten Brock <sourceforge.brock AT dse.nl>
282
283         * doc/sdccman.lyx: inserted footnotes about inline assembler labels,
284           thanks Jan Waclawek
285         * src/mcs51/gen.c (aopPut): fixed part of bug 1723128 when result is
286           AOP_CRY and ruonly
287           (gencjneshort): optimized when left is AOP_DIR
288         * src/SDCCglue.c (printIvalStruct): fixed other part of bug 1723128 for
289           initializing unions in a struct/array
290         * support/regression/fwk/include/testfwk.h: added defines for data, near
291           and far for host and z80
292         * support/regression/tests/bug1723128.c: new, added
293
294 2007-05-22 Borut Razem <borut.razem AT siol.net>
295
296         * doc/knownbugs.html: updated
297
298 2007-05-21 Raphael Neider <rneider AT web.de>
299
300         * src/pic16/glue.c (pic16_initPointer): avoid assertion, emit better
301           error message instead
302         * src/pic/pcoderegs.c (pCodeOptime2pCodes): keep register state intact
303
304 2007-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
305
306         * src/mcs51/peeph.def (257.b): disabled to fix bug 1721024
307
308 2007-05-21 Raphael Neider <rneider AT web.de>
309
310         * src/pic/pcoderegs.c (pCodeOptime2pCodes): fixed bogus optimization,
311           closes #1722392
312         * src/regression/gpsim_assert.h,
313         * src/regression/Makefile,
314         * src/regression/pcodeopt.c: regression test for the above fix
315
316 2007-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
317
318         * src/SDCCpeeph.c (labelIsUncondJump): ignore identical labels for
319           jumps to self, fixed bug 1717281
320
321 2007-05-10 Borut Razem <borut.razem AT siol.net>
322
323         * support/scripts/gen_known_bugs.pl: cosmetic fix
324         * doc/knownbugs.html: generated by gen_known_bugs.pl
325
326 2007-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
327
328         * src/SDCCast.c (createFunction): also generate non-inlined version of
329           function for functions declared as "static inline"
330         * src/SDCCast.c (fixupInline, inlineAddDecl): reset symbol state so
331           function can be inlined after non-inlined version generated.
332
333 2007-05-10 Borut Razem <borut.razem AT siol.net>
334
335         * support/scripts/gen_known_bugs.pl: added script
336           which generates knownbugs.html
337
338 2007-05-09 Maarten Brock <sourceforge.brock AT dse.nl>
339
340         * doc/knownbugs.html: updated for release 2.7.0
341
342 2007-05-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
343
344         * device/include/mcs51/uPSD33xx.h: Added patch by Jan Waclawek.
345
346 2007-05-08 Maarten Brock <sourceforge.brock AT dse.nl>
347
348         * src/ds390/gen.c (emitcode): don't change properties of previous lines,
349           (throughout): updated generating comments
350         * src/mcs51/gen.c (emitcode): don't change properties of previous lines,
351           (throughout): updated generating comments
352         * src/SDCCpeeph.c (peepHole): continue searching at the first replaced
353           rule instead of at the second, or it might skip lines when removing the
354           complete match
355         * support/regression/tests/bug1714204.c: changed test to foo
356
357 2007-05-08 Borut Razem <borut.razem AT siol.net>
358
359         * doc/sdccman.lyx: changed sdcc version to 2.7.0,
360           thanks to SDCC Distributed Compile Farm members,
361           added Z80 and GBZ80 command line options
362         * .version, doc/INSTALL.txt, sdcc.spec: changed sdcc version to 2.7.0
363
364 2007-05-08 Maarten Brock <sourceforge.brock AT dse.nl>
365
366         * device/lib/mcs51/crtxinit.asm: added disabled version for dual dptr
367         * device/include/mcs51/uPSD33xx.h: added sfr DPS as alias for DPTC
368         * support/regression/tests/longlit.c: modified to be tested at all and
369           to pass the actual test
370
371 2007-05-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
372
373         * device/include/mcs51/uPSD33xx.h: Added.
374
375 2007-05-07 Maarten Brock <sourceforge.brock AT dse.nl>
376
377         * device/lib/_gptrput.c,
378         * device/lib/_gptrget.c: removed old code,
379          (_gptrgetWord),
380         * src/ds390/gen.c (genGenPointerGet): fixed bug 1714204
381         * support/regression/tests/bug1714204.c: new, added
382
383 2007-05-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
384
385         * support/regression/tests/regtrack.c: test was never executed
386           because of the regression test being picky about white spaces.
387         * device/lib/mcs51/crtclear.asm: added comment
388
389 2007-05-06 Raphael Neider <rneider AT web.de>
390
391         * device/lib/pic/Makefile.rules,
392         * device/lib/pic16/Makefile.rules: make sure *.ignore file exists,
393           made "&> /dev/null" redirection sh-safe ("> /dev/null 2>&1")
394
395 2007-05-06 Raphael Neider <rneider AT web.de>
396
397         * src/pic16/device.h,
398         * src/pic16/main.h,
399         * src/pic16/main.c (pic16_optionsTable,_pic16_parseOptions,
400           _pic16_setDefaultOptions): removed/reordered command-line args
401         * doc/sdccman.lyx: updated PIC14 and PIC16 documentation (supported
402           devices, regrouped command line args, environment variables),
403           clarified sone points, added sections on how to add devices to the
404           PIC14/PIC16 ports
405
406 2007-05-06 Maarten Brock <sourceforge.brock AT dse.nl>
407
408         * src/z80/peeph.def: fixed bug in rule 2
409
410 2007-05-05 Maarten Brock <sourceforge.brock AT dse.nl>
411
412         * src/port.h: added TARGET_MCS51_LIKE
413         * src/SDCCpeeph.c (labelIsUncondJump): new, added, other targets could
414           take advantage of it too
415         * src/z80/gen.c (genIpush): push b, d or h directly instead of using a,
416           (shiftR2Left2Result): Optimized: don't check shifting by 0
417         * src/z80/peeph-z80.def,
418         * src/z80/peeph.def: whole set of new rules by Philipp Krause with some
419           modifications, see patch 1700823
420         * src/mcs51/peep.c (): fixed bug 1712928
421         * support/regression/tests/bug1712928.c: new, added
422
423 2007-05-05 Borut Razem <borut.razem AT siol.net>
424
425         * device/lib/pic16/Makefile.common.in,
426           device/lib/pic/Makefile.common.in, sim/ucsim/cmd.src/Makefile.in:
427           removed bash dependencies
428
429 2007-05-01 Borut Razem <borut.razem AT siol.net>
430
431         * src/SDCCicode.c:
432           fixed bug #1710507: --i-code-in-asm makes compile fail
433           all iCode comments are now one liners
434         * src/mcs51/gen.c: fixed memory leak
435
436 2007-05-01 Raphael Neider <rneider AT web.de>
437
438         * device/lib/pic/libdev/*.c
439         * device/include/pic/*.h: regenerated all device libs from updated
440           .inc files
441         * support/scripts/inc2h.pl: documented usage, now uses strict to
442           catch more bugs
443
444 2007-04-30 Borut Razem <borut.razem AT siol.net>
445
446         * doc/sdccman.lyx:
447           fixed bug #1669175: Problem with space in output paths
448           documented how to use paths with spaces for Windows users
449
450 2007-04-29 Borut Razem <borut.razem AT siol.net>
451
452         * Fixed svn:eol-style and svn:keywords properties
453         * src/SDCCval.c: fixed bug
454           #1592871: Segfault with "large" const arrays of characters
455           replaced recursion with iteration
456         * Removed svn:executable property from non-executable files
457
458 2007-04-29 Maarten Brock <sourceforge.brock AT dse.nl>
459
460         * src/mcs51/gen.c (genRet): fixed bug 1707003
461
462 2007-04-27 Raphael Neider <rneider AT web.de>
463
464         * src/pic16/pcode.c (pBlockRemoveUnusedLabels,pic16_pBlockAddInval,
465           createReachingDefinitions,assignValnums,pic16_destructDF,
466           pic16_createDF,pic16_vcg_dumpedges,pic16_vcg_dump_default):
467           prevent NULL pointer dereferences
468         * device/lib/pic/libdev/pic16f886.c,
469         * device/lib/pic/libdev/pic16f887.c: svn mv'ed to disabled_* to
470           prevent building them, gputils do not really support them yet
471
472 2007-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
473
474         * device/lib/_ltoa.c: 36 bytes less __data mem. This really
475           helps printf_small. 32 bytes more __idata mem.
476
477 2007-04-27 Raphael Neider <rneider AT web.de>
478
479         * src/pic/pcode.c (addpCode2pBlock,LinkFlow,pBlockRemoveUnusedLabels):
480           return early when pb or pb->pcHead is NULL (patch #1708427)
481         * src/regression/empty.c,
482         * src/regression/Makefile: added test with empty functions
483         * support/Util/SDCCerr.c: fixed typo in E_INIT_STRUCT message
484
485 2007-04-27 Borut Razem <borut.razem AT siol.net>
486
487         * src/SDCCast.c: fixed feature request
488           #1547512: Redundant strings linked when using sizeof("abc")
489
490 2007-04-23 Borut Razem <borut.razem AT siol.net>
491
492         * doc/sdccman.lyx, src/SDCCmain.c:
493           peep-hole comments are generated only if --fverbose-asm option is
494           specified and --no-peep-comments is not, as proposed by Frieder.
495         * support/regression/Makefile.in: compile regression tests with
496           --fverbose-asm option so one can "grep" whether a new (or an old)
497           peephole is (still) applied; requested by Frieder.
498
499 2007-04-23 Kevin Buettner <kevin AT buettner.to>
500
501         * device/include/pic/pic16f886.h,
502         * device/include/pic/pic16f887.h,
503         * device/lib/pic/libdev/pic16f886.c,
504         * device/lib/pic/libdev/pic16f887.c,
505         * device/include/pic/pic14devices.txt,
506         * device/lib/pic/libdev/devices.txt: Add 16f886 and 16f887.
507
508 2007-04-23 Kevin Buettner <kevin AT buettner.to>
509
510         * device/lib/pic/libsdcc/idata.c: PAGESEL _main before going there,
511           fixes #1704666
512
513 2007-04-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
514
515         * device/lib/_memset.c: assembler version for mcs51
516
517 2007-04-22 Borut Razem <borut.razem AT siol.net>
518
519         * support/scripts/listerr.c: program to create the list of errors and
520           warnings list from - added
521         * doc/sdccman.lyx: removed the note
522           "For list of warnings and corresponding codes, see err_warn.txt"
523         * src/SDCCsymt.c: fixed bug #1699804:
524           Bug with some uses of sizeof(static local array) (MCS51)
525         * support/regression/tests/bug-1699804.c: added
526
527 2007-04-20 Maarten Brock <sourceforge.brock AT dse.nl>
528
529         * as/mcs51/asmain.c (search_path_append, search_path_fopen): new, added,
530           (main): added option -i,
531           (asmbl, case S_INCL): use search_path_fopen,
532           mostly from patch 1579668 by Peter Miller, thanks
533         * src/z80/main.c: fixed typo --callee-saves-bc
534         * device/include/mcs51/compiler.h: added sfrword for Tasking
535
536 2007-04-20 Borut Razem <borut.razem AT siol.net>
537
538         * src/z80/main.c: replaced reserved keyword asm with asmblr
539
540 2007-04-19 Borut Razem <borut.razem AT siol.net>
541
542         * src/port.h: use const pointers to strings
543         * src/SDCCargs.h: declared getStringArg() and getIntArg()
544         * src/pic16/main.c: include SDCCargs.h
545         * src/SDCCglobl.h: code_seg and const_seg are not pointers to
546           const char, since the strings are dynamically allocated
547         * src/SDCCmain.c: options.code_seg and options.const_seg are
548           dynamically allocated; check port specific command line options
549           before the general ones
550         * src/z80/main.c: fixed bug #1631895: codeseg/constseg #pragma fail
551
552 2007-04-18 Maarten Brock <sourceforge.brock AT dse.nl>
553
554         * device/include/ds400rom.h,
555         * device/lib/ds390/lcd390.c,
556         * device/lib/ds390/memcpyx.c,
557         * device/lib/ds390/rtc390.c,
558         * device/lib/ds400/ds400rom.c,
559         * device/lib/ds400/memcpyx.c,
560         * device/lib/hc08/_ret.c: more replacements of keywords with their
561           double underscore equivalents
562         * device/lib/ds390/Makefile.in,
563         * device/lib/ds400/Makefile.in,
564         * device/lib/gbz80/Makefile.in,
565         * device/lib/hc08/Makefile.in,
566         * device/lib/mcs51/Makefile.in,
567         * device/lib/z80/Makefile.in: added --std-c89 to CFLAGS
568
569 2007-04-17 Borut Razem <borut.razem AT siol.net>
570
571         * doc/sdccman.lyx, src/SDCCmain.c, src/SDCCglobal.h, src/ds390/gen.c,
572           src/hc08/gen.c, src/mcs51/gen.c, src/mcs51/rtrack.c:
573           fixed #1493816: option --no-gen-comments: --no-gen-comments renamed
574           to --fverbose-asm, to be gcc'ish
575
576 2007-04-17 Maarten Brock <sourceforge.brock AT dse.nl>
577
578         * src/mcs51/gen.c (aopOp): set size to 1 for ruonly, fixes bug 1699455
579
580 2007-04-17 Borut Razem <borut.razem AT siol.net>
581
582         * doc/sdccman.lyx: fixed #1701874: Mac OSX references in SDCC manual
583         * device/lib/ds400/tinibios.c, device/lib/hc08/_divuint.c,
584           device/lib/hc08/_divulong.c: replaced _asm and _endasm keywords
585           with their double underscore equivalent
586
587 2007-04-14 Borut Razem <borut.razem AT siol.net>
588
589         * doc/sdccman.lyx: some additional "freeware" replaced with "free open
590           source"
591
592 2007-04-13 Borut Razem <borut.razem AT siol.net>
593
594         * doc/sdccman.lyx: -pedantic-parse-number is not in conformance with
595           C99 standard
596         * device/examples/serialcomm/windows/serial.[ch],
597           device/examples/serialcomm/windows/test_serialcomm.cpp:
598           updated by Bela Torok
599         * device/examples/serialcomm/windows/serialcomm.dsw,
600           device/examples/serialcomm/windows/serialcomm.dsp: added
601
602 2007-04-13 Jan Waclawek <wek AT efton.sk>
603
604         * doc/sdccman.lyx: additions and changes at various places
605           (submitted as #1697136).
606           (svn commit by Frieder Ferlemann <Frieder.Ferlemann AT web.de>)
607
608 2007-04-10 Borut Razem <borut.razem AT siol.net>
609
610         * doc/cdbfileformat.lyx, doc/sdccman.lyx, doc/test_suite_spec.lyx:
611           LyX file format changed to 245
612         * doc/sdccman.lyx, doc/README.txt, sdc/SDCC.lex, src/SDCCglue.c:
613           "FreeWare" replaced with "free open source"
614
615 2007-04-10 Maarten Brock <sourceforge.brock AT dse.nl>
616
617         * device/include/mcs51/C8051F120.h: added some defines for bits in RSTSRC
618
619 2007-04-08 Maarten Brock <sourceforge.brock AT dse.nl>
620
621         * device/include/pic16/pic18fregs.h,
622         * device/lib/_bp.c,
623         * device/lib/_decdptr.c,
624         * device/lib/_divsint.c,
625         * device/lib/_divslong.c,
626         * device/lib/_divuint.c,
627         * device/lib/_divulong.c,
628         * device/lib/_fs2schar.c,
629         * device/lib/_fs2sint.c,
630         * device/lib/_fs2slong.c,
631         * device/lib/_fs2uchar.c,
632         * device/lib/_fs2uint.c,
633         * device/lib/_fs2ulong.c,
634         * device/lib/_fsadd.c,
635         * device/lib/_fscmp.c,
636         * device/lib/_fsdiv.c,
637         * device/lib/_fseq.c,
638         * device/lib/_fsget1arg.c,
639         * device/lib/_fsget2args.c,
640         * device/lib/_fsgt.c,
641         * device/lib/_fslt.c,
642         * device/lib/_fsmul.c,
643         * device/lib/_fsneq.c,
644         * device/lib/_fsnormalize.c,
645         * device/lib/_fsreturnval.c,
646         * device/lib/_fsrshift.c,
647         * device/lib/_fssub.c,
648         * device/lib/_fsswapargs.c,
649         * device/lib/_gptrget.c,
650         * device/lib/_gptrgetc.c,
651         * device/lib/_gptrput.c,
652         * device/lib/_logexpf.c,
653         * device/lib/_modsint.c,
654         * device/lib/_modslong.c,
655         * device/lib/_moduint.c,
656         * device/lib/_modulong.c,
657         * device/lib/_mulint.c,
658         * device/lib/_mullong.c,
659         * device/lib/_schar2fs.c,
660         * device/lib/_ser.c,
661         * device/lib/_setjmp.c,
662         * device/lib/_sint2fs.c,
663         * device/lib/_slong2fs.c,
664         * device/lib/_spx.c,
665         * device/lib/_uchar2fs.c,
666         * device/lib/_uint2fs.c,
667         * device/lib/_ulong2fs.c,
668         * device/lib/asincosf.c,
669         * device/lib/atanf.c,
670         * device/lib/calloc.c,
671         * device/lib/ds390/tinibios.c,
672         * device/lib/ds400/tinibios.c,
673         * device/lib/expf.c,
674         * device/lib/free.c,
675         * device/lib/hc08/_mulint.c,
676         * device/lib/logf.c,
677         * device/lib/malloc.c,
678         * device/lib/printf_fast.c,
679         * device/lib/printf_tiny.c,
680         * device/lib/printfl.c,
681         * device/lib/realloc.c,
682         * device/lib/ser_ir.c,
683         * device/lib/serial.c,
684         * support/regression/tests/libmullong.c: replaced all special keywords
685           with their double underscore equivalent
686         * support/regression/ports/mcs51-xstack-auto/spec.mk,
687         * device/lib/Makefile.in: compile libs with --std-c99 instead of
688           --std-sdcc99
689         * src/mcs51/gen.c (outBitC): don't store if result is return-use-only,
690           (genRet): if the bit-symbol is ruonly it already is in the carry
691         * src/mcs51/ralloc.c (regTypeNum): make regType REG_CND for ruonly bit
692         * src/SDCCast.c (createFunction): applied patch 887171 by Stas Sergeev
693         * src/SDCCicode.c (ast2iCode): '!', GETHBIT, GETABIT: only set operand
694           type UCHAR if dest is not bit
695
696 2007-04-03 Maarten Brock <sourceforge.brock AT dse.nl>
697
698         * device/include/math.h,
699         * device/lib/cotf.c,
700         * device/lib/expf.c,
701         * device/lib/sincoshf.c: changed XMAX to C99 HUGE_VALF
702
703 2007-04-01 Borut Razem <borut.razem AT siol.net>
704
705         * src/SDCC.lex, src/SDCCmain.c, support/cpp2/sdcpp.c:
706           fixed bug #1692042: input buffer overflow...scanner uses REJECT
707         * support/cpp2/sdcpp.c: fixed recursion bug - internal_error() called
708           gcc_unreachable() called internal_error()...
709
710 2007-03-30 Raphael Neider <rneider AT web.de>
711
712         * src/pic/ralloc.c (isData): suppress garbage debug output
713
714 2007-03-28 Borut Razem <borut.razem AT siol.net>
715
716         * doc/sdccman.lyx:
717           "Nightly Snapshots" replaced with "Snapshot Builds", since the SDCC
718           is developed, built and used worldwide, and the word "night" doesn't
719           make any sense.
720
721 2007-03-28 Maarten Brock <sourceforge.brock AT dse.nl>
722
723         * device/include/mcs51/C8051F360.h: new, added
724         * device/include/mcs51/C8051F520.h: fixed buggy sbit addresses SPI0CN
725
726 2007-03-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
727
728         * src/SDCC.y (declaration_specifiers, function_specifier),
729         * support/Util/SDCCerr.c,
730         * support/Util/SDCCerr.h,
731         * src/SDCCsymt.h,
732         * src/SDCCsymt.c (mergeSpec, checkFunction): Parse and validate the
733           inline keyword
734         * src/SDCCmem.c (deallocParms),
735         * src/SDCCast.c: support for function inlining, not quite complete
736         * src/SDCCsymt.c (printTypeChain, printTypeChainRaw): display
737           'restrict' qualifier
738
739 2007-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
740
741         * src/mcs51/gen.c (saveRegisters, unsaveRegisters): free some bitVects,
742           (saveRBank, unsaveRBank): don't save bits,
743           (genFunction, genEndFunction): save bits exactly once, fix bug 1535242
744         * support/regression/tests/bug1535242.c: new, added
745         * device/include/assert.h: applied patch 1686533 to fix bug 1686528,
746           thanks Alexey Shamrin <shamrin AT gmail.com>,
747           made assert.h header ANSI compliant (added a check for NDEBUG macro,
748           removed header guard)
749         * .version,
750         * sdcc.spec: bumped version to 2.6.5
751         * src/SDCCmain.c(parseCmdLine): fixed bug 1677144
752
753 2007-03-22 Borut Razem <borut.razem AT siol.net>
754
755         * debugger/mcs51/cmd.c, debugger/mcs51/sdcdb.c:
756           fixed bug #1653671: sdcdb integration into ddd is broken
757
758 2007-03-22 Raphael Neider <rneider AT web.de>
759
760         * src/pic/gen.c (popGetExternal): augmented to also create references
761           to external variables (not only labels),
762           (genCall): comment on plan to reduce PAGESEL overhead,
763           (genFunction, genEndFunction): also save/restore FSR around interrupt
764           handling code, removed lots of unused code
765           (genDivOneByte): release acquired temp register
766         * src/pic/glue.c (pic14createInterruptVect): adapt to new signature
767           of popGetExternal
768         * device/lib/pic/libsdcc/shadowregs.c: NEW, provide storage location
769           for registers that need to be saved during interrupts (FSR, STATUS,
770           PCLATH; W needs special handling), currently only FSR is used
771
772 2007-03-22 Raphael Neider <rneider AT web.de>
773
774         * device/include/pic/pic14devices.txt: 16f688 has only one config word
775
776 2007-03-19 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
777
778         * /as/link/mcs51/aslink.dsp: Object extension for mcs51 is 'rel' not 'o'.
779
780 2007-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
781
782         * src/mcs51/peeph.def (263.x): fixed bug for volatile variables
783
784 2007-03-14 Maarten Brock <sourceforge.brock AT dse.nl>
785
786         * as/link/aslink.h: added LKOBJEXT
787         * as/link/hc08/link_hc08.dsp,
788         * as/link/hc08/Makefile.bcc,
789         * as/link/hc08/Makefile.in,
790         * as/link/mcs51/aslink.dsp,
791         * as/link/mcs51/Makefile.bcc,
792         * as/link/mcs51/Makefile.in: moved lkamof51.c and lkdata.c
793         * as/link/hc08/lkaomf51.c,      as/link/mcs51/lkaomf51.c,
794         * as/link/lkaomf51.c: merged and moved
795         * as/link/hc08/lkdata.c,        as/link/mcs51/lkdata.c,
796         * as/link/z80/lkdata.c,
797         * as/link/lkdata.c: merged and moved
798         * as/link/hc08/lkmain.c,
799         * as/link/mcs51/lkmain.c: cosmetic changes
800         * as/link/z80/lkeval.c,         as/link/lkeval.c: merged
801         * as/link/lklex.c: use LKOBJEXT
802         * as/link/z80/lklist.c,         as/link/lklist.c: merged,
803           ANSI-fied functions, removed bubble-sorts
804         * as/link/z80/lksym.c           as/link/lksym.c: merged,
805           ANSI-fied functions
806         * as/link/z80/linkgbz80.dsp,
807         * as/link/z80/linkz80.dsp,
808         * as/link/z80/Makefile.in: added lkaomf51.c and lknoice.c,
809           moved lkdata.c, lkeval.c, lkhead.c, lklex.x, lklist.c, lksym.c
810         * as/link/z80/lkhead.c,
811         * as/link/z80/lklex.c: deleted
812         * as/link/z80/lklibr.c: moved LKOBJEXT to aslink.h
813         * as/link/z80/lkmain.c: added copyfile()
814
815 2007-03-13 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
816
817         * device/include/mcs51/P89LPC925.h: Added missing P1_6 and P1_7.
818
819 2007-03-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
820
821         * device/lib/_strlen.c: assembler version for mcs51
822
823 2007-03-13 Raphael Neider <rneider AT web.de>
824
825         * device/include/pic16/pic18f2221.h,
826         * device/include/pic16/pic18f2321.h,
827         * device/include/pic16/pic18f2331.h,
828         * device/include/pic16/pic18f4221.h,
829         * device/include/pic16/pic18f4321.h,
830         * device/include/pic16/pic18f4331.h: fixed config byte location names
831         * support/scripts/inc2h-pic16.pl: removed debug output, emit
832           consistently named config byte locations
833
834 2007-03-13 Borut Razem <borut.razem AT siol.net>
835
836         * src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
837           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/s51.src/Makefile.in,
838           sim/ucsim/xa.src/Makefile.in, sim/ucsim/z80.src/Makefile.in,
839           as/link/z80/Makefile.in, as/z80/Makefile.in:
840           introduced LDFLAGS
841
842 2007-03-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
843
844         * device/lib/printfl.c: 13 bytes less __data mem (12 more __idata)
845         * device/lib/printf_large.c: pointer was converted to generic
846         pointer for mcs51 models other than model-small (Maarten noticed)
847
848 2007-03-10 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
849
850         * device/include/mcs51/ADuC84x.h: Added.
851
852 2007-03-10 Borut Razem <borut.razem AT siol.net>
853
854         * src/SDCC.lex, src/SDCCutil.[ch], src/SDCCval:
855           fixed RFE #1624219: double backslashes in filenames;
856           functions hexEscape(), octalEscape() and copyStr() moved from
857           SDCCval.c to SDCCutil.c and made them glovbally available
858
859 2007-03-09 Borut Razem <borut.razem AT siol.net>
860
861         * src/SDCC.lex, src/SDCCast.c. src/SDCCglobl.c, src/SDCCsymt.c,
862           src/SDCCval.c: fixed bugs #1676768: Wrong line number reported and
863           1673361: Missaligned comments in output files
864
865 2007-03-09 Raphael Neider <rneider AT web.de>
866
867         * device/include/pic/pic14devices.txt: fixed confsiz of 16f91[3467]
868
869 2007-03-09 Raphael Neider <rneider AT web.de>
870
871         * src/pic/gen.c,
872         * src/pic/glue.c,
873         * src/pic/ralloc.c: suppress undesired debug output
874         * src/SDCCmain.c (linkEdit): initialize c to quieten compiler
875
876 2007-03-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
877
878         * device/lib/printf_large.c: 6 bytes less __data mem (6 more __idata)
879
880 2007-03-07 Borut Razem <borut.razem AT siol.net>
881
882         * device/lib/pic16/libdev/pic18f[24][34]31.c:
883           search include files in the current directory
884
885 2007-03-04 Maarten Brock <sourceforge.brock AT dse.nl>
886
887         * src/SDCCglue.c (emitMaps, glue),
888         * src/SDCCmem.c (initMem, allocDefault): added x_abs for initialized
889           absolute xdata
890         * support/regression/tests/absolute.c: added xdata test
891
892 2007-03-03 Maarten Brock <sourceforge.brock AT dse.nl>
893
894         * src/SDCCmain.c (parseCmdLine): only set options.xstack_loc for mcs51,
895           added condition to macro, fixes bug 1666080
896
897 2007-03-02 Raphael Neider <rneider AT web.de>
898
899         * src/pic/gen.c (genGenPointerSet): removed bogus assertion
900
901 2007-02-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
902
903         * device/lib/mcs51/crtxclear.asm: pdata segment of 256 byte would not
904         be cleared. Unconditionally set __XPAGE
905         * src/hc08/gen.c: --no-gen-comments (RFE #1493816) for hc08
906
907 2007-02-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
908
909         * src/SDCCglobl.h,
910         * src/SDCCmain.c,
911         * src/mcs51/gen.c,
912         * src/mcs51/rtrack.c,
913         * src/ds390/gen.c,
914         * doc/sdccman.lyx: added --no-gen-comments
915         * src/mcs51/peeph.def: added 192.b, disabled 185
916
917 2007-02-25 Raphael Neider <rneider AT web.de>
918
919         * src/pic16/gen.c (genCast): fixed typo
920         * device/lib/pic16/Makefile.subdir: only install existing files
921         * device/lib/pic16/libdev/Makefile.in: build serially, avoid races
922
923 2007-02-25 Maarten Brock <sourceforge.brock AT dse.nl>
924
925         * device/lib/mcs51/crtcall.asm: new, added for indirect calls
926         * device/lib/mcs51/crtclear.asm,
927         * device/lib/mcs51/crtxclear.asm: renumbered labels
928         * device/lib/mcs51/Makefile.in: added crtcall.asm
929         * doc/sdccman.lyx: documented mcs51 crt* library startup code
930         * src/mcs51/gen.c (movc): removed,
931           (aopGet, genPlusBits): clear a after loading the carry (possibly from
932             acc.x or psw.x),
933           (toCarry, genSend, genRet): added function toCarry,
934           (genPcall): use "lcall @a+dptr" for functions w/o parameters,
935           (assignBit, genAssign, genCast): added function assignBit
936         * src/mcs51/Makefile.bcc: added rtrack.c
937         * src/mcs51/ralloc.h: made valueKnown a bitfield
938         * src/mcs51/rtrack.c (getReg, rtrackUpdate): added getReg,
939           fixed "jbc acc" and "cpl acc" bug, enhanced "cjne", "jnz" and "djnz",
940           disabled InvalidateAllRx for lcall __gptrput, added "xch a,rn"
941         * src/pic/pcode.c (FixRegisterBanking): fixed warning used uninitialized
942         * src/z80/gen.c: added AOP_IS_PAIRPTR,
943           (_pop): only pop valid pairs, see gencjneshort,
944           (gencjneshort): return pair that still needs to be popped, restructured,
945           (gencjne, genCmpEq): call _pop
946
947 2007-02-23 Raphael Neider <rneider AT web.de>
948
949         * device/include/pic/pic14devices.txt: 16f684 has only one config word
950
951 2007-02-22 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
952
953         * device/include/mcs51/P89LPC925.h: Added.
954
955 2007-02-18 Raphael Neider <rneider AT web.de>
956
957         * src/pic/glue.c (emitInitVal): fixed #1659894 (SIGSEGV on arrays)
958
959 2007-02-17 Borut Razem <borut.razem AT siol.net>
960
961         * support/cpp2/directives.c, support/cpp2/version.c:
962           synchronized with GCC CPP 4.1.2
963
964 2007-02-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
965
966         * src/mcs51/rtrack.h,
967         * src/mcs51/rtrack.c: added register tracking for the mcs51 port,
968           by checking the strings passed by emitcode() to the assembler.
969           Feel free to change. This in part addresses RFE #482179.
970           Set environment variable SDCC_RTRACK to enable.
971         * src/mcs51/gen.c: inserted hooks
972         * src/mcs51/ralloc.h: added two members to struct regs
973         * support/regression/tests/regtrack.c: added
974
975 2007-02-14 Borut Razem <borut.razem AT siol.net>
976
977         * src/SDCC.y: fixed bug #1291133: duplicate members across enum(s)
978         * Makefile.in: applied patch from Makefile related part of
979           #1469393: Compiler does not initialize static data
980
981 2007-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
982
983         * src/SDCCicode.c (geniCodeAssign): return (itemp) right instead of left
984           for better fix of bug 1273984, compiles pic16 rand.c
985
986 2007-02-12 Borut Razem <borut.razem AT siol.net>
987
988         * src/pic16/main.c: fixed pic16 standard library directory bug
989
990 2007-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
991
992         * src/hc08/gen.c (genSwap): fix swap regression test
993
994 2007-02-10 Borut Razem <borut.razem AT siol.net>
995
996         * src/SDCCsymt.c: fixed bug #1159134: invalid duplicate declarations
997           with same scope
998         * support/regression/tests/bug-1654060.c: added regression test for
999           #1654060
1000
1001 2007-02-09 Bernhard Held <bernhard AT bernhardheld.de>
1002
1003         * src/mcs51/gen.c (genRet): fixed RFE 1652561: added code for bit to
1004         bit moves in return statement
1005
1006 2007-02-09 Borut Razem <borut.razem AT siol.net>
1007
1008         * src/SDCC.y: fixed bug #1654060 typedef within function causes
1009           syntax error
1010
1011 2007-02-07 Maarten Brock <sourceforge.brock AT dse.nl>
1012
1013         * src/mcs51/gen.c (aopPut): use direct name for pushing registers
1014         * src/SDCCmain.c (parseCmdLine): dbuf_s path must be initialised
1015
1016 2007-02-07 Raphael Neider <rneider AT web.de>
1017
1018         * src/pic16/devices.inc,
1019         * device/include/pic16/pic18fregs.h,
1020         * device/include/pic16/pic18f[24][34]31.h,
1021         * device/lib/pic16/libdev/pic18f[24][34]31.c,
1022         * device/lib/pic16/pics.all: added 18f[24][34]31 family
1023         * device/lib/pic16/libio/i2c.ignore: do not build i2c
1024
1025 2007-02-07 Maarten Brock <sourceforge.brock AT dse.nl>
1026
1027         * device/lib/printf_large.c (_print_format): fixed compare/assign bug, how
1028           can this have lived here for so many years?
1029         * src/SDCCicode.c (ast2iCode): return left instead of right for assignment,
1030           fixes bug 1273984, see also patch 1645121, thanks Gnther Jehle
1031         * support/regression/tests/bug1273984.c: new, added, thanks Gnther Jehle
1032
1033 2007-02-06 Bernhard Held <bernhard AT bernhardheld.de>
1034
1035         * src/SDCCBlock.c (addiCodeToeBBlock): fixed bug 1652207: GOTO icodes
1036         appended by loop induction must be at the very end of the eBBlock
1037
1038 2007-02-05 Kevin Vigor
1039
1040         * src/ds390/gen.c, src/ds390/main.c: Address bug 1469393.
1041
1042 2007-02-05 Borut Razem <borut.razem AT siol.net>
1043
1044         * support/regression/fwk/lib/timeout.c: native WIN32 port,
1045           implemented #1651830 Reg. tests: rewrite timeout.c to use WIN32 API
1046
1047 2007-02-03 Borut Razem <borut.razem AT siol.net>
1048
1049         * src/SDCC.y, src/SDCCmain.c, src/SDCCglobl.h, doc/sdccman.lyx:
1050           applied patch #1646602 option to set default signedness of char to
1051           unsigned, added -funsigned-char command line option,
1052           thanks to Gunther Jehle
1053         * device/lib/Makefile.in: added the -f option to rm so it doesn't
1054           prompt for file deletion a few hundred times (especially the
1055           subversion files, which have ro permissions so it asks for
1056           confirmation), thanks to Simon McAuliffe;
1057           added {} + option to find in order to remove multiple files from a
1058           single rm commad
1059
1060 2007-02-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1061
1062         * device/include/mcs51/SST89x5xRDx.h: Added.
1063
1064 2007-02-02 Raphael Neider <rneider AT web.de>
1065
1066         * src/pic/glue.c (emitSymbolSet): check sym->etype before use
1067         * src/regression/Makefile: use --no-pcode-opt, ignore failing tests
1068
1069 2007-02-01 Raphael Neider <rneider AT web.de>
1070
1071         * src/pic/glue.c (picglue,emitSymbolSet,showAllMemmaps): emit the
1072           config words again
1073
1074 2007-01-31 Borut Razem <borut.razem AT siol.net>
1075
1076         * support/Util/dbuf_string.h: added ATTRIBUTE_PRINTF to dbuf_printf()
1077           if compiled with GCC. Thanks to Raphael Neider
1078
1079 2007-01-31 Raphael Neider <rneider AT web.de>
1080
1081         * src/pic/pcode.c (isValidIdChar,bankCompare): fuzzy matching of
1082             operand names, handles name and (name + n) for all n,
1083           (sameBank): restructured, also check bank allocation policy,
1084         * src/pic/glue.c (emitPseudoStack): fixed printf arguments,
1085           (pic14_operandsAllocatedInSameBank): check whether to operands
1086             will be allocated into the same bank (i.e., section) to reduce
1087             BANKSEL overhead, queried from pcode.c:sameBank,
1088           (pic14printLocals): reintroduced clustering registers into a single
1089             section: all compiler generated symbols will now reside in one
1090             bank (per file), reducing BANKSEL overhead and code size,
1091           (showAllMemmaps): use local dbuf where possible
1092
1093 2007-01-29 Raphael Neider <rneider AT web.de>
1094
1095         * src/pic/gen.c (popGetExternal): simplified, mark symbol as used,
1096           (call_libraryfunc): retrieve/create symbol and mark as used,
1097           (genFunction): mark defined functions as non-extern and add again
1098            to code memmap for later output
1099         * src/pic/glue.c (emitPseudoStack): put into own subroutine,
1100           (pic14printLocals): reworked for new symbol emission,
1101           (emitIfNew,pic14_constructAbsMap,emitIvalLabel,emitIvals,emitInitVal,
1102           showAllMemmaps): reworked symbol output using dbufs, added handling
1103             of string literals (still incomplete),
1104           (picglue): removed symbol emission, moved into showAllMemmaps,
1105           (emitSymbolSet): new workhorse for symbol output,
1106           (pic14emitMaps,pic14printPublics,pic14printExterns): commented out
1107
1108 2007-01-29 Borut Razem <borut.razem AT siol.net>
1109
1110         * src/SDCCmain.c, src/SDCCutil.c: dbuf_splitFile: file extension
1111           component contains the extension separator.
1112
1113 2007-01-28 Borut Razem <borut.razem AT siol.net>
1114
1115         * sim/ucsim/cmd.src/cmdutil.cc: NUL device is detected as CG_FILE type
1116           on WIN32
1117         * src/SDCCdwarf2.c, src/SDCCglobl.h, src/SDCCmain.c, src/SDCCutil.c,
1118           src/SDCCutil.h, src/avr/gen.c, src/ds390/gen.c, src/hc08/gen.c,
1119           src/mcs51/gen.c, src/pic/device.c, src/pic/gen.c, src/pic/pcode.c,
1120           src/pic/pcodepeep.c, src/pic/ralloc.c, src/pic16/device.h,
1121           src/pic16/gen.c, src/pic16/main.c, src/pic16/pcode.c,
1122           src/pic16/pcodepeep.c, src/pic16/ralloc.c, src/xa51/gen.c,
1123           src/z80/gen.c, support/Util/MySystem.c:
1124           accept slash and backslash as directory separator on WIN32 and
1125           Cygwin ports
1126
1127 2007-01-28 Raphael Neider <rneider AT web.de>
1128
1129         * src/pic16/devices.inc,
1130         * device/include/pic16/pic18f[24][23]21.h,
1131         * device/include/pic16/pic18fregs.h,
1132         * device/lib/pic16/libdev/pic18f[24][23]21.c,
1133         * device/lib/pic16/pics.all: added support for the 18f[24][23]21 family
1134         * device/lib/pic16/libio/adc.ignore,
1135         * device/lib/pic16/libio/i2c.ignore,
1136         * device/lib/pic16/libio/usart.ignore: do not build I/O lib for new
1137           family, as gputils do not yet support the devices
1138         * device/lib/pic16/Makefile.subdir: ignore errors on install
1139         * support/scripts/inc2h-pic16.pl: script to generate pic16 device
1140           headers and libraries from gputils .inc files
1141
1142 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
1143
1144         * doc/sdccman.lyx: add printf_fast_f precision limitation note
1145
1146 2007-01-26 Paul Stoffregen <paul AT pjrc.com>
1147
1148         * doc/sdccman.lyx: add printf benchmarks
1149
1150 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
1151
1152         * device/lib/printf_fast.c: fix %c, char promoted to int
1153         * device/lib/printf_tiny.c: fix %c, char promoted to int
1154
1155 2007-01-25 Paul Stoffregen <paul AT pjrc.com>
1156
1157         * device/lib/printf_fast.c: fix float overflow check, bug #1525093
1158
1159 2007-01-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1160
1161         * support/regression/tests/swap.c: 64 bit hosts failed
1162         * doc/sdccman.lyx: added preliminary mcs51 printf feature matrix
1163
1164 2007-01-25 Raphael Neider <rneider AT web.de>
1165
1166         * src/pic/pcode.c (sameBank,FixRegisterBanking): optimize banksels
1167           based on absolute register address, patch by Alex Blond
1168
1169 2007-01-22 Raphael Neider <rneider AT web.de>
1170
1171         * src/pic/glue.c (pic14emitRegularMap): mark initialized symbols as
1172           emitted, do not emit them again...
1173
1174 2007-01-22 Raphael Neider <rneider AT web.de>
1175
1176         * src/regression/bank1.c, src/regression/compare6.c,
1177           src/regression/add.c: cosmetic changes
1178         * src/pic/pcode.h: moved GPTRTAG_* here from gen.c
1179         * src/pic/gen.c: fixed global zero and one,
1180           (aopForSym): removed unued code,
1181           (aopGet): assert aop is defined, check and use `index' of
1182             pCodeImmd operands (fixes #1630908),
1183         * src/pic/pcode.c (get_op): added output of generic pointer tag,
1184           (register_reassign): prevent accidental register unification,
1185           (ReuseReg): cosmetic changes (also above)
1186         * src/pic/glue.c (pic14_constructAbsMap,pic14emitRegularMap,
1187           pic14emitStaticSeg): do not emit initialized data,
1188           (printIval*): replaced with working versions,
1189           (pic14createInterruptVect,picglue): use idata for initialized data,
1190             now init data should work in all modules (not only main()),
1191         * device/lib/pic/libsdcc/idata.c: NEW, handle initialized data
1192
1193 2007-01-21 Borut Razem <borut.razem AT siol.net>
1194
1195         * sim/ucsim/configure.in: introduced macro DD_COPT_NO_IGNORE,
1196           use -fPIC or -fpic if they are supported and not ignored
1197         * src/SDCCval.c: fixed bug introduced by me in rev. #4577
1198         * support/cpp2/libcpp/lex.c: fixed gcc 4.1.1 warnings
1199
1200 2007-01-20 Borut Razem <borut.razem AT siol.net>
1201
1202         * src/SDCC.lex, src/SDCCmain.c, sdc/SDCCglobl.h, doc/sdccman.lyx:
1203           implemented RFE #1470316: allow "$" in variable names
1204
1205 2007-01-20 Raphael Neider <rneider AT web.de>
1206
1207         * device/include/pic/pic14regs.h: reverted accidental wipe of the file
1208
1209 2007-01-20 Raphael Neider <rneider AT web.de>
1210
1211         * device/lib/pic/libdev/devices.txt: device list for mkall.sh
1212         * device/lib/pic/libdev/mkall.sh: script to rebuild all device libs
1213         * device/lib/pic/libdev/pic14ports.txt: device PORT specifications
1214         * support/scripts/inc2h.pl: fixed major .inc parsing bugs,
1215           applied patch from Robert Tate (#1629249) to add PORTs and TRISs
1216         * device/lib/pic/libdev/pic*.c,
1217         * device/include/pic/pic*.h: regenerated with enhanced inc2h.pl
1218         * device/lib/pic/libdev/Makefile.in: show progress
1219
1220 2007-01-19 Bernhard Held <bernhard AT bernhardheld.de>
1221
1222         * doc/sdccman.lyx: updated "configure options" for autoconf 2.6
1223         * support/scripts/sdcc_cygwin_mingw32,
1224         * support/scripts/sdcc_mingw32,
1225         * support/scripts/build.mak: replaced --datadir by --datarootdir for
1226         conformance with autoconf 2.6
1227
1228 2007-01-19 Raphael Neider <rneider AT web.de>
1229
1230         * src/pic/device.c (register_map): fixed list construction
1231         * src/pic/gen.c (genDivOneByte,genModOneByte): accept result > 1 byte,
1232           (genMod): removed case for genModbits,
1233           (genModbits): removed as now unused/unimplemented
1234         * src/pic/glue.c (picglue): prevent name clash with sources 'init.c'
1235
1236 2007-01-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1237
1238         * support/regression/tests/swap.c: added in response to #1638622
1239         * doc/sdccman.lyx: synced version, minor changes
1240
1241 2007-01-18 Borut Razem <borut.razem AT siol.net>
1242
1243         * SDCClabel.c: fixed bug #1638651: wrong linenumber presented in warning,
1244           thanks to Gunther Jehle
1245         * src/asm.c: don't die if the file drfined in #line couldn't be opened
1246         * src/SDCC.lex, src/SDCCglobal.h, src/SDCCicode.c, src/SDCCsymt.c,
1247           src/SDCCval.c: removed redundant definitions of currFname and mylineno;
1248           use filename in lineno instead.
1249         * SDCCast.c: removed MSVC warning C4018: '==' : signed/unsigned mismatch,
1250           print the file name in ast_print()
1251
1252 2007-01-18 Borut Razem <borut.razem AT siol.net>
1253
1254         * support/Util/dbuf_string.c: removed (PTR) cast since it is not
1255           defined in MSVC
1256         * src/SDCC.lex: stringLiteral() returns const char pointer,
1257           EOF detection in stringLiteral(), fixed asmbuf memory leak,
1258           fixed column counting
1259         * src/SDCCval.[ch]: constVal(), value *strVal() and charVal()
1260           accept const char pointer as parameter
1261         * src/SDCCdwarf2.c: corrected buffer size
1262
1263 2007-01-17 Borut Razem <borut.razem AT siol.net>
1264
1265         * support/Util/dbuf_string.c: fixed for amd64
1266
1267 2007-01-15 Borut Razem <borut.razem AT siol.net>
1268
1269         * src/pic16/ralloc.c, src/pic/ralloc.c, src/SDCC.y:
1270           removed terminal symbol ELIPSIS, since it was never generated by the
1271           lexer and it was wrongly used in parameter_identifier_list rule
1272
1273 2007-01-15 Raphael Neider <rneider AT web.de>
1274
1275         * doc/sdccman.lyx: updated PIC14/16 command line args, updated PIC14
1276             code page and data banking description
1277         * src/pic/genarith.c,
1278         * src/pic/gen.h: removed bit arithmetic functions,
1279             updated exit(1) to exit(EXIT_FAILURE)
1280         * device/lib/pic16/libsdcc/stack/stack.S: default to 256 byte stack
1281         * device/include/pic16/pic18f2455.h,
1282         * device/lib/pic16/libdev/pic18f2455.c: added PORTD, LATD, LATE,
1283             TRISD and TRISE, fixed/added some bit names
1284         * device/lib/pic16/libdev/pic18f{2550,4550,4455}.c,
1285         * device/include/pic16/pic18f{2550,4550,4455}.h: simply include
1286             updated pic18f2455.{c,h} instead of duplicating them
1287
1288 2007-01-14 Borut Razem <borut.razem AT siol.net>
1289
1290         * as/mcs51/asnoice.c, as/hc08/asnoice.c: fixed bug #1447412:
1291           Cannot debug files that contain spaces in the path name
1292           by converting spaces in asm file name to underscores
1293
1294 2007-01-13 Borut Razem <borut.razem AT siol.net>
1295
1296         * doc/sdccman.lyx: fixed format errors
1297
1298 2007-01-10 Borut Razem <borut.razem AT siol.net>
1299
1300         * src/SDCC.lex, src/SDCCmain.c: fixed bug #1631895:
1301           codeseg/constseg #pragma fail
1302         * suppoprt/cpp2/Makefile.bcc: reenable Borland C compilation
1303         * suppoprt/cpp2/configure.in, suppoprt/cpp2/libcpp/lex.c,
1304           suppoprt/cpp2/Makefile.in, suppoprt/cpp2/sdcpp-opts,
1305           suppoprt/cpp2/sdcpp.[ch]: house cleaning
1306
1307 2007-01-09 Borut Razem <borut.razem AT siol.net>
1308
1309         * get rid of diagnistic.[ch], pretty-print.[ch],
1310           c-pretty-print.[ch], ... used just for error, warning, ...
1311           message formatting
1312         * suppoprt/cpp2/pretty-print.[ch], suppoprt/cpp2/diagnostic.[ch],
1313           suppoprt/cpp2/diagnostic.def, suppoprt/cpp2/input.h,
1314           suppoprt/cpp2/pretty-print.[ch]:
1315           removed
1316         * suppoprt/cpp2/Makefile.in, suppoprt/cpp2/opts.c,
1317           suppoprt/cpp2/sdcpp-opts.c, suppoprt/cpp2/sdcpp.[ch],
1318           suppoprt/cpp2/sdcpp.dsp:
1319           changed
1320
1321 2007-01-08 Maarten Brock <sourceforge.brock AT dse.nl>
1322
1323         * device/lib/printf_large.c (output_float): removed recursion,
1324           use smaller buffer on stack for mcs51,
1325           fixed bug printing 1.96
1326         * support/regression/tests/snprintf.c: added test
1327
1328 2007-01-07 Borut Razem <borut.razem AT siol.net>
1329
1330         * use dynamic memory buffers instead temporary files
1331         * support/Util/dbuf_string.c, support/Util/dbuf_string.h:
1332           added
1333         * src/Makefile.in, src/SDCC.lex, src/SDCCast.c, src/SDCCast.h,
1334           src/SDCCcse.c, src/SDCCglobl.h, src/SDCCglue.c, src/SDCCglue.h,
1335           src/SDCCicode.c, src/SDCCicode.h, src/SDCCmain.c, src/SDCCmem.c,
1336           src/SDCCmem.h, src/SDCCpeeph.c, src/SDCCpeeph.h, src/SDCCsymt.c,
1337           src/SDCCsymt.h, src/SDCCutil.c, src/asm.c, src/asm.h, src/avr/gen.c,
1338           src/avr/main.c, src/ds390/gen.c, src/ds390/main.c, src/hc08/gen.c,
1339           src/hc08/main.c, src/izt/gen.c, src/mcs51/gen.c, src/mcs51/main.c,
1340           src/pic/device.c, src/pic/gen.c, src/pic/glue.c, src/pic/main.c,
1341           src/pic/ralloc.c, src/pic16/gen.c, src/pic16/glue.c,
1342           src/pic16/main.c, src/pic16/ralloc.c, src/port.h, src/src.dsp,
1343           src/xa51/gen.c, src/xa51/main.c, src/z80/gen.c, src/z80/main.c,
1344           support/Util/dbuf.c, support/Util/dbuf.h:
1345           modified
1346         * .version, sdcc.spec: bumped version to 2.6.4
1347
1348 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
1349
1350         * src/port.h: added TARGET_Z80_LIKE macro
1351         * src/SDCCmain.c (linkEdit): use TARGET_Z80_LIKE,
1352           output PSEG location if --xram-loc or --xstack-loc was used
1353         * as/link/mcs51/lkarea.c (lnksect2): set segment address afterwards
1354
1355 2007-01-07 Maarten Brock <sourceforge.brock AT dse.nl>
1356
1357         * as/as_gbz80.dsp, as/z80/as_gbz80.dsp,
1358         * as/as_z80.dsp,   as/z80/as_z80.dsp,
1359         * as/asx8051.dsp,  as/mcs51/asx8051.dsp,
1360         * sdcc.dsw: moved project files into subdir
1361         * as/hc08/as_hc08.dsp,
1362         * as/hc08/Makefile.bcc,
1363         * as/hc08/Makefile.in,
1364         * as/mcs51/Makefile.bcc,
1365         * as/mcs51/Makefile.in,
1366         * as/z80/Makefile.bcc,
1367         * as/z80/Makefile.in,
1368         * as/link/mcs51/Makefile.bcc: use as/strcmpi.c
1369         * as/hc08/asm.h,
1370         * as/mcs51/asm.h,
1371         * as/z80/asm.h: added as_strcmpi() and as_strncmpi() prototypes
1372         * as/hc08/asmain.c,
1373         * as/hc08/assym.c,
1374         * as/mcs51/asmain.c,
1375         * as/mcs51/assym.c,
1376         * as/z80/assym.c: removed include "strcmpi.h"
1377         * as/hc08/strcmpi.c,
1378         * as/hc08/strcmpi.h,
1379         * as/mcs51/strcmpi.c,
1380         * as/mcs51/strcmpi.h,
1381         * support/Util/strcmpi.c,
1382         * support/Util/strcmpi.h: removed files
1383         * as/strcmpi.c: added as_strncmpi()
1384
1385 2007-01-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1386
1387         * sdcc.dsw: Added some dependencies on project config.dsp
1388
1389 2007-01-05 Maarten Brock <sourceforge.brock AT dse.nl>
1390
1391         * as/link/mcs51/lkarea.c (lnkarea2, lnksect2): replaced [di]seg_ap->a_addr
1392           with [di]ram_start to fix a regresion
1393
1394 2007-01-03 Bernhard Held <bernhard AT bernhardheld.de>
1395
1396         * configure.in: added missing mcs51 in status output
1397         * Makefile.in: add support/regression to SDCC_EXTRA to distclean this
1398         directory
1399         * debugger/mcs51/clean.mk (distclean): remove config.h
1400         * src/clean.mk (clean): remove SDCCy.c, SDCCy.h, SDCClex.c
1401         * support/cpp2/Makefile.in (clean): remove s-options, optionlist,
1402         options.h, s-options-h and options.c
1403         * support/cpp2/clean.mk: unused, removed
1404         * Makefile.common.in,
1405         * main_in.mk,
1406         * as/Makefile.in,
1407         * as/hc08/Makefile.in,
1408         * as/hc08/clean.mk,
1409         * as/mcs51/Makefile.in,
1410         * as/mcs51/clean.mk,
1411         * as/z80/clean.mk,
1412         * as/z80/conf.mk,
1413         * as/z80/Makefile.in,
1414         * as/z80/clean.mk,
1415         * as/link/Makefile.in,
1416         * as/link/hc08/Makefile.in,
1417         * as/link/hc08/clean.mk,
1418         * as/link/mcs51/Makefile.in,
1419         * as/link/mcs51/clean.mk,
1420         * as/link/z80/Makefile.in,
1421         * as/link/z80/clean.mk,
1422         * as/link/z80/conf.mk,
1423         * debugger/mcs51/Makefile.in,
1424         * debugger/mcs51/clean.mk,
1425         * device/include/Makefile.in,
1426         * device/lib/Makefile.in,
1427         * device/lib/mcs51/Makefile.in,
1428         * device/lib/pic/Makefile.in,
1429         * device/lib/pic/Makefile.common.in,
1430         * device/lib/pic/Makefile.subdir,
1431         * device/lib/pic/Makefile.rules,
1432         * device/lib/pic16/libio/Makefile.in,
1433         * device/lib/pic16/Makefile.subdir,
1434         * device/lib/pic16/libdev/Makefile.in,
1435         * device/lib/pic16/Makefile.rules,
1436         * device/lib/pic16/Makefile.common.in,
1437         * sim/ucsim/avr.src/Makefile.in,
1438         * sim/ucsim/main_in.mk,
1439         * sim/ucsim/cmd.src/Makefile.in,
1440         * sim/ucsim/doc/Makefile.in,
1441         * sim/ucsim/gui.src/Makefile.in,
1442         * sim/ucsim/gui.src/obsolete/portmon.src/Makefile.in,
1443         * sim/ucsim/gui.src/serio.src/Makefile.in,
1444         * sim/ucsim/hc08.src/Makefile.in,
1445         * sim/ucsim/libltdl/Makefile.in,
1446         * sim/ucsim/s51.src/Makefile.in,
1447         * sim/ucsim/sim.src/Makefile.in,
1448         * sim/ucsim/sim.src/conf.mk,
1449         * sim/ucsim/xa.src/Makefile.in,
1450         * sim/ucsim/z80.src/Makefile.in,
1451         * src/Makefile.in,
1452         * src/clean.mk,
1453         * src/port.mk,
1454         * support/cpp2/Makefile.in,
1455         * support/librarian/Makefile.in,
1456         * support/librarian/clean.mk,
1457         * support/makebin/Makefile.in,
1458         * support/makebin/clean.mk,
1459         * support/packihx/Makefile.in,
1460         * support/regression/Makefile.in,
1461         * support/regression/ports/ds390/spec.mk,
1462         * support/regression/ports/gbz80/spec.mk,
1463         * support/regression/ports/hc08/spec.mk,
1464         * support/regression/ports/mcs51/spec.mk,
1465         * support/regression/ports/mcs51-large/spec.mk,
1466         * support/regression/ports/mcs51-medium/spec.mk,
1467         * support/regression/ports/mcs51-xstack-auto/spec.mk,
1468         * support/regression/ports/pic14/spec.mk,
1469         * support/regression/ports/pic16/spec.mk,
1470         * support/regression/ports/mcs51-stack-auto/spec.mk,
1471         * support/regression/ports/ucz80/spec.mk,
1472         * support/regression/ports/xa51/spec.mk,
1473         * support/regression/ports/z80/spec.mk: fixed for autoconf 2.6x by
1474         adding a slash after $(top_builddir) and/or adding @datarootdir@
1475         * configure.in,
1476         * debugger/mcs51/configure.in,
1477         * device/lib/pic/configure.in,
1478         * device/lib/pic16/configure.in,
1479         * sim/ucsim/configure.in,
1480         * support/cpp2/configure.in,
1481         * support/packihx/configure.in: changed AC_PREREQ to 2.60
1482         * configure,
1483         * debugger/mcs51/configure,
1484         * device/lib/pic/configure,
1485         * device/lib/pic16/configure,
1486         * sim/ucsim/configure,
1487         * support/cpp2/configure,
1488         * support/packihx/configure: generated with autoconf 2.60
1489
1490 2007-01-02 Maarten Brock <sourceforge.brock AT dse.nl>
1491
1492         * as/link/hc08/lkihx.c (newArea),
1493         * as/link/hc08/lkrloc.c: renamed newArea() to ihxNewArea()
1494
1495 2007-01-02 Borut Razem <borut.razem AT siol.net>
1496
1497         * doc/sdccman.lyx: documented #pragma sdcc_hash
1498         * support/cpp2/sdcpp.c: allow_naked_hash (value of #pragma sdcc_hash)
1499           initialized to 0
1500         * support/cpp2/c-ppoutput.c: fixed warning: no newline at end of file
1501
1502 2007-01-01 Bernhard Held <bernhard AT bernhardheld.de>
1503
1504         * src/SDCCast.c (createDo): backPatchLabels() needs falseLabel in
1505         empty 'while'-loop to work correctly, see regression test 'while.c'
1506         * support/regression/tests/while.c: added
1507
1508 2007-01-01 Borut Razem <borut.razem AT siol.net>
1509
1510         * support/cpp2/libcpp/directives.c, support/cpp2/libcpp/identifiers.c,
1511           support/cpp2/libcpp/init.c, support/cpp2/libcpp/sdcpp-opts.c,
1512           support/cpp2/libcpp/sdcpp.c:
1513           sdcpp specific pragma/directive/option handling moved to sdcpp.c
1514         * doc/sdccman.lyx: reference to the GCC 4.1.1 CPP Manual
1515         * support/cpp2/libcpp/mkdeps.c: synchronized with GCC CPP 4.1.1
1516
1517 2006-12-31 Borut Razem <borut.razem AT siol.net>
1518
1519         * SDCPP synchronized with GCC CPP release version 4.1.1,
1520           currently the latest release:
1521         * support/cpp2/libcpp, support/cpp2/libcpp/include,
1522           support/cpp2/libcpp/include/cpp-id-data.h
1523           support/cpp2/libiberty/fopen_unlocked.c
1524           support/cpp2/libiberty/md5.c
1525           support/cpp2/md5.h
1526           support/cpp2/opt-functions.awk
1527           support/cpp2/opt-gather.awk
1528           support/cpp2/optc-gen.awk
1529           support/cpp2/opth-gen.awk:
1530           added
1531         * support/cpp2/Makefile.in, support/cpp2/auto-host_vc_in.h,
1532           support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
1533           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
1534           support/cpp2/c-pretty-print.h, support/cpp2/cppdefault.c,
1535           support/cpp2/cppdefault.h, support/cpp2/diagnostic.c,
1536           support/cpp2/diagnostic.h, support/cpp2/except.h,
1537           support/cpp2/hwint.h, support/cpp2/input.h,
1538           support/cpp2/intl.h, support/cpp2/move-if-change,
1539           support/cpp2/opts.c, support/cpp2/opts.h,
1540           support/cpp2/output.h, support/cpp2/prefix.c,
1541           support/cpp2/prefix.h, support/cpp2/pretty-print.c,
1542           support/cpp2/pretty-print.h, support/cpp2/sdcpp-opts.c,
1543           support/cpp2/sdcpp.c, support/cpp2/sdcpp.dsp,
1544           support/cpp2/sdcpp.h, support/cpp2/sdcpp.opt,
1545           support/cpp2/sdcppa.dsp, support/cpp2/symcat.h,
1546           support/cpp2/version.c:
1547           modified
1548         * support/cpp2/libcpp/charset.c, support/cpp2/libcpp/directives.c,
1549           support/cpp2/libcpp/errors.c, support/cpp2/libcpp/expr.c,
1550           support/cpp2/libcpp/files.c, support/cpp2/libcpp/identifiers.c,
1551           support/cpp2/libcpp/include/cpplib.h, support/cpp2/libcpp/include/line-map.h,
1552           support/cpp2/libcpp/include/mkdeps.h, support/cpp2/libcpp/include/symtab.h,
1553           support/cpp2/libcpp/init.c, support/cpp2/libcpp/internal.h,
1554           support/cpp2/libcpp/lex.c, support/cpp2/libcpp/line-map.c,
1555           support/cpp2/libcpp/macro.c, support/cpp2/libcpp/mkdeps.c,
1556           support/cpp2/libcpp/symtab.c, support/cpp2/libcpp/system.h,
1557           support/cpp2/libcpp/traditional.c, support/cpp2/libcpp/ucnid.h,
1558           support/cpp2/libiberty/hashtab.c, support/cpp2/libiberty/hashtab.h:
1559           moved
1560         * support/cpp2/cppcharset.c, support/cpp2/cpperror.c,
1561           support/cpp2/cppexp.c, support/cpp2/cppfiles.c,
1562           support/cpp2/cpphash.c, support/cpp2/cpphash.h,
1563           support/cpp2/cppinit.c, support/cpp2/cpplex.c,
1564           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
1565           support/cpp2/cppmacro.c, support/cpp2/cpptrad.c,
1566           support/cpp2/cppucnid.h, support/cpp2/hashtab.c,
1567           support/cpp2/hashtab.h, support/cpp2/hashtable.c,
1568           support/cpp2/hashtable.h, support/cpp2/line-map.c,
1569           support/cpp2/line-map.h, support/cpp2/mkdeps.c,
1570           support/cpp2/mkdeps.h, support/cpp2/options_vc_in.c,
1571           support/cpp2/options_vc_in.h, support/cpp2/opts.sh,
1572           support/cpp2/system.h:
1573           deleted / moved
1574
1575 2006-12-31 Borut Razem <borut.razem AT siol.net>
1576
1577         * configure.in, configure: fixed bug #1538756: configure dies if bison
1578           and flex are not installed, 2nd try
1579
1580 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
1581
1582         * src/mcs51/peeph.def: renamed rule 400 to 500, moved rule 253.x to
1583         400.x for better code in RFE 899102
1584
1585 2006-12-30 Bernhard Held <bernhard AT bernhardheld.de>
1586
1587         * src/SDCCpeeph.c (deadMove),
1588         * src/port.h,
1589         * src/mcs51/peep.h: renamed 'op' by 'reg'
1590         * src/mcs51/peep.c (isFunc, isCallerSaveFunc): added,
1591         (scan4op): small change for removeDeadMove(), added support for
1592         'callee saves' and/or PACLL function calls,
1593         (removeDeadMove): added, removes superflous 'mov r%1,%2',
1594         (removeDeadPopPush): renamed from mcs51DeadMove(), common parts
1595         left in new dispatcher mcs51DeadMove()
1596         (mcs51DeadMove): dispatcher for removeDeadPopPush() and new
1597         removeDeadMove()
1598         * src/mcs51/peeph.def: added rule 301 removing superflous 'mov r%1,%2'
1599
1600 2006-12-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1601
1602         * support/cpp2/options_vc_in.h, support/cpp2/options_vc_in.c,
1603           support/cpp2/sdcppa.dsp: create 'options.h' and 'options.c' under MSVC.
1604
1605 2006-12-30 Borut Razem <borut.razem AT siol.net>
1606
1607         * support/cpp2/spacs.h: deleted from svn
1608         * configure.in, configure: fixed bug #1538756: configure dies if bison
1609           and flex are not installed
1610
1611 2006-12-29 Maarten Brock <sourceforge.brock AT dse.nl>
1612
1613         * src/z80/gen.c (assignResultValue): fixed bug when registers overlap,
1614           with this z80 passes printf float test when enabled
1615         * support/regression/tests/bug1057979.c: typo disabled ds390 float test
1616
1617 2006-12-28 Borut Razem <borut.razem AT siol.net>
1618
1619         * support/cpp2/config.in, support/cpp2/configure.in,
1620           support/cpp2/configure, support/cpp2/Makefile.in:
1621           fix for the solaris build
1622
1623 2006-12-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1624
1625         * src/SDCC.y (type_specifier2, pointer),
1626         * src/SDCCsymt.h,
1627         * src/SDCCsymt.c (mergeSpec, checkSClass),
1628         * support/Util/SDCCerr.c,
1629         * support/Util/SDCCerr.h: Parse and validate the restrict keyword
1630         * support/valdiag/valdiag.py: Allow test cases to specify
1631           required language standard
1632         * support/valdiag/tests/restrict.c: New file to test restrict keyword
1633         * support/valdiag/tests/tentdecl.c: Supress empty source file error
1634
1635 2006-12-27 Borut Razem <borut.razem AT siol.net>
1636
1637         * support/cpp2/cppmain.c, support/cpp2/mbchar.[ch]: removed
1638         * support/cpp2/libiberty/Makefile.in, support/cpp2/libiberty/sdcpp.dsp:
1639           mbchar removed
1640         * support/cpp2/libiberty/getpwd.c, support/cpp2/sdcpp.h:
1641           fixed for borland C
1642         * support/cpp2/libiberty/Makefile.bcc: updated
1643         * src/pic16/main.c: fixed #pragma udata handling
1644         * src/mcs51/mcs51.dsp: added peep.[ch] to the project
1645
1646 2006-12-26 Bernhard Held <bernhard AT bernhardheld.de>
1647
1648         * src/SDCCpeeph.c: made labelHashEntry global,
1649         made pcDistance, FBYNAME static,
1650         (pcDistance): made static, use isComment and isLabel,
1651         (deadMove): added,
1652         (getLabelRef): added, extracted from labelRefCount(),
1653         (labelRefCount): use new getLabelRef(),
1654         (callFuncByName): made static, added deadMove,
1655         use isComment and isLabel,
1656         (newPeepRule): made static, set isLabel,
1657         (isLabelDefinition): added parameter isPeepRule to allow '%' in
1658         labels from peephole rules,
1659         (buildLabelRefCountHash): speed up by running isLabelDefinition() only
1660         when isComment or isLabel is set
1661         * src/SDCCpeeph.h: added "isLabel" and "visited" to struct lineNode,
1662         added labelHashEntry, isLabelDefinition, labelHash and getLabelRef
1663         to make them global
1664         * src/mcs51/peep.h: added
1665         * src/mcs51/peep.c: added, implements mcs51DeadMove()
1666         * src/port.h: added peep->deadMove to port structure
1667         * src/mcs51/main.c: initialize peep->deadMove with mcs51DeadMove
1668         * src/mcs51/peeph.def: renumbered rule 300 to 400, added new rule 300
1669         deadMove, finally removed no. 1 and 2
1670         * src/mcs51/gen.c,
1671         * src/pic/gen.c,
1672         * src/z80/gen.c,
1673         * src/z80/ralloc.c,
1674         * src/pic16/gen.c,
1675         * src/ds390/gen.c,
1676         * src/hc08/gen.c: mark lines with isComment or isLabel
1677         * sim/ucsim/s51.src/uc390hw.cc: don't waist 65535 ticks before CKRDY
1678         * .version,
1679         * sdcc.spec: bumped version to 2.6.3
1680
1681 2006-12-26 Borut Razem <borut.razem AT siol.net>
1682
1683         * support/cpp2/Makefile.in: added dependency on options.h
1684         * configure: regenerated
1685         * support/cpp2/sdcpp.opt, support/cpp2/move-if-change: svn:eol-style native
1686         * support/cpp2/Makefile.in: added vasprintf.c
1687
1688 2006-12-25 Borut Razem <borut.razem AT siol.net>
1689
1690         * SDCPP synchronized with GCC CPP release version 3.4.6,
1691           the latest release before 4.x:
1692         * support/cpp2/Makefile.in, support/cpp2/config.h,
1693           support/cpp2/configure, support/cpp2/configure.in,
1694           support/cpp2/cppdefault.c, support/cpp2/cppdefault.h,
1695           support/cpp2/cpperror.c, support/cpp2/cppexp.c,
1696           support/cpp2/cppfiles.c, support/cpp2/cpphash.c,
1697           support/cpp2/cpphash.h, support/cpp2/cppinit.c,
1698           support/cpp2/cpplex.c, support/cpp2/cpplib.c,
1699           support/cpp2/cpplib.h, support/cpp2/cppmacro.c,
1700           support/cpp2/cpptrad.c, support/cpp2/except.h,
1701           support/cpp2/hashtable.c, support/cpp2/hashtable.h,
1702           support/cpp2/hwint.h, support/cpp2/intl.h,
1703           support/cpp2/line-map.c, support/cpp2/line-map.h,
1704           support/cpp2/mkdeps.c, support/cpp2/mkdeps.h,
1705           support/cpp2/output.h, support/cpp2/prefix.c,
1706           support/cpp2/prefix.h, support/cpp2/sdcpp.dsp,
1707           support/cpp2/system.h, support/cpp2/version.c:
1708           modified
1709         * support/cpp2/c-incpath.c, support/cpp2/c-incpath.h,
1710           support/cpp2/c-ppoutput.c, support/cpp2/c-pretty-print.c,
1711           support/cpp2/c-pretty-print.h, support/cpp2/cppcharset.c,
1712           support/cpp2/cppucnid.h, support/cpp2/diagnostic.c,
1713           support/cpp2/diagnostic.def, support/cpp2/diagnostic.h,
1714           support/cpp2/hashtab.c, support/cpp2/hashtab.h,
1715           support/cpp2/input.h, support/cpp2/libiberty/getpwd.c,
1716           support/cpp2/libiberty/vasprintf.c, support/cpp2/libiberty/xmemdup.c,
1717           support/cpp2/move-if-change, support/cpp2/opts.c,
1718           support/cpp2/opts.h, support/cpp2/opts.sh,
1719           support/cpp2/pretty-print.c, support/cpp2/pretty-print.h,
1720           support/cpp2/sdcpp.opt, support/cpp2/sdcpp-opts.c,
1721           support/cpp2/win32, support/cpp2/win32/dirent.c,
1722           support/cpp2/win32/dirent.h:
1723           added
1724         * support/cpp2/sdcpp.c: renamed from sdcppmain.c
1725         * support/cpp2/sdcpp.h: renamed from sdcc.h
1726         * sdcppinit.c: deleted
1727
1728 2006-12-23 Borut Razem <borut.razem AT siol.net>
1729
1730         * support/cpp2/cpphash.h, support/cpp2/cpplex.c,
1731           support/cpp2/cpplib.[ch], support/cpp2/sdcppinit.c, doc/sdccman.lyx,
1732           preproc.c: an other try to fix bug #982435: introduced
1733           -pedantic-parse-number command line option and pedantic_parse_number
1734           pragma
1735
1736 2006-12-21 Maarten Brock <sourceforge.brock AT dse.nl>
1737
1738         * as/link/mcs51/lkarea.c (lnkarea2): handle absolute areas, restructured
1739            BSEG handling,
1740           (lnksect2): use --data-loc and --idata-loc as lower bound for ramstart,
1741            corrected overlayed areax addresses, warn about memory overlaps
1742         * as/mcs51/asmain.c (asmbl): create a new area for every .org directive
1743         * src/avr/main.c,
1744         * src/ds390/main.c,
1745         * src/hc08/main.c,
1746         * src/mcs51/main.c,
1747         * src/pic16/main.c,
1748         * src/pic/main.c,
1749         * src/xa51/main.c,
1750         * src/z80/main.c,
1751         * src/port.h: added xabs_name and iabs_name
1752         * src/SDCCglue.c (emitRegularMap): allocate for absolutes with initializer
1753           (glue, emitMaps): create and emit maps d_abs and i_abs
1754         * src/SDCCglue.h: cosmetic changes
1755         * src/SDCCmain.c (setDefaultOptions): idata can start below 0x80
1756         * src/SDCCmem.h,
1757         * src/SDCCmem.c (initMem): added x_abs, i_abs and d_abs
1758           (allocDefault): put absolute, initialized globals in them
1759         * support/regression/tests/absolute.c: added absolute bdata test
1760         * device/lib/printf_large.c (output_float): moved fpBuffer to stack/xdata
1761
1762 2006-12-20 Borut Razem <borut.razem AT siol.net>
1763
1764         * support/cpp2/cpphash.h, support/cpp2/cpplex.c: fixed bug #982435
1765         * support/regression/tests/preproc.c: renamed from bug-1351710.c,
1766           added regression test for bug #982435
1767
1768 2006-12-18 Borut Razem <borut.razem AT siol.net>
1769
1770         * src/SDCCutil.c: fixed a bug in (get_pragma_token)
1771         * src/pic16/main.c, src/SDCC.lex, src/z80/main.c:
1772           small cosmetic changes
1773         * src/SDCC.lex: (stringLiteral) fixed bug #1351710
1774         * support/regression/tests/bug-1351710.c: added regression test
1775
1776 2006-12-18 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1777
1778         * doc/sdccman.lyx: added the long missed iCode table
1779           "<where is figure II?>", added links to wiki
1780
1781 2006-12-17 Borut Razem <borut.razem AT siol.net>
1782
1783         * doc/sdccman.lyx, src/pic16/main.c, src/pic/main.c, src/port.h,
1784           src/SDCC.lex, src/SDCCutil.[ch], src/z80/main.c,
1785           support/Util/SDCCerr.[ch]: removed deprecated pragmas,
1786           unified table driven pragma handling, pragma argument type checking
1787         * support/Util/dbuf.c: (dbuf_set_size) allow to set size equal to the
1788           current one - version 1.1.3
1789         * src/SDCCmain.c: (setParseWithComma) substituted brain damaged strtok
1790
1791 2006-12-13 Raphael Neider <rneider AT web.de>
1792
1793         * src/pic/device.h: removed AssignedMemory structure and macros
1794         * src/pic/device.c: removed global finalMapping (linker assigns
1795             memory locations),
1796           (register_map): add SFRs to remembered memRanges
1797           (addMemRange,isSFR,dump_map,dump_sfr,mapRegister,assignRegister,
1798           assignFixedRegisters,assignRelocatableRegisters): removed,
1799           (setMaxRAM,validAddress): adapted accordingly,
1800           (pic14_hasSharebank,pic14_getSharedStack): only report and use
1801             reasonably sized sharebanks,
1802         * src/pic/ralloc.c (writeUsedRegs): stripped down (remove?),
1803           (allDefsOutOfRange): removed unused code,
1804         * src/pic/main.c (_process_pragma): removed memmap/maxram pragma
1805             handling
1806         * src/pic/pcode.c (register_reassign): removed recursion warning,
1807             fired far too often,
1808         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap): modified
1809             to use existing pic14_stringInSet() to avoid duplicate symbols,
1810             tidied up the code a bit,
1811           (pic14printLocals): added in symmetry to printExterns, replaces
1812             writeUsedRegs more or less,
1813           (picglue): call new pic14_printLocals(),
1814         * device/include/pic/pic*.h: removed #pragma memmap directives,
1815             information gathered from include/pic/pic14devices.txt
1816         * support/scripts/inc2h.pl: do not emit #pragma memmap lines
1817
1818 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
1819
1820         * device/include/mcs51/C8051F520.h: fixed buggy CPT0MX
1821
1822 2006-12-11 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1823
1824         * device/include/mcs51/cc2430.h: fixed missing ';'
1825
1826 2006-12-10 Raphael Neider <rneider AT web.de>
1827
1828         * device/lib/pic16/libc/stdio/vfprintf.c,
1829         * device/lib/pic16/libc/stdio/printf_small.c,
1830         * device/lib/pic16/libc/stdio/printf_timy.c: pop int from stack for
1831           char arguments, as char varargs are cast to int by the caller,
1832           hopefully fixes #1604915 (other device libraries are still affected)
1833
1834 2006-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1835
1836         * src/mcs51/ralloc.c (packRegsForAssign),
1837         * src/hc08/ralloc.c (packRegsForAssign): fixed bug #1605880
1838
1839 2006-12-10 Maarten Brock <sourceforge.brock AT dse.nl>
1840
1841         * device/include/malloc.h: removed init_dynamic_memory
1842         * device/lib/malloc.c: made init_dynamic_memory static and automatically
1843           call it once from malloc. Also use _sdcc_heap[] from _heap.c
1844         * device/lib/_heap.c: new, added, contains _sdcc_heap[]
1845         * device/lib/libsdcc.lib,
1846         * device/lib/Makefile.in,
1847         * support/regression/ports/mcs51-xstack-auto/spec.mk: added _heap.c
1848         * doc/sdccman.lyx: documented use of new _heap.c
1849         * support/regression/tests/malloc.c: removed init_dynamic_memory
1850         * src/cdbFile.c(spacesToUnderscores): new function,
1851           (cdbWriteEndFunction, cdbWriteCLine): use spacesToUnderscores, fixes bug
1852           1068030
1853         * device/include/tinibios.h: removed defines for putchar and getchar
1854         * device/lib/ds390/Makefile.in: added putchar.c
1855         * device/lib/ds390/putchar.c: new, added, fixes bug 1465671
1856
1857 2006-12-09 Borut Razem <borut.razem AT siol.net>
1858
1859         * support/cpp2/sdcc.h: prevent multiple inclusion
1860         * support/cpp2/options.h: deleted
1861
1862 2006-12-08 Borut Razem <borut.razem AT siol.net>
1863
1864         * support/cpp2/sdcc.h: removed x*alloc() macros
1865         * support/cpp2/libiberty.h: uncommented out x*alloc() declarations
1866         * support/cpp2/Makefile.bcc, support/cpp2/Makefile.in,
1867           support/cpp2/sdcpp.sdc: x*alloc files added to the project
1868         * support/cpp2/system.h: moved #include "sdcc.h"
1869         * support/cpp2/libiberty/xexit.c, support/cpp2/libiberty/xmalloc.c,
1870           support/cpp2/libiberty/xstrdup.c, support/cpp2/libiberty/xstrerror.c:
1871           added
1872         * support/cpp2/sdcppinit.c: added -isysroot, -fsigned-char,
1873           -funsigned-char options
1874         * support/cpp2/sdcppmain.c: fixed bug 1611411
1875
1876 2006-12-07 Borut Razem <borut.razem AT siol.net>
1877
1878         * support/cpp2/cpplib.c: reverted sdcpp special handling of _Pragma()
1879           directive
1880
1881 2006-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
1882
1883         * src/SDCCsymt.c (addDecl): fixed bug 1609244
1884         * src/SDCCmain.c (linkEdit): fixed bug 1609279
1885         * doc/sdccman.lyx,
1886         * .version: bumped to 2.6.2 because a) it's been a while
1887           b) the linker sources have moved c) the preprocessor is upgraded
1888
1889 2006-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1890
1891         * support/regression/tests/snprintf.c: some checks
1892         * lib/src/printf_large.c: %bc: read char instead of int from stack
1893
1894 2006-12-03 Maarten Brock <sourceforge.brock AT dse.nl>
1895
1896         * device/include/mcs51/cc2430.h: inserted _XPAGE
1897
1898 2006-12-02 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
1899
1900         * device/include/mcs51/cc2430.h: added
1901
1902 2006-12-02 Maarten Brock <sourceforge.brock AT dse.nl>
1903
1904         * device/include/asm/default/features.h,
1905         * device/include/asm/ds390/features.h,
1906         * device/include/mcs51/at89s53.h,
1907         * device/include/ser.h,
1908         * device/include/ser_ir.h,
1909         * device/include/serial.h: changed keywords to double underscore variants,
1910           fixes bug 1590261 some more, thanks Steven Borley
1911
1912 2006-12-01 Raphael Neider <rneider AT web.de>
1913
1914         * src/pic/pcode.c (register_reassign): do not crash on recursive code
1915           but emit warning (recursion is not supported for pic14)
1916
1917 2006-11-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
1918
1919         * src/mcs51/peeph.def: added 101.a,b (moves to int/long xdata)
1920         * doc/sdccman.lyx: various small changes, acknowledged Sourceforge
1921
1922 2006-11-30 Raphael Neider <rneider AT web.de>
1923
1924         * src/pic/device.c (dump_sfr): always emit symbols
1925         * src/pic/glue.c (pic14printPublics): fixed typo
1926
1927 2006-11-30 Raphael Neider <rneider AT web.de>
1928
1929         * src/pic/device.c (create_pic,ram_map): add memRange entries to PIC
1930           (pic14_getSharebankSize, pic14_getSharebankAddress): replaced with
1931           (pic14_hasSharebank,pic14_isShared,pic14_allRAMShared,
1932            pic14_getSharedStack): NEW, evaluate the memRange entries to locate
1933            a sharebank, use a non-shared bank for the stack if none available
1934         * src/pic/device.h (struct memRange): added linked list next field,
1935           added prototypes for above functions
1936         * src/pic/ralloc.c (initStack): handle shared and banked stacks,
1937           (typeRegWithIdx): accept fixed and unfixed stack registers
1938         * src/pic/pcode.c (pCodeInitRegisters): use new functions to create
1939           the stack, handle shared and banked stack (except for WSAVE),
1940           (insertBankSel): removed useless optimization (will never fire),
1941           (FixRegisterBanking): added optimization for devices with only one
1942           possibly aliased bank of memory, like 16f84
1943         * src/pic/glue.c (pic14_constructAbsMap): back to udata_ovr, as some
1944           devices have no SHAREBANK in the linker script
1945         * device/include/pic/pic14devices.txt: documented memmap
1946         * device/lib/pic/libdev/Makefile.in: removed --stack-loc again
1947
1948 2006-11-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
1949
1950         * src/hc08/gen.c (transferRegReg, loadRegFromAop, forceStackedAop,
1951           storeRegToAop, freeAsmop, genPlusIncr, genPlus, genPointerGetSetOfs,
1952           genAnd, genOr, genXor, genLeftShiftLiteral, genRightShiftLiteral,
1953           genhc08Code): switched most of the D (debug) macros to DD (detailed
1954           debug) macros to better control clutter in the generated .asm file.
1955         * src/hc08/gen.c: (forceStackedAop, genUminus, genLeftShift,
1956           genRightShift): fixed bug with non-constant bit shift stored to
1957           a volatile result (SF Open Discussion forum thread #1616749).
1958           Single byte case is not yet optimized.
1959
1960 2006-11-28 Maarten Brock <sourceforge.brock AT dse.nl>
1961
1962         * device/include/asm/mcs51/features.h,
1963         * device/include/malloc.h,
1964         * device/include/stdio.h: changed keywords to double underscore variants,
1965           fixes bug 1590261
1966
1967 2006-11-27 Borut Razem <borut.razem AT siol.net>
1968
1969         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
1970           support/cpp2/Makefile.in, support/cpp2/cppfiles.c,
1971           support/cpp2/output.h, support/cpp2/cppinit.c,
1972           support/cpp2/cpplib.c, support/cpp2/cpplib.h,
1973           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
1974           support/cpp2/cppdefault.c, support/cpp2/system.h,
1975           support/cpp2/cpphash.h, support/cpp2/cpplex.c,
1976           support/cpp2/cppdefault.h, support/cpp2/mbchar.c,
1977           support/cpp2/prefix.c, support/cpp2/except.h,
1978           support/cpp2/hwint.h, support/cpp2/cppmacro.c,
1979           support/cpp2/line-map.h, support/cpp2/sdcpp.dsp,
1980           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
1981           support/cpp2/version.c, support/cpp2/cppmain.c,
1982           support/cpp2/version.h, support/cpp2/hashtable.c,
1983           support/cpp2/cpperror.c:
1984           synchronized with GCC CPP release version 3.3.6,
1985           the latest where cppmain.c still exists.
1986         * support/cpp2/cpptrad.c, support/cpp2/sdcppmain.c,
1987           support/cpp2/sdcppinit.c: added
1988
1989 2006-11-27 Borut Razem <borut.razem AT siol.net>
1990
1991         * support/cpp2/cpplex.c:
1992           fixed _asm ... _endasm handling bug, introduce with GCC CPP
1993           synchronization
1994         * support/cpp2/cpplib.c: removed definitions of unused variables
1995
1996 2006-11-26 Borut Razem <borut.razem AT siol.net>
1997
1998         * support/cpp2/libiberty.h: commented out x*alloc() declarations
1999           since they are redefined by macros in support/cpp2/sdcc.h
2000         * support/cpp2/sdcc.h: x*alloc macro redefinition
2001
2002 2006-11-25 Borut Razem <borut.razem AT siol.net>
2003
2004         * support/cpp2/cppexp.c, support/cpp2/hashtable.h,
2005           support/cpp2/configure, support/cpp2/Makefile.in,
2006           support/cpp2/cppfiles.c, support/cpp2/output.h,
2007           support/cpp2/cppinit.c, support/cpp2/cpplib.c,
2008           support/cpp2/config.h, support/cpp2/cpplib.h,
2009           support/cpp2/Makefile.bcc, support/cpp2/cpphash.c,
2010           support/cpp2/cppdefault.c, support/cpp2/config.in,
2011           support/cpp2/system.h, support/cpp2/cpplex.c,
2012           support/cpp2/cpphash.h, support/cpp2/mbchar.c,
2013           support/cpp2/cppdefault.h, support/cpp2/prefix.c
2014           support/cpp2/hwint.h, support/cpp2/mbchar.h,
2015           support/cpp2/prefix.h, support/cpp2/cppmacro.c,
2016           support/cpp2/configure.in, support/cpp2/intl.h,
2017           support/cpp2/sdcpp.dsp, support/cpp2/acconfig.h,
2018           support/cpp2/sdcc.h, support/cpp2/mkdeps.c,
2019           support/cpp2/version.c, support/cpp2/cppmain.c,
2020           support/cpp2/ansidecl.h, support/cpp2/libiberty.h,
2021           support/cpp2/hashtable.c, support/cpp2/aclocal.m4,
2022           support/cpp2/cpperror.c,
2023           support/cpp2/libiberty/safe-ctype.c,
2024           support/cpp2/libiberty/safe-ctype.h,
2025           support/cpp2/libiberty/splay-tree.c,
2026           support/cpp2/libiberty/obstack.c,
2027           support/cpp2/libiberty/lbasename.c,
2028           support/cpp2/libiberty/splay-tree.h,
2029           support/cpp2/libiberty/obstack.h:
2030           synchronized with GCC CPP release version 3.2.3,
2031           the latest before integration of cpp into gcc
2032         * support/cpp2/except.h, support/cpp2/line-map.c,
2033           support/cpp2/line-map.h,
2034           support/cpp2/libiberty/hex.c,
2035           support/cpp2/libiberty/concat.c,
2036           support/cpp2/libiberty/filenames.h: added
2037         * support/cpp2/intl.c: deleted
2038
2039 2006-11-24 Borut Razem <borut.razem AT siol.net>
2040
2041         * src/SDCC.y: enabled compilation of empty source file
2042         * support/Util/SDCCerr.[ch]: added sdcc warning 190 -
2043           "ISO C forbids an empty source file"
2044         * device/lib/_startup.c, device/lib/printf_tiny.c: disable warning 190
2045           if all the code is ifdefed out.
2046
2047 2006-11-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
2048
2049         * src/hc08/gen.c (genPcall): fix for bug #1601032
2050
2051 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
2052
2053         * device/include/mcs51/c8051f000.h, device/include/mcs51/C8051F000.h,
2054         * device/include/mcs51/c8051f018.h, device/include/mcs51/C8051F018.h,
2055         * device/include/mcs51/c8051f020.h, device/include/mcs51/C8051F020.h,
2056         * device/include/mcs51/c8051f040.h, device/include/mcs51/C8051F040.h,
2057         * device/include/mcs51/c8051f060.h, device/include/mcs51/C8051F060.h,
2058         * device/include/mcs51/c8051f120.h, device/include/mcs51/C8051F120.h,
2059         * device/include/mcs51/c8051f200.h, device/include/mcs51/C8051F200.h,
2060         * device/include/mcs51/c8051f300.h, device/include/mcs51/C8051F300.h,
2061         * device/include/mcs51/c8051f310.h, device/include/mcs51/C8051F310.h,
2062         * device/include/mcs51/c8051f320.h, device/include/mcs51/C8051F320.h,
2063         * device/include/mcs51/c8051f326.h, device/include/mcs51/C8051F326.h,
2064         * device/include/mcs51/c8051f330.h, device/include/mcs51/C8051F330.h,
2065         * device/include/mcs51/c8051f340.h, device/include/mcs51/C8051F340.h,
2066         * device/include/mcs51/c8051f350.h, device/include/mcs51/C8051F350.h,
2067         * device/include/mcs51/c8051f410.h, device/include/mcs51/C8051F410.h:
2068           Renamed to all upper case as per the standard set by SiLabs
2069
2070 2006-11-23 Maarten Brock <sourceforge.brock AT dse.nl>
2071
2072         * device/include/mcs51/C8051F520.h: new, added
2073         * device/include/mcs51/compiler.h: added link about predefined macros
2074
2075 2006-11-23 Raphael Neider <rneider AT web.de>
2076
2077         * src/regression/Makefile: add -L path to fresh library
2078         * src/regression/simulate: emphasize FAILED output
2079         * src/regression/create_stc: output _failures from gpsim
2080         * src/regression/compare4.c,
2081         * src/regression/rotate6.c: fixed char literals,
2082           all compile, all run =8-D
2083
2084         * src/pic/pcode.h: added isPCASMDIR macro
2085         * src/pic/gen.c (genAnd): fixed bit offset
2086         * src/pic/ralloc.c (allocNewDirReg,allocDirReg,allocRegByName,
2087           packBits): unified register numbering schemes,
2088           (newReg): do not insert stack registers into hash table,
2089           (initStack): unpinned pseudo stack, simplified,
2090           (typeRegWithIdx): fixed retrieval of stack registers,
2091         * src/pic/pcode.c (addpCodeComment,sameBank): added,
2092           (pCodeReplace): removed invalid assertion,
2093           (insertPCodeInstruction): fixed newly added labels,
2094           (insertBankSwitch,BankSelect,IsBankChange,DoBankSelect,
2095           FixRegisterBankingInFlow,compareBankFlow,FixBankFlow,
2096           DumpFlow): removed unsed (broken?) code,
2097           (insertBankSel): prevent STATUS from being BANKSELed,
2098           (FixRegisterBanking): rewritten from scratch, implemented generic
2099             optimizations (suppress BANKSELs to same register and to registers
2100             present in all banks),
2101           (AnalyzeBanking): update flow after BANKSELection
2102
2103         * src/pic/glue.c (pic14_constructAbsMap): emit pseudo stack in
2104             sharebank, let linker place it, mark STKxx symbols as emitted
2105
2106 2006-11-21 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2107
2108         * src/regression/arrays.c,
2109         * src/regression/bank1.c,
2110         * src/regression/bool2.c,
2111         * src/regression/compare7.c,
2112         * src/regression/compare8.c,
2113         * src/regression/compare9.c,
2114         * src/regression/compare10.c,
2115         * src/regression/configword.c,
2116         * src/regression/for.c,
2117         * src/regression/mult1.c,
2118         * src/regression/pointer1.c,
2119         * src/regression/rotate6.c,
2120         * src/regression/string1.c,
2121         * src/regression/struct1.c,
2122         * src/regression/Makefile: make PIC14 regression tests run again
2123           (3 fail, 6 won't compile)
2124
2125 2006-11-21 Raphael Neider <rneider AT web.de>
2126
2127         * device/include/pic16/pic18f4550.h,
2128         * device/include/pic16/pic18f4455.h,
2129         * device/lib/pic16/libdev/pic18f4550.c,
2130         * device/lib/pic16/libdev/pic18f4455.c: fixed #1578591 and #1595144
2131         * configure.in: removed superfluous closing bracket
2132
2133 2006-11-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2134
2135         * device/lib/expf.c: Fixed bug 1599523: result of expf(x) is
2136           always positive.
2137
2138 2006-11-21 Raphael Neider <rneider AT web.de>
2139
2140         * src/pic/device.{c,h}: added pic14_getPIC()
2141         * src/pic/gen.c (continueIfTrue,jumpIfTrue): added PIC code,
2142           (genAnd): added PIC code for one case, fixes #1597044
2143         * src/pic/pcode.c (BankSelect): Ohoh, added generic optimization for
2144           SFRs that are present in all banks (e.g., STATUS)
2145
2146 2006-11-20 Raphael Neider <rneider AT web.de>
2147
2148         * src/pic/pcode.c: changed inverted ops for DECFSZ/DECFSZW and
2149           INCFSZ/INCFSZW and declared them as changing Z bit,
2150           (insertPCodeInstruction): correctly invert the above instructions,
2151           fixes #1599333,
2152           (DoBankSelect): don't panic on po_immediates
2153
2154 2006-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
2155
2156         * as/link/aslink.h,
2157         * as/link/mcs51/lkihx.c (newArea),
2158         * as/link/mcs51/lkrloc.c: renamed newArea() to ihxNewArea()
2159         * as/link/mcs51/lkihx.c (ihx): output reset vector as start address
2160
2161 2006-11-11 Raphael Neider <rneider AT web.de>
2162
2163         * src/pic/pcode.c (newpCodeOpBit): search SymbolTab for referenced
2164           bitfield symbols, fixes #1579535 (once more...).
2165
2166 2006-11-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2167
2168         * support/regression/generate-cases.py,
2169         * support/regression/fwk/include/testfwk.h,
2170         * support/regression/fwk/lib/testfwk.c: used code pointers,
2171           (about 50kByte less code generated for mcs51)
2172
2173 2006-11-06 Borut Razem <borut.razem AT siol.net>
2174
2175         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
2176           debugger/mcs51/configure: fixed failed check because the function
2177           rl_function_of_keyseq isn't in Readline 5.2. Thanks to Ilya Goldberg
2178           who submitted the patch for gpsim.
2179         * debugger/mcs51/configure.in: removed the result message
2180         * debugger/mcs51/Makefile.in: fixed the config.status warning
2181           "... seems to ignore the --datarootdir setting"
2182
2183 2006-11-03 Maarten Brock <sourceforge.brock AT dse.nl>
2184
2185         * device/include/mcs51/c8051f020.h,
2186         * device/include/mcs51/c8051f040.h,
2187         * device/include/mcs51/c8051f060.h,
2188         * device/include/mcs51/c8051f120.h: added PS0, fixed bug 1589279
2189         * src/z80/gen.c (gencjneshort),
2190         * src/z80/peeph.def: applied patch 1571373, thanks Philipp Krause
2191
2192 2006-10-31 Borut Razem <borut.razem AT siol.net>
2193
2194         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
2195           debugger/mcs51/configure: get readline version
2196
2197 2006-10-30 Borut Razem <borut.razem AT siol.net>
2198
2199         * debugger/mcs51/sdcdb.c: replaced hardcoded "/" with DIR_SEPARATOR_STRING
2200         * debugger/mcs51/acinclude.m4, debugger/mcs51/aclocal.m4,
2201           debugger/mcs51/configure: locate readline even when cross compiling
2202         * support/scripts/sdcc.nsi: include readline5.dll into the setup package
2203
2204 2006-10-29 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2205
2206         * device/include/mcs51/serial_IO.h: putchar() and getchar() using
2207           serial port.
2208
2209 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
2210
2211         * device/include/malloc.h,
2212         * device/lib/calloc.c,
2213         * device/lib/free.c,
2214         * device/lib/malloc.c,
2215         * device/lib/realloc.c: moved definition of struct into sources
2216         * support/regression/tests/malloc.c: use void* for init_dynamic_memory()
2217
2218 2006-10-29 Maarten Brock <sourceforge.brock AT dse.nl>
2219
2220         * as/asx8051.dsp: corrected output directories
2221         * as/link/hc08: new directory for hc08 linker
2222         * as/hc08/aslink.h,             as/link/aslink.h,
2223         * as/hc08/aslink.mak,           as/link/hc08/aslink.mak,
2224         * as/hc08/clean.mk,             as/link/hc08/clean.mk,
2225         * as/hc08/link_hc08.dsp,        as/link/hc08/link_hc08.dsp,
2226         * as/hc08/lkaomf51.c,           as/link/hc08/lkaomf51.c,
2227         * as/hc08/lkarea.c,             as/link/hc08/lkarea.c,
2228         * as/hc08/lkdata.c,             as/link/hc08/lkdata.c,
2229         * as/hc08/lkelf.c,              as/link/hc08/lkelf.c,
2230         * as/hc08/lkihx.c,              as/link/hc08/lkihx.c,
2231         * as/hc08/lklibr.c,             as/link/hc08/lklibr.c,
2232         * as/hc08/lkmain.c,             as/link/hc08/lkmain.c,
2233         * as/hc08/lkmem.c,              as/link/hc08/lkmem.c,
2234         * as/hc08/lkrloc.c,             as/link/hc08/lkrloc.c,
2235         * as/hc08/lks19.c,              as/link/hc08/lks19.c,
2236         * as/hc08/Makefile.aslink,      as/link/hc08/Makefile.aslink,
2237         * as/hc08/Makefile.bcc,         as/link/hc08/Makefile.bcc,
2238         * as/hc08/Makefile.in,          as/link/hc08/Makefile.in,
2239         * as/link/hc08/conf.mk,
2240         * configure,
2241         * configure.in,
2242         * Makefile.in,
2243         * sdcc.dsw: moved hc08 linker to as/link/hc08
2244         * as/hc08/lkeval.c,     as/link/mcs51/lkeval.c,     as/link/lkeval.c,
2245         * as/hc08/lkhead.c,     as/link/mcs51/lkhead.c,     as/link/lkhead.c,
2246         * as/hc08/lklex.c,      as/link/mcs51/lklex.c,      as/link/lklex.c,
2247         * as/hc08/lklist.c,     as/link/mcs51/lklist.c,     as/link/lklist.c,
2248         * as/hc08/lknoice.c,    as/link/mcs51/lknoice.c,    as/link/lknoice.c,
2249         * as/hc08/lksym.c,      as/link/mcs51/lksym.c,      as/link/lksym.c,
2250         * as/link/mcs51/aslink.dsp,
2251         * as/link/mcs51/Makefile.in: factored out the common files
2252         * as/hc08/lkstore.c: deleted, use the one already in as/link/
2253         * as/clean.mk: extra cleaning common files
2254         * as/link/mcs51/strcmpi.c,      as/strcmpi.c: moved
2255         * as/link/mcs51/strcmpi.h: deleted, moved protoype to aslink.h
2256         * as/mcs51/asm.h: include sdccconf.h or sdcc_vc.h
2257
2258 2006-10-29 Raphael Neider <rneider AT web.de>
2259
2260         * src/pic/ralloc.c (newReg): create aliases for registers with
2261           multiple names to fix #1579535 and #1584001,
2262           (regWithIdx,dirregWithName): resolve aliases on lookup
2263         * src/pic/pcode.c (DoBankSelect): die with error message on failing
2264           bankselect
2265         * device/lib/pic/libdev/Makefile.in: move pseudo stack down to 0x4f
2266           to prevent build errors on small devices
2267
2268 2006-10-28 Raphael Neider <rneider AT web.de>
2269
2270         * src/pic/gen.c (genFunction,genCall): drop "same code page"
2271           assumption within interrupt handlers, fixes #1584940
2272         * src/pic/glue.c (pic14_constructAbsMap): mark absolute symbols as
2273           "emitted" to avoid emitting them again in udata
2274
2275 2006-10-27 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2276
2277         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
2278         Removed.
2279
2280 2006-10-26 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2281
2282         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c:
2283         Initialize uart only if SM0 and SM1 are zero.  Also, use flag to turn
2284         on/off CR to CRLF conversion.
2285
2286 2006-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2287
2288         * doc/sdccman.lyx: updated IRQ section
2289
2290 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2291
2292         * device/lib/serial_io.c: removed
2293         * device/lib/_putchar.c, device/lib/_getchar.c, device/lib/inituart.c
2294         replacements for serial_io.c
2295
2296 2006-10-24 Maarten Brock <sourceforge.brock AT dse.nl>
2297
2298         * src/z80/main.c (_process_pragma, _parseOptions): fixed bug 1583318
2299
2300 2006-10-24 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2301
2302         * device/lib/serial_io.c: Default putchar() and getchar() for
2303           mcs51 uses serial port.
2304
2305 2006-10-23 Maarten Brock <sourceforge.brock AT dse.nl>
2306
2307         * src/mcs51/gen.c (movc): improved check for 0 and 1, see RFE 1582704
2308
2309 2006-10-23 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2310
2311         * support/regression/ports/mcs51/support.c: smaller
2312         _sdcc_external_startup()
2313         * device/lib/mcs51/crtxclear.asm: don't check high byte of l_PSEG
2314
2315 2006-10-20 Maarten Brock <sourceforge.brock AT dse.nl>
2316
2317         * device/lib/gbz80/crt0.s,
2318         * device/lib/gbz80/crt0_rle.s,
2319         * device/lib/gbz80/div.s,
2320         * device/lib/gbz80/fstubs.s,
2321         * device/lib/gbz80/heap.s,
2322         * device/lib/gbz80/mul.s,
2323         * device/lib/gbz80/putchar.s,
2324         * device/lib/gbz80/stubs.s,
2325         * device/lib/z80/crt0.s,
2326         * device/lib/z80/crt0_rle.s,
2327         * device/lib/z80/div.s,
2328         * device/lib/z80/fstubs.s,
2329         * device/lib/z80/heap.s,
2330         * device/lib/z80/mul.s,
2331         * device/lib/z80/putchar.s,
2332         * device/lib/z80/stubs.s: reverted, I was mistaken
2333
2334 2006-10-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2335
2336         * src/mcs51/peeph.def: peephole 238.x added check for notvolatile
2337         * support/regression/ports/mcs51/support.c: removed race
2338         condition on TI in _putchar allowing to use serial port mode 0
2339
2340 2006-10-20 Borut Razem <borut.razem AT siol.net>
2341
2342         * debugger/mcs51/sdcdb.c: replaced isblank() with isspace()
2343
2344 2006-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
2345
2346         * device/lib/gbz80/crt0.s,
2347         * device/lib/gbz80/crt0_rle.s,
2348         * device/lib/gbz80/div.s,
2349         * device/lib/gbz80/fstubs.s,
2350         * device/lib/gbz80/heap.s,
2351         * device/lib/gbz80/mul.s,
2352         * device/lib/gbz80/putchar.s,
2353         * device/lib/gbz80/stubs.s,
2354         * device/lib/z80/crt0.s,
2355         * device/lib/z80/crt0_rle.s,
2356         * device/lib/z80/div.s,
2357         * device/lib/z80/fstubs.s,
2358         * device/lib/z80/heap.s,
2359         * device/lib/z80/mul.s,
2360         * device/lib/z80/putchar.s,
2361         * device/lib/z80/stubs.s: removed all leading underscores from area names
2362
2363 2006-10-17 Maarten Brock <sourceforge.brock AT dse.nl>
2364
2365         * support/regression/ports/mcs51/support.c: use highest baudrate so the
2366           regression tests are not waiting in the simulator for simulated
2367           transmission of debug output
2368
2369 2006-10-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2370
2371         * device/lib/printf_large.c: slightly smaller
2372         * doc/sdccman.lyx: do not use spaces within html links
2373
2374 2006-10-16 Borut Razem <borut.razem AT siol.net>
2375
2376         * configure.in, configure, sdccconf_in.h, src/SDCCglobal,
2377           debugger/mcs51/Makefile.in, debugger/mcs51/sdcdb.[ch],
2378           debugger/mcs51/aclocal.m4, debugger/mcs51/acinclide.m4,
2379           debugger/mcs51/config.h.in, debugger/mcs51/configure.in,
2380           debugger/mcs51/configure:
2381           [ 1185668 ] add gnu readline support to sdcdb - enabled
2382
2383 2006-10-16 Raphael Neider <rneider AT web.de>
2384
2385         * src/pic/pcode.c (BankSelect): another fix on (partial) BANKSELs,
2386           fixes #1577882, removes close to all banking optimizations
2387
2388 2006-10-15 Maarten Brock <sourceforge.brock AT dse.nl>
2389
2390         * src/SDCCsymt.c (checkSClass): no error for uninitialised absolute
2391           variables in code memory
2392         * support/regression/tests/absolute.c: added test for this
2393
2394 2006-10-15 Raphael Neider <rneider AT web.de>
2395
2396         * src/pic/pcode.c (InsertBankSel): suppress BANKSELs for one bank
2397           devices,
2398           (BankSelect): emit BANKSEL before touching linker-placed regs,
2399           fixes #1570934
2400
2401 2006-10-10 Raphael Neider <rneider AT web.de>
2402
2403         * src/SDCCmain.c (optionsTable): accept --stack-size for PICs,
2404         * src/pic/device.c (pic14_getSharebankSize,pic14_getSharebankAddress),
2405         * src/pic/main.c (_pic14_parseOptions),
2406         * src/pic/main.h: mostly reverted to previous state, now use results
2407             from SDCCmain.c's argument parsing
2408
2409 2006-10-10 Borut Razem <borut.razem AT siol.net>
2410
2411         * debugger/mcs51/break.[ch], debugger/mcs51/cmd.c,
2412           debugger/mcs51/sdcdb.[ch], debugger/mcs51/simi.c:
2413           [ 1185668 ] add gnu readline support to sdcdb -
2414           prepared for READLINE, not enabled yet,
2415           thanks to <tal.bav AT gmail.com>
2416
2417 2006-10-10 Raphael Neider <rneider AT web.de>
2418
2419         * src/pic16/pcode.c (pic16_pCode2str): use isACCESS_BANK macro
2420         * src/pic16/devices.inc,
2421         * device/include/pic16 (pic18f[24]620.h),
2422         * device/include/pic18fregs.h,
2423         * device/lib/pic16/pics.all,
2424         * device/lib/pic16/libdev/pic18f[24]{620,525}.c): added support for
2425             18f2620, 18f4620, 18f2525, and 18f4525 devices, thanks to
2426             Gary Plumbridge and Anton Strobl
2427
2428 2006-10-10 Raphael Neider <rneider AT web.de>
2429
2430         * src/pic/main.c (_pic14_parseOptions): added --stack-loc=NUM and
2431           --stack-siz=NUM options to configure the argument passing stack
2432         * src/pic/main.h: added stackLocation and stackSize to pic14_options_t
2433         * src/pic/device.c (mapRegister): catch out-of-memory SIGSEGVs,
2434           (pic14_getSharebankSize): obey --stack-siz=NUM,
2435           (pic14_getSharebankAddress): obey --stack-loc=NUM
2436
2437 2006-10-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
2438
2439         * doc/sdccman.lyx: added to the manual
2440         * doc/figures/ddd_example.png: added (neither pdflatex nor
2441         most browsers seem to like the .eps file)
2442
2443 2006-10-06 Bernhard Held <bernhard AT bernhardheld.de>
2444
2445         * src/SDCCglue.c (tempfileandname): changed un*x tmp search paths
2446         to /tmp and /var/tmp acc. LSB
2447         * src/SDCCast.c (addCast): Fixed bug 1571231: promote in case of
2448         RESULT_TYPE_IFX
2449         * support/regression/tests/onebyte.c: added test
2450
2451 2006-10-05 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2452
2453         * src/mcs51/gen.c: emitcode for "add a,0x%02x" requires only 8 bits.
2454
2455 2006-10-05 Borut Razem <borut.razem AT siol.net>
2456
2457         * partially fixed [ 1570701 ] peephole - not replacing code from multiline macros,
2458           thanks to dfulab:
2459           - sdcc.dsw: changed property eol-style to CRLF
2460           - support/scripts/resource.rc: replaced references to "afxres.h" with "winres.h"
2461
2462 2006-10-04 Raphael Neider <rneider AT web.de>
2463
2464         * device/include/pic/{pic16f84.h,pic16f84a.h},
2465         * device/lib/pic/libdev/{pic16f84.c,pic16f84a.c}: added PORT[AB]_bits
2466           from patch #1522504, thanks to Robas Teodor
2467
2468 2006-10-02 Maarten Brock <sourceforge.brock AT dse.nl>
2469
2470         * as/link/z80/lkarea.c: essentially reverted lnksect() to #4380 which
2471           fixes bug 1566015
2472
2473 2006-10-01 Maarten Brock <sourceforge.brock AT dse.nl>
2474
2475         * src/pic16/glue.c (pic16emitMaps),
2476         * src/pic/glue.c (pic14emitMaps): hopefully fixed bug 1568779
2477         * device/lib/gets.c: fixed bug 1568829,thanks Philipp Krause
2478         * device/lib/pic16/libc/string/memcpypgm2ram.c,
2479         * device/lib/pic16/libc/string/memcpyram2ram.c: fixed bug 1568836, thanks
2480           Philipp Krause
2481         * as/mcs51/asmain.c (asmbl, newdot): fixed problems with absolute areas
2482         * as/link/mcs51/lkmem.c (summary2): reverted, do do count abs segments
2483
2484 2006-09-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2485
2486         * support/librarian/sdcclib.c: Added option -l.
2487         * as/link/mcs51/lkmem.c: don't use absolute segments to compute memory
2488           usage totals.
2489         * device/lib/make51lib.bat: added.  Allows building mcs51 libraries easily
2490           using Windows command prompt.
2491
2492 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
2493
2494         * device/lib/libsdcc.lib: added module rand
2495         * src/ds390/ralloc.c (rematStr),
2496         * src/hc08/ralloc.c (rematStr),
2497         * src/mcs51/ralloc.c (rematStr),
2498         * src/z80/ralloc.c (rematStr): made output more consistent
2499         * src/mcs51/gen.c: cosmetic changes
2500
2501 2006-09-30 Maarten Brock <sourceforge.brock AT dse.nl>
2502
2503         * src/port.h: added mem.cabs_name to PORT
2504         * src/ds390/main.c,
2505         * src/hc08/main.c,
2506         * src/mcs51/main.c,
2507         * src/pic16/main.c,
2508         * src/pic/main.c,
2509         * src/xa51/main.c,
2510         * src/z80/main.c: added cabs_name initializers
2511         * src/SDCCglue.c (emitStaticSeg): allocate and initialize absolute
2512           constants
2513           (emitMaps): emit absolutes in code memory into cabs_name
2514         * src/SDCCmem.c,
2515         * src/SDCCmem.h: added memory map c_abs and defined CABS_NAME
2516         * src/ds390/gen.c (genCodePointerGet): fixed bug if left is a literal
2517         * support/regression/fwk/include/testfwk.h: added define for at
2518         * support/regression/tests/absolute.c: added, new
2519
2520 2006-09-29 Maarten Brock <sourceforge.brock AT dse.nl>
2521
2522         * src/mcs51/gen.c (genPlusIncr, genMinusDec, genAddrOf): small
2523           optimizations, see also patch 887161 by Stas Sergeev
2524         * src/mcs51/peeph.def(104, 207, 209, 212): disabled as they do not seem
2525           to be necessary anymore,
2526           (102, 103, 104, 127): renamed all occurances of bp to _bp
2527
2528 2006-09-27 Maarten Brock <sourceforge.brock AT dse.nl>
2529
2530         * device/include/mcs51/at89c51snd1c.h: fixed MSK_SREQ definition
2531           thanks Weston T. Schmidt for patch 1555221
2532         * src/mcs51/peeph.def: renamed rule 257 to 257.a, added 257.b
2533         * src/SDCCicode.c(geniCodeMultiply): small optimization
2534
2535 2006-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
2536
2537         * device/include/stdlib.h: added rand prototypes
2538         * device/lib/rand.c: new, added
2539         * device/lib/Makefile.in: added rand.c
2540         * src/z80/peeph.def,
2541         * src/z80/peeph-gbz80.def,
2542         * src/z80/peeph-z80.def: updated conditonals, fixed bug 1565908
2543
2544 2006-09-20 Raphael Neider <rneider AT web.de>
2545
2546         * device/lib/pic16/libio/i2c/i2cnack.c (i2c_nack): fixed ACKDT bit
2547
2548 2006-09-19 Maarten Brock <sourceforge.brock AT dse.nl>
2549
2550         * as/link/aslink.h: cosmetic changes
2551         * as/link/mcs51/Makefile.in,
2552         * as/link/z80/Makefile.in: fixed build on CF where VPATH is used
2553
2554 2006-09-17 Maarten Brock <sourceforge.brock AT dse.nl>
2555
2556         * as/link/aslink.h,
2557         * as/link/mcs51/aslink.h,
2558         * as/link/z80/aslink.h: merged and moved to as/link/
2559         * as/link/lkstore.c,
2560         * as/link/mcs51/lkstore.c: moved to as/link/
2561         * as/link/clean.mk: remove *.o
2562         * as/link/mcs51/alloc.h: deleted
2563         * as/link/mcs51/lkarea.c: added lnksect prototype
2564         * as/link/mcs51/lkdata.c,
2565         * as/link/mcs51/lklex.c,
2566         * as/link/mcs51/lkmain.c: renamed as_getline to lk_getline
2567         * as/link/mcs51/lkmem.c,
2568         * as/link/mcs51/lknoice.c: removed include strcmpi.h
2569         * as/link/mcs51/lksym.c: include stdlib.h instead of malloc.h or alloc.h
2570         * as/link/mcs51/aslink.dsp,
2571         * as/link/mcs51/Makefile.aslink,
2572         * as/link/mcs51/Makefile.bcc,
2573         * as/link/mcs51/Makefile.in: updated for moved files
2574         * as/link/z80/lkarea.c,
2575         * as/link/z80/lkhead.c,
2576         * as/link/z80/lklex.c,
2577         * as/link/z80/lklibr.c,
2578         * as/link/z80/lklist.c,
2579         * as/link/z80/lkmain.c,
2580         * as/link/z80/lkrloc.c,
2581         * as/link/z80/lksym.c: synced with mcs51
2582         * as/link/z80/lkdata.c,
2583         * as/link/z80/lkeval.c,
2584         * as/link/z80/lkihx.c,
2585         * as/link/z80/lks19.c: cosmetic changes
2586         * as/link/z80/Makefile.in,
2587         * as/link/z80/linkgbz80.dsp,
2588         * as/link/z80/linkz80.dsp: updated for moved files
2589
2590 2006-09-16 Borut Razem <borut.razem AT siol.net>
2591
2592         * debugger/mcs51/sdcdb.c: partially fixed
2593           [ 1203664 ] sdcdb fails to open files w. two "." periods
2594         * debugger/mcs51/simi.c, debugger/mcs51/symtab.c,
2595           debugger/mcs51/symtab.h: fixed indenting
2596         * configure.in, configure: up to date with latest Maarten's changes
2597
2598 2006-09-15 Maarten Brock <sourceforge.brock AT dse.nl>
2599
2600         as/link/mcs51
2601         as/aslink.dsp,                  as/link/mcs51/aslink.dsp,
2602         as/link/mcs51/aslink.h,         as/mcs51/aslink.h,
2603         as/link/mcs51/aslink.mak,       as/mcs51/aslink.mak,
2604         as/link/mcs51/lkaomf51.c,       as/mcs51/lkaomf51.c,
2605         as/link/mcs51/lkarea.c,         as/mcs51/lkarea.c,
2606         as/link/mcs51/lkdata.c,         as/mcs51/lkdata.c,
2607         as/link/mcs51/lkeval.c,         as/mcs51/lkeval.c,
2608         as/link/mcs51/lkhead.c,         as/mcs51/lkhead.c,
2609         as/link/mcs51/lkihx.c,          as/mcs51/lkihx.c,
2610         as/link/mcs51/lklex.c,          as/mcs51/lklex.c,
2611         as/link/mcs51/lklibr.c,         as/mcs51/lklibr.c,
2612         as/link/mcs51/lklist.c,         as/mcs51/lklist.c,
2613         as/link/mcs51/lkmain.c,         as/mcs51/lkmain.c,
2614         as/link/mcs51/lkmem.c,          as/mcs51/lkmem.c,
2615         as/link/mcs51/lknoice.c,        as/mcs51/lknoice.c,
2616         as/link/mcs51/lkrloc.c,         as/mcs51/lkrloc.c,
2617         as/link/mcs51/lks19.c,          as/mcs51/lks19.c,
2618         as/link/mcs51/lkstore.c,        as/mcs51/lkstore.c,
2619         as/link/mcs51/lksym.c,          as/mcs51/lksym.c,
2620         as/link/mcs51/Makefile.aslink,  as/mcs51/Makefile.aslink,
2621         as/link/mcs51/alloc.h,
2622         as/link/mcs51/clean.mk,
2623         as/link/mcs51/conf.mk,
2624         as/link/mcs51/Makefile.bcc,
2625         as/link/mcs51/Makefile.in,
2626         as/link/mcs51/readme.390,
2627         as/link/mcs51/strcmpi.c,
2628         as/link/mcs51/strcmpi.h,
2629         as/mcs51/clean.mk,
2630         as/mcs51/Makefile.bcc,
2631         as/mcs51/Makefile.in,
2632         configure,
2633         Makefile.in,
2634         sdcc.dsw: moved mcs51 linker to as/link/mcs51
2635
2636 2006-09-14 Maarten Brock <sourceforge.brock AT dse.nl>
2637
2638         * as/link,
2639         * as/link/Makefile.in,
2640         * as/link/z80/linkgbz80.dsp,
2641         * as/link/z80/linkz80.dsp,
2642         * configure,
2643         * link,
2644         * link/clean.mk,
2645         * link/Makefile.in,
2646         * link/README,
2647         * link/z80,
2648         * link/z80/aslink.h,
2649         * link/z80/clean.mk,
2650         * link/z80/conf.mk,
2651         * link/z80/linkgbz80.dsp,
2652         * link/z80/linkz80.dsp,
2653         * link/z80/lkarea.c,
2654         * link/z80/lkdata.c,
2655         * link/z80/lkeval.c,
2656         * link/z80/lkgb.c,
2657         * link/z80/lkgg.c,
2658         * link/z80/lkhead.c,
2659         * link/z80/lkihx.c,
2660         * link/z80/lklex.c,
2661         * link/z80/lklibr.c,
2662         * link/z80/lklist.c,
2663         * link/z80/lkmain.c,
2664         * link/z80/lkrloc.c,
2665         * link/z80/lks19.c,
2666         * link/z80/lksym.c,
2667         * link/z80/Makefile.in,
2668         * Makefile.in,
2669         * sdcc.dsw: moved link/ to as/link/
2670
2671 2006-09-11 Maarten Brock <sourceforge.brock AT dse.nl>
2672
2673         * as/mcs51/i51mch.c (machine): fixed warning
2674
2675 2006-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
2676
2677         * as/mcs51/i51mch.c (machine): S_DJNZ fixed bug 1554318
2678
2679 2006-09-09 Borut Razem <borut.razem AT siol.net>
2680
2681         * debugger/mcs51/sdcdb.c, debugger/mcs51/simi.c:
2682           sdcdb WIN32 native port
2683         * src/clean.mk: fixed
2684
2685 2006-09-08 Borut Razem <borut.razem AT siol.net>
2686
2687         * doc/sdccman.lyx: SDCDB and ucSim are available on Win32 platforms.
2688
2689 2006-09-08 Raphael Neider <rneider AT web.de>
2690
2691         * src/pic16/main.c (_pic16_linkEdit,pic16_linkCmd),
2692         * src/pic/main.c(_pic14_do_link, linkCmd): pass "-w" and "-r"
2693             to gplink to disable processor mismatch warning and to allow
2694             the use of devices with only aliased (shared) memory banks,
2695           (_pic16_genAssemblerPreamble): include pXXX.inc on --mplab-comp
2696
2697 2006-09-07 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2698
2699         * doc/sdccman.lyx: Some re-formating plus example on using
2700           #pragma preproc_asm +/-
2701
2702 2006-09-07 Borut Razem <borut.razem AT siol.net>
2703
2704         * support/scripts/sdcc.nsi: added SDCDB executables in a separate
2705           section
2706
2707 2006-09-06 Borut Razem <borut.razem AT siol.net>
2708
2709         * support/scripts/sdcc.nsi: fixed Error: unterminated string parsing
2710           line at sdcc.nsi:153
2711         * sdcc/debugger/mcs51/simi.c: argsToCmdLine() fixes
2712
2713 2006-09-05 Borut Razem <borut.razem AT siol.net>
2714
2715         * configure.in, configure: support for winsock2
2716         * debugger/mcs51/break.h, debugger/mcs51/cmd.c,
2717           debugger/mcs51/cmd.h, debugger/mcs51/sdcdb.c,
2718           debugger/mcs51/sdcdb.h, debugger/mcs51/simi.c,
2719           debugger/mcs51/simi.h, debugger/mcs51/symtab.c,
2720           debugger/mcs51/symtab.h: sdcdb WIN32 native port
2721
2722 2006-09-05 Maarten Brock <sourceforge.brock AT dse.nl>
2723
2724         * src/SDCCopt.c (cnvToFcall): fixed bug 1551947 by updating OP_USES
2725           and OP_DEFS
2726         * support/regression/tests/bug1551947.c: new, added
2727         * src/SDCCsymt.h: strings are char* not byte*
2728
2729 2006-09-05 Raphael Neider <rneider AT web.de>
2730
2731         * device/lib/pic16/libdev/pic18f4550.c,
2732           device/include/pic16/pic18f4550.h: added PORTD/TRISD
2733             declarations/definitions from patch #1520949
2734
2735 2006-09-05 Raphael Neider <rneider AT web.de>
2736
2737         * src/pic16/gen.c (genPackBits): fix assignment to 8-bit,
2738           byte-aligned bitfields, fixes #1539278
2739
2740 2006-09-05 Raphael Neider <rneider AT web.de>
2741
2742         * src/pic/gen.c (genReceive): skip unreferenced arguments,
2743           fixes #1544120
2744
2745 2006-09-04 Borut Razem <borut.razem AT siol.net>
2746
2747         * support/scripts/sdcc.nsi: move ucSim executables to a separate section
2748         * support/scripts/sdcc_cygwin_mingw32: don't disable ucsim,
2749           -mno-cygwin is a part of the compiler name
2750         * support/scripts/sdcc_mingw32: don't disable ucsim
2751
2752 2006-09-03 Borut Razem <borut.razem AT siol.net>
2753
2754         * sdcc.spec: corrected for 2.6.0. Thanks to Christer Weinigel.
2755         * device/lib/Makefile.in device/lib/clean.mk: small but essential corrections
2756
2757 2006-09-03 Raphael Neider <rneider AT web.de>
2758
2759         * src/pic/ralloc.c,
2760         * src/pic/pcode.c (InitReuseRegs): allocate registers with pseudo
2761           indices >= 0x1000 to disambiguate them from fixed regs __at(addr),
2762           fixes #1550049
2763
2764 2006-09-01 Borut Razem <borut.razem AT siol.net>
2765
2766         * sim/ucsim/cmd.src/cmdutil.cc: #include <sys/time.h> and <unistd.h>
2767           to make ppc-osx happy
2768
2769 2006-08-31 Borut Razem <borut.razem AT siol.net>
2770
2771         * sim/ucsim/cmd.src/newcmdposix.cc: #include <assert.h>
2772         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
2773         * sim/ucsim/cmd.src/newcmd.cc: #include <ctype.h>
2774         * support/regression/ports/ds390/spec.mk,
2775           support/regression/ports/mcs51/spec.mk,
2776           support/regression/ports/xa51/spec.mk: introduced DEV_NULL variable.
2777           To run regression tests in mingw environment:
2778           make DEV_NULL=NUL CC=gcc
2779
2780 2006-08-30 Borut Razem <borut.razem AT siol.net>
2781
2782         * sim/ucsim/cmd.src/newcmdposix.cc, sim/ucsim/cmd.src/newcmdposixcl.h,
2783           sim/ucsim/cmd.src/newcmdwin32.cc, sim/ucsim/cmd.src/newcmdwin32cl.h,
2784           sim/ucsim/app.cc, sim/ucsim/appcl.h, sim/ucsim/configure,
2785           sim/ucsim/configure.in, sim/ucsim/ddconfig_in.h, sim/ucsim/error.cc,
2786           sim/ucsim/errorcl.h, sim/ucsim/option.cc, sim/ucsim/optioncl.h,
2787           sim/ucsim/utils.cc, sim/ucsim/utils.h, sim/ucsim/cmd.src/Makefile.in,
2788           sim/ucsim/avr.src/avr.cc, sim/ucsim/avr.src/avrcl.h,
2789           sim/ucsim/cmd.src/bp.cc, sim/ucsim/cmd.src/bpcl.h,
2790           sim/ucsim/cmd.src/cmdconf.cc, sim/ucsim/cmd.src/cmdgui.cc,
2791           sim/ucsim/cmd.src/cmdmem.cc, sim/ucsim/cmd.src/cmdset.cc,
2792           sim/ucsim/cmd.src/cmdsetcl.h, sim/ucsim/cmd.src/cmdstat.cc,
2793           sim/ucsim/cmd.src/cmduc.cc, sim/ucsim/cmd.src/cmduccl.h,
2794           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
2795           sim/ucsim/cmd.src/command.cc, sim/ucsim/cmd.src/commandcl.h,
2796           sim/ucsim/cmd.src/get.cc, sim/ucsim/cmd.src/getcl.h,
2797           sim/ucsim/cmd.src/info.cc, sim/ucsim/cmd.src/newcmd.cc,
2798           sim/ucsim/cmd.src/newcmdcl.h, sim/ucsim/cmd.src/set.cc,
2799           sim/ucsim/cmd.src/show.cc, sim/ucsim/cmd.src/timer.cc,
2800           sim/ucsim/hc08.src/hc08.cc, sim/ucsim/hc08.src/hc08cl.h,
2801           sim/ucsim/s51.src/Makefile.in, sim/ucsim/s51.src/interrupt.cc,
2802           sim/ucsim/s51.src/interruptcl.h, sim/ucsim/s51.src/pca.cc,
2803           sim/ucsim/s51.src/pcacl.h, sim/ucsim/s51.src/port.cc,
2804           sim/ucsim/s51.src/portcl.h, sim/ucsim/s51.src/serial.cc,
2805           sim/ucsim/s51.src/serialcl.h, sim/ucsim/s51.src/timer0.cc,
2806           sim/ucsim/s51.src/timer0cl.h, sim/ucsim/s51.src/timer1.cc,
2807           sim/ucsim/s51.src/timer1cl.h, sim/ucsim/s51.src/timer2.cc,
2808           sim/ucsim/s51.src/timer2cl.h, sim/ucsim/s51.src/uc390.cc,
2809           sim/ucsim/s51.src/uc390cl.h, sim/ucsim/s51.src/uc390hw.cc,
2810           sim/ucsim/s51.src/uc390hwcl.h, sim/ucsim/s51.src/uc51.cc,
2811           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/wdt.cc,
2812           sim/ucsim/s51.src/wdtcl.h, sim/ucsim/sim.src/hw.cc,
2813           sim/ucsim/sim.src/hwcl.h, sim/ucsim/sim.src/mem.cc,
2814           sim/ucsim/sim.src/memcl.h, sim/ucsim/sim.src/obsolete.cc,
2815           sim/ucsim/sim.src/obsolete.h, sim/ucsim/sim.src/sim.cc,
2816           sim/ucsim/sim.src/simcl.h, sim/ucsim/sim.src/stack.cc,
2817           sim/ucsim/sim.src/stackcl.h, sim/ucsim/sim.src/test_mem_speed.cc,
2818           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
2819           sim/ucsim/xa.src/xa.cc, sim/ucsim/xa.src/xacl.h,
2820           sim/ucsim/z80.src/z80.cc, sim/ucsim/z80.src/z80cl.h:
2821           ucsim WIN32 native port
2822
2823 2006-08-30 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2824
2825         * doc/sdccman.lyx: added note on dynamic memory heap initialization
2826
2827 2006-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
2828
2829         * src/mcs51/gen.c (genAnd, genOr, genXor): fixed bug 1546986
2830         * src/ds390/gen.c (aopGetUsesAcc): handle AOP_DPTR2 and AOP_DPTRn too
2831
2832 2006-08-26 Maarten Brock <sourceforge.brock AT dse.nl>
2833
2834         * src/ds390/gen.c (genAnd, genOr, genXor): fixed bug 1546986
2835         * support/regression/tests/bug1546986.c: new, added
2836         * as/mcs51/.cvsignore,
2837         * debugger/mcs51/.cvsignore,
2838         * src/.cvsignore: deleted
2839
2840 2006-08-25 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2841
2842         * device/include/mcs51/P89c51RD2.h: fixed bug 1546936 (error in sbit
2843           definitions)
2844
2845 2006-08-20 Borut Razem <borut.razem AT siol.net>
2846
2847         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h:
2848           removed cl_listen_console::match(), cl_console::match(),
2849           restructured cl_commander::proc_input()
2850
2851 2006-08-16 Borut Razem <borut.razem AT siol.net>
2852
2853         * sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/newcmdcl.h,
2854           sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/cmdutil.h,
2855           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/uc.cc: code cleaning
2856
2857 2006-08-14 Borut Razem <borut.razem AT siol.net>
2858
2859         * support/regression/Makefile.in,
2860           support/regression/ports/pic14/gpsim.cmd,
2861           support/regression/ports/pic14/spec.mk,
2862           support/regression/ports/pic14/support.c:
2863           added pic14 regression test
2864
2865 2006-08-14 Maarten Brock <sourceforge.brock AT dse.nl>
2866
2867         * as/doc/asxhtm.html: documented changed ABS behaviour
2868         * as/doc/README: fixed some typos
2869
2870 2006-08-13 Maarten Brock <sourceforge.brock AT dse.nl>
2871
2872         * support/regression/tests/float_trans.c: disabled test if __STDC_IEC_559__
2873           not defined on host
2874
2875 2006-08-12 Borut Razem <borut.razem AT siol.net>
2876
2877         * support/regression/fwk/include/testfwk.h,
2878           support/regression/fwk/lib/testfwk.c,
2879           support/regression/generate-cases.py,
2880           support/regression/Makefile.in:
2881           regression test framework does not depend on function pointers and
2882           variable arguments
2883
2884 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
2885
2886         * device/include/stddef.h: c temporary hack to fix bug 1518273
2887
2888 2006-08-09 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
2889
2890         * device/include/mcs51/cc2510fx.h: added
2891         * src/z80/z80.dsp, src/gbz80/gbz80.dsp: added support/Util/strcmpi.ch
2892           to projects.
2893
2894 2006-08-09 Maarten Brock <sourceforge.brock AT dse.nl>
2895
2896         * as/z80/assym.c (mlookup): ignore case when looking up mnemonics
2897         * as/z80/Makefile.in: added strcmpi.c
2898         * as/z80/z80adr.c: added upper case registers and lower case conditionals
2899         * support/Util/strcmpi.ch: added with intention to remove from mcs51/hc08
2900
2901 2006-08-08 Maarten Brock <sourceforge.brock AT dse.nl>
2902
2903         * device/lib/gbz80/asm_strings.s,
2904         * device/lib/gbz80/crt0_rle.s,
2905         * device/lib/gbz80/div.s,
2906         * device/lib/gbz80/mul.s,
2907         * device/lib/gbz80/shift.s,
2908         * device/lib/z80/asm_strings.s,
2909         * device/lib/z80/crt0_rle.s,
2910         * device/lib/z80/div.s,
2911         * device/lib/z80/mul.s,
2912         * device/lib/z80/shift.s: changed to all lower case menmonics except the
2913           flags which are all upper case
2914
2915 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
2916
2917         * as/z80/asm.h: made CASE_SENSITIVE 1
2918         * link/z80/aslink.h: made CASE_SENSITIVE 1
2919         * src/z80/gen.c (throughout): made all conditionals upper case
2920         * support/regression/tests/bug1503067.c: new
2921
2922 2006-08-07 Maarten Brock <sourceforge.brock AT dse.nl>
2923
2924         * src/z80/gen.c (aopPut): fixed bug !*ixy should be !*iyx,
2925           (shiftIntoPair): added case 2 for PAIR_IY,
2926           (setupToPreserveCarry): replaced parameters with iCode and check if
2927            PAIR_DE is in use to fix bug 1399290,
2928           (genPlus, genMinus): updated call to setupToPreserveCarry
2929         * support/regression/tests/bug1399290.c: new
2930
2931 2006-08-06 Maarten Brock <sourceforge.brock AT dse.nl>
2932
2933         * device/lib/Makefile.in (Z80SOURCES): enabled float support
2934         * sim/ucsim/z80.src/inst.cc (inst_rst): generate breakpoint on RST8,ACC==0
2935         * src/ds390/gen.c (shiftRLong),
2936         * src/hc08/gen.c (shiftLLong, shiftRLong): fixed bug 1533966
2937         * src/mcs51/gen.c (sameReg): changed to sameByte,
2938           (xch_a_aopGet): new,
2939           (shiftL2Left2Result, shiftR2Left2Result, shiftRLeftOrResult, shiftLLong,
2940            shiftRLong): fixed bug 1533966
2941         * src/z80/gen.c (shiftR2Left2Result, shiftL2Left2Result, genlshTwo,
2942           genLeftShiftLiteral, genrshTwo, genRightShiftLiteral): fixed bug 1533966
2943         * support/regression/Makefile.in: disabled z80, enabled ucz80
2944         * support/regression/tests/float_trans.c: enabled test for z80 and host
2945         * support/regression/tests/shifts2.c: new, for testing bug 1533966
2946
2947 2006-08-01 Borut Razem <borut.razem AT siol.net>
2948
2949         * src/mcs51/gen.c, src/dc390/gen.c: fixed warning:
2950           comparison is always false due to limited range of data type
2951           on PPC64 machine (openpower-linux1) where "char = unsigned char"
2952
2953 2006-08-01 Maarten Brock <sourceforge.brock AT dse.nl>
2954
2955         * sim/ucsim/hc08.src/hc08mac.h: removed faulty and unused add_u16_disp
2956         * sim/ucsim/hc08.src/hc08.cc: removed faulty and unused int8
2957         * sim/ucsim/z80.src/z80mac.h (add_u16_disp): use explicit signed char cast
2958         * sim/ucsim/z80.src/z80.cc: removed faulty and unused int8
2959
2960 2006-07-31 Borut Razem <borut.razem AT siol.net>
2961
2962         * sim/ucsim/configure, sim/ucsim/cmd.src/newcmdcl.h,
2963           sim/ucsim/cmd.src/newcmd.cc, sim/ucsim/cmd.src/cmdutil.cc,
2964           sim/ucsim/z80.src/Makefile.in, sim/ucsim/configure.in,
2965           sim/ucsim/hc08.src/Makefile.in, sim/ucsim/hc08.src/hc08.cc,
2966           sim/ucsim/ddconfig_in.h, sim/ucsim/s51.src/Makefile.in,
2967           sim/ucsim/s51.src/uc51cl.h, sim/ucsim/s51.src/serialcl.h,
2968           sim/ucsim/s51.src/uc51.cc, sim/ucsim/s51.src/serial.cc,
2969           sim/ucsim/app.cc, sim/ucsim/avr.src/Makefile.in:
2970           enable ucsim mingw compilation. Serial port is disabled,
2971           since it uses termios.h API, which is not available on native
2972           WIN32
2973
2974 2006-07-31 Borut Razem <borut.razem AT siol.net>
2975
2976         * Small Device C Compiler 2.6.0 released
2977         * support/scripts/sdcc.nsi: added FULL_DOC option
2978         * .version, doc/sdccman.lyx: changed sdcc version to 2.6.1
2979
2980 2006-07-28 Borut Razem <borut.razem AT siol.net>
2981
2982         * support/scripts/sdcc.nsi: remove $INSTDIR/include/asm/pic16/*.h
2983         * doc/INSTALL.txt: updated
2984
2985 2006-07-27 Borut Razem <borut.razem AT siol.net>
2986
2987         * device/lib/pic/Makefile.in, device/lib/pic/Makefile.subdir,
2988           device/lib/pic/libdev/Makefile.in: fixed bug
2989           [ 1438354 ] pic libsdcc: distclean doesn't work
2990         * device/lib/pic16/Makefile.in, device/lib/pic16/Makefile.subdir,
2991           device/lib/pic16/libio/Makefile.in: fixed bug
2992           [ 1438344 ] pic16 lib: clean doesn't work properly
2993         * doc/knownbugs.html removed [ 1438354 ] and [ 1438344 ] from the list
2994
2995 2006-07-26 Maarten Brock <sourceforge.brock AT dse.nl>
2996
2997         * device/lib/pic/libsdcc/fsdiv.c,
2998         * device/lib/pic/libsdcc/fsmul.c,
2999         * device/lib/pic16/libsdcc/float/fsdiv.c,
3000         * device/lib/pic16/libsdcc/float/fsmul.c,
3001         * device/lib/_fsdiv.c,
3002         * device/lib/_fsmul.c: bugfix, handle too large and too small numbers
3003         * support/regression/tests/bug1520966.c: added
3004         * doc/knownbugs.html: removed [ 1520966 ] from the list
3005
3006 2006-07-25 Borut Razem <borut.razem AT siol.net>
3007
3008         * configure.in, configure, sdccconf_in.h: fixed bug
3009           [ 1519095 ] regression test onebyte.c fails on ppc64 host
3010         * doc/knownbugs.html: removed [ 1519095 ] from the list
3011
3012 2006-07-25 Maarten Brock <sourceforge.brock AT dse.nl>
3013
3014         * doc/knownbugs.html: added, contains list of known bugs at release
3015         * device/include/mcs51/compiler.h: fixed SFR32 for SDCC
3016
3017 2006-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
3018
3019         * device/include/mcs51/compiler.h: added SFRX for xdata based special
3020           function registers and corrected defaults with additional warning
3021         * device/lib/malloc.c: cosmetic changes
3022         * device/lib/realloc.c: bugfix for bug #1496907, Thanks Efim Monyak
3023         * src/ds390/ralloc.c (getRegBitNoSpil): reenabled,
3024           (fillGaps): and used it
3025
3026 2006-07-20 Raphael Neider <rneider AT web.de>
3027
3028         * src/pic/device.c (addMemRange,assignRegister): suppress verbose
3029           output unless SDCCPICDEBUG is set
3030         * device/lib/pic16/Makefile.rules (%.lib target): suppress verbose
3031           output if SILENT is set
3032
3033 2006-07-11 Borut Razem <borut.razem AT siol.net>
3034
3035         * doc/README.txt: updated
3036
3037 2006-07-10 Borut Razem <borut.razem AT siol.net>
3038
3039         * support/scripts/sdcc.nsi: added device/include/asm/pic/features.h and
3040           device/lib/src/pic/libm/*.c and device/lib/src/pic16/libsdcc/stack/*.S
3041           in WIN32 installation
3042         * .version, sdcc.spec, doc/sdccman.lyx: changed sdcc version to 2.6.0 -
3043           release candidate 1
3044
3045 2006-07-08 Maarten Brock <sourceforge.brock AT dse.nl>
3046
3047         * device/include/mcs51/XC866.h: added sbit definitions for Px_x, P1_x, P2_x
3048         * src/pic16/glue.c (initPointer): fixed bug 1496419 for pic16
3049
3050 2006-07-06 Maarten Brock <sourceforge.brock AT dse.nl>
3051
3052         * src/hc08/gen.c (genAddrOf): fixed bug when offset on stack is >127
3053
3054 2006-07-06 Borut Razem <borut.razem AT siol.net>
3055
3056         * support/regression/tests/bitfields.c:
3057           fixed bug [ 1518322 ] regression test bitfields fails on ppc hosts
3058         * support/regression/tests/constantRange.c:
3059           fixed bug [ 1518317 ] regression test constantRange fails on alpha host
3060
3061 2006-07-04 Borut Razem <borut.razem AT siol.net>
3062
3063         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in,
3064           src/port.mk,
3065           src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
3066           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
3067           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
3068           reverted changes from 2006-07-03
3069         * Makefile.common.in: added @CPPFLAGS@ to CPPFLAGS
3070         * support/regression/Makefile.in, support/regression/ports/host/spec.mk:
3071           added CPPFLAGS, used by the host port
3072
3073 2006-07-03 Bernhard Held <bernhard AT bernhardheld.de>
3074
3075         * support/regression/valdiag/tests/switch.c,
3076         * support/regression/valdiag/tests/constantRange.c: adapted to gcc 4
3077         * support/regression/tests/libmullong.c: fixed for host
3078         * support/regression/ports/host/spec.mk: disable all warnings for host,
3079         SDCC runs with --less-pedantic too
3080
3081 2006-07-03 Borut Razem <borut.razem AT siol.net>
3082
3083         * src/configure.in, src/configure, src/Makefile.in, as/z80/Makefile.in:
3084           defined CPPFLAGS
3085         * src/port.mk: defined CPPFLAGS, renamed to src/port.mk.in
3086         * src/avr/Makefile.in, src/ds390/Makefile.in, src/ds400/Makefile.in,
3087           src/hc08/Makefile.in, src/mcs51/Makefile.in, src/pic16/Makefile.in,
3088           src/pic/Makefile.in, src/xa51/Makefile.in, src/z80/Makefile.in:
3089           include ../port.mk
3090         * sim/ucsim/main_in.mk, sim/ucsim/avr.src/Makefile.in,
3091           sim/ucsim/gui.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
3092           sim/ucsim/s52.src/Makefile.in, sim/ucsim/sim.src/Makefile.in,
3093           sim/ucsim/xa.src/Makefile.in: ignore header files for dependencies
3094
3095 2006-07-02 Raphael Neider <rneider AT web.de>
3096
3097         * src/pic16/devices.inc,
3098         * device/include/pic16/pic18fregs.h,
3099         * device/include/pic16/pic18f4550.h,
3100         * device/lib/pic16/pics.all,
3101         * device/lib/pic16/libdev/pic18f4550.c: added support for 18f4550
3102
3103 2006-07-01 Bernhard Held <bernhard AT bernhardheld.de>
3104
3105         * as/hc08/lkaomf51.c (OutputName),
3106         * as/mcs51/lkaomf51.c (OutputName),
3107         * as/z80/asmain.c (asmbl),
3108         * src/ds390/main.c (asmLineNodeFromLineNode),
3109         * src/hc08/ralloc.c (hc08_assignRegisters),
3110         * src/mcs51/main.c (asmLineNodeFromLineNode),
3111         * src/xa51/ralloc.c (checkRegMask),
3112         * src/xa51/gen.c (emitcode),
3113         * src/z80/gen.c (_emit2),
3114         * src/SDCCast.c (searchLitOp),
3115         * src/SDCCglobl.h,
3116         * support/packihx/packihx.c,
3117         * support/Util/MySystem.c (split_command): fix gcc 4 warnings
3118         * src/ds390/gen.c (aopPutUsesAcc),
3119         * src/ds390/ralloc.c (getRegBitNoSpil): unused, therefore disabled
3120         * support/regression/tests/libmullong.c (mullong_wrapper),
3121         * src/SDCCsymt.c (powof2),
3122         * src/SDCCast.c,
3123         * src/SDCCicode.c: renamed TYPE_WORD by TYPE_TARGET_INT and so on
3124         * src/SDCCsymt.h: added TYPE_TARGET_*
3125         * src/SDCCutil.c (doubleFromFixed16x16, fixed16x16FromDouble),
3126         * src/SDCCutil.h (doubleFromFixed16x16, fixed16x16FromDouble): moved to
3127         SDCCast because 1) header problems 2) this is the right place
3128         * src/SDCCast.c (doubleFromFixed16x16, fixed16x16FromDouble): added
3129         * src/SDCCval.h (doubleFromFixed16x16, fixed16x16FromDouble): added
3130         prototype
3131
3132 2006-06-29 Bernhard Held <bernhard AT bernhardheld.de>
3133
3134         * src/SDCCicode.h: removed buggy semicolon in unused macro
3135         * src/SDCClrange.c (findPrevUseSym, rlivePoint): fixed bug #1486853,
3136         search for previous definiton of auto symbols too,
3137         (findPrevUse): fixed logic of emitWarnings
3138
3139 2006-06-26 Raphael Neider <rneider AT web.de>
3140
3141         * src/pic16/gen.c (genFunction, genEndFunction): also preserve
3142           PCLATH and PCLATU on interrupts, potentially fixes #1505141
3143
3144 2006-06-25 Raphael Neider <rneider AT web.de>
3145
3146         * device/lib/pic/libm: NEW, added math library functions
3147         * device/lib/pic/libsdcc: NEW; added float support functions
3148         * device/lib/pic/{Makefile.in,configure.in,configure}: added libm/
3149         * device/include/pic/{limits.h,errno.h,sdcc-lib.h,float.h,math.h}:
3150           NEW, added math related headers
3151         * device/include/asm/pic/features.h: NEW
3152         * src/pic/gen.c (emitpcode_real): emit warning on NULL pCodeOp,
3153           (popGet): allow larger offsets for AOP_PCODE,
3154           (genDataPointerSet): handle literals explicitly, more debug output,
3155           (genAssign): fixed for float using aopLiteral ;-)
3156         * src/pic/glue.c (pic14createInterruptVect): inserted pagesel before
3157           GOTO initialisation routine
3158         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): set wasUsed
3159           flag on registers, fixes #1469043 (local variables do not work)
3160         * src/pic/main.c (_pic14_do_link),
3161         * src/pic16/main.c (_pic16_linkEdit): use fullDstFileName if
3162           available
3163
3164 2006-06-25 Borut Razem <borut.razem AT siol.net>
3165
3166         * device/lib/pic16/libc/stdio/sprintf.c: return the number of
3167           characters printed (not including the trailing '\0' used to end
3168           output to strings). Problem detected in regression test bug-927659.c.
3169           NOTE: printf() family functions should return int instead
3170           unsigned int!
3171         * device/lib/pic16/libc/stdio/vfprintf.c: "%%" prints "%", unknown
3172           specifier are printed as themselves
3173         * sdcc/support/regression/tests/bug1057979.c: pic16 printf doesn't
3174           support flags, width and precision specifiers
3175
3176 2006-06-24 Borut Razem <borut.razem AT siol.net>
3177
3178         * sdcc/support/regression/tests/bitvars.c: added gbz80, pic16 and pic16
3179           to the list of sdcc tagrets not supporting bit type
3180         * sdcc/support/regression/tests/bug-905992.c.c: excluded regression
3181           testfor pic16 due to bug:
3182           [ 1511794 ] pic16: regression test bug-895992.c fails
3183
3184 2006-06-24 Maarten Brock <sourceforge.brock AT dse.nl>
3185
3186         * src/mcs51/gen.c (genCmp): optimization for RFE 1162453
3187         * src/SDCCglue.c (initPointer), fixed bug 1496419
3188         * support/regression/tests/bug1496419.c: new, added
3189
3190 2006-06-22 Borut Razem <borut.razem AT siol.net>
3191
3192         * support/regression/ports/pic16/support.c: use gpsim usart module from
3193           libgpsim_modules library
3194
3195 2006-06-21 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3196
3197         * device/include/mcs51/at89c51ed2.h: Fixed bug 1510144 changed
3198         IP0H to IPH0.
3199
3200 2006-06-19 Raphael Neider <rneider AT web.de>
3201
3202         * src/pic/glue.h,src/pic16/glue.h: added prototypes
3203         * src/pic/glue.c,src/pic16/glue.c (pic1x_stringInSet,
3204           pic1x_emitSymbolIfNew): NEW, check for a string in a set,
3205           (pic14printExterns,pic14printPublics,pic16printPublics,
3206           pic16_printExterns): use new functions to emit symbols
3207           (picglue,pic16glue): emit publics before emitting externs
3208         * src/pic/gen.c,src/pic16/gen.c (genFunction): remember the names of
3209           locally defined functions to avoid bug #1443651
3210         * support/regression/tests/bug-716242.c: removed pic16 workaround
3211         * support/regression/ports/pic16/spec.mk: ignore errors during build
3212
3213 2006-06-19 Raphael Neider <rneider AT web.de>
3214
3215         * src/pic/glue.h: added pic14aopLiteral prototype
3216         * src/pic/glue.c (pic14aopLiteral): return unsigned int
3217         * src/pic/gen.c: removed stdint.h dependency
3218           (aopGet): use Safe_strdup()
3219           (bitpatternFromVal): removed, replaced use with pic14aopLiteral
3220           (genDataPointerSet): use pic14aopLiteral()
3221         * src/pic16/glue.h, src/pic16/glue.c, src/pic16/gen.c: similar changes
3222           for pic16; thanks to Bernhard and Maarten
3223
3224 2006-06-18 Borut Razem <borut.razem AT siol.net>
3225
3226         * support/regression/tests/structflexarray.c: flexible array members
3227           not supported by gcc < 3
3228         * sim/ucsim/configure, sim/ucsim/configure.in: do not compile serio
3229           GUI tool by default
3230         * src/pic/gen.c: don't include [p]strdin.h on solaris
3231         * support/Util/pstdint.h: addad svn attributes
3232         * support/regression/tests/constantRange.c,
3233           support/regression/tests/rotate.c: include inttypes.h instead
3234           stdint.h on solaris, addad svn attributes
3235
3236 2006-06-18 Raphael Neider <rneider AT web.de>
3237
3238         * src/SDCCsymt.c (initCSupport): change return type of divschar to
3239           int for PIC16
3240         * src/pic16/genarith.c (genAddLit): sign-extend via standard routine
3241           (pic16_genMinusBits): simplified sign-extension
3242           (pic16_genUMult8XLit_8,pic16_genUMult8X8_8): renamed to
3243             pic16_genMult8XLit_n resp. pic16_genMult8X8_n, fixed and
3244             adjusted to correctly handle mixed-signed operands, disabled
3245             now unused multiplciation routines
3246         * src/pic16/gen.c (pic16_pushpCodeOp): fixed to handle literals
3247           (assignResultValue): added argument denoting the size of the result
3248             as returned by the function (fixes upcasts in assigning from
3249             function calls: char foo(); int i = foo();)
3250           (genCall,genPcall,genGenPointerGet,genReceive): pass size of
3251             function result to assignResultValue
3252           (genMult): disabled inlined multiplication code
3253           (genDiv): augmented to also handle the modulus operator, fixed to
3254             handle mixed-signed operands correctly
3255           (genMod): simply call genDiv, disabled unused code
3256           (genAssign): fixed missing (sign-)extension on result
3257         * src/pic16/main.c (_hasNativeMulFor): accept literals [-128..256) as
3258             valid char operands, allow signed operands for native code, added
3259             division and modulo operator handling
3260         * device/lib/pic16/libsdcc/char/divschar.c: divschar returns an int
3261
3262         As a consequence, onebyte.c (if split into two files) and muldiv.c
3263         pass regression tests.
3264
3265 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3266
3267         * doc/Makefile.in: two runs of makeindex seem needed to get
3268         correct page references in the index of sdccman.pdf
3269         * doc/sdccman.lyx: mentioned cmon51, added links, small changes
3270
3271 2006-06-17 Borut Razem <borut.razem AT siol.net>
3272
3273         * sdcc/device/lib/Makefile.in: corrected PORTINCDIR path
3274
3275 2006-06-17 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3276
3277         * doc/sdccman.lyx: updated, added (porting source code, debugging),
3278         mentioned ec2drv and paulmon
3279
3280 2006-06-16 Maarten Brock <sourceforge.brock AT dse.nl>
3281
3282         * as/mcs51/lkarea.c (lnkarea2): clear new xdatamap, bugfix for two
3283           consecutive abs areas
3284           (find_empty_space, allocate_space): added map to handle codemap or
3285            xdatamap,
3286           (lnksect2): renamed rloc to locIndex, fixed bug 960060 by handling
3287            absolute idata and xdata
3288         * as/mcs51/lkmem.c (summary2): updated legend
3289
3290 2006-06-16 Raphael Neider <rneider AT web.de>
3291
3292         * src/pic16/gen.c (shiftR2Left2Result): fixed bug #1507127
3293
3294 2006-06-13 Maarten Brock <sourceforge.brock AT dse.nl>
3295
3296         * debugger/mcs51/cmd.c (cmdListFunctions): fixed bugs 1181163 and
3297           1208515
3298         * src/SDCClrange.c (findPrevUse): fixed bug 1294475
3299
3300 2006-06-13 Vangelis Rokas <vrokas AT users.sourceforge.net>
3301
3302         * src/port.h (struct PORT): added field gp_tags, to hold the tag
3303         value of generic pointers,
3304         * src/avr/main.c,
3305           src/ds390/main.c,
3306           src/hc08/main.c,
3307           src/izt/i186.c,
3308           src/izt/tlcs900h.c,
3309           src/mcs51/main.c,
3310           src/pic/main.c,
3311           src/pic16/main.c,
3312           src/xa51/main.c,
3313           src/z80/main.c: PORT structure, added elements for gp_tags field,
3314         * src/SDCCsymt.h: replaced hardwired values of GPTYPE_* macros with
3315         fields in the PORT structure of each port,
3316         * src/SDCCast.c (decorateType): allow processing of generic pointers
3317         for PIC16 port (FPTRSIZE equals GPTRSIZE), also set GPTYPE_NEAR for
3318         S_FIXED symbols
3319
3320 2006-06-12 Maarten Brock <sourceforge.brock AT dse.nl>
3321
3322         * link/z80/lkgb.c,
3323         * link/z80/lkgg.c,
3324         * src/pic16/gen.c,
3325         * src/pic16/main.c,
3326         * src/pic16/pcode.c,
3327         * src/pic/main.c,
3328         * src/pic/pcoderegs.c,
3329         * src/SDCCicode.c,
3330         * src/SDCCmain.c,
3331         * src/SDCCsymt.c: replaced all exit(-1) by exit(EXIT_FAILURE) to fix
3332           bug 1504689 on minGW
3333
3334 2006-06-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
3335
3336         * device/lib/printf_tiny.c: fixed bug #1465675 (%x format specifier)
3337
3338 2006-06-12 Bernhard Held <bernhard AT bernhardheld.de>
3339
3340         * src/SDCCast.c (backPatchLabels): fixed bug #1504636
3341
3342 2006-06-11 Maarten Brock <sourceforge.brock AT dse.nl>
3343
3344         * device/lib/printf_large.c (OUTPUT_CHAR, _output_char): added and used
3345           for optimization
3346
3347 2006-06-11 Vangelis Rokas <vrokas AT users.sourceforge.net>
3348
3349         * src/pic16/gen.c (genCast): fixed bug with assignment of a pointer
3350         to a char variable. Fixed bug #1504211
3351         * device/include/pic16/adc.h,
3352         device/include/lib/pic16/libio/adc/adcopen.c: applied patch #1364387
3353         and fixed bug #1364390
3354
3355 2006-06-10 Borut Razem <borut.razem AT siol.net>
3356
3357         * CVSROOT: removed the CVS left-over
3358
3359 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
3360
3361         * as/hc08/asmain.c (asexit),
3362         * as/hc08/lkmain.c (lkexit),
3363         * as/mcs51/asmain.c (asexit),
3364         * as/mcs51/lkmain.c (lkexit),
3365         * src/SDCCglue.c (DEFSETFUNC),
3366         * src/SDCCmain.c (linkEdit, assemble),
3367         * support/librarian/sdcclib.c (AddRel),
3368           replaced unlink() by standard C remove()
3369         * src/SDCC.y: replaced removePostIncDecOps() by createRMW()
3370         * src/SDCCast.c (replaceAstWithTemporary, createRMW,
3371           gatherImplicitVariables): new, added to fix bug 608752,
3372           (createFunction): added gatherImplicitVariables()
3373         * src/SDCCast.h: added createRMW prototype
3374         * src/SDCCsymt.h (struct symbol): added infertype
3375         * support/regression/tests/bug608752.c: new, added
3376
3377 2006-06-10 Raphael Neider <rneider AT web.de>
3378
3379         * src/pic16/gen.c (pic16_aopOp): use WREG as destination even for
3380           multibyte dummy reads (fixes #1503234)
3381
3382 2006-06-10 Maarten Brock <sourceforge.brock AT dse.nl>
3383
3384         * device/include/mcs51/compiler.h: new, added header file to enable
3385           creating common sfr definition header files for different compilers
3386
3387 2006-06-05 Raphael Neider <rneider AT web.de>
3388
3389         * src/pic16/{pcode.h,genarith.c}:
3390           introduced pCodeOp combining any two pCodeOps (previously only
3391           two register operands could be combined), removed pcop2 from
3392           pCodepReg, replaced pCodeOpReg2 with pCodeOp2, fixes #1492366
3393         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): added case for PO_TWO_OPS
3394         * src/pic16/gen.c (pic16_popGet2,pic16_popGet2p,pic16_popCombine2):
3395           rewritten to use new PO_TWO_OPS
3396         * src/pic16/main.c (_hasNativeMulFor): cover more cases natively,
3397         * src/pic16/pcode.c (pic16_newpCodeOpImmd): initialize rIdx field,
3398           (pic16_newpCodeOp): catch invalid attempts on PO_TWO_OPS,
3399           (pic16_newpCodeOp2): NEW, create combined pCodeOp,
3400           (pic16_get_op): embraced return arg to allow #define return(x),
3401             added new case for combined opcodes
3402           (pic16_get_op2): reduced to use pic16_get_op() on second pCodeOp,
3403           (pic16_pCode2str,pic16_getRegFrompCodeOp,
3404            pic16_getRegFromInstruction2): fixed/added handling of new pCodeOp
3405
3406 2006-06-04 Bernhard Held <bernhard AT bernhardheld.de>
3407
3408         * src/SDCCval.c (checkConstantRange): added
3409         * src/SDCCval.h: added checkConstantRange
3410         * support/Util/SDCCerr.c,
3411         * support/Util/SDCCerr.h: replaced unused W_IF_NEVER_TRUE and
3412         W_IF_ALWAYS_TRUE by W_COMP_RANGE and W_LIT_OVERFLOW
3413         * src/SDCC.y: moved early 'condition transformations' to SDCCast.c
3414         * src/SDCCast.c (decorateType): added checkConstantRange,
3415         added 'condition transformations' from SDCC.y so that now W_COMP_RANGE
3416         can be emitted with the correct always true/false warning,
3417         added optimization for double '!';
3418         result of decorateType() must be assigned back to the tree, because
3419         decorateType() can change the tree
3420         * src/SDCCicode.c (geniCodeLogic),
3421         (geniCodeAssign): replaced new checkConstantRange, added warnings,
3422         (checkConstantRange): removed, it was only a fragment which never
3423         emitted a warning
3424         * src/SDCCsymt.c (computeType): fixed promotion for
3425         "-1 < (unsigned bit) b"
3426         * src/pic/ralloc.c (packRegsForAssign),
3427         * src/pic16/ralloc.c (packRegsForAssign),
3428         * src/hc08/ralloc.c (packRegsForAssign),
3429         * src/z80/ralloc.c (packRegsForAssign): ported fix for bug #930931
3430         from mcs51
3431         * src/mcs51/ralloc.c (packRegsForAssign): removed outcommented source
3432         * support/regression/tests/constantRange.c: added
3433         * support/valdiag/tests/constantRange.c: added
3434         * support/valdiag/valdiag.py: added -DPORT_HOST=1
3435
3436 2006-06-02 Borut Razem <borut.razem AT siol.net>
3437
3438         * support/regression/ports/pic16/support.c: increase stack size
3439           to 255 bytes
3440         * support/regression/Makefile.in: sort tests by name so that the
3441           resutlts can be compared on different machines / platforms
3442
3443 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
3444
3445         * device/lib/printf_large.c (output_digit): optimized further, Tnx Frieder
3446         * src/ds390/gen.c (emitLabel): new, added,
3447           (genDjnz): fixed stack overflow bug,
3448           (throughout): cosmetic changes to sync with mcs51/gen.c,
3449           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl)
3450         * src/mcs51/gen.c (genEndFunction): small optimization,
3451           (throughout): cosmetic changes to sync with ds390/gen.c
3452
3453 2006-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
3454
3455         * device/lib/printf_large.c (output_digit, calculate_digit): optimized,
3456           (_print_format): fixed printing pointers
3457         * src/mcs51/gen.c (emitLabel, movb): new, added,
3458           (genAssign): small optimization,
3459           (genDjnz): fixed stack overflow bug,
3460           (throughout): replaced sprintf with SNPRINTF,
3461           replaced mcs51_regWithIdx with REG_WITH_INDEX,
3462           replaced emitcode("mov", "b,...") with MOVB(...),
3463           replaced emitcode("", "%05d$:", lbl->key + 100) with emitLabel(lbl),
3464           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
3465         * src/mcs51/peeph.def: added rules 140 and 264
3466         * src/SDCCmem.c (allocLocal): store register declared locals in DSEG/OSEG
3467           so they may get optimized into registers
3468
3469 2006-05-30 Maarten Brock <sourceforge.brock AT dse.nl>
3470
3471         * src/SDCCmain.c (optionsTable, parseCmdLine): handle --use-stdout
3472           immediately when encountered,
3473           (printUsage): always use stderr even on windows
3474
3475 2006-05-30 Bernhard Held <bernhard AT bernhardheld.de>
3476
3477         * src/SDCCast.c (isLoopCountable): fixed bug #1478316
3478         (processParms): fixed bug #1247551
3479         * src/SDCCmain.c (printVersionInfo, printOptions, printUsage,
3480         parseCmdLine, main): print '--version' to stdout,
3481         print 'help' to stdout if --help is given,
3482         print 'help' to stderr and exit with EXIT_FAILURE if no or bad
3483         arguments are given; fixed --help
3484
3485 2006-05-27 Bernhard Held <bernhard AT bernhardheld.de>
3486
3487         * src/SDCCcse.c (findPointerSet): fixed bug #1493710
3488         * support/regression/tests/bug-1493710.c: added
3489
3490 2006-05-27 Borut Razem <borut.razem AT siol.net>
3491
3492         * support/regression/fwk/lib/testfwk.c: define array in _printn() as
3493           static instead auto
3494         * support/regression/ports/pic16/support.c: increase stack size
3495           from default 64 bytes to 128 bytes
3496         * support/regression/tests/staticinit.c,
3497           support/regression/tests/float.c: regression tests fully enabled
3498           for pic16 port by putting the initialized data arrays into the code
3499           section
3500         * support/regression/ports/pic16/spec.mk: don't link default libraries.
3501           This was changed by mistake in the previous version.
3502
3503 2006-05-28 Vangelis Rokas <vrokas AT users.sourceforge.net>
3504
3505         * src/pic16/gen.c (genFunction, genEndFunction): some
3506         beautifications, fixed bug with falsely restoring FSR2 in large
3507         stack model, thanks to Beau E. Cox for reporting the bug
3508
3509 2006-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
3510
3511         * debugger/mcs51/break.c,
3512         * debugger/mcs51/cmd.c (throughout): removed unused variables and labels,
3513           use %p to print pointers, made address variables unsigned
3514         * debugger/mcs51/cmd.c (infoSymbols): added missing parameter to printf
3515         * debugger/mcs51/symtab.c (parseSymbol): must return something
3516         * src/mcs51/gen.c (aopForSym): small optimization,
3517            moved declarations mcs51_ptrRegReq and mcs51_nRegs to ralloc.h,
3518           (freeAsmop): added missing break,
3519           (aopPut): removed parameter bvolatile, determine it inside the function,
3520           (saveRegisters, unsaveRegisters): small optimization,
3521           (genIpush): removed pointless check,
3522           (throughout): replaced Safe_calloc, strcpy with Safe_strdup,
3523           replaced sprintf with SNPRINTF,
3524           replaced strcpy with strncpyz,
3525           updated aopPut calls,
3526           replaced D(emitcode("; genXXX", "")) with D(emitcode(";", "genXXX"))
3527         * src/mcs51/ralloc.h:  added declarations mcs51_ptrRegReq and mcs51_nRegs
3528
3529 2006-05-24 Borut Razem <borut.razem AT siol.net>
3530
3531         * support/regression/tests/bug-221100.c: fixed xdata problem caused by
3532           modification of test for the pic16 port, put the array to the code
3533           memory for pic16port; thanks to Maarten Brock and Frieder Ferlemann
3534
3535 2006-05-23 Jesus Calvino-Fraga <jesusc at ece.ubc.ca>
3536
3537         * src/pic/gen.c: MSC 6 does not have <stdint.h>.  Use pstdint.h instead.
3538         * support/Util/pstdint.h: added
3539
3540 2006-05-22 Borut Razem <borut.razem AT siol.net>
3541
3542         * src/regression/Makefile: removed bool2.c test, added -q linker option
3543         * src/regression/add2.c, src/regression/add3.c, src/regression/bool1.c,
3544           src/regression/bool3.c, src/regression/nestfor.c, src/regression/ptrfunc.c,
3545           src/regression/compare.c, src/regression/or1.c, src/regression/compare2.c,
3546           src/regression/while.c, src/regression/compare3.c, src/regression/compare4.c,
3547           src/regression/compare5.c, src/regression/sub2.c, src/regression/rotate1.c,
3548           src/regression/rotate2.c, src/regression/rotate3.c, src/regression/rotate4.c,
3549           src/regression/switch1.c, src/regression/rotate5.c, src/regression/for.c,
3550           src/regression/add.c, src/regression/sub.c, src/regression/call1.c:
3551           define SUPPORT_BIT_TYPES 0, removed unused bit variables
3552
3553 2006-05-22 Raphael Neider <rneider AT web.de>
3554
3555         * src/pic16/gen.c (pic16_storeForReturn): fragile fix for
3556           bug #1492360 (problematic due to generic pointers, see code)
3557
3558 2006-05-22 Borut Razem <borut.razem AT siol.net>
3559
3560         * support/regression/ports/pic16/specs.mk: removed stack size linker
3561           directive
3562         * support/regression/tests/array.c,
3563           support/regression/tests/bitopcse.c,
3564           support/regression/tests/bug-908454.c,
3565           support/regression/tests/malloc.c: modified for pic16 regression test
3566         * support/regression/tests/bitfields.c:
3567           pic16 - excluded bitfileds of size > 8
3568         * support/regression/tests/bp.c: pic16 - reduced data size
3569         * support/regression/tests/bug-221100.c: pic16 - reduced data size
3570         * support/regression/tests/bug-460010.c:
3571           pic16 - used the absolute address the fits in memory
3572         * support/regression/tests/bug-716242.c:
3573           bug [ 1443651 ] pic 16: redefining symbol that cannot be redefined.
3574         * support/regression/tests/float.c:
3575           pic16 - excluded - data size too big
3576         * support/regression/tests/onebyte.c:
3577           pic16 - bug [ 1444425 ] onebyte.c regression tes fails on pic16
3578         * support/regression/tests/shifts.c:
3579           pic16 - function names probably have to differ in first X characters
3580           (gpasm limitation?)
3581         * support/regression/tests/staticinit.c:
3582           pic16 - excluded some tests due error: no target memory available for
3583           section ".idata"
3584
3585 2006-05-22 Borut Razem <borut.razem AT siol.net>
3586
3587         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
3588           second try. Thanks Stas Sergeev once more.
3589
3590 2006-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
3591
3592         * src/hc08/gen.c (transferAopAop): aop forced to stack was not restored,
3593           (genLeftShift, genRightShift): fixed bug 1491627
3594         * src/hc08/peeph.def (rules 7, 8.x): added
3595         * support/regression/tests/shifts.c (ShiftLeftByParam,
3596           ShiftRightByParam, testShiftByParam): added to test variable shifting
3597
3598 2006-05-20 Raphael Neider <rneider AT web.de>
3599
3600         * src/pic/gen.c (bitpatternFromVal): fixed for 64-bit machines
3601         * src/pic16/ralloc.c (newReg): use correct name in hashtable,
3602           (allocReg): add only new registers to dynAllocRegs,
3603           (pic16_assignRegisters): do not reset dynrIdx, fixes bugs
3604             #1489055, #1445850, and probably #1483693
3605
3606 2006-05-19 Vangelis Rokas <vrokas AT users.sourceforge.net>
3607
3608         * src/pic16/glue.c (pic16_emitConfigRegs, pic16_emitIDRegs): fixed
3609         bug in for-loop that didn't emit the last of CONFIG and ID registers
3610
3611 2006-05-18 Maarten Brock <sourceforge.brock AT dse.nl>
3612
3613         * src/mcs51/gen.c (genCodePointerGet): inc dptr instead of loading acc
3614           with offset
3615         * src/mcs51/peeph.def (186.x): updated and reenabled to fix bugs
3616           1489016, 1434401 and 1490124
3617         * src/ds390/peeph.def (186.x, 227.x): updated and reenabled to fix bugs
3618           1489016, 1434401 and 1490124
3619
3620 2006-05-17 Borut Razem <borut.razem AT siol.net>
3621
3622         * support/Util/dbuf.c: fixed bug #1489008 fix dbuf_c_str(),
3623           thanks Stas Sergeev
3624
3625 2006-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
3626
3627         * device/include/mcs51/P89c51RD2.h,
3628         * device/include/mcs51/P89LPC901.h,
3629         * device/include/mcs51/P89LPC922.h,
3630         * device/include/mcs51/P89LPC932.h: added, thanks Omar Espinosa
3631
3632 2006-05-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
3633
3634         * device/lib/pic16/libsdcc/stack/{stack.S, Makefile.in}: add workaround
3635         to fix missing stack pragma in compiled binary object file,
3636
3637 2006-05-14 Bernhard Held <bernhard AT bernhardheld.de>
3638
3639         * support/packihx/configure.in,
3640         * support/packihx/configure: removed warning, autoconf >= 2.5x can
3641         determine sizeof basic types even while cross compiling
3642
3643 2006-05-13 Bernhard Held <bernhard AT bernhardheld.de>
3644
3645         * src/avr/gen.c (aopop),
3646         * src/ds390/gen.c (aopOp),
3647         * src/hc08/gen.c (aopOp),
3648         * src/mcs51/gen.c (aopop),
3649         * src/pic16/gen.c (pic16_aopOp),
3650         * src/pic/gen.c (aopOp),
3651         * src/z80/gen.c (aopop): fix for bug #1479882; use new, exclusive asmop
3652         if size of operand is smaller than spill location
3653
3654 2006-05-12 Borut Razem <borut.razem AT siol.net>
3655
3656         * *.dsw, *.dsp: changed property svn:eol-style to CRLF since they
3657           have to have CR/LF line endings even if they are checked out on *nix
3658           or on WIN32 in cygwin binmode
3659
3660 2006-05-12 Maarten Brock <sourceforge.brock AT dse.nl>
3661
3662         * doc/sdccman.lyx: documented numeric ranges, WEBDOC #1442369
3663         * device/include/ds80c390.h: added sfr16 definitions
3664         * src/ds390/gen.c,
3665         * src/ds390/gen.h,
3666         * src/ds390/main.c,
3667         * src/ds390/ralloc.c,
3668         * src/ds390/ralloc.h: changes all over the place to sync with mcs51
3669           fixing several bugs and adding sfr16/sfr32, reentrant bit params,
3670           bit returning functions
3671         * support/regression/tests/sfr16.c: enabled test on ds390
3672
3673 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3674
3675         * src/hc08/gen.c (asmopToBool, genIfx): fix for bug #1429722
3676         * src/hc08/gen.c (storeRegToAop): fix for bug #1439894
3677
3678 2006-05-11 Maarten Brock <sourceforge.brock AT dse.nl>
3679
3680         * sim/ucsim/sim.src/memcl.h: added get_decoder() to cl_address_space
3681         * sim/ucsim/sim.src/mem.cc: implemented cl_address_space::get_decoder,
3682           (cl_address_space constructor): removed expensive initialization,
3683           (cl_address_space::get_cell): extended for late initialization,
3684           (cl_address_space::*): use late initialization,
3685           (cl_address_decoder::activate): removed expensive initialization,
3686           This reduced regression test running time by 25%
3687
3688 2006-05-11 Bernhard Held <bernhard AT bernhardheld.de>
3689
3690         * packihx/,
3691         * configure.in,
3692         * configure,
3693         * sdcc.dsw,
3694         * Makefile.bcc,
3695         * Makefile.in,
3696         * support/packihx/Makefile.in,
3697         * support/packihx/clean.mk,
3698         * support/packihx/Makefile.bcc,
3699         * support/packihx/PackIhx.dsp: moved packihx to support/packihx
3700
3701 2006-05-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3702
3703         * src/SDCCval.c (valNot): fix for regression test failure
3704           of not.c on big endian hosts
3705
3706 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
3707
3708         * device/inlcude/mcs51/msc1210.h: new, added, thanks Philippe Latu
3709
3710 2006-05-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
3711
3712         * device/lib/mcs51/Makefile.in: changed string comparison operator
3713           to = for POSIX compliance; == is bash extension
3714
3715 2006-05-10 Maarten Brock <sourceforge.brock AT dse.nl>
3716
3717         * device/lib/hc08/_mulint.c: applied patch 1485428, thanks
3718           kosmonaut_pirx
3719
3720 2006-05-09 Vangelis Rokas <vrokas AT users.sourceforge.net>
3721
3722         * src/pic16/gen.c (pic16_freeAsmop): release any temp registers
3723         allocated by aopForSym thus fixing bug #1478657 about failed testfwk.c
3724         * src/pic16/main.c (_pic16_keywords): added 'sfr16' keyword,
3725         * src/pic16/ralloc.c (pic16_allocWithIdx): also a fix for bug exposed by
3726         bug report #1478657,
3727
3728 2006-05-05 Borut Razem <borut.razem AT siol.net>
3729
3730         * doc/Makefile.in: remove of WARNINGS and labels.pl immediately after
3731           making the html
3732
3733 2006-05-02 Borut Razem <borut.razem AT siol.net>
3734
3735         * doc/Makefile.in: removed *.ind dependency since there is no rule to
3736           create *.ind, which made make to fail if invoked with -j 2
3737
3738 2006-05-01 Maarten Brock <sourceforge.brock AT dse.nl>
3739
3740         * src/SDCCglue.c (emitRegularMap): partial fix for bug 1477149, thanks
3741           Hubert Sack for patch 1479782
3742
3743 2006-05-01 Vangelis Rokas <vrokas AT users.sourceforge.net>
3744
3745         * src/pic16/glue.c (pic16_printIvalStruct): fixed bug #1445929
3746
3747 2006-05-01 Raphael Neider <rneider AT web.de>
3748
3749         * src/pic/device.c (sanitise_processor_name): only remove p(ic) prefix,
3750           (create_pic): store only prefix-free device name,
3751           (init_pic): check for device names with "16" prefix,
3752           (list_valid_pics),
3753         * src/pic/device.h (struct PIC_device),
3754         * src/pic/main.c (_pic14_genAssemblerPreamble): adapted to single
3755             stored device name,
3756         * device/include/pic/pic12f{635,675,629,683}.h,
3757         * device/lib/pic/libdev/pic12f{635,675,629,683}.c: NEW device libraries
3758         * device/lib/pic/libdev/Makefile.in: allow pic12* devices,
3759         * device/include/pic/pic16f505.h,
3760         * device/lib/pic/libdev/pic16f505.c: removed
3761         * device/include/pic/pic14devices.txt: added support for pic12f
3762             devices, removed unsupported non 16-bit devices
3763             [above changes provided by patch from Zik Saleeba]
3764         * src/pic/*, src/pic16/*, device/include/pic16/*,
3765           device/lib/pic/**, device/lib/pic16/**: obfuscated email address
3766
3767 2006-05-01 Borut Razem <borut.razem AT siol.net>
3768
3769         * configure.in, configure, doc/Makefile.in:
3770           sync with nightly build makefile - latex, dvipdf and dvips
3771           not needed any more
3772
3773 2006-04-30 Bernhard Held <bernhard AT bernhardheld.de>
3774
3775         * support/scripts/sdcc.nsi: removed all Readmes and Makefiles
3776         in the library source
3777
3778 2006-04-30 Maarten Brock <sourceforge.brock AT dse.nl>
3779
3780         * support/regression/ports/hc08/spec.mk: fixed bug 1478892
3781
3782 2006-04-28 Raphael Neider <rneider AT web.de>
3783
3784         * src/pic16/pcode.c (pic16_newpCodeOpLit12),
3785         * src/pic16/gen.c (pic16_popGetLit12): NEW, create 12 bit literal,
3786           (pic16_loadFSR0): handle 12 bit literals correctly, fixes #1440527
3787         * src/pic16/pcode.h: added prototype for pic16_newpCodeOpLit12()
3788
3789 2006-04-28 Bernhard Held <bernhard AT bernhardheld.de>
3790
3791         * device/lib/pic/libdev/Makefile.in,
3792         * device/lib/hc08/Makefile.in,
3793         * device/lib/gbz80/Makefile.in,
3794         * device/lib/z80/Makefile.in,
3795         * device/lib/ds390/Makefile.in,
3796         * device/lib/ds400/Makefile.in: added srcdir to include search path,
3797         thanks to Borut for the bug report
3798         * configure.in,
3799         * configure: always create doc/Makefile independent from --enable-doc
3800         * Makefile.in: always install from directory doc independent from
3801         --enable-doc
3802         * device/lib/pic/Makefile.in: added libdev again, it was erroneously
3803         removed
3804         * device/lib/pic/libdev/Makefile.in: fixed VPATH build
3805         * doc/Makefile.in: install *.txt if present
3806         * device/include/Makefile.in (install): added installation of pic/*.inc
3807         and pic/*.txt files again, they were erroneously removed
3808
3809 2006-04-28 Raphael Neider <rneider AT web.de>
3810
3811         * src/pic/{gen.c,main.h,pcode.c},
3812         * src/pic16/{gen.c,pcode.c}: quietened compiler warnings
3813             concerning signedness with casts
3814
3815 2006-04-28 Raphael Neider <rneider AT web.de>
3816
3817         * src/pic/gen.c (genFunction): set global pic14_hasInterrupt on
3818             definition of an interrupt handler,
3819         * src/pic/glue.c (pic14_emitInterruptHandler): moved output of
3820             interrupt handler stuff from picglue() to separate routine,
3821           (picglue): enabled definition of intr handlers in files w/o main()
3822
3823 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
3824
3825         * support/librarian/sdcclib.c: moved include <limits.h> up to enable
3826           compilation with MSVC 2005 Express Edition (VC8)
3827
3828 2006-04-26 Bernhard Held <bernhard AT bernhardheld.de>
3829
3830         * device/lib/Makefile: fixed build of gbz80 lib
3831
3832 2006-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
3833
3834         * support/regression/tests/bug-460010.c,
3835         * support/regression/tests/bug-524691.c,
3836         * support/regression/tests/bug-716242.c: removed conditional defines
3837           that are already in testfwk.h
3838
3839 2006-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
3840
3841         * src/ds390/gen.c (AccAXRrl1, AccAXLrl1): changed to real rotate by 1,
3842           (AccAXRsh1): added, shift right by 1,
3843           (AccAXLsh, AccAXRsh, AccAXRshS): updated for AccAXRrl1, AccAXRsh1 and
3844            AccAXLrl1
3845         * support/regression/tests/rotate.c: use <stdint.h> and enabled ds390
3846
3847 2006-04-25 Bernhard Held <bernhard AT bernhardheld.de>
3848
3849         * src/SDCCast.c (decorateType): partial fix for RFE 1475769,
3850         remove cast to same type
3851         * src/SDCCast.c (decorateType): fix for RFE 1475742,
3852         optimize 'ifx (op == 0)' resp. 'ifx (op != 0)'
3853         * as/z80/Makefile,
3854         * link/z80/Makefile: removed, they have moved to
3855         Makefile.in files
3856         * configure,
3857         * configure.in: replaced duplicate message about ucsim by missing sdcpp
3858         * install-sh: fix bug #1204398 by setting umask 0022
3859         * device/lib/Makefile: separate build of z80 and gbz80 lib
3860
3861 2006-04-24 Bernhard Held <bernhard AT bernhardheld.de>
3862
3863         Enabled VPATH feature: changed nearly all Makefiles (149 files).
3864         See sdccman.lyx '2.4.10 VPATH feature' about how to use it.
3865
3866         One basic decision: e.g. src/clean.mk includes further files. In order
3867         to make this work there are two solutions:
3868         - rename another dozen clean.mk to clean_in.mk, add srcdir to them and
3869           run configure on them. This way they can use
3870           'include $(srcdir)/port-clean.mk'
3871         - always include clean.mk by the Makefile at the same level. To avoid
3872           that `make clean` tries to include and build Makefile.dep the
3873           MAKECMDGOALS are examined (see e.g. src/Makefile.in). This has been
3874           implemented, because now even `make uninstall` doesn't create
3875           Makefile.in. clean.mk could be eliminated by pasting it in
3876           Makefile.in.
3877
3878         * debugger/mcs51/Makefile.in: build own objects from library sources
3879         (SLIB, SDCC) in current directory
3880
3881         * configure, configure.in: renamed --disable-device-lib-build in
3882         --disable-device-lib; added --enable-doc, the required tools are
3883         searched by configure; added result message; the toolchain for the
3884         belonging ports are now only built, if the port is enabled.
3885
3886         * support/regression/*: all output is written in directory gen, because
3887         the fwk and ports directories don't livet in the build tree using vpath
3888
3889         * doc/sdccman.lyx: renamed --disable-device-lib-build to
3890         --disable-device-lib, added --enable-doc, added section VPATH
3891
3892         * sim/ucsim/configure.in,
3893         * sim/ucsim/configure.in: hc08 couldn't be disabled, now hc08 and
3894         z80 are enabled by default
3895
3896 2006-04-24 Raphael Neider <rneider AT web.de>
3897
3898         * src/pic/device.c (pic14_assignConfigWordValue): remember assignments
3899             to config word, "pic14_"-prefixed some extern functions
3900           (pic14_emitConfigWord): emit __config directive(s) if assignment to
3901             config word has been found
3902         * src/pic/device.h: added prototypes
3903         * src/pic/pcode.c: added "pic14_"-prefix where needed
3904         * src/pic/ralloc.c (IS_CONFIG_ADDRESS,pic14_assignRegisters): cosmetic
3905             fixup
3906         * src/pic/glue.c (pic14_constructAbsMap): handle assignments to config
3907             words,
3908           (pic14emitRegularMap): ignore config words,
3909           (pic14createInterruptVect): moved generating __config directives away
3910           (picglue): have __config directives emitted
3911
3912 2006-04-24 Borut Razem <borut.razem AT siol.net>
3913
3914         * doc/Makefile: sync with nightly build makefile
3915
3916 2006-04-24 Raphael Neider <rneider AT web.de>
3917
3918         * src/pic/pcoderegs.c (OptimizeRegUsage): do not optimize
3919             registers that have not been assigned proper liveranges,
3920             fixes #1469504 and #1474602,
3921           (pCodeRegOptimizeRegUsage): fixed typo in comment
3922
3923 2006-04-24 Borut Razem <borut.razem AT siol.net>
3924
3925         * device/examples/main8051.c: deleted - it was removed from CVS
3926           24.mar.2000 and after that modified 18.feb.2001, so it reappered
3927           after the transition to Subversion
3928         * src/SDCCalloc.h: deleted - it was removed  from CVS
3929           3.feb.2001 and after that modified 18.feb.2001, so it reappered
3930           after the transition to Subversion
3931         * sim/ucsim/cpu.gif, sim/ucsim/interrupt.gif, sim/ucsim/new.gif,
3932           sim/ucsim/serial1.gif, sim/ucsim/serial2.gif,
3933           sim/ucsim/term_cpuopt.gif, sim/ucsim/timers.gif, sim/ucsim/wins.gif,
3934           sim/ucsim/post.jpg, sim/ucsim/UCsim.jpg: corrected
3935
3936 2006-04-22 Maarten Brock <sourceforge.brock AT dse.nl>
3937
3938         * as/asx8051.dsp: added mcs51/strcmpi.h
3939         * as/hc08/as_hc08.dsp: added asm.h, m6808.h, strcmpi.h
3940         * as/hc08/aslink.h: updated lnksect prototype
3941         * as/hc08/asm.h,
3942         * as/mcs51/asm.h: added a_addr to struct area and s_org to struct sym
3943         * as/hc08/asmain.c,
3944         * as/mcs51/asmain.c (asmbl): init dot.s_org for S_ORG,
3945           (newdot): handle A_ABS
3946         * as/hc08/asout.c,
3947         * as/mcs51/asout.c (outarea): output address
3948         * as/hc08/lkaomf51.c,
3949         * as/mcs51/lkaomf51.c: disabled unused array UsageType
3950         * as/hc08/m08pst.c,
3951         * as/mcs51/i51pst.c,
3952         * as/z80/z80pst.c: "ABS" is not A_OVR
3953         * as/hc08/lkarea.c (newarea): read a_addr,
3954           (lnkarea): added codemap array, sort absolute areas to the front,
3955            combine all GSINITx/GSFINAL,
3956           (find_empty_space, allocate_space): new functions,
3957           (lnksect): return next address, handle absolute sections
3958         * as/mcs51/lkarea.c (newarea): read a_addr,
3959           lnksect2 prototype changed,
3960           (lnkarea2): define codemap unsigned, combine all GSINITx/GSFINAL,
3961           (find_empty_space, allocate_space): new, factored out of lnksect2,
3962           (lnksect2): return next address, handle absolute sections
3963         * as/hc08/lkhead.c,
3964         * as/mcs51/lkhead.c (newhead): head is absolute but not overlay
3965         * as/hc08/lklibr.c (addfile, fndsym),
3966         * as/mcs51/lklibr.c (addfile, buildlibraryindex, fndsym): prevent
3967           index out of range and detect both '\' and '/'
3968         * device/include/mcs51/c8051f200.h: added _XPAGE, removed bad comment
3969         * device/include/stdbool.h: removed SDCC_ds390 from check to pass
3970           regression tests (ds390 cannot return bool yet)
3971         * doc/sdccman.lyx: changed version number, document changed --no-peep,
3972           document critical interrupts on z80, document changed SDCC define
3973         * src/asm.c (_asxxxx_mapping): fixed .org directive,
3974           (_a390_mapping): added .org directive
3975         * src/hc08/gen.c (transferAopAop): made bytemask log to fix warning,
3976           (genMultOneByte): fixed warnings
3977         * src/hc08/hc08.dsp: lowered warning level to 2 to suppress pedantic
3978           ones
3979         * src/pic16/device.c: removed newReg prototype, removed BYTE_IN_LONG
3980         * src/pic16/gen.c (pic16_popGetLabel): made parameter key signed,
3981           (pic16_genLeftShiftLiteral, genRightShiftLiteral): fixed warnings
3982         * src/pic16/gen.h: changed prototype for pic16_popGetLabel
3983         * src/pic16/main.c: removed newReg prototype
3984         * src/pic16/pcode.c,
3985         * src/pic16/pcode.h (pic16_emitDB): changed parameter c to int to fix
3986           warnings
3987         * src/pic16/pic16.dsp: lowered warning level to 2 to suppress pedantic
3988           ones
3989         * src/pic16/ralloc.c
3990         * src/pic16/ralloc.h (newReg): changed type to int and size to unsigned
3991           to fix warnings
3992         * src/pic/pcode.c (allocInternalRegister): changed parameter optype
3993           from short to PIC_OPTYPE
3994         * src/pic/pic.dsp: lowered warning level to 2 to suppress pedantic ones
3995         * src/pic/ralloc.c (newReg, allocInternalRegister): changed parameter
3996           optype from short to PIC_OPTYPE
3997         * src/port.h: made int_size unsigned to fix warnings
3998         * src/SDCC.y: fixed warning on MSVC
3999         * src/SDCCicode.c (getArraySizePtr): return unsigned int
4000         * src/SDCCopt.c (convertToFcall): fixed warnings
4001         * src/SDCCsymt.h: removed double prototype for genSymName
4002         * src/xa51/ralloc.c (allocReg): made size unsigned int, type int and
4003           offset int to fix warnings
4004
4005 2006-04-22 Borut Razem <borut.razem AT siol.net>
4006
4007         * doc/sdccman.lyx, */Makefile, */Makefile.in:
4008           references to CVS replaced with Subversion
4009
4010 2006-04-21 Borut Razem <borut.razem AT siol.net>
4011
4012         * doc/sdccman.lyx, */Makefile, */Makefile.in:
4013           references to CVS replaced with Subversion
4014
4015 2006-04-19 Borut Razem <borut.razem AT siol.net>
4016
4017         * src/version.awk: adapted for svn
4018         * /asxxxx/asxhtml/*.gif: set property svn:mime-type to image/gif
4019           sim/ucsim/doc/*.gif: set property svn:mime-type to image/gif
4020           sim/ucsim/doc/*.jpg: set property svn:mime-type to image/jpeg
4021           /binutils-avr/etc/*.vi, *.jin: removed all properties
4022           support/scripts/sdcc.ico: set property svn:mime-type to image/x-icon
4023
4024 2006-04-19 Borut Razem <borut.razem AT siol.net>
4025
4026         * CVS to Subversion migration completed
4027
4028 2006-04-18 Borut Razem <borut.razem AT siol.net>
4029
4030         * support/scripts/sdcc.nsi: removed unexisting ${DEV_ROOT}\lib\pic\*.o,
4031           ${DEV_ROOT}\lib\src\pic\libdev\*.S, ${DEV_ROOT}\lib\src\pic\libdev\*.inc
4032
4033 2006-04-17 Borut Razem <borut.razem AT siol.net>
4034
4035         * device/include/Makefile.in: added pic/*.inc to the installation
4036
4037 2006-04-15 Bernhard Held <bernhard AT bernhardheld.de>
4038
4039         * support/regression/collate-results.py: fixed output in case of
4040         a valdiag error
4041         * support/regression/generate-cases.py: fixed splitting of pathnames
4042         with dots
4043         * as/hc08/lklibr.c (addfile),
4044         * as/mcs51/lklibr.c (addfile): fixed off-by-one bug
4045
4046 2006-04-11 Raphael Neider <rneider AT web.de>
4047
4048         * src/pic16/gen.c (getFreePtr, pic16_popRegFromString),
4049         * src/pic16/ralloc.c (pic16_allocregWithName): removed debug output
4050         * src/pic16/pcode.c (assignValnums): fixed #1460578
4051
4052 2006-04-11 Raphael Neider <rneider AT web.de>
4053
4054         * device/lib/pic/libdev/*.c,
4055         * device/include/pic/*.h: replaced sfr and data with __sfr and __data,
4056           fixes #1468739, enables compilation in --std-c99 mode
4057         * support/scripts/inc2h.pl: emit __sfr/__data instead of sfr/data
4058
4059 2006-04-11 Raphael Neider <rneider AT web.de>
4060
4061         * src/pic/device.c (find_device): removed debug output
4062           (list_valid_pics): enabled verbose listing of supported devices
4063         * device/include/stdbool.h: define bool as char for pic14/16 as well
4064
4065 2006-04-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4066
4067         * src/SDCC.y: allow using brackets here: "__interrupt (1) __using (1)"
4068
4069 2006-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
4070
4071         * .version: bumped version to 2.5.6
4072         * src/pic/ralloc.c (newReg): MSVC doesn't support __builtin_return_address
4073
4074 2006-04-06 Raphael Neider <rneider AT web.de>
4075
4076         * .version: bumped version to 2.5.6 (pic14 ABI changed)
4077         * src/SDCCmain.c: add -DSDCC_PROCESSOR=<id> for pic14 port
4078         * src/pic/glue.c (emitSymbolToFile,pic14_constructAbsMap,
4079           pic14emitRegularMap,pic14emitMaps): moved output for absolute symbols to
4080             pic14_constructAbsMap
4081           (pic14printPublics): declare absolute global symbols as global
4082           (pic14createInterruptVect),
4083         * src/pic/ralloc.c (IS_CONFIG_ADDRESS): support second config word,
4084           (newReg): assume new registers unused, use correct name in
4085             hashtable (reg->name instead of name), more debugLog output
4086         * src/pic/device.h (PIC_device): added fields for verbose output
4087         * src/pic/device.c: moved device definition to pic14devices.txt,
4088             added routines for runtime parsing of pic14devices.txt,
4089             added support for second config word
4090         * src/pic/main.c (_process_pragma): removed #pragma maxram,
4091           (_pic14_keywords): no longer accept "bit" and "sbit" keywords
4092           (_pic14_initPaths): add search paths with "pic" suffix (not "pic14")
4093           (_pic14_parseOptions): moved pCodeInitRegisters here
4094           (_pic14_do_link): add "pic$(ARCH).lib" to linker arguments
4095         * src/pic/pcode.c (AnalyzeBanking): bail out on unset processor,
4096           (pCodeInitRegisters): rewrapped comments, perpared new approach to
4097             handling the pseudo stack
4098         * device/lib/Makefile.in: ignore failures in objects-pic16,
4099         * device/lib/pic/{configure,configure.in,Makefile}: added libdev/
4100         * device/lib/pic/NEWS: document new dependency on picXXX.lib
4101         * device/lib/pic/Makefile.subdir,
4102         * device/lib/pic16/Makefile.subdir: improved clean rules
4103         * device/lib/pic/libdev/: NEW, pic14 device libraries
4104         * device/lib/pic/libsdcc/_gptr{get,put}{1,2,3,4}.S: use _X not X
4105         * device/lib/pic/libsdcc/macros.inc: use _X not X, declare default SFRs
4106         * device/include/Makefile.in: create subdir and install pic14 headers
4107         * device/include/pic/p16f_common.inc: removed unused declarations
4108         * device/include/pic/pic16*.h: added header files for 100+ 14 bit
4109             PICs from inc2h.pl v1.6,
4110             replaced BIT_AT macros with struct declarations
4111         * device/include/pic/pic14devices.txt: definition of supported devices,
4112             all above improvements contributed by Zik Saleeba, thanks
4113         * support/scripts/inc2h.pl: removed BIT_AT, replaced with structs
4114         * support/scripts/sdcc.nsi: also install pic14 device libraries and
4115             headers
4116
4117 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
4118
4119         * device/include/mcs51/c8051f410.h: added interrupt numbers,
4120         * device/include/mcs51/c8051f200.h: old SiLabs mcu completes the list,
4121           thanks to Charles Olds
4122
4123 2006-04-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4124
4125         * debugger/mcs51/cmd.c (infoRegisters): show return address on stack
4126
4127 2006-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
4128
4129         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug 1464657
4130         * src/mcs51/gen.c (genJumpTab): fixed bug in medium model
4131         * support/regression/bug1464657.c: added, new test
4132
4133 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
4134
4135         * src/SDCCmain.c (preProcess): implemented RFE 1449908, define SDCC as the
4136           version number
4137
4138 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
4139
4140         * src/SDCCpeeph.c (initPeepHole): implemented RFE 1460196, when both
4141           --no-peep and --peep-file <file> are used don't use default rules but
4142           do use the <file>
4143
4144 2006-04-05 Maarten Brock <sourceforge.brock AT dse.nl>
4145
4146         * src/mcs51/gen.c (genCall): fixed bug 1457608
4147
4148 2006-03-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4149
4150         * doc/sdccman.lyx: reverted to version 1.129 of december as my latest
4151         changes seem to cause (trigger?) problems with the build system.
4152
4153 2006-03-29 Maarten Brock <sourceforge.brock AT dse.nl>
4154
4155         * src/SDCCpeeph.c (operandsLiteral): new, added,
4156           (callFuncByName): inserted operandsLiteral
4157         * src/mcs51/peeph.def: reenabled 132.e, added extra check to 132.x
4158
4159 2006-03-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4160
4161         * doc/sdccman.lyx: added paragraph "Use of SDCC in Education"
4162         * src/mcs51/peeph.def: disabled rule 132.e fixing bug #1453093
4163
4164 2006-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
4165
4166         * src/z80/gen.c (genFunction, genEndFunction): fixed bug 1160666,
4167           implemented patch 1120823 Thanks to Willy De la Court (normal
4168           interrupts need an interrupt number now if they are made critical),
4169           and enabled nesting of critical functions though not for gbz80
4170           (genCritical, genEndCritical): added functions
4171           (genZ80Code): added cases for CRITICAL and ENDCRITICAL
4172         * src/z80/mappings.i: added "ei" to all mappings
4173
4174 2006-03-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4175
4176         * sim/ucsim/cmd.src/newcmdcl.h: applied patch fixing GCC 4.1 build
4177         submitted by the Debian SDCC maintainer Aurelien Jarno:
4178         "Credits goes to Martin Michlmayr, who rebuilt the whole Debian
4179         archive with gcc 4.1 on mips and wrote the patch"
4180
4181 2006-03-16 Raphael Neider <rneider AT web.de>
4182
4183         * src/pic16/genarith.c (genAddLit): simplified and fixed case where
4184           the left operand is shorter than the result (c* = lit-c* + int),
4185           fixes bug #1450796
4186         * src/pic16/gen.c (genRightShift): check IS_SYMOP before accessing
4187           OP_SYMBOL
4188
4189 2006-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
4190
4191         * src/.version: increased version number to 2.5.5
4192         * src/SDCCmain.c (linkEdit): do not test for PIC16 target since, PIC16
4193         linking is done manually in pic16 port's _linkEdit,
4194         * src/SDCCsymt.c (compStructSize): for target PIC16 and shell variable
4195         PIC16_PACKED_BITFIELDS, compact bitfield structures as much as possible,
4196         * src/pic16/gen.c (aopForSym): when direct register name is WREG then
4197         allocate asmop as AOP_ACC,
4198         (aopForRemat): added parameter 'bool result' in function declaration,
4199         (pic16_aopGet): return AOP_ACC when accessing WREG,
4200         (pic16_popGetTempReg): minor modification,
4201         (pic16_popRegFromIdx): first try with 'pic16_regWithIdx' then with
4202         'pic16_allocWithIdx',
4203         (genPcall): removed ftype, usage of OP_SYM_TYPE asserted error when
4204         calling function in absolute addresses,
4205         (genAssign): take into account AOP_ACC asmop,
4206         * src/pic16/pcode.c (pic16_newpCodeOpReg): minor modifications,
4207         * src/pic16/pcoderegs.c: some debug functions and lines added,
4208         * src/pic16/ralloc.c (decodeRegType): added but commented out,
4209         * (pic16_typeRegWithIdx): search 'pic16_dynInternalRegs' for given
4210         register too,
4211         * (pic16_findFreeReg, pic16_findFreeRegNext): allocate new register via
4212         call to allocReg, not by manually allocating a new one,
4213         (pic16_assignRegisters): now before going through the register
4214         allocating functions mark all registers as free. This eliminates some
4215         side effects resulting from peephole parser done earlier in the backbone
4216
4217 2006-03-13 Maarten Brock <sourceforge.brock AT dse.nl>
4218
4219         * src/SDCCicode.c (geniCodeLogic),
4220         * src/SDCCast.c (decorateType): applied patch by Bernhard for rfe 1422617
4221
4222 2006-03-10 Maarten Brock <sourceforge.brock AT dse.nl>
4223
4224         * src/mcs51/gen.c (sameReg): new, checks if two aop regs are the same,
4225           (genSend): bugfix, do not allocate and free twice,
4226           (shiftRLong): handle partially overlapping aops
4227         * support/regression/tests/bitopcse.c: fixed warning redefined idata
4228
4229 2006-03-08 Borut Razem <borut.razem AT siol.net>
4230
4231         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata
4232           for pic16
4233
4234 2006-03-08 Maarten Brock <sourceforge.brock AT dse.nl>
4235
4236         * support/regression/tests/bug1409955.c: new, added
4237         * src/mcs51/gen.h: changed asmop.freed:1 to asmop.allocated for tracking
4238         * src/mcs51/gen.c (newAsmop): set asmop.allocated to 1,
4239           (aopForSym, aopOp): increment asmop.allocated if reused,
4240           (freeAsmop): decrement asmop.allocated and check for zero instead of
4241           using asmop.freed,
4242           (freeForBranchAsmop): use asmop.allocated instead of asmop.freed,
4243           (genNot, genCpl, genUminus, genMinus, genMult, genDiv, genMod, genCmpGt,
4244            genCmpLt, genAndOp, genOrOp, genAnd, genOr, genXor, genRRC, genRLC,
4245            genGetHbit, genGetAbit, genGetByte, genGetWord, genSwap,
4246            genLeftShiftLiteral, genLeftShift, genRightShiftLiteral,
4247            genSignedRightShift, genRightShift, genDataPointerGet,
4248            genPagedPointerGet, genFarPointerGet, genCodePointerGet,
4249            genGenPointerGet, genDataPointerSet, genAssign, genCast): free asmop's
4250             in reverse order from allocation,
4251           (genPlus, genCmpEq): free asmop's in reverse order from allocation and
4252             added swappedLR to keep track
4253         * support/regression/fwk/include/testfwk.h: added defines for xdata, idata,
4254           pdata & code for GCC, z80, gbz80 & hc08
4255         * support/regression/tests/zeropad.c: moved defines to testfwk.h
4256
4257 2006-03-08 Raphael Neider <rneider AT web.de>
4258
4259         * src/pic16/main.c (_hasNativeMulFor): fixed bug #1444425
4260
4261 2006-03-07 Maarten Brock <sourceforge.brock AT dse.nl>
4262
4263         * device/include/mcs51/c8051f410.h: new SiLabs mcu
4264         * src/ds390/peeph.def: disabled 186.d and 227.a as fix for #1434401
4265         * support/regression/tests/array.c: added parenthesis, made arrays unsigned
4266
4267 2006-03-06 Borut Razem <borut.razem AT siol.net>
4268
4269         * support/regression/ports/pic16/spec.mk: link with libm18f.lib,
4270           made the linker quiet
4271
4272 2006-03-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
4273
4274         * src/pic16/gen.c (genPcall): fixed bug #1443644
4275         * src/pic16/device.h (struct pic16_options_t): added 'int CATregs' flag
4276         which dumps before the function entry point a data byte which represents
4277         the number of the local variables used by the specified function, added
4278         'xinst' for initial support for Extended Instruction Support,
4279         * src/pic16/gen.c (aopForSym, pic16_aopGet): beautifications,
4280         (pic16_testStackOverflow): do not prefix GSTACK_TEST_NAME with
4281         port->fun_prefix anymore (may change later),
4282         (genFunction, genEndFunction): do not store/restore local registers for
4283         _main (this should take care the --main-return command line option in
4284         the future),
4285         (genOr): removed some legacy pic-port instructions,
4286         * src/pic16/genarith.c (genAddLit): re-enabled old code because
4287         performing operations with SFR's causes data to be written more than
4288         once to each SFR. Perhaps SFRs should be handled in special cases...
4289         * src/pic16/glue.c: macros BIG_ENDIAN and BYTE_IN_LONG are moved to
4290         pcode.h
4291         * src/pic16/main.c (_process_pragma): stack bound checking did not take
4292         into account for stack starting position,
4293         (struct OPTIONS pic16_optionsTable): added command line argument
4294         --extended or -y for Extended Instruction Support,
4295         * src/pic16/ralloc.c (pic16_decodeOp): added case for FUNCTION,
4296         (deassignLRs): *** perhaps the most important change, old 'for' code
4297         (commented out for reference), didn't account for some registers which
4298         were left marked 'not free' after a pointer operation. The change
4299         reduces register usage a lot in some cases
4300
4301 2006-03-04 Borut Razem <borut.razem AT siol.net>
4302
4303         * support/regression/ports/hc08/spec.mk: remove *.asm in traget
4304           _clean
4305         * support/regression/tests/bug-524697.c: decreased array size for
4306           mcs51 to fit into the internal RAM
4307         * support/regression/Makefile.in: a little bit more verbose
4308
4309 2006-03-03 Borut Razem <borut.razem AT siol.net>
4310
4311         * support/regression/fwk/lib/testfwk.c,
4312           support/regression/fwk/include/testfwk.h: introduced function
4313           _prints(), nonrecursive _printn(), call _initEmu() from main()
4314         * support/regression/ports/gbz80/support.asm,
4315           support/regression/ports/ucz80/support.asm,
4316           support/regression/ports/z80/support.asm,
4317           support/regression/ports/ds390/support.c,
4318           support/regression/ports/hc08/support.c,
4319           support/regression/ports/host/support.c,
4320           support/regression/ports/mcs51/support.c,
4321           support/regression/ports/xa51/support.c: added empty _initEmu()
4322           function
4323         * support/regression/ports/pic16/gpsim.cmd,
4324           support/regression/ports/pic16/spec.mk,
4325           support/regression/ports/pic16/support.c,
4326           support/regression/Makefile.in: added pic16 regression test
4327
4328 2006-03-01 Raphael Neider <rneider AT web.de>
4329
4330         * src/pic16/gen.c (genPcall,pic16_derefPtr,genGenPointerGet,
4331           genConstPointerGet): use safe way of generating MOVFF to cover
4332             literals as well as registers, fixes bug #1440527
4333         * src/pic16/glue.c (pic16_printIvalBitFields): prevent NULL pointer
4334             dereference
4335           (pic16_printIvalUnion,pic16_isUnion): NEW, handle initialized unions
4336             more correctly, fixes bug #1232186
4337           (pic16_printIval): use pic16_printIvalUnion() for initialized unions
4338         * src/pic16/main.c (_pic16_linkEdit): reorder linker arguments to make
4339             gplink guess the correct processor in more cases, applied patch
4340             from Till Riedel attached to and fixing bug #1436552
4341
4342 2006-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4343
4344         * support/regression/tests/array.c: added, contains check for #1434401
4345         * src/mcs51/peeph.def: disabled 186.d as temporary fix for #1434401
4346
4347 2006-02-16 Maarten Brock <sourceforge.brock AT dse.nl>
4348
4349         * device/include/mcs51/at89s8253.h: new, thanks to Krzysztof Polomka
4350         * device/include/mcs51/at89S8252.h: fixed, thanks to Krzysztof Polomka
4351         * device/include/mcs51/c8051f326.h,
4352         * device/include/mcs51/c8051f340.h: new SiLabs mcu's
4353         * device/include/mcs51/c8051f000.h,
4354         * device/include/mcs51/c8051f018.h,
4355         * device/include/mcs51/c8051f020.h: used () with __at, renamed IDLE,STOP to
4356           PCON_IDLE,PCON_STOP and added sfr16 definitions
4357
4358 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
4359
4360         * src/mcs51/gen.c (genPlus, genMinus, genMult, genGetAbit, genGetByte,
4361           genGetWord): fixed bug 1409955
4362
4363 2006-02-14 Maarten Brock <sourceforge.brock AT dse.nl>
4364
4365         * device/include/hc08/mc68hc908gp32.h,
4366         * device/include/hc08/mc68hc908jb8.h: removed AWUL, added PTA6 & PTA7
4367
4368 2006-02-13 Maarten Brock <sourceforge.brock AT dse.nl>
4369
4370         * src/SDCCast.c (constExprValue): return NULL if not a value
4371         * src/SDCCglue.c (printIvalArray): fixed bug 1225568
4372         * src/hc08/gen.c(genUnpackBits, genUnpackBitsImmed): fixed bug 1019480
4373         * support/regression/tests/bitfields.c: enabled signed bitfield for all
4374
4375 2006-02-13 Borut Razem <borut.razem AT siol.net>
4376
4377         * src/regression/ptrarg.c: added, fails due to bug #1430967
4378         * src/regression/Makefile: ptrarg.c added, ...
4379
4380 2006-02-12 Maarten Brock <sourceforge.brock AT dse.nl>
4381
4382         * src/z80/gen.c (genUnpackBits): fixed bug 1019480
4383         * support/regression/tests/bitfields.c: enabled signed bitfield for z80
4384
4385 2006-02-11 Borut Razem <borut.razem AT siol.net>
4386
4387         * src/SDCCmain.c: Added "sdcc: Calling linker..." if --verbose,
4388           print "Processor: xxx" message to stdout only if --verbose
4389
4390 2006-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
4391
4392         * src/SDCCglue.c (printIvalStruct): fixed bug 1426356 union initializer
4393         * support/regression/tests/bug1426356.c: added
4394         * support/regression/tests/bitfields.c: removed 2 tests
4395
4396 2006-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
4397
4398         * device/include/mcs51/at89c51snd1c.h: updated comments, see patch 1428901
4399         * device/include/mcs51/c8051f330.h,
4400         * device/include/mcs51/c8051f350.h: used () with __at, renamed IDLE,STOP to
4401           PCON_IDLE,PCON_STOP and added sfr16 definitions
4402         * device/lib/_divsint.c,
4403         * device/lib/_divuint.c,
4404         * device/lib/_divulong.c,
4405         * device/lib/_divulong.c: renamed a,b to x,y to avoid confusion, fixed
4406           register bank bug for small stackauto
4407
4408 2006-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
4409
4410         * support/regression/fwk/lib/timeout.c: include <stdlib.h> for exit()
4411
4412 2006-02-08 Maarten Brock <sourceforge.brock AT dse.nl>
4413
4414         * support/regression/ports/mcs51-xstack-auto/spec.mk: forgot -I(...)/mcs51
4415         * all.dsp: corrected several bin paths
4416         * device/include/mcs51/c8051f120.h,
4417         * device/include/mcs51/c8051f300.h,
4418         * device/include/mcs51/c8051f310.h: used () with __at and renamed IDLE,STOP
4419           to PCON_IDLE,PCON_STOP
4420         * device/include/mcs51/c8051f320.h: see above, also added sfr16 definitions
4421         * device/lib/printf_large.c (output_float): fixed bug 1388703
4422         * support/regression/tests/bug1057979.c: added test for bug 1388703
4423
4424 2006-02-08 Raphael Neider <rneider AT web.de>
4425
4426         * src/pic/pcode.c (pciTRIS): fixed typo,
4427           (BuildFlow,LinkFlow_pCode): added (disabled) debug output,
4428           (LinkFlow): fixed handling of flows that end in a call,
4429           (ReuseReg): perform safety check earlier
4430         * src/pic/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed
4431             to work with flows at the beginning of a pBlock,
4432             fixes #1426557 (Symbol not previously defined),
4433           (pic14_ReMapLiveRanges): NEW, destroy and rebuild register
4434             usage information
4435           (RemoveUnusedRegisters): update register usage info
4436         * src/pic/ralloc.c (newReg): prevent duplicate registers from being
4437             created, reuse existing ones instead
4438         * src/pic/gen.c (genPcall): fixed #1424719
4439
4440 2006-02-07 Bernhard Held <bernhard AT bernhardheld.de>
4441
4442         * link/z80/lkmain.c,
4443         * link/z80/lklex.c,
4444         * link/z80/lkdata.c,
4445         * link/z80/aslink.h: fixed build on current cygwin:
4446         replaced getline() by lk_getline()
4447
4448 2006-02-01 Borut Razem <borut.razem AT siol.net>
4449
4450         * src/regression/add.c, src/regression/add2.c, src/regression/add3.c,
4451           src/regression/add4.c, src/regression/and1.c, src/regression/and2.c,
4452           src/regression/arrays.c, src/regression/b.c, src/regression/bank1.c,
4453           src/regression/bool1.c, src/regression/bool2.c,
4454           src/regression/bool3.c, src/regression/call1.c,
4455           src/regression/compare.c, src/regression/compare10.c,
4456           src/regression/compare2.c, src/regression/compare3.c,
4457           src/regression/compare4.c, src/regression/compare5.c,
4458           src/regression/compare6.c, src/regression/compare7.c,
4459           src/regression/compare8.c, src/regression/compare9.c,
4460           src/regression/configword.c, src/regression/for.c,
4461           src/regression/inline.c, src/regression/mult1.c,
4462           src/regression/nestfor.c, src/regression/or1.c,
4463           src/regression/pointer1.c, src/regression/ptrfunc.c,
4464           src/regression/rotate1.c, src/regression/rotate2.c,
4465           src/regression/rotate3.c, src/regression/rotate4.c,
4466           src/regression/rotate5.c, src/regression/rotate6.c,
4467           src/regression/rotate7.c, src/regression/string1.c,
4468           src/regression/struct1.c, src/regression/sub.c,
4469           src/regression/sub2.c, src/regression/switch1.c,
4470           src/regression/while.c, src/regression/xor.c,
4471           src/regression/create_stc, src/regression/simulate,
4472           src/regression/rt.sh, src/regression/Makefile: reenabled Scott's PIC14
4473           regression tests
4474         * src/regression/gpsim_assert.h: added
4475
4476 2006-01-28 Bernhard Held <bernhard AT bernhardheld.de>
4477
4478         * src/ds390/gen.c (unsaveRegisters): fixed literal function pointer
4479         ((void (code *) (void)) 0) ();
4480         * as/hc08/aslex.c,
4481         * as/hc08/aslink.h,
4482         * as/hc08/asm.h,
4483         * as/hc08/asmain.c,
4484         * as/hc08/lkdata.c,
4485         * as/hc08/lklex.c,
4486         * as/hc08/lkmain.c,
4487         * as/mcs51/aslex.c,
4488         * as/mcs51/aslink.h,
4489         * as/mcs51/asm.h,
4490         * as/mcs51/asmain.c,
4491         * as/mcs51/lkdata.c,
4492         * as/mcs51/lklex.c,
4493         * as/mcs51/lkmain.c,
4494         * as/z80/aslex.c,
4495         * as/z80/asm.h,
4496         * as/z80/asmain.c: fixed build on current cygwin:
4497         replaced getline() by as_getline()
4498
4499 2006-01-27 Bernhard Held <bernhard AT bernhardheld.de>
4500
4501         * src/SDCC.y: fixed bug #716242, exchanged pointer and function
4502         declarator in the symbol chain
4503         * src/SDCCsymt.h,
4504         * src/SDCCsymt.c (processFuncPtrArgs): added, removes "(void)"
4505         parameter list for function pointers
4506         * src/SDCCast.c (decorateType): added call of processFuncPtrArgs()
4507         * support/regression/tests/bug-716242.c: added
4508
4509 2006-01-20 Bernhard Held <bernhard AT bernhardheld.de>
4510
4511         * src/SDCCicode.c (geniCodeAdd, geniCodeArray): use char for array
4512         offset if possible
4513         * src/SDCCast.c (getLeftResultType): 255 fits in char, not 256
4514
4515 2006-01-18 Bernhard Held <bernhard AT bernhardheld.de>
4516
4517         * src/SDCCast.c (backPatchLabels): fixed bug #1408066: made it
4518         inifinitely recurseable, added static
4519         * support/regression/tests/bug-1408066.c: added
4520
4521 2006-01-17 Bernhard Held <bernhard AT bernhardheld.de>
4522
4523         * src/SDCCicode.h,
4524         * src/SDCCicode.c (newiTempPreheaderLabel, newiTempLoopHeaderLabel):
4525         renamed, added possibility to create "postLoopLbl"-labels
4526         * src/SDCCBBlock.c (iCodeBreakDown): renamed newiTempPreheaderLabel to
4527         newiTempLoopHeaderLabel
4528         * src/SDCCloop.c (newInduction, newRegion, backEdges, insertIntoLoop,
4529         isNotInBlocks, addToExitsMarkDepth, createLoop, dominatedBy,
4530         addDefInExprs, assignmentsToSym, isOperandInvariant, pointerAssigned,
4531         hasNonPtrUse, loopInvariants, addressTaken, findInduction,
4532         findDefInRegion, mergeRegions, ifMerged, mergeInnerLoops): made static,
4533         (pinduction, pregion, hasIncomingDefs, findLoopEndSeq): disabled,
4534         (basicInduction): fixed bug #136564, made static,
4535         (loopInduction): changed parameter of basicInduction, made static,
4536         (addPostLoopBlock): added
4537         * src/SDCCloop.h: removed backEdges, pregion, pinduction,
4538         loopOptimizations, addressTaken, findDefInRegion, hasIncomingDefs,
4539         findLoopEndSeq
4540         * support/regression/tests/bug-136564.c: added
4541         * support/regression/ports/mcs51-xstack-auto/spec.mk: added
4542         --std-sdcc99 to LIBSDCCFLAGS
4543
4544 2006-01-16 Bernhard Held <bernhard AT bernhardheld.de>
4545
4546         * src/SDCCicode.c (geniCodeIfx): fix bug 1406131: always false
4547         while loop
4548         * support/regression/tests/bug-1406131.c: added
4549
4550 2005-12-31 Bernhard Held <bernhard AT bernhardheld.de>
4551
4552         * src/SDCCast.c (decorateType): fix promotion of unary minus
4553         * src/SDCCsymt.c (computeType): beautified
4554         * src/SDCCval.c (cheapestVal): beautified, old non-Ansi version removed,
4555         (valUnaryPM, valComplement): fix sign and promotion,
4556         (valNot): ANSI: result type is int (SDCC: unsigned char)
4557         * support/regression/tests/uminus.c: speedup by removing superflous
4558         test case 'int'
4559         * support/regression/tests/onebyte.c: added promotion and signedness
4560         tests for unary minus
4561         * support/regressions/tests/bug-477927.c: disable warning about
4562         uninitialized variables
4563         * support/regression/tests/not.c: added
4564
4565 2005-12-28 Bernhard Held <bernhard AT bernhardheld.de>
4566
4567         * device/lib/Makefile.in: added --std-sdcc99 to CFLAGS
4568         * src/mcs51/gen.c (gen51Code): show final register usage after
4569         fillGaps in asm with --i-code-in-asm
4570         * src/SDCClrange.c (sequenceiCode, setLiveFrom, setLiveTo,
4571         markLiveRanges, markAlive, findNextUseSym, findNextUse, unvisitBlocks,
4572         incUsed, rliveClear, adjustIChain): made static,
4573         (setFromRange): excluded because it's unused,
4574         (findPrevUseSym, markWholeLoop): added,
4575         (findPrevUse): rewritten; fixes bug 895992; now a complete search
4576         through all branches of predecessors enables sdcc to emit the warning
4577         W_LOCAL_NOINIT, marking of outermost loop was incomplete,
4578         (rlivePoint): made static, added parameter emitWarnings which is only
4579         true during the first run out of two,
4580         (findRecursiveSucc, findRecursivePred): removed,
4581         (computeLiveRanges): made static, added parameter emitWarnings,
4582         (dumpIcRlive): added for debugging only
4583         * src/SDCClrange.h: added boolean parameter to computeLiveRanges(),
4584         removed prototype of setFromRange()
4585         * src/SDCCopt.c (eBBlockFromiCode): added new parameter emitWarnings
4586         in call of computeLiveRanges()
4587         * support/regression/tests/bug-895992.c: added
4588         * support/regression/tests/bug-971834.c: added
4589         * support/valdiag/tests/bug-895992.c: added
4590         * support/valdiag/tests/bug-971834.c: added
4591
4592 2005-12-18 Raphael Neider <rneider AT web.de>
4593
4594         * src/pic16/gen.c: added IS_DIRECT macro for "direct" operands,
4595           (genUnpackBits): improved code for direct operands,
4596           (genPackBits): improved code for literal assignment to bitfields
4597             and for direct destination operands (no FSR indirection),
4598             prevented redundant AND, fixes #1362800,
4599           (AccLsh): added parameter to disable masking of the result
4600         * src/pic16/pcode.c (pic16_safepCodeUnlink): fixed to work with
4601           skip instructions with side-effects (like incfsz),
4602           (pic16_pCodeIsAlive): suppress verbose output unless pcode_verbose,
4603         * src/pic16/pcoderegs.c (RemoveRegsFromSet): removed annoying warning
4604         * device/lib/pic16/Makefile.common.in: added --asm=@GPASM@ to CC,
4605           fixes #1375263
4606
4607 2005-12-11 Bernhard Held <bernhard AT bernhardheld.de>
4608
4609         * src/SDCCicode.c (geniCodeAssign): fixed bug 11369874, don't use
4610         volatile variables as spill location
4611
4612 2005-12-10 Bernhard Held <bernhard AT bernhardheld.de>
4613
4614         * src/SDCCcse.c (findCheaperOp): fixed bug 1376320, copy signedness to
4615         replacing literals
4616         * support/regression/tests/bug-1376320.c: added
4617
4618 2005-12-08 Raphael Neider <rneider AT web.de>
4619
4620         * src/pic/device.c: renamed is_shared to pic14_is_shared
4621         * src/pic/gen.c (genIfx): re-enabled handling of sbits
4622         * src/pic/glue.c (emitSymbolToFile): added workaround for sbits,
4623           (is_valid_identifier): added for above workaround
4624
4625 2005-12-07 Maarten Brock <sourceforge.brock AT dse.nl>
4626
4627         * device/lib/Makefile.in: fixed to enable port-specific-objects
4628         * device/lib/ds390/i2c390.c (BitOutI2C): optimized by making bout unsigned
4629           char, thanks Hubert Sack
4630         * doc/sdccman.lyx: documented --xstack-loc,
4631           elaborated a bit more on interrupts and pitfalls,
4632           removed "setjmp/longjmp unsupported",
4633           documented some unsupported C99 features
4634         * src/SDCCmain.c (linkEdit): adapted default lib path for --stack-auto
4635         * src/SDCCpeeph.c (readRules): inserted patch 1367130 for finding missing
4636           if, thanks Hubert Sack
4637         * src/mcs51/gen.c (genEndFunction): enabled "pop psw" for regbank 0 isr
4638         * support/regression/Makefile.in: test-mcs51-stack-auto no longer needs to
4639           make make_library
4640         * support/regression/get_ticks.py: new, get cpu cycles and code size, so
4641           regression tests can report resource usage (rfe 700441)
4642         * support/regression/collate-results.py: report resource usage
4643         * support/regression/ports/ds390/spec.mk,
4644         * support/regression/ports/hc08/spec.mk,
4645         * support/regression/ports/mcs51/spec.mk,
4646         * support/regression/ports/ucz80/spec.mk: run sim output through get_ticks
4647         * support/regression/ports/ds390/uCsim.cmd,
4648         * support/regression/ports/hc08/uCsim.cmd,
4649         * support/regression/ports/mcs51/uCsim.cmd,
4650         * support/regression/ports/ucz80/uCsim.cmd: inserted "state" to report time
4651         * support/regression/ports/mcs51-stack-auto/spec.mk: no need to build the
4652           library, use the default one
4653         * support/regression/ports/mcs51-xstack-auto/spec.mk: inserted rules for
4654           building the library
4655
4656 2005-12-06 Maarten Brock <sourceforge.brock AT dse.nl>
4657
4658         * config.dsp: added dependency on .version and configure_vc.awk
4659         * device/include/setjmp.h: updated for --stack-auto and --xstack
4660         * device/include/mcs51/at89c51snd1c.h: corrected line endings
4661         * device/include/mcs51/XC866.h: added, thanks Llewellyn van Zyl
4662         * device/lib/_setjmp.c: updated for --stack-auto and --xstack
4663         * device/lib/libsdcc.lib: added _setjmp
4664         * src/SDCCast.c (createIvalCharPtr): fixed warnings,
4665           (decorateType): fixed bug 1372851,
4666           (optimizeGetHbit): fixed warning
4667         * src/SDCCglue.c (printIvalChar, printIvalArray): adapted for flexible
4668           array initialisation
4669         * support/regression/tests/bug1057979.c: added test for bug 1358192
4670         * support/regression/tests/setjmp.c: added, test for setjmp/longjmp
4671
4672 2005-12-03 Borut Razem <borut.razem AT siol.net>
4673
4674         * support/scripts/sdcc.nsi: added /SOLID option to "SetCompressor lzma"
4675           command since the NSIS was upgraded to version 2.11 on CF x86-linux2
4676
4677 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
4678
4679         * src/SDCCast.c (createIvalStruct, createIvalArray, createIvalPtr,
4680         createIval): implement symbol independant "flexible array member",
4681         (createIvalCharPtr): implemented flexible array initialisation with a
4682         string
4683         * src/SDCCsymt.c (copyStruct): removed,
4684         (getSize): fixed misleading comment,
4685         (getAllocSize): removed, the additional allocation size is now in
4686         sym->flexArrayLength,
4687         (checkStructFlexArray): new, syntax checks for flexible array members,
4688         (compStructSize): added syntax checks for "flexible array members"
4689         (copyStruct): removed,
4690         (copyLinkChain): removed inefficient fix for bug 770487
4691         * src/SDCCglue.c (emitRegularMap): getAllocSize has been removed
4692         * src/SDCCsymt.h: added structdef.b_flexArrayMember and
4693         symbol->flexArrayLength
4694         * src/SDCCerr.c,
4695         * src/SDCCerr.h: added W_INVALID_FLEXARRAY, W_C89_NO_FLEXARRAY,
4696         E_FLEXARRAY_NOTATEND and E_FLEXARRAY_INEMPTYSTRCT
4697         * support/regression/tests/structflexarray.c: added
4698         * support/valdiag/tests/structflexiblearray.c: added
4699
4700 2005-11-29 Bernhard Held <bernhard AT bernhardheld.de>
4701
4702         * src/SDCCast.c (decorateType): fixed bug 1368489
4703         * support/Util/SDCCerr.c,
4704         * support/Util/SDCCerr.h: added warning W_CMP_SU_CHAR
4705
4706 2005-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4707
4708         * device/include/mcs51/at89c51snd1c.h: added file submitted by
4709           Weston T. Schmidt <schmidtw AT users.sourceforge.net>, patch #1368001
4710
4711 2005-11-27 Borut Razem <borut.razem AT siol.net>
4712
4713         * support/cpp2/cppinit.c, support/cpp2/cpplib.h, support/cpp2/mkdeps.c,
4714           support/cpp2/mkdeps.h: added command line option
4715           -obj-ext=<extension> to SDCPP to define object file externion, used
4716           for generation of make dependencies (-M)
4717         * src/SDCCmain.c: pass -obj-ext=<extension> to SDCPP
4718
4719 2005-11-26 Borut Razem <borut.razem AT siol.net>
4720
4721         * support/scripts/sdcc.nsi: added small-stack-auto libraries,
4722           added missing device/lib/mcs51/crt*.asm, pic and pic16 sources,
4723           added pic and pic16 libraries
4724
4725 2005-11-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4726
4727         * device/include/float.h: Corrected typo in prototype of __fsgt
4728
4729 2005-11-25 Borut Razem <borut.razem AT siol.net>
4730
4731         * sdcc/device/lib/Makefile.in, sdcc/device/lib/incl.mk:
4732           added creation of model-mcs51-stack-auto libraries
4733
4734 2005-11-24 Bernhard Held <bernhard AT bernhardheld.de>
4735
4736         * src/SDCCsymt.c (copyLinkChain): fixed bug 770487, copy structdef
4737         and fields-list too
4738         * src/SDCCast.c (createIvalArray): removed obsolete comment
4739
4740 2005-11-24 Borut Razem <borut.razem AT siol.net>
4741
4742         * sdcc/device/lib/Makefile.in: remove all unnecessary files, 2nd try...,
4743           added missing device/lib/mcs51/crt*.asm sources
4744
4745 2005-11-23 Bernhard Held <bernhard AT bernhardheld.de>
4746
4747         * src/SDCCast.c (createIvalCharPtr): fixed bug 1348271
4748
4749 2005-11-22 Maarten Brock <sourceforge.brock AT dse.nl>
4750
4751         * device/lib/_fs2schar.c,
4752         * device/lib/_fs2sint.c,
4753         * device/lib/_fs2slong.c: optimized inline asm
4754
4755 2005-11-21 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4756
4757         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
4758           Better handling of floats between -1.0 and 0.0.
4759
4760 2005-11-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
4761
4762         * src/mcs51/peeph.def: added missing "if"s as noted by Hubert Sack.
4763           (the missing "if"s prohibited removal of redundant labels)
4764
4765 2005-11-19 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4766
4767         * device/lib/_fs2slong.c, device/lib/_fs2sint.c, device/lib/_fs2char.c:
4768           Properly convert floats between -1.0 and 0.0 to long, int, and char
4769           types (max integer value of negative floats tends to zero).
4770         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
4771           Removed changes made so to work properly with floats between
4772           -1.0 and 0.0, as the problem is fixed in _fs2slong.c, _fs2sint.c,
4773           and _fs2char.c
4774
4775 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
4776
4777         * src/SDCCcse.c (ReplaceOpWithCheaperOp): minor fix for debugging only
4778         * src/mcs51/gen.c (genUnpackBits): better code and a fix,
4779         (genCast) cosmetic change
4780         * src/ds390/gen.c (genUnpackBits, ): ported from mcs51
4781         * src/ds390/ralloc.c (packRegsForAssign): ported fix for bitfields
4782         from mcs51
4783         * support/regression/tests/bitfields (testSignedBitfields): added
4784
4785 2005-11-18 Borut Razem <borut.razem AT siol.net>
4786
4787         * sdcc/device/lib/Makefile.in: remove all unnecessary files
4788         * device/lib/pic/Makefile.rules, device/lib/pic16/Makefile.subdir:
4789           introduced SILENT option to make building of pic16 libraries less
4790
4791 2005-11-18 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4792
4793         * device/lib/modff.c, device/lib/ceilf.c, device/lib/floorf.c:
4794           Now they work properly with floats between -1.0 and 0.0
4795         * device/lib/printf_large.c: Removed temporary patch for bug 1358192
4796
4797 2005-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
4798
4799         * src/SDCCicode.c (printOperand): added missing else
4800
4801 2005-11-18 Bernhard Held <bernhard AT bernhardheld.de>
4802
4803         * src/SDCCsymt.c (computeType): fixed bug 1358192: added missing else,
4804         reformatted for better readability
4805         * src/mcs51/gen.c (genUnpackBits): initial, incomplete support for
4806         signed bitfields
4807
4808 2005-11-17 Borut Razem <borut.razem AT siol.net>
4809
4810         * device/lib/pic16/Makefile.rules, device/lib/pic16/Makefile.subdir:
4811           introduced SILENT option to make building of pic16 libraries less
4812           verbose - used for nightly snapshot build
4813         * doc/sdccman.lyx: documented that SDCDB and ucSim are currently not
4814           available on Win32 platforms.
4815         * sdcc/device/lib/Makefile.in: added library sources for mcs51, small,
4816           medium, large, pic and pic16
4817
4818 2005-11-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
4819
4820         * device/lib/printf_large.c: Temporary patch for bug 1358192:
4821           printf("%f"...) sets fraction to zero.
4822
4823 2005-11-16 Raphael Neider <rneider AT web.de>
4824
4825         * src/pic/pcode.c (LinkFlow): handle empty flows correctly,
4826           fixes #1357221
4827         * src/pic/gen.c (genIfx): implemented for CARRY bit
4828         * src/pic16/gen.c (genAssign,genCast): fixed assigning/casting
4829           to generic pointers, fixes #1357332,
4830           (pic16_movLit2f): NEW,
4831           (pic16_storeForReturn,genDataPointerSet): use pic16_movLit2f
4832
4833 2005-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
4834
4835         * src/SDCCmain.c (parseCmdLine): fixed bug 1356800, thanks rsudjian
4836
4837 2005-11-11 Raphael Neider <rneider AT web.de>
4838
4839         * src/pic/gen.c: handle FPOINTERS like POINTERS everywhere
4840         * src/pic16/gen.c (pic16_derefPtr): now works for non-pointers as well,
4841           compute pointer's type from operand,
4842           (genUnpackBits,genPackBits): handle FPOINTERS correctly, re-indented,
4843           improved single bit reads, fixes bug #1353379
4844
4845 2005-11-09 Borut Razem <borut.razem AT siol.net>
4846
4847         * support/scripts/sdcc.nsi: added lib/pic to the package
4848
4849 2005-11-08 Maarten Brock <sourceforge.brock AT dse.nl>
4850
4851         * src/SDCCval.c (valUnaryPM): fixed bug 1350699
4852
4853 2005-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
4854
4855         * support/regression/tests/bug1348008.c: added
4856         * src/mcs51/gen.c (saveRBank, unsaveRBank): fixed bug 1348008
4857         * support/regression/tests/bug1337835.c: updated comment
4858
4859 2005-11-06 Borut Razem <borut.razem AT siol.net>
4860
4861         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
4862           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
4863           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
4864           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
4865           sim/ucsim/cmd.src/set.cc, sim/ucsim/cmd.src/show.cc:
4866           dynamic construction of cl_error_class and derivates - 2.nd try
4867
4868 2005-11-05 Borut Razem <borut.razem AT siol.net>
4869
4870         * sim/ucsim/sim.src/error.cc: fixed uninitialized class member variable
4871           bug, which caused Bus Errors on sparc solaris
4872
4873 2005-11-04 Borut Razem <borut.razem AT siol.net>
4874
4875         * sim/ucsim/error.cc, sim/ucsim/errorcl.h,
4876           sim/ucsim/sim.src/stack.cc, sim/ucsim/sim.src/stackcl.h,
4877           sim/ucsim/sim.src/uc.cc, sim/ucsim/sim.src/uccl.h,
4878           sim/ucsim/sim.src/mem.cc, sim/ucsim/sim.src/memcl.h,
4879           sim/ucsim/cmd.src/cmdconf.cc: dynamic construction of cl_error_class
4880           and derivates to resolve the initialization problem on OSX
4881
4882 2005-11-02 Borut Razem <borut.razem AT siol.net>
4883
4884         * sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
4885           corrected typo - #include <winsock2.h>
4886
4887 2005-11-02 Maarten Brock <sourceforge.brock AT dse.nl>
4888
4889         * src/asm.c (printILine): always close tmpFile, thanks Beau E. Cox,
4890           (_asxxxx_mapping): added org directive for future enhancements
4891
4892 2005-11-01 Borut Razem <borut.razem AT siol.net>
4893
4894         * sim/ucsim/app.cc, sim/ucsim/cmd.src/cmdutil.cc, sim/ucsim/cmd.src/newcmd.cc:
4895           enabled sockets on WIN32
4896         * sim/ucsim/cmd.src/newcmd.cc: fixed bug with uninitialized variables
4897
4898 2005-10-31 Borut Razem <borut.razem AT siol.net>
4899
4900         * support/regression/generate-cases.py: escape backslashes in {testcase}:
4901           WIN32 backslash path delimiters should be escaped when used in C strings
4902         * support/regression/tests/bitfields.c: exclude failing assertions for
4903           __CYGWIN32__ and __MINGW32__ hosts
4904
4905 2005-10-30 Borut Razem <borut.razem AT siol.net>
4906
4907         * src/SDCCutil.c: corrected double comparison typo
4908
4909 2005-10-30 Maarten Brock <sourceforge.brock AT dse.nl>
4910
4911         * device/lib/medium/Makefile: added for new memory model medium
4912         * device/include/asm/mcs51/features.h: updated for medium/pdata
4913         * device/include/mcs51/c8051f120.h: added sfr16/sfr32 definitions,
4914           added Multiply & Accumulate sbit's and MAC0_PAGE define
4915         * device/include/mcs51/c8051f300.h: added sfr16 definitions
4916         * device/include/mcs51/c8051f310.h: added sfr16 definitions
4917         * device/lib/_mullong.c: update for medium model
4918         * device/lib/incl.mk: added medium model
4919         * doc/sdccman.lyx: documented medium model
4920         * src/SDCCast.c (isBitAndPow2): simplified using updated powof2
4921         * src/SDCCicode.c (geniCodeMultiply, geniCodeDivision): use updated powof2
4922         * src/SDCCmain.c (optionsTable, linkEdit): enabled medium model
4923         * src/SDCCmem.c (allocIntoSeg): set iaccess for pdata symbols,
4924           (allocParms): set SCLS and OCLS to pdata for medium model
4925         * src/SDCCsymt.c (processFuncArgs): use default_local_map and set iaccess
4926           for pdata,
4927           (powof2): return <0 if not power of 2
4928         * src/avr/gen.c (genBitWise): use updated powof2
4929         * src/mcs51/gen.c (genMinusDec): use acc if necessary,
4930           (shiftR2Left2Result): small optimization in setup, save acc when storing,
4931           (shiftLLeftOrResult): use B if necessary
4932         * src/mcs51/main.c (_mcs51_finaliseOptions, mcs51_port): added medium model
4933         * src/mcs51/peeph.def: renamed 226 to 226.b, added 226.a
4934         * src/pic/main.c (_pic14_do_link): made void parameter list explicit
4935         * support/regression/Makefile.in: added test-mcs51-medium
4936         * support/regression/ports/mcs51-medium/spec.mk: added to test medium model
4937
4938 2005-10-28 Bernhard Held <bernhard AT bernhardheld.de>
4939
4940         * src/SDCCsymt.c (compStructSize): make bitfields without (un)signed
4941         specifier unsigned
4942         * device/lib/time.c (mktime): fixed bug 1334315
4943
4944 2005-10-28 Raphael Neider <rneider AT web.de>
4945
4946         * device/include/pic/p16f_common.inc: added common declarations
4947         * src/pic/ralloc.c (initStack): moved regs *r to block start for Alpha
4948
4949 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
4950
4951         * src/mcs51/gen.c (getTempRegs): return 0 if not enough registers found,
4952           (aopPutUsesAcc): added to predict accumulator use,
4953           (assignResultValue): save acc if necessary,
4954           (genMinusDec): store result if indirectly addressed,
4955           (genDivOneByte):  save acc if necessary,
4956           (movLeft2Result): bugfix if left already in acc,
4957           (genAnd, genOr, genXor, shiftL2Left2Result, shiftR2Left2Result): pay more
4958             attention to accumulator use (esp. pdata),
4959           (genReceive): receive pdata correctly
4960         * src/SDCCicode.c (isOperandInPagedSpace): added to detect pdata operands
4961         * src/SDCCicode.h: added isOperandInPagedSpace prototype
4962
4963 2005-10-27 Raphael Neider <rneider AT web.de>
4964
4965         * doc/sdccman.lyx: corrected version (should be 2.5.4 not 2.5.5)
4966
4967 2005-10-27 Raphael Neider <rneider AT web.de>
4968
4969         * .version: changed version to 2.5.4
4970         * doc/sdccman.lyx: changed version to 2.5.4, added some remarks to PIC14
4971         * device/lib/pic/libsdcc/{_mulint.c,_mullong.c}: use unsigned literals,
4972           (_divschar.c,divuchar.c,_mulchar.c,_modschar.c,_moduchar): NEW,
4973             arithmetics support routines
4974         * device/lib/pic/Makefile.rules: have assembler sources preprocessed
4975         * device/lib/Makefile.in: also create installdir for pic
4976
4977         * src/SDCCopt.c (cnvToFcall): mark support routines `extern' for
4978           pic14 port as well
4979         * src/pic/device.c (dump_sfr): rewritten to delegate register
4980           placement to the linker (use `extern sym' rather than sym EQU addr),
4981           (validAddress): fixed to check last specified address
4982         * src/pic/gen.c (aopForSym): added code to deal with array (useless?),
4983           (popGetLit): truncate literal value to 8 bit,
4984           (popGet): moved assert to more appropriate place
4985           (popGetExternal): create pCode operand from and mark the according
4986             symbol as being `extern'
4987           (popGetAddr): added sanity check on immediate's offset, provide
4988             GPOINTER tag on demand
4989           (aopPut): fixed for immediates,
4990           (mov2w_op): move operand's address or contents to WREG (depending on
4991             operand type), safer variant of mov2w,
4992           (movwf,call_libraryfunc): NEW, handy abbreviations,
4993           (get_argument_pcop,get_return_val_pcop,pass_argument,
4994           get_returnvalue): interface for accessing function parameters and
4995             return values,
4996           (assignResultValuei,genRet): use new parameter/return value interface
4997           (pic14_getDataSize): back to old version handling generic pointers,
4998           (pic14_toBoolean,genNot,genCpl,genCmpEq,genOrOp): heavily rewritten,
4999             provided implementation and/or fixed old one,
5000           (genMultOneByte,genDivOneByte,genModOneByte): implemented as library
5001             calls, removed legacy 8051 reference code
5002           (AccLsh,AccRsh): rewritten and fixed to deal with signed operands
5003           (loadSignToC): NEW, move the operands sign bit to CARRY,
5004           (genGenericShift): NEW, replaces genLeftShift, genRightShift and
5005             genRightShiftSigned, accepts negative shift counts,
5006           (setup_fsr): load FSR and adjust IRP (indirect memory access),
5007           (emitPtrByteGet,emitPtrByteSet): rewritten, now works with
5008             generic pointers, __data pointers and __code pointers,
5009           (genUnpackBits,genPackBits): rewritten to work with generic pointers
5010             and signed bitfields, limit bitfields to 8 bit,
5011           (genDataPointerGet): fixed number of bytes read,
5012           (genGenPointerGet,genConstPointerGet): fixed bitfield access,
5013           (genPointerGet,genPointerSet): fixed handling of __code pointers,
5014             pointers to constant data are no longer assumed to point to __code
5015             space, removed invalid pointer types,
5016           (bitpatternFromVal): retrieve the PICs representation of an integer
5017             or float literal,
5018           (genDataPointerSet): fixed assigning to po_immediate operands,
5019           (genGenPointerSet): implemented as library call,
5020           (genIfx): fixed incorrect condition,
5021           (genAddrOf): limit generic pointers' addresses to 2 bytes,
5022             provide GPOINTER tag according to destination's storage class,
5023           (genCast): added code to handle casting to generic pointers, added
5024             sign-/zero extension of the result
5025           (aop_isLitLike,op_isLitLike): fixed handling of immediates
5026         * src/pic/gen.h: added macros to access IRP bit in STATUS register
5027         * src/pic/genarith.c (genAddLit): use min(result's,left's) size, sign
5028           extend the result
5029         * src/pic/glue.c (is_shared_address,is_shared): check whether a given
5030           address/register resides in the shared banks
5031           (emitSymbolToFile): improved to handle global and `pinned' symbols,
5032             put all variables into separate sections (have the linker arrange
5033             them)
5034           (picglue): put init code and interrupt handlers in separate sections
5035         * src/pic/main.c: added port specific options table, modified to PORT
5036           structure to make GPOINTERs 3 byte, added pic14_options
5037           (_pic14_do_link): private linking routine (update paths to libraries,
5038             add libsdcc.lib by default)
5039         * src/pic/main.h: declare pic14_options
5040         * src/pic/pcode.c: fixed instructions i/o relations,
5041           (RegCond): reverted to correct version,
5042           (newpCodeOpLit): truncate literals to 8 bit,
5043           (genericPrint): added debug output,
5044           (getRegFromInstruction): fixed for various operand types, simplified
5045           (BuildFlow): fixed broken handling of isntructions with labels
5046           (LinkFlow): start at last instruction in flow (skip trailing comments),
5047             pass the flow on to the next instruction after CALL
5048           (pCodeReplace): NEW, replace a pCode and move meta data to the new one
5049           (insertPCodeInstruction): fixed inserting after a skip instruction,
5050           (DoBankSelect): fixed for labeled instructions
5051           (OptimizepBlock): honor --nopeep switch
5052           (AnalyzeFlow,ReuseReg): prevent crash on source files with no function
5053         * src/pic/pcodepeep.c (pCodePeepMatchRule): prevent NULL pointer accesses
5054         * src/pic/pcoderegs.c (regIsLocal): NEW, check visibility of a register
5055           (pCodeOptime2pCodes): allow disabling this optimization via
5056             --no-pcode-opt due seldomly occuring bugs, fixed some conditions
5057             but is still buggy), started implementation of a dataflow based
5058             pCode optimization (CSE + dead code elimination)
5059           (pCodeRegMapLiveRangesInFlow): removed bogus inCond
5060         * src/pic/ralloc.c (initStack): renamed stack registers to STK%d, the new
5061           names are independant of the stack location and therefore portable across
5062           devices
5063
5064 2005-10-27 Maarten Brock <sourceforge.brock AT dse.nl>
5065
5066         * src/mcs51/ralloc.c (bitType): added to detect bit variables,
5067           (selectSpil): fixed bug 1337835 by not spilling bit variables
5068         * support/regression/tests/bug1337835.c: added test for this bug
5069         * src/mcs51/peeph.def: restart after rule 3.c,
5070           addded rules 263.x to optimize loading constants
5071
5072 2005-10-26 Raphael Neider <rneider AT web.de>
5073
5074         * src/SDCCsymt.c (compStructSize): allow signed bitfields for PIC ports
5075         * src/pic16/gen.c (genUnpackBits): support signed bitfields,
5076           (genAssign): emit warning when casting literals to generic pointer
5077             type, also applies when taking the address of a fixed variable,
5078           (genCast): improved casting to generic pointers
5079         * src/pic16/glue.c (pic16emitStaticSeg): fixed(?) handling of fixed
5080           extern variables, added verbose error message
5081         * device/include/pic16/{string.h,errno.h}: added #pragma library c
5082
5083 2005-10-26 Bernhard Held <bernhard AT bernhardheld.de>
5084
5085         * src/mcs51/gen.c (genMinus): fixed bug 1270906: reverse subtraction,
5086         carry must be complemented too
5087         * src/mcs51/peeph.def: addded rule 262 to remove double cpl c, which
5088         could be emitted by genMinus
5089         * src/SDCCval.c (constVal): fixed bug 1305065
5090
5091 2005-10-25 Bernhard Held <bernhard AT bernhardheld.de>
5092
5093         * src/SDCCast.c (addCast): added promotion for bit variables
5094         (decorateType): emit W_COMPLEMENT before the problem vanishes behind
5095         promotion casts + optimisation
5096         (optimizeGetWord): fix warning 'i' might be used uninitialized
5097         * src/mcs51/gen.c (genCpl): removed W_COMPLEMENT
5098         * src/ds390/gen.c (genCpl): removed W_COMPLEMENT
5099
5100 2005-10-24 Bernhard Held <bernhard AT bernhardheld.de>
5101
5102         * src/SDCCicode.c (ast2iCode): reverted to 1.224 because of regression:
5103         all chars are promoted to int; promotion should be handled in SDCCast.c
5104
5105 2005-10-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5106
5107         * device/lib/_strcmp.c: Fixed bug 1326457
5108
5109 2005-10-11 Raphael Neider <rneider AT web.de>
5110
5111         * device/lib/pic16/libio/i2c.ignore: added 1320, fixes broken builds
5112         * device/lib/pic16/libdev/pic18f1320.c: added 1320's device library
5113
5114 2005-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
5115
5116         * src/SDCC.y (AT): fixed bug with sfr32 addresses when built with GCC
5117         * support/regression/tests/sfr16.c: added test for the sfr32 bug
5118
5119 2005-10-04 Raphael Neider <rneider AT web.de>
5120
5121         * device/include/pic16/pic18fregs.h, src/pic16/devices.inc,
5122           device/lib/pic16/pics.all: added pic18f1320
5123         * src/pic16/pcode.c (mnem2key): fixed prototype's argument mismatch
5124
5125 2005-09-30 Raphael Neider <rneider AT web.de>
5126
5127         * src/pic16/device.c (Pics16[]): moved device descriptions to devices.inc
5128         * src/pic16/devices.inc: NEW, provides device descriptions
5129         * src/pic16/gen.c (genInline): fixed handling of ';'-comments
5130
5131 2005-09-26 Maarten Brock <sourceforge.brock AT dse.nl>
5132
5133         * src/SDCCicode.c (operandOperation): added GETABIT, GETBYTE, GETWORD and
5134           GETHBIT
5135
5136 2005-09-25 Maarten Brock <sourceforge.brock AT dse.nl>
5137
5138         * doc/sdccman.lyx: updated Highest Order Bit documentation,
5139           documented Any Order Bit, Higher Order Byte and Higher Order Word
5140         * src/SDCC.y: added tokens GETABIT, GETBYTE, GETWORD
5141         * src/SDCCast.c (optimizeGetHbit): updated to also accept bool=expr&(1<<n),
5142           (optimizeGetAbit): new, to get any bit, not only the high bit,
5143           (optimizeGetByte): new, to get a byte from a (long) int: expr>>(8*n),
5144           (optimizeGetWord): new, to get a word from a long int: expr>>(8*n),
5145           (isConformingBody): also check GETABIT, GETBYTE, GETWORD,
5146           (decorateType): '&': also try GETABIT, GETBYTE, GETWORD optimization,
5147             RIGHT_OP: also try GETBYTE, GETWORD optimization,
5148             GETABIT, GETBYTE, GETWORD: decorate them,
5149           (isShiftRightLitVal, isBitAndPowOf2): new helper functions,
5150           (ast_print): added GETABIT, GETBYTE, GETWORD
5151         * src/SDCCcse.c (isSignedOp): added GETABIT, GETBYTE, GETWORD
5152         * src/SDCCicode.c (codeTable): added GETABIT, GETBYTE, GETWORD,
5153           (geniCodeBinary): new generic binary icode,
5154           (ast2iCode): added GETABIT, GETBYTE, GETWORD
5155         * src/port.h: updated comment for PORT.hasExtBitOp
5156         * src/mcs51/gen.c (genGetAbit): new, to get any single bit,
5157           (genGetByte): new, to get a single byte,
5158           (genGetWord): new, to get a word from a long,
5159           (gen51Code): added GETABIT, GETBYTE, GETWORD
5160         * src/mcs51/main.c (hasExtBitOp): added GETABIT, GETBYTE, GETWORD
5161
5162 2005-09-23 Raphael Neider <rneider AT web.de>
5163
5164         * configure.in, configure: have device/lib/pic configured
5165         * device/lib/Makefile.in: added model-pic14
5166         * device/lib/clean.mk: added pic/ to clean rule
5167         * device/lib/pic: added rudimentary pic14 library providing support
5168           functions for multiplication/division/generic pointer access
5169         * src/SDCCopt.c (convilong): mark support functions as extern
5170           for pic14 port as well
5171         * src/pic/gen.c (genMult): added assertions,
5172           (genpic14Code): emit warning on unhandled iCodes
5173         * src/pic/main.c (_hasNativeMulFor): return true only for 8x8 bit
5174         * src/pic/pcode.c (pCodeOpCopy),
5175         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed handling of various
5176           pCodeOpReg-subtypes (PO_{STATUS,INTCON,PCL,PCLATH,PCLATU,BSR,
5177           SFR_REGISTER}), made safe for future extensions
5178         * src/pic16/pcode.c (pic16_safepCodeUnlink): allow for removal of
5179           instructions even if preceeded by SKIP instructions (also remove
5180           them); removed unused code
5181         * src/pic16/pcode.h: added arg2 to pCodeOpLit to match pCodeOpLit2,
5182           prevents leaving parts of the structure uninitialized after copying
5183
5184 2005-09-22 Maarten Brock <sourceforge.brock AT dse.nl>
5185
5186         * src/mcs51/gen.c (genMinus): fix for undetected bug introduced 3 months
5187           ago by me
5188         * support/regression/tests/addsub.c: added test for the bug
5189
5190 2005-09-21 Raphael Neider <rneider AT web.de>
5191
5192         * device/include/pic16/pic18f1220.h,
5193           device/lib/pic16/libdev/pic18f1220.c: added ECCPAS sfr and bitfield
5194         * device/lib/pic16/Makefile.rules: added missing opening paren
5195         * src/pic16/gen.c (pic16_genNot,pic16_genCpl): removed as these
5196           are provided in genutils.c,
5197           (genUminusFloat,genUminus,genCmpEq): added asserts on different
5198           operand/result sizes,
5199           (genCmp): assert on NULL pointers first, then check deref'ed values
5200         * src/pic16/genutils.c (pic16_genCpl): fixed for different operand/
5201           result size
5202
5203 2005-09-18 Raphael Neider <rneider AT web.de>
5204
5205         * src/pic16/gen.c (genFarPointerGet,genFarPointerSet): removed
5206           as these are now unused,
5207           (genPointerGet,genPointerSet): handle FPOINTERs like POINTERs
5208         * src/pic16/pcode.c (pic16_symIsSpecial): assume REG_TMPs to be
5209           local, avoids uninitialized pointer dereference on r->name
5210         * src/pic16/ralloc.c (newReg): fixed indentation
5211
5212 2005-09-13 Maarten Brock <sourceforge.brock AT dse.nl>
5213
5214         * src/SDCCval.c (constVal): fixed bug 730366
5215         * support/Util/SDCCerr.c,
5216         * support/Util/SDCCerr.h: added warning W_INVALID_INT_CONST
5217
5218 2005-09-10 Maarten Brock <sourceforge.brock AT dse.nl>
5219
5220         * as/mcs51/lkmem.c (summary2): fixed report for absolute areas (bug 1210220)
5221
5222 2005-09-09 Maarten Brock <sourceforge.brock AT dse.nl>
5223
5224         * src/mcs51/peeph.def (241.x): fixed bug when comparing generic pointers
5225
5226 2005-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
5227
5228         * as/hc08/lkaomf51.c (OutputName): made name unsigned char,
5229           (hex2dec): made hex_digit unsigned char, removed ascii dependance
5230         * as/mcs51/lkaomf51.c (OutputName): made name unsigned char,
5231           (hex2dec): made hex_digit unsigned char, removed ascii dependance
5232         * as/mcs51/lkarea.c (lnkarea2): sort absolute areas to the front
5233         * packihx/packihx.c (hexDigit): made c unsigned char
5234         * as/mcs51/lklibr.c (fndsym),
5235         * link/z80/lkgb.c (gb),
5236         * link/z80/lklibr.c (fndsym),
5237         * link/z80/lkrloc.c (relr),
5238         * sim/ucsim/libltdl/ltdl.c (load_deplibs, try_dlopen),
5239         * src/SDCC.lex (checkCurrFile, process_pragma),
5240         * src/SDCCglue.c (spacesToUnderscores),
5241         * src/SDCCmain.c (setParseWithComma, processFile),
5242         * src/asm.c (tvsprintf, printCLine),
5243         * src/avr/gen.c (emitcode, aopPut),
5244         * src/ds390/gen.c (emitcode),
5245         * src/hc08/gen.c (emitcode, emitinline),
5246         * src/mcs51/gen.c (emitcode, genInline),
5247         * src/pic/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
5248           tokenizeLineNode),
5249         * src/pic/ralloc.c (debugLog),
5250         * src/pic16/pcodepeep.c (cvt_extract_destination, cvt_extract_status,
5251           tokenizeLineNode),
5252         * src/pic16/ralloc.c (debugLog),
5253         * src/z80/main.c (_process_pragma):
5254            made all ctype.h function calls safe
5255         * src/SDCCopt.c: include math.h for fabs
5256         * src/SDCCpeeph.c: added macros ISCHARDIGIT, ISCHARSPACE and ISCHARALNUM
5257           and used them throughout the code to make ctype.h function calls safe
5258         * src/ds390/main.c (asmLineNodeFromLineNode),
5259         * src/mcs51/main.c (asmLineNodeFromLineNode): made p unsigned char*
5260         * src/pic/gen.c (DEBUGpic14_emitcode, pic14_emitcode): made lbp
5261            unsigned char*
5262         * src/pic/pcode.c (mnem2key): made mnem unsigned char*,
5263           (newpCodeAsmDir): made ctype.h function calls safe
5264         * src/pic16/gen.c (pic16_emitpcomment, DEBUGpic16_emitcode,
5265           pic16_emitcode):  made lbp unsigned char*
5266         * src/pic16/pcode.c (mnem2key): made mnem unsigned char*,
5267           (pic16_newpCodeAsmDir): made ctype.h function calls safe
5268         * src/xa51/gen.c (emitcode),
5269         * src/z80/gen.c (_emit2): made lbp unsigned char*
5270         * support/Util/MySystem.c (split_command): made cmd_line and p unsigned
5271            char*
5272
5273 2005-09-05 Raphael Neider <rneider AT web.de>
5274
5275         * src/pic16/ralloc.c (pic16_allocDirReg): use device specific
5276           access bank splitpoint
5277
5278 2005-09-05 Raphael Neider <rneider AT web.de>
5279
5280         * device/lib/pic16/libc/Makefile: added (missing) string to SUBDIRS
5281
5282 2005-09-03 Maarten Brock <sourceforge.brock AT dse.nl>
5283
5284         * .version: changed to version 2.5.3
5285         * doc/sdccman.lyx: changed version to 2.5.3,
5286           documented --codeseg and --constseg and pragma codeseg and constseg,
5287           documented bit parameters (reentrant) and bit returning
5288         * src/SDCCicode.c (geniCodeReceive): fixed (possible) bug generating
5289            currFunc->recvSize, but is this ok for all ports?
5290           (ast2iCode): result of ~ on unsigned char must be cast to int for
5291            bool to work
5292         * src/SDCCmem.c (allocGlobal, allocLocal): don't put bit returning
5293           function pointers in bit space
5294         * src/SDCCsymt.c (checkSClass): allow bit returning function pointers,
5295           (processFuncArgs): call port.reg_parm() with reentrancy info
5296         * src/port.h,
5297         * src/avr/main.c,
5298         * src/ds390/main.c,
5299         * src/hc08/main.c,
5300         * src/pic/main.c,
5301         * src/pic16/main.c,
5302         * src/xa51/main.c,
5303         * src/z80/main.c: port.reg_parm prototype extended with
5304           "bool reentrant" parameter
5305         * src/mcs51/main.c (_mcs51_regparm): use parameter reentrant instead of
5306           options.stackAuto for allocating bit register parameters
5307         * src/mcs51/gen.c (genNot): optimized complementing direct bit,
5308           (genSend): set BitBankUsed if it is,
5309           (selectRegBank): factored out of genCall for use in genPcall,
5310           (genCall): removed redundant dtype assignmen, use selectRegBank,
5311           (genPcall): handle returning in Carry properly, save in F0 if needed,
5312           (genReceive): handle bit register parameters
5313         * src/mcs51/ralloc.c (updateRegUsage): update BitBankUsed along the way,
5314           (mcs51_assignRegisters): enable bit registers for all reentrant
5315            functions and don't set BitBankUsed unconditionally
5316         * src/mcs51/peeph.def (177.d): fixed bug if %2==%3
5317         * support/regression/tests/bitvars.c: enable tests for SDCC_STACK_AUTO
5318         * support/regression/tests/funptrs.c: added tests for BOOL and for return
5319
5320 2005-08-27 Borut Razem <borut.razem AT siol.net>
5321
5322         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) and on
5323         ppc-osx (Darwin) does not support -u option. It seems that it is
5324         supported only on Linux - GNU cp
5325
5326 2005-08-25 Borut Razem <borut.razem AT siol.net>
5327
5328         * sim/ucsim/gui.src/serio.src/Makefile.in,
5329           sim/ucsim/s51.src/Makefile.in, sim/ucsim/avr.src/Makefile.in,
5330           sim/ucsim/z80.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
5331           sim/ucsim/xa.src/Makefile.in: install -s changed to 2 steps:
5332           install and strip, since the strip at /usr/ccs/bin should be used
5333           on solaris
5334
5335 2005-08-24 Borut Razem <borut.razem AT siol.net>
5336
5337         * clean.mk, device/lib/clean.mk: find on sparc-solaris does not support -maxdepth option
5338
5339 2005-08-23 Bernhard Held <bernhard AT bernhardheld.de>
5340
5341         * src/SDCCopt.c (convertToFcall): fixed modulus with divisors 1 and
5342         ffffffffu
5343
5344 2005-08-23 Maarten Brock <sourceforge.brock AT dse.nl>
5345
5346         * as/mcs51/aslink.h: completed lkrloc.c prototypes
5347         * as/mcs51/lkmain.c (link_main): fixed warning
5348         * device/include/stdbool.h: ds390 has no advanced bit support yet
5349         * src/SDCC.y: use SPEC_SHORT and renamed _signed to b_signed
5350         * src/SDCCsymt.c: use SPEC_SHORT and renamed _signed to b_signed
5351         * src/SDCCsymt.h (struct specifier): renamed _xxx bitfields to b_xxx
5352           and updated their macros
5353         * src/SDCCval.c (constVal): updated comment for renamed b_long
5354
5355 2005-08-22 Maarten Brock <sourceforge.brock AT dse.nl>
5356
5357         * as/mcs51/asdata.c: changed ctype['['] to BINOP
5358         * as/mcs51/asexpr.c (expr): added case '[' for bit access in bdata,
5359           (term): abused bit 15 of s_addr to indicate bit-addressable bytes,
5360           (oprio): set priority for '['
5361         * as/mcs51/aslink.h: added define R_BIT, and prototypes for adb_bit
5362            and adb_24_bit
5363         * as/mcs51/asm.h: added defines R_BIT and S_BIT
5364         * as/mcs51/lkarea.c (lnksect2): use T for seg BIT_BANK and overlay it
5365         * as/mcs51/lkdata.c: changed ctype['['] to BINOP
5366         * as/mcs51/lkmain.c (Areas51): rel2 contains 12 (=C) areas now,
5367           added overlayable BIT_BANK area
5368         * as/mcs51/lkmem.c (summary): add BIT_BANK to BSEG_BYTES in the report,
5369           (summary2): explain 'T' in legenda
5370         * as/mcs51/lkrloc.c: replaced old K&R style,
5371           (relr): added R_BIT processing,
5372           (errmsg): added "Bit-addressable relocation error",
5373           (adb_bit): added for converting from byte- to bit-addressable space,
5374           (adb_24_bit): added for converting from byte- to bit-addressable space
5375         * device/include/stdbool.h: changed BOOL to __bit for mcs51 as it can be
5376            used in reentrant functions now even as return value
5377         * device/lib/_gptrput.c (_gptrput): removed obsolete code
5378         * src/SDCCast.c (resultTypePropagate): also propagate AND_OP and OR_OP,
5379           (decorateType): case '!', GETHBIT, AND_OP, OR_OP: result in bool or char
5380         * src/SDCCglobl.h: added indicator BitBankUsed
5381         * src/SDCCglue.c (glue): emit area BIT_BANK with byte 'bits' and equ's for
5382            the bit registers b0-b7
5383         * src/SDCCicode.c (operandFromSymbol): removed IS_BITVAR check,
5384           (geniCodeCast): fixed bug 1263853,
5385           (geniCodeLogicAndOr): put result in bool or char,
5386           (geniCodeReceive): added parameter func for accessing the return type,
5387           (geniCodeFunctionBody): pass func to geniCodeReceive
5388         * src/SDCCmain.c: added indicator BitBankUsed
5389         * src/SDCCmem.c (allocLocal): explicitly set sclass for V_BIT
5390         * src/SDCCsymt.c (newBoolLink): added for creating a bool/bit,
5391           (checkSClass): don't put automatic bool/bit on stack,
5392           (checkFunction): removed check on function cannot return bit
5393         * src/SDCCsymt.h: added newBoolLink prototype
5394         * src/mcs51/gen.c (rb1regs): added bit registers,
5395           (movc): created for assigning to carry,
5396           (pushReg, popReg): created for pushing registers,
5397           (sameRegs): check both AOP_REG and AOP_CRY types,
5398           (aopOp): handle bit registers,
5399           (aopPut): optimization no self-assign,
5400           (saveRegisters): push reg->base (bits) only once for bit registers,
5401            and use pushReg,
5402           (unsaveRegisters): pop reg->base only once and use popReg,
5403           (assignResultValue): added parameter func and return in carry for bits,
5404           (genIpush): optimization no reload in A if not changed,
5405           (genSend): bit parameters in reentrant functions are passed in bit
5406            registers by first assigning to bits in B, then save registers and
5407            copy B to bits,
5408           (genCall): handle returning in Carry properly, save it in F0 if needed,
5409           (genPcall): updated assignResultValue call, this is not safe yet for bit
5410            returning function !!!
5411           (genFunction): don't generate equ's for bit registers and use pushReg,
5412           (genEndFunction): take care of bit returning functions and use popReg,
5413           (genRet): return bit in Carry,
5414           (genIfx): optimize bit registers and other directly addressable bits,
5415           (genReceive): updated assignResultValue call
5416         * src/mcs51/main.c (_mcs51_reset_regparm): added regBitParmFlg,
5417           (_mcs51_regparm): allow passing of upto 8 bit parameters in bit
5418            registers when using stack-auto
5419         * src/mcs51/ralloc.c (_G): added allBitregs,
5420           (regs8051): added the bit registers,
5421           (createStackSpil): use macro IS_BIT,
5422           (getRegBit): added to allocate a bit register, else spill,
5423           (getRegBitNoSpil): added to allocate a bit register, else a gpr,
5424           (updateRegUsage): factored out to ease stepping while debugging,
5425           (serialRegAssign): use updateRegUsage, only spill bits if necessary,
5426            also allocate bit registers,
5427           (fillGaps): handle bit registers,
5428           (findAllBitregs): added to create bit vector with all bit registers,
5429           (mcs51_allBitregs): returns this bit vector,
5430           (mcs51_assignRegisters): when using stack-auto use bit registers for
5431            passing parameters and creating local variables
5432         * src/mcs51/ralloc.h: added B0_IDX..B7_IDX and prototype mcs51_allBitregs
5433
5434 2005-08-22 Borut Razem <borut.razem AT siol.net>
5435
5436         * device/lib/Makefile.in: replaced find option -or with -o
5437           to make it run on solaris
5438
5439 2005-08-22 Raphael Neider <rneider AT web.de>
5440
5441         * src/pic16/gen.c (pic16_loadFromReturn): added check for AOP_PCODE,
5442           fixes #1265442 (crash on Solaris)
5443
5444 2005-08-20 Borut Razem <borut.razem AT siol.net>
5445
5446         * configure, configure.in: added tests for libsocket and libnsl libraries,
5447           requred by sdcdb on sparc-solaris; generate support/regression/Makefile
5448           from support/regression/Makefile.in
5449         * support/regression/Makefile.in: added
5450         * device/lib/pic16/Makefile.common.in: force make to use bash shell
5451         * sim/ucsim/libtool: regenerated on sparc-solaris
5452         * sim/ucsim/avr.src/Makefile.in, sim/ucsim/hc08.src/Makefile.in,
5453           sim/ucsim/s51.src/Makefile.in, sim/ucsim/xa.src/Makefile.in,
5454           sim/ucsim/z80.src/Makefile.in: removed GNU ld specific linker options
5455           -Wl,--start-group and -Wl,--end-group to enable ucsim compilation on
5456           sparc-solaris, which doesn't use GNU ld linker
5457         * device/lib/Makefile.in: cp on sparc-solaris (SunOS) does not support -u option
5458         * as/Makefile: find on sparc-solaris does not support -maxdepth option
5459
5460 2005-08-19 Maarten Brock <sourceforge.brock AT dse.nl>
5461
5462         * src/mcs51/peeph.def: updated comments
5463
5464 2005-08-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5465
5466         * device/lib/_gptrget.c,
5467         * device/lib/_gptrput.c: slightly shorter
5468         * doc/sdccman.lyx: incremented version
5469         * src/mcs51/peeph.def: moved peephole comments to the line of first
5470           change to better keep line correlation, reanimated 186.e
5471         * src/mcs51/peeph.def: renamed similar peepholes by using suffixes
5472
5473 2005-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
5474
5475         * src/pic/pcode.c : Pasted ".line" assembly directives patch from
5476           David Saxton with quotes around file name.
5477
5478 2005-08-15 Borut Razem <borut.razem AT siol.net>
5479
5480         * support/regression/tests/bitfields.c, support/regression/tests/bitvars.c,
5481           support/regression/tests/bitwise.c, support/regression/tests/literalop.c,
5482           support/regression/tests/rotate.c, support/regression/tests/zeropad.c:
5483           make tests run on x86_64 platform
5484
5485 2005-08-13 Raphael Neider <rneider AT web.de>
5486
5487         * device/lib/pic16/Makefile.subdir: weakened clean-intermediate rule
5488           as it might be executed DURING a build (parallel make is wonderful)
5489
5490 2005-08-13 Raphael Neider <rneider AT web.de>
5491
5492         * device/lib/Makefile.in (port-specific-objects-pic16):
5493           revert to cp $(PORT)/bin/*.* $(PORTDIR)
5494         * device/lib/pic16/Makefile: added .PHONY targets, removed builddir
5495           dependency
5496         * device/lib/pic16/Makefile.rules: build subdirs before creating
5497           the library, removed builddir rule, create $(builddir) early in
5498           recurse rule, use empty recurse rule for leaf directories
5499         * device/lib/pic16/Makefile.subdir: added phony targets, ignore
5500           mkdir errors (race condition), removed duplicate suffix "hex"
5501           from clean rules
5502         * device/lib/pic16/libdev/Makefile: recursive make via + and $(MAKE)
5503         * device/lib/pic16/libio/Makefile: create sub-make's builddir early,
5504           prevents mkdir -p from aborting on Alpha
5505
5506 2005-08-12 Raphael Neider <rneider AT web.de>
5507
5508         * src/pic16/glue.c (pic16_print(G)PointerType): do not flush
5509           db-statements in order to allow for arrays of pointers in code
5510           sections to be placed without interspersed 0-padding, fixes
5511           bug #1256215
5512         * (emitStatistics): fixed division by zero for pic18f1220
5513         * src/pic16/pcode.c: buffer (up to) 12 DB directives to allow for
5514           unpadded writing of 8-bit, 16-bit, 24-bit and 32-bit values
5515         * (pic16_emitDS): respect DB_ITEMS_PER_LINE
5516         * (pic16_pCodeConstString): keep track of already emitted string
5517           literals to prevent "duplicate definitions of symbol _str_NR"
5518         * src/pic16/ralloc.c (pic16_allocRegByName): removed not so helpful
5519           debug message
5520         * device/lib/Makefile.in: ignore failing PIC16 library builds
5521         * device/lib/pic16/Makefile: do not build if gputils are missing
5522         * device/lib/pic16/Makefile.common.in: do not enforce MAKEFLAGS=-s
5523
5524 2005-08-10 Raphael Neider <rneider AT web.de>
5525
5526         * device/lib/Makefile.in: fixed copying pic16 libraries (broken by
5527           my last commit)
5528
5529 2005-08-10 Raphael Neider <rneider AT web.de>
5530
5531         * src/*.c, src/pic16/{gen.c,glue.c,main.c}: applied Vangelis
5532           Rokas' patch to add the new fixed point type "__fixed16x16"
5533         * device/lib/pic16/libsdcc/fixed16x16: added Vangelis' support
5534           functions for __fixed16x16 arithmetics
5535         * device/lib/pic16: reimplemented the build system to support
5536           a separate build directory, better handling of libio (create
5537           the library in a separate subdir for each architecture) and
5538           easier configuration (centralized in Makefile.common)
5539
5540 2005-08-07 Raphael Neider <rneider AT web.de>
5541
5542         * src/pic16/gen.c (genrshTwo): fixed sign extension
5543         * src/pic16/device.c: added pic18f2320, 4220 and 4320
5544         * device/include/pic16/pic18f2220.h: changed some bit definitions,
5545           added T0CONbits
5546         * device/include/pic16/pic18f4220.h: NEW, header for
5547           pic18f4220 and pic18f4320
5548         * device/include/pic16/pic18fregs.h: added new devices,
5549           embraced Nop(), ClrWdt(), Sleep() and Reset() with do {} while(0)
5550         * device/include/pic16/signal.h: resolved name clashes
5551           on bit definitions, added DEF_HANDLER2(sig1,sig2,handler)
5552           to also allow testing for interrupt enable bits, added
5553           comments on how to use the macros
5554         * device/lib/pic16/libdev/pic18f2220.c: added T0CONbits
5555         * device/lib/pic16/libdev/pic18f{2320,4220,4320}.c: NEW,
5556           register definitions for the devices
5557         * device/lib/pic16/pics.all: added new devices
5558         * device/lib/pic16/libc/stdlib/calloc.c: fixed zeroing
5559           allocated memory
5560         * device/lib/pic16/libc/stdlib/memfree: do not count
5561           the block header as free memory
5562         * device/lib/pic16/libc/stdlib/memmisc.c (_initHeap):
5563           simplified and added missing end-of-blocklist-marker
5564           (reported by Peter Onion, fixes #1252814)
5565         * (_mergeHeapBlock): fixed loop condition
5566         * device/lib/pic16/libc/stdlib/realloc.c: return NULL for
5567           len==0, restructured code
5568         * device/lib/pic16/libc/stdlib/{malloc,memfreemax}.c: cleaned
5569           up a bit, reduced bitfield accesses, prevent endless loops
5570           in case of heap corruption
5571         * device/lib/pic16/libc/stdlib/x_ftoa.c: disabled
5572           "unreferenced arguments/must return a value" warnings
5573         * device/lib/pic16/libio/usart/ubaud.c (usart_baud):
5574           replaced BAUDREG with SPBRG
5575         * device/lib/pic16/libsdcc/lregs/{lrrest.c,lrst.c},
5576           device/lib/pic16/debug/gstack/gstack.c: replaced
5577           _naked, _asm, _endasm with __naked, __asm, __endasm
5578
5579 2005-08-05 Raphael Neider <rneider AT web.de>
5580
5581         * src/pic16/gen.c (pic16_aopGet): fixed handling of offsets in
5582           AOP_PCODE operands, fixes multibyte union-bitfield-accesses
5583
5584 2005-08-05 Borut Razem <borut.razem AT siol.net>
5585
5586         * device/lib/Makefile.in: added missing ';'
5587         * configure: removed ^M characters
5588
5589 2005-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5590
5591         * device/include/mcs51/at89c51ed2.h, device/include/mcs51/p89v51rd2.h,
5592           device/include/mcs51/at89s53.h: changed to GNU Lesser General Public
5593           License
5594
5595 2005-08-04 Borut Razem <borut.razem AT siol.net>
5596
5597         * configure.in: pic16 libraries build 2nd try - enable running
5598           configure in device/lib/pic16
5599         * configure: regenerated from configure.in
5600         * device/lib/Makefile.in: create $(PORT)/bin directory
5601
5602 2005-08-03 Raphael Neider <rneider AT web.de>
5603
5604         * src/pic16/gen.c (pic16_derefPtr): NEW, single place
5605           to get/set values via pointers
5606         * (genUnpackBits,genPackBits): changed detection of
5607           ptr->bitfield vs. sym.bitfield, fixed access via generic
5608           pointers, removed dead (wrong) code for multibyte bitfields
5609         * (genNearPointerGet, genGenPointerGet): removed useless code,
5610           fixed bitfield detection, fixes #1250594
5611         * (genNearPointerSet): removed useless code
5612         * src/pic16/gen.h: renamed pic16_emitpcode to pic16_emitpcode_real
5613           and introduced macro pic16_emitpcode that conditionally emits
5614           the origin of the following pCode (useful for debugging SDCC)
5615         * src/pic16/pcode.c: changed (and disabled) some debug outputs
5616         * (createDefmap): fixed handling of LFSR for --optimize-df
5617
5618 2005-08-02 Borut Razem <borut.razem AT siol.net>
5619
5620         * device/lib/Makefile.in: pic16 libraries build enabled since
5621           gputils-0.13.2 are now localy installed at sourceforge's compile farm
5622
5623 2005-08-02 Raphael Neider <rneider AT web.de>
5624
5625         * src/pic16/gen.c (genPackBits): removed deprecated warning
5626         * (genGenPointerSet): fixed bitfield detection
5627
5628 2005-08-02 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5629
5630         * device/include/mcs51/msm8xc154s.h: Removed PT2 definition, now in 8052.h.
5631
5632 2005-07-31 Raphael Neider <rneider AT web.de>
5633
5634         * device/lib/pic16/libdev/pic18f458.c,
5635           device/include/pic16/pic18f458.h: added missing T0CONbits
5636
5637 2005-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
5638
5639         * device/include/mcs51/msm8xc154s.h: added, thanks to Matthias Arndt
5640
5641 2005-07-28 Maarten Brock <sourceforge.brock AT dse.nl>
5642
5643         * src/mcs51/gen.c (operandsEqu): fixed bug 1246687
5644
5645 2005-07-23 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5646
5647         * device/include/mcs51/at89c51ed2.h: added.
5648
5649 2005-07-23 Raphael Neider <rneider AT web.de>
5650
5651         * src/pic/gen.h: added emitpcode macro for debugging
5652         * src/pic/gen.c (emitpcode): renamed to emitpcode_real
5653           and replace by macro adding debug information on demand
5654         * (genNot): fixed to C semantics (!0 = 1; !x = 0 iff x != 0)
5655         * (gencjne): tried to fix; replaced with correct (slower) code
5656         * (gen{Unp,P}ackBits): fixed single bit access
5657         * src/pic/pcode.c (AnalyzepCode): fixed DFPRINTF argument
5658         * src/pic/pcodepeep.c (pCodeSearchCondition): fixed finding
5659           previous instruction
5660         * src/pic/pcoderegs.c (regIsSpecial): NEW, check whether a
5661           register has to be handled with care (forbidding movement
5662           of assignments/uses, removing assignments completely, ...)
5663         * (pCodeOptime2pCodes): make use of regIsSpecial
5664         * added lots of debugging output (commented out)
5665         * src/pic/rallloc.c (deassignLRs): prevent operand registers
5666           from being reused as result UNLESS it is known to work
5667
5668 2005-07-23 Maarten Brock <sourceforge.brock AT dse.nl>
5669
5670         * support/Util/dbuf.h: include <stddef.h> for size_t
5671         * .version: changed to version 2.5.2
5672
5673 2005-07-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5674
5675         * src/SDCCloop.c (loopInvariants): fixed bug #1234048
5676
5677 2005-07-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5678
5679         * src/hc08/gen.c (genMinus): fixed bug #1241835,
5680           (genModOneByte): removed needless psha/pula
5681
5682 2005-07-22 Raphael Neider <rneider AT web.de>
5683
5684         * src/SDCCmain.c (linkEdit): initialized linkerScriptFileName,
5685           have PIC14 handled like PIC16, fixes broken pic14 linker calls
5686         * src/pic/gen.c (resolveIfx): do not "invent" labels
5687         * (genSkipc): changed to positive logic
5688         * (genSkipCond): removed as no longer needed
5689         * (pic14_mov2w_regOrLit,genCmp): NEW, replacement for buggy version,
5690           backport from PIC16
5691         * (genLeftShift): check operands are in different registers
5692         * src/pic/genarith.c (genPlus): replaced INCF with ADDLW as
5693           INCF does not update CARRY...
5694         * src/pic/main.c: fixed _linkCmd
5695         * src/pic/pcode.c (unlinkpCode): added inactive code
5696         * src/pic/ralloc.c (deassignLRs): keep arguments to shift operations
5697           alive (do not assign result and operand overlapping registers)
5698
5699 2005-07-22 Raphael Neider <rneider AT web.de>
5700
5701         * src/pic/device.c (dump_sfr): replaced register declaration with
5702           call to emitSymbolToFile() to avoid duplicate symbols
5703         * (assignRelocatableRegisters): do not declare external symbols
5704         * src/pic/ralloc.c (allocNewDirReg): fixed to get size of arrays
5705           right (take size of type, not etype)
5706         * (allocDirReg): fixed call to allocNewDirReg() to pass OP_SYM_TYPE
5707         * (writeUsedRegs): also dump dynDirectRegs (e.g. local variables)
5708         * (packRegsForAccUse): disabled assignment of WREG as
5709           the result reg to prevent occurence of just fixed #1235003,
5710           fixes #1242954
5711         * src/pic/glue.c (emitSymbolToFile): NEW, central place to declare
5712           symbols (avoids duplicate symbols in .asm file)
5713         * (pic14emitRegularMap): use emitSymbolToFile()
5714         * src/pic/gen.c (aopOp): fixed spillLocation handling
5715         * (gen{Unp,P}ackBits): fixed acquiring bit-operands
5716         * (genDataPointerSet): removed unneccessary variables/output
5717
5718 2005-07-22 Maarten Brock <sourceforge.brock AT dse.nl>
5719
5720         * as/mcs51/lkarea.c: enlarged codemap for banked memory
5721         * device/lib/mcs51/crtbank.asm: added # to 0x0F
5722
5723 2005-07-21 Raphael Neider <rneider AT web.de>
5724
5725         * src/pic/gen.c (aopOp): do not generate AOP_ACC operands as pic14
5726           architecture cannot handle them efficiently, fixes bug #1235003
5727         * src/pic16/device.c (pic16_dump_{u,i}section,pic16_dump_int_registers):
5728           check for empty sets before using them (fixes bug #1232190)
5729
5730 2005-07-19 Maarten Brock <sourceforge.brock AT dse.nl>
5731
5732         * as/mcs51/lkarea.c (lnkarea, lnkarea2): improved BSEG size calculation,
5733           (lnksect2): generate warnings for memory overlap
5734         * src/SDCC.lex (doPragma, process_pragma): added pragma's codeseg and
5735           constseg to set the name of these segments so you can instruct the linker
5736           to place them in banks
5737         * src/SDCCast.c (decorateType): use new macro IS_FUNCPTR()
5738         * src/SDCCglobl.h: added MODEL_HUGE to enum,
5739           added code_seg and const_seg to options
5740         * src/SDCCglue.c (emitMaps): use options.const_seg,
5741           (createInterruptVect): put interrupt vectors in segment HOME,
5742           (glue): put HOME before static segment and put the main glue in HOME,
5743           (glue): use options.code_seg
5744         * src/SDCCicode.c (geniCodeCall): use new macro IS_FUNCPTR()
5745         * src/SDCCmain.c: added option --codeseg and --constseg to set the name of
5746           these segments so you can instruct the linker to place them in banks
5747           (linkEdit): use code_loc for HOME segment which should be the first
5748           segment in code memory now
5749         * src/SDCCmem.c: fixed more stuff like bug 1238386
5750         * src/SDCCsymt.c (getSize): use generic pointer size for banked functions,
5751           (changePointer): don't change function pointers to code pointers for
5752           banked functions,
5753           (compareType): added exceptional check for banked function pointers
5754         * src/SDCCsymt.h: changed IFFUNC_ISBANKEDCALL, added IS_FUNCPTR
5755         * src/hc08/main.c (_hc08_genAssemblerPreamble): put HOME first, put CSEG
5756           after static in code memory
5757         * src/mcs51/gen.c: added aopLiteralLong prototype,
5758           (aopForSym): use getSize for functions,
5759           (genCall): generate banked calls over one trampoline __sdcc_banked_call
5760           in HOME with lsb of address in r0, msb in r1 and bank in r2, use
5761           -Wl-bBANKSEG=0xbbaaaa option to set the address (aaaa) and bank (bb) of
5762           the segment,
5763           (genPcall): use call for literal function pointers and generate banked
5764           calls over the one trampoline so there's only one place for the user to
5765           modify according to his/hers hardware,
5766           (genEndFunction): jump to __sdcc_banked_ret in HOME for banked functions,
5767           (genPlusIncr): moved check icount>4 beyond inc dptr optimization
5768         * src/mcs51/main.c: added keyword banked,
5769           (_mcs51_genExtraAreas): put HOME first followed by GSINIT, STATIC and CSEG
5770         * support/Util/SDCCerr.c,
5771         * support/Util/SDCCerr.h: added E_BANKED_WITH_CALLEESAVES, registers are
5772           needed for passing the bank and address to the trampoline
5773         * device/lib/mcs51/crtbank.asm: added for bankswitching
5774         * device/lib/mcs51/Makefile: added crtbank
5775
5776 2005-07-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5777
5778         * src/SDCCcse.c (algebraicOpts): fixed loss of volatility
5779           for fields at offset 0 of a struct or union as reported
5780           on 2005-07-07 in the developer mailing list.
5781
5782 2005-07-15 Maarten Brock <sourceforge.brock AT dse.nl>
5783
5784         * src/SDCCmem.c: fixed bug 1238386
5785
5786 2005-07-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5787
5788         * src/mcs51/peeph.def: added labelrefcounting for peepholes
5789           (patch #1144962), added peephole 300, enabled 259.x
5790         * doc/sdccman.lyx: removed screenshot and provided link instead
5791
5792 2005-07-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5793
5794         * doc/sdccman.lyx: added section about debugging with ddd
5795         * doc/figures/ddd_example.eps: screenshot of debugging session
5796
5797 2005-07-04 Raphael Neider <rneider AT web.de>
5798
5799         * src/pic/gen.c (genPointerGet): handle pointers to CONST values
5800           like CODE pointers, fixes #1115683
5801         * src/pic/pcode.c (DoBankSelect): forget LastRegIdx during function
5802           call, fixes bugs #1232211, #1228110,
5803           fixed wrong casts to pCodeFlow from pCodeInstructions
5804
5805 2005-07-04 Raphael Neider <rneider AT web.de>
5806
5807         * src/pic/gen.c (popGet): changed assert to allow for
5808           bit operands
5809         * (popGetAddr): changed signature to provide
5810           an additional index, patched all call sites
5811         * (genCmpEq): handle literal-like operands correctly
5812         * (genAddrOf): added sanity checks on __code/__data pointers
5813         * (genAssign): added handling of symbols from __code section
5814         * (gencjne): do not generate code for comparisons whose result
5815           is neither stored nor used, fixes bug #1171114
5816         * (AccLsh, AccRsh): operate on operand instead of WREG
5817         * (shift{Left,Right}_Left2ResultLit): NEW, size independant
5818           replacement for Shift{LR}{12}Left2Result; shift (byte/int/long)
5819           by known count
5820         * rewrote complete shift-by-literal logic, commented unused
5821           functions out
5822         * (genConstPointerGet): get multiple bytes (if result size > 1),
5823           fixed handling of non-immediate addresses
5824         * (genPointerGet): handle CODE pointers like CONST pointers
5825         * (genpic14Code): insert C-SRC lines as Cource-pCodes
5826         * ({aop,op}_isLitLike): NEW, single place to decide whether an
5827           operand is to be treated as a literal or not
5828         * (mov2w,genPcall,genCmpEq),
5829           src/pic/genarith.c: use aop_isLitLike() to decide between
5830           literal/register contents
5831         * (addSign): added missing offset
5832         * src/pic/gen.h: remove newline after FENTRY/FEXIT comments,
5833           only emit comment in debug-mode,
5834           use {aop,op}_isLitLike throughout the file
5835         * src/pic/glue.c: fix initializers for pointers (work in progress)
5836         * src/pic/pcode.c (get_op): honor index on _const symbols
5837         * ({reset,dump}pCodeStatistics): NEW, estimate code size
5838         * (dumppBlock): added pCode size estimation
5839         * src/pic/ralloc.c (deassignLRs,serialRegAssign,packRegisters):
5840           check for IS_SYMOP before OP_SYMBOL'ing
5841         * fixed indentation, compacted switch-statements
5842         * (allocReg): find free register and allocate it instead of
5843           allocating new registers all the time
5844         * (deassignLRs): prevent POINTER_GET's from being assigned the same
5845           registers as its operands (necessary only for multibyte GETs)
5846
5847 2005-07-01 Raphael Neider <rneider AT web.de>
5848
5849         * src/pic/gen.h: added prototypes emitpComment, popGetAddr and
5850           debugging .asm-output macros FENTRY + FEXIT
5851         * src/pic/gen.c (Safe_vsnprintf): NEW, is there a more generic
5852           way... I wonder...
5853         * (emitpComment): NEW, printf to pCode
5854         * (popGet): added assert on too large offsets, fixed PO_IMMEDIATE's
5855           offset handling
5856         * (popGetAddr): NEW, variant of popGet to access an immediates
5857           high(er) bytes instead of the n'th byte of memory they reference,
5858           replaced popGet with popGetAddr where neccessary
5859         * (genDataPointerGet): reactivated and fixed implementation
5860         * (genNearPointerGet): enabled call to genDataPointerGet, fixes array-
5861           accesses
5862         * (genDataPointerSet): fixed multibyte assignments
5863         * (genpic14Code): fixed --i-code-in-asm handling
5864         * src/pic/genarith.c: fixed PO_IMMEDIATE issue using popGetAddr,
5865         * (genPlus): fixed index-out-of-bounds error
5866         * src/pic/pcode.c (get_op): fixed PO_IMMEDIATE's index/offset handling
5867         * src/pic/ralloc.c: added debugging output macro FENTRY2
5868         * (spillThis): fixed indentation, enbraced for-body for clarity
5869         * (rematStr): commented out as now unused
5870         * (regTypeNum): commented out special spill case (overwrites
5871           arbitrary values)
5872         * fixes bugs #1229346, #1216476 (both arrays) and #1115667 (SIGSEGV)
5873
5874 2005-06-30 Maarten Brock <sourceforge.brock AT dse.nl>
5875
5876         * doc/sdccman.lyx: documented sfr16/sfr32,
5877           added example for using storage class with function pointers
5878         * src/mcs51/gen.c (genPlusIncr): optimized small offsets from dptr
5879
5880 2005-06-28 Maarten Brock <sourceforge.brock AT dse.nl>
5881
5882         * device/lib/_gptrget.c: also push/pop _PSBANK, added # to 0x03
5883         * device/lib/_itoa.c,
5884         * device/lib/_ltoa.c: optimized codesize
5885         * src/SDCCsymt.c (checkSClass): added sanity check for sfr at addresses,
5886           but don't know how to suppress the double warning.
5887         * src/mcs51/gen.c (genPlusIncr): fixed bug when incrementing volatile int's
5888         * support/Util/SDCCerr.c,
5889         * support/Util/SDCCerr.h: added warning W_SFR_ABSRANGE for sanity check
5890
5891 2005-06-27 Maarten Brock <sourceforge.brock AT dse.nl>
5892
5893         * as/mcs51/asexpr.c (expr): disabled warning "not in .flat24 mode",
5894           fixed old K&R prototypes
5895         * as/mcs51/asout.c (outrb): always output as if generating 24bit addresses
5896         * device/lib/_gptrget.c,
5897         * device/lib/_gptrgetc.c,
5898         * device/lib/_gptrput.c: changed versions for new memory indicator values,
5899           also new versions for small generic pointers and banked generic pointers
5900         * src/port.h: added const_name
5901         * src/SDCC.lex: added keywords sfr16, __sfr16, sfr32, __sfr32
5902         * src/SDCC.y: added tokens SFR16, SFR32 and their sfr_attributes
5903         * src/SDCCcse.c (findPrevIc): check all associative operators
5904         * src/SDCCglue.c (emitMaps): use CONST_NAME if defined
5905         * src/SDCCicode.h: added macro IS_ASSOCIATIVE
5906         * src/SDCCmem.c: updated comments,
5907           set far-space to 0 for pdata, results in optimized code
5908         * src/SDCCmem.h: added macro CONST_NAME
5909         * src/SDCCsymt.h: renumerated generic pointer types GPTYPE_... thereby
5910           moving the info into the highest bits, see also gptrget/gptrput
5911         * src/src.dsp: added sdcc.ico to project files
5912         * src/avr/gen.c (genCast): fixed bug 0x%d
5913         * src/avr/main.c (avr_port): added "CONST (CODE)" for const_name
5914         * src/ds390/gen.c (aopForRemat, adjustArithmeticResult): disconnected direct
5915           relation between ptr_type and DCL_TYPE,
5916           (genCast): fixed bug 0x%d
5917         * src/ds390/main.c (ds390_port, tininative_port, ds400_port): added "CONST
5918           (CODE)" for const_name
5919         * src/hc08/gen.c (genCast): fixed bug 0x%d
5920         * src/hc08/main.c (_hc08_genAssemblerPreamble): added .area ...const_name,
5921           (hc08_port): added "CONST (CODE)" for const_name
5922         * src/mcs51/gen.c (aopForSym): optimized pushing ACC,
5923           (aopForRemat, adjustArithmeticResult): disconnected direct relation
5924           between ptr_type and DCL_TYPE,
5925           (aopGetUsesAcc, aopGet, aopPut): changed first parameter from asmop* to
5926           operand* and took AOP() inside function so sfr-ness can be checked,
5927           (all over): repaired calls to aopGetUsesAcc, aopGet, aopPut to comply with
5928           new prototype,
5929           (genFunction, genEndFunction): optimized stack setup,
5930           (genMinus): optimized for literals with ending zeroes (in bytes),
5931           (genCast): fixed bug 0x%d
5932         * src/mcs51/main.c (_mcs51_keywords): added sfr16 and sfr32,
5933           (mcs51_port): added "CONST (CODE)" for const_name
5934         * src/mcs51/peeph.def: made rule 226 more generic
5935         * src/pic/main.c (pic_port): added "CONST (CODE)" for const_name
5936         * src/pic16/main.c (pic16_port): added "CONST (CODE)" for const_name
5937         * src/xa51/main.c (xa51_port): added "CONST (CODE)" for const_name
5938         * src/z80/main.c (z80_port): added NULL for const_name,
5939           (gbz80_port): added NULL for const_name
5940         * support/regression/tests/bug663539.c,
5941         * support/regression/tests/sfr16.c: new tests
5942
5943 2005-06-25 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
5944
5945         * device/include/mcs51/p89v51rd2.h, device/include/mcs51/at89s53.h: added.
5946
5947 2005-06-24 Raphael Neider <rneider AT web.de>
5948
5949         * device/lib/pic16/libdev/pic18f[68][567]20.c:
5950           corrected typos...
5951         * device/include/pic16/signal.h: added USBIF
5952           and SIG_USB
5953
5954 2005-06-24 Raphael Neider <rneider AT web.de>
5955
5956         * device/lib/pic16/libdev/pic18f2455.c,
5957           device/include/pic16/pic18f2455.h: NEW
5958         * device/include/pic16/pic18fregs.h,
5959           device/lib/pic16/pics.all,
5960           src/pic16/device.c: added 18f2455
5961         * device/lib/pic16/libdev/pic18f[68][567]20.c,
5962           device/include/pic16/{pic18f[68][567].h,usart.h}:
5963           replaced MULTIPLE_USARTS define with more relaible
5964           compatibility sfrs (for USART access)
5965
5966 2005-06-20 Slade Rich <slade_rich AT users.sourceforge.net>
5967
5968         * src/pic/pcode.c : Fixed problem when a string constant contains a "\r\n"
5969           and the output asm file line is printed on two lines.
5970
5971 2005-06-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
5972
5973         * sim/ucsim/hc08.src/inst.cc (inst_condbranch): fixed simulation of
5974           BGT, BLE, BHI, and BLS instructions
5975         * src/hc08/gen.c (outAcc, outBitC, outBitNV, genCmpLt, genCmpGt,
5976           genCmpEq): removed
5977         * src/hc08/gen.c (genCmpEQorNE, genCmp, branchopCmp, nameCmp,
5978           negatedCmp, exchangedCmp, genhc08Code): rewrite of comparison handling,
5979           fixes bug #1216342
5980         * src/hc08/peeph.def: added rules 2g - 2l for new conditional branches
5981
5982 2005-06-15 Raphael Neider <rneider AT web.de>
5983
5984         * src/pic16/NOTES: moved Vangelis from active developers to people to contact
5985         * device/include/pic16/{6520.h,8520.h}: fixed configuration bits
5986         * src/pic16/gen.c (): prevent iTemps from being considered to be in CODESPACE,
5987           fixes bug #1221120; for symbols in CODESPACE get number of bytes to read from
5988           OP_SYM_TYPE() instead of OP_SYM_ETYPE()
5989
5990 2005-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
5991
5992         * device/include/mcs51/reg764.h: Changed PB0 to PBO as requested by
5993           Marcel Telka in bug #1215704
5994
5995 2005-06-02 Slade Rich <slade_rich AT users.sourceforge.net>
5996
5997         * src/pic/pcode.c : Changed pseudo stack size to 15 to allow WSAVE to be
5998           located in shared memory bank.
5999
6000 2005-05-31 Raphael Neider <rneider AT web.de>
6001
6002         * src/pic16/{gen.c,genarith.c}: replaced sign-extension
6003           "CLRF, BTFSC <signbit>, DECF/COMF" with side-effect-free
6004           "CLRF, BTFSC <signbit>, SETF"; fixes "long>>9"
6005
6006 2005-05-27 Maarten Brock <sourceforge.brock AT dse.nl>
6007
6008         * device/lib/_strncpy.c: fixed the fix
6009
6010 2005-05-26 Raphael Neider <rneider AT web.de>
6011
6012         * src/pic16/glue.c (pic16_printIvalChar): fixed _constant_ string
6013           initializers with \0, bug #1208187
6014         * src/pic/glue.c (printIvalChar): fixed (non- and constant) string
6015           intializers with \0, bug #1208187
6016
6017 2005-05-26 Raphael Neider <rneider AT web.de>
6018
6019         * src/pic16/glue.c (pic16_printIvalChar): fixed string
6020           initializers with \0, bug #1208187
6021         * src/pic16/main.c (_process_pragma): added sanity checks
6022           for stack position and size, emit warnings when appropriate
6023
6024 2005-05-26 Maarten Brock <sourceforge.brock AT dse.nl>
6025
6026         * device/lib/_strncpy.c: fixed not filling with \0
6027
6028 2005-05-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6029
6030         * src/SDCCast.c (funcOfType, funcOfTypeVarg, stringToSymbol,
6031           createFunction),
6032         * src/SDCC.y (external_definition, enumerator, parameter_declaration,
6033           compound_statement),
6034         * src/SDCCsymt.h,
6035         * src/SDCCsymt.c (addSymChain, processFuncArgs): fixed bug #1159134
6036
6037 2005-05-24 Raphael Neider <rneider AT web.de>
6038
6039         * src/pic16/glue.c (pic16_printGPointerType): fixed #1207796
6040
6041 2005-05-24 Raphael Neider <rneider AT web.de>
6042
6043         * device/include/pic16/pic18f{442,452,458}.h: fixed wrong
6044           TRISE definitions, closes bug #1162453
6045
6046 2005-05-22 Raphael Neider <rneider AT web.de>
6047
6048         * src/pic16/main.c (_process_pragma): check for missing
6049           arguments to pragmas code and udata
6050         * device/include/pic16/pic18f{2550,4331,4455,4520}.h:
6051           consistency fixes to match other headers (thanks to Jim Paris)
6052         * device/lib/pic16/libio/i2c.ignore: 18f4331 provides no I2C
6053
6054 2005-05-21 Maarten Brock <sourceforge.brock AT dse.nl>
6055
6056         * src/SDCCicode.c (isOperandEqual): fixed missing ;
6057
6058 2005-05-19 Maarten Brock <sourceforge.brock AT dse.nl>
6059
6060         * support/regression/tests/bug1198642.c: new test
6061         * src/SDCCicode.c (isOperandEqual): fixed bug 1198642
6062         * src/SDCCcse.c (findPrevIc): added comment, please have a look
6063         * support/scripts/resource.h,
6064         * support/scripts/resource.rc,
6065         * src/src.dsp: added sdcc.ico to project as icon for sdcc.exe
6066         * support/scripts/sdcc.ico: added 32x32 icon
6067
6068 2005-05-18 Raphael Neider <rneider AT web.de>
6069
6070         * device/lib/pic16/libdev/pic18f*.c,
6071         * device/include/pic16/pic18f*.h: updated "sfr" and "at X"
6072           keywords to "__sfr" and "__at (X)"
6073         * device/include/pic16/pic18fregs.h: added pic18f4520
6074         * src/pic16/pcode.c (pic16_pCode2str): fixed (?) bug
6075           #1203088 (MPLAB compatibility)
6076
6077 2005-05-17 Raphael Neider <rneider AT web.de>
6078
6079         * device/include/pic16/pic18f{2550,4331,4455,4520}.h: NEW
6080         * device/lib/pic16/libdev/pic18f{2550,4331,4455,4520}.c: NEW
6081         * device/lib/pic16/pics.all: added new devices
6082         * src/pic16/device.c: added support for pic18f4520
6083
6084 2005-05-16 Raphael Neider <rneider AT web.de>
6085         * src/pic16/gen.{c,h}: s/mov2f/pic16_mov2f made public
6086         * src/pic16/genarith.c (genAddLit): fixed bug 1202480
6087         * src/pic16/pcode.{c,h} (pic16_newpCodeOpBit_simple): NEW
6088           convenience function for bit access
6089
6090 2005-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
6091
6092         * device/lib/printf_large.c: fixed bug 1193299
6093         * support/regression/tests/bug1057979.c: added test %3.3s
6094
6095 2005-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6096
6097         * device/include/mcs51/8051.h,
6098         * device/include/mcs51/8052.h: made parseable with lint
6099         * device/include/mcs51/lint.h: added include file for (sp)lint
6100         * doc/sdccman.lyx: added doc about use of splint (syntax checking tool)
6101         * doc/cdbfileformat.lyx,
6102         * doc/test_suite_spec.lyx: hardcoded date to the date of last text change
6103
6104 2005-05-14 Raphael Neider <rneider AT web.de>
6105
6106         * device/lib/pic16/Makefile.common.in: add --optimize-df to OPT_FLAGS
6107         * device/lib/pic16/libc/stdlib/itoa.c (new)
6108         * device/lib/pic16/libc/stdlib/Makefile: have itoa.c built
6109         * device/lib/pic16/libio/Makefile: exclude subdir according to
6110           ${subdir}.ignore for certain PICs (lacking e.g. i2c)
6111         * device/lib/pic16/libio/i2c.ignore (new): pic18f1220 has no I2C support
6112         * src/pic16/gen.c (genFunction): prevent annoying warning
6113         * src/pic16/pcode.c: renamed stack_t to dynstack_t to prevent
6114           nameclashes on BeOS
6115         * support/cpp2/cppmain.c (cpp_output_string): new
6116         * support/cpp2/cpplib.c (_cpp_do__Pragma): fixed _Pragma(""),
6117           fixes bug 1116802
6118
6119 2005-05-13 Borut Razem <borut.razem AT siol.net>
6120
6121         * src/SDCCmain.c (linkEdit): fixed bug 1195202
6122
6123 2005-05-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6124
6125         * .version: changed to version 2.5.1; back to bleeding edge development
6126
6127 2005-05-11 Borut Razem <borut.razem AT siol.net>
6128
6129         * doc/sdccman.lyx doc/cdbfileformat.lyx doc/test_suite_spec.lyx:
6130           generate PDF version 1.3 documents
6131
6132 2005-05-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6133
6134         * .version: changed to version 2.5.0
6135
6136 2005-04-27 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6137
6138         * doc/sdccman.lyx: updated weblinks, index and smaller updates
6139
6140 2005-04-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6141
6142         * doc/sdccman.lyx: changed version 2.5.0, documented --std-c89,
6143         --std-sdcc89, --std-c99, --std-sdcc99, and the corresponding #pragmas, as
6144         well as many smaller updates.
6145         * .version: changed to version 2.5.0-pre1
6146
6147 2005-04-26 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
6148
6149         * src/SDCCmain.c (setIncludePath): added port->target to SDCC_INCLUDE_NAME
6150
6151 2005-04-26 Maarten Brock <sourceforge.brock AT dse.nl>
6152
6153         * support/regression/tests/bug1185672.c: added
6154         * src/mcs51/gen.c (aopGetUsesAcc, genCpl, genAnd, genOr, genXor): fixed
6155           bug 1185672
6156         * src/mcs51/gen.c (genCall): added comments, made it look safer
6157         * src/mcs51/gen.c (genEndFunction): simplified
6158
6159 2005-04-25 Maarten Brock <sourceforge.brock AT dse.nl>
6160
6161         * src/mcs51/ralloc.c (serialRegAssign): fixed bug 1189609
6162
6163 2005-04-14 Borut Razem <borut.razem AT siol.net>
6164
6165         * fixed bug 1045046 - SIGSEGV with really simple code?:
6166           src/pic/pcode.c (pCodeInitRegisters)- pseudo stack size increased to 16
6167           src/pic/ralloc.c (typeRegWithIdx) - error message on pseudo stack overflow
6168
6169 2005-04-14 Borut Razem <borut.razem AT siol.net>
6170
6171         * src/pic16/gen.c (genInline), src/pic16/main.c (_process_pragma),
6172           src/pic16/device.h: temporarily disabled experimental #inline pragma
6173           for 2.5.0 release
6174
6175 2005-04-14 Maarten Brock <sourceforge.brock AT dse.nl>
6176
6177         * device/include/z80/stdio.h,
6178         * device/include/z80/string.h: removed these highly incomplete files so
6179           SDCC can use the default ones in device/include/
6180
6181 2005-04-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6182
6183         * src/mcs51/gen.c (genEndFunction): removed unused variable to fix
6184         gcc warning.
6185         * device/lib/Makefile.in: default PORTINCDIR to the mcs51 subdir to
6186         fix sdcpp warnings.
6187
6188 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
6189
6190         * device/include/malloc.h: removed redundant __reentrant prototypes
6191         * device/lib/_mullong.c: added working xstack variant in asm (C version
6192           doesn't pass regression tests)
6193         * device/lib/bpx.c: used __data and made bpx char for mcs51
6194         * src/SDCCast.c (decorateType): removed unused GPTYPE_IDATA,
6195           (createFunction): fixed bug with xstackPtr
6196         * src/SDCCcse.c: corrected comments
6197         * src/SDCCopt.c (convertToFcall): fixed warning in MSVC,
6198           (killDeadCode, eBBlockFromiCode): removed unused code
6199         * src/SDCCsymt.h: removed unused GPTYPE_GPTR and GPTYPE_IDATA,
6200           corrected comments
6201         * src/mcs51/gen.c (aopForSym, aopPut, toBoolean, unsaveRegisters,
6202           assignResultValue, genCall, genFunction, genEndFunction, genAnd,
6203           genOr, genXor, genAddrOf): fixed several bugs concerning xstack
6204           (genModOneByte): fixed warning in MSVC
6205         * src/mcs51/main.c (): added comments
6206         * src/mcs51/peeph.def: changed 129 to 129.a, added 129.b, 129.c & 129.d
6207
6208 2005-04-12 Maarten Brock <sourceforge.brock AT dse.nl>
6209
6210         * src/SDCCmain.c (linkEdit): oops, changed one line too many
6211
6212 2005-04-11 Maarten Brock <sourceforge.brock AT dse.nl>
6213
6214         * src/SDCCmain.c (linkEdit): fixed bug with finding crt0.o for z80
6215
6216 2005-04-10 Vangelis Rokas <vrokas AT users.sourceforge.net>
6217
6218         * src/pic16/glue.c (printIvalChar): fixed bug when emitting
6219         characters arrays of larger size than the declared one.
6220
6221 2005-04-10 Borut Razem <borut.razem AT siol.net>
6222
6223         * src/pic/gen.c (genInline),
6224           src/pic/pcode.c (newpCodeAsmDir), (pCode2str),
6225           (genericPrint), (unlinkpCodeFromBranch), (compareLabel),
6226           (findNextInstruction), (findPrevInstruction),
6227           (findInstructionUsingLabel),
6228           src/pic/pcode.h: fixed bug #1164907 - Labels not being recognized
6229         * src/pic/pcode.c (findLabel): added missing '\n'
6230         * src/src.dsp: added SDCCdwarf2.c to the project
6231
6232 2005-04-09 Borut Razem <borut.razem AT siol.net>
6233
6234         * support/scripts/sdcc.nsi: added include/hc08/* h to NSIS setup
6235
6236 2005-04-08 Raphael Neider <rneider AT web.de>
6237
6238         * src/pic16/pcode.c: added helpers defmapInsertAfter (insert a new item
6239           into the chain after a given one) and mergeDefmapSymbols (combine
6240           defmap entries for each symbol per pcode)
6241         * (createDefmap): have defmap entries merged in the end
6242         * (defmapReplaceSymRef): split defmap entries covering two accesses to
6243           a symbol before replacing one access type's symbol, merge symbols in
6244           the end (replacement symbol might already have an entry)
6245         * (assignValnums): keep reference to written WREG intact
6246
6247 2005-04-08 Raphael Neider <rneider AT web.de>
6248
6249         * src/pic16/pcode.c (struct defmap_s): named anonymous union (for
6250           Alpha)
6251
6252 2005-04-08 Vangelis Rokas <vrokas AT users.sourceforge.net>
6253
6254         * src/pic16/pcode.c (pic16_get_op2): enlarged size of array b to 128
6255         bytes
6256
6257 2005-04-07 Raphael Neider <rneider AT web.de>
6258
6259         * device/include/pic16/usart.h: added compatibility defines for
6260           devices with more than one USART
6261         * device/include/pic16/pic18f[68][567]20.h: activated above defines
6262
6263 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
6264
6265         * device/lib/Makefile.in: updated for port specific include
6266
6267 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
6268
6269         * support/regression/ports/mcs51/spec.mk: added mcs51 include
6270
6271 2005-04-07 Maarten Brock <sourceforge.brock AT dse.nl>
6272
6273         * device/include/8051.h,
6274         * device/include/8052.h,
6275         * device/include/at89S8252.h,
6276         * device/include/at89c55.h,
6277         * device/include/at89x051.h,
6278         * device/include/at89x51.h,
6279         * device/include/at89x52.h,
6280         * device/include/mcs51reg.h,
6281         * device/include/reg51.h,
6282         * device/include/reg764.h,
6283         * device/include/regc515c.h,
6284         * device/include/sab80515.h: (re)moved these 12 files
6285         * device/include/mcs51/8051.h,
6286         * device/include/mcs51/8052.h,
6287         * device/include/mcs51/at89S8252.h,
6288         * device/include/mcs51/at89c55.h,
6289         * device/include/mcs51/at89x051.h,
6290         * device/include/mcs51/at89x51.h,
6291         * device/include/mcs51/at89x52.h,
6292         * device/include/mcs51/mcs51reg.h,
6293         * device/include/mcs51/reg51.h,
6294         * device/include/mcs51/reg764.h,
6295         * device/include/mcs51/regc515c.h,
6296         * device/include/mcs51/sab80515.h: and added them here
6297
6298 2005-04-06 Maarten Brock <sourceforge.brock AT dse.nl>
6299
6300         * device/include/stdarg.h: changed SDCC specific keywords to double
6301           underlined form.
6302         * device/include/stdint.h: changed intptr_t and uintptr_t for others than
6303           mcs51 and ds390.
6304         * device/include/hc08/mc68hc908gp32.h,
6305         * device/include/hc08/mc68hc908jb8.h,
6306         * device/include/hc08/mc68hc908jkjl.h,
6307         * device/include/hc08/mc68hc908qy.h: fixed comments
6308         * device/include/mcs51/README: updated
6309         * device/include/mcs51/c8051f120.h: added PINRSF
6310         * device/lib/pic16/libc/stdlib/crc16.c: fixed comments
6311         * src/pic16/pcode.c: MSVC6 doesn't accept declaring new variables
6312           amidst code. Also inline is not supported.
6313
6314 2005-04-06 Raphael Neider <rneider AT web.de>
6315
6316         * src/pic16/pcode.c (pic16_pCodeReplace): also update pcflow->end
6317         * (createDefmap): fixed CALLs to depend on FSR1 and RETLW to restore
6318           callers stack/frame pointers
6319
6320 2005-04-06 Vangelis Rokas <vrokas AT users.sourceforge.net>
6321
6322         * device/include/pic16/usart.h: added, missing in previous commit,
6323         * device/include/pic16/adc.h: fixed typo,
6324         * device/lib/pic16/libc/utils/cvtdec.S: added missing in previous
6325         commit,
6326         * device/lib/pic16/libc/stdlib/g_ftoa.S: modified to include
6327         <p18fxxx.inc>
6328         * device/lib/pic16/libc/stdio/streams.c: leave stdin, stdout
6329         uninitialized because a bug appears with gplink
6330         * device/lib/pic16/{some makefiles}: moved $(CSTD) from CFLAGS to
6331         COMPILE_FLAGS and added CPPFLAGS with -nostdinc because sdcpp
6332         complains for unrecognised option
6333
6334 2005-04-05 Raphael Neider <rneider AT web.de>
6335
6336         * src/pic16/gen.c (pic16_popCopyReg): made copying work for extended
6337           structs as well (using memcpy)
6338         * (genFunction): fixed comparison, used pCodeOpLabel to reduce warning
6339           on ISRs (GOTO has no label)
6340         * src/pic16/device.h: added OF_OPTIMIZE_DF
6341         * src/pic16/main.c: added compiler switch --optimize-df to enable the
6342           new data flow analysis/optimization
6343         * src/pic16/pcode.c: added (prototypes for and implementation of)
6344           dataflow analysis functions, fixed pCodeInstructions' inCond and
6345           outCond values, made RCALL a branch instruction
6346         * (pic16_unlinkpCode): keep C line if possible
6347         * (pic16_pCodeUnlink): removed cast on left side of assignment, have
6348           C line moved if possible
6349         * (pic16_getRegFrompCodeOp): NEW, improved version of...
6350         * (pic16_getRegFromInstruction,pic16_getRegFromInstruction2): changed
6351           to use new pic16_getRegFrompCodeOp (works for more SFRs)
6352         * (pic16_BuildFlow): fixed skip instructions with label (did not start
6353           new flow)
6354         * (pic16_getJumptabpCode): NEW, needed in...
6355         * (LinkFlow): fixed handling of jumptables, calls and conditional
6356           branches
6357         * (pic16_InsertCommentAfter): NEW
6358         * (pic16_pCodeReplace): made verbose and flow preserving
6359         * (AnalyzeFlow): added call to data flow analysis
6360         * src/pic16/pcode.h: added defmaps to pCodeFlow struct
6361         * src/pic16/pcodeflow.h: added PCC_STATUS to mean all STATUS bits
6362         * src/pic16/ralloc.c (packRegsForAssign): added return 1 in the end
6363
6364 2005-04-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6365
6366         * src/SDCCast.c (decorateType): fixed bug #1105626
6367
6368 2005-04-02 Vangelis Rokas <vrokas AT users.sourceforge.net>
6369
6370         * device/include/asm/pic16/features.h,
6371         * pic18f*.h headers,
6372         * device/include/pic16/adc.h,
6373         * device/include/pic16/delay.h,
6374         * device/include/pic16/i2c.h,
6375         * device/include/pic16/malloc.h,
6376         * device/include/pic16/stdio.h,
6377         * device/include/pic16/stdlib.h,
6378         * device/include/pic16/string.h,
6379         * device/lib/pic16/libc/stdio/printf_tiny.c,
6380         * device/lib/pic16/libc/stdio/printf_small.c,
6381         * device/lib/pic16/libc/stdio/strmgpsim.c,
6382         * device/lib/pic16/libc/stdio/strmmssp.c,
6383         * device/lib/pic16/libc/stdio/strmusart.c,
6384         * device/lib/pic16/libc/stdio/vfprintf.c,
6385         * device/lib/pic16/libc/stdlib/ltoa.c,
6386         * device/lib/pic16/libc/stdlib/putchar.c,
6387         * device/lib/pic16/libc/stdlib/x_ftoa.c,
6388         * device/lib/pic16/libc/stdlib/memchrpgm.c,
6389         * device/lib/pic16/libc/stdlib/memchrram.c,
6390         * device/lib/pic16/libc/stdlib/memcpypgm2ram.c,
6391         * device/lib/pic16/libc/stdlib/memcpyram2ram.c,
6392         * device/lib/pic16/libio/adc/adcbusy.c,
6393         * device/lib/pic16/libio/adc/adcread.c,
6394         * device/lib/pic16/libio/adc/adcsetch.c,
6395         * device/lib/pic16/libio/usart/ubaud.c,
6396         * device/lib/pic16/libio/usart/ubusy.c,
6397         * device/lib/pic16/libio/usart/udrdy.c,
6398         * device/lib/pic16/libio/usart/uopen.c,
6399         * device/lib/pic16/libio/usart/uputc.c,
6400         * device/lib/pic16/libsdcc/gptr/gptrget1.c,
6401         * device/lib/pic16/libsdcc/gptr/gptrget2.c,
6402         * device/lib/pic16/libsdcc/gptr/gptrget3.c,
6403         * device/lib/pic16/libsdcc/gptr/gptrget4.c,
6404         * device/lib/pic16/libsdcc/gptr/gptrput1.c,
6405         * device/lib/pic16/libsdcc/gptr/gptrput2.c,
6406         * device/lib/pic16/libsdcc/gptr/gptrput3.c,
6407         * device/lib/pic16/libsdcc/gptr/gptrput4.c: modified all SDCC
6408         specific keywords to double underlined form,
6409         * device/lib/pic16/libc/Makefile.rules,
6410         * device/lib/pic16/libsdcc/Makefile.rules,
6411         * device/lib/pic16/libm/Makefile,
6412         * device/lib/pic16/libio/Makefile.rules: added CSTD macro in CFLAGS
6413         to compile with C standard set in Makefile.common
6414         * device/lib/pic16/libc/stdlib/Makefile: added new C sources
6415         rand.c and crc.c in compilation process,
6416         * device/lib/pic16/libsdcc/int/divuint.c,
6417         * device/lib/pic16/libsdcc/long/divulong.c: changed declaration of
6418         `c' from signed to unsigned,
6419         * device/lib/pic16/startup/crt0.c,
6420         * device/lib/pic16/startup/crt0i.c,
6421         * device/lib/pic16/startup/crt0iz.c: adopted to all SDCC specific
6422         keywords to double underlined form, bug fixes in _do_cinit function
6423         which prevented the correct initialization of the .idata segment,
6424         * src/pic16/pcoderegs.c (insideLRBlock): fixed a bug that caused the
6425         core to enter a infinite loop
6426         * device/lib/pic16/libc/stdlib/rand.c, crc.c: new files
6427
6428 2005-04-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6429
6430         * src/SDCCicode.c (getArraySizePtr): fixed bug #1122171
6431
6432 2005-04-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6433
6434         * device/include/Makefile.in: add support for hc08 subdirectory
6435         * device/include/hc08/: new subdirectory
6436         * device/include/hc08/mc68hc908jkjl.h: new header contributed by
6437         Lucas Loizaga, thanks!
6438         * device/include/hc08/mc68hc908qy.h,
6439         * device/include/hc08/mc68hc908gp32.h,
6440         * device/include/hc08/mc68hc908jb8.h: moved hc08 register defs to
6441         their own directory. Changed internal macro names to use the compiler
6442         reserved namespace. Changed SDCC specific keywords to double
6443         underlined form.
6444         * device/include/math.h,
6445         * device/include/malloc.h,
6446         * device/include/stdarg.h,
6447         * device/include/stdbool.h
6448         * device/include/string.h,
6449         * device/include/tinibios.h,
6450         * device/include/ds400rom.h,
6451         * device/include/8051.h,
6452         * device/include/8052.h,
6453         * device/include/80c51xa.h,
6454         * device/include/at89c55.h,
6455         * device/include/at89S8252.h,
6456         * device/include/at89x51.h,
6457         * device/include/at89x52.h,
6458         * device/include/ds80c390.h,
6459         * device/include/reg764.h,
6460         * device/include/regc515c.h,
6461         * device/include/sab80515.h,
6462         * device/include/mcs51/c8051f000.h,
6463         * device/include/mcs51/c8051f018.h,
6464         * device/include/mcs51/c8051f020.h,
6465         * device/include/mcs51/c8051f040.h,
6466         * device/include/mcs51/c8051f060.h,
6467         * device/include/mcs51/c8051f120.h,
6468         * device/include/mcs51/c8051f300.h,
6469         * device/include/mcs51/c8051f310.h,
6470         * device/include/mcs51/c8051f320.h,
6471         * device/include/mcs51/c8051f330.h,
6472         * device/include/mcs51/c8051f350.h,
6473         * device/include/z180.h: Changed SDCC specific keywords to double
6474         underlined form.
6475
6476 2005-03-31 Vangelis Rokas <vrokas AT users.sourceforge.net>
6477
6478         * src/pic16/device.c (Pics16[]): added devices 18F2550, 18F4331,
6479         18F4455,
6480         * (pic16_assignConfigWordValue): disable testing of configuration
6481         register value with config mask,
6482         * src/pic16/gen.c (pic16_testStackOverflow): prefix stack test
6483         function with port->fun_prefix,
6484         * (genFunction): when generating a naked interrupt function never
6485         create an absolute segment placed in interrupt vector address, place
6486         the actual interrupt function at IVA instead, when an interrupt
6487         function is generated with unspecified interrupt then do not create
6488         the absolute section,
6489         * (genGenPointerGet, genGenPointerSet, genPackBits): replace all
6490         code for generating a call to generic pointer get/put function with
6491         a call to function pic16_callGenericPointer(),
6492         * src/pic16/genutils.c (pic16_callGenericPointerRW): NEW, generates
6493         the call to the generic pointer get/put functions with prefixing the
6494         function name with port->fun_prefix,
6495         * src/pic16/glue.c (pic16glue): ifdef-out test of OF_LR_SUPPORT,
6496         * src/pic16/main.c (_process_pragma): prefix function with
6497         port->fun_prefix,
6498         * (_pic16_finaliseOptions): define macro __18Fxxxx macro when
6499         calling assembler, old 18Fxxxx macro is deprecated,
6500         * src/pic16/pcode.c (unlinkpCodeFromBranch): added PC_INLINE and
6501         PC_ASMDIR in while condition,
6502         * (findInstruction): add PC_ASMDIR in while condition,
6503         * (buildCallTree): prefix main with port->fun_prefix,
6504         * (pic16_pCode2str): fixed bug that didn't emit the memory access
6505         identifier for variable with banked access in instructions BTFSS,
6506         BTFSC, BCF, BSF, BTG
6507         * (AnalyzeFlow): moved call to OptimizepCode to pic16_AnalyzeBanking,
6508         * src/pic16/pcodepeep.c (pCodeOpCompare): increase size of b to 1024,
6509         * src/pic16/pcoderegs.c (pic16_pCodeRegoptimizeRegUsage): don't
6510         perform optimization when enviroment variable NO_REG_OPT is set,
6511         * (insideLRBlock): NEW, return 1 if register is inside an
6512         INF_LOCALREGS block,
6513         * (RemoveRegFromLRBlock): remove a register that is completely
6514         eliminated by register optimization, but it is still left in local
6515         register store/restore in/from stack block,
6516         * (Remove2pcodes): after removing register, check to see if it
6517         should be removed from local register store/restore in/from stack
6518         block,
6519         * src/pic16/ralloc.c (pic16_decodeOp): added decode for
6520         DUMMY_READ_VOLATILE,
6521
6522         * device/include/pic16/adc.h: minor prototype modifications and
6523         update,
6524         * device/include/pic16/malloc.h: added GPL notice various
6525         modifications,
6526         * device/include/pic16/stdint.h: NEW, standard header for ints
6527         * device/include/pic16/delay.h: NEW, header for delay functions,
6528         delay10tcy, delay100tcy, delay1ktcy, delay10ktcy, delay100ktcy,
6529         delay1mtcy,
6530         * device/include/pic16/signal.h: NEW, header providing helper macros
6531         for implementing signal handlers,
6532         * device/include/pic16/stdio.h: added prototypes for functions,
6533         printf, vprintf, sprintf, vsprintf, fprintf, vfprintf. Added
6534         prototypes for stdin and stdout, added macro PUTCHAR to
6535         automatically implement putchar function prototype,
6536         * device/include/pic16/usart.h: modified and updated USART library,
6537         * device/lib/pic16/libio/adc/,
6538         * device/lib/pic16/libio/i2c: some modifications to improve library
6539         performance,
6540         * device/lib/pic16/libc/stdio/: modifications for the new printf*
6541         family of functions,
6542         * device/lib/pic16/libc/stdlib/: various modifications in the malloc
6543         family of functions and other sources,
6544         * device/lib/pic16/libio/usart/: NEW, c sources for the usart module
6545         of the PIC18Fxx[28] devices,
6546         * device/lib/pic16/libc/delay/: NEW, c sources for the delay functions,
6547         * device/lib/pic16/libc/utils/: minor modifications in the .S sources,
6548         * device/lib/pic16/startup/{crt0i.c, crt0iz.c}: redesign of the
6549         _do_cinit function, because the previous failed when local variables
6550         where not placed in the same memory bank,
6551         * device/lib/pic16/libsdcc/char/: various modifications to improve
6552         library performance,
6553         * doc/sdccman.lyx: some reorganization of the PIC16 part, added many
6554         information on the new functions of the c library and more...
6555
6556 2005-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6557
6558         * src/SDCCBBlock.c (iCodeBreakDown): fixed bug #1170212
6559
6560 2005-03-26 Raphael Neider <rneider AT web.de>
6561
6562         * src/pic16/gen.c (genSkipc): fixed semantics (execute branch
6563           if condition == CARRY)
6564         * (genCmp): adapted to new genSkipc semantics
6565         * src/pic16/genutils.c (pic6_genCmp_special): removed side effect
6566           on rIfx (genCmp was broken)
6567
6568 2005-03-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6569
6570         * src/SDCCmain.c (setDefaultOptions, optionsTable[], parseCmdLine),
6571         * src/z80/main.c (_keywords[]),
6572         * src/SDCCglobal.h (struct options),
6573         * src/SDCC.y,
6574         * src/SDCC.lex (isTargetKeyword, doPragma, pragma_tbl[]): new pragmas
6575         to enable/disable SDCC and C99 extensions/keywords (std_c89, std_sdcc89,
6576         std_c99, std_sdcc99). Also, equivalent command line options (--std-c89,
6577         --std-sdcc89, --std-c99, --std-sdcc99). SDCC specific keywords are
6578         always available in leading double underscore form. The C99 support is
6579         mostly missing, but it's a start.
6580         * support/regression/tests/bug-227710.c: fixed nonconforming use of
6581         reserved identifier "__data".
6582
6583 2005-03-24 Maarten Brock <sourceforge.brock AT dse.nl>
6584
6585         * src/mcs51/peeph.def: fixed bug 1170013
6586
6587 2005-03-22 Maarten Brock <sourceforge.brock AT dse.nl>
6588
6589         * device/include/mcs51reg.h: fixed bug 842007
6590
6591 2005-03-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6592
6593         * src/SDCCcflow.c (dfNumCompare): committed the wrong version of this
6594         last time.
6595
6596 2005-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6597
6598         * src/port.h (struct PORT),
6599         * src/avr/ralloc.c (avr_assignRegisters),
6600         * src/avr/main.c,
6601         * src/ds390/ralloc.c (ds390_assignRegisters),
6602         * src/ds390/main.c,
6603         * src/hc08/ralloc.c (hc08_assignRegisters),
6604         * src/hc08/main.c,
6605         * src/mcs51/ralloc.c (mcs51_assignRegisters),
6606         * src/mcs51/main.c,
6607         * src/pic/ralloc.c (pic14_assignRegisters),
6608         * src/pic/main.c,
6609         * src/pic16/ralloc.c (pic16_assignRegisters),
6610         * src/pic16/main.c,
6611         * src/xa51/ralloc.c (xa51_assignRegisters),
6612         * src/xa51/main.c,
6613         * src/z80/ralloc.c (z80_assignRegisters),
6614         * src/z80/ralloc.h,
6615         * src/SDCCopt.c (eBBlockFromiCode, replaceRegEqv, killDeadCode),
6616         * src/SDCCcse.c (ifxOptimize, cseBBlock, cseAllBlocks),
6617         * src/SDCCcse.h,
6618         * src/SDCCdflow.c (computeDataFlow),
6619         * src/SDCCdflow.h,
6620         * src/SDCCloop.c (addDefInExprs, loopInvariants, loopOptimizations),
6621         * src/SDCCloop.h,
6622         * src/SDCCcflow.c (*),
6623         * src/SDCCcflow.h,
6624         * src/SDCCBBlock.c (iCodeBreakDown, dumpEbbsToFileExt, eBBWithEntryLabel),
6625         * src/SDCCBBlock.h (struct ebbIndex): new struct that keeps two copies
6626         of the eBBlock list, sorted by both bbnum and dfnum. (fixes bug with
6627         immedDom() returning wrong block; probably fixes bug #1160833)
6628
6629 2005-03-20 Borut Razem <borut.razem AT siol.net>
6630
6631         * support/scripts/inc2h.pl: WIN32 port
6632
6633 2005-03-19 Maarten Brock <sourceforge.brock AT dse.nl>
6634
6635         * device/lib/makefile.in: added abs.c and labs.c
6636
6637 2005-03-17 Maarten Brock <sourceforge.brock AT dse.nl>
6638
6639         * device/include/stdint.h: added
6640         * device/lib/abs.c: added
6641         * device/lib/labs.c: added
6642         * device/include/stdlib.h: added abs() and labs() prototypes
6643         * device/lib/libsdcc.lib: added abs and labs
6644         * device/include/float.h,
6645         * device/lib/_fsmul.c,
6646         * device/lib/printf_fast.c,
6647         * device/lib/printf_tiny.c: updated comments
6648
6649 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6650
6651         * src/SDCCicode.c (geniCodeSwitch, geniCodeJumpTable): fixed
6652         bug #1164313
6653
6654 2005-03-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6655
6656         * src/SDCCcse.c (cseBBlock): retain assignment to self when volatile
6657         * src/SDCCast.c (isLoopCountable): fixed bug #1161985
6658
6659 2005-03-15 Maarten Brock <sourceforge.brock AT dse.nl>
6660
6661         * device/lib/printf_large.c: removed inline assembly for portability and
6662           readability. Use printf_fast if speed or size are more important.
6663         * src/pic16/gen.c: removed conditions around use of DEBUGpc
6664         * src/pic16/genutils.h: added define for DEBUGpc for MSVC
6665
6666 2005-03-15 Vangelis Rokas <vrokas AT users.sourceforge.net>
6667
6668         * src/pic16/genutils.c (pic16_genCmp_special): initialized offs to
6669         prevent compiler warning
6670
6671 2005-03-14 Vangelis Rokas <vrokas AT users.sourceforge.net>
6672
6673         * device/lib/pic16/startup/crt0i.c (_cinit): local variables where
6674         moved to level 0 and declared as static. Also they are explicit
6675         placed in access bank. This was necessery because some times they
6676         might cross memory bank boundaries. crt0iz.c is *NOT* updated!!!
6677         * src/pic16/device.h: added flag OPTIMIZE_CMP to enable some compare
6678         optimizations. Currently only compare to unsigned char is implemented,
6679         * src/pic16/gen.c: added fReturnIdx array,
6680         * (struct resolvedIfx) is moved to gen.h and made public,
6681         * (struct _G): added sregsAlloc and sregsAllocSet fields,
6682         * (aopForSym): added an optimization to directly store in stack of
6683         the operand of a SEND iCode,
6684         * (pic16_aopOp): don't return return registers as strings (AOP_STR)
6685         but as registers instead (AOP_REG) using the fReturnIdx array,
6686         * (pic16_freeAsmop): remove the freed register from the
6687         _G.sregsAlloc field,
6688         * (pic16_aopGet): in case AOP_STR, the compare to 'a' is changed to
6689         a compare of 'WREG',
6690         * (pic16_popGetTempRegCond): changed function prototype, now
6691         function takes also a bitVector argument v which holds the current
6692         set of registers that are allocated for stack access by aopForSym,
6693         registers allocated in aopForSym for accessing stack symbols are not
6694         any more part of the functions usedRegs field,
6695         * (genCall): some times aopOp is called for a stack variable to be
6696         send, aopForSym might perform the push, if this is true make sure
6697         that genCall doesn't push the variable twice by testing _G.resDirect,
6698         * (genFunction): changed testing for unspecified interrupt number
6699         from 256 to INTNO_UNSPEC,
6700         * modified selection scheme of frame pointer generation. Previously
6701         if function did use local registers a frame pointer was generated,
6702         now a frame pointer is generated only if function has arguments
6703         (that need PLUSW2 register access), or has stack arguments, or the
6704         compiler is not instructed to omit the frame pointer,
6705         * (genEndFunction): before restoring local registers that were saved
6706         in the function preamble, also restore the registers that *might*
6707         have been allocated for stack access,
6708         * (genRet): removed some old comments,
6709         * (genCmp, the active (RN's) version): added a call to the
6710         pic16_genCmp_special function to perform the compare with a more
6711         robust and optimized way,
6712         * (genInline): a feature has been added in inline code generation,
6713         which allows a wildcard variable substitution when writing inline
6714         assembly. Code is incomplete and experimental therefore undocumented,
6715         * (genCast): changed order of aopOp for result and right to allow
6716         aopForSym to directly load the result if possible,
6717         * src/pic16/genutils.c (selectCompareOp, pic16_genCmp_special): NEW,
6718         perform an optimized compare on some selected special occasions,
6719         * src/pic16/genutils.h: declaration of resolvedIfx structure from gen.c,
6720         * src/pic16/glue.c (pic16createInterrupVect): make sure we never
6721         generate an IVT any more,
6722         * src/pic16/main.c (pic16_optionsTable): added command line option
6723         --optimize-cmp,
6724         * (_pic16_initPaths): when calling C preprocessor define pic18fXXXX
6725         macro too, when calling assembler define pic18fXXXX *and* __18Fxxxx
6726         macros,
6727         * src/pic16/NOTES: Raphael Neider added in list of active developers
6728         * src/pic16/pcode.c (OPT_TYPE_STR): added strings jumptable_begin and
6729         jumptable_end to prevent bug #,
6730         * (pic16_pciADDWFC, ADDFWC, COMF, CLRF): added some missing flags in
6731         inCond and outCond fields,
6732         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): add a fix for bug #,
6733         * src/pic16/ralloc.c (serialRegAssign): explicit set willCS to 0 to
6734         turn off register spilling,
6735         * (packRegsForOneUse): synced with other ports' versions although it
6736         is not used currently,
6737         * (pic16_packRegisters): added an optimization while reading
6738         structure bitfields, some registers may be saved (malloc code is
6739         decreased by 80 bytes)
6740
6741 2005-03-12 Vangelis Rokas <vrokas AT users.sourceforge.net>
6742
6743         * src/SDCCcse.c (cseBBlock): inside 'do operand lookup' loop test if
6744         left is a bitfield, if yes, then don't optimize assignment. Perhaps
6745         this can be optimized more?
6746
6747 2005-03-10 Raphael Neider <rneider AT web.de>
6748
6749         * src/pic16/gen.c (pic16_loadFSR0, genPackBits, genUnpackBits,
6750           genNearPointerGet): (hopefully) fixed access to bitfields via
6751           pointers (p->bitN = x; and x = p->bitN; failed)
6752
6753 2005-03-09 Paul Stoffregen <paul AT pjrc.com>
6754
6755         * device/lib/printf_fast.c: fix leading zero format, eg "%02d"
6756
6757 2005-03-09 Raphael Neider <rneider AT web.de>
6758
6759         * src/SDCCopt.c (killDeadCode): fixed bug #1156016
6760
6761 2005-03-06 Maarten Brock <sourceforge.brock AT dse.nl>
6762
6763         * src/SDCCicode.h: moved CRITICAL and ENDCRITICAL from SKIP_IC2 to SKIP_IC
6764         * src/mcs51/ralloc.c (willCauseSpill): added check for REG_BIT type,
6765           (regTypeNum): set REG_BIT type if necessary
6766         * src/mcs51/ralloc.h: added define REG_BIT, used to fix bug 1144613
6767         * support/regression/tests/critical.c: check bug 1144613
6768
6769 2005-03-02 Raphael Neider <rneider AT web.de>
6770
6771         * src/pic16/gen.c (genRightShiftLiteral): fixed bug #1154256
6772
6773 2005-02-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6774
6775         * src/avr/ralloc.c (serialRegAssign),
6776         * src/ds390/ralloc.c (serialRegAssign),
6777         * src/hc08/ralloc.c (serialRegAssign),
6778         * src/mcs51/ralloc.c (serialRegAssign),
6779         * src/pic/ralloc.c (serialRegAssign),
6780         * src/pic16/ralloc.c (serialRegAssign),
6781         * src/xa51/ralloc.c (serialRegAssign),
6782         * src/z80/ralloc.c (serialRegAssign): fixed bug #1105154
6783
6784 2005-02-22 Maarten Brock <sourceforge.brock AT dse.nl>
6785
6786         * src/SDCCast.c (decorateType): fixed bug 1124787
6787
6788 2005-02-20 Hubert Sack <sack AT digiplan.de>
6789         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6790
6791         * src/mcs51/peeph.def: added peepholes 3.h-k and 132.a-f from
6792         patch #1121755
6793
6794 2005-02-20 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6795
6796         * src/SDCCpeeph.def: new keyword "labelRefCountChange" which allows peepholes
6797         to keep the correct label reference count when adding/removing references
6798         to labels. A peephole file using this is appended to patch #1144962.
6799
6800 2005-02-14 Raphael Neider <rneider AT web.de>
6801
6802         * device/lib/pic16/libc/string/memccpy.c: changed 3rd argument to char
6803         * src/SDCC.lex (process_pragma): fixed to make disable_warning work for PIC16
6804         * src/pic16/gen.c (aopForSym, calls to pic16_aopOp): prevent unneccessary
6805           retrievals of result operand's value on assignment
6806
6807 2005-02-13 Vangelis Rokas <vrokas AT otenet.gr>
6808
6809         * device/include/pic16/string.h: modified prototype for memccpy()
6810         to memccpy(void *, void *, char, size_t)
6811         * src/pic16/gen.c (genFunction, genEndFunction): reenable if-case to
6812         check whether to omit frame pointer or not,
6813         * (genInline): convert all occurences of "\n" to LF in inline
6814         assembler blocks, this helps formatting the inline text,
6815         * (pic16_loadFSR0): modified prototype,
6816         * (genNearPointerGet, genNearPointerSet): reorganization of code,
6817         removed some 8051 legacy code,
6818         * (genPackBits): enabled handling bitfields exceeding one byte in size,
6819         * src/pic16/ralloc.c (pic16_assignRegisters): clear dynrIdx variable
6820         before allocating temporary registers in functions,
6821
6822 2005-02-11 Maarten Brock <sourceforge.brock AT dse.nl>
6823
6824         * support/regression/tests/bitvars.c: corrected the "fix"
6825
6826 2005-02-10 Maarten Brock <sourceforge.brock AT dse.nl>
6827
6828         * support/regression/tests/bitvars.c,
6829         * support/regression/tests/bitwise.c,
6830         * support/regression/tests/rotate.c: "fixed" problems on Alpha
6831
6832 2005-02-10 Raphael Neider <rneider AT web.de>
6833
6834         * src/pic16/pcode.c (assignToSameBank) : fixed cast to pointer of
6835           different size for Alpha
6836         * src/pic16/gen.c (genCmpEq) : improved compare with 0
6837
6838 2005-02-09 Raphael Neider <rneider AT web.de>
6839
6840         * src/SDCC.lex(doPragma) : save and restore warning options as well
6841           (also added new stack plus clone- and copyAndFreeSDCCERRG())
6842         * have #pragma less_pedantic set the errorlevel to WARNING
6843           (fixes #1117001)
6844         * (cloneOptimize) : fixed wrong malloc's size
6845         * support/Util/SDCCerr.[ch] : made SDCCERRG globally accessible to
6846           facilitate correct handling of #pragma (save|restore)
6847
6848 2005-02-09 Maarten Brock <sourceforge.brock AT dse.nl>
6849
6850         * src/mcs51/gen.c: removed non-standard C nameless struct/union
6851
6852 2005-02-04 Slade Rich <slade_rich AT users.sourceforge.net>
6853
6854         * src/pic/gen.c : Fix for bugs #1080519 & #1115662.
6855
6856 2005-02-03 Maarten Brock <sourceforge.brock AT dse.nl>
6857
6858         * device/include/mcs51/c8051f120.h: added declarations for sbit port 2,3&4
6859
6860 2005-02-02 Raphael Neider <rneider AT web.de>
6861
6862         * src/SDCCast.c (processParms): disabled W_NONRENT_ARGS for pic16 port
6863         * src/pic16/gen.c (aopForSym): reenabled special case for function pointers
6864         * (pic16_storeForReturn): fixed to allow returning function pointers
6865         * (genPackBits): improved accessing full bytes, implemented for GPOINTERs
6866         * device/include/pic16/{stddef.h,stdbool.h}: added
6867
6868 2005-02-02 Maarten Brock <sourceforge.brock AT dse.nl>
6869
6870         * device/include/mcs51/c8051f040.h: added define CPT2_PAGE
6871
6872 2005-02-01 Slade Rich <slade_rich AT users.sourceforge.net>
6873
6874         * src/pic16/pic16.dsp : Added file graph.c to make it compile under windows
6875         * src/pic16/Makefile.bcc : Do not use this file but added file graph.c as it
6876          appeared to be required
6877
6878 2005-01-31 Borut Razem <borut.razem AT siol.net>
6879
6880         * support/scripts/sdcc.nsi: added include/asm/ds390, include/asm/mcs51,
6881           include/mcs51 and include/z80 directories to the package
6882
6883 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6884
6885         * src/hc08/gen.c (genFunction): fixed bug #1112752
6886
6887 2005-01-30 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6888
6889         * src/mcs51/peeph.def: adapted peephole 258.x to changed gen.c (genAnd)
6890
6891 2005-01-29 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
6892
6893         * src/mcs51/gen.c (genAnd): accessing LSB/MSB by rotating acc
6894
6895 2005-01-29 Maarten Brock <sourceforge.brock AT dse.nl>
6896
6897         * device/include/Makefile.in: create/copy mcs51 and z80 include subdirs
6898
6899 2005-01-27 Maarten Brock <sourceforge.brock AT dse.nl>
6900
6901         * device/include/c8051fxxx.h: removed these 6 files
6902         * device/include/mcs51/c8051fxxx.h: added these 11 new files
6903
6904 2005-01-26 Raphael Neider <rneider AT web.de>
6905
6906         * src/pic16/gen.c (genAssign): fixed assignment from longs
6907           in codespace (were cut to three bytes)
6908         * (genDummyRead): implemented (except for CODESPACE...),
6909           fixed bug #1108575
6910         * src/pic16/glue.c (emitStatistics): beautified
6911         * device/lib/pic16/libm/Makefile: added include path
6912
6913 2005-01-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6914
6915         * src/z80/gen.c (aopPut): fixed bug #1103902
6916
6917 2005-01-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
6918
6919         * device/lib/expf.c: fixed bug #1095792
6920
6921 2005-01-24 Vangelis Rokas <vrokas AT otenet.gr>
6922
6923         * device/lib/pic16/libm: added Math library sources
6924
6925 2005-01-24 Raphael Neider <rneider AT web.de>
6926
6927         * src/pic16/pcode.h: added second memory operand to pCodeOpReg
6928           to enable upcast to pCodeOpReg2 (there is no type tag to
6929           differenciate the two and pic16_popGet2p cast into PCOR2)
6930         * src/pic16/main.c (_process_pragma): fixed another malloc bug
6931           (sizeof(sectNames) changed to sizeof(sectName))
6932           Both patches fix segfaults under MinGW.
6933
6934 2005-01-23 Raphael Neider <rneider AT web.de>
6935
6936         * src/pic16/{device.c,pcode.c}: s/free/Safe_free/g for
6937           Safe_[mc]?alloc()'ed variables
6938         * src/pic16/gen.c (pic16_aopOp,pic16_popGet): added handling
6939           of (byte sized) temporaries (assign them to WREG for now)
6940         * src/pic16/main.c (_process_pragma): fixed nasty malloc bug
6941           (used sizeof(set *sectSyms) instead of sizeof(struct sectSym)),
6942           this might fix SIGSEGVs on MinGW...
6943         * src/SDCCopt.c (killDeadCode): restored original behaviour
6944           (volatile operands might get thrown away though)
6945
6946 2005-01-23 Vangelis Rokas <vrokas AT otenet.gr>
6947
6948         * src/pic16/gen.c: fixed bug #1106975,
6949         * src/pic16/gen.c: fixed possible bug #1102572, now during TOS
6950         pointer update, INTCON is saved, global interrupts are disabled and
6951         restored after updateing TOS.
6952         * src/SDCC.y, src/SDCC.lex, src/SDCCsymt.c, src/SDCCsymt.h:
6953         * added function attribute 'shadowregs' to take advantage of shadow
6954         registers,
6955         * added function attribute 'wparam' as an alternative to the wparam
6956         pragma,
6957         * support/Utils/SDCCerr.[ch]: added error E_SHADOWREGS_NO_ISR when
6958         user declares a non-ISR function as 'shadowregs',
6959         * doc/sdccman.lyx: updated to reflect recent changes of pic16 port
6960
6961 2005-01-22 Vangelis Rokas <vrokas AT otenet.gr>
6962
6963         * .version: bumped version number to 2.4.8
6964         * device/lib/pic16/pics.all: list of PIC18F devices supported by
6965         pic16 port,
6966         * device/lib/pic16/libio/i2c/: I2C module support library,
6967         * device/include/pic16/i2c.h: I2C support library header,
6968         * device/lib/pic16/libc/stdio/: standard IO support sources,
6969         * (printf_small.c): printf_small() source, supports float print,
6970         * (printf_tiny.c): printf_tiny() source, does not support floats,
6971         * device/lib/pic16/Makefile.common.in: added OPT_FLAGS macro to
6972         enable global optimizations for entire library source, other
6973         Makefiles in the source tree are also modified to reflect this,
6974         * device/lib/pic16/libc/stdlib/putchar.c (putchar): dummy putchar()
6975         function,
6976         * doc/sdccman.lyx: updated to reflect new changes,
6977         * src/pic16/gen.c (aopForSym): don't handle sym->iaccess in
6978         sym->onStack if-case,
6979         * src/pic16/main.c (_pic16_keywords): commented out keywords bit,
6980         sbit, idata, _idata, xdata, _xdata,
6981         * added pragma library, to link an external library, (see doc),
6982         * removed command line options, --pomit-config-words, --pomit-ivt,
6983         --pleave-reset-vector,
6984         * (pic16_finaliseOptions): when define macro SDCC_MODEL_{SMALL/LARGE}
6985         when calling assembler to reflect memory model used, also define
6986         macro STACK_MODEL_{SMALL/LARGE} when compiling and assembling to
6987         reflect stack model used,
6988         * src/pic16/ralloc.c (pic16_allocDirReg): when operand is allocated
6989         on stack return NULL,
6990
6991 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
6992
6993         * src/SDCCopt.c (killDeadCode): do not throw iCodes away if one
6994           of the operands is volatile. Fixes #1020220
6995
6996 2005-01-22 Daniel Winkler <post AT danielwinkler.de>
6997
6998         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): reenabled optimization
6999         * (OptimizeRegUsage): make sure that there is really no other flow where
7000           the first pCode is used
7001
7002 2005-01-22 Raphael Neider <rneider AT web.de>
7003
7004         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): disabled optimization
7005           to fix #1106967 (pCode->seq are not set up correctly)
7006
7007 2005-01-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7008
7009         * src/SDCCglue.c (glue): make sure code area is declared before the
7010         static initialization area.
7011
7012 2005-01-21 Raphael Neider <rneider AT web.de>
7013
7014         * device/lib/Makefile.in: fixed test for pic16 install dir
7015         * device/lib/pic16/*/Makefile*: modified compile flags to enable
7016           optimizations
7017         * doc/sdccman.lyx: updated banksel optimization, removed --flr-support and
7018           added --optimize-goto compiler switch and pragma wparam documentation
7019         * src/pic16/pcode.c (pic16_OptimizeBanksel): removed statistics dump
7020         * src/pic16/pcodepeep.c (pic16_pCodeOpCopy): fixed copying of WREG, PRODL
7021           and PRODH closing bug #1071770 (peephole optimizer)
7022
7023 2005-01-19 Raphael Neider <rneider AT web.de>
7024
7025         * src/SDCCglobl.h: ensure that PATH_MAX >= 2048 to guarantee
7026           cmdLine buffers (used when calling sdcpp...) are large enough
7027           (MAX_PATH=256 truncates arguments leading to system halts when
7028           used in MinGW...)
7029         * src/pic16/gen.c (pic16_sameRegs): relaxed size criterion
7030         * (genUminus): rewritten to for efficiency
7031         * (genNearPointer[GS]et): enforce reloading of FSR0 (was still
7032           used uninitialized in some cases)
7033         * (genCast): upcasting a 16bit int to a 24bit GPOINTER may not
7034           copy the third byte from the int -- now assumes 0x80 (data memory)
7035         * src/pic16/genarith.c (pic16_genPlus): fixed bug when swapping
7036           operands (genAddLit expects the iCode's operands to swapped as
7037           well), fixed leftover bytes (crashed for short left operands)
7038         * (pic16_genMinusDec): performance improvements, removed false
7039           PIC14 emitSKPNCs
7040         * (pic16_genMinus): fixed to cope with differently sized operands
7041         * src/pic16/glue.c (pic16_glue): added new banksel optimization
7042           for --obanksel > 1
7043         * src/pic16/pcode.c: implemented (first phase of) banksel optimization
7044         * src/pic16/graph.[ch]: implementation of directed graphs, used by
7045           new banksel optimization
7046         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): prevented
7047           analysis for temporary registers (segfaults...)
7048         * src/pic16/peeph.def: added rule
7049
7050 2005-01-18 Vangelis Rokas <vrokas AT otenet.gr>
7051
7052         * device/lib/pic16/libc/stdlib/x_ftoa.c: it defines x_ftoa function
7053         which converts a float number to its ASCII representation
7054         * device/lib/pic16/libc/utils/cnvfrac.S,cnvint.S: support
7055         functions to convert the fractional and integer part of a float to ASCII,
7056         * device/lib/pic16/libc/stdlib/(calloc.c,free.c, malloc.c,
7057         realloc.c): added _MALLOC_SPEC to explicit place variables in data
7058         ram
7059         * device/include/asm/pic16/features.h: added _CODE, _DATA, _AUTOMEM,
7060         _STATMEM macros,
7061         * device/include/pic16/adc.h: added GPL info,
7062         * src/pic16/gen.c (genIfxpCOpJump): perform an genIfxJump but using
7063         a pCodeOp as tested operand,
7064         * (genNearPointerGet): optimized bit testing, does not use
7065         intermediate register for bit value, test directly instead with
7066         BTFSS, BTFSC, works only for single bits,
7067         * (genpic16Code): dump the name of the iCode in the asm,
7068         * src/pic16/ralloc.c (decodeOp): removed static declaration and
7069         renamed to pic16_decodeOp,
7070         * (serialRegAssign): do not allocate a temporary register for iCode
7071         sequences that test a single bit for 1/0
7072
7073 2005-01-12 Vangelis Rokas <vrokas AT otenet.gr>
7074
7075         * src/pic16/pcode.[ch]: introduced pic16_stackpnt_*,
7076         pic16_framepnt_*, pic16_stack_*, pic1_frame_* pointer variables to
7077         access stack and frame pointers. They are initially assigned to
7078         point at pic16_pc_fsr1[lh] and pic16_pc_fsr2[lh] variables and other
7079         accessing SFRs. Updated all occurences of modification of stack or
7080         frame pointer in gen.c and pcode.c,
7081         * src/pic16/ralloc.c (serialRegAssign): fixed two bugs with
7082         assigning of a literal value to pointers,
7083         * src/pic16/main.c (pic16_finiliseOptions): set pre-processor define
7084         flag STACK_MODEL_SMALL or STACK_MODEL_LARGE according to the model
7085         selected
7086
7087 2005-01-11 Vangelis Rokas <vrokas AT otenet.gr>
7088
7089         * doc/sdccman.lyx: update documentation about stack pragma, added
7090         some info for stack memory models
7091
7092 2005-01-08 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
7093
7094         * src/pic16/gen.c (DEBUGpc): MSVC 6 does not support macro variable arguments
7095
7096 2005-01-08 Raphael Neider <rneider AT web.de>
7097
7098         * src/pic16/device.c (pic16_dump_usection): changed naming scheme for
7099           udata sections to fix bug #1097823
7100
7101 2005-01-05 Raphael Neider <rneider AT web.de>
7102
7103         * src/pic16/gen.c (genGenericShift): added handling of differently
7104           sized left operand and result
7105
7106 2005-01-04 Raphael Neider <rneider AT web.de>
7107
7108         * src/pic16/gen.c (genIfxJump): fixed inverted skips on CARRY
7109         * (genIfx): fixed (?) read from uninitialized SPIL_LOC (now assumes CARRY
7110           to hold the condition bit)
7111         * added new version of genCmp (old code available via #define)
7112         * added new version of genShiftLeft/genShiftRight in a generic
7113           way, now supports shifting by negative values
7114         * (genLeftShiftLiteral, genRightShiftLiteral): use absolute value of
7115           shiftCount (expected by genGenericShift)
7116         * src/pic16/genarith.c (genPlus): added code for adding CARRY+literal
7117         * src/pic16/pcode.c (pic16_OptimizeJumps): removed annoying statistics
7118           dump
7119         * (pic16_newpCodeOpLit): changed to cast to unsigned char (as e.g. -32766
7120           is an invalid literal too...)
7121
7122 2005-01-04 Vangelis Rokas <vrokas AT otenet.gr>
7123
7124         * src/pic16/gen.c (aopForSym, genEndFunction): applied some fixes
7125         from Raphael Neider,
7126         * src/pic16/pcode.c (pic16_newpCodeOpLit): removed casting to char
7127         for 8-bit literals. This fixes some literal operands which are sign
7128         extended to 16-bits ints when instruction needs only 8-bits.
7129
7130 2004-12-31 Paul Stoffregen <paul AT pjrc.com>
7131
7132         * device/lib/logf.c: added mcs51 assembly version
7133         * device/lib/expf.c: added mcs51 assembly version
7134         * device/lib/_logexpf.c: new shared asm code for expf and logf
7135         * device/include/math.h: add defines for assembly math library
7136         * device/lib/Makefile.in: build new _logexpf.c
7137         * device/lib/libfloat.lib: use new _logexpf.c
7138
7139 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
7140
7141         * src/pic/device.c
7142         * src/pic/pcode.c : adjusted internal stack and pre-allocated registers for
7143           device types which have less than 0x7f registers.
7144
7145 2004-12-29 Slade Rich <slade_rich AT users.sourceforge.net>
7146
7147         * src/pic/genarith.c : Fixed problem with subtraction where the result would not be updated when borrowing.
7148
7149 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
7150
7151         * device/lib/printf_fast.c: only build on supported arch.
7152         * device/lib/printf_tiny.c: only build on supported arch.
7153         * device/lib/printf_fast_f.c: only build if asm float lib
7154         * device/lib/_fsget1arg.c: only build if asm float lib
7155         * device/lib/_fsget2args.c: only build if asm float lib
7156         * device/lib/_fsnormalize.c: only build if asm float lib
7157         * device/lib/_fsreturnval.c: only build if asm float lib
7158         * device/lib/_fsrshift.c: only build if asm float lib
7159         * device/lib/_fsswapargs.c: only build if asm float lib
7160         * device/include/stdio.h: don't provide print_fast,
7161           print_fast_f, print_tiny prototypes if --xstack used
7162
7163 2004-12-28 Maarten Brock <sourceforge.brock AT dse.nl>
7164
7165         * device/lib/sincosf.c (sincosf): don't invert bit/bool by ~
7166         * support/regression/ports/mcs51-stack-auto/spec.mk: added new _fs.. files
7167           to the SOURCES
7168
7169 2004-12-28 Paul Stoffregen <paul AT pjrc.com>
7170
7171         * device/lib/printf_fast_f.c: same as printf_fast, but
7172           with floating point enabled
7173         * device/lib/printf_fast.c: minor tweaks
7174         * device/include/stdio.h: add printf_fast_f
7175
7176 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
7177
7178         * src/SDCCmain.c: make --float-reent default for mcs51
7179         * device/lib/_fsadd.c: added mcs51 assembly version
7180         * device/lib/_fssub.c: added mcs51 assembly version
7181         * device/lib/_fsmul.c: added mcs51 assembly version
7182         * device/lib/_fsdiv.c: added mcs51 assembly version
7183         * device/lib/_fseq.c: added mcs51 assembly version
7184         * device/lib/_fsneq.c: added mcs51 assembly version
7185         * device/lib/_fsgt.c: added mcs51 assembly version
7186         * device/lib/_fslt.c: added mcs51 assembly version
7187         * device/lib/_fscmp.c: shared code for fseq,fsgt,fslt,fsneq
7188         * device/lib/Makefile.in: add _fscmp to build
7189         * device/lib/libfloat.lib: add _fscmp to build
7190
7191 2004-12-27 Paul Stoffregen <paul AT pjrc.com>
7192
7193         * device/lib/_fs2slong.c: added mcs51 assembly version
7194         * device/lib/_fs2sint.c: added mcs51 assembly version
7195         * device/lib/_fs2schar.c: added mcs51 assembly version
7196         * device/lib/_fs2ulong.c: added mcs51 assembly version
7197         * device/lib/_fs2uint.c: added mcs51 assembly version
7198         * device/lib/_fs2uchar.c: added mcs51 assembly version
7199         * device/lib/_slong2fs.c: added mcs51 assembly version
7200         * device/lib/_sint2fs.c: added mcs51 assembly version
7201         * device/lib/_schar2fs.c: added mcs51 assembly version
7202         * device/lib/_ulong2fs.c: added mcs51 assembly version
7203         * device/lib/_uint2fs.c: added mcs51 assembly version
7204         * device/lib/_uchar2fs.c: added mcs51 assembly version
7205         * device/include/float.h: added #define to select asm vs c
7206
7207 2004-12-26 Paul Stoffregen <paul AT pjrc.com>
7208
7209         * device/lib/printf_fast.c: improvements to float output
7210         * device/include/float.h: add defines for assembly float library
7211         * device/lib/_fsget1arg.c: receive 1 float arg
7212         * device/lib/_fsget2args.c: receive 2 float args (reentrant)
7213         * device/lib/_fsnormalize.c: normalize a float
7214         * device/lib/_fsreturnval.c: return float, various helper routines
7215         * device/lib/_fsrshift.c: right shift a float's mantissa
7216         * device/lib/_fsswapargs.c: swap 2 floats
7217         * device/lib/Makefile.in: build these 6 new files for mcs51
7218         * device/lib/libfloat.lib: add these 6 files to the library
7219
7220 2004-12-26 Borut Razem <borut.razem AT siol.net>
7221
7222         * sim/ucsim/avr.src/arith_inst.cc: fixed bug #1088372- savr is not
7223           built by gcc 3.4.2
7224
7225 2004-12-25 Paul Stoffregen <paul AT pjrc.com>
7226
7227         * device/lib/printf_tiny.c: printf for mcs51 in only 267 bytes,
7228           and fully reentrant and register bank neutral.
7229         * device/lib/printf_fast.c: added float (not enabled by default),
7230           added compact/slower integer (also not enabled by default),
7231           improved size/speed of fast integer code, other minor changes
7232         * device/include/stdio.h, device/lib/Makefile.in,
7233           device/lib/libsdcc.lib: integrate printf_tiny into mcs51 build
7234
7235 2004-12-24 Maarten Brock <sourceforge.brock AT dse.nl>
7236
7237         * src/pic16/pcode.c: declaring variables other than at the start of a
7238           block is not supported in C by VC6.
7239
7240 2004-12-22 Vangelis Rokas <vrokas AT otenet.gr>
7241
7242         * applied a previous patch from Raphael Neider that wasn't included
7243         in the previous commits, which fixes infinite loops within jumptable
7244         improvements,
7245         * made some fixes that previous patches introduced
7246
7247 2004-12-21 Vangelis Rokas <vrokas AT otenet.gr>
7248
7249         * src/pic16/gen.c (pic16_aopGet): applied fix from Raphael Neider
7250         that fixes an issue with AOP_PCODE asmop's offset,
7251         * (pic16_popCopyReg): update instance field too,
7252         * (mov2w): modified to pic16_mov2w because it conflicts with mov2w
7253         function of pic port,
7254         * (genCmp, genAnd, genAssign),
7255         * src/pic16/genarith.c (genAddLit): some fixes from Raphael Neider,
7256
7257 2004-12-20 Vangelis Rokas <vrokas AT otenet.gr>
7258
7259         * src/SDCCast.c (gatherAutoInit): allow pic16 to emit static
7260         variables initial values to idata section,
7261         * src/SDCCicode.c (geniCodeCall): patch from ### to fix unreferenced
7262         variables in some functions. This utilizes parmBytes field of iCode
7263         structure to hold the offset of the variable in stack. (might be
7264         able to use the stack field too?)
7265         * applied patch from Raphael Neider # ### , # ###
7266         * src/pic16/glue.c (pic16emitRegularMap): fix to print static
7267         variable initial values in idata section,
7268         * src/pic16/ralloc.c (pic16_allocDirReg): don't allocate register
7269         for static variables with initial value
7270         * src/device/lib/pic16/libsdcc/float/ulong2fs.c (__ulong2fs):
7271         applied fix in while loop from Raphael Neider.
7272
7273 2004-12-19 Maarten Brock <sourceforge.brock AT dse.nl>
7274
7275         * src/ds390/gen.c (genCpl): fixed bit=~(char/bit) bugs, added warning
7276         * src/ds390/main.c (_ds390_regparm): don't pass bit params in registers
7277         * src/ds390/ralloc.c (serialRegAssign): spill bits
7278         * src/mcs51/gen.c (genCpl): fixed bit=~(char) bugs, added warning
7279         * support/Util/SDCCerr.c,
7280         * support/Util/SDCCerr.h: added warning W_COMPLEMENT for using bit=~(bit)
7281         * support/regression/tests/bitvars.c: added tests for bitwise complement(~)
7282         * support/regression/tests/bitwise.c: added test for bitwise complement(~)
7283
7284 2004-12-09 Maarten Brock <sourceforge.brock AT dse.nl>
7285
7286         * device/include/sdcc-lib.h: inserted LGPL, added includes
7287           asm/ds390/features.h and asm/mcs51/features.h
7288         * device/include/asm/default/features.h,
7289         * device/include/asm/gbz80/features.h,
7290         * device/include/asm/z80/features.h: added empty _AUTOMEM
7291           and _STATMEM
7292         * device/include/asm/ds390/features.h,
7293         * device/include/asm/mcs51/features.h: added files with defines for
7294           _AUTOMEM and _STATMEM indicating automatic and static storage class
7295         * device/lib/printf_large.c (_print_format): optimized & used _AUTOMEM
7296         * doc/sdccman.lyx: version 2.4.7, updated xstack documentation
7297         * src/SDCCicode.c (geniCodeCast),
7298         * src/SDCCsymt.c (compareType): allow cast of data-ptr to idata-ptr
7299         * src/SDCCloop.c (loopInduction): removed unused variable lr
7300         * src/SDCCopt.c (convilong, convertToFcall): moved "easy special case"
7301           to convertToFcall to include char modulo (RFE 1065037), added check
7302           if left operand is unsigned and use abs of literal value
7303         * src/SDCCpeeph.c (setFromConditionArgs): removed double quotes option
7304           as it doesn't work after conversion from peephole.def to peephole.rul
7305         * src/mcs51/gen.c (toBoolean): added check for size,
7306           (genModOneByte): optimized code for signed char modulo a literal
7307           power of 2 (thanks to Hubert Sack),
7308           (genRRC): removed unnecessary "clr c",
7309           (genRLC): replaced "add a,acc" with cheaper "rlc a"
7310         * src/mcs51/peeph.def: renamed 115 to 115.a, added rule 115.b: another
7311           jump optimization,
7312           swapped rules 256.c and 256.d,
7313           extended 256.d by using new multiple checks (thanks Erik),
7314           added rules 256.e and 256.f,
7315           updated rule 261.a and 261.b to new generated code
7316         * support/regression/tests/muldiv.c: added test div/mod by a power of 2
7317
7318 2004-12-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7319
7320         * src/SDCCloop.c (basicInduction, loopInduction): fixed several
7321           induction related bugs, including first part of bug #1074377
7322
7323 2004-12-05 Vangelis Rokas <vrokas AT otenet.gr>
7324
7325         * applied patch from bug-report #1076292,
7326         * applied patches for genAnd and Goto-optimizations for Raphael
7327         Neider,
7328         * src/SDCCicode.c (printOperand): fixed !REGA source to compile and
7329         dump a less iCode information,
7330         * src/pic16/device.h (pic16_options_t): added field debgen,
7331         * src/pic16/gen.h: added macros DUMP_FUNCTION_ENTRY,
7332         DUMP_FUNCTION_EXIT, FENTRY, FENTRY2,
7333         * src/pic16/gen.c (my_powof2): renamed to pic16_my_powof2 and made
7334         puclic,
7335         * (various functions): added macros FENTRY and FENTRY2 to functions,
7336         to emit function prologue,
7337         * (various functions): fixed indentation,
7338         * (genNearPointerGet): fixed loading of FSR0,
7339         * (genPackBits): applied patch from Raphael Neider to fix updating
7340         of FSR0 and touching only the modified bits,
7341         * src/pic16/genarith.c (various functions): added macros FENTRY to
7342         emit function prologue in comments,
7343         * src/pic16/pcode.h: added functions debugf2, debugf3,
7344         * src/pic16/ralloc.c: partial fix for packForPush caused
7345         segmentation fault,
7346
7347 2004-12-04 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7348
7349         * src/mcs51/peeph.def: added 261.a,b (16 bit rotate) by Stas Sergeev
7350           <stsp AT users.sourceforge.net> with reversed byte order
7351         * support/regression/tests/rotate.c: added (ds390 skips some tests)
7352
7353 2004-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7354
7355         * src/z80/gen.c (genLeftShift, genRightShift): fixed second part of
7356           bug #1074377
7357         * src/hc08/gen.c (genrshFour, shiftRLong, shiftLLong),
7358         * src/mcs51/gen.c (shiftLLong): Fixed some shifting bugs Frieder found
7359
7360 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
7361
7362         * src/pic/pcode.c : fixed a problem where banksel was not being inserted.
7363
7364 2004-12-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7365
7366         * src/SDCCpeeph.c (callFuncByName): support combined peephole rule
7367           conditions,
7368           (setFromConditionArgs): friendly operand parser for peephole rules,
7369           (operandBaseName, operandsNotRelated): new peephole condition
7370           "operandsNotRelated" -- similar to "operandsNotSame", but takes
7371           architecture specific register naming into account, handles n-way
7372           comparisons, and supports quoted literals
7373         * src/mcs51/peeph.def: restored rule 177.d with an extra condition
7374
7375 2004-12-02 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7376
7377         * src/mcs51/peeph.def: fixed bug #1076940
7378
7379 2004-12-02 Slade Rich <slade_rich AT users.sourceforge.net>
7380
7381         * device/include/pic/pic16f877.h : added an include file for the PIC16F877 device.
7382
7383 2004-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7384
7385         Adding support for replacing ljmps with sjmps in jumptables
7386         generated for switch statements. For now you need to set the
7387         environment variable SDCC_SJMP_JUMPTABLE to enable this.
7388         Now 4 algorithms for mcs51 jumptable generation are used:
7389         ljmp or sjmp jumptables for up to 16 cases, stack-pushing target
7390         addresses loaded pc-relative for up to 112 cases and stack-pushing
7391         target addresses loaded with offset from dptr for up to 256 cases.
7392
7393         * src/SDCCpeeph.c: added peephole conditional labelJTInRange
7394         * src/mcs51/main.c: adapted constants for switch table generation
7395         * src/mcs51/peeph.def: added 260.x for replacing ljmp with sjmp
7396
7397 2004-11-26 Maarten Brock <sourceforge.brock AT dse.nl>
7398
7399         * device/lib/printf_large.c (_print_format): fixed bug 1073386
7400         * support/regression/tests/bug1057979.c: added test for bug 1073386
7401
7402 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
7403
7404         * src/pic16/pcode.c: fixed bug which may produce error in non-GNU
7405         compilers
7406
7407 2004-11-25 Vangelis Rokas <vrokas AT otenet.gr>
7408
7409         * src/pic16/device.h,
7410         * src/pic16/genarith.c,
7411         * src/pic16/glue.c,
7412         * src/pic16/main.c,
7413         * src/pic16/pcode.c: applied patches #1068154 and #1070213
7414
7415 2004-11-24 Vangelis Rokas <vrokas AT otenet.gr>
7416
7417         Large cummulative patch for pic16 port.
7418         * device/lib/pic16/gstack.h: NEW, user can specify its own handler
7419         to call when a stack overflow occurs,
7420         * (malloc.h): added CVS Id tag,
7421         * (pic18f{242,252,442,452}.h): added T0CONbits structure and
7422         variable,
7423         * added libc directory. The current version of LibC contains string
7424         functions, ctype functions and macros and some functions of the
7425         stdlib set (like malloc/free/atof/atoi etc...). All functions are to
7426         be extensively tested in the future. Standard disclaimer here.
7427         Library is not automatically build yet. But one can build it by
7428         invoking 'make' inside the libc directory.
7429         * added ADC library under libio. Preliminary version yet.
7430
7431         * src/pic16/gen.h: added emitTOGC macro, to toggle Carry flag,
7432         * src/pic16/gen.c (aopForRemat): asmop size is filled by
7433         aopForRemat() now and not by pic16_aopOp(),
7434         * (pic16_popGetTempReg): removed warning messgae when allocating
7435         temporary registers, its a buggy feature and will be removed,
7436         * (pic16_popGet): set register instance field in AOP_CRY,
7437         * (pic16_outBitC): fixed for results in size greater than 1,
7438         * (genUminusFloat): fixed for pic16, ported code from mcs51,
7439         * (pic16_storeForReturn): optimized return of 0,
7440         * (genCmp): experimental code for new genCmp which uses PIC18's
7441         special compare&skip instructions. Initial tests fail some times
7442         with variables grater than 1 byte in size, so new code is disabled,
7443         * (genUnpackBits, genPackBits): more optimizations in reading/writing,
7444         a single bit,
7445         * (genCast): began a fix to optimize the casting of a bit to another
7446         bit, now assigning a bitfield to another bitfield will fail, sorry,
7447         * src/pic16/main.c: disabled the use of lr-support feature,
7448         * src/pic16/pcode.h: renamed PCASMDIR to PCAD,
7449         * added some function prototypes, added function _debugf prototype,
7450         * src/pic16/pcode.c: (pic16_get_op): fixed emitting operands of register
7451         bits with offset (case PO_GPR_BIT),
7452         * (genericPrint): don't emit INFO pcode when --pcode-verbose not in
7453         command line,
7454         * (isBankInstruction): modified to return 0 for no banking instruction,
7455         and 1 for banking instruction,
7456         * (pic16_isPCinFlow): check for PCAD (assembler directives) too,
7457         caused stop processing pCodes after a inline assembly block,
7458         * (pic16_popCopyGPR2Bit): updated to match bitfields with offset,
7459         * src/pic16/pcoderegs.c: fixed a bug with eliminating some temporary
7460         registers when it shouldn't,
7461         * src/pic16/ralloc.c (allocReg): add preliminary support for
7462         supporting a limited set of temporary registers,
7463
7464 2004-11-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7465
7466         * src/hc08/gen.c (genAssign, genPointerGetSetOfs, genDataPointerGet,
7467           genDataPointerSet): ensure assignments always copy in MSB to LSB
7468           order,
7469           (loadRegFromAop): recognize CLRH optimization,
7470           (genFunction): optimize RECEIVE iCodes in reentrant functions
7471
7472 2004-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7473
7474         * src/SDCCmain.c (parseCmdLine, optionsTable[]): fixed bug with
7475           --out-fmt-s19 turning into --out-fmt-elf if s19 was already
7476           selected.
7477         * src/SDCCmain.c (linkEdit): don't define SSEG for HC08
7478         * src/hc08/main.c (_hc08_setDefaultOptions): default xdata to be
7479           contiguous with data
7480
7481 2004-11-19 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7482
7483         * device/lib/_gptrget.c (_gptrget),
7484         * device/lib/_gptrgetc.c (_gptrgetc),
7485         * device/lib/_gptrput.c (_gptrput): _naked allows to use ret
7486           instead of sjmp to ret
7487         * src/mcs51/peeph.def: added peepholes 3.d-g and 177.g,h provided
7488           by Hubert Sack <hsack2002 AT arcor.de> in RFE #1067986, thanks
7489
7490 2004-11-18 Maarten Brock <sourceforge.brock AT dse.nl>
7491
7492         * .version: bumped version to 2.4.7
7493         * device/lib/_gptrget.c (_gptrget): is now _naked
7494         * device/lib/_gptrgetc.c (_gptrgetc): is now _naked
7495         * device/lib/_gptrput.c (_gptrput): is now _naked
7496         * src/SDCCast.c (createBlock): removed ridiculous self-assignment,
7497           (createFunction): fixed xstack
7498         * src/SDCCglue.c (emitMaps): set allocation required for bit area
7499         * src/SDCCicode.c (geniCodeCast): don't change SPEC_OCLS for literal
7500           or bit either,
7501           (geniCodeCritical): store original interrupt state in an iTemp bit
7502           var unless stack-auto
7503         * src/SDCCicode.h: added CRITICAL and ENDCRITICAL to SKIP_IC2
7504         * src/SDCCmain.c (setIncludePath): added include/target to search path
7505         * src/SDCCmem.c (allocParms): store bit vars in bit space, not overlay
7506         * src/SDCCsymt.c (checkFunction): don't check regbank for isr's against
7507           prototype,
7508           (processFuncArgs): put bit vars in bit area
7509         * src/mcs51/gen.c (saveRegisters, unsaveRegisters, genXpush, saveRBank,
7510           unsaveRBank): fixed xstack,
7511           (genFunction): bugfix: replaced (global!) reentrant with fReentrant,
7512           (genFunction, genEndFunction): fixed xstack,
7513           (genAssign): optimization don't walk backwards through mem
7514         * src/mcs51/main.c (_mcs51_regparm): don't pass bit params in registers
7515         * src/mcs51/ralloc.c (createStackSpil): spill bits to bit area
7516         * support/regression/Makefile: also make library (for stack-auto) when
7517           making "all" and added "test-mcs51-xstack-auto"
7518         * support/regression/fwk/lib/testfwk.c: added T2_isr prototype for mcs51
7519         * support/regression/ports/mcs51/T2_isr.c: added this file as a stub
7520         * support/regression/ports/mcs51/fwk.lib: added to link T2_isr stub
7521         * support/regression/ports/mcs51/spec.mk: added rules for fwk.lib
7522         * support/regression/ports/mcs51-stack-auto/spec.mk: replaced
7523           make-library by MAKE_LIBRARY
7524         * support/regression/ports/mcs51-xstack-auto/spec.mk: file added to run
7525           regression tests for xstack
7526         * support/regression/tests/bitvars.c: test for bit vars (bug 938782)
7527         * support/regression/tests/critical.c: test for critical on mcs51
7528
7529 2004-11-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7530
7531         * support/regression/ports/ucz80/spec.mk: use include and lib files from
7532           built version of sdcc instead of installed version
7533
7534 2004-11-14 Maarten Brock <sourceforge.brock AT dse.nl>
7535
7536         * src/mcs51/gen.c (toBoolean): fixed bug 1065458
7537         * device/lib/Makefile.in: z80 uses printf_large.c, sprintf.c and
7538           vprintf.c now
7539         * device/lib/printf_large.c (calculate_digit): fixed bug 1057979
7540         * device/lib/z80/Makefile: don't use printf.c as it fails bug 1057979
7541           WARNING: remove device/lib/build/z80/printf.o by hand when
7542           updating from previous build!
7543         * device/lib/z80/printf.c: updated comment
7544         * support/regression/tests/bug1057979.c: test all ports now
7545         * support/regression/tests/bug1065458.c: file added
7546
7547 2004-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7548
7549         * src/z80/gen.c (genFunction, genEndFunction): avoided generating
7550           *_start and *_end symbols for static functions
7551
7552 2004-11-11 Maarten Brock <sourceforge.brock AT dse.nl>
7553
7554         * src/SDCCmain.c (linkEdit): don't suppress crt0 if --nostdlib is used
7555           and search crt0.o in all library paths,
7556           (setIncludePath): proper handling of --nostdinc,
7557           (setLibPath): proper handling of --nostdlib
7558         * support/regression/Makefile,
7559         * support/regression/ports/ds390/spec.mk,
7560         * support/regression/ports/gbz80/spec.mk,
7561         * support/regression/ports/hc08/spec.mk,
7562         * support/regression/ports/mcs51/spec.mk,
7563         * support/regression/ports/mcs51-large/spec.mk,
7564         * support/regression/ports/mcs51-stack-auto/spec.mk,
7565         * support/regression/ports/z80/spec.mk: use include and lib files from
7566           built version of sdcc instead of installed version
7567         * doc/sdccman.lyx: fixed typo in --nostdinc
7568
7569 2004-11-10 Slade Rich <slade_rich AT users.sourceforge.net>
7570
7571         * src/pic/pcode.c,
7572         * src/pic/device.c,
7573         * src/pic/ralloc.c,
7574         * src/pic/gen.c : added support to generate code for struct bit fields.
7575
7576 2004-11-06 Maarten Brock <sourceforge.brock AT dse.nl>
7577
7578         * as/xa51/xa_version.h,
7579         * device/include/errno.h,
7580         * device/include/regc515c.h,
7581         * device/lib/_itoa.c,
7582         * device/lib/_ltoa.c,
7583         * device/lib/ser_ir_cts_rts.c,
7584         * sim/ucsim/xa.src/glob.cc,
7585         * sim/ucsim/xa.src/inst_gen.cc,
7586         * sim/ucsim/xa.src/xa_bit.cc,
7587         * sim/ucsim/xa.src/xa_sfr.cc,
7588         * sim/ucsim/z80.src/inst_dd.cc,
7589         * sim/ucsim/z80.src/inst_fdcb.cc,
7590         * support/scripts/keil2sdcc.pl,
7591         * src/pic16/pic16.dsp,
7592         * src/pic16/pic16a.dsp: corrected cvs line endings
7593         * device/lib/printf_large.c: fixed bug 1057979
7594         * src/pic16/gen.c: fixed non-C standard code
7595         * src/SDCCmain.c: made --pack-iram default, added --no-pack-iram
7596         * src/SDCCglobl.h: changed pack_iram to no_pack_iram
7597         * support/regression/ports/mcs51/support.c: reload T1 asap
7598         * doc/sdccman.lyx: updated for options --pack-iram and --no-pack-iram,
7599           pdata use and clear idata startup behaviour
7600         * support/regression/tests/bug1057979.c: added
7601
7602 2004-11-04 Maarten Brock <sourceforge.brock AT dse.nl>
7603
7604         * device/examples/ds390/ow390/ad26.h,
7605         * device/examples/ds390/ow390/cnt1d.h,
7606         * device/examples/ds390/ow390/crcutil.c,
7607         * device/examples/ds390/ow390/ownet.h,
7608         * device/examples/ds390/ow390/owsesu.c,
7609         * device/examples/ds390/ow390/swt12.h,
7610         * device/examples/ds390/ow390/swtoper.c,
7611         * device/examples/ds390/ow390/temp10.h,
7612         * device/examples/ds390/ow390/thermodl.c,
7613         * device/examples/ds390/tinitalk/tinitalk.dsp,
7614         * device/examples/ds390/tinitalk/tinitalk.dsw,
7615         * device/examples/mcs51/clock/hw.h,
7616         * device/examples/mcs51/simple2/go.bat,
7617         * device/examples/serialcomm/windows/serial.h,
7618         * device/examples/xa51/dummy.c,
7619         * device/examples/xa51/hello.c,
7620         * device/include/80c51xa.h,
7621         * device/include/at89x051.h: corrected cvs line endings
7622
7623 2004-11-04 Vangelis Rokas <vrokas AT otenet.gr>
7624
7625         * src/pic16/main.c (options): added command line --gstack, to trace
7626         stack over/under flows,
7627         * added pragma 'wparam' to allow passing first byte of function
7628         parameters via WREG, syntax is #pragma wparam my_function[, func2...]
7629         * src/pic16/gen.c (pic16_testStackOverflow): function which emits a
7630         call to __gstack_test function and sets up the symbol as extern,
7631         * (pic16_pushpCodeOp, pic16_poppCodeOp, pushw, pushaop, popaopidx,
7632         * popaop): added call to pic16_testStackOverflow,
7633         * (wParamCmp, inWparamList): NEW, test existence of a symbol in
7634         wparamList list,
7635         * (genCall, genPcall): now all parameters are passed via stack
7636         except in functions that are pass to wparam pragma in which WREG is
7637         used too,
7638         * (genPcall): REENTRANT flag is checked to see if variable prototype
7639         contains reentrant keyword, don't call a non-reentrant function, via
7640         a reentrant function pointer or vice versa, functions are never
7641         passed via WREG,
7642         * (genJumpTab): applied patch from bug #1057478 by R.Neider and
7643         D.Winkler,
7644         * src/pic16/glue.c (pic16emitRegularMap): fixed bug which caused a
7645         SIGSEGV when accessing a NULL register stucture,
7646         * (pic16_printGPointerType): modified to handle UPPER modifier for
7647         function initializers, changed prototype of function to simpler one,
7648         * (pic16_printIvalFuncPtr): check to see if function is already
7649         added in externs list,
7650         * src/pic16/pcoderegs.c (pCodeOptime2pCodes): fixed bug which
7651         optimized a move from W to SFR with a move to the same register
7652         later after a CALL,
7653         * device/lib/pic16/debug: NEW directory, contains debug features
7654         which are enabled when linking with libdebug.lib, currently command
7655         line option --gstack enables stack pointer tracing for over/under
7656         flow, corresponding sources are in debug/gstack
7657
7658 2004-10-30 Vangelis Rokas <vrokas AT otenet.gr>
7659
7660         * doc/sdccman.lyx: updated SDCC version,
7661         * (PIC16 port): update list of command line options,
7662         * src/pic16/device.h (structure pic16_options_t): added field gstack
7663         to enable stack overflow tracing on push/pops,
7664         * src/pic16/device.c (statistics structure): added statistics
7665         structure,
7666         * (pic16_dump_access, pic16_dump_usection, pic16_dump_gsection,
7667         pic16_dump_int_registers): increase statistics counters for each
7668         * variable which is encountered
7669         * (pic16_dump_usection): emit each .udata variable to its own udata
7670         section,
7671         * src/pic16/gen.c (assignResultValue, genCall, genPcall, genFunction):
7672         when macro USE_WREG_IN_FUNC_PARAMS is set to 0 pass all function
7673         parameters via stack, otherwise use old scheme,
7674         * src/pic16/glue.c (pic16_emitStatistics): dump statistics in
7675         assembler output file,
7676         * src/pic16/main.c: added command line options --gstack to enable
7677         push/pop tracing for stack overflow,
7678         * src/pic16/pcode.c (all pCodeInstruction records for PIC18F
7679         instructions): added size of each instruction,
7680         * (pic16_countInstruction): estimate size of instructions in
7681         the_pFile list, inline assembly blocks are not counted,
7682         * (pic16_FixRegisterBanking): trace previous register usage, when
7683         banksel optimizations is greater than 0, don't emit a redudant
7684         banksel directive,
7685
7686 2004-10-26 Slade Rich <slade_rich AT users.sourceforge.net>
7687
7688         * src/pic/ralloc.c : fixed inefficient code produced when compiling a complimented bit operation.
7689         * src/pic16/ralloc.c : applied same fix for pic16.
7690         * src/pic/gen.c : tidied it up a little.
7691
7692 2004-10-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7693
7694         * src/mcs51/peeph.def: disabled 259.a,b for removing redundant ret,
7695         thanks to Martin Helmling for reporting (mail on sdcc-devel 2004-10-25)
7696
7697 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7698
7699         * src/SDCCast.c (reverseParms): fixed bug #1040577 (part 2)
7700
7701 2004-10-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
7702
7703         * device/lib/ser_ir_cts_rts.c: integer promotion caused a call to the
7704         non-reentrant function __modsint in the interrupt function (thus
7705         corrupting math operations during serial I/O)
7706         * device/lib/ser_ir.c: as above, changed buffersize
7707         * src/mcs51/peeph.def: added 259.a,b for removing redundant ret,
7708         256.c,d for zeroing
7709         * doc/Makefile: added option -t for rsync
7710
7711 2004-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7712
7713         * src/SDCCast.h (struct ast),
7714         * src/SDCCast.c (reverseParms, copyAst): fixed bug #1040577 (part 1)
7715
7716 2004-10-20 Borut Razem <borut.razem AT siol.net>
7717
7718         * support/scripts/sdcc.nsi: added include/pic16/*.h to the setup
7719         package
7720
7721 2004-10-20 Vangelis Rokas <vrokas AT otenet.gr>
7722
7723         * device/lib/pic16/libsdcc/Makefile: added lregs directory in
7724         makefile targets,
7725         * device/lib/pic16/libsdcc/lregs/{Makefile,lrst.c,lrrest.c}: NEW
7726         support functions to replace long sequences of MOVFF's from access
7727         bank registers to stack and vice versa,
7728         * src/pic16/device.h: added new field opt_flags, where optimization
7729         flags can be set to enable certain features,
7730         * src/pic16/gen.c (pic16_emitpinfo): NEW to add PC_INFO pCode in
7731         * pBlock, (genFunction, genEndFunction): surroung loop for
7732         saving/loading used registers in stack with PC_INFO pCodes,
7733         INF_LREGS. Code in between can then be optimized by pCode optimizer
7734         to support function calls,
7735         * (genDataPointerSet): fixed bug which loaded float fields in
7736         structures with corrupt data,
7737         * src/pic16/genutils.c (debugf, _debugf): macro/function which emits
7738         in a standard way debug info on stderr. Feature used for developing
7739         and debugging only,
7740         * src/pic16/glue.c (pic16glue): reformatted, deleted some old and
7741         obsolete chunks of code,
7742         * if optimization flag OF_LR_SUPPORT was set, call pic16_OptimizeLocalRegs,
7743         * src/pic16/main.c (_pic16_parseOptions): added handler for --flr-support,
7744         * pic16/src/pcode.c (pic16_newpCodeInfo,
7745         * (pic16_newpCodeOpLocalRegs),
7746         * (pic16_convertLocalRegs2Support): NEW, to support new optimization
7747         feature,
7748         * (pic16_pCodeConstString): printing of the initial value of a
7749         symbol as a comment is inhibited since parsing was already done by
7750         copyStr and output is corrupt,
7751         * (pic16_pCode2str, genericPrint): handle PC_INFO pCode,
7752
7753 2004-10-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
7754
7755         * src/mcs51/ralloc.c (packRegisters): fixed bug #1044601
7756
7757 2004-10-19 Maarten Brock <sourceforge.brock AT dse.nl>
7758
7759         * as/mcs51/lkarea.c: removed old K&R style,
7760           (lnksect): changed check on boundary error,
7761           (lnksect2): changed check on boundary error,
7762           (lnksect2): extend XSTK to end of page if size = 1
7763         * as/mcs51/lkmain.c: removed old K&R style,
7764           (Areas51): create l_IRAM symbol
7765         * as/mcs51/lkmem.c (summary2): added report on PSEG and XSTK
7766         * device/lib/Makefile.in: renamed model-mcs51-reentrant to
7767           model-mcs51-stack-auto, added model-mcs51-xstack-auto
7768         * device/lib/_mullong.c: added version to be compiled with xstack
7769         * device/lib/mcs51/crtclear.asm: clear only upto --iram-size
7770         * device/lib/mcs51/crtxclear.asm: clear pdata as well
7771         * device/lib/mcs51/crtxstack.asm: fixed comment
7772         * src/SDCCglue.c: maxInterrupts defaults to 0,
7773           (emitMaps): added pdata,
7774           (createInterruptVect): (re)moved default,
7775           (glue): added pdata,
7776           (glue): moved __start__xstack to XSTK with default size 1
7777         * src/SDCCmain.c (parseCmdLine): automatically set options.intlong_rent
7778           and options.float_rent when options.stackAuto is set,
7779           (linkEdit): only write XDATA_NAME if provided on command line
7780         * src/SDCCmem.h,
7781         * src/SDCCmem.c: added pdata
7782         * src/port.h: added pdata_name to PORT
7783         * src/mcs51/gen.c (toBoolean): fixed for Acc use of aopGet,
7784           (saveRegisters, unsaveRegisters): removed usage of B,
7785           (genMinus): fixed accumulator clash,
7786           (genJumpTab): added comment, this needs another look
7787         * src/mcs51/gen.c: added check for "B in use" paranoia,
7788           added pushB() and popB()
7789         * src/mcs51/peeph.def: restart after 177.c so 177.a can get a second
7790           chance
7791         * src/avr/main.c,
7792         * src/ds390/main.c,
7793         * src/hc08/main.c,
7794         * src/mcs51/main.c,
7795         * src/pic/main.c,
7796         * src/pic16/main.c,
7797         * src/xa51/main.c,
7798         * src/z80/main.c: (reset_regparms) made void parameter explicit and
7799           added PSEG (PAG,XDATA) or NULL to port specifier
7800         * src/ds390/main.c (_ds390_genIVT): moved implemented default in here
7801         * src/mcs51/main.c (_mcs51_genIVT): moved implemented default in here,
7802           (_mcs51_genInitStartup): removed __start__xstack equ,
7803           (mcs51_port): moved xstack from XSEG (XDATA) to XSTK (PAG,XDATA)
7804         * src/pic16/device.c (pic16_dump_usection, pic16_dump_isection),
7805         * src/z80/gen.c (_rleAppend): fixed warnings
7806         * support/regression/tests/zeropad.c: added pdata test
7807         * .version: bumped to 2.4.6
7808
7809 2004-10-17 Borut Razem <borut.razem AT siol.net>
7810
7811         * support/scripts/sdcc.nsi: cross compiling of WIN32 setup.exe on Linux
7812         as a part of nightly build
7813
7814 2004-10-16 Vangelis Rokas <vrokas AT otenet.gr>
7815
7816         * src/pic16/gen.c (struct _G): added field useWreg, is set to 1 when
7817         WREG holds the first byte function parameters,
7818         * (aopForSym): take special case for symbols which are in FARSPACE
7819         but in CODESPACE too,
7820         * (assignResultValue): modified to take into account _G.useWreg,
7821         * (genCall): don't use wreg for parameter passing when function is
7822         declared as reentrant, too, added optimization INCF to stack
7823         pointer when stack parameter count is 1,
7824         * (genFunction, genEndFunction): refurnished and fixed to not using
7825         wreg for passing parameters when function has varargs or is
7826         reentrant, fixed bug with symbol name compare for generating
7827         functions in absolute address,
7828         * (pic16_storeForReturn): refurnished,
7829         * (genCmp): began writing a new version of the function, not ready
7830         yet, therefore it is disabled,
7831         * (genAssign): do not read code memory when assigning a function to
7832         a pointer function,
7833         * src/pic16/glue.c (pic16emitStaticSeg): abSym->name is defined an
7834         array of characters, not pointer,
7835         * (pic16initialComments): in debug mode emit an .ident directive for
7836         the assembler,
7837         * (_process_pragma): emit a new warning type (internal to pic16)
7838         when setting stack to default length, emit a similar warning when
7839         placing a function at absolute address and address is not word aligned
7840         * (_pic16_parseOptions): added 'return TRUE' statement,
7841         * (_pic16_linkEdit): if compiling a source, then add the source's
7842         file object, first in the list of objects to link,
7843
7844 2004-10-13 Slade Rich <slade_rich AT users.sourceforge.net>
7845
7846         * src/pic/pcoderegs.c : increased count on regUsedinRange to prevent unnecessary warning.
7847         * src/pic/main.c : removed VC warning.
7848         * src/pic/gen.c : changed comment.
7849
7850 2004-10-12 Vangelis Rokas <vrokas AT otenet.gr>
7851
7852         * device/lib/pic16/libsdcc/gptr/gptrput[234].c: an external
7853         reference to a deprecated symbol _GPTRREG was causing failure to
7854         link. Thanks G. M. Gallant for the info.
7855
7856 2004-10-12 Slade Rich <slade_rich AT users.sourceforge.net>
7857
7858         * src/pic/pcode.c : Applied a code patch supplied by Paul Ashmore in
7859         comments for Bugs item #954788.
7860
7861 2004-10-10 Vangelis Rokas <vrokas AT otenet.gr>
7862
7863         * src/pic16/device.c (pic16_dump_gsection,
7864         * pic16_groupRegistersInSection): handle symbols declared to be in
7865         access bank differently,
7866         * src/pic16/gen.c (struct _G): added field resDirect,
7867         * (aopForSym): if symbol on stack and iCode is '=' and result exists,
7868         send values read from stack directly to result and don't allocate
7869         temporary values,
7870         * (pic16_sameRegs): fixed bug that allowed MOVFF to move between
7871         same registers,
7872         * (pic16_sameRegsOfs): NEW,
7873         * (freeAsmop): if _G.resDirect is set then do not mark registers as
7874         free because they were not allocated from temporary pool,
7875         * pic16_popRegFromString): workaround to fix a problem with
7876         allocating variables twice or never,
7877         * (genGenPointerGet): using PRODL instead of FSR0H,
7878         * (genGenPointerSet): using POSTDEC1 (that is a stack location)
7879         instead of FSR0H,
7880         * (genAssign): take advantage of the _G.resDirect flag,
7881         * (genCast): around line 11844, use mov2f instead of directly
7882         MOVFF'ing between operands to account for literal values,
7883         * src/pic16/genutils.c: some new debug functions for gpsim have been
7884         added,
7885         * src/pic16/glue.c (pic16_printIvalType): fixed bug that initialized
7886         float with integer part only,
7887         * src/pic16/main.c (_process_pragma): handle pragma udata access to
7888         place variables in access bank
7889         * device/lib/pic16/libsdcc/gptr/gptr*.c: using BRA instead of GOTO,
7890         updated sources to reflect recent changes in gen.c
7891
7892 2004-10-06 Vangelis Rokas <vrokas AT otenet.gr>
7893
7894         * device/lib/pic16/libsdcc/Makefile.rules: fixed bug concerning
7895         sources that searched for headers in installation path, now the
7896         device/include/pic16 is used,
7897         * src/pic16/glue.c (pic16glue),
7898         * src/pic16/pcode.c (pCode2str, genericPrint): don't print .file or
7899         .line directives if not in debug mode, this suppresses assembler's
7900         warnings for ignored directives
7901
7902 2004-10-05 Maarten Brock <sourceforge.brock AT dse.nl>
7903
7904         * src/port.h: made reset_regparms prototype void parameter explicit.
7905         * src/SDCCsymt.c (processFuncArgs): removed argument "func".
7906         * src/mcs51/ralloc.c (packRegisters): new fix for bugs 898889 & 979599.
7907         * doc/sdccman.lyx: documented warning disabling and how to use
7908           printf_large to make it print floats.
7909         * device/include/stdbool.h: NEW
7910         * device/lib/_atof.c,
7911         * device/lib/_divuint.c,
7912         * device/lib/_divulong.c,
7913         * device/lib/expf.c,
7914         * device/lib/printf_large.c,
7915         * device/lib/sincosf.c,
7916         * device/lib/sincoshf.c: used stdbool.h, all compile with stack-auto now
7917         * device/lib/Makefile.in: added target for model-mcs51-reentrant to build
7918           a completely reentrant lib.
7919
7920 2004-10-05 Vangelis Rokas <vrokas AT otenet.gr>
7921
7922         * device/lib/pic16/libsdcc/gptr/gptr*.c: added return statements
7923         * device/include/pic16/stdio.h: fixed bug with colon
7924
7925 2004-10-03 Vangelis Rokas <vrokas AT otenet.gr>
7926
7927         * device/include/pic16/stdio.h,
7928         * device/include/pic16/stdlib.h,
7929         * device/include/pic16/math.h: NEW
7930         * device/lib/pic16/libsdcc/gptr/*.c (gptrget*, gptrput*): functions
7931         declared as _naked to reduce overhead
7932         * device/lib/Makefile.in (target port-specific-objects-pic16):
7933         changed * to *.* so to ignore the CVS directory,
7934         * src/pic16/gen.c (pic16_freeAsmop): added code to store result of
7935         stacked variables back in stack,
7936         * (genEndFunction): fixed bug reported by G.M. Gallant with stack
7937         corruption
7938
7939 2004-10-01 Vangelis Rokas <vrokas AT otenet.gr>
7940
7941         * .version: bumped version number to 2.4.5
7942         * support/Util/SDCCerr.h: added warning W_POSSBUG2.
7943         * support/Util/SDCCerr.c (messages structure): added entry for
7944         W_POSSBUG2
7945
7946         Large cumulative patch for pic16 port and libraries.
7947         * device/include/pic16/sdcc-lib.h,
7948         * device/include/pic16/stdarg.h,
7949         * device/include/asm/pic16/features.h,
7950         * device/include/lib/pic16/libsdcc/gptr/{*.c, Makefile}: NEW,
7951         * device/include/pic16/float.h: changes reentrant keyword with
7952         _FS_REENTRANT, added prototype for __fsneq, included sdcc-lib.h
7953         * device/lib/pic16/libsdcc/Makefile: added target directory gptr,
7954         updated target build-libraries to include objects from gptr,
7955         * device/lib/pic16/libsdcc/{char,int,long}/*.c: added macro
7956         _IL_REENTRANT to all function headings, included sdcc-lib.h header,
7957         * device/lib/pic16/libsdcc/float/*.c: added macro _FS_REENTRANT to
7958         all function headings,
7959         * src/SDCCmain.c: added global parameter userIncDirsSet,
7960         * (parseCmdLine): when option -I is encountered add directory to
7961         userIncDirsSet too,
7962         * src/version.awk: added space between control and long,
7963         * src/pic16/NOTES: added some notes for the port,
7964         * src/pic16/gen.c: added prototype for mov2fp function,
7965         * (fReturnpic16[]): properly named return value registers,
7966         * (_G structure): added fields stackRegSet, fregsUsed, stack_lat,
7967         * (aopForSym): added code to handle symbols with onStack flag set,
7968         symbols onStack are allocated PTRSIZE bytes,
7969         * (aopFreeAsmop): handles special case where asmops are stack objects,
7970         * (aopGet, pic16_popGet): adde cod to handle new asmop AOP_STA,
7971         * (pic16_popGetTempReg, pic16_popGetTempRegCond, pic16_popReleaseTempReg):
7972         added argument lock to trace flaws in allocating temporary registers
7973         when developing port,
7974         * (pic16_popGetLit, pic16_popGetLit2): changed lit from unsigned to signed
7975         * (pic16_popRegFromString): reenabled allocating a direct register
7976         from string,
7977         * (assignResultValue): various beautifications,
7978         * fixed bug #1037717 (patch from R. Neider & D. Wrinkler) with mistaken
7979         referenced function argument,
7980         * (genIpush): reenabled to allow stacked arguments, handles only
7981         ic->parmPush iCodes,
7982         * (genCall, genPcall): major changes to allow for variable argument
7983         functions, fixed a bug with falsely restoring stack pointer after
7984         returning from call,
7985         * (genFunction): pending code for critical function,
7986         * (shiftR1Left2ResultSigned, shiftR1Left2Result, shiftL2Left2Result,
7987         * (shiftR2Left2Result, shiftLLong) applied patch #1032155 from R.Neider,
7988         * (genNearPointerGet): fixed bug with indirect reading, was always
7989         reading from INDF0
7990         * (genGenPointerGet, genGenPointerSet): rewrote to support generic
7991         pointers,
7992         * (genAddrOf): rewrote code to take address of a stacked function parameter
7993         * (genCast): fixed casting to generic pointer type,
7994         * src/pic16/gen.h: added AOP_STA,
7995         * (struct asmop): added field stk,
7996         * src/pic16/genarith.c (pic16_AopType): handle AOP_STA,
7997         * (pic16_genPlusIncr): changed emitSKPNZ to emitSKPNZ,
7998         * (pic16_genAddLit, pic16_genPlus): applied patch #1034042 by tecodev,
7999         * (pic16_genMinus): fixed bug #1035119 with patch submitted by tecodev,
8000         * src/pic16/genutils.c (pic16_genNot): removed symbol *tlbl,
8001         * src/pic16/glue.c (pic16_printGPPointerType): fixed to support new
8002         generic pointers,
8003         * src/pic16/main.c (_pic16_initPaths): ignores default SDCC include
8004         and library paths,
8005         * (pic16_port structure): generic pointer size is set to 3,
8006         * src/pic16/pcode.c (pic16_newpCodeOpLit): correctly print literal integer,
8007         * (insertBankSwitch): cast to (char *) to prevent 64bit CPUs'
8008         compiler warning,
8009         * src/pic16/ralloc.c (allocReg): prevent allocating register when
8010         operand is an iTemp,
8011
8012 2004-09-24 Martin Helmling <mh AT octo-soft.de>
8013
8014         * debugger/mcs51/cmd.c: set PC if a symbol at pc reg is set
8015         * debugger/mcs51/simi.c: addapt new syntax of s51
8016
8017 2004-09-23 Vangelis Rokas <vrokas AT otenet.gr>
8018
8019         * src/pic16/genutils.c (pic16_genNot): fixed bug #1032265,
8020         * src/pic16/pcode.c: commented out some calls to free() in order to
8021         fix bug #989576,
8022
8023 2004-09-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8024
8025         * src/SDCCicode.h,
8026         * src/SDCCicode.c (isiCodeInFunctionCall),
8027         * src/avr/ralloc.c (selectSpil),
8028         * src/pic/ralloc.c (selectSpil),
8029         * src/pic16/ralloc.c (selectSpil),
8030         * src/ds390/ralloc.c (selectSpil),
8031         * src/hc08/ralloc.c (selectSpil),
8032         * src/xa51/ralloc.c (selectSpil),
8033         * src/mcs51/ralloc.c (selectSpil): Don't use remainSpil to spill to the
8034         stack in the middle of a function call sequence (fixes bug #1020268)
8035         * src/SDCCicode.c (geniCodeJumpTable): fixed error in computing the
8036         costs associated with the minimum switch case.
8037
8038 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8039
8040         * src/SDCC.lex: fixed bug #1030549
8041
8042 2004-09-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8043
8044         * src/SDCCcse.h (struct cseDef),
8045         * src/SDCCcse.c (cseBBlock, newCseDef, ifFromAddrTaken): purge CSEs
8046         over a function call if the CSE is derived from a symbol whose
8047         address has been taken (fixes bug #1029883)
8048         * support/regression/tests/bug-1029883: a new regression test for
8049         this bug
8050
8051 2004-09-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8052
8053         * src/hc08/gen.c (emitinline): fixed bug #1029778
8054         * src/SDCC.y (assignment_expr): fixed the grammer so that assignment
8055         to a cast object is no longer a syntax error ("fixes" bug #1030006,
8056         and starts toward RFE #905167)
8057
8058 2004-09-17 Vangelis Rokas <vrokas AT otenet.gr>
8059
8060         * src/pic16/gen.c (mov2f): New function to move an operand to
8061         another without considering if it is a literal or a register,
8062         * (pic16_sameRegs): don't check if they are both AOP_REG,
8063         * (AccRsh): removed andmask=0 lines,
8064         * (genLeftShift): duplicated to be improved in future versions,
8065         * src/pic16/main.c (_process_pragma): emit stack default size in hex,
8066         * src/pic16/pcode.c: added POC_INFSNZW, updated inverted_op fields
8067         in POC_INCFSZ, POC_INCFSZW, POC_INFSNZ,
8068         * (pic16initMnemonics): added initialization for POC_INFSNZW,
8069         * (insertBankSwitch): fixed inserting banksel directives algorithm
8070         for instructions that follow a skip instruction, this fixes a report
8071         for broken subtraction code generation,
8072         * src/pic16/ralloc.c (deassignLRs): do not free register if current
8073         iCode is a left op, just in case result and right share the same
8074         registers
8075
8076 2004-09-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8077
8078         * src/hc08/main.c,
8079         * src/hc08/gen.c (genJumpTable): more efficient jump table, supports
8080         preservation of HX
8081         * src/hc08/gen.c (pullRegs): fixed order of HX & XA pairs
8082         * src/mcs51/ralloc.c (packRegisters): removed the patch applied
8083         on 2004-09-12; it was buggy
8084
8085 2004-09-15 Bernhard Held <bernhard AT bernhardheld.de>
8086
8087         * src/SDCCsymt.h: removed RESULT_CHECK
8088         * src/SDCCast.c,
8089         * src/SDCCglue.c,
8090         * src/SDCCval.c,
8091         * src/pic/glue.c,
8092         * src/pic16/glue.c: replaced RESULT_CHECK with RESULT_TYPE_NONE
8093
8094 2004-09-15 Vangelis Rokas <vrokas AT otenet.gr>
8095
8096         * src/SDCCicode.c (piCode): applied patch from Raphael Neider,
8097         * src/pic16/device.c (pic16_assignConfigWordValues): wrong
8098         configuration values no more rejected by compiler, they are assigned
8099         to configuration registers with a warning message instead,
8100         * src/pic16/glue.c (pic16_emitConfigRegs): added +1 at top-limit of
8101         the for-loop so last conf register is emitted too,
8102         * (_pic16_initPaths): link library libsdcc.lib by default,
8103         * (_hasNativeMulFor): modified test for multiplication according to
8104         Raphael Neider's remarks. Integer multiplication is also done with
8105         support functions,
8106         * device/include/pic16/pic18fregs.h: corrected type error in while
8107         testing and including 18f6720 header file
8108
8109 2004-09-14 Vangelis Rokas <vrokas AT otenet.gr>
8110
8111         * src/pic16/device.h (pic16_options): removed field use_crt,
8112         * src/pic16/gen.c (genUnpackBits): added call to pic16_loadFSR0
8113         until an optimization to handle single bits is added,
8114         * (pic16_loadFSR0): moved before genUnpackBits,
8115         * (genAnd): some white lines removed,
8116         * src/pic16/main.c (_pic16_finaliseOptions): set omit_ivt and clear
8117         leave_reset flags in pic16_options when using crt modules,
8118
8119 2004-09-12 Maarten Brock <sourceforge.brock AT dse.nl>
8120
8121         * src/mcs51/ralloc.c (packRegisters): applied fix by Bernhard Held
8122           for bugs 898889 & 979599. Also used some safer print instructions.
8123
8124 2004-09-12 Vangelis Rokas <vrokas AT otenet.gr>
8125
8126         * src/pic16/device.h (pic16_options_t): added field use_crt,
8127         crt_name, no_crt,
8128         * src/pic16/genarith.c (pic16_genPlus): added an assert(0) line to
8129         catch a probable future bug,
8130         * src/pic16/gen.c: aopIdx function commented out,
8131         * (genAssign): commented out old code which used aopIdx,
8132         * src/pic16/glue.c (pic16glue): removed some legacy fragments of
8133         code, added if conditionals to take into account the --use-crt
8134         command line options,
8135         * src/pic16/main.c (pic16_optionsTable): added new command line
8136         options, --use-crt= and --no-crt,
8137         * (_pic16_linkEdit): now the proper crt object is added in the
8138         linker command line except than when --no-crt is specified,
8139         * src/pic16/pcode.c,
8140         * src/pic16/pcode.h: added some structures and functions for a new
8141         optimization scheme to compansate for instruction overhead between
8142         same iCodes, this scheme is currently under development and is not
8143         working in any way,
8144         * src/pic16/gen.c (genAnd): added patch provided by Aaron Collwell
8145         to && operator,
8146         * device/lib/pic16/startup/crt0i.c,
8147         * device/lib/pic16/startup/crt0iz.c: added global char variable
8148         __uflags to force the generation of an idata section
8149
8150 2004-09-12 Bernhard Held <bernhard AT bernhardheld.de>
8151
8152         * doc/Makefile,
8153         * doc/clean.mk: added support for easy creation of sdcc-doc.tar.bz2
8154         * doc/sdccman.lyx: updated sdcc version to 2.4.4
8155
8156 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8157
8158         * doc/sdccman.lyx: fixed a problem with my new index entries (thanks
8159         Frieder) and clarified the default code optimization mode
8160
8161 2004-09-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8162
8163         * src/SDCC.lex (doPragma, process_pragma),
8164         * src/SDCCglobl.h (struct optimize): added pragmas "opt_code_speed",
8165         "opt_code_size", and "opt_code_balanced"
8166         * src/SDCCmain.c (optionsTable[], printOptions, scanOptionsTable):
8167         regrouped options by category, added support for category headers
8168         * src/SDCCmain.c (parseCmdLine): added options "--opt-code-speed"
8169         and "--opt-code-size"
8170         * doc/sdccman.lyx: documented these new options and pragmas
8171         * src/hc08/gen.c (AccLsh, AccRsh): take speed/size optimization
8172         preference into account
8173
8174 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
8175
8176         * src/SDCCicode.c (geniCodePostInc, geniCodePreInc, geniCodePostDec,
8177           geniCodePreDec): Fixed bug 904237 by generating a warning
8178         * src/SDCCerr.h,
8179         * src/SDCCerr.c: added warning W_SIZEOF_VOID
8180
8181 2004-09-09 Slade Rich <slade_rich AT users.sourceforge.net>
8182
8183         * src/pic/device.c : When no max ram set validate full memory range.
8184         * src/pic/pcode.c,
8185         * src/pic/pcodepeep.c : Copy C code comments to optimised replacement code.
8186
8187 2004-09-08 Maarten Brock <sourceforge.brock AT dse.nl>
8188
8189         * device/lib/_gptrget.c,
8190         * device/lib/_gptrput.c: updated comment
8191         * device/lib/calloc.c,
8192         * device/lib/free.c,
8193         * device/lib/malloc.c,
8194         * device/lib/realloc.c: added LGPL, made them reentrant-safe
8195         * src/SDCCcse.c (cseBBlock),
8196         * src/SDCCicode.c (printOperand, geniCodeArray),
8197         * src/SDCCicode.h (struct operand): fixed bug 868103
8198         * support/regression/tests/bug-868103.c: added
8199         * src/SDCCast.c (searchLitOp),
8200         * src/SDCCcse.h (struct cseDef),
8201         * src/SDCCglue.c (printIvalArray, spacesToUnderscores),
8202         * src/SDCCicode.h (struct operand),
8203         * src/SDCCsymt.h (struct sym_link),
8204         * src/avr/gen.c (hasInc),
8205         * src/ds390/gen.c (hasInc),
8206         * src/hc08/gen.c (genPlusIncr, hasInc),
8207         * src/mcs51/gen.c (hasInc),
8208         * src/pic16/glue.c (pic16_printIvalChar),
8209         * src/pic16/ralloc.c (regWithIdx),
8210         * src/xa51/gen.c (hasInc) : removed warnings
8211         * src/SDCCast.c (createBlock): added comment ???
8212         * src/hc08/ralloc.c: updated comments
8213
8214 2004-09-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8215
8216         * doc/sdccman.lyx: updated section on switch statements, added
8217         section about semaphore locking
8218         * doc/Makefile: added option -info for latex2html
8219         * device/lib/_gptrget.c,
8220         * device/lib/_gptrput.c: __XPAGE instead of P2 in outcommented code
8221
8222 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
8223
8224         * src/pic/device.h,
8225         * src/pic/device.c,
8226         * src/pic/port.c : Changed PIC14 code to not set bit RP1 when
8227          maxram is less than 0x100.
8228
8229 2004-09-06 Slade Rich <slade_rich AT users.sourceforge.net>
8230
8231         * Bug fixes for PIC14 - signed RSHIFT problem. Patch supplied by Allen(agschrum).
8232
8233 2004-09-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8234
8235         * src/port.h,
8236         * src/mcs51/main.c,
8237         * src/ds390/main.c,
8238         * src/z80/main.c,
8239         * src/hc08/main.c,
8240         * src/pic/main.c,
8241         * src/pic16/main.c,
8242         * src/avr/main.c,
8243         * src/xa51/main.c
8244         * src/SDCCicode.c (geniCodeJumpTable): Better logic to determine if a
8245         a jump table is the best form for a switch statement, including
8246         automatic insertion of missing cases to make the case range
8247         continuous. Developed in collaboration with Frieder Ferlemann.
8248
8249 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8250
8251         * src/hc08/ralloc.c (canDefAccResult): multi-byte shift is unsafe for
8252         accumulator result if it needs sign extension
8253
8254 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
8255
8256         * src/hc08/ralloc.c (canUseAccOperand): fixed comparison bug
8257
8258 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
8259
8260         * device/lib/gbz80/printf.c,
8261         * device/lib/z80/printf.c: removed define for NULL
8262
8263 2004-09-02 Maarten Brock <sourceforge.brock AT dse.nl>
8264
8265         * as/xa51/xa_link.c,
8266         * device/examples/ds390/ow390/ad26.c,
8267         * device/examples/ds390/ow390/cnt1d.c,
8268         * device/examples/ds390/ow390/counter.c,
8269         * device/examples/ds390/ow390/ds2480.h,
8270         * device/examples/ds390/ow390/ds2480ut.c,
8271         * device/examples/ds390/ow390/findtype.c,
8272         * device/examples/ds390/ow390/gethumd.c,
8273         * device/examples/ds390/ow390/owllu.c,
8274         * device/examples/ds390/ow390/ownetu.c,
8275         * device/examples/ds390/ow390/swt12.c,
8276         * device/examples/ds390/ow390/swtloop.c,
8277         * device/examples/ds390/ow390/temp.c,
8278         * device/examples/ds390/ow390/temp10.c,
8279         * device/examples/ds390/ow390/thermo21.c,
8280         * device/examples/ds390/ow390/tinilnk.c,
8281         * device/examples/ds390/ow390/tstfind.c,
8282         * device/examples/serialcomm/windows/serial.cpp,
8283         * device/examples/serialcomm/windows/test_serialcomm.cpp,
8284         * device/include/reg51.h: fixed line endings for cvs
8285
8286 2004-09-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8287
8288         * src/hc08/ralloc.c (canDefAccResult, canUseAccOperand,
8289         packRegsForAccUse, packRegisters): new accumulator register
8290         packing algorithm
8291         * support/regression/ports/hc08/support.c (_putchar): suppress
8292         warning of unused variable
8293         * src/SDCCicode.c: added SWAP entry to codeTable
8294
8295 2004-09-01 Maarten Brock <sourceforge.brock AT dse.nl>
8296
8297         * device/lib/sprintf.c: forgot to add this file before previous commit
8298
8299 2004-09-01 Vangelis Rokas <vrokas AT otenet.gr>
8300
8301         * src/pic16/gen.c (genPackBits): added operand right in function
8302         parameters, load result directly if p_type is POINTER (that is
8303         called by genNearPointerSet)
8304         * (genUnPackBits): added operand left in function parameters,
8305         * (genNearPointerGet, genNearPointerSet): prevent the loading of
8306         FSR0 if accessing bitfields,
8307
8308 2004-08-31 Maarten Brock <sourceforge.brock AT dse.nl>
8309
8310         * device/include/stdio.h: added NULL, size_t, typedef pfn_outputchar,
8311           _print_format; updated printf, sprintf, vsprintf
8312         * device/include/asm/default/features.h: corrected comment/define
8313         * device/lib/Makefile.in: added sprintf.c
8314         * device/lib/libsdcc.lib: added sprintf module
8315         * device/lib/printf_large.c,
8316         * device/lib/vprintf.c,
8317         * device/lib/sprintf.c: totally refactored printf_large and vprintf
8318           into these 3 files
8319         * support/regression/Makefile: changed ALL_PORTS into a usefull default
8320         * support/regression/ports/mcs51-stack-auto/spec.mk: added sprintf
8321         * support/regression/tests/bug-927659.c: removed dummy putchar, enabled
8322           hc08 test
8323         * support/regression/tests/zeropad.c: define idata as data for hc08
8324
8325 2004-08-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8326
8327         * src/SDCCpeeph.c (labelIsReturnOnly): support hc08 rts opcode also
8328         * src/SDCCpeeph.c (buildLabelRefCountHash): assume function entry point
8329         labels are referenced at least once (even if a reference is not found)
8330         * src/hc08/gen.c (emitcode): set isComment flag for comments
8331         * src/hc08/peeph.def: added rules 5a..5f (optimize redundant immediate
8332         loads), rules 6a..6b (optimize jumps to return)
8333
8334 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8335
8336         * device/lib/acosf.c (acosf),
8337         * device/lib/asinf.c (asinf),
8338         * device/lib/atanf.c (atanf),
8339         * device/lib/ceilf.c (ceilf),
8340         * device/lib/cosf.c (cosf),
8341         * device/lib/coshf.c (coshf),
8342         * device/lib/cotf.c (cotf),
8343         * device/lib/fabsf.c (fabsf),
8344         * device/lib/floorf.c (floorf),
8345         * device/lib/log10f.c (log10f),
8346         * device/lib/logf.c (logf),
8347         * device/lib/sinf.c (sinf),
8348         * device/lib/sinhf.c (sinhf),
8349         * device/lib/sqrtf.c (sqrtf),
8350         * device/lib/tanf.c (tanf),
8351         * device/lib/tanhf.c (tanhf),
8352         * device/include/math.h: defined _FLOAT_FUNC_REENTRANT macro and
8353         replaced all instances of "reentrant" in the library functions
8354         defined in math.h with this macro.
8355         * support/regression/tests/float_trans.c: reenabled test for hc08
8356
8357 2004-08-30 Bernhard Held <bernhard AT bernhardheld.de>
8358
8359         * device/lib/pic16/Makefile.common.in: added MODELFLAGS again, it was
8360         erroneously deleted
8361
8362 2004-08-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8363
8364         * src/hc08/gen.c (loadRegFromAop): better use of clra & clrx
8365         * src/hc08/gen.c (genAnd, genOr): fixed bug with conditional when
8366         multi-byte volatile operands are used
8367         * src/hc08/gen.c (shiftRLong): fixed bug with wrong rotate direction
8368         * src/hc08/main.c (_hc08_genAssemblerPreamble): moved the built-in
8369         initialization to area GSINIT0 so that it would always precede
8370         any static initializers in GSINIT
8371         * support/regression/tests/zeropad.c: fixed idata define for hc08
8372         * support/regression/tests/bug-927659.c,
8373         * support/regression/tests/float_trans.c: disabled tests for hc08
8374         pending missing library routines
8375         * .version: increased version number to 2.4.4 - hc08 port now passes
8376         regression tests
8377
8378
8379 2004-08-29 Bernhard Held <bernhard AT bernhardheld.de>
8380
8381         * device/lib/pic16/Makefile.common.in: added $(MM) to fix `make clean`
8382         * Makefile.common.in,
8383         * as/Makefile,
8384         * as/hc08/Makefile.in,
8385         * as/mcs51/Makefile.in,
8386         * as/z80/Makefile.in,
8387         * debugger/mcs51/Makefile.in,
8388         * device/include/Makefile.in,
8389         * device/lib/Makefile.in,
8390         * doc/Makefile,
8391         * link/Makefile,
8392         * link/z80/Makefile.in,
8393         * packihx/Makefile.in,
8394         * sim/ucsim/main_in.mk,
8395         * sim/ucsim/avr.src/Makefile.in,
8396         * sim/ucsim/doc/Makefile.in,
8397         * sim/ucsim/gui.src/serio.src/Makefile.in,
8398         * sim/ucsim/hc08.src/Makefile.in,
8399         * sim/ucsim/s51.src/Makefile.in,
8400         * sim/ucsim/xa.src/Makefile.in,
8401         * sim/ucsim/z80.src/Makefile.in,
8402         * src/Makefile.in,
8403         * support/cpp2/Makefile.in,
8404         * support/librarian/Makefile,
8405         * support/makebin/Makefile: added DESTDIR to the install path proposed
8406         by "Maciej 'Agaran' Pijanka" <agaran AT pld-linux.org>
8407         * doc/sdccman.lyx: added DESTDIR documentation
8408
8409 2004-08-29 Vangelis Rokas (vrokas AT otenet.gr>
8410
8411         * src/pic16/gen.c (genFunction, genEndFunction): fixed return
8412         instruction for interrupt handlers, use fast returns when returning
8413         from high priority interrupts
8414
8415 2004-08-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8416
8417         * src/hc08/gen.c (genAnd, genOr, transferAopAop, rmwWithAop): optimized
8418         code generation
8419         * src/hc08/gen.c (genrshFour, genCpl): fixed bugs
8420         * src/hc08/gen.c (genMultOneByte, genDivOneByte, genModOneByte): fixed
8421         bugs, ported much of Bernhard's code from mcs51
8422         * src/mcs51/gen.c (genSend),
8423         * src/hc08/gen.c (genSend): fixed bug with lost SEND iCodes if more
8424         than one when calling a reentrant function
8425         * device/lib/_mullong.c: defined an alternate struct layout for big
8426         endian ports (hc08)
8427
8428 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8429
8430         * src/hc08/gen.c (shiftL2Left2Result): fix for bug-500536 regression
8431         test
8432
8433 2004-08-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8434
8435         * src/SDCCsymt.c (processFuncArgs): make sure parameter types
8436         are sane and complete before asking the port its prefered parameter
8437         passing method (fixes bug #1017633)
8438         * device/lib/hc08/_ret.c: added "data" storage class to _ret2
8439         and _ret3
8440
8441 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8442
8443         * src/hc08/gen.c (genPackBitsImmed, genUnpackBitsImmed): fix offset
8444         problem in bitfields >= 8 bits.
8445
8446 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
8447
8448         * src/SDCCsymt.c: undid changes that were not meant to be committed
8449
8450 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
8451
8452         * support/regression/ports/hc08spec.mk: REENTRANT must be reentrant
8453
8454 2004-08-27 Maarten Brock <sourceforge.brock AT dse.nl>
8455
8456         * src/hc08/gen.c (genUminusFloat): fixed bug where only 3 bytes were
8457           copied and wrong bit got inverted
8458
8459 2004-08-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8460
8461         * src/hc08/gen.c (genPointerSet, genFarPointerSet): moved code from
8462         genFarPointerSet into genPointerSet; eliminated genFarPointerSet
8463         * src/hc08/gen.c (genPointerGet, genFarPointerGet): moved code from
8464         genFarPointerGet into genPointerGet; eliminated genFarPointerGet
8465         * src/hc08/gen.c (genPackBitsImmed): generate optimized code for
8466         assignments to bitfields at known addresses
8467         * src/hc08/gen.c (genUnpackBitsImmed): generate optimized code for
8468         reads from bitfields at known addresses
8469         * src/hc08/ralloc.c (packRegisters),
8470         * src/hc08/gen.c (genPointerGet, genUnpackBits, genUnpackBitsImmed,
8471         genhc08Code): optimize pointer get values used as conditionals
8472         * src/hc08/peeph.def: added rules 2e & 2f to optimize bit test
8473         and branch
8474
8475 2004-08-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8476
8477         * src/mcs51/gen.c (genPointerGet, genNearPointerGet, genPagedPointerGet,
8478         genFarPointerGet, genCodePointerGet, genGenPointerGet, genUnpackBits),
8479         * src/mcs51/ralloc.c (packRegisters): optimize pointer get values used
8480         as conditionals
8481
8482 2004-08-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8483
8484         * src/mcs51/peeph.def: peepholes 248.i-m for xdata bitfields
8485
8486 2004-08-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8487
8488         * src/mcs51/ralloc.c (packRegsForOneuse): fixed bug #1012650 and some
8489         related problems
8490
8491 2004-08-21 Bernhard Held <bernhard AT bernhardheld.de>
8492
8493         * sim/ucsim/cmd.src/Makefile.in: run lex only if $(PRJDIR)/devel exists
8494
8495 2004-08-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8496
8497         * src/z80/ralloc.c (packRegsForAssign): ported some bug fixes from the
8498         mcs51 port
8499
8500 2004-08-16 Slade Rich <slade_rich AT users.sourceforge.net>
8501
8502         * src/pic/gen.c: Restored fn genRet as previous fix was incorrect.
8503
8504 2004-08-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8505
8506         * src/mcs51/gen.c (genJumpTab): jumptables for more than 16 switch
8507         cases use more compact code.
8508
8509 2004-08-13 Slade Rich <slade_rich AT users.sourceforge.net>
8510
8511         * src/pic/gen.c: Fixed problem with fn returning a variable bigger than a char.
8512
8513 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8514
8515         * src/SDCClrange.c (findPrevUse): fixed bug #1007371
8516
8517 2004-08-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8518
8519         * src/SDCCsymt.h,
8520         * src/SDCCsymt.c (changePointer, checkDecl, addSymChain): changed
8521         parameter of changePointer() from symbol* to sym_link*
8522         * src/SDCCast.c (decorateType): call changePointer() for CAST op
8523         * src/SDCCsymt.c (compareType): void* type is castable to other
8524         pointers, but not necesarily an exact match.
8525         * src/SDCCicode.c (geniCodeCast): allow void* casting here since it
8526         is no longer blindly treated as an exact match.
8527         * src/SDCCval.c (valCastLiteral): treat missing type as cast to void
8528
8529 2004-08-12 Slade Rich <slade_rich AT users.sourceforge.net>
8530
8531         * src/pic/glue.c: Added struct initialisation fn printIvalStruct.
8532
8533 2004-08-11 Slade Rich <slade_rich AT users.sourceforge.net>
8534
8535         * src/pic/gen.c,
8536         * src/pic/pcode.c,
8537         * src/pic/ralloc.h,
8538         * src/pic/ralloc.c: Printing rIdx on internal verbose debug.
8539
8540 2004-08-10 Slade Rich <slade_rich AT users.sourceforge.net>
8541
8542         * src/pic/device.c,
8543         * src/pic/device.h,
8544         * src/pic/device.c: Will no longer exit if #pragma maxram has not been defined.
8545
8546 2004-08-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8547
8548         * src/mcs51/gen.c (emitcode): fixed bug #992819
8549
8550 2004-08-05 Maarten Brock <sourceforge.brock AT dse.nl>
8551
8552         * src/pic/ralloc.c (deassignLR): allthough pic port is buggy already,
8553           there's no need to make it worse
8554
8555 2004-08-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8556
8557         * src/mcs51/ralloc.c (deassignLR),
8558         * src/ds390/ralloc.c (deassignLR),
8559         * src/hc08/ralloc.c (deassignLR),
8560         * src/z80/ralloc.c (deassignLR),
8561         * src/pic/ralloc.c (deassignLR),
8562         * src/pic16/ralloc.c (deassignLR),
8563         * src/avr/ralloc.c (deassignLR),
8564         * src/SDCClrange.c (findRecursiveSucc, findRecursivePred, findPrevUse,
8565         rlivePoint): fixed another part of bug #971834
8566
8567 2004-08-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8568
8569         * src/z80/main.c: enabled "critical" keyword
8570         * src/z80/mappings.i,
8571         * src/z80/gen.c (genFunction, genEndFunction): support for interrupt
8572         functions (fixes bug #979646)
8573         * doc/sdccman.lyx: added a subsection explaining z80 interrupt support
8574
8575 2004-08-04 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
8576
8577         * src/mcs51/gen.c (genInline): Add \n for labels, not DOS/WIN dirs
8578           such as c:\mydir.
8579
8580 2004-08-03 Maarten Brock <sourceforge.brock AT dse.nl>
8581
8582         * src/SDCCloop.c (loopInvariants): fixed bug 983545, hope this
8583           doesn't disable too much optimizations
8584
8585 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
8586
8587         * src/pic/glue.c Disabled "WARNING: function 'main' undefined" when -S option is used.
8588
8589 2004-08-02 Maarten Brock <sourceforge.brock AT dse.nl>
8590
8591         * src/SDCClrange.c (rlivePoint): fixed bug 988568, thanks to anonymous
8592
8593 2004-08-02 Slade Rich <slade_rich AT users.sourceforge.net>
8594
8595         * src/pic/gen.c tidied up tabs
8596         * src/pic/genarith.c tidied up tabs and fixed bug with literal multiple where same register was used for hi and low byte
8597         * src/pic/main.c tidied up tabs
8598         * src/pic/pcode.c tidied up tabs and disabled verbose code generation
8599         * src/pic/pcoderegs.c tidied up tabs
8600         * src/pic/ralloc.c tidied up tabs
8601
8602 2004-07-30 Vangelis Rokas <vrokas AT otenet.gr>
8603
8604         * src/SDCCmem.c (allocGlobal): don't turn S_REGISTER storage class
8605         to S_FIXED for pic16 port and when symbol is not in level 0,
8606         allocate for S_REGISTER storage class and pic16 port, too,
8607         * src/pic16/device.h: prototype for checkSym,
8608         * src/pic16/device.c (pic16_dump_access, checkSym): NEW,
8609         * (pic16_assignConfigWordValue): test the value and the mask to
8610         validate that the value is suitable for the configuration word,
8611         * src/pic16/glue.c (pic16_printIvalFuncPtr): use 'externs' to
8612         collect extern declared symbols, don't emit symbol twice, check
8613         first if symbol is in publics set first,
8614         * src/pic16/main.c (_pic16_keywords[]): added keyword 'register',
8615         * added command line '--fstack' which enables an experimental
8616         feature for stack access, too buggy to be used yet...
8617         * src/pic16/ralloc.c (pic16_accessregWithName): NEW,
8618         * (pic16_allocDirReg): when register has storage class S_REGISTER
8619         allocate in pic16_dynAccessRegs,
8620         * device/include/pic16/pic18f????.h: modified configuration word
8621         naming convention, words started as CONFIG0H but should be CONFIG1H
8622
8623 2004-07-29 Maarten Brock <sourceforge.brock AT dse.nl>
8624
8625         * device/include/mcs51reg.h: fixed bug 970993
8626
8627 2004-07-27 Maarten Brock <sourceforge.brock AT dse.nl>
8628
8629         * added lib/calloc.c, lib/free.c, lib/realloc.c, include/stddef.h
8630         * updated lib/malloc.c, lib/libsdcc.lib, lib/Makefile.in, include/malloc.h
8631         * src/SDCC.lex (doPragma): added pragma disable_warning <nnn>
8632         * src/SDCCmain.c (parseCmdLine): added option --disable-warning <nnn>
8633         * src/ds390/gen.c (genPlusIncr): fixed bug when incrementing generic pointers
8634         * support/Util/SDCCerr.c (vwerror): suppress disabled warnings and output
8635           error/warning numbers,
8636           added function setWarningDisabled()
8637         * support/Util/SDCCerr.h: added setWarningDisabled() and MAX_ERROR_WARNING
8638         * support/regression/ports/mcs51-stack-auto/spec.mk: added dependencies
8639           _memcmp.c _memmove.c calloc.c realloc.c free.c
8640         * support/regression/tests/malloc.c: added tests for new functionality
8641         * support/regression/tests/zeropad.c: added tests for truncated initializers
8642           and initialized char arrays starting with '\x0'
8643         * src/mcs51/peeph.def: fixed regression, added peephole 177.f
8644
8645 2004-07-26 Bernhard Held <bernhard AT bernhardheld.de>
8646
8647         * support/valdiag/tests/overflow.c: fixed warning on (1 >> 40)
8648
8649 2004-07-26 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8650
8651         * doc/sdccman.lyx: updated example in section "Absolute Addressing"
8652         * src/mcs51/peeph.def: added contributed fix for "bug" #995347 as
8653         peephole 177.e. Thanks to anonymous
8654
8655 2004-07-25 Vangelis Rokas <vrokas AT otenet.gr>
8656
8657         * src/pic16/glue.c (pic16_printIvalFuncPtr): when an extern
8658         function isn't used in the source but referenced as a
8659         variable initializer then declare it as extern in .asm file
8660
8661 2004-07-24 Vangelis Rokas <vrokas AT otenet.gr>
8662
8663         * .version: increased version number to 2.4.3
8664
8665         Adding version extension according to ChangeLog CVS revision
8666         * src/Makefile.in (target all): added dependency 'version.h'
8667         * (rule version.h): added rule to create version.h from ChangeLog,
8668         * (rule dep): added dependency version.h,
8669         * src/version.awk: AWK script to create version.h
8670         * src/SDCCdwarf2.c (dwWriteModule),
8671         * src/SDCCglue.c (initialComments),
8672         * src/SDCCmain.c (printVersionInfo): modified to write after
8673         version string the version extension number,
8674         * src/SDCCutil.c: included "version.h"
8675         * (getBuildNumber): NEW, returns SDCC's ChangeLog minor revision
8676         number,
8677         * src/SDCCutil.h: added prototype for getBuildNumber
8678
8679         * src/SDCCmain.c (parseCmdLine): when sOpt is 'I' add rest in
8680         includeDirsSet, too,
8681         * src/SDCCsymt.c (checkSClass): don't emit error when a variable,
8682         const char [] is found in function prototype...
8683
8684         * src/pic16/genarith.c (pic16_genUMult8XLit_8): optimization to omit
8685         moving to WREG with source is already in WREG,
8686         * src/pic16/gen.h: added AOP_FSR0 and AOP_FSR2 in enum,
8687         * src/pic16/gen.c (getFreePtr): updated to look for FSR0 and FSR2,
8688         * (aopForSym): stack'ed symbols are partially supported, added
8689         if-clause to support symbols in FARSPACE,
8690         * (sameRegs): added test for AOP_ACC to see if registers are same,
8691         * (pic16_freeAsmop): added case for AOP_FSR0 and AOP_FSR2,
8692         * (pic16_aopGet): added case for AOP_FSR0 and AOP_FSR2,
8693         * (pic16_popRegFromString): will not allocate a new register if it
8694         doesn't find one by name, bug may have introduced...
8695         * (pic16_popGet): added case for AOP_FSR0 and AOP_FSR2,
8696         * (genIpush): revived to use pic16 port's stack,
8697         * (genAddrOf): added incomplete case for stack'ed operand,
8698         * (genCast): optimized a pair of MOVFW,MOVWF to MOVFF
8699         * src/pic16/genutils.c (pic16_genNot): almot new vesrion for NOT,
8700         can handle multibyte operands,
8701         * src/pic16/glue.c (pic16_printIval*): some debug info added,
8702         * (pic16initialComments): added message for MPLAB compatibility
8703         mode enabled,
8704         * src/pic16/main.h: prototype for pic16_mplab_comp,
8705         * src/pic16/main.c (pic16_optionsTable): new option --mplab-comp,
8706         which enabled MPLAB compatibility mode (i.e. no #LINE/#FILE, BANKED)
8707         * (_pic16_linkEdit): NEW, handles link stage, transferred here
8708         because of increased complexity of procedure,
8709         * (_process_pragma): stack pragma changed to format 'stack pos len',
8710         emit symbol '_stack_end' to conform with gplink,
8711         * src/pic16/pcode.c (pic16_newpCodeOpBit): using pic16_regWithName
8712         to search for register,
8713         * (pic16_get_op, pic16_get_op2): added case for PO_W, PO_WREG and
8714         PO_GPR_REGISTER,
8715         * (pic16_pCode2str): when in MPLAB compatibility mode, comment out
8716         #LINE directives and replace 'B' with 'BANKED' in instruction opcodes
8717         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
8718         case for PO_GPR_REGISTER,
8719         * (pic16_AnalyzeBanking): removed the old message for inc2h.pl, past
8720         dies, the new era is ahead !...
8721         * src/pic16/ralloc.c: added hash reposits pic16_dynAllocRegNames and
8722         pic16_dynInternalRegs,
8723         * (pic16_allocregWithName, pic16_procregWithName, pic16_regWithname): NEW,
8724         * (pic16_allocDirReg): minor optimizations and bug fixes,
8725         * (pic16_allocWithIdx): when searching pic16_dynProcessorRegs use fixed,
8726
8727         * device/lib/pic16/startup/crt0*.c: extern definition of stack_end,
8728         load stack and frame pointer with address of 'stack_end' symbol
8729
8730 2004-07-23 Vangelis Rokas <vrokas AT otenet.gr>
8731
8732         * src/pic16/glue.c (pic16emitStaticSeg): fixed bug with files
8733         without source code but only variable initializers
8734
8735 2004-07-20 Vangelis Rokas <vrokas AT otenet.gr>
8736
8737         * src/pic16/glue.c (pic16emitRegularMap): unused functions marked as
8738         external are not declared as extern to reduce overhead while linking
8739
8740 2004-07-20 Maarten Brock <sourceforge.brock AT dse.nl>
8741
8742         * src/SDCCast.c (decorateType): removed buggy fix for bug #979599
8743
8744 2004-07-11 Maarten Brock <sourceforge.brock AT dse.nl>
8745
8746         * src/SDCCglue.c (printIvalArray): fixed bug #984229, thanks to Phuah
8747           Yee Keat for the patch
8748         * src/SDCCast.c (decorateType): fixed bug #979599
8749         * src/ds390/gen.h: removed local fReturnSizeDS390
8750         * src/ds390/gen.c: made fReturnSizeDS390 signed short to remove a warning
8751         * src/ds390/gen.c (genAnd, genOr, genXor),
8752         * src/mcs51/gen.c (genAnd, genOr, genXor): generate better optimized code
8753
8754 2004-07-04 Vangelis Rokas <vrokas AT otenet.gr>
8755
8756         * src/SDCCmain.c (linkEdit): modifications only for pic16 port,
8757         add relFilesSet to $3, manipulate $2 to handle linking of object
8758         files without source files in command line,
8759         * device/include/pic16 (all headers): added ID location macros,
8760         * src/pic16/device.c (struct PIC16_device Pics16[]): added field
8761         entries for ID location bytes,
8762         * (pic16_assignIdByteValue): NEW,
8763         * src/pic16/device.h: new structures idRegInfo_t and idBytesInfo_t,
8764         added field dumpcalltree to pic16_options_t,
8765         * src/pic16/gen.c (genCmp): fixed bug case so a temporary register
8766         is used instead of pic16_Gstack_base_addr, check if (ifx) before
8767         emitting rFalseIfx label after check_carry label,
8768         * src/pic16/glue.c (PIC16_IS_IDLOC_ADDRESS, PIC16_IS_HWREG_ADDRESS,
8769         pic16_emitDIRegs), NEW
8770         * (pic16glue): dump .calltree file when option --calltree found,
8771         * src/pic16/main.c (OPTION _pic16_optionsTable): new option --calltree
8772         * (_pic16_genAssemblerPreamble): emit ID locations after
8773         configuration registers,
8774         * (pic16_linkCmd): modifications of the link command,
8775         * src/pic16/pcode.c (pic16_pciMOVFF): PCC_REGISTER replaces PCC_REGISTER2
8776         * (pic16_pCodeInitRegisters): don't init stack registers,
8777         * (pic16_findPrevInstruction): fixed bug,
8778         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): fixed
8779         bug with immediate registers,
8780         * (buildCallTree): traces stack push and pop,
8781         * (pct2): dump also stack usage for each function,
8782         * src/pic16/ralloc.c (dynrIdx): registers names start from 0x00
8783         * (pic16_allocDirReg): various modifications,
8784         * (pic16_typeRegWithIdx): when searching pic16_dynProcessorRegs set
8785         fixed to 1,
8786
8787 2004-07-02 Vangelis Rokas <vrokas AT otenet.gr>
8788
8789         * src/pic16/pcode.c: removed buggy double colon
8790
8791 2004-07-01 Borut Razem <borut.razem AT siol.net>
8792
8793         * support/scripts/sdcc.nsi: added include/pic16 to setup
8794
8795 2004-06-30 Vangelis Rokas <vrokas AT otenet.gr>
8796
8797         * device/lib/Makefile.in: fixed bug in target objects-pic16,
8798         * device/lib/pic16/Makefile: prefixed with dash (-) command under
8799         target 'clean',
8800         * doc/sdccman.lyx: changed version to 2.4.2 and added some port
8801         specific command line arguments. Also added sample lkr script
8802         for placing a variable at a specific memory bank.
8803         * src/pic16/device.c (pic16_dump_gsection): NEW, to dump variables
8804         at a specific memory bank,
8805         * (pic16_dump_isection): fixed bug which caused string literals to
8806         be omitted when dumping idata section,
8807         * (pic16_groupRegistersInSection): added code to handle registers
8808         in specific memory banks,
8809         * src/pic16/gen.c: labelOffset is prefixed with pic16_ and made
8810         public, all references are renamed too,
8811         * (pic16_aopGet): removed switch cases for AOP_R0,AOP_R1,AOP_DPTR,
8812         AOP_DPTR2,
8813         * (pic16_storeForReturn): added case to handle when dest is WREG,
8814         * src/pic16/genarith.c (pic16_pCodeOpSubType): NEW,
8815         * src/pic16/glue.c (pic16emitRegularMap): when adding a register in
8816         pic16_rel_udata, check to see if that register is marked as being
8817         a member of a specific memory bank,
8818         * (pic16_printIvalCharPtr): added code to add string literals either
8819         to code or the idata sections,
8820         * src/pic16/main.c (_process_pragma): added \n to WHITE constant,
8821         also accept the 'udata' pragma,
8822         * src/pic16/main.h: new structure types sectName and sectSym
8823         * src/pic16/pcode.c: added new pCodeInstruction entry for BANKSEL
8824         * (newpCodeOpBit): added PIC_OPTYPE subt in function prototype,
8825         * (pic16_findPrevInstruction): fixed, it returned nothing,
8826         * (insertBankSwitch): fixed to emit banksel/skip and skip/banksel
8827         instruction combinations,
8828         * (pic16_FixRegisterBanking): heavily reorganised,
8829         * (pic16_AnalyzeBanking): if generating banksel directives is
8830         disabled, then don't call FixRegisterBanking at all,
8831         * src/pic16/ralloc.c (bitEQUs, aliasEQUs, allDefsOutOfRange):
8832         completely removed,
8833         * (pic16_writeUsedRegisters): added call to pic16_dump_gsection
8834
8835 2004-06-29 Bernhard Held <bernhard AT bernhardheld.de>
8836
8837         * src/SDCCglue.c (printChar): fixed bug #973350, patch provided by
8838         Phuah Yee Keat <yk.phuah AT nestac.com>
8839
8840 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
8841
8842         * src/pic16/glue.c (pic16createInterruptVect): function now emits
8843         correctly the IVT even if it is relocated to some other location
8844
8845 2004-06-28 Vangelis Rokas <vrokas AT otenet.gr>
8846
8847         * device/include/pic16/pic18fregs.h: added case for pic18f2220.h
8848         * device/include/pic16/pic18f2220.h: NEW,
8849         * device/lib/pic16/libdev/pic18f2220.c: NEW,
8850         * device/lib/pic16/libdev/Makefile: added 18f2220 in DEVS,
8851         * src/pic16/device.c (struct Pics16): added info for 18f2220,
8852         * src/pic16/device.h (struct pic16_options): added ivt_loc and
8853         nodefaultlibs, ivt_loc is the location of the interrupt vector
8854         table, and nodefaultlibs signs that default libraries should not be
8855         linked in link stage,
8856         * src/pic16/gen.c (genFunction): relocate interrupt vector functions
8857         according to --ivt-loc argument,
8858         * src/pic16/main.c (_process_pragma): emit '_stack' as public symbol
8859         when pragma stack is found,
8860
8861 2004-06-25 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8862
8863         * src/mcs51/peeph.def: added peepholes 182.d (return 0.0),
8864         256 (range check), 257 (do while), 258.a-f (bit banging
8865         f.e. on 3-wire SPI bus)
8866
8867 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8868
8869         * src/SDCClrange.c (findNextUseSym): fixed a live range bug with
8870         variables used exclusively within a loop
8871
8872 2004-06-21 Bernhard Held <bernhard AT bernhardheld.de>
8873
8874         * src/mcs51/gen.c (genCpl): quick fix for bug #974835
8875
8876 2004-06-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8877
8878         * src/SDCClrange.c (computeClash): fixed bug #971834
8879
8880 2004-06-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8881
8882         * src/mcs51/gen.c (genCmp): fixed bug #975903
8883         * src/hc08/gen.c (operandsEqu),
8884         * src/ds390/gen.c (operandsEqu),
8885         * src/z80/gen.c (operandsEqu),
8886         * src/pic/gen.c (operandsEqu),
8887         * src/pic16/gen.c (operandsEqu),
8888         * src/mcs51/gen.c (operandsEqu): fixed bug #976283
8889         * src/SDCCmain.c (parseCmdLine): report --unknown-option only once
8890
8891 2004-06-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8892
8893         * src/SDCCcse.c (cseBBlock): fixed bug #966963
8894
8895 2004-06-12 Vangelis Rokas <vrokas AT otenet.gr>
8896
8897         * src/pic16/gen.c (genPointerGet): added E_INTERNAL_ERROR for
8898         default case in switch statement,
8899         * glue.c (pic16_initPointer): expr is initialised via decoarteType
8900         to eliminate problem with initialisation of pointers, but problem
8901         still exists,
8902         * (pic16_pointerTypeToGPByte): removed, no needed for pic16,
8903         * (emitStaticSegment): removed various lines emitting debug info,
8904         * src/pic16/pcode.c, src/pic16/pcode.h, src/pic16/ralloc.h:
8905         added processor registers for utilizing EEPROM,
8906         * src/pic16/pcode.c (pic16_emitDB): number of DBs emitted is not
8907         configurable and set 8
8908
8909 2004-06-08 Vangelis Rokas <vrokas AT otenet.gr>
8910
8911         * .version: increased version number to 2.4.2,
8912
8913         Cumulative patch for pic16 port
8914         * src/pic16/device.c: changed scheme to dump initial values for
8915         variables in idata segment, all print_idata* functions were removed,
8916         now the pic16_printIval* will be called,
8917         * src/pic16/glue.c: (pic16_initPointer, pic16_pointerTypeToGPByte,
8918         * _pic16_printPointerType, pic16_printPointerType,
8919         * pic16_printGPointerType, pic16_printIvalArray, pic16_printIvalStruct,
8920         * pic16_printIvalBitFields, pic16_printIvalFuncPtr, pic16_printIvalPtr:
8921         NEW, similar to the respective functions in SDCCglue.c,
8922         * src/pic16/pcode.c (pic16_emitDB, pic16_flushDB): reverted to old
8923         way, emitting hex bytes,
8924         * (pic16_emitDS): NEW, emits a string for pointer initialisation,
8925
8926 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8927
8928         * src/avr/ralloc.c (serialRegAssign),
8929         * src/xa51/ralloc.c (serialRegAssign),
8930         * src/pic/ralloc.c (serialRegAssign),
8931         * src/pic16/ralloc.c (serialRegAssign),
8932         * src/hc08/ralloc.c (serialRegAssign),
8933         * src/z80/ralloc.c (serialRegAssign),
8934         * src/ds390/ralloc.c (serialRegAssign),
8935         * src/mcs51/ralloc.c (serialRegAssign): fixed bug #964479
8936
8937 2004-06-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
8938
8939         * src/SDCCicode.c (geniCodeJumpTable): fixed bug #967601
8940         * src/SDCCpeeph.c (labelIsReturnOnly): fixed bug #966505
8941
8942 2004-06-07 Vangelis Rokas <vrokas AT otenet.gr>
8943
8944         Cumulative patch for pic16 port:
8945         * src/pic16/device.h (typedef PIC16_device) modified fields for
8946         defining microcontrollers,
8947         * src/pic16/device.c: added new info for all devices in Pics16 array,
8948         * src/pic16/gen.c (genPcall): fixed bug that caused the return label
8949         to be optimised out by the pCode optimiser,
8950         * src/pic16/glue.c (pic16emitRegularMap): treat implicit aggragates
8951         specially, bug reported by G.M. Gallant,
8952         * src/pic16/pcode.c (pic16_newpCodeLabelFORCE): NEW, marks a label
8953         as force'd so that cannot be optimised out by pCode optimiser,
8954         * src/pic16/pcode.c,
8955         * src/pic16/pcodepeeph.c,
8956         * src/pic16/pcoderegs.c: many modifications to re-enable peepholes,
8957         they are disabled by default, but can be enabled explicit with
8958         command argument --denable-peeps, for testing,
8959         * device/lib/pic16/startup/Makefile: added --no-peep,--pomit-config-words,
8960         --pomit-ivt in COMPILE_FLAGS
8961
8962 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
8963
8964         * src/pic16/pcode.c (pic16_emitDB): removed double semicolon which fails
8965           compilation on MSVC
8966
8967 2004-06-06 Maarten Brock <sourceforge.brock AT dse.nl>
8968
8969         * device/include/sab80515.h: added sfr P6, changed GPL to LGPL
8970
8971 2004-06-06 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8972
8973         device/include/sab80515.h: fixed bug #967492, DAPR is defined at adress
8974         0xd8, but the correct adress is 0xda. Thanks to anonymous for reporting
8975
8976 2004-06-06 Vangelis Rokas <vrokas AT otenet.gr>
8977
8978         * src/pic16/device.c (pic16_assignConfigWord): fixed bug that
8979         would only assign 0x300001 register.
8980
8981 2004-06-05 Vangelis Rokas <vrokas AT otenet.gr>
8982
8983         * device/lib/pic16/startup/Makefile: added $(MODELFLAGS)
8984         in COMPILE_FLAGS. Thanks to G. Gallant for report.
8985
8986 2004-06-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
8987
8988         * doc/sdccman.lyx: minor changes, mentioned beta vendor support
8989         for ds80c400
8990         * src/mcs51/peeph.def: ran unexpand -a over peeph.def
8991         * src/mcs51/peeph.def: removed obsolete peephole 100.a,
8992         added peephole 254 (left shift), 255 (jump table)
8993
8994 2004-06-04 Vangelis Rokas <vrokas AT otenet.gr>
8995
8996         * device/lib/Makefile.in: removed comment line with model-pic16,
8997         * (target port-specific-objects-pic16): the libraries and objects
8998         are copied to the build directory form the device/lib/pic16/bin
8999         directory
9000
9001         Cumulative patch concerning pic16 port:
9002         * library directory has been re-organized,
9003         * added support for PIC18F1220,
9004         * added headers and library sources for chips 18f1220,18f6520,
9005         18f6620,18f6680,18f6720,18f8520,18f8620,18f8680,18f8720
9006
9007         * configuration registers setting has changed, now each supported
9008         device has a complete description of the registers it uses,
9009         * all initialisations are moved to idata sections, these section
9010         can be absolute or relocatable,
9011         * fixed initialisation of codespace variables,
9012         * fixed warning about PCLATU and gpsim,
9013         * src/pic16/gen.c (genCmp): now can handle partially iCodes with no ifx,
9014         * (genAssign): use table reads when assigning from variables in codespace,
9015         * src/pic16/glue.c (pic16emitStaticSeg): fixed to correctly initialise
9016         char/int variables placed in codespace,
9017         * (pic16_emitConfigRegs): NEW, emits a list with configuration
9018         registers set in .asm file, no need for --pomit-config-words anymore,
9019         * (pic16glue): some 8051 legacy segments are commented out
9020         (to be removed completely),
9021         * added support for alternative assembler and linker with --asm=
9022         and --link= command line arguments,
9023         * peepholes are disabled automatically in the port, no need to
9024         specify on command line,
9025         * port supports natively char/int/long multiplication, but converts
9026         all divisions to support functions,
9027         * main.c: pic16_linkCmd and pic16_asmCmd changed to force output
9028         to the file set in variable $2,
9029         * pcode.c (pic16_emitDB, pic16_flushDB): modified to print printable
9030         strings in ASCII format and not in hex,
9031         * ralloc.c (serialRegAssign): added a triplet of conditional calls
9032         to pic16_allocDirReg for IC_RESULT, IC_LEFT and IC_RIGHT so to
9033         allocate proper register if iCodes aren't temporary,
9034
9035 2004-06-02 Maarten Brock <sourceforge.brock AT dse.nl>
9036
9037         * support/regression/tests/zeropad.c: added TEST_G macro for alpha
9038
9039 2004-06-02 Vangelis Rokas <vrokas AT otenet.gr>
9040
9041         * src/pic16/gen.c (genPcall): warning about gpsim and PCLATU
9042         is commented out
9043
9044 2004-06-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9045
9046         * src/hc08/gen.c (genPointerGetSetOfs): disabled optimization if
9047         computed address is reused
9048         * src/hc08/gen.c (genPackBits): fixed offsets in assignments to
9049         multi-byte bitfields
9050
9051 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
9052
9053         * src/z80/gen.c: (genArrayInit): must check for pointers too
9054
9055 2004-06-01 Maarten Brock <sourceforge.brock AT dse.nl>
9056
9057         * support/regression/tests/zeropad.c: never meant to commit the
9058           nestedstruct test: removed, added check for GCC version
9059
9060 2004-05-31 Maarten Brock <sourceforge.brock AT dse.nl>
9061
9062         * src/SDCCast.c (createIvalArray): fixed bug 770487 SIGSEGV
9063         * src/SDCCglue.c (emitRegularMap): fixed bug 770484 allocation problem
9064         * src/SDCCglue.c (initPointer, printIvalType, printIvalStruct,
9065           printIvalArray, printIvalFuncPtr, printIvalPtr, printIval): fixed
9066           bugs 928906 and 954082 half-empty initializers
9067         * src/SDCCsymt.h,
9068         * src/SDCCsymt.c (getAllocSize): added for above fix
9069         * src/z80/gen.c (genArrayInit): fixed bug 741044
9070         * support/regression/tests/zeropad.c: added tests
9071
9072 2004-05-30 Vangelis Rokas <vrokas AT otenet.gr>
9073
9074         * src/pic16/device.c (pic16_dump_section): corrected bug which
9075         caused some symbols of the libraries to be misplaced
9076
9077 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
9078
9079         * src/pic16/glue.c,
9080         * src/pic16/ralloc.h,
9081         * src/pic16/ralloc.cc: prefixed IS_CONFIG_ADDRESS with PIC16_
9082         to fix conflict with pic port
9083
9084 2004-05-28 Vangelis Rokas <vrokas AT otenet.gr>
9085
9086         * src/pic16/glue.c (pic16emitStaticSeg): do not print as publics or
9087         externs configuration variables,
9088         * src/pic16/ralloc.h,
9089         * src/pic16/ralloc.cc: IS_CONFIG_ADDRESS is made public and added
9090         prototype in header, commented out some debug messages
9091
9092 2004-05-26 Vangelis Rokas <vrokas AT otenet.gr>
9093
9094         * src/pic16/glue.c,
9095         * src/pic16/main.c,
9096         * src/pic16/pcode.c: added gpasm directives #FILE/#LINE
9097         for gpasm COFF object generation. Thanks to D. Hawkins for
9098         his patch info
9099
9100 2004-05-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9101
9102         * src/ds390/main.c,
9103         * src/mcs51/main.c: fixed sort order of mnemonics (thanks to Maarten
9104         Brock for spotting this)
9105         * src/ds390/gen.c (genEndFunction),
9106         * src/mcs51/gen.c (genEndFunction): always save psw if function is an
9107         interrupt handler and critical. Disable push/pop optimizations when
9108         peephole optimizations disabled.
9109
9110 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
9111
9112         Updated pic16 library sources and headers.
9113         * device/lib/pic16/pic18f*/ ,
9114         * device/include/pic16/*.h: modified to handle structured SFR
9115         definitions
9116
9117 2004-05-25 Vangelis Rokas <vrokas AT otenet.gr>
9118
9119         * src/port.h (PORT structure): added hook initPaths, now each
9120         port can declare its own default search paths,
9121         which can been seen with the --print-search-dirs option,
9122         see pic16 port for example,
9123         * src/SDCCmain.c (setBinPaths, setIncludePaths, setLibPath,
9124         setDataPaths): test to options.printSearchDirs is ifdef'ed out,
9125         * (doPrintSearchDirs): NEW, replaces in a central manner the
9126         printing of search dirs which was split in set*Paths functions,
9127         * (main): added call to port->initPaths and doPrintSearchDirs,
9128         * src/avr/main.c,
9129         * src/ds390/main.c,
9130         * src/hc08/main.c,
9131         * src/izt/i186.c,
9132         * src/izt/tlcs900h.c,
9133         * src/mcs51/main.c,
9134         * src/pic/main.c,
9135         * src/pic16/main.c: modified port structures to reflect addition of
9136         initPaths hook,
9137
9138         * src/pic16/device.c (regCompare): registers are finally sorted by name,
9139         * (pic16_dump_section): for registers in same address reserve memory once,
9140         * src/pic16/device.h (struct PIC16_device): changed variable gen_banksel
9141         to no_banksel,
9142         * src/pic16/genarith.c (pic16_genPlus): added code to handle cases where
9143         result is greater in size than right or left,
9144         * (pic16_genUMult8X8_8): there are some cases where the result can
9145         be 16 bits size, so handle these,
9146         * src/pic16/gen.c: changed some pic16_emitpcomment to DEBUGpic16_emitcode,
9147         * (pic16_outBitC): modified to emit pcodes,
9148         * (pic16_storeForReturn): using is_LitOp to see if operand is literal
9149         or not,
9150         * (genDivOneByte): implemented algorithm to divide 8-bits,
9151         * (genCmp): uncommented goto, but issues still exist,
9152         * (genAnd): fixed a bug with variables >8bits,
9153         * (genPackBits): optimization added that uses BCF/BSF to change a
9154         single bit,
9155         * (genAssign): fixed bug when assigning floating point literals,
9156         * src/pic16/glue.c (pic16glue): added assembler directive 'code' before
9157         __sdcc_gsinit_startup label,
9158         * src/pic16/main.c (_pic16_init): removed search directory
9159         initialisations,
9160         * (_pic16_initPaths): NEW, used to initialise search directories,
9161         * (_hasNativeMulFor): support functions for all except char/int
9162         multiplication, and char division,
9163         * (PIC16_port struct): modified entry for native mul support,
9164         * src/pic16/pcode.c (insertBankSwitch): modified to support the renamed
9165         no_banksel option,
9166         * (buildCallTree): call to register_usage is ifdef'ed out,
9167
9168 2004-05-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9169
9170         * device/include/string.h: applied Stas Sergeev's patch to make this
9171         header file compatible with the preprocessor -Wundef option
9172         * src/SDCCmain.c (main): abort compilation if preprocessor reports
9173         failure (fixes bug #941458)
9174
9175 2004-05-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9176
9177         * src/SDCCopt.c (killDeadCode): fixed bug #907733
9178         * support/Util/SDCCerr.c: reworded E_AUTO_ASSUMED diagnostic to clarify
9179         that the variable, not the function, should be static
9180         * src/SDCCval.c (valCastLiteral): fixed bit initialization from literal
9181         to be consistent with non-literal case
9182
9183 2004-05-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9184
9185         * src/SDCCast.c (isConformingBody): fixed bug #949967
9186         * src/SDCCopt.c (cnvToFcall, cnvToFloatCast, cnvFromFloatCast,
9187         convilong): fixed bug #952086
9188
9189 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9190
9191         * src/SDCCmem.c (allocVariables): fixed bug #955321
9192
9193 2004-05-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9194
9195         * src/hc08/main.c (_hc08_genAssemblerEnd),
9196         * src/SDCCdwarf2.c (dwOpenFile, dwCloseFile, dwWriteFunction,
9197         dwWriteModule, dwWriteCLine, dwWriteALine, dwarf2FinalizeFile):
9198         completely eliminated the use of a temporary file
9199         * src/SDCCdwarf2.c (dwWriteAttr): fixed bug with location list offset
9200         when more than one file linked
9201         * src/SDCCloop.c (pointerAssigned): fixed bug #954163
9202
9203 2004-05-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9204
9205         * src/SDCCval.c (valForArray): applied Maarten Brock's patch #947682
9206         which fixes bug #543481
9207         * support/regression/tests/bug-751703.c: fixed comments left from a
9208         cut and paste error
9209         * src/SDCCdwarf2.c (dwCloseFile): don't explicitly close a temp file
9210         * src/SDCCdwarf2.c (dwTagFromType): added bitfield support
9211         * src/SDCCdwarf2.c (dwWriteSymbolInternal): handle extern within local
9212         scopes
9213         * src/SDCCdwarf2.c (dwWriteLineNumber): line number deltas are signed
9214         * src/SDCCmain.c (processFile, parseCmdLine): non-alphanumeric chars
9215         are now changed to underscores in moduleName
9216
9217 2004-05-15 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9218
9219         * as/mcs51/lkmem.c: better fix for bug #954173
9220
9221 2004-05-15 Maarten Brock <sourceforge.brock AT dse.nl>
9222         committed by Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9223
9224         * device/include/c8051f020.h: newly added SiLabs (Cygnal) header file
9225         * device/include/c8051f000.h,
9226         * device/include/c8051f120.h,
9227         * device/include/c8051f300.h,
9228         * device/include/c8051f310.h,
9229         * device/include/c8051f320.h: updated (added _XPAGE, CAPN, CAPP,
9230         PWM16) and detab'ed
9231
9232 2004-05-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9233
9234         * doc/sdccman.lyx: mentioned sourceforge's delay between web frontend
9235         and mailing lists, doc'ed --no-peep-comments, removed reference
9236         to knoppix (newest version has no LyX/LaTeX), other minor changes
9237         * src/SDCCglue.c (glue): save 2 bytes stack space with
9238         option --main-return. The ljmp could probably be avoided too
9239
9240 2004-05-14 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9241
9242         * as/mcs51/lkmem.c, as/mcs51/lkaomf51: fixed bug 954173
9243
9244 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9245
9246         * src/SDCCsymt.h: added IS_AUTO(symbol) test macro
9247         * src/SDCCopt.c (isLocalWithoutDef),
9248         * src/SDCCicode.c (operandFromSymbol): use the IS_AUTO test macro
9249         which adds a !IS_EXTERN codition. Fixes bugs #877426 and #751703.
9250         (credit to Maarten Brock for patch #949363, on which this is based)
9251         * support/regression/tests/bug-751703.c: some test cases of extern used
9252         within inner scopes.
9253
9254 2004-05-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9255
9256         * src/SDCCdwarf2.c (dwMatchTypes): structs must have matching
9257         SPEC_STRUCT
9258         * src/SDCCdwarf2.c (dwTagFromType): fix to handle recursive
9259         struct definitions
9260         * src/SDCCdwarf2.c (dwWriteModule, dwNewDebugSymbol, dwWriteEndFunction,
9261         dwWriteLabel): fix to create valid debugger symbols even when
9262         the module name has non-alphanumeric symbols in it
9263         * src/SDCCdwarf2.c (dwWriteSymbolInternal): better detection for
9264         when a variable's allocation has been optimized away
9265
9266
9267 2004-05-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9268
9269         * src/hc08/gen.c (hc08_emitDebuggerSymbol),
9270         * src/hc08/main.c,
9271         * src/mcs51/gen.c (mcs51_emitDebuggerSymbol),
9272         * src/mcs51/main.c,
9273         * src/ds390/gen.c (ds390_emitDebuggerSymbol),
9274         * src/ds390/main.c,
9275         * src/z80/gen.c (z80_emitDebuggerSymbol),
9276         * src/z80/main.c,
9277         * src/pic/gen.c (pic14_emitDebuggerSymbol),
9278         * src/pic/main.c,
9279         * src/pic16/gen.c (pic14_emitDebuggerSymbol),
9280         * src/pic16/main.c,
9281         * src/avr/gen.c (avr_emitDebuggerSymbol),
9282         * src/avr/main.c,
9283         * src/xa51/gen.c (xa51_emitDebuggerSymbol),
9284         * src/xa51/main.c,
9285         * src/SDCCdebug.c (emitDebuggerSymbol),
9286         * src/SDCCdebug.h,
9287         * src/port.h: added a debugger struct to the port struct. Added a
9288         callback for defining debugger symbols
9289
9290         * src/SDCCast.c (createLabel),
9291         * src/SDCC.y (labeled_statement): mark all compiler generated labels
9292         with isitmp = 1
9293         * src/SDCCicode.h,
9294         * src/SDCCicode.c (geniCodeFunctionBody): added a link from the FUNCTION
9295         iCode back to the ast for the function
9296
9297         * src/hc08/ralloc.c (hc08_assignRegisters),
9298         * src/hc08/ralloc.h: define a regs struct for the stack pointer. Removed
9299         unneeded fields from the regs struct.
9300         * src/hc08/gen.c (transferRegReg, genFunction, genEndFunction): use the
9301         pushReg() & pullReg() functions instead of emitcode()
9302
9303         * src/hc08/gen.c (genLabel, genhc08Code),
9304         * src/SDCCdebug.h: Added additional debugger hooks needed for DWARF
9305
9306         * src/cdbFile.c (cdbWriteLabel, cdbWriteScope): Added stubs for unneeded
9307         debugger hooks
9308
9309         * src/hc08/gen.c (genEndFunction, genhc08Code),
9310         * src/hc08/gen.h,
9311         * src/mcs51/gen.c (genEndFunction, gen51Code),
9312         * src/mcs51/gen.h,
9313         * src/ds390/gen.c (genEndFunction, gen390Code),
9314         * src/ds390/gen.h,
9315         * src/z80/gen.c (genEndFunction, genZ80Code),
9316         * src/z80/gen.h,
9317         * src/z80/z80.h,
9318         * src/pic/gen.c (genEndFunction, genpic14Code),
9319         * src/pic/gen.h,
9320         * src/pic16/gen.c (genEndFunction, genpic16Code),
9321         * src/pic16/gen.h,
9322         * src/avr/gen.c (genEndFunction, genAVRCode),
9323         * src/avr/gen.h,
9324         * src/xa51/gen.c (genEndFunction, genXA51Code),
9325         * src/xa51/gen.h,
9326         * src/cdbFile.c (cdbWriteFunction, cdbWriteEndFunction): moved cdb
9327         specific code to cdbFile.c and out of the backend code generators
9328
9329         * as/hc08/lkmain.c (main): removed OMF51 support from link-hc08
9330         * as/hc08/lkarea.c (lnkarea): areas with NOLOAD attribute default
9331         starting address is now 0
9332
9333         * as/hc08/asm.h,
9334         * as/hc08/m08pst.c,
9335         * as/hc08/asmain.c (asmbl): implemented the .sleb128 and .uleb128
9336         assembler directive for DWARF support
9337         * as/hc08/lkelf.c (elf): only increment address when rtflg[] set
9338
9339         * src/src.dsp,
9340         * src/Makefile.in,
9341         * src/SDCCdwarf2.c: preliminary DWARF (ver 2) debugger data generator
9342
9343 2004-05-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9344
9345         * src/hc08/gen.c (genJumpTab, emitcode, genhc08code): fixed stack error
9346         and inappropriate peephole optimization in jump tables
9347
9348 2004-04-30 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9349
9350         * as/hc08/m08pst.c,
9351         * src/SDCCglue.c: sdccopt works for the hc08 port now
9352
9353 2004-04-27 Bernhard Held <bernhard AT bernhardheld.de>
9354
9355         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): fixed bug #942130
9356
9357 2004-04-27 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9358
9359         * as/hc08/lkelf.c: sdccconf.h is not available in WIN32
9360
9361 2004-04-24 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9362
9363         * src/SDCCpeeph.c (replaceRule): support empty replacement peephole
9364         rules
9365         * src/SDCCmain.c,
9366         * src/SDCCglobl.h,
9367         * src/SDCCpeeph.c (getPeepLine): new option --no-peep-comments omits
9368         comments from the peephole optimizer replacement rules
9369         * src/SDCCmem.c (printAllocInfoSeg): give actual location of spilled
9370         symbols
9371         * src/SDCCcse.c (updateSpillLocation),
9372         * src/SDCCopt.c (killDeadCode, findReqv): better tracking of register
9373         equivalents
9374         * src/hc08/ralloc.c (regTypeNum): pseudo symbols must be in DATA only
9375         * src/hc08/main.c (_hc08_finaliseOptions): made pointers to stack
9376         objects far pointers
9377
9378 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9379
9380         * src/SDCCsymt.h: a missing part of my last change
9381         * src/pic/ralloc.c (regTypeNum),
9382         * src/pic16/ralloc.c (regTypeNum): fixed statement/declaration order
9383
9384 2004-04-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9385
9386         * src/SDCCicode.h,
9387         * src/SDCCicode.c (aggrToPtrDclType),
9388         * src/SDCCptropt.h,
9389         * src/SDCCptropt.c (ptrBaseRematSym, ptrPseudoSymSafe,
9390         ptrPseudoSymConvert),
9391         * src/pic/ralloc.c (regTypeNum),
9392         * src/pic16/ralloc.c (regTypeNum),
9393         * src/hc08/ralloc.c (regTypeNum),
9394         * src/ds390/ralloc.c (regTypeNum),
9395         * src/mcs51/ralloc.c (regTypeNum): check for dependancy hazards before
9396         creating pseudo symbols (fixed bugs #777768, #930484, and #933966)
9397
9398 2004-04-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9399
9400         * link/z80/lkmain.c (afile),
9401         * as/hc08/lkmain.c (afile),
9402         * as/mcs51/lkmain.c (afile): fix suggested by Maarten Brock to
9403         prevent a pointer problem when a filename has no directory and
9404         no extension specified.
9405
9406 2004-04-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9407
9408         * link/z80/lkmain.c (afile): allow periods in directory names
9409         * link/z80/lkmain.c (afile),
9410         * as/mcs51/lkmain.c (afile),
9411         * as/hc08/lkmain.c (afile): allow linker script file to have an
9412         extension other than ".lnk"
9413         * link/z80/lklex.c (getfid),
9414         * link/z80/lkmain.c (parse),
9415         * as/mcs51/lklex.c (getfid),
9416         * as/mcs51/lkmain.c (parse),
9417         * as/hc08/lklex.c (getfid),
9418         * as/hc08/lkmain.c (parse): Support comments in the linker script
9419         file on lines by themselves and after filenames
9420
9421 2004-04-20 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9422
9423         * as/link_hc08.dsp: Added as/hc08/lkelf.c to project.
9424
9425 2004-04-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9426
9427         * src/z80/peeph-z80.def: removed some peephole rules that don't
9428         work with multibyte arithmetic (fixed bug #937126)
9429         * src/mcs51/peeph.def: fixed peephole rules 150-158 to apply only
9430         to registers and not global variables
9431         * src/SDCCicode.c (geniCodeAssign, ast2iCode, geniCodePostInc,
9432         geniCodePreInc, geniCodePostDec, geniCodePreDec,
9433         geniCodeLogicAndOr, geniCodeConditional): enforce strict lvalue
9434         checking for assignments not internally generated (fixed bug #931895)
9435         * src/SDCC.y (postfix_expr): ignore typedefs when looking for a
9436         structure member (fixed bug #930072)
9437
9438 2004-04-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9439
9440         * src/SDCCmain.c (linkEdit),
9441         * src/hc08/main.c (_hc08_parseOptions),
9442         * as/hc08/Makefile.in,
9443         * as/hc08/aslink.h,
9444         * as/hc08/asm.h,
9445         * as/hc08/m08pst.c,
9446         * as/hc08/lkrloc.c (relr, rele),
9447         * as/hc08/lkarea.c (lnkarea)
9448         * as/hc08/lkmain.c (afile, parse),
9449         * as/hc08/lkelf.c: support for ELF output
9450         * as/hc08/lks19.c (s19),
9451         * as/hc08/lkihx.c (ihx): ignore areas with the NOLOAD attribute
9452
9453 2004-04-17 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9454
9455         * as/mcs51/lkihx.c: Fixed bug #899105.
9456
9457 2004-04-16 Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
9458
9459         * doc/sdccman.lyx: Added instructons on how to convert MSVC .dsw and
9460         .dsp files from Unix to DOS.
9461
9462 2004-04-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9463
9464         * doc/sdccman.lyx: removed the ANSI-C noncompliance note regarding
9465         function pointers; we have been compliant for several months now.
9466         * src/mcs51/ralloc.c (serialRegAssign): enabled part of my 2004-04-13
9467         change that was accidently commented out
9468         * src/mcs51/gen.c (freeAsmop, getFreePtr, freeForBranchAsmop, genIfxJump,
9469         genCmpEq, jmpTrueOrFalse, genCmp, genAnd, genOr, genXor, genIfx): fixed
9470         bug #922319
9471
9472 2004-04-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9473
9474         * src/hc08/gen.c: output of all of the internal debugging information
9475         is now controlled by the D() macro; it is disabled by default
9476
9477 2004-04-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9478
9479         * src/mcs51/ralloc.c (serialRegAssign, fillGaps, allocThisReg): try
9480         harder to keep the same registers during a CAST iCode
9481         * src/SDCCopt.c (optimizeCastCast, eBBlockFromiCode): casts of char to
9482         long via int can be done in a single cast, if the signedness is
9483         correct.
9484         * support/regression/tests/bug-927659.c: fixed to avoid conflict with
9485         putchar() in tinibios.c in ds390's library
9486
9487 2004-04-12 Bernhard Held <bernhard AT bernhardheld.de>
9488
9489         * src/SDCCast.c (decorateType): fixed bug #898889,
9490         cast result of a literal complement too
9491         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #930931,
9492         fixed check for bitfields
9493
9494 2004-04-11 Bernhard Held <bernhard AT bernhardheld.de>
9495
9496         * src/SDCCicode.c (geniCodeLogic): made it static,
9497         (geniCodeLogicAndOr): added in order to fix bug #905492,
9498         (ast2iCode): fixed bug #905492
9499         * support/regression/tests/bug-905492.c: added
9500         * src/SDCCast.c (decorateType): don't decorate/process parms twice,
9501         (processParms): fixed bug #927659: don't copy parms, this will clear
9502         decorated flag
9503         * support/regression/tests/bug-927659.c: added
9504
9505 2004-03-29 Bernhard Held <bernhard AT bernhardheld.de>
9506
9507         * src/SDCCast.c (addCast): don't cast float to char
9508         * device/lib/libsdcc.lib: added _memmove
9509
9510 2004-03-28 Bernhard Held <bernhard AT bernhardheld.de>
9511
9512         * device/lib/large/Makefile: fixed parallel execution by
9513         replacing `make` by `$(MAKE)`
9514
9515 2004-03-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9516
9517         * src/hc08/gen.c (genPointerGetSetOfs): correctly handle 1 byte array
9518         offsets (fixes bug #923936)
9519
9520 2004-03-26 Bernhard Held <bernhard AT bernhardheld.de>
9521
9522         * device/lib/small/Makefile: fixed parallel execution by
9523         replacing `make` by `$(MAKE)`
9524
9525 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
9526
9527         * device/lib/vprintf.c (vsprintf): minor optimization, see bug #801101
9528
9529 2004-03-23  Scott Dattalo  <scott AT dattalo.com>
9530
9531         * src/pic/gen.c (genCpl): multi-byte complements were not working.
9532         * src/regression/Makefile: Regression test was not running.
9533
9534 2004-03-23 Bernhard Held <bernhard AT bernhardheld.de>
9535
9536         * src/SDCCast.c (resultTypePropagate, decorateType): avoid promotion to int for
9537         complement if possible
9538         * src/SDCCval.c (valComplement),
9539         * src/SDCCicode.c (operandOperation): fixed complement of literal
9540         * support/regression/tests/onebyte.c (testComplement): added
9541
9542 2004-03-22 Bernhard Held <bernhard AT bernhardheld.de>
9543
9544         * src/SDCCast.c (processParms): fixed bug #920866; decorateType() can
9545         return an optimized tree; actually replace actParm with the new tree
9546         * src/SDCCast.h: added some parantheses to remove side effects
9547         * support/regression/tests/bug-920866.c
9548
9549 2004-03-21  Scott Dattalo  <scott AT dattalo.com>
9550         * src/pic/gen.c, src/pic/gen.h, src/pic/genarith.c, src/pic/pcode.c:
9551         Bit operands were not being handled properly in the pic14 port.
9552         (now src/regression/add.c passes again).
9553
9554 2004-03-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9555
9556         * src/SDCC.y (labeled_statement): case and default no longer require
9557         a following statement (RFE #893037)
9558
9559 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9560
9561         * src/mcs51/gen.c (pushSide, genSignedRightShift, genDjnz, geniPush):
9562         use MOVA macro to avoid "mov a,acc" when peephole optimizer is
9563         disabled (fixes bug #916294)
9564         * sim/ucsim/s51.src/mov.cc (inst_mov_a_addr): Throw an error on
9565         "mov a,acc"; patch provided by Lenny Story
9566         * device/include/mc68hc908gp32.h: header contibuted by Juan Gonzalez
9567
9568 2004-03-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9569
9570         * src/mcs51/gen.c (genFunction): optimize RECEIVE in reentrant
9571         functions
9572         * src/ds390/gen.c (genFunction, genEndFunction),
9573         * src/ds390/ralloc.c (ds390_assignRegisters),
9574         * src/mcs51/gen.c (genFunction, genEndFunction, mcs51_assignRegisters):
9575         * src/mcs51/ralloc.c (mcs51_assignRegisters): Skip optimizing registers
9576         pushed if there are parameters passed on the stack. Also, a cleaner
9577         way to decide if r0/r1 should be pushed/popped. (Together they fix
9578         bug #918693)
9579
9580 2004-03-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9581
9582         * doc/sdccman.lyx,
9583         * device/lib/mcs51/crtpagesfr.asm,
9584         * device/lib/mcs51/crtxinit.asm,
9585         * device/lib/mcs51/crtxstack.asm: Changed name of _PAGESFR to _XPAGE
9586         to avoid confusion with Si Lab's SFRPAGE register.
9587
9588 2004-03-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9589
9590         * src/SDCCglue.c (emitMaps): allow public sfr variables
9591         * src/SDCCglue.c (initialComments): include compiler build date
9592         with compiler version and put the timestamp of the generated
9593         assembly file on a serperate line to be less confusing.
9594         * src/port.h: added genInitStartup hook
9595         * src/avr/main.c,
9596         * src/ds390/main.c,
9597         * src/hc08/main.c,
9598         * src/pic/main.c,
9599         * src/pic16/main.c,
9600         * src/xa51/main.c,
9601         * src/z80/main.c: genInitStartup initialize as NULL (default to
9602         historical behaviour)
9603         * src/SDCCglue.c (glue): _sdcc_gsinit_startup is now port specific.
9604         * src/mcs51/main.c: (_mcs51_genInitStartup, _mcs51_genExtraAreas,
9605         _mcs51_genXINIT, _mcs51_genRAMCLEAR): link initialization code from the
9606         library instead of hard coding it into the compiler.
9607         * support/regression/ports/mcs51-stack-auto/spec.mk,
9608         * src/SDCCmain.c (linkEdit): added mcs51.lib to the link libraries
9609         * device/lib/mcs51/Makefile,
9610         * device/lib/small/Makefile,
9611         * device/lib/large/Makefile,
9612         * device/lib/mcs51/crtpagesfr.asm,
9613         * device/lib/mcs51/crtstart.asm,
9614         * device/lib/mcs51/crtxclear.asm,
9615         * device/lib/mcs51/crtxinit.asm,
9616         * device/lib/mcs51/crtclear.asm,
9617         * device/lib/mcs51/crtxstack.asm: move most of the mcs51 C runtime
9618         startup/initialization out of src/SDCCglue.c and src/mcs51/main.c
9619         and into user configurable files.
9620         * device/lib/clean.mk: clean mcs51 directory too
9621         * support/regression/tests/longlit.c: added static to T1 declaration
9622         * doc/sdccman.lyx: documented _PAGESFR sfr for customizing pdata
9623         accesses in the initialization code
9624
9625 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9626
9627         * device/include/mc68hc908qy.h: corrected declarations of FLBPR and
9628         OSCTRIMVAL as noted in bug #916008
9629
9630 2004-03-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9631
9632         * src/SDCCloop.c (basicInduction): fixed bug with loop induction
9633         in loops with multiple exits (reported as incorrect registers
9634         used by Martin Helmling in Sdcc-user list)
9635
9636 2004-03-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9637
9638         * src/ds390/main.c (_ds390_genAssemblerPreamble): cosmetic change,
9639         made ds390 register extensions look less like error messages
9640
9641 2004-03-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9642
9643         * src/SDCCglue.c (printIvalPtr): fixed bug with pointer initializer
9644         reported by Adam Wozniak in Sdcc-user list
9645
9646 2004-03-10 Bernhard Held <bernhard AT bernhardheld.de>
9647
9648         * src/SDCCast.c (decorateType): fixed with bug and promotion in
9649         arithmetic optimizations, added debug output
9650
9651 2004-03-09 Bernhard Held <bernhard AT bernhardheld.de>
9652
9653         * device/lib/time.c (mktime): fixed bug reported by Bert Thomas
9654         * sdcc.spec: updated and split sdcc into 3 rpms
9655         * src/SDCCast.c (decorateType): &|^ don't need addCast(); addCast() is
9656         needed for literals of LEFT_OP and '+'
9657         * src/SDCCicode.c (geniCodeLogic): I must have been braindead when I
9658         introduced RESULT_TYPE_NOPROM
9659         (geniCodeMultiply): fixed logic for decision if mul is optimized to
9660         left shift
9661         * src/SDCCsymt.c (computeType): op is int; added RESULT_TYPE_OTHER;
9662         limited promotion to int only for '*'
9663         * src/SDCCsymt.h (computeType): op is int, removed RESULT_TYPE_NOPROM
9664
9665 2004-03-09 Hans Dorn <hjdorn AT users.sourceforge.net>
9666
9667         * src/pic16/gen.c (genSkip),
9668         (genc16bit2lit), (gencjneshort): commented out
9669         (is_LitOp): new helper function, checks operand type
9670         (genCmpEq): rewritten
9671
9672 2004-03-08 Bernhard Held <bernhard AT bernhardheld.de>
9673
9674         * support/regression/tests/bug-908454.c: added
9675
9676 2004-03-07 Bernhard Held <bernhard AT bernhardheld.de>
9677
9678         * src/SDCCast.c (addCast): fixed bug #908454 by promoting bits to char
9679         * src/SDCCicode.c (usualBinaryConversions): op needs int type
9680         (geniCodeCast): cosmetic, don't preserve bit storage class
9681         (geniCodeLeftShift): added promotion
9682         (geniCodeLogic): fixed regression
9683         * src/SDCCsymt.c (computeTypeOr): accept bits too
9684         (compareType): 2nd part of fix for bug #908454, needed for bitfields
9685
9686 2004-03-07  Borut Razem <borut.razem AT siol.net>
9687
9688         * support/Util/findme.c: alloca() replaced with malloc()/free() pair
9689
9690 2004-03-06 Vangelis Rokas <vrokas AT otenet.gr>
9691
9692         * src/pic16/ralloc.c (pic16_genPackRegisters): reverted to old
9693         version of pic16_genPackRegisters which does not check if ic is a
9694         CAST operator,
9695         * src/pic16/gen.c (ifxForOp): disabled new and untested code in
9696         function cause string1.c regression test fails
9697
9698 2004-03-06 Bernhard Held <bernhard AT bernhardheld.de>
9699
9700         * sim/ucsim/configure.in,
9701         * sim/ucsim/configure,
9702         * sim/ucsim/doc/Makefile.in: use docdir
9703         * src/SDCC.y: fixed sbit atrributes
9704         * src/SDCCast.c (getResultTypeFromType): added support for bitfields
9705         * src/SDCCast.c (decorateType): |^& need special promotion handling
9706         * src/SDCCast.h,
9707         * src/SDCCsymt.h: moved definition of RESULT_TYPE
9708         * src/SDCCsymt.h (computeType),
9709         * src/SDCCicode.c: computeType() needs op
9710         * src/SDCCsymt.c (checkTypeSanity),
9711         * doc/sddman.lyx: "plain" bitfields are unsigned
9712         * src/SDCCsymt.c (computeTypeOr): added
9713         * src/SDCCsymt.c (computeType): added support for bitfields, fixed
9714         |^& ops
9715         * src/SDCCval.c (val*): computeType() needs op
9716         * src/SDCCval.c (valCastLiteral): fixed casting of bitfields
9717         * support/regression/tests/onebyte.c: added tests for |^&
9718
9719 2004-03-06 Hans Dorn <hjdorn AT users.sourceforge.net>
9720
9721         * src/pic16/gen.c: (genpic16Code) use copy of printILine's output
9722         for writing icode into asm output.
9723
9724 2004-03-05 Vangelis Rokas <vrokas AT otenet.gr>
9725
9726         * src/pic16/device.c: added some debug lines enabled
9727         with macro DEBUG_CHECK,
9728         * src/pic16/genarith.c: more debug in genPlus,
9729         * (pic16_genUMult8XLit_16, pic16_genUMult8X8_16): removed,
9730         * (pic16_genUMult16X16_16, pic16_genUMult16XLit_16): NEW,
9731         * src/pic16/gen.c: added prototypes for pic16_genMult16X16_16,
9732         * (aopForSym): onStack symbols are re-placed in data memspace,
9733         and onStack flag is cleared,
9734         * (pic16_popGetTempReg, pic16_popReleaseTempReg): modified to
9735         copy temporary pcodeop,
9736         * (genPcall): added warning for not updating PCLATU,
9737         * (genFunction): removed test with IFFUNC_CALLEESAVES, its
9738         always true for pic16 port,
9739         * (genMultOneWord): NEW, supports integer multiplication,
9740         * (genMult): modified to call genMultOneWord,
9741         * (ifxForOp): added warning when return NULL,
9742         * src/pic16/glue.c (pic16emitRegularMap): symbol implicit
9743         flag is set before call to operandFromSymbol for implicit
9744         added structures,
9745         * src/pic16/main.c (_pic16_finaliseOptions): options.float_rent,
9746         options.intlong_rent are set by default,
9747         * (_hasNativeMulFor): modified to allow port generation of integer
9748         multiplication,
9749         * src/pic16/ralloc.c (pic16_allocDirReg): commented out line which
9750         set regtype to REG_SFR for all registers, restricting seting the
9751         accessBank flag for registers 0<= r < 0x80 and 0xf80<=r<=0xfff,
9752
9753 2004-03-05 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
9754
9755         * src/mcs51/peephole.def: added 251.b and 253.x. 253.x are applied
9756         more than 500 times in the regression tests
9757
9758 2004-03-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9759
9760         * support/Util/SDCCerr.h,
9761         * support/Util/SDCCerr.c,
9762         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
9763         enumerator_list),
9764         * src/SDCCsymt.c (addSymChain): show location of oriignal definition
9765         for symbol conflicts.
9766         * support/valdiags/tests/enum.c,
9767         * support/valdiags/tests/tentdecl.c,
9768         * support/valdiags/tests/struct.c: expect possible error messages
9769         referring to original symbol definitions.
9770         * src/SDCC.y (struct_or_union_specifier, struct_declarator),
9771         * src/SDCCsymt.h,
9772         * src/SDCCsymt.c (promoteAnonStructs): support anonymous struct/union
9773
9774 2004-03-03 Hans Dorn <hjdorn AT users.sourceforge.net>
9775
9776         * src/pic16/gen.c (gencjne): fixed for right=REG / left=LIT
9777
9778 2004-02-03 Vangelis Rokas <vrokas AT otenet.gr>
9779
9780         * src/pic16/ralloc.c (newReg): fixed bug #908929
9781
9782 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9783
9784         * src/ds390/gen.c: added missing #include "main.h"
9785
9786 2004-03-02 Vangelis Rokas <vrokas AT otenet.gr>
9787
9788         * src/pic16/device.c (checkAddSym): NEW, adds a symbol to set while
9789         checking if symbol is already in set,
9790         * src/pic16/device.h: prototype for checkAddSym,
9791         * src/pic16/gen.c: (_G): added entry interruptvector,
9792         * (assignResultValue): removed some commented out lines,
9793         * (genFunction): check for ISR via sym->type, absolute section for
9794         interrupt code is created via a new pBlock, the goto instruction is
9795         placed now correctly at the interrupt vector position, changed all
9796         references from ivec to _G.interruptvector,
9797         * WREG,STATUS,BSR are not saved in stack upon an entry to interrupt
9798         is the interrupt is a high priority one, same for return from ISR,
9799         * src/pic16/glue.c: changed all calls of addSetHead for publics and
9800         externs to calls of checkAddSym,
9801         * src/pic16/pcode.c (pic16_pBlockConvert2*): emit warning when
9802         pic16_pcode_verbose flag is set,
9803         * src/pic16/pcode.h: extern to pic16_pcode_verbose,
9804         * src/pic16/pcoderegs.c: message about how many registers are saved
9805         will only be emitted if pic16_pcode_verbose flag is set,
9806
9807 2004-03-02 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9808
9809         * src/ds390/ralloc.h,
9810         * src/ds390/ralloc.c (ds390_regWithIdx),
9811         * src/ds390/gen.c (emitcode),
9812         * src/ds390/main.h,
9813         * src/ds390/main.c (instructionSize, ds390newAsmLineNode, updateOpRW,
9814         ds390opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
9815         ds390operandCompare, getRegsRead, getRegsWritten,
9816         initializeAsmLineNode): customized instruction size calculation for
9817         ds390, started basis for some register optimizations
9818         * src/ds390/gen.c (gen390Code, emitcode): associate iCodes with
9819         corresponding assembly output
9820         * src/ds390/gen.c (genFunction, genEndFunction): added case to handle
9821         missing push/pop of r0/r1. Optimized push/pops
9822
9823 2004-03-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9824
9825         * src/mcs51/main.c (instructionSize): fixed ACALL size
9826         * src/mcs51/main.c (updateOpRW): fixed bug with @dptr, @a+dptr operands
9827
9828 2004-03-01 Vangelis Rokas <vrokas AT otenet.gr>
9829
9830         * src/pic16/device.c (pic16_dump_section): fixed a bug that allowed
9831         the sorting of rlist with NULL elements
9832         * (print_idataType, print_idata): NEW to create idata sections
9833         * src/pic16/device.h: idataSymSet new variable
9834         * src/pic16/gen.c (genFunction): fixed some bugs in string
9835         comparing, improved the absolute section creation for ISRs,
9836         added FSR0L/FSR0H in registers that are saved in an ISR,
9837         * (genInline): fixed the processing of inline snippets,
9838         now they undergo no process by the peephole optimizer
9839         * src/pic16/glue.c (pic16emitRegularMap): symbols with initialiser
9840         are placed in idataSymSet,
9841         * (pic16emitStaticSeg): extern symbols are added in externs,
9842         * src/pic16/ralloc.c (pic16_allocDirReg): work around to reduce bank
9843         switching when aboslute variables are placed in access bank memory
9844         * (pic16_writeUsedRegs): added call to pic16_dump_idata,
9845         * (packRegsForSupport,packRegsForAccUse,packRegsForOneuse):
9846         commented out with #if,
9847         * (pic16_packRegisters): reintroduce the check for CAST because some
9848         symbols are not correctly handled,
9849         * src/pic16/pcode.h: changed the definition of pCodeAsmDir to hold a
9850         pCodeInstruction instead of pCode,
9851         * src/pic16/pcode.c (pic16_newpCodeAsmDir): modified for the new
9852         pCodeAsmDir definition,
9853         * (pic16_pCode2str, genericPrint): when an AsmDir pcode has a NULL
9854         directive, then the argument directive is emitted without the leading
9855         tab, hack for inline labels which must be in the first column,
9856         * (compareLabel,pic16_findNextInstruction),
9857         * (pic16_findPrevInstruction): added case for PO_ASMDIR,
9858         * (insertBankSwitch): modified for the new pCodeAsmDir,
9859
9860 2004-03-01 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
9861         patch applied by Vangelis Rokas <vrokas AT otenet.gr>
9862
9863         * src/pic16/gen.c (pic16_popGet): case PO_DIR, adds the offset to
9864         instance,
9865         * (pushSide): commented out with #if,
9866         * (assignResultValue): fixed some typos in saving
9867         registers,
9868         * (genPcall): FIXED and sync'ed with genCall,
9869         * (genDataPointerGet,genDataPointerSet): using offset not leoffset
9870         * (genNearPointerGet): fixed to handle some more cases,
9871         implementation scheme via table reads,
9872         * (genConstPointerGet): modified to access code memory correct,
9873         * (genCodePointerGet,genNearPointerSet,genGenPointerSet): modified
9874         and improved to handle some cases
9875         * glue.c (printIvalType,printIvalChar,emitStaticSeg): use "DB"
9876         instead of "RETLW" for init data
9877         * src/pic16/ralloc.c (pic16_allocDirReg): warning when a symbol is
9878         not IN_DIRSPACE, work around to reduce bank switching when aboslute
9879         variables are placed in access bank memory (<0x80 and >=0xf80),
9880         * src/pic16/pcode.c: added SFRs TBLPTR, TABLAT, added opcodes TBLRD,
9881         TBLRD_POSTINC,TBLRD_POSTDEC,TBLRD_PREINC,TBLWT,TBLWT_POSTINC,
9882         TBLWT_POSTDEC,TBLWT_PREINC
9883         * Fixed initialisation of BSR, set "alias" for SSAVE to "0"
9884         * (pic16_emitDB,pic16_flushDB): New functions to generate "DB"
9885         directives
9886         * (pic16_pCodeConstString): use "DB" instead of "RETLW"
9887         * src/pic16/pcode.h: added TBLRD*,TBLWT*, added pic16_emitDB,
9888         pic16_flushDB, made pic16_newpCodeAsmDir public, added TBLPTR, TABLAT
9889         * src/pic16/ralloc.h: added IDX_BSR,IDX_TBLPTR*,IDX_TABLAT
9890
9891 2004-02-29  Borut Razem <borut.razem AT siol.net>
9892
9893         * src/Makefile.in, src/SDCCutil.c, support/Util/findme.c,
9894         support/Util/findme.h, support/Util/system.h: enhance binary relative
9895         search for lib and include by using findProgramPath()
9896
9897 2004-02-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
9898
9899         * src/SDCCpeeph.h,
9900         * src/SDCCpeeph.c (pcDistance),
9901         * src/port.h,
9902         * src/mcs51/ralloc.h,
9903         * src/mcs51/ralloc.c (mcs51_regWithIdx),
9904         * src/mcs51/main.h,
9905         * src/mcs51/main.c (instructionSize, asmLineNode, updateOpRW,
9906         mcs51opcodeCompare, asmLineNodeFromLineNode, getInstructionSize,
9907         mcs51operandCompare, getRegsRead, getRegsWritten): made instruction
9908         size calculation port specific, started basis for some register
9909         optimizations
9910         * src/mcs51/gen.c (genFunction, genEndFunction): added case to handle
9911         missing push/pop of r0/r1. Optimized push/pops
9912         * src/mcs51/ralloc.c (packregisters): fixed bug #727095
9913         * device/lib/_modsint.c (_modsint),
9914         * device/lib/_modslong.c (_modslong): fixed sign of result in non-asm
9915         and stack version so regression tests pass
9916
9917 2004-02-26 Bernhard Held <bernhard AT bernhardheld.de>
9918
9919         * src/Makefile.in (dep): include SLIBOBJS in dependency check
9920         * src/SDCCast.c (decorateType): catch another small optimization
9921         with '?' operator
9922         * src/SDCCsymt.c (computeType): added comments and cosmetic changes
9923         * src/SDCCval.c (valMult, valDiv, valMod, valPlus, valMinus, valShift):
9924         modified to finally use computeType() all over SDCC,
9925         see Feature Request #877103
9926         * src/SDCCval.h: cosmetic
9927         * src/SDCCicode.c (operandOperation): fixed EQ_OP bug, now same as in
9928         valCompare(); regression tested in muldiv.c
9929         * support/regression/tests/muldiv.c (testMod): mod sign follows
9930         dividend only
9931
9932 2004-02-23 Bernhard Held <bernhard AT bernhardheld.de>
9933
9934         * src/SDCCast.c (decorateType): fixed bug #902362
9935         * doc/INSTALL.txt: fixed install instructions for win32
9936
9937 2004-02-21 Bernhard Held <bernhard AT bernhardheld.de>
9938
9939         * device/include/Makefile.in (install): fixed by replacing spaces
9940         by tabs
9941         * doc/README.txt,
9942         * doc/INSTALL.txt: updated for release
9943         * doc/sdccman.lyx: added warning for --xstack being buggy
9944
9945 2004-02-20 Bernhard Held <bernhard AT bernhardheld.de>
9946
9947         * src/pic16/ralloc.c (packRegsForAccUse):  disabled functions with #if
9948         to eliminate build warnings.
9949         * src/pic16/gen.c (pic16_popGet): fixed for gcc 2.95.4
9950
9951 2004-02-20 Vangelis Rokas <vrokas AT otenet.gr>
9952            Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
9953
9954         * doc/sdccman.lyx: removed PIC16 from PIC16 Port Specific Options,
9955         removed -penable-stack, added comment for stack pragma, added
9956         warning for not initializing the stack/frame registers, removed
9957         comment at interrupts section
9958
9959         Stack is made permanent, there is no ability to disable stack usage.
9960         * src/pic16/device.h,
9961         * src/pic16/device.c: removed all references to USE_STACK macro,
9962         * src/pic16/device.c (pic16_dump_section): when no elements in
9963         rlist, free rlist before return,
9964         * (pic16_dump_int_registers): NEW, internal registers are a new set
9965         of general purpose registers reused by each function,
9966         * (checkAddReg): returns 1 if registers is added to set,
9967         * (pic16_groupRegistersInSection): when a registers is of type
9968         PO_GPR_TEMP add it in pic16_int_regs and not in pic16_rel_udata,
9969         * src/pic16/device.h: memRange and Assigned Memory are deleted,
9970         SRCASECMP macro is moved here from device.c
9971         * src/pic16/genarith.c (pic16_pCodeOpType): added cases for
9972         PO_PCLATU, PO_PRODL, PO_PRODH,
9973         * (pic16_pCodeOpType, genMinus,
9974         changed compares to "a" register, with AOP_ACC,
9975         * (pic16_genPlus): fixed some bugs and indented properly,
9976         * (pic16_addSign): changed size to size+offset in the MOVWF
9977         instruction,
9978         * (pic16_genUMult8XLit_8): NEW, uses processor MULLW instruction to
9979         multiply 8-bit operand by literal, result is 8-bit,
9980         * (pic16_genUMult8X8_8): NEW, uses processor MULWF instruction to
9981         multiply 2 8-bit operand, result is 8-bit,
9982         * (pic16_genMult8X8_8): modified to call genUMult8X*_8 functions and not
9983         genUMult8X*_16,
9984         * src/pic16/gen.c: changed accUse to contain WREG only,
9985         * (pic16_emitcomment): renamed to pic16_emitpcomment,
9986         * (aopForSym): allocated dir register when IN_DIRSPACE(space) is,
9987         true, do not use immediate addressing any more unless sym is a
9988         pointer in codespace,
9989         * (aopForRemat): do not use immediate addressing when symbol not in
9990         codespace and when symbol's address is requested,
9991         * (aopOp): for-loop in if(sym->accUse) is modified for the new
9992         accUse size (= 1),
9993         * (aopGet): added case for AOP_ACC and don't return "accumulator
9994         bug" but WREG instead,
9995         * (popGetTempReg): pushes contents of temporary register in stack,
9996         * (popReleaseTempReg): pops contents of temporary register from
9997         stack. Use popGetTempReg/popReleaseTempReg in aligned pairs,
9998         * (pic16_popGet): separated case AOP_ACC to return register WREG
9999         from processor registers, AOP_PCODE not checks if pcop is PO_DIR
10000         or PO_IMMEDIATE and initializes their instance/offset appropriately,
10001         * The whole issue with aopForSym,aopForRemat,popGet) is to minimize
10002         the use of immediate pointers to certain cases only.
10003
10004         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): use pic16_popGet2p,
10005         * (pic16_loadFromReturn, pic16_storeForReturn: NEW,
10006         * (assignResultValue, genCall, genRet): modified to use the new
10007         function return value scheme with WREG,PRODL,PRODH,FSR0L and FSR0,
10008         genPcall is still broken,
10009         * (genFunction): added code to create 'A' type pBlocks when
10010         interrupt functions are generated, code not extensively tested yet,
10011         ISRs push WREG,STATUS,BSR,PRODL,PRODH,FSR0L,FSR0H registers on stack,
10012         * (genEndFunction): modified so ISRs pop stored registers from stack,
10013         * (genMultOneByte): cleanup,
10014         * (AccRsh): added flag andmask, to and result with appropriate mask,
10015         * (genUnpackBits,genPackBits): fixed and can handle bit fields,
10016         * (genDataPointerGet): fixed and reenabled its use,
10017         * (genNearDataPointerGet): bugs fixed,
10018         * (genDataPointerSet): bugs fixed,
10019         * src/pic16/genutils.c: added functions pic16_DumpValue,pic16_DumpAop,
10020         pic16_DumpSymbol, pic16_DumpOp,
10021         * src/pic16/genutils.h: function prototypes for the above functions,
10022         * src/pic16/glue.c: new flags initsfpnt, to initialize stack/frame
10023         pointers,
10024         * (pic16emitRegularMap): many many many improvements, but needs a
10025         major cleanup,
10026         * src/pic16/main.c: enable_stack in pic16_options is removed,
10027         * (_pic16_parseOptions): removed command line options -penable-stack,
10028         * (_process_pragma): emit stack symbol only when stack pragma is
10029         processed,
10030         * src/pic16/pcode.c: pic16_pc_fsr0 is removed, all operations are
10031         redirected to FSR0L/FSR0H pair,
10032         * (pic16_get_op, pic16_get_op2): modifications and improvements,
10033         * (pic16_getRegFromInstruction, pic16_getRegFromInstruction2): added
10034         cases PO_PRODL,PO_PRODH, pic16_getRegFromInstruction2 returns sane
10035         for immediates,
10036         * (insertBankSwitch): modified to handle cases like: (alfa + 1)
10037         * (dumpPicOptype): NEW,
10038         * src/pic16/pcode.h: added PO_PCLATU,PO_PRODL,PO_PRODH in enum,
10039         * src/pic16/pcoderegs.c (pCodeRegMapLiveRangesInFlow): fixed bug
10040         with movff instruction,
10041         * src/pic16/ralloc.c: renamed typeRegWithIdx to pic16_typeRegWithIdx,
10042         added pic16_int_regs, some packRegsFor* functions are commented out,
10043         because produce errors,
10044         * src/pic16/NOTES: minor modifications
10045
10046 2004-02-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10047
10048         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c, as/mcs51/lkmain.c,
10049         as/mcs51/lkmem.c, src/SDCCglob.h, src/SDCCmain.c: added options --stack-size and
10050         --pack-iram.
10051         * doc/sdccman.lyx: described options --stack-size and --pack-iram.
10052         * as/mcs51/lkaomf51.c: fixed bug #895763
10053
10054 2004-02-17 Bernhard Held <bernhard AT bernhardheld.de>
10055
10056         * device/include/c8051f320.h: added. Contributed by Maarten Brock.
10057
10058 2004-02-17 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10059
10060         * doc/sdccman.lyx: added details about the HC08 storage classes and
10061         interrupts, fixed the register usage info for z80 & gbz80
10062
10063 2004-02-17 Vangelis Rokas <vrokas AT otenet.gr>
10064
10065         * doc/sdccman.lyx: added more pic16 port documentation
10066         * device/include/pic16/: added header pic18fregs.h
10067
10068 2004-02-16 Bernhard Held <bernhard AT bernhardheld.de>
10069
10070         * doc/sdccman.lyx: added Vangelis' contribution
10071
10072 2004-02-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10073
10074         * src/SDCClrange.c (rlivePoint): live range of SEND operand should
10075         extend to the next CALL or PCALL, not just to the next CALL.
10076
10077 2004-02-16 Vangelis Rokas <vrokas AT otenet.gr>
10078
10079         * src/pic16/gen.c (genInline): fixed bug #896482 with inline assembly
10080
10081 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10082
10083         * src/mcs51/ralloc.c (packRegsForAssign, reassignAliasedSym): fixed
10084         bug #895752 and a better fix for bug #716790
10085
10086 2004-02-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10087
10088         * src/SDCCsymt.c (processFuncArgs): fixed bug #896796
10089
10090 2004-02-14 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10091
10092         * doc/sdccman.lyx: minor changes, minor changed
10093
10094 2004-02-13 Bernhard Held <bernhard AT bernhardheld.de>
10095
10096         * src/SDCCicode.c (usualBinaryConversions): removed pic16 from ports
10097         which can't handle SDCC_NEWONEBYTEOPS,
10098         (geniCodeMultiply): removed conversion from mult to shift for pic14
10099         and pic16
10100
10101 2004-02-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10102
10103         * src/hc08/gen.h,
10104         * src/hc08/gen.c (storeRegToAop, aopOp, aopAdrStr, accopWithAop,
10105         rmwWithAop): Ported my 2003-10-02 fix for bug #663539 to the hc08,
10106         thus fixing bug #895406
10107
10108 2004-02-11 Bernhard Held <bernhard AT bernhardheld.de>
10109
10110         * device/lib/_modsint.c,
10111         * device/lib/_modslong.c: sign follows divisor only
10112         * src/hc08/gen.c (genMultOneByte): if result size is 1,
10113         signs or signedness can be ignored
10114         * src/SDCCast.c (addCast): cosmetic - added lineno to CAST
10115         * src/SDCCast.c (resultTypePropagate): added even more ops: +, - and *,
10116         added optimization for IFX,
10117         (decorateType): Mult/Div/ModOneByte ops can handle all kind of signed
10118         arguments;
10119         reenabled optimization for IFX, which was removed on 2004-01-11
10120         * src/SDCCast.h: added return type IFX
10121         * src/SDCCicode.c: Mult/Div/ModOneByte ops can handle all kind of signed
10122         arguments with 8 or 16 bit results; pic14 and pic16 ports use old
10123         promotion behaviour; env. var. SDCC_NEWONEBYTEOPS selects the new,
10124         SDCC_OLDONEBYTEOPS selects the old behaviour
10125         * src/SDCCsymt.c (computeType): type2 can be NULL (for LEFT_OP);
10126         changed again and commented promotion rule
10127         * src/SDCCval.c (valDiv): promotion no longer necessary
10128         * src/ds390/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte),
10129         * src/mcs51/gen.c (genMultOneByte) (genDivOneByte) (genModOneByte):
10130         rewritten
10131         * support/regression/tests/onebyte.c: added
10132
10133 2004-02-11 Vangelis Rokas <vrokas AT otenet.gr>
10134
10135         * gen.c (genInline): reverted to old code for assemnling inline
10136         code because of bug reported James Chadd
10137
10138 2004-02-10 Vangelis Rokas <vrokas AT otenet.gr>
10139
10140         * ralloc.h: missing declarations from previous patch,
10141         seems that patch for ralloc.h was never applied, fixed
10142
10143 2004-02-10 Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
10144            patch committed by Vangelis Rokas <vrokas AT otenet.gr>
10145
10146         * pcode.c,
10147         * pcode.h,
10148         * ralloc.h: added FSR0L, FSR0H and other missing PIC16 SFR's for
10149         indirect addressing. Marked FSR0 as deprecated
10150         * gen.c (pointerCode): commented out, not needed now
10151         (pic16_popGet2p): new MOVFF helper function
10152         (genGenPointerGet),
10153         (genGenPointerSet): reimplemented with MOVFF and POSTINC0
10154         (shiftRLong): removed duplicate debugging info
10155
10156 2004-02-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10157
10158         * src/ds390/gen.c (genNearPointerGet),
10159         * src/mcs51/gen.c (genNearPointerGet): allow the genDataPointerGet()
10160         optimization with bits, but not bitfields.
10161         * src/ds390/ralloc.c (packRegisters),
10162         * src/mcs51/ralloc.c (packRegisters): fixed bug #884453 & #880832
10163
10164 2004-02-09 Bernhard Held <bernhard AT bernhardheld.de>
10165
10166         * src/SDCCcse.c (algebraicOpts): copy operands before modification
10167
10168 2004-02-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10169
10170         * src/SDCCsymt.h,
10171         * src/SDCCicode.c (operandFromSymbol),
10172         * src/mcs51/ralloc.c (verifyRegsAssigned, serialRegAssign),
10173         * src/ds390/ralloc.c (verifyRegsAssigned, serialRegAssign),
10174         * src/z80/ralloc.c (verifyRegsAssigned, serialRegAssign),
10175         * src/hc08/ralloc.c (verifyRegsAssigned, serialRegAssign),
10176         * src/pic/ralloc.c (verifyRegsAssigned, serialRegAssign),
10177         * src/pic16/ralloc.c (verifyRegsAssigned, serialRegAssign): fixed
10178         bug #892038
10179         * src/SDCCast.c (createIvalStruct, createIvalArray, gatherAutoInit),
10180         * src/SDCCglue.c (emitRegularMap, printIvalStruct, printIvalArray,
10181         printIvalCharPtr, printIvalPtr, printIval, emitStaticSeg, emitOverlay)
10182         * src/SDCCsymt.c (newSymbol),
10183         * src/SDCC.y (struct_or_union_specifier, enum_specifier,
10184         enumerator_list),
10185         * src/SDCCval.h,
10186         * src/SDCCval.c (newiList): fixed bug #885705
10187
10188 2004-02-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10189
10190         * doc/sdccman.lyx: added section 3.1.4: sdcclib.
10191         * as/mcs51/lkmem.c: report the size of the stack in .mem file.
10192
10193 2004-02-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10194
10195         * device/include/c8051f120.h,
10196         * device/include/c8051f300.h,
10197         * device/include/c8051f310.h: added/updated header files for Silicon
10198         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
10199         * doc/sdccman.lyx: minor changes, recommended diff -Naur and diff -u
10200         in new section Submitting patches
10201
10202 2004-02-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10203
10204         * src/mcs51/gen.c (genNearPointerGet, genPagedPointerGet,
10205         genFarPointerGet, genCodePointerGet, genGenPointerGet,
10206         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
10207         genGenPointerSet),
10208         * src/ds390/gen.c (genNearPointerGet, genPagedPointerGet,
10209         genFarPointerGet, genCodePointerGet, genGenPointerGet,
10210         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
10211         genGenPointerSet),
10212         * src/pic16/gen.c (genNearPointerGet, genPagedPointerGet,
10213         genFarPointerGet, genCodePointerGet, genGenPointerGet,
10214         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
10215         genGenPointerSet),
10216         * src/pic/gen.c (genNearPointerGet, genPagedPointerGet,
10217         genFarPointerGet, genCodePointerGet, genGenPointerGet,
10218         genNearPointerSet, genPagedPointerSet, genFarPointerSet,
10219         genGenPointerSet): fixed bug #892400
10220         * src/pic16/gen.c (genSkipz, AccRol): disabled functions with #if 0
10221         to eliminate build warnings.
10222         * src/SDCCast.c (processParms),
10223         * src/SDCC.y (function_declarator2, declarator2_function_attributes):
10224         fixed bug 751859
10225         * support/valdiag/valdiag.py: added GCC to the list of defines active
10226         when compiling with gcc
10227
10228 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10229
10230         * support/Util/SDCCerr.h,
10231         * support/Util/SDCCerr.c,
10232         * src/SDCCast.c (decorateType, sizeofOp): complain when sizeof is used
10233         with an incomplete type (fixed bug #883734)
10234         * src/SDCCicode.c (geniCodeCast): fixed bug #890510
10235
10236 2004-02-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10237
10238         * src/pic16/gen.c (genCmpEq, shiftRLong): fixed declarations
10239
10240 2004-02-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10241
10242         * src/SDCCast.c (decorateType),
10243         * src/SDCCicode.c (geniCodeParms, geniCodeCall): fixed bugs in my ANSI
10244         function pointer implementation
10245         * support/regression/tests/funptrs.c: added tests to verify both forms
10246         of function pointers work correctly. Added tests to verify parameters
10247         are passed in the correct order.
10248
10249 2004-02-06  Vangelis Rokas <vrokas AT otenet.gr>
10250
10251         * device.c (regCompare): registers are sorted by ascending
10252         address and increasing size,
10253         * main.c (_pic16_finaliseOptions): removed the declaration
10254         of compiler macro MCU. Now a macro of the format pic18fxxxx
10255         will be defined from the command line
10256
10257 2004-02-06  Hans-Juergen Dorn <hans.dorn AT apl-landau.de>
10258             patch committed by Vangelis Rokas <vrokas AT otenet.gr>
10259
10260         * pcode.c (pic16initMnemonics): fixed typo in assignment to PCOP_RLNCF
10261         PCOP_RLCF was overwritten!
10262         * gen.c (genSkip): commented out calls to pic16_emitcode,
10263         * (genCmpEQ): fixed "long" compares, only high word did get compared,
10264         * (genlshTwo),
10265         * (genRRC): added debugging info,
10266         * (shiftL2Left2Result): Fixed bug, if offr > offl. Result got
10267         overwritten while shifting,
10268         * (shiftR2Left2Result): Fixed bug, if offr < offl. Result got
10269         overwritten while shifting,
10270         * (AccLsh),
10271         * (AccRsh),
10272         * (shiftLLeftOrResult),
10273         * (shiftRLeftOrResult),
10274         * (shiftRLong),
10275         * (shiftLLong): Implemented with pic16_emitpcode
10276         * (genlshFour): Replaced pic16_aopPut with pic16_emitpcode,
10277         * (genLeftShift): Fixed bug, operand for shift by variable always
10278         was "and"ed with 0x0f,
10279         * (genLeftShiftLiteral),
10280         * (genrshTwo),
10281         * (genRightShiftLiteral): added debugging info,
10282         * (genrshFour): added comment,
10283         * (genRightShift): determined signedness from operand "left"
10284         instead of "result"
10285
10286 2004-02-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10287
10288         * src/SDCCicode.c (geniCodeParms),
10289         * src/SDCCast.c (decorateType, processParms): support for ANSI-style
10290         function pointers, fixed function pointer bugs #861242 and #861896
10291
10292 2004-01-31 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10293
10294         * device/include/c8051f000.h,
10295         * device/include/c8051f120.h,
10296         * device/include/c8051f300.h: added header files for Silicon
10297         Laboratories (formerly Cygnal) CPUs. Contributed by Maarten Brock.
10298
10299 2004-01-31 Bernhard Held <bernhard AT bernhardheld.de>
10300
10301         * src/SDCCast.c (processParams): added new type flow and restructured
10302         (gatherAutoInit): added new type flow
10303         (addCast): cosmetic changes
10304         (getLeftResultType): added new type flow for array indices, patch
10305         provided by Stas, see FR #877103
10306         (decorateType): SDCC_NEWTYPEFLOW removed, new type flow is now standard;
10307         array index patch by Stas
10308         * src/SDCCast.h: added prototype getResultTypeFromType()
10309         * src/SDCCval.h,
10310         * src/SDCCval.c (resolveIvalSym) (resolveIvalSym),
10311         * src/pic/glue.c (pic14emitStaticSeg),
10312         * src/pic16/glue.c (pic16emitStaticSeg),
10313         * src/SDCCglue.c (emitRegularMap) (emitStaticSeg): added new type flow
10314         for initialization of symbols
10315         * src/SDCCicode.c (geniCodeArray): removed warning W_ARRAY_BOUND
10316         * support/Util/SDCCerr.h:
10317         * support/Util/SDCCerr.c: replaced W_ARRAY_BOUND by W_IDX_OUT_OF_BOUNDS
10318         * .version: bumped version number to 2.3.8
10319         * device/include/Makefile.in (install),
10320         * doc/Makefile (install): changed to 'rm `find ...`' construct to
10321         avoid warnings
10322
10323 2004-01-30 Bernhard Held <bernhard AT bernhardheld.de>
10324
10325         * support/regression/tests/libmullong.c: fixed for 64 bit hosts
10326         Slade Rich fixed an optimization bug
10327         * src/pic/pcodepeep.c,
10328         * src/pic/pcoderegs.c
10329         * doc/Makefile (install): added test for directory
10330
10331 2004-01-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10332
10333         * src/mcs51/ralloc.c (getRegPtr, getRegGpr),
10334         * src/ds390/ralloc.c (getRegPtr, getRegGpr),
10335         * src/pic/ralloc.c (getRegPtr, getRegGpr),
10336         * src/pic16/ralloc.c (getRegPtr, getRegGpr),
10337         * src/z80/ralloc.c (getRegGpr): fixed bug #883361
10338         * as/mcs51/asexpr.c (term),
10339         * as/hc08/asexpr.c (term): fixed bug #887146
10340
10341 2004-01-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10342
10343         * src/z80/gen.c (genMult): handle single byte result product
10344         * src/SDCCopt.c (killDeadCode): never convert ADDRESS_OF iCode to
10345         DUMMY_READ_VOLATILE (fixed bug #886367)
10346
10347 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
10348
10349         * support/regression/tests/libmullong.c: fixed logic, on little endian
10350         hosts we ended without a mullong_wrapper()
10351
10352 2004-01-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10353
10354         * ChangeLog: changed "@" to " AT " in hopes of reducing spam and
10355         virus/worm forged address usage.
10356
10357 2004-01-27 Bernhard Held <bernhard AT bernhardheld.de>
10358
10359         Fixed promotion, it should be done on AST level:
10360         * src/SDCCast.c (addCast): added promotion to int
10361         (decorateType): updated call to upCast()
10362         * src/SDCCicode.c (geniCodeLeftShift): removed call to
10363         usualUnaryConversions()
10364
10365 2004-01-26  Michael Hope  <michaelh AT juju.net.nz>
10366
10367         * support/regression/tests/literalop.c (mulWrapper): Added a
10368         wrapper to remove integer overflow warnings.
10369
10370         * support/regression/tests/float_trans.c: Made work on host.
10371
10372         * support/regression/ports/ucz80/spec.mk (UCZ80): Made detect the
10373         location of sz80.
10374
10375         * support/regression/generate-cases.py (main): Changed from inline
10376         to a main method.
10377
10378         * doc/Makefile (install): Changed to depth first to get rid of
10379         missing directory install warning.
10380
10381         * as/Makefile (install-doc): Made work on Mac.
10382
10383 2004-01-25 Bernhard Held <bernhard AT bernhardheld.de>
10384
10385         * src/SDCCast.c: added an additional type flow in decorateType() of
10386         opposite direction, see feature request #860006; it's enabled at runtime
10387         by setting the environment variable SDCC_NEWTYPEFLOW
10388         * src/SDCCast.h: changed prototype of decorateType()
10389         * src/SDCCglue.c (emitRegularMap): updated call of decorateType()
10390         * src/SDCCicode.c (geniCodeDivision) (geniCodeModulus): promotion from
10391         'char' to 'int' can be omitted, if both operands are 'unsigned char';
10392         see feature request #877103
10393         * src/SDCCval.c: updated call of decorateType()
10394         (valBitwise): fixed bug #882876
10395         (valMinus): added promotion
10396         (valLogicAndOr): result is unsigned
10397         (cheapestVal) (constVal): literals from 0...255 are 'unsigned char' now
10398         * src/SDCCsymt.c (computeType),
10399         * src/mcs51/gen.c (genCmpGt) (genCmpLt): literal 'unsigned char'
10400         must not cause an unsigned operation
10401         * src/pic/glue (pic14emitRegularMap),
10402         * src/pic16/glue.c (pic16emitRegularMap): updated call of decorateType()
10403
10404 2004-01-23 Bernhard Held <bernhard AT bernhardheld.de>
10405
10406         * src/pic/pcode.c (PCodeID): commented out left over debug code
10407
10408 2004-01-20 Bernhard Held <bernhard AT bernhardheld.de>
10409
10410         * support/valdiag/tests/overflow.c: added shift tests
10411         * src/pic/device.c,
10412         * src/pic/gen.c,
10413         * src/pic/gen.h,
10414         * src/pic/glue.c,
10415         * src/pic/main.c,
10416         * src/pic/pcode.c,
10417         * src/pic/pcode.h,
10418         * src/pic/pcodepeep.c,
10419         * src/pic/pcoderegs.c,
10420         * src/pic/ralloc.c,
10421         * src/pic/ralloc.h: applied patch from Slade Rich;
10422         added support for multiple code pages and multiple RAM banks on the
10423         PIC 14 port. The ASM files now no longer simply assume all the
10424         code / RAM are in the same page / bank. This means the linker can
10425         safely allocate code/RAM of separate ASM files to different pages/banks.
10426         * doc/sdccman.lyx: added Slade's tips
10427         * src/mcs51/peeph.def: fixed bug #880768
10428
10429 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10430
10431         * src/hc08/ralloc.c (rematStr): fixed bug #879282
10432         * src/SDCCast.c (decorateType): fixed bug #880197
10433
10434 2004-01-20  Michael Hope  <michaelh AT juju.net.nz>
10435
10436         * sim/ucsim/gui.src/serio.src/main.cc: Fixed unconditional use of
10437         getopt.h.
10438
10439         * debugger/mcs51/cmd.c (getValBasic): Changed strtof to strtod as
10440         strtof is not part of C89 and isn't included with Mac OS X.
10441
10442 2004-01-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10443
10444         * src/hc08/gen.c (genPlusIncr, genUminus, genMinusDec, genCmp,
10445         shiftL2Left2Result): fixed bug #879326
10446         (genAnd, genOr, genXor): fixed bug when result was of type AOP_CRY
10447         (genMultOneByte): fixed bug in signed vs unsigned multiplication
10448         * sim/ucsim/hc08.src/inst.cc (inst_clr): added missing effective
10449         address fetch for clr instruction
10450         * device/lib/hc08/_mulint.c: created optimized assembly version
10451         * src/SDCCdflow.c (computeDataFlow): fixed bug #878209
10452
10453 2004-01-19 Bernhard Held <bernhard AT bernhardheld.de>
10454
10455         * src/SDCCicode.c (geniCodeArray): applied patch from Stas Sergeev
10456         proposed in FR #877103
10457
10458 2004-01-18 Bernhard Held <bernhard AT bernhardheld.de>
10459
10460         * src/SDCCval.c (cheapestVal): added missing checks
10461         * src/SDCCicode.c (usualBinaryConversions): fixed condition
10462         * src/SDCCicode.c (geniCodeAdd): fixed part of bug #877103
10463
10464 2004-01-16 Klaus Flittner <klaus_flittner AT gmx.de>
10465
10466         * src/ds390/gen.c (aopOp3): fixed the assignment of different dptrs to
10467         equal operands
10468
10469 2004-01-16 Vangelis Rokas <vrokas AT otenet.gr>
10470
10471         * src/SDCCmain.c (linkEdit): variable $3 of the linker command is
10472         loaded with the linker search paths (-L arguments) and the libraries
10473         to be linked with the current source (-l arguments). Changes
10474         currently will affect only the pic16 port.
10475         * src/pic16/main.c (_pic16_finaliseOptions): add to the linker
10476         include path the port specific paths and port specific libraries,
10477         * gplink command now contains the $3 argument,
10478         * src/pic16/device.h,
10479         * src/pic16/device.c,: structure PIC_device is made public and
10480         renamed to PIC16_device, the same for variable Pics which is renamed
10481         to Pics16. Updated all references to them.
10482         * src/pic16/glue.c (pic16glue): corrected bug with code
10483         initialization which bypassed the variable initializations block.
10484
10485         * device/lib/pic16/Makefile.rules: removed --penable-stack from
10486         COMPILE_FLAGS and added the --nostdinc option
10487
10488 2004-01-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10489
10490         * device/include/mc68hc908jb8.h: Register defs for another member
10491         of the hc08 family. Contributed by Bjorn Bringert - thanks!
10492
10493 2004-01-14 Vangelis Rokas <vrokas AT otenet.gr>
10494
10495         Documenting changes from previous commits.
10496         * configure.in (version 1.56),
10497         * configure: initially I've added AC_CONFIG_SUBDIRS(device/lib/pic16)
10498         when generating output files to configure the pic16 library,
10499         but now I've commented it out, since gputils aren't installed in the
10500         SF compile farm, so library won't compile
10501
10502         * device/lib/Makefile.in (version 1.56): initially I've added in
10503         target 'all' the prerequestive 'model-pic16' so it compiled the
10504         pic16 library, but now I've commented it out for the same reasons
10505         above,
10506         * added targets 'model-pic16' and 'objects-pic16' to compile the
10507         library
10508         * added target 'port-specific-objects-pic16' to handle the
10509         generated libraries and copy them into the build/ directory
10510         * added target 'clean-intermediate-pic16' to clean intermediate
10511         files into pic16 directory
10512         * in target 'installdirs' added line to create directory pic16 in
10513         the installation path
10514
10515         * device/include/Makefile.in (version 1.11): in target 'install'
10516         added lines to copy all header files to installation path,
10517         * in target 'installdirs' added line create directory for pic16
10518         headers in the installation path
10519
10520 2004-01-13 Klaus Flittner <klaus_flittner AT gmx.de>
10521
10522         * src/ds390/gen.c (genCall): fixed a double use of acc and b after
10523          a function call
10524
10525 2004-01-13 Bernhard Held <bernhard AT bernhardheld.de>
10526
10527         * configure,
10528         * device/lib/configure.in,
10529         * device/lib/configure: fixed for autoconf 2.57
10530
10531 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10532
10533         * src/z80/main.c (_parseOptions): fixed the portmode= command line
10534         option so that it actually works. Made it specific to the z80, since
10535         the gbz80 doesn't have these kinds of I/O ports.
10536
10537 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10538
10539         * device/include/z180.h,
10540         * device/lib/_memcpy.c,
10541         * device/lib/_memmove.c,
10542         * device/lib/_mulint.c,
10543         * device/lib/ser_ir.c,
10544         * device/lib/ser_ir_cts_rts.c,
10545         * device/lib/_strcmp.c,
10546         * device/lib/_strtok.c: fixed pragmas to non-deprecated form
10547         * src/z80/main.c (_process_pragma): add support for pragmas bank and
10548         portmode; added deprecation warning for bank= and protmode= forms.
10549         Also, guard against buffer overflow.
10550         * src/z80/gen.c (aopGet): generate better code for sfr banked read
10551
10552 2004-01-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10553
10554         * src/hc08/main.c (_hc08_genAssemblerPreamble): fixed bug #875487. Also
10555         changed interrupt vector table generation to only emit declared vectors.
10556         * device/include/Makefile.in: added missing backslash
10557         * device/lib/pic16/Makefile.rules: add $(MODELFLAGS) to $(CFLAGS)
10558
10559 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
10560
10561         Mainly changes to support compilation of the device libraries
10562         * src/pic16/device.c: stack is allocated via symbol and not
10563         via literal number. The symbol is placed in the corresponding
10564         position of the data ram
10565         * (pic16_dump_section): relocatable and absolute uninitialized
10566         data are now emitted in sorted order to reduce section naming,
10567         * src/pic16/ralloc.c (newReg): fixed bug with SFR's that
10568         weren't marked as being in the access bank,
10569
10570 2004-01-13 Vangelis Rokas <vrokas AT otenet.gr>
10571
10572         Added portion of GNU PIC Library under the directory
10573         device/include/pic16 and device/lib/pic16. These files
10574         contain the declarations of SFRs for the PIC18Fxx2 devices.
10575         The directory is initialized via configure from toplevel.
10576
10577 2004-01-12 Klaus Flittner <klaus_flittner AT gmx.de>
10578
10579         * src/ds390/gen.c (operandsEqu): fixed a little typo, that prevented
10580         the spilllocations to be compared correctly
10581
10582 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
10583
10584         * src/SDCCast.c (decorateType): fixed bug introduced today
10585
10586 2004-01-12  Borut Razem <borut.razem AT siol.net>
10587
10588         * src/SDCC.lex, support/Util/SDCCerr.h, support/Util/SDCCerr.c,
10589         doc/sdccman.lyx: upper case pragmas are deprecated
10590
10591 2004-01-12 Bernhard Held <bernhard AT bernhardheld.de>
10592
10593         * src/SDCCast.c (decorateType): replacing 'ul > 0' by  '!ul' results
10594         in simpler and even better code
10595
10596 2004-01-11 Bernhard Held <bernhard AT bernhardheld.de>
10597
10598         * src/SDCCicode.c (operandOperation): fixed bug #874819
10599         * src/SDCCast.c (decorateType): fixed
10600         char foo (unsigned long ul) { return ul > 0; }
10601
10602 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10603
10604         * doc/sdccman.lyx: Moved and added some sections, small changes
10605         all over. Telling LaTeX to be less strict with word spacing
10606         to better keep the right margin. Changed some notes about
10607         maintainance of the ports in section 3.2.1 - is it OK like this?
10608
10609 2004-01-11 Vangelis Rokas <vrokas AT otenet.gr>
10610
10611         SDCC source changes:
10612         * src/SDCCopt.c (cntToFcall, cnvToFloatCast, cnvFromFloatCast,
10613         convilong): modified to inform the pic16 port that builtin functions
10614         are external
10615
10616         PIC16 PORT specific changes:
10617         * src/pic16/device.c pic16_dump_equates() added,
10618         processor registers declared internally by the port are emitted in
10619         the translation as equates,
10620         * src/pic16/gen.c: inline code is passed unprocessed to the
10621         translation,
10622         * (pic16_popGetLit2): fnuction modified to take second operand as
10623         pCodeOp pointer and not as literal,
10624         * (popRegFromIdx): prefixed with pic16_,
10625         * (pic16_popCombine2): modified to receive already allocated pCode
10626         operands,
10627         * (pic16_pushpCodeOpReg, pic16_poppCodeOpReg): added
10628         * (genFunction): initializes local stack frame and pushes on stack
10629         all the registers used by this function,
10630         * (genEndFunction): restores all registers from stack and restores
10631         stack frame,
10632         * src/pic16/glue.c (pic16emitRegularMap): various changes and
10633         improvements,
10634         * (pic16glue): changed the program startup sequence,
10635         * added new dbName code 'A' for functions placed in absolute section
10636         * src/pic16/main.c: added function attribute _naked,
10637         * added pragma 'code' to place a fnuction at an absolute address,
10638         * added command line arguments --debug-ralloc and --pcode-verbose,
10639         * (_pic16_finiliseOptions): options.all_callee_saves is set by default
10640         * src/pic16/pcode.c (pic16_pBlockConvert2Absolute) added,
10641         * (pic16_newpCodeOpLit2): modified to take the second operand as
10642         pCodeOp pointer,
10643         * (pic16_printpBlock): modified to emit each function in a separate
10644         section,
10645         * (pic16_get_op): modified to use the gpasm modifiers LOW,HIGH and
10646         UPPER for immediate operands,
10647         * src/pic16/pcodepeeph.c: added peephole support for the LFSR
10648         instruction,
10649         * src/pic16/peeph.def: all peepholes with movff are commented out,
10650         because there is a problem in the pcode peep optimizer,
10651         * src/pic16/ralloc.c: the register allocator can now reuse local
10652         function symbols for another function. This saves register usage.
10653         * src/pic16/ralloc.h: added flag isLocal in structure regs,
10654
10655         Added file src/pic16/NOTES with information about program writing on
10656         the current port version.
10657
10658 2004-01-11 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10659
10660         * src/mcs51/peephole.def: added peepholes 177.c,d (redundant moves)
10661         and peephole 252 (array access)
10662
10663 2004-01-09  Borut Razem <borut.razem AT siol.net>
10664
10665         * src/SDCCmain.c : fixed #872250: -l command line defined library
10666           files are scanned before standard library files
10667
10668 2004-01-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10669
10670         * src/SDCCast.c (decorateType): fixed bug #874046
10671
10672 2004-01-09  Borut Razem <borut.razem AT siol.net>
10673
10674         * support/scripts/sdcc.nsi: remove previous installation
10675
10676 2004-01-09 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10677
10678         * src/SDCCglue.c (createInterruptVect): don't append 7(5) padding
10679         bytes for last interrupt vector (mcs51)
10680         * sdcc.spec: fixed typo
10681
10682 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10683
10684         * src/mcs51/gen.c (genFunction, genEndFunction, genReceive, getTempRegs,
10685         gen51Code): more efficient parameter receive for --model-large
10686         ("bug" #845294)
10687
10688 2004-01-09 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10689
10690         * src/ds390/main.c,
10691         * src/z80/main.c: added missed needLinkerScript flags (more than
10692         one port structure defined in these file)
10693         * src/ds390/gen.c (aopForSym, aopOp, operandsEqu, aopOp3): fixed
10694         bug #795325
10695
10696 2004-01-08 Vangelis Rokas <vrokas AT otenet.gr>
10697
10698         * src/SDCCmain.c: removed various references to DEFAULT_PORT
10699         * src/port.h: added flag needLinkerScript in port->linker
10700         structure to inform whether to create a .lnk file or not,
10701         * src/avr/main.c,
10702         * src/ds390/main.c,
10703         * src/hc08/main.c,
10704         * src/mcs51/main.c,
10705         * src/pic/main.c,
10706         * src/pic16/main.c,
10707         * src/xa51/main.c,
10708         * src/z80/main.c: changed appropriately to configure
10709         needLinkerScript flag
10710         * src/pic/gen.c,
10711         * src/pic16/gen.c (genAddrOf): fixed bug #863624
10712         * src/pic/glue.c: added variable udata_section_name to
10713         override default uninitialized data segment definition for
10714         devices only with SHAREBANK memory (reported from Erik Epetrich)
10715         * (pic14emitOverlay): modified to emit a commented overlay segment
10716         directive when no overlay data exist
10717         * (picglue): modified to emit uninitialized data segment
10718         according to udata_section_name
10719         * src/pic/main.c (_pic14_parseOptions): added command line
10720         options --udata-section-name=[name] to override default
10721         udata definition name
10722         * modified _linkCmd and _asmCmd to include compiler passed
10723         arguments via -W option
10724         * src/pic16/main.c: added $l in _asmCmd, changed extension for
10725         object file from '.rel' to '.o' in port->linker structure,
10726         changed size of fptr from 2 to 3 in port structure
10727
10728 2004-01-07  Borut Razem <borut.razem AT siol.net>
10729
10730         * support/scripts/sdcc.nsi: update PATH
10731         * support/scripts/sdcc.ico: craeted
10732
10733 2004-01-07 Bernhard Held <bernhard AT bernhardheld.de>
10734
10735         * device/include/Makefile.in: fix install
10736         * doc/Makefile: fix install
10737
10738 2004-01-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10739
10740         * src/SDCCsymt.c (processFuncArgs): fixed superflous allocation noted
10741         in bug #860505
10742         * src/SDCCmem.c (printAllocInfoSeg, printAllocInfo): minor changes to
10743         how the function variable allocation summary is displayed; also
10744         include information about variables allocated to the overlay
10745         segment
10746
10747 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10748
10749         * as/mcs51/lkmain.c: Help about -Y option
10750         * as/mcs51/lkarea.c: Fixed gcc warnings
10751
10752 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
10753
10754         * src/SDCCval.c (valShift): changed from 16 to 32 bit shift count,
10755         fixed warning
10756         * support/valdiag/tests/overflow.c: added
10757         * src/SDCCast.c (decorateType),
10758         * src/SDCCicode.c (geniCodeLeftShift): added promotion to int for
10759         LEFT_OP (left shift)
10760
10761 2004-01-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10762
10763         * as/mcs51/lkmain.c: stack must be after data when option -Y is not used
10764         (default behaviour).
10765
10766 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10767
10768         A python script to validate compiler diagnostic messages. It can be
10769         used to verify that sdcc complains about bad c source code and
10770         gives a good location of the error.
10771         * support/valdiag/Makefile,
10772         * support/valdiag/valdiag.py,
10773         * support/valdiag/tests/*
10774
10775 2004-01-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10776
10777         * src/SDCC.y (enum_specifier, enumerator_list, opt_assign_expr),
10778         * src/SDCCsymt.c (newEnumType),
10779         * src/SDCCsymt.h
10780         * support/Util/SDCCerr.c,
10781         * support/Util/SDCCerr.h: fixed bug #871258 and some other unreported
10782         enum related bugs.
10783         * support/regression/tests/enum.c: added test for enum values that
10784         require at least 2 bytes of storage.
10785
10786 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
10787
10788         * src/common.h: added ifndef/define/endif macros
10789         around the header file.
10790         Bug reported from Jesus Calvino-Fraga
10791
10792 2004-01-06 Bernhard Held <bernhard AT bernhardheld.de>
10793
10794         * sdcc.spec: updated
10795         * device/include/Makefile.in: don't install CVS directories
10796         * device/lib/Makefile.in: added removal of CVS directories after install
10797         * doc/Makefile: fixed install, added local_icons
10798         * sim/ucsim/gui.src/Makefile.in: fixed an old typo
10799         * src/mcs51/gen.c (genRightShift): fixed bug #870788
10800         * src/ds390/gen.c (genRightShift): fixed bug #870788
10801         * src/SDCCast.c (decorateType): fixed bug #870781
10802
10803 2004-01-06 Vangelis Rokas <vrokas AT otenet.gr>
10804
10805         PIC16 port related changes:
10806         * device.c: removed pic16_finalMapping and pic16_finalMappingSize,
10807         added variable stackPos,
10808
10809         * gen.c: genCall, assignResultValue: added support for
10810         pushing/retrieving function parameters to/from stack,
10811         genFunction,genEndFunction: setup stack frame for the
10812         generated function,
10813         genAddrOf: will be changed according to bug 863624
10814
10815         * added files genutils.c and genutils.h which contain gen*
10816         debugged and optimised functions extracted from gen.c
10817
10818         * glue.c: added variable 'externs' which holds extern symbols,
10819         pic16emitRegularMap: is modified to properly handle relocatable
10820          symbols under the new scheme,
10821         pic16createInterruptVect: is modified
10822         pic16printPublics: is modified to emit 'global' assembler directives,
10823         added pic16_printExterns to print extern symbols,
10824         pic16glue: initializes stack/frame pointer in the beginning of
10825         the assembly output. Temporary hack, will be corrected later,
10826         because gplink yet does not support stack and SDCC does not
10827         yet support a type of crt0.o object to create the final binary.
10828
10829         * Removed many lines that contain 8051 legacy code.
10830         * The code is finally placed under a 'code' directive.
10831         * Added port specific options.
10832
10833         * _process_pragma: simplified since now we do not need *special*
10834         include file to define SFR registers. But a separate header
10835         will be needed. This will be developed later.
10836         * _pic16_parseOptions: added, parses port specific options:
10837         --pgen-banksel, --obanksel=, --pomit-config-words, --pomit-ivt,
10838         --pleave-reset-vector, --penable-stack, --pstack-model, --debug-xtra
10839         --preplace-udata-with=
10840
10841         * _pic16_setDefaultOptions: modified to initialize section names,
10842         but hack is temporarly out of order since it needs improvement.
10843         * _pic16_genAssemblerPreamble: configuration words are emitted by
10844         their address instead of their name. This part is incomplete and
10845         supports only the 18Fxx2 devices. Other devices will emit an error
10846         during assembly since they do not contain the same set of config
10847         registers
10848         * _pic16_genIVT: is modified,
10849
10850         * pcode.c: added definitions for some hardware registers that are needed
10851         for stack support
10852         * added flag is2LitOp and variable pci_magic in pCodeInstruction.
10853         All PCI entries are updated. Now LFSR is supported.
10854         * Removed pic16_pciTRIS is mentioned by mdubuc in source
10855         * added pic16_newpCodeOpLit2 to support instructions with
10856         two literal arguments
10857         * pic16_pCode2str: corrected code that emits assembler instructions
10858         with two literal operands and those that have an access bit modifier
10859         * genericPrint: now PC_ASMDIR pCodes, can emit a label if it exists,
10860         this fixes a bug which caused some labels to be lost, when an
10861         assembler directive was added, i.e. banksel,
10862         * pic16_FixRegisterBanking: improved logic that causes the insertion
10863         of bank switching,
10864         * InlineFunction: functions that are called once, are not any more
10865         inlined. This can be a port option in the future,
10866
10867         * pcode.h: added pCodeOpLit2 and added variable label in pCodeAsmDir
10868
10869         * ralloc.c: added pic16_rel_udata and pic16_fix_udata variables which
10870         hold the corresponding uninitialized symbols,
10871         * pic16_allocProcessorRegister: registers have explicit marked the
10872         accessBank field,
10873         * pic16_allocInternalRegister: registers are explicit marked as
10874         not used,
10875         * pic16_writeUsedRegs: pic16_dynDirectBitRegs was missing from the
10876         processing list, so bit registers were lost,
10877         *
10878
10879         * ralloc.h: added field 'accessBank' and original symbol operand
10880         in register definition,
10881         * removed the field isMapped from register definition,
10882
10883         ** Several functions have been removed from various sources:
10884         BanksUsedFlow2,BanksUsedFlow,FixBankFlow,InstructionRegBank,
10885         pic16_addMemRange,pic16_isREGinBank,pic16_dump_map,pic16_dump_cblock
10886         isSFR,validAddress,mapRegister,assignRegister,pic16_assignFixedRegisters
10887         pic16_assignRelocatableRegisters
10888
10889         ** others have been introduced:
10890         pic16_areRegsSame,pic16_dump_section,checkAddReg,pic16_groupRegistersInSection
10891         pic16_popGetLit2,pic16_popCombine2,pushw,pushaop
10892
10893 2004-01-05 Vangelis Rokas <vrokas AT otenet.gr>
10894
10895         * support/scripts/inc2h.pl: changed definition of BIT_AT
10896         to emit 'sbit at' instead of 'bit at'. This was a request.
10897
10898         PIC16 port related preliminary changes:
10899         * gen.c: prefixed function popRegFromString with
10900         pic16_ and all references to it corrected
10901         * pcode.c: all pic16_pc_* hardware registers prefixed
10902         with underscore (_),
10903         pic16_popCopyGPR2Bit(): function sets register wasUsed=1
10904         * ralloc.c: newReg(): when register is REG_SFR then
10905         set address to rIdx,
10906         pic16_allocProcessorRegister(): marks register wasUsed=0
10907         pic16_writeUsedRegs(): added a call to assign processor
10908         registers via pic16_assignFixedRegisters
10909
10910 2004-01-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
10911
10912         * as/mcs51/aslink.h, as/mcs51/lkarea.c, as/mcs51/lkdata.c,
10913         as/mcs51/lkmain.c, as/mcs51/lkmem.c: 8051 linker can now pack
10914         variables in unused register banks.  Also the SSEG is placed
10915         wherever there is enough space for it, and IDATA can be anywhere
10916         in internal RAM.  For now compile using -Wl-Y[stack_size].
10917         The mem file is different for this option as well, since it
10918         makes no sense of talking about DSEG lenght.
10919
10920 2004-01-02 Vangelis Rokas <vrokas AT otenet.gr>
10921
10922         * src/SDCClrange.c: fixed bug 869095 that caused segfault
10923         in certain cases, e.g. when ROM assignment, patch provided
10924         from Albert den Haan.
10925
10926 2004-01-01 Bernhard Held <bernhard AT bernhardheld.de>
10927
10928         Many signedness and type propagation fixes:
10929         * src/SDCCicode.c: made geniCodeCast() static
10930         replaced SPEC_ by IS_ (cosmetic)
10931         (operandOperation): fixed div and mod operation
10932         (usualBinaryConversions): added support for promotion of char
10933         (geniCodeMultiply): replaced (unsigned long) by (TYPE_UDWORD)
10934         (geniCodeDivision): replaced (unsigned long) by (TYPE_UDWORD)
10935         (geniCodeAdd): an array index will stay unsigned, even if promoted
10936         from char to int
10937         (geniCodeArray): ditto
10938         * src/SDCCicode.h: made geniCodeCast() static: removed prototype
10939         * src/SDCCsymt.c (computeType): added more support for char;
10940         promotion of char is selectable by promoteCharToInt, fixed signedness
10941         for all cases
10942         (powof2): replaced (unsigned long) by (TYPE_UDWORD)
10943         * src/SDCCsymt.h (powof2): replaced (unsigned long) by (TYPE_UDWORD)
10944         * src/SDCCval (val*): replaced signedness calculation by
10945         computeType()
10946         rearranged if-branches (cosmetic)
10947         (valShift): added warning W_SHIFT_CHANGED
10948         (valCompare): fixed problem with different types
10949         * src/hc08/rallo.c (leastUsedLR): fixed gcc 3.3 warning
10950         * support/regression/tests/literalop.c: added many cases
10951         * support/regression/tests/ast_constant_folding.c: changed finally to
10952         'unsigned int'
10953         * .version: new year, new version: 2.3.7
10954         * src/SDCCmain.c (main): applied patch #866468
10955         * debugger/mcs51/sdcdb.c (parseCmdLine): added -k for ucsim, patch
10956         provided by Scott Bronson
10957         * doc/sdccman.lyx: updated documentation for sdcdb
10958         updated and added chapter tips
10959
10960 2004-01-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10961
10962         * src/SDCCsymt.h: missing from yesterday's commits
10963
10964 2003-12-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10965
10966         * src/SDCC.y (struct_or_union_specifier),
10967         * support/Util/SDCCerr.c,
10968         * support/Util/SDCCerr.h: verify that struct & union tags are used
10969         as declared.
10970
10971 2003-12-29 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10972
10973         * src/SDCCglobl.h: missing from yesterday's commits
10974
10975 2003-12-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10976
10977         * src/SDCC.y (external_definition, type_specifier2, sfr_reg_bit,
10978         sft_attributes, struct_declaration, parameter_declaration,
10979         type_name, start_block, declaration_list),
10980         * src/SDCC.lex (check_type): support redefinition of typedef names
10981
10982 2003-12-22 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
10983
10984         * src/mcs51/gen.c (genPlus): added special handling for 256 byte
10985         aligned xdata arrays. Erik helped me with the if clause.
10986
10987 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10988
10989         * device/lib/ds390/tinibios.c (CpuSpeed): suppress unreachable code
10990         warning
10991
10992 2003-12-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
10993
10994         * src/SDCCast.h,
10995         * src/SDCCast.c (newAst_),
10996         * src/SDCCicode.h,
10997         * src/SDCCicode.c (ast2iCode, newiCode),
10998         * src/SDCCglobl.h,
10999         * src/SDCC.y (logical_and_expr, logical_or_expr, conditional_expr,
11000         expr, statement, expression_statement, selection_statement,
11001         iteration_statement, expr_opt, jump_statement): foundation for tracking
11002         sequence points
11003         * src/SDCCopt.c (killDeadCode): fixed bug #861580 (needs the sequence
11004         point code too)
11005
11006 2003-12-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11007
11008         * support/Util/SDCCerr.c,
11009         * src/SDCCast.h,
11010         * src/SDCCast.c (createCase, createDefault, decorateType),
11011         * src/SDCClabel.c (labelUnreach),
11012         * src/SDCC.y (labeled_statement, jump_statement): More improvements
11013         to error messages.
11014         * support/Util/SDCCerr.c (werrorfl): fixed a non-standard declaration
11015         (with thanks to Stas Sergeev)
11016         * device/include/time.h,
11017         * device/lib/time.c (CheckTime): suppress unreachable code warning
11018
11019 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11020
11021         * src/SDCCast.c (createIvalCharPtr),
11022         * src/SDCCglue.c (printChar): fixed bug #862241 (an error in my fix for
11023         bug #753752)
11024         * support/regression/tests/nullstring.c: tests for these two bugs
11025
11026 2003-12-18 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11027
11028         * support/Util/SDCCerr.h,
11029         * support/Util/SDCCerr.c (E_NOT_ALLOWED),
11030         * src/SDCC.y (struct_declaration, struct_or_union_specifier): complain
11031         about storage class and 'at' used inside struct or union
11032         * src/SDCCBBlock.c (iCodeFromeBBlock),
11033         * src/SDCCcse.c (ifxOptimize),
11034         * src/SDCCglue.c (emitRegularMap, initPointer, printIvalStruct,
11035         printIvalArray, printiValFuncPtr, printIvalCharPtr, printIvalPtr,
11036         printIval, emitStaticSeg, emitOverlay),
11037         * src/SDCClabel.c (deleteIfx),
11038         * src/SDCCopt.c (replaceRegEqv, eBBlockFromiCode),
11039         * src/SDCCast.c (resolveSymbols, createIvalStruct, createIvalArray,
11040         gatherAutoInit, processParms),
11041         * support/Util/SDCCerr.h,
11042         * support/Util/SDCCerr.c (werrorfl): Support for better error location
11043         reporting for post-parse errors.
11044
11045 2003-12-16 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11046
11047         * src/SDCCval.c (valPlus, valMinus, valShift): fixed some problems with
11048         implicit casts via union; they don't work on big endian systems
11049         (possible fix for bug #861138)
11050
11051 2003-12-16 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11052
11053         (committed by Erik Petrich <epetrich AT ivorytower.norman.ok.us> on Frieder's behalf)
11054         * src/mcs51/main.c: fixed the fix for bug #737001
11055
11056 2003-12-15  Borut Razem <borut.razem AT siol.net>
11057
11058         * support/scripts/sdcc.nsi: updated for NSIS 2.0 beta 4
11059
11060 2003-12-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11061
11062         * support/makebin/makebin.c: put output in binary mode
11063
11064 2003-12-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11065
11066         * src/mcs51/main.c: fixed bug #737001 for the mcs51. SDCC clears
11067         xdata and data memory on startup. Set the environment variable
11068         SDCC_NOGENRAMCLEAR to disable this.
11069         * src/mcs51/peephole.def,
11070         * src/ds390/peephole.def: using the atomic test and clear instruction jbc
11071         (allows non-interrupt and interrupt code to safely compete for a resource
11072         without the non-interrupt code having to disable interrupts)
11073
11074 2003-12-13 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11075
11076         * src/SDCCicode.c (geniCodeAdd),
11077         * src/SDCCast.c (decorateType): fixed bug #857753 (need to be careful
11078         with valFromType if type might be a pointer and host is big endian).
11079         * src/SDCCast.c (decorateType): unary plus compatible with all arithmetic
11080         types, not just integer types.
11081         * src/SDCCsymt.c (addSymChain): clarified error message when symbol is
11082         multiply defined with mismatching "at" address.
11083
11084 2003-12-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11085
11086         * src/ds390/main.c (PORT tininative_port): fixed bug #858416
11087         * src/SDCCglue.c (printChar, printIvalChar, emitStaticSeg),
11088         * src/SDCCast.c (createIvalCharPtr, stringToSymbol): handle strings
11089         with embedded nulls (fixed bug #753752)
11090
11091 2003-12-12 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11092
11093         * src/mcs51/main.c(_mcs51_genRAMCLEAR): using r0 instead of r1/r2.
11094         Apparently this did not see much testing (endless loop)
11095
11096 2003-12-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11097
11098         * src/z80/ralloc.c: set DISABLE_PACK_HL = 1 as a temporary fix to bug #855165
11099
11100 2003-12-10 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11101
11102         * src/SDCCdebug.c (outputDebugSymbols, outputDebugStackSymbols, dumpSymInfo):
11103         gracefully handle NULL memmap pointers
11104
11105 2003-12-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11106
11107         * src/SDCCopt.c (killDeadCode): change iCode type to DUMMY_READ_VOLATILE
11108         instead of deleting the iCode when an operand is volatile
11109         * src/z80/gen.c (genDummyRead),
11110         * src/mcs51/gen.c (genDummyRead),
11111         * src/ds390/gen.c (genDummyRead),
11112         * src/hc08/gen.c (genDummyRead): handle operands in IC_LEFT and/or IC_RIGHT,
11113         not just IC_RIGHT
11114         * src/SDCCicode.c (geniCodeCall): fixed bug #851607
11115         * src/SDCC.y: fixed bug #850420
11116
11117 2003-12-05 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11118
11119         Applied z80 i/o port patch from Peter Townson and fixed some operators
11120         to better handle operands in A register.
11121         * device/include/z180.h
11122         * src/SDCC.y
11123         * src/SDCCglue.c
11124         * src/z80/gen.c
11125         * src/z80/gen.h
11126         * src/z80/main.c
11127         * src/z80/peeph-z80.def
11128         * src/z80/peeph.def
11129         * src/z80/z80.h
11130
11131 2003-12-03 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11132
11133         * src/SDCCsymt.c (addSymChain, compareTypeExact): fixed bug #838241 again
11134
11135 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11136
11137         * device/lib/hc08/_mullong.c: Removed extra #endif
11138
11139 2003-12-01 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11140
11141         * sim/ucsim/hc08.src/inst.cc,
11142         * sim/ucsim/hc08.src/hc08mac.h: fixed some problems with CC flag bits and
11143         carries from x to h
11144         * src/hc08/gen.c (aopAdrStr): fixed problem with 16 bit immediate
11145         * src/hc08/gen.c (XAccRsh): fixed problem with right shift
11146         * device/include/stdarg.h: fixed varargs for hc08
11147         * device/lib/Makefile.in,
11148         * device/lib/hc08/Makefile,
11149         * device/lib/hc08/_mulint.c,
11150         * device/lib/hc08/_mullong.c: fixed some endian problems
11151
11152 2003-11-28 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11153
11154         * sdcc/src/mcs51/gen.c (genMultOneByte): help peephole 105
11155         * sdcc/src/mcs51/peeph.def: added peephole 186.e array access in code space
11156         * device/lib/_gptrget.c,
11157         * device/lib/_gptrput.c: P2 not used any more (related to #850747, #785979)
11158
11159 2003-11-27 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11160
11161         * src/SDCClrange.c (findNextUseSym, rlivePoint): fixed bug #849795
11162         * src/SDCCast.c (astErrors): fixed bug #846007
11163         * src/SDCCsymt.c (checkFunction): fixed follow-up bug on bug #846007
11164
11165 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11166
11167         * src/SDCCast.c (decorateType): disabled a transformation I added in
11168         revision 1.188 (access to fields of a structure at an absolute address);
11169         it breaks with bitfields, extern declarations, and gcse analysis.
11170         * src/SDCCopt.c (isLocalWithoutDef): if ADDRESS_OF applied to a symbol, it
11171         could be assigned through a pointer, so don't complain.
11172         * src/SDCCast.c (astErrors),
11173         * src/SDCCast.h,
11174         * src/SDCCglue.c (emitRegularMap): fixed bug #847813
11175
11176 2003-11-26 Vangelis Rokas <vrokas AT otenet.gr>
11177
11178         * src/pic16/main.c (_pic16_genIVT): fixed interrupt vector table
11179         * src/pic16/main.c (_pic16_genAssemblerPreamble): re-enabled the
11180         output of __config directives, since gpasm now supports them
11181         * src/pic16/main.c (_pic16_finaliseOptions): define MCU
11182         pre-processor macro, i.e. -DMCU=p18f452
11183         * src/pic16/ralloc.c: renamed packRegisters to pic16_packRegisters,
11184         and modified to handle 'cast' icode similarly to '=' icode
11185         * src/pic16/device.h (typedef struct PIC_device): added field
11186         'extMIface' to indicate that chip has external memory interface
11187         * src/pic16/device.c: added chips 18F248, 18F258, 18F448, 18F458,
11188         18F6520, 18F6620, 18F6680, 18F6720, 18F8520, 18F8620, 18F8680,
11189         18F8720
11190
11191 2003-11-26 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11192
11193         * src/SDCC.y (pointer): fixed bug #846006
11194         * support/Util/SDCCerr.c: made W_PTR_TYPE_INVALID message clearer
11195         * src/SDCCast.c (decorateType): fixed bug #846009
11196         * src/ds390/peeph.def,
11197         * src/ds390/gen.c (genAnd, genOr),
11198         * src/mcs51/peeph.def,
11199         * src/mcs51/gen.c (genAnd, genOr): fixed bug #846777
11200
11201 2003-11-25 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11202
11203         Fixed several common-sub-expression bugs (#772861, #768380, & #755323)
11204         * src/SDCCdflow.c
11205         * src/SDCCcse.c
11206         * src/SDCCcse.h
11207         * src/SDCCBBlock.h
11208         * src/SDCCBBlock.c
11209
11210 2003-11-23 Klaus Flittner <klaus_flittner AT gmx.de>
11211
11212         fixed bug #845089
11213         * src/SDCCbitv.h,
11214         * src/SDCCbitv.c: added function to free a bitvector
11215         * src/SDCClrange.h,
11216         * src/SDCClrange.c: added function to recompute the liveranges
11217         * src/avr/ralloc.c,
11218         * src/ds390/ralloc.c,
11219         * src/hc08/ralloc.c,
11220         * src/mcs51/ralloc.c,
11221         * src/pic/ralloc.c,
11222         * src/pic16/ralloc.c,
11223         * src/xa51/ralloc.c,
11224         * src/z80/ralloc.c: recompute the liveranges after register packing
11225
11226 2003-11-21 Klaus Flittner <klaus_flittner AT gmx.de>
11227
11228         * src/SDCCloop.c (newInduction): fixed bug #845630
11229
11230 2003-11-21 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11231
11232         * src/SDCCsymt.c (compareTypesExact): disabled debugging output
11233         inadvertantly left behind from my 2003-11-12 change
11234
11235 2003-11-20 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11236
11237         Updated headers I neglected to commit yesterday.
11238         * src/SDCClrange.h,
11239         * src/SDCCicode.h
11240
11241 2003-11-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11242
11243         * src/SDCCcse.c (algebraicOpts): fixed bug #773153
11244         * src/SDCClrange.c (rlivePoint): need to mark IC_RESULT used if POINTER_SET op
11245         * src/SDCCopt.c (eBBlockFromiCode),
11246         * src/SDCClrange.c (hashiCodeKeys, sequenceiCode, computeLiveRanges): seperated
11247         the creation of the key hash table from the sequencing so it can be used
11248         earlier (for some GCSE bug fixes still pending)
11249
11250 2003-11-15 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11251
11252         * src/mcs51/gen.c (genPlus): generate shortcut for adding 0xab00
11253         * support/regression/tests/addsub.c: testing genPlus shortcut
11254
11255 2003-11-15  Borut Razem <borut.razem AT siol.net>
11256
11257         * src/SDCCmain.c: fixed bug #841645: -MM command line option passed to sdcpp
11258
11259 2003-11-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11260
11261         * src/SDCCcse.c (cseBBlock): fixed bug #527779
11262         * src/SDCCcse.c (deleteGetPointers): rewrote so that the set
11263         ordering is immaterial.
11264         * src/SDCCdflow.c (mergeInExprs): fixed bug #587536
11265
11266 2003-11-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11267
11268         * src/SDCCicode.c (geniCodeAddressOf): fixed part of bug #840381
11269         * src/SDCCopt.c (replaceRegEqv, isLocalWithoutDef): fixed other part
11270         (SIGSEV) of bug #840381
11271         * src/SDCCmain.c (linkEdit, assemble): fixed bug #841606 (don't
11272         unlink new file before rename if new and old filenames are the same)
11273
11274 2003-11-13 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11275
11276         * src/mcs51/main.c: started fixing bug #737001 (SDCC not clearing
11277         uninitialized variables) for the mcs51. Set environment variable
11278         SDCC_GENRAMCLEAR to test.
11279         xdata initialization slightly shorter
11280
11281 2003-11-12 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11282
11283         * src/SDCCsymt.h,
11284         * src/SDCCsymt.c (addSymTypeChain, compareTypesExact): fixed bugs
11285         #838241 & 780691 (basicly the same bug)
11286         * src/SDCCBBlock.c (iCode2eBBlock): fixed bug #840148
11287         * src/SDCCBBlock.c (iCodeFromeBBlock): fixed bug #840162
11288
11289 2003-11-11 Bernhard Held <bernhard AT bernhardheld.de>
11290
11291         * src/SDCCmain.c (linkEdit): "fix" #834252
11292
11293 2003-11-11 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11294
11295         * src/SDCCast.c (removePostIncDecOps, removePreIncDecOps),
11296         * src/SDCCast.h,
11297         * src/SDCC.y: fixed bug #819403
11298
11299 2003-11-08 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11300
11301         * support/regression/fwk/lib/testfwk.c: printn is recursive and thus needs
11302         the reentrant attribute.
11303         * src/hc08/gen.c (genPackBits): added missing stack readjustment
11304         * sim/ucsim/hc08.src/inst.cc (inst_mov): fixed bugs with mov instruction
11305         simulation
11306         * src/SDCCast.c (decorateType): fixed bug with storage class not being
11307         updated during pointer dereference; f.e. ~(((char *)1)*) was being
11308         erroneously reduced to a literal.
11309         * src/hc08/ralloc.c (packRegisters, rematStr),
11310         * src/hc08/gen.c (aopForRemat): allow literals to be rematerialized in
11311         some cases
11312
11313 2003-11-08 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11314
11315         * src/mcs51/main.c: fixed bug #838385. Thanks to Josef Pavlik for finding and fixing
11316         * doc/sdccman.lyx: changed from 'article' to 'book'
11317         * doc/Makefile: readded test_suite_spec and cdbfileformat
11318
11319 2003-11-08 Bernhard Held <bernhard AT bernhardheld.de>
11320
11321         * device/include/stdlib.h: include malloc.h to comply with ANSI
11322         * support/regression/tests/malloc.c: include stdlib.h instead of malloc.h
11323
11324 2003-11-07 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11325
11326         * doc/Makefile: sdccman.pdf should build with correct references (more info in commit msg)
11327         * doc/clean.mk: also remove *.out files
11328         * doc/sdccman.lyx: some additions, larger top/bottom margins
11329
11330 2003-11-07 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11331
11332         * src/SDCC.y: fixed bug #837365
11333         * support/regression/tests/bitopcse.c
11334         * src/hc08/gen.c (genPointerGet): Don't assume pointer operand is
11335         a symbol (might be valop instead)
11336         * device/lib/Makefile.in: added errno.c to HC08SOURCES
11337         * device/lib/clean.mk: added hc08 to the cleaning list
11338
11339 2003-11-04  Borut Razem <borut.razem AT siol.net>
11340
11341         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h: reverted changes,
11342           made 2003-11-04
11343         * support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
11344           as/z80/aslist.c, as/z80/assym.c: removed inclusion of nonstandard malloc.h;
11345           malloc is declared in standard stdlib.h
11346
11347 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11348
11349         * device/lib/hc08/Makefile: need to clean .rel not .o files
11350         * src/hc08/gen.c (genDjnz): can't use djnz with extended addressing mode
11351
11352 2003-11-06 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11353
11354         * src/port.h,
11355         * src/hc08/main.c,
11356         * src/mcs51/main.c,
11357         * src/ds390/main.c,
11358         * src/z80/main.c,
11359         * src/avr/main.c,
11360         * src/pic/main.c,
11361         * src/pic16/main.c,
11362         * src/xa51/main.c: added hasExtBitOp & oclsExpense functions to ports
11363         * src/SDCCicode.c: changed several IS_FARSPACE tests to isOclsExpensive
11364         tests (which uses the port's oclsExpense function)
11365         * src/SDCC.y,
11366         * src/SDCCast.c,
11367         * src/SDCCicode.c,
11368         * src/hc08/gen.c,
11369         * src/ds390/gen.c,
11370         * src/mcs51/gen.c: added support for the SWAP iCode (RFE #834167)
11371
11372 2003-11-04 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11373
11374         * src/SDCCcse.c (ifxOptimize),
11375         * src/SDCClabel.c (labelIfx, deleteIfx): When the condition to
11376         an IFX iCode is volatile, convert to DUMMY_READ_VOLATILE instead
11377         deleting the IFX iCode.
11378         * src/hc08/ralloc.c: reduced unneeded slocs
11379         * src/hc08/gen.c: fixed bug in asmopToBoolean
11380
11381 2003-11-04  Borut Razem <borut.razem AT siol.net>
11382
11383         * configure, configure.in, sdcc_vc_in.h, sdcconf_in.h,
11384           support/Util/NewAlloc.c, as/hc08/lklibr.c, as/mcs51/lklibr.c,
11385           as/z80/aslist.c, as/z80/assym.c: decision to include malloc.h
11386           transferred to configure
11387
11388 2003-11-03 Bernhard Held <bernhard AT bernhardheld.de>
11389
11390         Use headers defined in the C[++] standards:
11391         * sim/ucsim/gui.src/serio.src/fileio.cc
11392         * sim/ucsim/gui.src/serio.src/frontend.cc
11393         * sim/ucsim/gui.src/serio.src/main.cc
11394         * sim/ucsim/gui.src/serio.src/posix_signal.cc
11395         * support/Util/NewAlloc.c
11396         * as/hc08/lklibr.c
11397         * as/mcs51/lklibr.c
11398         * as/z80/aslist.c
11399         * as/z80/assym.c
11400
11401 2003-11-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11402
11403         * Added MSVC projects for hc08 assembler and linker:
11404         all.dsp, config.dsp, sdcc.dsw, /as/hc08/as_hc08.dsp,
11405         /as/hc08/link_hc08.dsp
11406
11407 2003-11-03 Martin Helmling <Martin.Helmling AT octo-soft.de>
11408
11409         * debugger/mcs51/cmd.c: allows filename starting with digit(+ some debug)
11410
11411 2003-11-02 Bernhard Held <bernhard AT bernhardheld.de>
11412
11413         * src/SDCCmain.c (linkEdit): "fixed" again bug #833605
11414
11415 2003-11-01 Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11416
11417         * src/mcs51/main.c: xdata initialization is 13 bytes shorter now
11418
11419 2003-10-31  Borut Razem <borut.razem AT siol.net>
11420
11421         * support/cpp2/cpplib.h,
11422           support/cpp2/cpplib.c,
11423           support/cpp2/cpplex.c,
11424           support/cpp2/cppinit.c: introduced #pragma preproc_asm [ + | - ]
11425           to switch _asm block preprocessing on / off. Default is
11426           #pragma preproc_asm +
11427
11428 2003-10-31  Borut Razem <borut.razem AT siol.net>
11429
11430         * support/cpp2/cpplex.c: Fixed _WIN32 problem with CR-CR-LF sequences
11431           when outputting comment blocks (when executed with -C option) and
11432           _asm (SDCPP specific) blocks
11433
11434 2003-10-31 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11435
11436         * as/hc08/lkrloc.c (relr): Fixed ihx output, fixed lastAreaIndex warning
11437
11438 2003-10-31 Klaus Flittner <klaus_flittner AT gmx.de>
11439
11440         * src/SDCCcse.c (updateSpillLocation): fixed bug #808027
11441
11442 2003-10-31 Bernhard Held <bernhard AT bernhardheld.de>
11443
11444         * src/SDCCmain.c (linkEdit): "fixed" bug #833605
11445         * src/SDCCast.c (decorateType): fixed bug #832664
11446
11447 2003-10-31  Borut Razem <borut.razem AT siol.net>
11448
11449         * support/cpp2/cpplex.c: fixed for SDCPP:
11450           comments(when executed with -C option) and _asm blocks
11451           were included even if they where in skipped #if block.
11452           Applied solution from GCC cpp 3.3.2
11453
11454 2003-10-31  Borut Razem <borut.razem AT siol.net>
11455
11456         * src/SDCC.lex: sdcc now understands both formats:
11457           '# <line_number> <file_name>' and
11458           '#line <line_number> <file_name>'
11459         * support/cpp2/cppmain.c: sdcpp now generates the standard
11460           '# <line_number> <file_name>' instead of former
11461           '#line <line_number> <file_name>'
11462
11463 2003-10-30  Borut Razem <borut.razem AT siol.net>
11464
11465         * support/cpp2/cpphash.h,
11466         * support/cpp2/cpplib.h
11467         * support/cpp2/cpplex.c,
11468         * support/cpp2/cppmain.c,
11469         * support/cpp2/cppinit.c: fixed bug #828015 - Syntax variation for _asm character constants
11470
11471 2003-10-30 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11472
11473         Fixed a number of problems revealed by bug #827883.
11474         * src/SDCCloop.c (loopInvariants): Spill location of the
11475         result operand should be recomputed if extracted from
11476         a loop. Also, don't extract assignments of an iTemp
11477         from a literal.
11478         * src/SDCCast.c (isConformingBody): loop reversal should
11479         not occur if the control variable is involved with a
11480         relational operator.
11481
11482 2003-10-28 Bernhard Held <bernhard AT bernhardheld.de>
11483
11484         * .version: bumped to 2.3.6 to reflect the big improvements
11485         made by Erik and Klaus. Thanks!
11486
11487 2003-10-28 Klaus Flittner <klaus_flittner AT gmx.de>
11488
11489         Replaced the livrange code.
11490         * src/SDCClrange.c: added new LR code
11491         * src/SDCCloop.c,
11492         * src/SDCCBBlock.h: removed remainig parts from old LR code
11493         * src/ds390/ralloc.c,
11494         * src/ds390/gen.c: minor fixes to make it work with new code
11495
11496 2003-10-28 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11497
11498         * as/hc08/asm.h,
11499         * as/hc08/lkrloc.c,
11500         * src/hc08/gen.c,
11501         * src/hc08/ralloc.c: Fix various warnings related to the hc08
11502         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec): Fixed bug #829717
11503         (tweaked fix for bug #818696)
11504
11505 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11506
11507         * src/z80/ralloc.c (joinPushes): Fixed bug #828742
11508
11509 2003-10-23 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11510
11511         * src/SDCCmain.c,
11512         * sdccconf_in.h: Fixed bug #828387 (--disable-hc08-port didn't work)
11513         * src/mcs51/gen.c (gencjneshort),
11514         * src/ds390/gen.c (gencjneshort): Made comparison with AOP_IMMD operand
11515         more efficient (per Scott Bronson's suggestion)
11516
11517 2003-10-22 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11518
11519         Extended the semantics of the critical keyword to include
11520         individual statements. See RFE #827755 and #799831
11521         * src/SDCC.y
11522         * src/SDCCicode.c
11523         * src/SDCCopt.c
11524         * src/SDCCast.c
11525         * support/Util/SDCCerr.c
11526         * support/Util/SDCCerr.h
11527         * src/mcs51/gen.c
11528         * src/ds390/gen.c
11529         * src/hc08/gen.c
11530
11531 2003-10-19  Borut Razem <borut.razem AT siol.net>
11532
11533         * src/SDCC.lex: fixed bug #825944 - defined yytext_ptr to make it compile with flex 2.5.31
11534
11535 2003-10-19 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11536
11537         * src/SDCCicode.c (geniCodePreInc, geniCodePreDec, ast2iCode):
11538         Fixed bug #818696
11539         * src/SDCCast.c (ast_print): Fixed --dumptree so that preincrement
11540         and predecrement operand is displayed
11541
11542 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
11543
11544         * src/SDCCval.c (valMinus): fixed bug #826041
11545
11546 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11547
11548         Some hc08 related updates that I missed earlier
11549         * sim/ucsim/stypes.h
11550         * support/regression/ports/hc08/spec.mk
11551
11552 2003-10-15 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11553
11554         New target "hc08" for the Motorola 68hc08 family of micros
11555
11556         * configure
11557         * configure.in
11558         * Makefile
11559         * src/hc08/*
11560         * src/SDCCmain.c
11561         * src/port.h
11562         * sim/ucsim/hc08.src/*
11563         * sim/ucsim/configure.in
11564         * src/ucsim/configure
11565         * sim/ucsim/packages_in.mk
11566         * as/hc08/*
11567         * as/Makefile
11568         * device/include/mc68hc908qy.h
11569         * device/lib/hc08/*
11570         * device/lib/Makefile.in
11571         * support/regression/ports/hc08/*
11572         * support/regression/Makefile
11573
11574 2003-10-14 Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11575
11576         * src/z80/gen.c: fixed bug revealed by ast_constant_folding.c
11577         regression test
11578         * src/ds390/gen.c (genCast): fixed bug #821957
11579
11580 2003-10-13 Bernhard Held <bernhard AT bernhardheld.de>
11581
11582         * device/lib/logf.c: "fixed" overlay bug
11583         * support/regression/ports/host/spec.mk: added m library
11584         * support/regression/ports/mcs51-stack-auto/spec.mk: added float funcs
11585         * support/regression/tests/float_trans: added (for Eric)
11586
11587 2003-10-12 Bernhard Held <bernhard AT bernhardheld.de>
11588
11589         * src/mcs51/gen.c (genCpl): fixed bug
11590         http://sf.net/mailarchive/message.php?msg_id=6263915
11591
11592 2003-10-10 Bernhard Held <bernhard AT bernhardheld.de>
11593
11594         * src/SDCCast.c (decorateType): added extended constant folding
11595         * src/SDCCsymt.c (computeType): cleanup
11596         * src/SDCCval.c (valShift): minor optimization
11597         * support/regression/tests/ast_constant_folding.c: added
11598
11599 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11600
11601         * src/SDCCmain.c: removed some unintended changes
11602
11603 2003-10-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11604
11605         * src/SDCCmain.c (setParseWithComma): fixed bug #816685
11606         * src/z80/gen.c: fixed part of bug #817589
11607         * src/SDCCsymt.c (checkFunction): fixed bug #817895
11608
11609 2003-10-08 Bernhard Held <bernhard AT bernhardheld.de>
11610
11611         Replaced cast (void **) with (void *) to avoid gcc 3 warning:
11612         * src/SDCCcflow.c
11613         * src/SDCCcse.c
11614         * src/SDCCdflow.c
11615         * src/SDCClabel.c
11616         * src/SDCClrange.c
11617         * src/SDCCmem.c
11618         * src/SDCCopt.c
11619         * src/SDCCpeeph.c
11620         * src/SDCCset.c
11621         * src/avr/ralloc.c
11622         * src/ds390/ralloc.c
11623         * src/izt/ralloc.c
11624         * src/mcs51/ralloc.c
11625         * src/pic/ralloc.c
11626         * src/pic16/ralloc.c
11627         * src/xa51/ralloc.c
11628         * src/z80/ralloc.c
11629         * src/z80/gen.c: removed unused label "release:"
11630
11631 2003-10-06  Borut Razem <borut.razem AT siol.net>
11632
11633         * src/SDCC.lex: removed definition of unused variables
11634           save_optimize and save_options
11635
11636 2003-10-06 Bernhard Held <bernhard AT bernhardheld.de>
11637
11638         * clean.mk: removed '=' in "-maxdepth=1"
11639         * src/SDCCloop.c: replace LRKLAUS with SDCC_LRKLAUS
11640         * src/SDCClrange.c: replace LRKLAUS with SDCC_LRKLAUS
11641
11642 2003-10-06  Borut Razem <borut.razem AT siol.net>
11643
11644         * src/SDCC.lex, src/SDCC.lex: use dbuf for "_asm" definitions;
11645           my_unput() replaced by unput()
11646
11647 2003-10-05 Bernhard Held <bernhard AT bernhardheld.de>
11648
11649         * src/SDCCloop.c (assignmentsToSym, loopInduction): cast argument of
11650         setToNull() to (void *) to avoid gcc3.x's warning: "dereferencing
11651         type-punned pointer will break strict-aliasing rules"
11652         Old LR behaviour is again default; Klaus' LR can be choosen by
11653         defining the environment variable LRKLAUS
11654         * src/SDCCBBlock.h
11655         * src/SDCCloop.c
11656         * src/SDCClrange.c
11657         * src/ds390/ralloc.c (spillThis): applied Klaus' patch
11658         * clean.mk: fixed removal of files in bin/CVS/
11659         * device/lib/clean.mk: fixed removal of directories small and large
11660         * support/Util/SDCCerr.c: changed W_INT_OVL to ERROR_LEVEL_PEDANTIC
11661         * src/SDCCicode.c,
11662         * src/SDCCval.c: removed superflous test for pedantic
11663
11664 2003-10-05  Borut Razem <borut.razem AT siol.net>
11665
11666         * src/SDCC.lex, support/Util/SDCCerr.c, sdcc/support/Util/SDCCerr.h:
11667           Fixed bug #816692: introduced new ERROR_LEVEL_PEDANTIC warning
11668           message "unmatched #pragma SAVE and #pragma RESTORE"
11669
11670 2003-10-04  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11671
11672         * doc/sdccman.lyx: various additions and updates (interrupts, inline
11673           assembly, critical functions, atomic, nojtbound)
11674
11675 2003-10-04 Bernhard Held <bernhard AT bernhardheld.de>
11676
11677         Applied liferange patch from Klaus Flittner <klaus_flittner AT gmx.de>
11678         * src/SDCCBBlock.h
11679         * src/SDCCloop.c
11680         * src/SDCCloop.h
11681         * src/SDCClrange.c
11682
11683 2003-10-03  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11684
11685         * src/z80/gen.h,
11686         * src/z80/gen.c (aopOp, aopGet, aopPut, genDummyRead),
11687         * src/mcs51/gen.h
11688         * src/mcs51/gen.c (aopOp, aopGet, aopPut, genDummyRead),
11689         * src/ds390/gen.h
11690         * src/ds390/gen.c (aopOp, aopGet, aopPut, genDummyRead),
11691         * src/SDCCicode.c (ast2iCode, geniCodeDummyRead): Fixed bug #663539
11692         * src/SDCCopt.c (killDeadCode): Fixed bugs #663539 & #816705
11693
11694 2003-10-02  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11695
11696         * src/z80/gen.c (genRet): fixed bug #524753
11697         * src/z80/gen.c (genCast): fixed internal error on cast from
11698         pointer to long
11699         * src/z80/gen.c (_saveRegsForCall, emitCall): adapted Johan's
11700         fix for bug #477835 to the z80
11701         * src/z80/gen.c (genZ80code, _vemit2, _emit2): added support
11702         for tracking iCodes in the peephole optimizer for z80
11703
11704 2003-10-01  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11705
11706         * src/SDCCicode.c (geniCodeJumpTable, geniCodeSwitch): fixed
11707         the other part of bug #814548
11708         * src/SDCCpeeph.c (labelInRange): fixed bug #814558
11709
11710 2003-09-30  Bernhard Held <bernhard AT bernhardheld.de>
11711
11712         * src/SDCCcse.c: fixed part of bug #814548
11713
11714 2003-09-28  Borut Razem <borut.razem AT siol.net>
11715
11716         * src/asm.c: rewrite of printILine() to use temporary file instead
11717           a pipe
11718         * src/xa51/main.c: commented out declaration of int rewinds
11719
11720 2003-09-27  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11721
11722         * src/SDCCicode.c (geniCodeJumpTable): Fixed bug #813206
11723
11724 2003-09-26  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11725
11726         * src/SDCCdflow.c (computeDataFlow): Fixed bug #810746
11727         * src/asm.c (printILine): Fixed bug #811015
11728
11729 2003-09-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11730
11731         *link/z80/lklibr.c, as/mcs51/lklibr.c: Improved memory allocation and
11732         freeing.
11733
11734 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11735
11736         * src/z80/gen.c (setupToPreserveCarry): Fixed bug #796955
11737         * src/z80/gen.c (setupPair, genMovePairPair): Fixed setupPair
11738         to correctly handle general case of AOP_PAIRPTR
11739         * src/z80/gen.c (aopGet, aopPut): Generalized AOP_PAIRPTR handling
11740
11741 2003-09-21  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11742
11743         * src/mcs51/ralloc.c (fillGaps),
11744         * src/ds390/ralloc.c (fillGaps): fixed bug #810093 (yet another
11745         register positioning bug)
11746
11747 2003-09-21  Bernhard Held <bernhard AT bernhardheld.de>
11748
11749         * device/lib/_fsdiv.c: replaced (1<<31) by (1ul<<31)
11750
11751 2003-09-19  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11752
11753         * src/mcs51/gen.c (loadDptrFromOperand, genFarPointerGet,
11754         genCodePointerGet, genGenPointerGet, genFarPointerSet,
11755         genGenPointerSet): handle AOP_DPTR correctly when loading dptr
11756         (ralloc doesn't intentionally do this now, but perhaps later)
11757         * src/mcs51/ralloc.c (serialRegAssign, fillGaps),
11758         * src/ds390/ralloc.c (serialRegAssign, fillGaps): fixed some
11759         register positioning bugs (Fixed bug #762602 and #795325)
11760         * src/SDCCicode.c (geniCodeDerefPtr): Track output class correctly
11761         (Fixed bug #808779)
11762         * src/z80/gen.c: increased _vemit2's buffer[] to handle long
11763         lines that --i-code-in-asm generates
11764
11765 2003-09-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11766
11767         *link/z80/lklibr.c, as/mcs51/lklibr.c: Fixed Linux segfaults when
11768         trying to fclose a FILE* that was already closed.
11769
11770 2003-09-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11771
11772         * src/SDCCsymt.c (structElemType): fixed bug #808291 (members
11773         of const struct should be treated as if const themselves)
11774
11775 2003-09-18  Bernhard Held <bernhard AT bernhardheld.de>
11776
11777         * src/SDCCval.c (valPlus, valMinus): fixed bug #808337
11778
11779 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11780
11781         * support/librarian/sdcclib.c: Generate correct offsets for libraries with
11782         Unix (/n) and DOS (/r/n) line terminations.
11783
11784 2003-09-17  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11785
11786         * src/SDCCopt.c (cnvFromFloatCast, cnvToFloatCast): fixed
11787         bug #613775
11788
11789 2003-09-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11790
11791         * src/mcs51/gen.c (genFunction, genEndFunction),
11792         * src/ds390/gen.c (genFunction, genEndFunction): Moved save
11793         and restore of EA so that stack offsets to parameters are
11794         correct when using both critical and reentrant/stack-auto.
11795         * src/z80/gen.c (aopOp): removed erroneous assertion about sloc
11796         size (can be triggered in error if sloc is shared between
11797         different sized objects)
11798         * device/include/float.h: fixed macros to explicitly use
11799         unsigned long where needed
11800
11801 2003-09-15  Bernhard Held <bernhard AT bernhardheld.de>
11802
11803         Feature req. 799831: added code to allow nesting of critical functions
11804         * src/mcs51/gen.c (genFunction, genEndFunction)
11805         * src/ds390/gen.c (genFunction, genEndFunction)
11806
11807 2003-09-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11808
11809         * src/SDCCsymt.c (sclsFromPtr),
11810         * src/SDCCsymt.h,
11811         * src/SDCCast.c (decorateType): fixed bug #462971. Also, better
11812         support for standard C idiom of memory mapped variables; for
11813         example, *((xdata int*)0x1234) = 1 is now internally equivalent
11814         to xdata int at 0x1234 tempvar = 1.
11815         * sim/ucsim/z80.src/inst_xd.cc: fixed bug #805483 with patch
11816         provided by Akiya ISHIDA
11817
11818 2003-09-13  Bernhard Held <bernhard AT bernhardheld.de>
11819
11820         * src/SDCCval.c (cheapestVal): reenabled to reduce int to char
11821         * src/SDCCval.c (constVal): added reduction from int to char
11822         * src/SDCCval.c (valMult, valDiv): fixed sign handling
11823         * src/SDCCval.c (valShift): fixed after change of cheapestVal()
11824         * src/SDCCval.c (valCompare): fixed EQ_OP and NE_OP; they have
11825         to ignore the sign
11826         * support/regression/tests/shifts.c: fixed
11827
11828 2003-09-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11829
11830         * src/z80/gen.c (genXor): Fixed bug #805445
11831
11832 2003-09-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11833
11834         Fixed bug #621531 (const & volatile confusion in the type chain).
11835         DCL_PTR_CONST, DCL_PTR_VOLATILE, & IS_PTR_CONST now exclusively
11836         refer to the const or volatile state of the pointer itself.
11837
11838         * src/SDCCast.c
11839         * src/SDCCglue.c
11840         * src/SDCCicode.c
11841         * src/SDCCsymt.c
11842         * src/SDCCval.c
11843         * src/SDCC.y
11844         * src/SDCCsymt.h
11845         * src/pic/gen.c
11846         * src/pic/ralloc.c
11847         * src/pic16/gen.c
11848         * src/pic16/ralloc.c
11849         * support/regression/tests/const.c
11850
11851 2003-09-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11852
11853         When checking for duplicated modules, use absolute paths
11854         instead of relative paths.  Files changed:
11855
11856         * as/mcs51/lklib.c
11857         * link/z80/lklib.c
11858
11859 2003-09-09  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11860
11861         * src/SDCCicode.c (geniCodeLogic): fixed bug #797572
11862
11863 2003-09-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11864
11865         * device/include/string.h: added size_t typedef, changed
11866         prototypes to use size_t, eliminated separate reentrant and
11867         non-reentrant declarations, added _memmove declaration
11868         * device/lib/_memcpy.c: changed to use size_t instead of int,
11869         changed /4 to >>2 to avoid division library call
11870         * device/lib/_memcmp.c,
11871         * device/lib/_memset.c,
11872         * device/lib/_strncat.c,
11873         * device/lib/_strncpy.c,
11874         * device/lib/_strncmp.c: changed to use size_t instead of int
11875         * device/lib/_memmove.c: new file (fixed bug #772294)
11876         * device/lib/Makefile.in: added _memmove.c
11877         * device/lib/z80/asm_strings.s: fixed bug #772290
11878         * support/regression/tests/bitfields.c: attempt to fix host assertion
11879         failure on amd64-unknown-linux2.2
11880
11881 2003-09-06  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11882
11883         * src/z80/gen.c (aopPut, spillPairReg): fixed bug #800998
11884         * src/z80/gen.c (genFunction, genEndFunction): fixed "bug" #774700
11885         * as/z80/asmain.c (main): fixed bug #801766
11886
11887 2003-09-06  Bernhard Held <bernhard AT bernhardheld.de>
11888
11889         * src/SDCCicode.c (ast2iCode): fixed differences in iCode with different
11890         compilers
11891
11892 2003-09-05  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11893
11894         * src/SDCCast.c (isConformingBody): fixed loop reversal bug
11895         reported in bug #800609
11896
11897 2003-09-04  Vangelis Rokas <vrokas AT otenet.gr>
11898
11899         * Top header beautifications in src/pic16 directory:
11900           device.c, device.h, gen.c, gen.h, genarith.c, glue.c, pcode.c,
11901           pcodeflow.c, pcodeflow.h, pcode.h, pcodepeep.c, pcoderegs.c,
11902           pcoderegs.h, ralloc.c, ralloc.h
11903         * main.c: added top header and GPL license notice
11904         * pcode.c: fixed the if-conditional warning
11905
11906 2003-09-04  Bernhard Held <bernhard AT bernhardheld.de>
11907
11908         * device/lib/_mullong.c: replaced int by short for gcc
11909
11910 2003-08-31  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11911
11912         * src/SDCCpeeph.c (notVolatile, notVolatileVariable): handle IFX
11913         and JUMPTABLE iCodes properly now (worked by accident before)
11914         * src/mcs51/gen.c (leftRightUseAcc),
11915         * src/ds390/gen.c (leftRightUseAcc): handle IFX and JUMPTABLE
11916         iCode properly now. Use getSize instead of nRegs since a & b
11917         aren't part of the nRegs tally.
11918
11919 2003-08-31  Vangelis Rokas <vrokas AT otenet.gr>
11920
11921         * src/pic16/main.c: corrected offsets of interrupt vectors in _pic16_genIVT()
11922         * src/pic16/pcode.c: fix to disable inserting BANKSEL directive
11923           before instructions that use the _STATUS register
11924
11925 2003-08-31  Bernhard Held <bernhard AT bernhardheld.de>
11926
11927         * src/mcs51/gen.c (freeAsmop): fixed off by one in stack offset (AOP_STK)
11928         * src/mcs51/gen.c (genNearPointerSet): added missing opcode for
11929         fetching of the pointer
11930         * src/mcs51/gen.c (genNearPointerGet): added reuse of PREG,
11931         copied from genNearPointerSet()
11932         * src/mcs51/gen.c (genNearPointerGet): don't pop r0/r1, if RESULTONSTACK
11933         * src/mcs51/gen.c: changed order of freeAsmop(left/right/result)-calls.
11934         If they pop r0/r1 they must be called in the opposite order than aopOp().
11935         * device/lib/_mullong.c: fixed for "--model-large --int-long-reent"
11936         (resp. --stack-auto), prepared for --xstack
11937
11938 2003-08-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11939
11940         * doc/sdccman.lyx: reverted tables to those in cvs 1.64
11941
11942 2003-08-28  Bernhard Held <bernhard AT bernhardheld.de>
11943
11944         * device/lib/_startup.c: quick & dirty fix for ds390/ds400;
11945         these ports have their own __sdcc_external_start()
11946
11947 2003-08-26  Bernhard Held <bernhard AT bernhardheld.de>
11948
11949         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
11950         * src/pic/glue.c (pic14printPublics): fixed bug introduced when symbol
11951         type for bits was changed. It resulted in bit variables becoming
11952         global, which is not permitted in PIC 14 assembly output.
11953
11954 2003-08-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
11955
11956         * doc/sdccman.lyx: various additions and updates. Rearranged sections
11957
11958 2003-08-22  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
11959
11960         Z80 and MCS51 linkers complaint if a public symbol is defined
11961         in more than one library module:
11962
11963         * as/mcs51/lklib.c
11964         * link/z80/lklib.c
11965         * as/mcs51/Makefile.in
11966
11967 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11968
11969         A few small changes that speed up the peephole optimizer.
11970
11971         * src/SDCCpeeph.c
11972
11973 2003-08-22  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11974
11975         Try to make the peephole optimizer smarter by maintaining
11976         an association between the assembly source code and the
11977         iCodes that originated them. Put this information to use
11978         with a new peephole rule condition "notVolatile" so that
11979         the rules can be aggressive yet still safe.
11980
11981         * src/SDCCpeeph.c
11982         * src/SDCCpeeph.h
11983         * src/mcs51/gen.c
11984         * src/mcs51/peeph.def
11985
11986 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11987
11988         Fixed bug #741761
11989
11990         * src/mcs51/gen.c (aopForSym, leftRightUseAcc),
11991         * src/ds390/gen.c (aopForSym, leftRightUseAcc): preserve A and B
11992         if the left or right operand symbols have the accuse flag set.
11993
11994 2003-08-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
11995
11996         Changed the type of the result of the ! (NOT) operator to char;
11997         previously it returned the same type as the source. This allows
11998         us to eliminate all the genFloatNot functions (all of its target
11999         implementations were very buggy) since !float can use the same
12000         code as !long now.
12001
12002         * src/SDCCicode.c (ast2iCode): ! returns char
12003         * src/mcs51/gen.c (genNot, genNotFloat),
12004         * src/ds390/gen.c (genNot, genNotFloat),
12005         * src/z80/gen.c (genNot, genNotFloat),
12006         * src/pic/gen.c (genNot, genNotFloat),
12007         * src/pic16/gen.c (genNot, genNotFloat): eliminated genNotFloat
12008
12009 2003-08-19  Bernhard Held <bernhard AT bernhardheld.de>
12010
12011         pic patch provided by Slade Rich <slade_rich AT yahoo.com>
12012         1. Interrupt would not compile properly. Ensure PCLATH register is saved
12013            during interrupts. Ensure WSAVE is located at a shared bank address.
12014         2. Fixed page selection in some places
12015         3. Fixed BTFSS/C to where necessary use registers directly and not simply
12016            the registers name strings.
12017         4. Fixed "signed / unsigned compare" compiler warnings.
12018         5. The PIC port manages its own allocation of the general purpose
12019            registers, but makes no attempt to reuse them. As a result when
12020            compiling it soon runs out of general purpose registers. Some
12021            additional code was added to the files pcode.c and device.c to walk
12022            through the function call tree and rename the registers so that they
12023            get reused.
12024
12025         * src/pic/device.c
12026         * src/pic/gen.c
12027         * src/pic/glue.c
12028         * src/pic/pcode.c
12029         * src/pic/pcode.h
12030         * src/pic/ralloc.c
12031         * src/pic/ralloc.h
12032         * src/pic/genarith.c: Fixed problems with PIC 14 port in functions
12033         genPlus() & genMinus() when the result is the same as left or right
12034
12035 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12036
12037         * src/z80/gen.c (isUnsplitable, fetchPairLong): fixed bug #770454
12038
12039 2003-08-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12040
12041         Made bitfield a distinct type from bit so that bitfields
12042         convert as per ANSI C and bits retain their traditional
12043         boolean style behaviour. Implemented bitfield support in
12044         the z80 port.
12045
12046         * src/SDCCsymt.h,
12047         * src/SDCCsymt.c,
12048         * src/SDCCast.c,
12049         * src/cdbFile.c,
12050         * src/mcs51/gen.c,
12051         * src/ds390/gen.c: bit v bitfield split
12052         * src/z80/gen.c: New support for bitfields
12053         * support/regression/tests/bitfields.c: reenabled z80,
12054         added more tests
12055
12056 2003-08-17  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12057
12058         Rules 246.x, 247.x relate to bitfields, the others speed up
12059         access to xdata mapped I/O devices.
12060
12061         * src/mcs51/peeph.def: added 26 peepholes 246.x - 248.x, 180.x
12062
12063 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12064
12065         Cleaned up genPackBits and genUnpackBits and added two helper
12066         functions, emitPtrByteGet & emitPtrByteSet. Added optimizations
12067         for literal assignments in genPackBits (thanks to Frieder for
12068         reminding me).
12069
12070         * src/mcs51/gen.c
12071         * src/ds390/gen.c
12072
12073 2003-08-16  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12074
12075         Fixed bug #748310 (pointer to function type mishandled when the
12076         function name is omitted). Also fixed a SIGSEGV when a function
12077         attribute (reentrant, etc) is used on a non-function or on a
12078         function but misplaced before the parameter list.
12079
12080         * src/SDCC.y (abstract_declarator, abstract_declaractor2): fixed
12081         bug #748310
12082         * src/SDCC.y (declarator2_function_attributes): avoided SIGSEGV
12083         * support/Util/SDCCerr.h,
12084         * support/Util/SDCCerr.c: Added func attr misuse error msg
12085
12086 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
12087
12088         Fixed bug #787649 by anonymous
12089         * src/SDCCglue.c (emitRegularMap): added emission of sloc for func ptr
12090         * src/ds390/gen.c (aopForSym): fixed func ptr in sloc
12091
12092 2003-08-14  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12093
12094         Fixed numerous bitfield problems.
12095
12096         * src/SDCC.y: More bitfield related error checking
12097         * src/SDCCsymt.h,
12098         * src/SDCCsymt.c (compStructSize): fixed bitfield offset calc
12099         * support/Util/SDCCerr.h,
12100         * support/Util/SDCCerr.c: Added & edited some bitfield err msgs
12101         * src/mcs51/gen.c (genPackBits, genUnpackBits): fixed mask bugs
12102         * src/ds390/gen.c (genPackBits, genUnpackBits): fixed mask bugs
12103         * support/regression/tests/bitfields.c: tests added
12104
12105 2003-08-13  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12106
12107         Made the constant following the "interrupt" keyword optional. If
12108         omitted, the function will not automatically be given an entry
12109         in the interrupt vector table (similar to #pragma NOIV, but
12110         less syntacticly kludgy). The interrupt number is also now
12111         range checked. Also fixed a bug in the high order bit example
12112         in the manual.
12113
12114         * src/SDCC.y
12115         * src/SDCCmem.c
12116         * src/SDCCglue.c
12117         * src/SDCCsymt.h
12118         * support/Util/SDCCerr.c
12119         * support/Util/SDCCerr.h
12120         * doc/sdccman.lyx
12121
12122 2003-08-13  Bernhard Held <bernhard AT bernhardheld.de>
12123
12124         * src/SDCCcse.c (algebraicOpts): fix bug converting op from value to type
12125         * src/SDCCicode.c (operandOperation): rewritten some ops
12126         (*, ==, unary_minus) to fix possible overflows and to accord with ANSI
12127         * src/SDCCsymt.c (computeType): literals are handled the same way as any
12128         other type
12129         * src/SDCCval.c (cheapestVal): removed, it doesn't accord with ANSI (can
12130         be re-activated by defining REDUCE_LITERALS)
12131         * src/SDCCval.c (constVal): fixed; hex and octal constants can be
12132         unsigned, but are signed by default
12133         * src/SDCCval.c (constVal): rearranged
12134         * src/SDCCval.c (valMod): preliminary fix
12135         * src/SDCCval.c (valCastLiteral): use TYPE_* types
12136         * support/regression/literalop.c: added, work in progress
12137
12138 2003-08-12  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12139
12140         Generate warnings for useless declarations like "char data;"
12141         that don't do what new users expect.
12142
12143         * src/SDCC.y
12144         * support/Util/SDCCerr.h
12145         * support/Util/SDCCerr.c
12146
12147 2003-08-09  Bernhard Held <bernhard AT bernhardheld.de>
12148
12149         * src/SDCCval.c (valMult): fix overflow detection of negative int
12150
12151 2003-08-07  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12152
12153         * src/z80/ralloc.c (joinPushes): made compatible with new signedness
12154
12155         Changes to support big endian targets:
12156
12157         * src/ports.h
12158         * src/SDCCglue.c
12159         * src/avr/main.c
12160         * src/ds390/main.c
12161         * src/izt/i186.c
12162         * src/mcs51/main.c
12163         * src/pic/main.c
12164         * src/pic16/main.c
12165         * src/xa51/main.c
12166         * src/z80/main.c
12167
12168 2003-08-06  Bernhard Held <bernhard AT bernhardheld.de>
12169
12170         * src/SDCCval.c (cheapestVal): changed behaviour to the same as constVal()
12171         * device/lib/time.c: fixed warning "integer overflow in expression"
12172
12173 2003-08-05  Bernhard Held <bernhard AT bernhardheld.de>
12174
12175         * src/SDCCval.c (cheapestVal, valueFromLit): use TYPE_* types
12176         * src/SDCCval.c (constVal): changed default to signed; hex and octal
12177         constants are unsigned; added recognition of "u" flag for unsigned
12178         * src/SDCCval.c (valMult): fixed signdness, added warning for overflow
12179         * src/SDCCval.c (valDiv, valMod): fixed signdness
12180         * src/SDCCicode.c (operandOperation): fixed critical typo; fixed
12181         signedness of modulo, left and right shift
12182         * support/Util/SDCCerr.c: added warning "integer overflow in expression"
12183         * support/Util/SDCCerr.h: added warning W_INT_OVL
12184         * src/SDCCast.c (decorateType): fixed gcc3.3 warning
12185         * src/SDCCast.c (ast_print): improved output of constants
12186
12187 2003-08-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12188
12189         Fixed some warnings when building with MSVC:
12190
12191         * as/mcs51/asdata.c
12192         * as/z80/asdata.c
12193         * as/mcs51/asm.h
12194         * as/z80/asm.h
12195         * link/z80/aslink.h
12196         * link/z80/lkdata.c
12197         * link/z80/lkeval.c
12198         * link/z80/lkgb.c
12199         * link/z80/lkihx.c
12200         * link/z80/lks19.c
12201         * link/z80/lksym.c
12202         * support/cpp2/cpplib.c
12203         * src/ds390/gen.c
12204         * src/mcs51/gen.c
12205
12206 2003-08-03  Bernhard Held <bernhard AT bernhardheld.de>
12207
12208         * src/SDCCast.c (constExprTree): fix bug #781827 by Carl Worth <cworth AT isi.edu>
12209
12210 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12211
12212         * support/librarian/clean.mk: Do not remove Makefile.
12213         * support/librarian/Makefile: added.
12214
12215 2003-08-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12216
12217         Added librarian to MSVC build:
12218         * all.dsp
12219         * sdcc.dsw
12220         * support/librarian/librarian.dsp
12221
12222         'configure' not needed for librarian, removed:
12223         * support/librarian/configure
12224         * support/librarian/configure.in
12225         * support/librarian/config_in.h
12226         * support/librarian/Makefile.in
12227
12228         Hopefully these ones built the librarian and the rest of sdcc properly:
12229         * Makefile
12230         * Makefile.common.in
12231
12232         Messed up 'configure', so revert to previous version:
12233         * configure
12234         * configure.in
12235
12236 2003-07-31  Bernhard Held <bernhard AT bernhardheld.de>
12237
12238         * src/SDCCicode.c (operandOperation): 3. fix, this time for Alpha; ULONG has 64 bits
12239         there, while the mantissa of a double is "only" 53 bits wide.
12240
12241 2003-07-31  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12242
12243         Adding sdcclib to the build.  MSVC project coming soon.
12244         Files added/changed:
12245
12246         * support/librarian/clean.mk
12247         * support/librarian/configure
12248         * support/librarian/configure.in
12249         * support/librarian/config_in.h
12250         * support/librarian/Makefile.bcc
12251         * support/librarian/Makefile.in
12252         * support/librarian/sdcclib.c
12253         * Makefile.bcc
12254         * Makefile
12255         * Makefile.common.in
12256         * configure
12257         * configure.in
12258
12259 2003-07-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12260
12261         Linker now complaints if linked modules have conflicting options, for
12262         example, one compiled using --model-large and another one compiled with
12263         --model-small.  The following files were modified:
12264
12265         * as/mcs51/asdata.c
12266         * as/mcs51/aslink.h
12267         * as/mcs51/asm.h
12268         * as/mcs51/asmain.c
12269         * as/mcs51/asout.c
12270         * as/mcs51/i51pst.c
12271         * as/mcs51/lkdata.c
12272         * as/mcs51/lklibr.c
12273         * as/mcs51/lkmain.c
12274         * as/z80/asdata.c
12275         * as/z80/asm.h
12276         * as/z80/asmain.c
12277         * as/z80/asout.c
12278         * as/z80/z80pst.c
12279         * link/z80/aslink.h
12280         * link/z80/lkdata.c
12281         * link/z80/lklibr.c
12282         * link/z80/lkmain.c
12283         * src/SDCCglue.c
12284
12285 2003-07-28  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12286
12287         *link/z80/aslink.h, link/z80/lklibr.c, as/mcs51/aslink.h,
12288         as/mcs51/lklibr.c: Generate a warning when a library is not found.
12289
12290 2003-07-28  Bernhard Held <bernhard AT bernhardheld.de>
12291
12292         * src/z80/mappings.i: fix _mul[us][int,long] entries
12293
12294 2003-07-26  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12295
12296         *src/SDCCmain.c: do not search for crt0.o when using --nostdlib
12297
12298 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
12299
12300         * src/SDCCicode.c (operandOperation): really fixed problem with bitops
12301         * support/regression/tests/bitopcse.c: added
12302         fixed warning:
12303         * src/avr/gen.c:
12304         * src/pic/gen.c:
12305         * src/pic16/gen.c:
12306         * src/z80/gen.c:
12307         * src/xa51/gen.c:
12308
12309 2003-07-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12310
12311         added support for new library format to z80, gbz80 linkers:
12312         *link/z80/aslink.h
12313         *link/z80/lklex.c
12314         *link/z80/lklib.c
12315         *link/z80/lklist.c
12316
12317 2003-07-24  Bernhard Held <bernhard AT bernhardheld.de>
12318
12319         * src/SDCCicode.c (operandOperation): fixed problem with bitops and 0xffffffff;
12320         after {double d = 0xffffffff; long l = d;} l will be 0x80000000 (LONG_MIN)
12321
12322 2003-07-23  Bernhard Held <bernhard AT bernhardheld.de>
12323
12324         added DUMMY_READ_VOLATILE:
12325         * src/SDCC.y:
12326         * src/avr/gen.c:
12327         * src/xa51/gen.c:
12328         * src/z80/gen.c:
12329         * src/pic/gen.c:
12330         * src/pic16/gen.c:
12331         * src/mcs51/gen.c:
12332         * src/ds390/gen.c:
12333         * src/SDCCcse.c (algebraicOpts): many improvements
12334         * src/SDCCcse.h: removed algebraicOpts()
12335         * src/SDCCicode.c (picDummyRead): added
12336
12337 2003-07-23  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12338
12339         * as/mcs51/lkmem.c: Changed message "Insufficient DRAM memory" to
12340         "Insufficient space in data memory".
12341
12342 2003-07-20  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12343
12344         * src/mcs51/gen.c: fixed bug #771358
12345         * src/z80/gen.c: fixed bug #759087
12346
12347 2003-07-20  Bernhard Held <bernhard AT bernhardheld.de>
12348
12349         * src/pic16/glue.c: minor cleanup by Vangelis
12350
12351 2003-07-19  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12352
12353         * device/include/regc515c.h: fixed #758477
12354         * device/lib/_gptrget.c: saving some cycles in generic pointer get
12355         * device/lib/_gptrput.c: saved a few bytes
12356         * my tab spacing is 8, yours too?)
12357         * device/lib/_ser.c: process RX bytes earlier than TX bytes
12358         * device/lib/serial.c: process RX bytes earlier than TX bytes
12359         * src/mcs51/gen.c(genGenPointerGet/Set): removed writing of type after postincrement
12360
12361 2003-07-18  Erik Petrich <epetrich AT ivorytower.norman.ok.us>
12362
12363         * src/z80/gen.c: fixed some right shift bugs (#772726 among them)
12364
12365 2003-07-17  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12366
12367     * link/z80/lklibr.c: fixed bug when there is a '.' in a library path.
12368
12369 2003-07-17  Bernhard Held <bernhard AT bernhardheld.de>
12370
12371         * device/lib/Makefile.in: bad fix, reverted to 1.43
12372
12373 2003-07-16  Bernhard Held <bernhard AT bernhardheld.de>
12374
12375         * device/lib/Makefile.in: added missing z80 object files
12376
12377 2003-07-14  Bernhard Held <bernhard AT bernhardheld.de>
12378
12379         * src/SDCCcse.c (algebraicOpts): CSE fun with &|^ and 0x00/0xff literals
12380         pic16 progress by Vangelis:
12381         * src/SDCCglobl.h:
12382         * src/SDCCmain.c:
12383         * src/pic/Makefile:
12384         * src/pic:
12385         * pic/Makefile:
12386         * pic16/device.c:
12387         * pic16/device.h:
12388         * pic16/gen.c:
12389         * pic16/gen.h:
12390         * pic16/genarith.c:
12391         * pic16/glue.c:
12392         * pic16/main.c:
12393         * pic16/pcode.c:
12394         * pic16/pcode.h:
12395         * pic16/pcodepeep.c:
12396         * pic16/peeph.def:
12397
12398 2003-07-13  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12399
12400     * src/SDCCmain.c, src/SDCCglobl.h: added option --no-std-crt0
12401
12402 2003-07-12  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12403
12404     * sdcc.dsw, all.dsp, link/z80/linkgbz80.dsp, as/z80/as-gbz80.dsp:
12405     added gbz80 build to MSVC project.
12406     * src/SDCCmain.c, src/SDCCglue.c, src/z80/main.c, src/z80/z80.dsp,
12407     link/z80/aslink.h, linkz80.dsp: cleaned up z80 and gbz80 asm files
12408     from 8051 stuff and setup so it links using a .lnk file.
12409
12410 2003-07-06  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12411
12412     * support/librarian/sdcclib.c: sdcc librarian.
12413     * as/mcs51/aslink.h, as/mcs51/lklib.c: Support for libraries created
12414     with sdcclib.
12415
12416 2003-07-03  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12417
12418     * as/mcs51/lkmain.c: properly handle extensions in function afile.
12419
12420 2003-07-02  Borut Razem <borut.razem AT siol.net>
12421
12422         * src/port.h, src/SDCCmain.c, src/pic/glue.h, src/pic/main.c,
12423         src/pic16/glue.h, sdcc/src/pic16/main.c, src/izt/i186.c,
12424         src/izt/tlcs900h.c, src/avr/main.c, src/ds390/main.c, src/mcs51/main.c,
12425         src/xa51/main.c, src/z80/main.c:
12426         virtualization of glue() function: each port has it's own glue function,
12427         which is accessed by do_glue function pointer in PORT.general structure
12428
12429 2003-07-01 Kevin Vigor <kevin AT vigor.nu>
12430
12431         * DS800C400 fun, improved ROM interface and tinibios.
12432
12433 2003-06-27 Kevin Vigor <kevin AT vigor.nu>
12434
12435         * More support for DS80C400. Now includes beginning of interface to ROM.
12436
12437 2003-06-25  Bernhard Held <bernhard AT bernhardheld.de>
12438
12439         * src/mcs51/gen.c (gencjneshort): fixed bug #760345
12440
12441 2003-06-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12442
12443         * as/mcs51/lkaomf51.c: Make sure the size of the last procedure is correct.
12444
12445 2003-06-19  Borut Razem <borut.razem AT siol.net>
12446
12447         * src/z80/main.c: fixed Z80 port again: missing -k library paths in linker command line
12448
12449 2003-06-19  Borut Razem <borut.razem AT siol.net>
12450
12451         * src/SDCCutil.h, src/SDCCutil.c, src/SDCCglobl.h, src/SDCCmain.c, src/z80/main.c:
12452         fixed Z80 port - crt0.o: cannot open.
12453
12454 2003-06-19  Bernhard Held <bernhard AT bernhardheld.de>
12455
12456         * support/Util/MySystem.c (merge_command): revert bad fix
12457
12458 2003-06-18  Borut Razem <borut.razem AT siol.net>
12459
12460         * src/SDCC.lex, src/SDCCmain.c: fixed some warnings, introduced with changes made 15.06.1003
12461
12462 2003-06-18  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12463
12464         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
12465         option --use-stdout sends errors to stdout instead of stderr.
12466
12467 2003-06-18  Bernhard Held <bernhard AT bernhardheld.de>
12468
12469         * support/Util/MySystem.c (merge_command): quick fix for Linux segfault with \"cmd\" arg
12470
12471 2003-06-15  Borut Razem <borut.razem AT siol.net>
12472
12473         * support/cpp2/sdcc.h: HAVE_DOS_BASED_FILE_SYSTEM defined for _WIN32
12474         * src/SDCC.lex: cloneXxx and copyAndFreeXxx functions for options and optimize stack handling
12475         * src/SDCCglobl.h, src/SDCCmain.c, src/ds390/main.c, src/mcs51/main.c, src/z80/main.c:
12476         fixed width array of pointers replaced with sets;
12477         multiple include and lib paths ared transferred to preprocessor and linker
12478         * src/SDCCset.c, src/SDCCset.h: added function setFromSetNonRev() and mergeSets()
12479         * src/SDCCsymt.c: reimplemented function inCalleeSaveList() by using sets instead
12480         fixed width array of pointers
12481         * src/SDCCutil.c, src/SDCCutil.h: added functions fputStrSet(), appendStrSet(), joinStrSet();
12482         removed functions addToList(), join(), joinn(), pathCharsEquivalent(), pathCharTransform(),
12483         fixupPath(), getPathDifference()
12484         * src/ds390/gen.c, src/mcs51/gen.c: reimplemented function  inExcludeList() by using sets instead
12485         fixed width array of pointers
12486
12487 2003-06-11  Bernhard Held <bernhard AT bernhardheld.de>
12488
12489         * src/pic16/ralloc.c: fix warnings
12490         * src/pic16/pcode.c: fix warning
12491
12492 2003-06-10  Scott Dattalo  <scott AT dattalo.com>
12493
12494          Scott D. for Vangelis Rokas (vrokas AT otenet.gr). I (scott) don't
12495         know all the details, but essentially this set of changes enable
12496         the pic16 port to generate movff instructions and generate assembler
12497         directives,
12498         * src/SDCCmain.c:
12499         * src/pic16/gen.c:
12500         * src/pic16/glue.c:
12501         * src/pic16/pcode.c:
12502         * src/pic16/device.c:
12503         * src/pic16/main.c:
12504         * src/pic16/pcode.h:
12505         * src/pic16/pcoderegs.c:
12506         * src/pic16/ralloc.c:
12507         * src/pic16/ralloc.h:
12508
12509 2003-06-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12510
12511         * support/Util/SDCCerr.c, src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx:
12512         added option --vc, so sdcc errors and warnings are compatible with
12513         Microsoft Visual Studio.
12514
12515 2003-06-07  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12516
12517         * device/lib/_atof.c, device/lib/Makefile.in, device/include/stdlib.h,
12518           device/lib/libfloat.lib: added atof function.
12519
12520 2003-06-04  Bernhard Held <bernhard AT bernhardheld.de>
12521
12522         * doc/sdccman.lyx: updated to Lyx 1.3
12523         * doc/cdbfileformat.lyx: updated to Lyx 1.3
12524         * doc/test_suite_spec.lyx: updated to Lyx 1.3
12525         * doc/Makefile: added fix for the \tabularnewline problem, thanks to Jesus
12526
12527 2003-06-03  Bernhard Held <bernhard AT bernhardheld.de>
12528
12529         * src/SDCCpeeph.c: separate peepRules2pCode() for pic16 by "Vangelis Rokas" <vrokas AT otenet.gr>
12530
12531 2003-06-02  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12532
12533         * doc/sdccman.lyx: cvs revision keywords, passing pdf information in latex preamble,
12534           additions to the "related tools/documentation" section
12535
12536 2003-06-02  Bernhard Held <bernhard AT bernhardheld.de>
12537
12538         * src/SDCCglue.c (tempfileandname): added check for missing TMP/TEMP/TMPDIR variable
12539
12540 2003-05-29  Bernhard Held <bernhard AT bernhardheld.de>
12541
12542         * src/pic/device.c: added 16F819, patch by "David I. Lehn" <dlehn AT vt.edu>
12543         * src/SDCCcse.c (algebraicOpts): fixed "c * 1"
12544
12545 2003-05-28  Bernhard Held <bernhard AT bernhardheld.de>
12546
12547         * doc/sdccman.lyx: fix double dash and other minor things
12548         * doc/Makefile: fix double dash
12549
12550 2003-05-28  Karl Bongers(patches from Martin Helmling)
12551         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files. Martin adds
12552           condition and ignore commands.
12553
12554 2003-05-28  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12555
12556         * doc/sdccman.lyx: Changes all over, index improved, smaller margins. The manual
12557           is in parts still quite out of date, I did changes as far as I felt makes sense
12558           for a non-native english speaker.
12559           Please feel free to add to the manual or to correct my changes.
12560         * doc/Makefile: undid touching the date of intermediate tex files.
12561
12562 2003-05-26  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12563
12564         * doc/sdccman.lyx: Manual has an index now
12565
12566 2003-05-25  Bernhard Held <bernhard AT bernhardheld.de>
12567
12568         Finalize muluint/mulsint and mululong/mulslong merging:
12569         * device/lib/_mulint.c
12570         * device/lib/_mullong.c
12571         * device/lib/gbz80/mul.s
12572         * device/lib/gbz80/stubs.s
12573         * device/lib/z80/mul.s
12574         * device/lib/z80/stubs.s
12575         * src/SDCCsymt.c (initCSupport)
12576
12577 2003-05-25  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12578
12579         * as/mcs51/lkaomf51.c: Address space 'z' was missing.
12580         * src/avr/avr.dsp, src/ds390/ds390.dsp, src/mcs51/mcs51.dsp,
12581           src/pic/pic.dsp, src/pic16/pic16.dsp, src/xa51/xa51.dsp,
12582           src/x80/z80.dsp: peep.rul is bigger now, so /Zm1000 is used
12583           instead of /Zm500.
12584
12585 2003-05-25  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
12586
12587         * src/mcs51/peeph.def: added rules 244.x, 245.x. Although they pass
12588           the regression tests I'm not brave enough to enable 245.b, 245.c
12589         * doc/sdccman.lyx: added latex preamble for hyperref package.
12590           Using pdflatex this will give you a hyperlinked pdf file with
12591           bookmarks. (prepend '%' before /usepackage if this breaks something)
12592
12593 2003-05-24  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12594
12595          * doc/sdccman.lyx: updated information about .adb files (fixed bug 742649)
12596
12597 2003-05-22  Bernhard Held <bernhard AT bernhardheld.de>
12598
12599         * src/pic16/pcode.c (pic16_get_op_from_instruction): fixed a gcc 3.x warning
12600
12601 2003-05-21    <johan AT balder>
12602
12603         * src/SDCCglue.c (printIval): fixed bug #739934
12604
12605 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
12606
12607         Applied patch from bug 737905 (renamed yylineo to mylineno):
12608         * src/altlex.c
12609         * src/SDCCast.c
12610         * src/SDCglobl.h
12611         * src/SDCC.lex
12612         * src/SDCCsymt.c
12613         * src/SDCCval.c
12614         * src/pic16/pcode.c: Cleaned warnings
12615         * src/pic16/pcodeflow.c: Cleaned warnings
12616         * src/pic16/pcoderegs.c: Cleaned warnings
12617
12618 2003-05-19  Scott Dattalo  <scott AT dattalo.com>
12619
12620         * src/pic16/pcode.c: Cleaned warnings
12621         * src/pic16/pcodepeep.c: Cleaned warnings
12622         * src/pic16/ralloc.c: Cleaned warnings
12623
12624 2003-05-19  Bernhard Held <bernhard AT bernhardheld.de>
12625
12626         * doc/sdccman.lyx: fixed bug 739745
12627         * src/pic16/pcode.c (pic16_get_op): fixed warning on alpha
12628
12629 2003-05-18  Bernhard Held <bernhard AT bernhardheld.de>
12630
12631         * src/port.h: removed DEFAULT_PORT, it's not yet pic16 ;-)
12632         it can be defined with CFLAGS when running configure
12633         * src/SDCCmain.c: fixed compiling + linking with object files
12634
12635 2003-05-18  Vangelis Rokas (vrokas AT otenet.gr)
12636
12637         * configure.in: configure for pic16 port,
12638             added --disable-pic16-port
12639         * sdccconf_in.h: added macro OPT_DISABLE_PIC16
12640         * src/SDCCmain.c: linkOptions is changed to set *,
12641             added if/endif conditional macros to remove options help
12642             messages from optionsTable when a port is not configured, added
12643             support for the PIc16 port in the ports table, when executing
12644             the compiler with no port specified on command line, a default
12645             port is selected with the new macro DEFAULT_PORT which is
12646             defined in port.h, in setDefaultOptions() linkOptions is removed
12647             from initialization assignment, since now it is a set,
12648             parseCmdLine uses setParseWithComma for linkOptions, in
12649             linkEdit() linkOptions are accessed with new function indexSet()
12650             which returns the i'th item of a set variable. See SDCCset.c, in
12651             linkEdit() when calling buildCmdLine(), added linkOptions as
12652             last argument. Now users can pass arguments to gplink via the
12653             -Wl option, main() uses pic16glue() to glue up pic16 programs
12654         * src/SDCCpeeph.c: various changes to support pic16
12655         * src/SDCCset.c: added function  void *indexSet(set *, int)  to
12656             return the i'th item of the set
12657         * src/SDCCset.h: added function prototype for indexSet()
12658         * src/SDCCsymt.c: in checkSClass(), added support for PIC16
12659         * src/clean.mk: added pic16 in CLEANALLPORTS variable
12660         * src/port.h: added TARGET_ID_PIC16,TARGET_IS_PIC16 macro,
12661             added macro DEFAULT_PORT
12662         * src/pic/main.c: corrected arguments of gplnk in _linkCmd
12663         * src/pic16/gen.c: bug fix in genCpl(), now the correct code is
12664             generated
12665         * src/pic16/glue.c: commented out some error producing lines
12666         * src/pic16/main.c: __config directives are commented out to stop
12667             gpasm complaining and test the linkage with gplink, _linkCmd and
12668             _asmCmd changed to be more gplink and gpasm friendly
12669         * src/pic16/peeph.def: peep rule 3 is commented out, since it
12670             produced an error when parsed, peep rule 12 is added to utilize
12671             movff, but it is commented out since the pCode does not support
12672             yet a command with 2 address arguments
12673
12674 2003-05-18    <johan AT balder>
12675
12676         * src/ds390/gen.c (genArrayInit): removed obsolete and buggy ARRAYINIT
12677         * src/ds390/main.c (genArrayInit): removed obsolete and buggy ARRAYINIT
12678 2003-05-17  Karl Bongers(apply patches from Martin Helmling)
12679
12680         * debugger/mcs51/sdcdb.c,cmd.c,break.c and .h files.
12681   Added feature to script commands from file.
12682
12683 2003-05-14  Bernhard Held <bernhard AT bernhardheld.de>
12684
12685         * device/lib/_strtok.c: fixed bug #734355 by Lenny Story and Tim Woodall
12686         * src/SDCCutil.c: include ctype.h for win32
12687
12688 2003-05-13  Bernhard Held <bernhard AT bernhardheld.de>
12689
12690         * src/pic16/*: removed CR from many files, reported by Vangelis Rokas
12691
12692 2003-05-12  Karl Bongers(apply development patches from Martin Helmling)
12693
12694         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,break.c and .h files.
12695   Fixed so you can set breakpoints prior to run, run does not stop
12696   on entry now.  Add tbreak.  Other enhancements and fixes for use
12697   with ddd.
12698
12699 2003-05-12  Borut Razem <borut.razem AT siol.net>
12700
12701         * src/SDCCmain.c: fixed the problem with searching the DATADIR as the last resort on *nix
12702
12703 2003-05-11  Borut Razem <borut.razem AT siol.net>
12704
12705         * src/SDCCutil.c: WIN32 version of getBinPath() calls GetModuleFileName() to determine
12706         the path of bin directory, so that PATH is the only env. variable, which has to be set
12707         in case of standard installation.
12708         * src/ds390/ds390.dsp: increased value of /Zm option to 1000
12709         * src/pic/main.c: add quotes to file name parameters for gplink and gpasm
12710         * src/SDCCglobl.h, src/SDCCmain.c, doc/sdccman.lyx: added --print-search-dirs command line option
12711
12712 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
12713
12714         * src/SDCCmain.c (linkEdit): fixed buffer overflow for gbz80
12715         * support/regression/Makefile: inter-port-clean is no longer nesessary, the
12716         temp files are in the port dir; clean the gen/test directory when
12717         generating new test.c
12718         * support/regression/ports/host/spec.mk: defined OBJEXT for target clean
12719         * support/regression/tests/vaargs.c: fixed gcc 3.3 warning
12720         * support/regression/tests/zeropad.c: added
12721
12722 2003-05-09    <johan AT balder>
12723
12724         * src/SDCCglue.c: fixed bug #597940
12725
12726 2003-05-05  Karl Bongers(apply patches from Martin Helmling)
12727
12728         * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
12729   cache sfr, optimize next,step, fix off by one sourceline,
12730   support ddd list function.
12731         * sim/ucsim/cmd.src/newcmd.cc - small fix for sdcdb use.
12732
12733 2003-05-04  Bernhard Held <bernhard AT bernhardheld.de>
12734
12735         * support/regression/HTMLgen.py: added compare_s2f()
12736         * support/regression/Makefile: redo 1.27
12737         * support/regression/generate-cases.py: redo 1.5
12738
12739 2003-04-30  Bernhard Held <bernhard AT bernhardheld.de>
12740
12741         * support/regression/tests/float.c: workaround 33 bit hex constant
12742         * support/regression/tests/simplefloat.c: fix division for host
12743
12744 2003-04-29  Scott Dattalo  <scott AT dattalo.com>
12745
12746         * src/pic/pcoderegs.c Applied patch from Jim Hawkridge <jim AT jimhawkridge.uk.eu.org>
12747         that tame's the PIC's over-aggressive optimizer.
12748
12749 2003-04-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
12750
12751          * src.dsw, link/z80/aslink.h, link/z80/linkz80.dsp: z80 linker
12752          support for MSVC.
12753
12754 2003-04-29  Kevin Vigor <kevin AT vigor.nu>
12755
12756         Initial support for DS80C400. "Hello world" runs on TINIm400
12757         (with polled I/O).
12758
12759 2003-04-28  Karl Bongers(apply patches for Martin Helmling)
12760
12761          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,symtab.c and .h files.
12762          * Some notes on ddd usage added in debugger/README
12763          Martin Helmling adding more features and fixes for ddd GUI debugger.
12764          Code added for nexti, stepi, up, down, and other adjustments.
12765
12766 2003-04-28  Scott Dattalo  <scott AT DATTALO.COM>
12767
12768         * src/pic/pCodepeep.c non-wildcard asmops are now handled
12769         * src/pic/peeph.def Added two rules to optimize carry manipulation
12770         * src/pic/* removed debug printfs
12771
12772 2003-04-28  Bernhard Held <bernhard AT bernhardheld.de>
12773
12774         * debugger/mcs51/cmd.c: added header newalloc.h
12775
12776 2003-04-26  Bernhard Held <bernhard AT bernhardheld.de>
12777
12778         * as/Makefile: new EXEEXT
12779         * as/z80/Makefile: remove trailing slash of BUILDIR
12780         * as/z80/clean.mk: new EXEEXT
12781         * Makefile.common.in: add to CFLAGS (and others), don't replace it
12782         * support/cpp2/Makefile.in: new EXEEXT
12783         * src/pic/glue.c (pic14emitRegularMap): fixed warning
12784
12785 2003-04-24  Bernhard Held <bernhard AT bernhardheld.de>
12786
12787         Cygwin's gcc always appends .exe: 'gcc -o a a.c' creates a.exe;
12788         EXEEXT was introduced to fix all related problems with targets
12789         "clean", "install" and "uninstall"; a couple of further flaws
12790         especially with "clean" have been fixed too
12791         * as/mcs51/Makefile.in
12792         * as/mcs51/clean.mk
12793         * as/z80/Makefile
12794         * Makefile
12795         * clean.mk
12796         * debugger/mcs51/Makefile.in
12797         * debugger/mcs51/clean.mk
12798         * link/z80/Makefile
12799         * link/z80/Makefile.in
12800         * link/z80/clean.mk
12801         * link/Makefile
12802         * packihx/Makefile.in
12803         * packihx/clean.mk
12804         * sim/ucsim/Makefile
12805         * sim/ucsim/clean.mk
12806         * sim/ucsim/avr.src/Makefile.in
12807         * sim/ucsim/avr.src/clean.mk
12808         * sim/ucsim/s51.src/Makefile.in
12809         * sim/ucsim/s51.src/clean.mk
12810         * sim/ucsim/xa.src/Makefile.in
12811         * sim/ucsim/xa.src/clean.mk
12812         * sim/ucsim/z80.src/Makefile.in
12813         * sim/ucsim/z80.src/clean.mk
12814         * sim/ucsim/main_in.mk
12815         * sim/ucsim/packages_in.mk
12816         * sim/ucsim/gui.src/Makefile.in
12817         * sim/ucsim/gui.src/serio.src/Makefile.in
12818         * sim/ucsim/gui.src/serio.src/clean.mk
12819         * src/Makefile.in
12820         * src/clean.mk
12821         * support/cpp2/Makefile.in
12822         * support/cpp2/clean.mk
12823         * support/makebin/Makefile
12824         * support/makebin/clean.mk
12825         * support/scripts/sdcc_mingw32: --program-suffix no longer needed
12826         * doc/sdccman.lyx: --program-suffix no longer needed
12827
12828 2003-04-23  Karl Bongers(apply patches for Martin Helmling)
12829
12830          * debugger/mcs51/sdcdb.c,simi.c,cmd.c,..
12831          Martin Helmling added support for ddd GUI debugger.
12832          Code added to display assembly, set variables, and other commands
12833          to interface to ddd.
12834
12835 2003-04-23  Bernhard Held <bernhard AT bernhardheld.de>
12836
12837         * as/Makefile: fix target clean
12838         * as/clean.mk: fix target clean
12839         * as/z80/clean.mk: fix target clean
12840
12841 2003-04-22  Bernhard Held <bernhard AT bernhardheld.de>
12842
12843         * Makefile.common.in: added  AT EXEEXT AT
12844         * configure.in: removed all mingw32 stuff
12845         * configure: rebuilt from configure.in
12846         * doc/sdccman.lyx: updated section "installation"
12847         * support/scripts/sdcc_mingw32: adapted to configure
12848         * support/scripts/sdcc_cygwin_mingw32: added
12849
12850 2003-04-22  Scott Dattalo  <scott AT dattalo.com>
12851
12852         * src/pic Added object file support for the PIC port
12853         * src/pic Applied patch from Craig Franklin (this started the object file support)
12854         * src/regression Updated the PIC regression tests for object files
12855
12856 2003-04-20  Borut Razem <borut.razem AT siol.net>
12857
12858         * sdcc/as/mcs51/lklex.c: make getfid() more robust and fixed gcc warning:
12859           lklex.c: In function `getfid':
12860           lklex.c:203: warning: array subscript has type `char'
12861         * src/SDCCglobl.h: small change in stack handling macros, to avoid crash when compiled
12862           with MSVC with global optimization enabled (probably an cl compiler bug ;-)
12863         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added function fatal(), called from
12864           stack handling macros
12865
12866 2003-04-19  Borut Razem <borut.razem AT siol.net>
12867
12868         * "handling space characters in file path" task:
12869         * src/SDCCmacro.c: fixed bug in handlig quote at the end of line
12870         * support/Util/BuildCmd.c: define par as NULL if parameter value is invalid
12871         * support/Util/MySystem.h: make it self-sufficient
12872         * src/avr/main.c, src/ds390/main.c, src/mcs51/main.c, src/pic/main.c, src/xa51/main.c,
12873           src/z80/main.c, sdcc/as/mcs51/lklex.c:
12874           handling space characters in file path
12875         * src/SDCCmain.c: introduced setDataPaths() function, {datadir} macro
12876           (it will be used by assemblers, which have their own includes, e.g. gpasm)
12877         * support/Util/MySystem.c: handling space characters in executable's path
12878
12879 2003-04-19  Bernhard Held <bernhard AT bernhardheld.de>
12880
12881         * as/z80/Makefile: fix permanent rebuild of z80
12882         * sim/ucsim/gui.src/Makefile.in: target "install" builds the same packages as target "all"
12883         * support/regression/tests/bitfields.c: added Johan's bitfields.c
12884
12885 2003-04-18      Kevin Vigor <kevin AT vigor.nu>
12886
12887         * src/SDCCopt.c: add special case optimization to replace modulo by
12888           a power of two with a bitwise AND.
12889
12890 2003-04-18    <johan AT balder>
12891
12892         * src/mcs51/gen.c (getFreePtr): fixed bug #635354
12893
12894 2003-04-17    <johan AT balder>
12895
12896         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #716790 and removes lot's of redundant register usage around function calls
12897         * src/mcs51/ralloc.c (packRegisters): fixed bug #720667
12898
12899 2003-04-13  Borut Razem <borut.razem AT siol.net>
12900
12901         * doc/sdccman.lyx: updated info about #pragma SAVE/RESTORE nesting
12902         * configure.in, configure: fixed problems on cygwin/WinCVS environmet with ports.* line endings;
12903           fixed mingw problem in adl_NORMALIZE_PATH
12904
12905 2003-04-12  Borut Razem <borut.razem AT siol.net>
12906
12907         * fixed "#pragma SAVE/RESTORE can not be nested":
12908         * src/SDCC.lex: reworked pragma handling functions
12909         * sdcc/src/SDCCglobl.h: reworked stack handling macros
12910         * support/Util/SDCCerr.c, support/Util/SDCCerr.h: added E_STACK_VIOLATION error
12911
12912 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
12913
12914         * src/SDCCutil.c (pathEquivalent): defined but not used
12915         * debugger/mcs51/sdcdb.c: replace SDCC_LIB_DIR
12916         * configure.in: remove sdcc_datadir, sdcc_lib_dir and sdcc_include_dir
12917         * configure: rebuilt from configure.in
12918         * sdccconf_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
12919         * sdcc_vc_in.h: remove SDCC_LIB_DIR and SDCC_INCLUDE_DIR
12920         * device/include/Makefile.in: replace sdcc_datadir
12921         * device/lib/Makefile.in: replace sdcc_datadir
12922         * Makefile.common.in: add LDFLAGS from configure
12923         * packihx/Makefile.in: use LDFLAGS
12924         * src/Makefile.in: use LDFLAGS
12925         * support/cpp2/Makefile.in: add LDFLAGS from configure
12926         * support/makebin/Makefile: use LDFLAGS
12927         * .version: bumped version number to 2.3.5
12928
12929 2003-04-12  Borut Razem <borut.razem AT siol.net>
12930
12931         * completed "different paths" task:
12932         * src/SDCCmacro.c: fixed bug in handling quotes
12933         * src/SDCCutil.c, src/SDCCutil.c: rewritten getPrefixFromBinPath()
12934         * src/SDCCmain.c: _discoverPaths() replaced with setBinPaths(), setIncludePath() and setLibPath()
12935
12936 2003-04-12  Bernhard Held <bernhard AT bernhardheld.de>
12937
12938         * src/pic/pcoderegs.c (Remove1pcode): fix warning on alpha
12939
12940 2003-04-11 kevin Vigor <kevin AT vigor.nu>
12941
12942         * ds390/gen.c ds390/peeph.def: fix bug 706781
12943
12944 2003-04-11  Borut Razem <borut.razem AT siol.net>
12945
12946         * support/Util/dbuf.c, support/Util/dbuf.h: update to version 1.1.1 - re-added C++ stuff to make it still more portable
12947
12948 2003-04-10  Scott Dattalo  <scott AT dattalo.com>
12949
12950         * src/pic/* Applied the pointer-to-function patch from Steve Tell.
12951         * src/pic/* Fixed several pointer bugs. (PIC port broke when the ruonly bit was
12952          set - this bit used to not be set...).
12953         * src/pic/gen.c Fixed buf 609268 ==> x = (x+1) & 0xf; generated
12954           bad code in PIC Port
12955         * src/regression/and2.c added to test bug 609268
12956         * src/regression/Makefile added and2.c to regression test
12957
12958
12959 2003-04-08    <johan AT CP255758-A>
12960
12961         * src/mcs51/gen.c (gen51Code): display reg usage in --icode-in-asm
12962         * src/mcs51/ralloc.c (serialRegAssign): update the registers in use and save some slocs
12963         * src/SDCCicode.h: added riu to show the register usage in --icode-in-asm
12964
12965 2003-04-07  Bernhard Held <bernhard AT bernhardheld.de>
12966
12967         * configure.in: fully support prefix, exec_prefix, datadir, docdir;
12968         fix bug #487815
12969         * support/cpp2/Makefile.in: fix bug #487815
12970         * configure: rebuilt from configure.in
12971         * Makefile.common.in: docdir changed, new path suffixes
12972         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
12973         * sdcc_vc_in.h: reflect changes from sdccconf.h
12974         * src/SDCCglobl.h: remove *SEPARATOR_CHARS, they are now in sdccconf.h
12975         * src/SDCCutil.h: remove BINDIR hack
12976         * doc/sdccman.lyx: update new path hierarchy
12977
12978 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
12979
12980         * src/SDCCpeeph.c: added okToRemoveSLOC test
12981
12982 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
12983
12984         * device/lib/printf_fast.c: added leading zero format ("%06d", etc)
12985
12986 2003-04-06    Paul Stoffregen <paul AT pjrc.com>
12987
12988         * src/SDCCpeeph.c: added labelIsReturnOnly test
12989         * src/mcs51/peeph.def: Peephole 244: replace ljmp to ret with ret
12990
12991 2003-04-05    <johan AT balder>
12992
12993         * src/SDCCcse.c (cseAllBlocks): fixed bug #460088
12994         * src/SDCCloop.c (DEFSETFUNC): fixed bug #460088
12995         * src/SDCCopt.c (eBBlockFromiCode): fixed bug #460088
12996         * src/SDCCast.c: fixed a warning
12997         * src/SDCCast.h: fixed a warning
12998         * src/SDCCicode.c (operandFromAst): fixed a warning
12999
13000 2003-04-04    <johan AT balder>
13001
13002         * src/SDCCloop.c (DEFSETFUNC): undid the fix for bug #519584
13003         * src/SDCCast.c (decorateType): fixed bug #715076
13004         * src/SDCC.y: fixed bug #702907
13005
13006 2003-04-03    <johan AT balder>
13007
13008         * device/lib/_mulint.c (_muluint): new #pragma LESS_PEDANTIC
13009         * src/SDCCopt.c (eBBlockFromiCode): new #pragma LESS_PEDANTIC
13010         * src/SDCCglobl.h (PRAGMA_LESSPEDANTIC): new #pragma LESS_PEDANTIC
13011         * src/SDCC.lex (doPragma): new #pragma LESS_PEDANTIC
13012         * src/SDCCmain.c (parseCmdLine): new #pragma LESS_PEDANTIC
13013
13014 2003-04-03  Bernhard Held <bernhard AT bernhardheld.de>
13015
13016         * _decdptr.c: fix return values
13017         * _gptrget.c: fix return values
13018         * _gptrgetc.c: fix return values
13019         * _gptrput.c: fix return values
13020         * _mulint.c: fix return values
13021         * as/z80/Makefile: fix 'make -j' problem
13022
13023 2003-04-02  Bernhard Held <bernhard AT bernhardheld.de>
13024
13025         * Makefile.common.in: unused PORT, SCC and SAS removed, fixed docdir
13026         * configure.in: big cleanup, updated to autoconf 2.5x
13027         * configure: rebuilt from configure.in
13028         * sdccconf_in.h: new RETSIGTYPE, and other PATHs
13029         * sdcc_vc_in.h: reflect changes from sdccconf.h
13030         * doc/Makefile: fixed a flaw in "make install"
13031
13032 2003-04-02    <johan AT balder>
13033
13034         * src/ds390/gen.c (genCmp): no comments
13035         * src/mcs51/gen.c (genCmp): no comments
13036         * src/SDCCopt.c (eBBlockFromiCode): detect missing return values
13037         * src/SDCCast.c (ast_print): fixed the function type in --dumptree
13038
13039 2003-04-01  Bernhard Held <bernhard AT bernhardheld.de>
13040
13041         * support/regression/generate-cases.py: place generated file in given sub directory
13042         * support/regression/ports/host/spec.mk: prevent removal of testfwk.o
13043         * support/regression/Makefile: improvements for 'make -j';
13044         side effect: it's simpler and faster now
13045
13046 2003-03-31  Borut Razem <borut.razem AT siol.net>
13047
13048         * src/z80/main.c: link-{port} and as-{port} defined without path
13049         * src/src.dsp: support/Util/MySystem.h and src/SDCCutil.h added to project
13050
13051 2003-03-31  Bernhard Held <bernhard AT bernhardheld.de>
13052
13053         * Makefile, src/Makefile.in: add dependencies, so that 'make -j' works
13054
13055 2003-03-30  Borut Razem <borut.razem AT siol.net>
13056
13057         * support/Util/BuildCmd.c, support/Util/BuildCmd.h: rewrite buildCmdLine(),
13058           changed type of list parameter to set
13059         * src/ds390/main.c: changed type of parameter asmOptions to set in _tininative_do_assemble()
13060         * src/port.h: changed type of do_assemble() parameter to set
13061         * src/SDCCmain.c: type of asmOptions changed to set, introduced setParseWithComma(),
13062           sdcpp defined without path, removed variable VersionString, introduced set binPathSet,
13063           definition of "cppoutfilename" macro with NULL value in preProcess()
13064         * src/SDCCglobl.h: included "SDCCset.h", added declaration of setParseWithComma()
13065         * src/SDCCglue.c: removed variable VersionString, inroduced spacesToUnderscores()
13066         * support/Util/MySystem.c, support/Util/MySystem.h: rewrite, char *ExePathList[]
13067           replaced with set *binPathSet
13068         * shash_add() deallocates the item, if allready exsists, before adding the new one
13069         * src/SDCCmacro.c: handling macros with empty or NULL values in _evalMacros()
13070
13071 2003-03-30  Scott Dattalo  <scott AT dattalo.com>
13072
13073         * src/pic/gen.c: Commit patch from Steve Tell <tell AT telltronics.org> that fixes
13074           a nested for loop bug in the PIC port
13075         * src/regression/nestfor.c: new regression test file Steve wrote to test nested
13076           for loops
13077
13078 2003-03-29  Bernhard Held <bernhard AT bernhardheld.de>
13079
13080         * support/Util/dbuf.h: remove C++ stuff to make it portable
13081
13082 2003-03-28  Borut Razem <borut.razem AT siol.net>
13083
13084         * src/SDCC.lex: Fix for bug #711240: dynamic buffer handling of C
13085           literal strings in stringLiteral()
13086         * support/Util/dbuf.c, support/Util/dbuf.h: added: dynamic buffer handling
13087         * src/Makefile.bcc, src/Makefile.in, src/src.dsp: added support/Util/dbuf.c
13088           to the project
13089
13090 2003-03-27  Paul Stoffregen <paul AT pjrc.com>
13091
13092         * src/SDCCpeeph.c (pcDistance): accurate byte distance for mcs51
13093
13094 2003-03-26    <johan AT balder>
13095
13096         * src/mcs51/gen.c (saveRegisters): catched symbol abuse
13097         * src/ds390/gen.c (saveRegisters): catched symbol abuse
13098         * src/SDCCast.c (decorateType): fixed " -v < 3"
13099
13100 2003-03-23  Bernhard Held <bernhard AT bernhardheld.de>
13101
13102         * doc/cdbfile.html: removed, replaced by cdbfileformat.lyx
13103         Added Lenny Story's debug infrastructure changes:
13104         * src/Makefile.in:  added new files cdbFile.c and SDCCdebug.c
13105         * src/Makefile.bcc: added new files cdbFile.c and SDCCdebug.c
13106         * src/cdbFile.c: added
13107         * src/SDCCdebug.c: added
13108         * src/SDCCdebug.h: added
13109         * src/SDCCast.c (createFunction)
13110         * src/SDCCglue.c (emitRegularMap, emitStaticSeg, emitOverlay, glue)
13111         * src/SDCCmain.c (parseCmdLine, main)
13112         * src/SDCCmem.c (redoStackOffsets)
13113         * src/SDCCsymt.c (cdbStructBlock, cdbTypeInfo, cdbSymbol, cdbStruct, cdbStructBlock)
13114         * src/SDCCsymt.h
13115         * src/common.h
13116         * src/avr/gen.c (genAVRCode)
13117         * src/ds390/gen.c (gen390Code)
13118         * src/mcs51/gen.c (gen51Code)
13119         * src/pic/gen.c (genpic14Code)
13120         * src/pic/glue.c (pic14emitRegularMap, pic14emitStaticSeg, pic14emitOverlay, picglue)
13121         * src/xa51/gen.c (genXA51Code)
13122         * src/SDCCast.c: fixed "void foo(void){char c; -c < 0;}"
13123
13124 2003-03-22  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13125
13126         * src/mcs51/gen.c (genCodePointerGet): quicker code for bug #700797
13127         * src/mcs51/peeph.def: added rules 177, 241.x to 243, touched 181, 182.x, 193.x
13128
13129 2003-03-22    <johan AT balder>
13130
13131         * src/SDCCicode.c (geniCodeDerefPtr): fixed bug #698231
13132
13133 2003-03-21  Bernhard Held <bernhard AT bernhardheld.de>
13134
13135         * support/scripts/sdcc_mingw32: adapted to configure from autoconf 2.54
13136         * doc/cdbfileformat.lyx: added, written by Lenny Story
13137         * doc/Makefile: added cdbfileformat.lyx
13138         * doc/clean.mk: added cdbfileformat.lyx
13139
13140 2003-03-20  Bernhard Held <bernhard AT bernhardheld.de>
13141
13142         * src/mcs51/peeph.def: fix bug #705773
13143
13144 2003-03-20    <johan AT balder>
13145
13146         An sfr/sbit can have an "at #" AND an initializer
13147         * src/SDCCsymt.c (checkSClass):
13148         * src/SDCCmem.c (allocGlobal):
13149         * src/SDCCmem.c (allocLocal):
13150         * src/SDCCast.c (createBlock):
13151
13152 2003-03-17  Bernhard Held <bernhard AT bernhardheld.de>
13153
13154         * src/ds390/peeph.def: fix bug #704878: added rule 213.b suggested by Jan Rejlek
13155
13156 2003-03-16    <johan AT balder>
13157
13158         Undid the hackup of const and volatile, the problem is much bigger
13159         * src/SDCC.y:1.65
13160         * src/SDCCast.c:1.171
13161         * src/SDCCglue.c:1.138
13162         * src/SDCCicode.c:1.146
13163         * src/SDCCsymt.c:1.150
13164         * src/SDCCval.c:1.65
13165
13166 2003-03-15  Bernhard Held <bernhard AT bernhardheld.de>
13167
13168         * src/mcs51/ralloc.c (packRegsForAssign): fixed bug #703541
13169         * src/ds390/gen.c (genAddrOf): fixed bug #704087
13170
13171 2003-03-13    <johan AT balder>
13172
13173         Hackup const and volatile modifiers in type chains a bit:
13174         * src/SDCC.y:1.63
13175         * src/SDCCast.c:1.169
13176         * src/SDCCglue.c:1.136
13177         * src/SDCCicode.c:1.143
13178         * src/SDCCsymt.c1.146
13179         * src/SDCCsymt.h1.59
13180         * src/SDCCval.c:1.63
13181
13182 2003-03-12    <johan AT balder>
13183
13184         * src/SDCCBBlock.h: more LRH debugging junk
13185         * src/SDCCcflow.h: more LRH debugging junk
13186         * src/SDCCloop.c: more LRH debugging junk
13187         * src/SDCC.y (struct_declaration): fixed bug #697590
13188         * src/SDCCsymt.[hc] (cloneSpec): NEVER EVER use this again
13189         * src/ds390/gen.c (aopForRemat): fixed bug #700031
13190         * src/SDCCglue.c (emitStaticSeg): fixed bug #700797
13191
13192 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
13193         * src/SDCCpeeph.c: quit being lazy and made proper fix (peephole
13194         test function names must now match exactly).
13195         * src/SDCCcse.c: added special case in findCheaperOp to allow
13196         extending a short integer. Makes less awful code for bug 700121 test case.
13197
13198 2003-03-11  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13199
13200         * as/mcs51/lkmain.c: Added ASlink-Warning to messages
13201         * as/mcs51/lkaomf51.c: Fixed bug when linking asmblink example
13202
13203 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
13204
13205         * src/SDCCpeeph.c: fix so that operandsNotEqualX functions are
13206         actually called (operandsNotEqual() was called for all
13207         operandsNotEqualX tests).
13208
13209 2003-03-11 Kevin Vigor <kevin AT vigor.nu>
13210
13211         * src/SDCCcse.c: fix findCheaperOp to prevent replacing int types
13212         with shorter literals. Fixes bug 700121.
13213
13214 2003-03-11    <johan AT balder>
13215
13216         * src/SDCCsymt.c (compareType): a (void *) can be assigned to any pointer
13217
13218 2003-03-11  Bernhard Held <bernhard AT bernhardheld.de>
13219
13220         * src/SDCCloop.c (mergeRegions): an evil beast is dead
13221         * src/SDCCmain.c (preProcess): minor cleanup: eliminate preOutName
13222
13223 2003-03-10  Borut Razem <borut.razem AT siol.net>
13224
13225         * src/SDCCmain.c: pipe preprocessor's output
13226         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
13227         * sdcc_vc_in.h: define pclose as _pclose for WIN32
13228         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
13229         which closes all pipes in pipeSet set
13230         * src/SDCCset.c: free deleted item in function deleteSetItem()
13231         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
13232         moved from z80 to src subproject
13233         * .version: increased version number to 2.3.4
13234
13235 2003-03-10  Bernhard Held <bernhard AT bernhardheld.de>
13236
13237         * support/regression/ports/mcs51/spec.mk: increase timeout for CF's sparc to 30s
13238         * support/regression/ports/ds390/spec.mk: increase timeout for CF's sparc to 25s
13239         * support/regression/ports/xa51/spec.mk: fix typo
13240
13241 2003-03-09  Bernhard Held <bernhard AT bernhardheld.de>
13242
13243         * src/SDCCglobl.h: PATH_MAX is already defined in mingw32 headers
13244
13245 2003-03-09  Borut Razem <borut.razem AT siol.net>
13246
13247         * src/SDCCmain.c: pipe preprocessor's output
13248         * support/Util/MySystem.c, support/Util/MySystem.h: added my_popen()
13249         * sdcc_vc_in.h: define pclose as _pclose for WIN32
13250         * src/SDCCglue.c, src/SDCCglue.h: added set pipeSet, added function closePipes,
13251         which closes all pipes in pipeSet set
13252         * src/SDCCset.c: free deleted item in function deleteSetItem()
13253         * src/src.dsp, src/z80/z80.dsp: files support/Util/BuildCmd.c and support/Util/MySystem.c
13254         moved from z80 to src subproject
13255
13256 2003-03-09  Borut Razem <borut.razem AT siol.net>
13257
13258         * src/SDCCglue.c: re-implemented tempfilename() and tempfile(): using mkstemp() if available
13259         * src/SDCCsymt.h: fixed MSVC and BORLANDC compilation (included SDCCglobl.h instead srccconf.h)
13260         * sdcc_vc_in.h: explicitly undefined HAVE_MKSTEMP which is not available on BORLANDC and MSVC
13261         * src/SDCCset.h: removed inclusion of sdccconf.h or sdcc_vc.h
13262         * src/SDCCglobl.h: unification of WIN32 native definitions
13263
13264 2003-03-09  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13265
13266         * src/mcs51/gen.c: applied in-/dec patch mentioned on sdcc-devel 2003-03-01
13267
13268 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
13269
13270         * src/configure.in:   check for endianess (even while cross-compiling)
13271         * src/configure:      check for endianess (even while cross-compiling)
13272         * src/configure_in.h: check for endianess (even while cross-compiling)
13273         * src/avr/gen.c:        remove old endianess stuff
13274         * src/mcs51/gen.c:      remove old endianess stuff
13275         * src/ds390/gen.c:      remove old endianess stuff
13276         * src/pic/gen.c:        remove old endianess stuff
13277         * src/pic/genarith.c:   remove old endianess stuff
13278         * src/pic/glue.c:       fix endianess check
13279         * src/pic16/gen.c:      remove old endianess stuff
13280         * src/pic16/genarith.c: remove old endianess stuff
13281         * src/pic16/glue.c:     fix endianess check
13282         * src/xa51/gen.c:       remove old endianess stuff
13283         * src/z80/gen.c:        fix endianess check
13284         * src/SDCCglue.c:       fix endianess check
13285         * src/ds390/peeph.def: fix bug 700036
13286
13287 2003-03-08  Bernhard Held <bernhard AT bernhardheld.de>
13288
13289         * src/SDCCsymt.h: use appropriate data-types on host for SDCC's int and long
13290         * src/configure: find appropriate data-types on host for SDCC's int and long
13291         * src/configure.in: find appropriate data-types on host for SDCC's int and long
13292         * src/sdccconf_in.h: find appropriate data-types on host for SDCC's int and long
13293         * src/xa51/gen.c: use %d, not %ld for 4 byte variables
13294
13295 2003-03-07    <johan AT balder>
13296
13297         Just a big NOOP:
13298                 some minor cleanups before the big shot
13299                 OP_DEFS and OP_USES now use Kevin's protection
13300                 new option --nolabelopt
13301
13302         * src/SDCCBBlock.c:
13303         * src/SDCCast.c,:
13304         * src/SDCCcflow.c:
13305         * src/SDCCcse.c:
13306         * src/SDCCicode.c:
13307         * src/SDCCicode.h:
13308         * src/SDCClabel.c:
13309         * src/SDCCloop.c:
13310         * src/SDCCmain.c:
13311         * src/ds390/ralloc.c:
13312         * src/mcs51/ralloc.c:
13313         * src/pic/ralloc.c:
13314         * src/xa51/ralloc.c:
13315         * src/z80/ralloc.c:
13316
13317 2003-03-06  Bernhard Held <bernhard AT bernhardheld.de>
13318
13319         * src/pic/pcode.c (get_op): fix 64 bit warnings
13320         * src/pic/pcode.c (pCode2str): fix 64 bit warnings
13321         * src/SDCChasht.c (newHashTable): fix 64 bit warnings
13322         * src/SDCCsymt.c (checkTypeSanity): fix 64 bit warnings
13323         * support/regression/tests/malloc.c: fix 64 bit warnings
13324
13325 2003-03-04  Bernhard Held <bernhard AT bernhardheld.de>
13326
13327         * src/mcs51/gen.c (genMinus): fixed bug 696436
13328
13329 2003-03-02  Borut Razem <borut.razem AT siol.net>
13330
13331         * src/SDCCmain.c: added BORLANDC, corrected MSVC in printVersionInfo()
13332
13333 2003-02-26  Bernhard Held <bernhard AT bernhardheld.de>
13334
13335         * configure.in: test for mkstemp
13336         * sdccconf_in.h: add HAVE_MKSTEMP
13337
13338 2003-02-24  Bernhard Held <bernhard AT bernhardheld.de>
13339
13340         * device/include/ctype.h: removed warning while using --stack-auto
13341         * device/include/malloc.h: removed warning while using --stack-auto
13342         * device/include/string.h: removed warning while using --stack-auto
13343
13344 2003-02-23  Borut Razem <borut.razem AT siol.net>
13345
13346         * src/asm.h: corrected assertion in function printILine(): _pipe() was not executed on MSVC,
13347         because NDEBUG is defined (see man assert)
13348         * sdcc_vc_in.h: vsnprintf is defined as _vsnprintf on MSVC
13349
13350 2003-02-23  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13351
13352         * src/mcs51/gen.c (genUminusFloat): avoided dptr in-/decrement for xdata variables
13353         * src/mcs51/peeph.def: added rule suggested by Gernot Fink, white space/comment changes
13354
13355 2003-02-18  Frieder Ferlemann <Frieder.Ferlemann AT web.de>
13356
13357         * src/SDCCpeeph.c: added peephole conditions testing for same arguments
13358         * src/mcs51/peeph.def: added rules 238a-d which remove redundant moves
13359
13360 2003-02-18    <johan AT balder>
13361
13362         * as/mcs51/asmain.c (asmbl): module can start with a digit
13363         * as/z80/asmain.c (asmbl): module can start with a digit
13364
13365 2003-02-16  Bernhard Held <bernhard AT bernhardheld.de>
13366
13367         * sim/ucsim/mkecho: inserted #!/bin/sh for Cygwin, so that it's executable
13368         * src/asm.c: fix pipe() for Mingw32
13369
13370 2003-02-15  Bernhard Held <bernhard AT bernhardheld.de>
13371
13372         * src/SDCCglue.h: make tmpfileNameSet available for preOutName
13373         * src/SDCCmain.c (preProcess): make sure, that preOutName will be deleted;
13374         make -V work again; --c1mode reads now from stdin
13375         * doc/sdccman.lyx: added --c1mode
13376         * support/Util/SDCCerr.c: new messages for c1 mode
13377         * support/Util/SDCCerr.h: new messages for c1 mode
13378         * src/SDCC.lex (checkCurrFile): test if fullSrcFileName is NULL for c1mode
13379
13380 2003-02-15    <johan AT balder>
13381
13382         * src/asm.c: new options: --no-c-code-in-asm and --i-code-in-asm
13383
13384 2003-02-14  Bernhard Held <bernhard AT bernhardheld.de>
13385
13386         * doc/sdccman.lyx: Environment variables, -o and other minor things
13387
13388 2003-02-14    <johan AT balder>
13389
13390         * src/xa51/main.c: before anyone really tries to use it :)
13391
13392         * Install doc's in share/sdcc/doc
13393         * removed some obsolete files
13394         * Do a proper make distclean and uninstall
13395         M Makefile.common.in
13396         R sdccbuild.sh
13397         M as/Makefile
13398         M device/include/Makefile.in
13399         M device/lib/Makefile.in
13400         M doc/sdccman.lyx
13401         M link/Makefile
13402         M sim/ucsim/doc/Makefile.in
13403         M src/clean.mk
13404         R src/avr/peeph.rul
13405         R src/xa51/peeph.rul
13406         M support/cpp2/Makefile.in
13407         M support/makebin/Makefile
13408
13409
13410 2003-02-13  Bernhard Held <bernhard AT bernhardheld.de>
13411
13412         * support/regression/ports/host/spec.mk: use cc as host compiler for max osx
13413
13414 2003-02-10  Borut Razem <borut.razem AT siol.net>
13415
13416         * doc/bccinst.txt, packihx/packihx.c, sdcc_vc_in.h, src/SDCCset.h,
13417         support/cpp2/config.in: Borland C++ build doesn't depend on Cygwin configure
13418         * Bcc.ini, Makefile.bcc, as/mcs51/Makefile.bcc,
13419         device/examples/ds390/tinitalk/Makefile.bcc, packihx/Makefile.bcc,
13420         support/cpp2/Makefile.bcc, src/Makefile.bcc, src/avr/Makefile.bcc,
13421         src/ds390/Makefile.bcc, src/izt/Makefile.bcc, src/mcs51/Makefile.bcc,
13422         src/pic/Makefile.bcc, src/pic16/Makefile.bcc, src/xa15/Makefile.bcc,
13423         src/z80/Makefile.bcc: Borland Makefile cleanup
13424         * as/z80/Makefile.bcc: Added Borland Makefile
13425         * support/cpp2/borland.h: Removed
13426
13427 2003-02-10  Bernhard Held <bernhard AT bernhardheld.de>
13428
13429         * doc/sdccman.lyx: new pragma NOIV by "Johannes Stezenbach" <js AT convergence.de>
13430         * src/SDCC.lex: new pragma NOIV
13431         * src/SDCCglobl.h: new pragma NOIV
13432         * src/SDCCmem.c: new pragma NOIV
13433
13434 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
13435
13436         * src/SDCCmain.c: signal handling is switched off by SDCC_LEAVE_SIGNALS
13437
13438 2003-02-09  Bernhard Held <bernhard AT bernhardheld.de>
13439
13440         * src/SDCCmain.c: signal handling is switched off by --debug
13441         * doc/Makefile: small fix for install; use clean.mk again
13442         * doc/clean.mk: clean *.pdf and *.html too
13443
13444 2003-02-08  Bernhard Held <bernhard AT bernhardheld.de>
13445
13446         * device/lib/_mulint.c: small fix for large/ds390 --int-long-reent resp. --stack-auto
13447         * device/lib/printfl.c: fix a ds390 bug by making it portable
13448         * src/SDCCsymt.c (initCSupport): fix compile warning on Cygwin
13449         * src/SDCCopt.c (cnvToFloatCast): fix compile warning on Cygwin
13450         * src/SDCCopt.c (cnvFromFloatCast): fix compile warning on Cygwin
13451         * debugger/mcs51/cmd.c: converted multi-line string literals
13452         * sim/ucsim/globals.cc: converted multi-line string literals
13453         * src/SDCCmain.c: introduced signal handler to remove temp files
13454         * doc/Makefile: small tweaks, implement clean
13455         * doc: removed generated files
13456
13457 2003-02-05  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13458
13459         * as/mcs51/aslink.h, as/mcs51/lkihx.c, as/mcs51/lkrloc.c:  Applied
13460         patch from Jan Rejlek <jr AT apex-lib.cz> to fix Bug 677692: "Extended
13461         Address Record is not correctly generated for DS390."
13462
13463 2003-02-02  Borut Razem <borut.razem AT siol.net>
13464
13465         * Makefile.bcc: removed non existing cpp project and non compilable izt project from makefile
13466         * as/mcs51/asm.h: fixed compilation with Borland C
13467         * support/cpp2/Makefile.bcc: added rule to generate auto-host.h
13468         * support/cpp2/auto-host_vc_in.h: fixed compilation with Borland C
13469         * src/mcs51/mcs51a.dsp: corrected misspelled project name from msc51a to mcs51a
13470         * src/avr/Makefile.bcc, src/ds390/Makefile.bcc, src/izt/Makefile.bcc,
13471         src/mcs51/Makefile.bcc, src/pic16/Makefile.bcc, src/xa51/Makefile.bcc,
13472         src/z80/Makefile.bcc: delete $(LIB) only if exist
13473         * src/Makefile.bcc, src/pic/Makefile.bcc:  fixed compilation with Borland C
13474
13475 2003-02-02  Bernhard Held <bernhard AT bernhardheld.de>
13476
13477         * device/include/malloc.h: introduced NULL
13478         * device/include/string.h: introduced NULL
13479         * device/include/stdlib.h: introduced NULL
13480         * device/lib/_memcpy.c: removed NULL
13481         * device/lib/_strcat.c: removed NULL
13482         * device/lib/_strchr.c: removed NULL
13483         * device/lib/_strcmp.c: removed NULL
13484         * device/lib/_strcpy.c: removed NULL
13485         * device/lib/_strcspn.c: removed NULL
13486         * device/lib/_strlen.c: removed NULL
13487         * device/lib/_strncat.c: removed NULL
13488         * device/lib/_strncmp.c: removed NULL
13489         * device/lib/_strncpy.c: removed NULL
13490         * device/lib/_strpbrk.c: removed NULL
13491         * device/lib/_strrchr.c: removed NULL
13492         * device/lib/_strspn.c: removed NULL
13493         * device/lib/_strstr.c: removed NULL
13494         * device/lib/_strtok.c: removed NULL
13495         * device/lib/malloc.c: removed NULL, include own header
13496
13497 2003-02-02    <johan AT balder>
13498
13499         * 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
13500         * support/regression/fwk/lib/testfwk.c: div and mod isn't broken anymore
13501         * regressions ds390/spec.mk and mcs51/spec.mk (timeout): my good old balder isn't fast enough for some tests
13502         * src/z80/gen.c (genZ80Code): added c-lines in asm comments
13503         * as/z80/asm.h (NINPUT): increased for long c-comments in regression tests
13504         * src/z80/gen.c (genRightShiftLiteral): fixed the (char)(-3)>>8 (I think)
13505
13506 2003-02-01  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13507
13508         * src/SDCCmain.c: Fixed bug 678574: "ds390: ASlink-Error-Stack overlaps
13509         area 'DATA'"
13510
13511 2003-02-01    <johan AT balder>
13512
13513         * src/SDCCval.c (valBitwise): fixed Karl's "2 | (1<<8)"
13514
13515 2003-01-31    <johan AT CP255758-A>
13516
13517         * src/ds390/main.c (_ds390_genAssemblerPreamble): applied Jan Rejlek's >64K startup patch
13518
13519 2003-01-30    <johan AT balder>
13520
13521         * src/SDCCBBlock.c: automatic bug detection
13522         * src/SDCCicode.c: automatic bug detection
13523
13524 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13525
13526         * src/SDCCglobl.h:   now --xram-size 0 works
13527         * src/SDCCmain.c:    now --xram-size 0 works
13528
13529 2003-01-29    <johan AT balder>
13530
13531         * src/almosteverything: changed OP_DEFS and OP_USES from macros to functions to catch symbol abuse (a hot topic in the bug list :)
13532
13533 2003-01-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13534
13535         * as/mcs51/aslink.h: Added options --xram-size and --code-size
13536         * as/mcs51/lkdata.c: Added options --xram-size and --code-size
13537         * as/mcs51/lkmain.c: Added options --xram-size and --code-size
13538         * as/mcs51/lkmem.c:  Added options --xram-size and --code-size
13539         * src/SDCCglobl.h:   Added options --xram-size and --code-size
13540         * src/SDCCmain.c:    Added options --xram-size and --code-size
13541
13542 2003-01-28  Bernhard Held <bernhard AT bernhardheld.de>
13543
13544         * src/ds390/gen.c: fix deps by replacing <common.h> with "common.h"
13545         * src/SDCC.lex: rename P_OVERLAY to P_OVERLAY_ for cross-gcc 3.2 MINGW32
13546
13547 2003-01-27    <johan AT balder>
13548
13549         * src/SDCC.y: fixed bug #613764
13550
13551 2003-01-26    <johan AT balder>
13552
13553         * src/SDCClrange.c:  fixed Bernhard's "char * code ptr = &c"
13554         * src/SDCCsymt.h: fixed bug #673374
13555         * src/SDCCglue.c: fixed bug #661910
13556         * src/SDCCast.c: fixed bug #458099 and 673374
13557
13558 2003-01-26  Bernhard Held <bernhard AT bernhardheld.de>
13559
13560         * as/mcs51/strcmpi.c: added, provides Aurelien Jarno's as_strcmpi(); strcmpi() is not ANSI
13561         * as/mcs51/strcmpi.h: added
13562         * as/mcs51/asm.h: remove ugly "#define strcmpi strcmp"
13563         * as/mcs51/aslink.h: remove ugly "#define strcmpi strcmp"
13564         * as/mcs51/asmain.c: strcmpi -> as_strcmpi
13565         * as/mcs51/assym.c: strcmpi -> as_strcmpi
13566         * as/mcs51/lkmem.c: strcmpi -> as_strcmpi
13567         * as/mcs51/lknoice.c: strcmpi -> as_strcmpi
13568         * as/mcs51/lksym.c: strcmpi -> as_strcmpi
13569         * as/mcs51/Makefile.aslink: new module strcmpi
13570         * as/mcs51/Makefile.asx8051: new module strcmpi
13571         * as/mcs51/Makefil.bcc: new module strcmpi
13572         * as/mcs51/Makefile.in: new module strcmpi
13573         * sim/ucsim/s51.src/uc390.cc (get_mem_size): make RAM big enough for tinibios
13574
13575 2003-01-26    <johan AT balder>
13576
13577         * src/SDCCglue.c: reverted back to 1.124
13578         * src/SDCCast.c: reverted back to 1.156
13579         * src/mcs51/gen.c (aopGet): applied Frieder's efficiency patch
13580
13581 2003-01-25    <johan AT balder>
13582
13583         * src/SDCCglue.c: A better fix for bug #661910
13584         * src/SDCCast.c: A better fix for bug #661910
13585         * src/SDCCglue.c (emitRegularMap): That was a little too efficient
13586
13587 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
13588
13589         * src/Makefile.in: remove spawn.o
13590         * src/SDCCmain.c: remove spawn.h
13591         * src/SDCCmain.c (printVersionInfo): report MINGW32 instead of UNIX
13592         * src/spawn.c: removed
13593         * src/spawn.h: removed
13594         * support/regression/ports/ds390/spec.mk: link with -r
13595
13596 2003-01-24    <johan AT CP255758-A>
13597
13598         * src/ds390/gen.c (aopOp): fixed bug #667458
13599         * src/SDCCglue.c (emitRegularMap): fixed bug #458099 again
13600         * src/SDCCast.c (createIvalCharPtr): fixed bug #661910
13601         (createIvalCharPtr): an ival doesn't always have a storage class anymore
13602
13603 2003-01-24  Bernhard Held <bernhard AT bernhardheld.de>
13604
13605         * src/mcs51/peeph.def: better assembler identation by Frieder
13606         * src/mcs51/gen.c: better assembler identation by Frieder
13607
13608 2003-01-22  Bernhard Held <bernhard AT bernhardheld.de>
13609
13610         * as/z80/string.h: removed for gcc 3.2
13611         * support/makebin/makebin.c: #include <string.h> for gcc 3.2
13612         * src/pic/pcode.c (get_op_from_instruction): fix concatenation of string literals with __FUNCTION__ for gcc 3.2
13613
13614 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
13615
13616         * src/SDCCmain.c (linkEdit): rename mem and map files even in case of failure
13617         * src/SDCCpeeph.c (replaceRule): fix bug #663503
13618         * support/regression/Makefile: separate temp files for ports
13619         * support/regression/generate-cases.py: separate temp files for ports
13620         * src/mcs51/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
13621         * src/ds390/peeph.def: Frieder: removed 237 (obsolete by 236g and 105); added 237 a/b
13622
13623 2003-01-19  Bernhard Held <bernhard AT bernhardheld.de>
13624
13625         * moved tinitalk to device/examples/ds390
13626
13627 2003-01-14  Bernhard Held <bernhard AT bernhardheld.de>
13628
13629         * as/mcs51/lkmem.c: rflag is for DS390
13630         * src/SDCCglobl.h: removed out_name and options stackOnData, genericPtr
13631         * src/SDCCmain.c (optionsTable, setDefaultOptions): removed --stack-after-data and --generic
13632                          (linkEdit): move mem- and map-files the same way as ihx-files
13633         * src/z80/main.c (_setDefaultOptions): removed --generic
13634         * src/SDCCmain.c (_processC1Arg, parseCmdLine, main): --c1mode works again
13635         * src/SDCCglue.c (createInterruptVect, glue): --c1mode works again
13636         * src/pic/glue.c (picglue): --c1mode works again
13637         * src/pic16/glue.c (pic16glue): --c1mode works again
13638         * src/asm.c (printCLine): fix #660034
13639
13640 2003-01-13  Bernhard Held <bernhard AT bernhardheld.de>
13641
13642         * src/ds390/peeph.def: fix #123; add 14 rules by Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>, 1 by Frieder
13643         * src/mcs51/peeph.def: fix #123; add 14 rules by Fiorenzo, 1 by Frieder
13644         * src/mcs51/gen.c (genFunction): emit r0 instead of ar0 by Fiorenzo
13645         * as/mcs51/lkmem (summary): better fix for sp problem
13646         * src/SDCCglue.c (glue): __start_stack - 1, saves 1 byte!
13647         * src/ds390/main.c (_ds390_finaliseOptions, _tininative_finaliseOptions): stack_loc = 0x400008
13648         * support/regression/ports/*/spec.mk: moving testfwk-object to port dir allow parallel execution of regression tests
13649                                               remove --stack-after-data
13650
13651 2003-01-12  Bernhard Held <bernhard AT bernhardheld.de>
13652
13653         * src/SDCCmain.c (main): port->finaliseOptions() moved for z80 linking
13654         * src/SDCCutil.c (join): ugly bug: missing '\0'
13655         * as/mcs51/lkmem.c (summary): sp on address 7 is safe
13656
13657 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
13658
13659         * src/SDCCmain.c (assemble, linkEdit): preparations for -o
13660         * src/port.h: typo
13661         * src/pic/main.c (_asmCmd): gpasm supports -o
13662         * src/z80/main.c: more general macros
13663         * device/lib/Makefile.in: remove intermediate files
13664
13665 2003-01-11  Bernhard Held <bernhard AT bernhardheld.de>
13666
13667         * .version: Bumped version number to 2.3.3
13668         * src/SDCCBBlock.c: new option -o
13669         * src/SDCCglobl.h: new option -o
13670         * src/SDCCglue.c: new option -o
13671         * src/SDCCmain.c: new option -o
13672         * src/asm.c: new option -o
13673         * src/ds390/main.c: new option -o
13674         * src/pic/glue.c: new option -o
13675         * src/pic/pcode.c: new option -o
13676         * src/pic/ralloc.c: new option -o
13677         * src/pic16/glue.c: new option -o
13678         * src/pic16/pcode.c: new option -o
13679         * src/pic16/ralloc.c: new option -o
13680         * src/z80/main.c: new option -o
13681         * device/lib/Makefile.in: use -o
13682         * support/regression/ports/ds390/spec.mk: use -o
13683         * support/regression/ports/gbz80/spec.mk: use -o
13684         * support/regression/ports/mcs51/spec.mk: use -o
13685         * support/regression/ports/mcs51-stack-auto/spec.mk: use -o
13686         * support/regression/ports/z80/spec.mk: use -o
13687         * support/regression/ports/ucz80/spec.mk: use -o
13688         * support/regression/ports/xa51/spec.mk: use -o
13689         * support/regression/fwk/lib/timeout.c: fix usage string
13690
13691 2003-01-09  Bernhard Held <bernhard AT bernhardheld.de>
13692         * src/mcs51/gen.c (genPlus): replaced "mov b,acc" by "mov b,a" Fiorenzo D. Ramaglia <fd.ramaglia AT tin.it>
13693
13694 2003-01-07    <johan AT balder>
13695
13696         * src/SDCCast.c (decorateType): fixed bug #600035
13697
13698 2003-01-07  Bernhard Held <bernhard AT bernhardheld.de>
13699         * as/mcs51/lkmem.c: added several l-modifiers to printf to remove warnings
13700         * as/mcs51/lkaomf51.c: #include <ctype.h> to remove warnings
13701         * src/pic/main.c (_hasNativeMulFor): outcommented unused variables to remove warnings
13702         * src/pic/pcode.c: outcommented unused variable to remove warnings
13703         * src/pic/ralloc.c: outcommented unused variable to remove warnings
13704
13705 2003-01-06    <karl AT turbobit.com>
13706         * sim/ucsim/cmd.src/command.cc: fixed so "break xram r 0x7654" works again in
13707    regression tests.
13708
13709 2003-01-06    <johan AT balder>
13710
13711         * src/SDCCicode.c: fixed array add
13712
13713 2002-01-05  Bernhard Held <bernhard AT bernhardheld.de>
13714         * src/SDCCmacro.c: MAX_STRING_LENGTH increased to 2048; was too small for regression tests
13715         * support/regression/ports/host/support.c: #include <stdarg.h> for gcc 3.2
13716
13717 2003-01-04    <johan AT balder>
13718
13719         * src/SDCCval.c (getNelements): fixed the initialized array of structures
13720
13721 2002-12-29  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13722         * as/mcs51/Makefile.bcc: fixed typo lkomf51.o -> lkaomf51.o
13723
13724 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
13725         * src/mcs51/peeph.def: added rules 234 and 235 from Frieder Ferlemann <frieder.ferlemann AT web.de>
13726         * support/regression/tests/bug-524697.c: fit mem usage into 8032
13727
13728 2002-12-28  Bernhard Held <bernhard AT bernhardheld.de>
13729         * src/mcs51/gen.c (aopGetUsesAcc): inserted missing "return FALSE"
13730
13731 2002-12-27  Bernhard Held <bernhard AT bernhardheld.de>
13732         * as/mcs51/Makefile.in: fixed typo lkomf51.o -> lkaomf51.o
13733
13734 2002-12-26  Bernhard Held <bernhard AT bernhardheld.de>
13735         * src/mcs51/main.c: removed {bindir}{sep} from aslink
13736
13737 2002-12-10  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13738
13739     * in /sdcc/as/mcs51/ changed these files in order to create an
13740     aomf51 file: aslink.h, lkdta.c, lklex.c, lklibr.c, lklist.c,
13741     lkmain.c.  Also added: lkmem.c and lkaomf51.c.  Changed the
13742     following files to include the previous two files: aslink.dsp,
13743     Makefile.aslink, Makefile.bcc, and Makefile.in.
13744
13745     * Changed /sdcc/src/SDCCmain.c so it creates files with extension
13746     .adb instead of .cdb
13747
13748 2002-11-09  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13749
13750         * /sdcc/as/mcs51/lklist.c: Now reports memory usage using the
13751         value from option --iram-size.
13752
13753 2002-09-20  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13754
13755         * /sdcc/as/mcs51/lklist.c: added boundary check before using
13756         dram[] array.
13757
13758 2002-09-18    <wiml AT hhhh.org>
13759
13760         * SDCClrange.h: exposed setFromRange() and setToRange()
13761         * mcs51/ralloc.c: fixed over-eager packRegsForSupport() and
13762           packRegsForAccUse() (bug 542397)
13763         * mcs51/gen.c: MOVA() is now a function to avoid calling aopGet()
13764           multiple times and emitting the fetch operations more than once
13765           added aopGetUsesAcc() function to allow binary operators to
13766           fetch their operands in the correct order; made genMinus() emit
13767           compact code for X = LITERAL - Y
13768
13769 2002-09-00  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13770         * /sdcc/as/mcs51/lklist.c: Fixed incorrect number of parameters to
13771         sprintf() in line 1267.
13772
13773 2002-09-08  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13774         * /sdcc/src/SDCCglue.c: Generate areas REG_BANK_[0-3] only for 8051
13775         like ports.
13776
13777 2002-09-04  Jesus Calvino-Fraga <jesusc AT ece.ubc.ca>
13778         Changes to aslink (All the changes are marked with 'JCF'):
13779
13780         * /sdcc/as/mcs51/aslink.h: External definition of sflag and
13781         summary().
13782
13783         * /sdcc/as/mcs51/lkarea.c: Computes the size of area BSEG_BYTES from
13784         area BSEG.  Also moves, if possible, the DATA area down into the internal
13785         ram so more space is available.
13786
13787         * /sdcc/as/mcs51/lkdata.c: Definition of memory summary output flag
13788         sflag.
13789
13790         * /sdcc/as/mcs51/lklist.c: For the BSEG area report the size in bits,
13791         not bytes.  Function summary() which creates a memory usage summary
13792         file with extension .mem.  Reports of overlaping stack and small stack
13793         size.  If the space for the stack is less than 16 bytes aslink trows a
13794         warning.
13795
13796         * /sdcc/as/mcs51/lkmain.c: Creation of some of the default areas for
13797         the 8051.  Option 'y' for memory summary output file.
13798
13799         Changes to sdcc (All the changes are marked with 'JCF'):
13800
13801         * /sdcc/src/SDCCglobl.h: External definition of RegBankUsed[4].
13802
13803         * /sdcc/src/SDCCglue.c:  If a register bank is used, creates an
13804         overlaying area for it (uses RegBankUsed[4]).
13805
13806         * /sdcc/src/SDCCmain.c: Definition RegBankUsed[4]; marks register
13807         bank zero as used by default.  By default aslink locates the stack
13808         (equivalent to --stack-after-data).  Pass option 'y' to aslink for
13809         the creation of the .mem file.  Delegates the allocation of data area
13810         to aslink (it is not longer 0x30 by default).  If --stack-loc passes
13811         the begining of the stack area to aslink.
13812
13813         * /sdcc/src/SDCCmem.c:  If a register bank is used, marks it so
13814         glue() in SDCCglue.c creates an area for it.
13815
13816 2002-09-03  Borut Razem <borut.razem AT siol.net>
13817         * sdcc/src/SDCCglue.c, sdcc/src/SDCCglue.h, sdcc/src/SDCCmain.c,
13818         sdcc/src/pic/glue.c:
13819         introduced atexit() handler for teporay files removal in case of
13820         errors, assertions, ...
13821
13822 2002-08-29  Borut Razem <borut.razem AT siol.net>
13823         * sdcc/support/cpp2/auto-host_vc_in.h:
13824         re-definition of O_BINARY and other O_XXX as _O_BINARY and _O_XXX, so the problem
13825         with the returned value from read() in sdcc/support/cpp2/cppfiles.c is solved for MSC.
13826         Maybe there is a similar problem with BORLANDC? It should be checked!
13827
13828         * sdcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c, sdcc/src/z80/ralloc.c:
13829         corrected improper use of assert: the assignment to clr variable was done inside the assert.
13830         In case that NDEBUG was defined, the assert macro was substituted with no-op, so the assignment
13831         was not executed, and the compiler (cl) launched a warning:
13832         ralloc.c(1442) : warning C4700: local variable 'clr' used without having been initialized
13833
13834 2002-08-28  Bernhard Held <bernhard AT bernhardheld.de>
13835         * src/SDCCglue.c (printIvalArray): iterative calculation of array length
13836
13837 2002-08-28  Jesus Calvino-Fraga and Borut Razem <borut.razem AT siol.net>
13838         * sdcc/sdcc.dsw: added sdcpp, sdcppa, yacc, conf projects
13839
13840         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
13841           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp,
13842           sdcc/src/xa51/xa51.dsp, sdcc/src/avr/avra.dsp,
13843           sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
13844           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp,
13845           sdcc/src/xa51/xa51a.dsp, sdcc/as/as_z80.dsp,
13846           sdcc/as/aslink.dsp, sdcc/as/asx8051.dsp, sdcc/packihx/packihx.dsp:
13847         - added Release configuration in VS projects
13848         - review of compiler an linker options
13849         - VC .exe files are generated in bin_vc directory, not to interfere
13850           with binaries generated from other projects (cygwin, mingw, bcc ...)
13851
13852         * sdcc/src/yacc.dsp: added
13853
13854         * sdcc/config.dsp, sdcc/configure_vc.awk, sdcc/sdcc_vc_in.h:
13855         added - genarate sdcc_vc.h using sdcc_vc_in.h as template
13856         and insert the version number definitions from .version
13857
13858         * sdcc/support/cpp2/sdcpp.dsp: added - VC project for sdcpp
13859
13860         * sdcc/support/cpp2/sdcppa.dsp, sdcc/support/cpp2/auto-host_vc_in.h:
13861         added - genarate auto-host.h using auto-host_vc_in.h as template
13862
13863         * sdcc/sdcc_vc.h,
13864         removed from CVS, generated automatically
13865
13866 2002-08-25  Bernhard Held <bernhard AT bernhardheld.de>
13867         * support/scripts/inc2h.pl: use gputils or gpasm (from Nathan Hurst)
13868
13869 2002-08-11  Borut Razem <borut.razem AT siol.net>
13870         * support/Util/NewAlloc.c: removed unneeded #include "sdccconf.h" (suggested by Jesus Calvino-Fraga)
13871
13872 2002-08-10  Borut Razem <borut.razem AT siol.net>
13873         * src/SDCCmain.c (main):
13874         file preOutName was unlinked before closed. This seems to be OK on UNIX and cygwin
13875         platforms, but it doesn't work with Visual Studio: the opened file can not be removed.
13876         The consequence was that some temporary files were not removed.
13877
13878         * src/SDCCglue.c:
13879         unification of code in functions tempfilename() and tempfile():
13880         function tempnam() is defined in Visual Studio 6.0 and .NET
13881
13882         * sdcc/sdcc.dsw: removed project sdcpp, added project xa51a
13883
13884         * sdcc/src/src.dsp, sdcc/src/avr/avr.dsp, sdcc/src/ds390/ds390.dsp,
13885           sdcc/src/mcs51/mcs51.dsp, sdcc/src/pic/pic.dsp, sdcc/src/z80/z80.dsp:
13886         - removed compiler command line option /WX: Treats all warnings as errors
13887         - update a list of source files, included into the project
13888
13889         * sdcc/src/avr/avra.dsp, sdcc/src/ds390/ds390a.dsp, sdcc/src/mcs51/mcs51a.dsp,
13890           sdcc/src/pic/pica.dsp, sdcc/src/z80/z80a.dsp:
13891         changed project type to Generic Project so that can be correcly converted to VS.NET project
13892
13893         * sdcc/as/mcs51/asm.h: definition of PATH_MAX for MSC
13894
13895         * sdcc/src/SDCCast.c: solved MSC error in function decorateType()
13896
13897         * sdcc/src/SDCC.y: added missing ending ';' to rules to get rid of bison warnings
13898
13899         * dcc/src/ds390/ralloc.c, sdcc/src/mcs51/ralloc.c:
13900         added return 0 statements after assert() to make compiler happy
13901
13902         * sdcc/src/xa51/peeph.rul, sdcc/src/xa51/peeph.def, sdcc/src/z80/ralloc.c:
13903         added newline in the def file to keep MSC compiler satisfied
13904
13905         * sdcc/src/z80/gen.c:
13906         - function strcasecmp() is not defined in MSC (and probably also in BORLANDC),
13907           so it is replaced with STRCASECMP, which is defined as stricmp in case of MSC and BORLANDC
13908         - solved MSC error in function aopDump()
13909
13910         * sdcc_vc.h: define PREFIX as "\\sdcc"
13911
13912 2002-07-18  Bernhard Held <bernhard AT bernhardheld.de>
13913         * src/SDCCast.c (decorateType): fixed access to array of structures http://sourceforge.net/mailarchive/forum.php?thread_id=902690&forum_id=4107
13914
13915 2002-06-22  Scott Dattalo <scott AT dattalo.com>
13916         * src/pic/*: Numerous bug fixes. Flow analysis has been enhanced.
13917         - Rewrote the register banking algorithm.
13918         - Added pCode live-range analysis to registers (for now, only non-used and
13919         singly-used registers optimized away)
13920
13921         * src/pic/pcoderegs.[ch]: Added new files for pCode live-range analysis
13922
13923         * 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.
13924
13925 2002-05-10  Scott Dattalo <scott AT dattalo.com>
13926         * src/pic/*: Added support for multiplication. Fixed many,many bugs.
13927
13928 2002-04-22  Michael Hope  <michaelh AT vroom>
13929
13930         * device/lib/z80/printf.c: Changed emitter to volatile to work around a pcall bug.
13931
13932         * configure.in (DD_COPT): Added include support required for gbdk.
13933
13934         * .version: Bumped version number just to increase it.
13935
13936         * src/SDCCmain.c: Added -nostdinc to the default options.
13937
13938 2002-04-15  Michael Hope  <michaelh AT vroom>
13939
13940         * device/lib/z80/printf.c (sprintf): Added.
13941
13942         * src/z80/ralloc.c (packRegisters): Disabled pack HL use for GB as it's broken.
13943
13944         * src/z80/peeph.def: Added transpose redundent load rule.
13945
13946         * src/z80/main.c: Added force callee saves for jaune.
13947
13948         * src/port.h: Removed the i186 and tlcs-900h ports as they weren't being being developed.
13949
13950         * src/SDCCmain.c: Pulled the options definition out so that you can add port specific options without changing the main file.
13951
13952 2002-03-28  Johan Knol  <johan AT balder>
13953
13954         * src/SDCCval.c: fixed bug #532436
13955
13956 2002-03-14  Scott Dattalo <scott AT dattalo.com>
13957         * /src/port.h:
13958         Added "char *Processor" field to the port structure.
13959
13960         * /src/SDCCmain.c:
13961         Added -p option. Allows port dependent processor to be specified.
13962
13963         * all ports:
13964         Initialized the new field char *Processor field to NULL in all ports
13965
13966         * /src/pic/*:
13967         Compiler generated registers for interrupt context saving
13968         were not getting allocated.
13969
13970 2002-03-16  Sandeep Dutta  <sandeep AT ddi.com>
13971
13972         * /src/SDCCast.c:
13973         Fixed left shift. Will promote the left side of a left shift
13974         if a) left shifting more than size of operand or b) when assigned
13975         to something size > size of left side
13976
13977 2002-03-14  Scott Dattalo <scott AT dattalo.com>
13978         * src/pic/*
13979         tons of changes. Register allocation has been
13980         rewritten. Added customization for the various PICs. Flow
13981         analysis is restructured. ...
13982
13983         * src/pic/device.h:
13984         Added
13985
13986         * src/pic/device.c:
13987         Added. device.c is a PIC port hack to accomodate variations
13988         in PIC devices.
13989
13990 2002-03-13  Michael Hope  <michaelh AT vroom>
13991
13992         * src/z80/gen.c (genGenPointerGet): Fixed a bug where a pointer in HL is dereferenced into HL but HL is not spilled.  Yeah.
13993
13994 2002-03-04  johanknol  <johanknol AT manik>
13995
13996         * /src/SDCCval.c: fixed
13997
13998         const unsigned char arr[][2] = { { 0, 1 } };
13999         t18.c:1: error: Initializer element is not constant
14000
14001 2002-03-04  bela  <bela AT manik>
14002
14003         * /device/include/mcs51reg.h:
14004         ds89c420 register definition update
14005
14006 2002-03-03    <johan AT FRIJA>
14007
14008         * support/Util/SDCCerr.c: did something, but don't no why anymore
14009
14010         * support/regression/tests/bug-524691.c: made it a little less shy
14011
14012         * src/SDCCast.c (decorateType): fixed bug #524697
14013
14014         * src/SDCCast.c: made some lineno improvements
14015
14016         * src/SDCCval.c (getNelements): changed warning to error
14017
14018         * src/SDCCglue.c (printIvalArray): changed warning to error
14019
14020         * src/SDCCicode.c: fixed a warning for mingw
14021
14022         * src/SDCCast.c (decorateType): fixed the << promotion for ops
14023
14024         * src/SDCCicode.c (geniCodeDivision): divide is shift only for unsigned (bug #524685)
14025
14026 2002-03-02  Sandeep Dutta  <sandeep AT ddi.com>
14027
14028         * src/ds390/peeph.def:
14029         Added some more peephole rules
14030
14031         * src/ds390/gen.c: Various fixes & enhancements
14032
14033         * src/SDCClrange.c, src/SDCClrange.h:
14034         functions "alldefsoutofrange" and "notusedinblock" moved to SDCClrange.c
14035
14036         * src/ds390/ralloc.c:
14037         various fixes & enhancements (ds390) specific
14038
14039         * src/avr/ralloc.c, src/mcs51/ralloc.c, src/pic/ralloc.c, src/xa51/ralloc.c, src/z80/ralloc.c:
14040         Functions "allDefsOutOfRange" & "notUsedinBlock" moved to SDCClrange.c
14041         from rallocs.
14042
14043         * sdcc/src/SDCCcse.c: Better fix for bug # 514308
14044
14045 2002-03-02    <johan AT FRIJA>
14046
14047         * src/SDCCast.c (decorateType): fixed bug #524708
14048
14049         * src/SDCCval.c (floatFromVal): fixed the literal void (whatever that may be)
14050
14051         * src/SDCCicode.c (geniCodePtrPtrSubtract): fixed bug #524691
14052
14053 2002-03-01  Michael Hope  <michaelh AT vroom>
14054
14055         * src/SDCCsymt.c (initCSupport): Removed managling of support function names.
14056
14057         * src/z80/ralloc.c (packRegsForIYUse): Fixed fp bug where four byte operands were packed into IY.
14058
14059 2002-03-01    <johan AT FRIJA>
14060
14061         * src/SDCCglue.c (printIvalPtr): fixed bug #524211
14062
14063         * src/SDCCast.c (decorateType): fixed bug #524209
14064
14065         * src/SDCCval.c (valNot): fixed bug #524195
14066
14067 2002-02-26    <johan AT balder>
14068
14069         * src/xa51/gen.c: fixed a warning
14070
14071         * src/SDCCglue.c (printIvalFuncPtr): fixed bug #522534
14072
14073         * src/SDCCast.c (decorateType): fixed bug #522534
14074
14075 2002-02-23    <johan AT balder>
14076
14077         * src/SDCCdflow.c (computeDataFlow): fixed bug #460088
14078
14079 2002-02-22    <johan AT balder>
14080
14081         * src/SDCCast.c: fixed bug #514865
14082
14083         * src/SDCCy.c ("SDCC.y"): fixed bug #516625
14084
14085 2002-02-21  Sandeep Dutta  <sandeep AT ddi.com>
14086
14087         * sdcc/src/SDCCloop.c:
14088         Previous fix was not good. basic blocks that have "break" or "return" are
14089         not really partof a loop , but live ranges used in these blocks should
14090         be live thru the entire loop, so set partOfLoop but don't add them to
14091         loop region
14092
14093 2002-02-21    <johan AT FRIJA>
14094
14095         * src/SDCCcse.c: fixed bug #514308
14096
14097 2002-02-20  Sandeep Dutta  <sandeep AT ddi.com>
14098
14099         * src/SDCCloop.c:
14100         Fixed BUG #519583. If a conditional block ended in a return/break
14101         statement inside a loop, it was not being considered part of the loop.
14102
14103         * src/SDCCcflow.c: Removed fix (Fixed in SDCCloop.c)
14104
14105 2002-02-10  Karl Bongers <karl AT turbobit.com>
14106
14107         * debugger/*:
14108         Fixed up SDCDB debugger somewhat.  Updated debugger/README
14109         with lots of comments and notes.
14110
14111         * device/examples/test2.c:
14112         Fix bug, "red" variable not being initialized(compiler complained).
14113
14114         * device/examples/Makefile, examples/test3.c:
14115         Add Makefile in device/examples folder, compiles test3.c
14116         for use as a multiple module SDCDB test case.
14117
14118         * sim/ucsim/cmd.src/cmdset.cc:
14119         Took out debug printfs in ucsim "next" command.
14120
14121         * sim/ucsim/xa.src:
14122         Karl and Johan start ucsim XA support.  Most dissassembly working,
14123         about 75% emulation done(plenty of work remaining).
14124
14125         * sim/ucsim/z80.src:
14126         Add Z80 support to ucsim, add test-ucz80 regression test,
14127         notice ucsim/z80 emulation fails on examples/test3.c/itoa code.
14128         Notice z80 compiler fails on examples/test3.c/crc code.
14129
14130 2002-01-30  Sandeep Dutta  <sandeep AT ddi.com>
14131
14132         * src/mcs51/gen.c, src/mcs51/main.c, src/mcs51/ralloc.c:
14133         Added support for --parms-in-bank1
14134
14135         * src/ds390/peeph.def:
14136         added a few more peephole optimzations
14137
14138         * src/ds390/main.c:
14139         1) added __builtin_inp & __builtin_outp used to read in data of given length
14140            from a memory mapped port
14141         2) added __builtin_memcmp
14142         3) added __builtin_swapw swap bytes of a short
14143
14144         * src/ds390/gen.c, src/ds390/gen.h, src/ds390/ralloc.c:
14145         1) handle multiple send & receives from register bank1
14146         2) ralloc can now allocate DPTR1 to some liveRanges
14147
14148         * src/SDCCsymt.c, src/SDCCsymt.h:
14149         changes to handle multiple sends & receives
14150
14151         * src/SDCCptropt.h:
14152         added some pointer arithmetic optimization
14153
14154         * src/SDCCptropt.c:
14155         added some pointer arithmetic optimizations but not stable yet so not
14156         called from anywhere (will get this working shortly)
14157
14158         * src/SDCCopt.c: fixed for multiple sends & receives
14159
14160         * src/SDCCmain.c:
14161         1) added options --parms-in-bank1 (ds390/mcs51) & --protect-sp-update
14162         2) preprocessing done AFTER port->finalizeoptions . This allows ports to
14163            set preprocessor defines (depending on options)
14164
14165         * src/SDCCicode.c, src/SDCCicode.h:
14166         changes made to handle multiple sends & receives
14167
14168         * src/SDCCglobl.h:
14169         Added options --protect-sp-update (ds390) and --parms-in-bank1 (ds390/mcs51)
14170
14171         * src/SDCCcse.c, src/SDCCcse.h:
14172         added function findbackward def (to be used in upcoming optimization)
14173
14174         * src/SDCCcflow.c, src/SDCCcflow.h:
14175         added function returnAtEnd - to determine if a basic block terminates with
14176         a RETURN iCode
14177
14178         * src/SDCCast.c, src/SDCCast.h:
14179         added option parms-in-bank1
14180
14181         * device/lib/_divsint.c, device/lib/_divslong.c, device/lib/_divuint.c
14182         * device/lib/_divulong.c, device/lib/_modsint.c, device/lib/_modslong.c
14183         * device/lib/_modulong.c, device/lib/_mulint.c, device/lib/_mullong.c:
14184         adjusted for --parms-in-bank1 option
14185
14186         * device/include/string.h:
14187         donot redefine "reentrant" keyword
14188
14189         * device/include/ds80c390.h: Added some more SFRs
14190
14191 2002-01-28  Bernhard Held  <bernhard AT bernhardheld.de>
14192
14193         * sim/ucsim: Merged branch ucsim-034-pre3 to main trunk; new version 0.4
14194
14195 2002-01-26  Bernhard Held  <bernhard AT bernhardheld.de>
14196
14197         * src/SDCCast.c (funcOfType): fix usage of double --float-reent
14198
14199 2002-01-22  Bernhard Held  <bernhard AT bernhardheld.de>
14200
14201         * support/regression/fwk/lib/testfwk.c (main): Removed workaround for bug #505387
14202
14203 2002-01-18  Paul Stoffregen  <paul AT pjrc.com>
14204
14205         * Added --xram-movc option
14206
14207 2002-01-13  Bernhard Held  <bernhard AT bernhardheld.de>
14208
14209         * support/regression/Makefile: don't include test-mcs51-stack-auto in target all
14210
14211 2002-01-11  Johan Knol
14212
14213         * Added math lib of Jesus Calvino-Fraga
14214
14215 2002-01-08  Bernhard Held  <bernhard AT bernhardheld.de>
14216
14217         * src/SDCCmain.c (processFile): fix processing of ../../src.c
14218         * support/regression/Makefile: new target test-mcs51-stack-auto
14219         * support/regression/ports/mcs51-stack-auto/spec.mk: added
14220
14221 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
14222
14223         * src/SDCCglue.h: printIvalCharPtr(), not printIvalChar()
14224
14225 2002-01-04  Bernhard Held  <bernhard AT bernhardheld.de>
14226
14227         * support/regression/ports/mcs51/support.c: correct setup of timer / UART
14228
14229 2002-01-03  Bernhard Held  <bernhard AT bernhardheld.de>
14230
14231         * src/SDCCsymt.c (processFuncArgs): fix #498307 by Johan
14232
14233         * src/SDCCglue.h: add definition for printIvalChar()
14234
14235 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
14236
14237         * src/SDCCast.c: fix #498138 by Johan
14238
14239         * src/SDCCglue.c: fix #498138 by Johan
14240
14241 2002-01-02  Bernhard Held  <bernhard AT bernhardheld.de>
14242
14243         * support/regression/Makefile: fix clean
14244
14245         * support/regression/ports/ds390/support.c: fix transmission of last character
14246
14247 2001-12-29  Sandeep Dutta  <sandeep AT ddi.com>
14248
14249         * /sdcc/src/ds390/gen.c:
14250         a) improved computing address of stack variable
14251         b) took out some #if 0 code
14252         c) improved parmBytes adjustment
14253         d) improved genPlusIncr & genMinusIncr
14254         e) genCmp could generate bad code (when left assigned to DPTR)
14255         f) Fixed bug in hasInc
14256
14257         * /sdcc/src/ds390/ralloc.c:
14258         a) packRegsForSupport could mess up live information (Fixed)
14259         b) packRegsDPTRuse could be incorrect for left & right shift
14260
14261         * /sdcc/src/mcs51/ralloc.c:
14262         packRegsForSupport could mess up the live information (Fixed)
14263
14264         * /sdcc/src/mcs51/gen.c: Fixed a bug in hasInc
14265
14266         * /sdcc/src/SDCCast.c:
14267         can reverse a loop even if function call is present as long
14268         as the loop control variable is local & is not passed as parameter
14269
14270 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
14271
14272         * /sdcc/ChangeLog: *** empty log message ***
14273
14274         * /sdcc/src/ds390/gen.c, /sdcc/src/ds390/main.c:
14275         More builtin function additions for TININative
14276
14277         * /sdcc/src/ds390/ralloc.c:
14278         Had broken the regression testsuite
14279
14280         * /sdcc/src/SDCCast.c: Fixed a bug in dumptree
14281
14282         * /sdcc/src/SDCCsymt.c, /sdcc/src/SDCCsymt.h:
14283         Added funcattr hasStackParms will be set for reentrant functions when there
14284         are paramteres on the stack, this helps in minimizing frame pointer generation
14285         typeFromStr can handle function pointers now
14286
14287         * /sdcc/doc/builtins.txt, /sdcc/doc/TININative.txt:
14288         *** empty log message ***
14289
14290 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
14291
14292         * /src/ds390/gen.c, /src/ds390/main.c:
14293         More builtin function additions for TININative
14294
14295         * /src/ds390/ralloc.c:
14296         Had broken the regression testsuite
14297
14298         * /src/SDCCast.c: Fixed a bug in dumptree
14299
14300         * /src/SDCCsymt.c, /src/SDCCsymt.h:
14301         Added funcattr hasStackParms will be set for reentrant functions when there
14302         are paramteres on the stack, this helps in minimizing frame pointer generation
14303         typeFromStr can handle function pointers now
14304
14305         * /doc/builtins.txt, /doc/TININative.txt:
14306         *** empty log message ***
14307
14308
14309 2001-12-24  Sandeep Dutta  <sandeep AT ddi.com>
14310
14311         * /src/ds390/gen.c, /src/ds390/main.c, /src/ds390/peeph.def, /src/ds390/ralloc.c:
14312         ALPHA version for -mTININative
14313
14314         * /src/izt/i186.c, /src/izt/tlcs900h.c, /src/mcs51/main.c, /src/pic/main.c, /src/z80/main.c, /src/avr/main.c:
14315         updated to reflect changes in the port structure
14316
14317         * /src/port.h:
14318         added function do_assemble (similar to do_link) if non-null this function
14319         will be called to do assembly (-mTININative) requires a multi command
14320         assembly
14321         added function genAssemblerEnd will be called to generate assembler Epilogue
14322
14323         * /src/SDCCsymt.c:
14324         added _JavaNative to debug info printing
14325
14326         * /src/SDCCmain.c: added option --tini-libid
14327         added port->do_assemble function (-mTININative) has a multi command assemble
14328
14329         * /src/SDCCglue.c: Disabled "constExpr" check
14330         added port->genAssemblerEnd function
14331
14332         * /src/SDCCglobl.h: Added option --tini-libid value
14333
14334         * /src/SDCCast.h:
14335         tookout optimizeCompare from the header (has no external references)
14336
14337         * /src/SDCCast.c: made one more function "static"
14338
14339 2001-12-23  Michael Hope  <michaelh AT juju.net.nz>
14340
14341         * src/z80/mappings.i: Added z80asm support.
14342
14343         * src/z80/main.c: Added z80asm support on --asm=z80asm
14344
14345         * src/z80/gen.c: Fixed asm portability issues.
14346
14347         * src/asm.c (tvsprintf): Removed old code, added 'N' for function name.  For extern support.
14348
14349         * src/SDCCglue.c (printExterns): Added global/extern split.
14350
14351 2001-12-17  Bernhard Held  <bernhard AT bernhardheld.de>
14352
14353         * support/regression/Makefile: added test for mcs51 model large
14354
14355         * support/regression/ports/mcs51-large/spec.mk: added test for mcs51 model large
14356
14357         * support/regression/ports/gbz80/spec.mk: added -mgbz80
14358
14359 2001-12-05  Michael Hope  <michaelh AT juju.net.nz>
14360
14361         * src/diff.1 (Index): Many, many optmisiations.  Dhrystone up to 201.
14362
14363 1904-01-06  Michael Hope  <michaelh AT juju.net.nz>
14364
14365         * src/z80/ralloc.c (packRegsForIYUse): Fixed the case where an operand is in direct space.
14366
14367         * src/z80/gen.c (makeFreePairId): Optimised IY load by using a spare pair.
14368
14369 2001-12-02  Bernhard Held  <bernhard AT bernhardheld.de>
14370
14371         * src/mcs51/gen.c (genFunction): avoid excess "inc sp"
14372
14373         * support/regression/tests/simplefloat.c: Port to mcs51.
14374
14375 2001-11-25  Michael Hope  <michaelh AT juju.net.nz>
14376         * support/regression/tests/bug-485362.c: Added.
14377
14378         * support/regression/tests/simplefloat.c (testDivNearOne): Added.
14379
14380         * src/z80/gen.c (aopOp): Fixed case where left and result are in the same spill loc and they have different sizes.
14381
14382         * src/z80/peeph.def: Added rules for optimising two byte compares on the same thing, and to optimise two ptr assign.
14383
14384         * src/z80/gen.c (aopDump): Added a dump function.
14385
14386 2001-11-25  Bernhard Held  <bernhard AT bernhardheld.de>
14387         * sim/ucsim/s51.src/glob.cc: DS390 SFRs and bits added.
14388
14389         * sim/ucsim/s51.src/port.cc: Port 4 and 5 added.
14390
14391         * sim/ucsim/s51.src/regs51.h: DS390 SFRs added.
14392
14393         * sim/ucsim/s51.src/uc390.cc: Some details improved, CKRDY works for tinibios.
14394
14395         * sim/ucsim/s51.src/uc390cl.h: Work in progress.
14396
14397         * sim/ucsim/sim.src/uccl.h: 6 ports for DS390.
14398
14399         * support/regression/fwk/lib/testfwk.c: Run with tinibios.
14400
14401         * support/regression/ports/mcs51/spec.mk: Fine tuninig.
14402
14403         * support/regression/ports/ds390/support.c: Use tinibios.
14404
14405         * support/regression/ports/ds390/spec.mk: Fine tuning, use tinibios.
14406
14407 2001-11-23  Michael Hope  <michaelh AT juju.net.nz>support/regression/tests/bug-460010.c
14408
14409         * src/z80/ralloc.c (packRegsForHLUse3): Changed to not pack into HL if anything is in direct space.
14410         (packRegsForHLUse3): Added packing support for send, cast, and return value from a call.
14411
14412         * src/z80/peeph.def: Added rules for optimising pushes of part of a pair.
14413
14414         * src/z80/gen.c (emitCall): Changed the stack fixup to not use HL.
14415
14416 2001-11-18  Michael Hope  <michaelh AT juju.net.nz>
14417
14418         * src/z80/gen.c (genCmp): Fixed compare on unsigned.
14419
14420         * src/z80/ralloc.c (packRegsForHLUse3): Created and optimised.
14421         (packRegsForIYUse): Created and optimised.
14422
14423 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
14424
14425         * support/regression/tests/float.c (testFloatAdd): Fixed up warning.
14426 2001-11-18  Bernhard Held  <bernhard AT bernhardheld.de>
14427
14428         * sdcc/support/regression/tests/bug-460010.c: fix seg violation on host
14429
14430         * sdcc/support/regression/tests/muldiv.c: fix output on mcs51
14431
14432         * sdcc/support/regression/tests/stacks.c: fix DSEG overflow on mcs51
14433
14434 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
14435
14436         * sdcc/sim/device/lib/_gptrget.c: mem region 5 (idata) added
14437
14438         * sdcc/sim/device/lib/_gptrput.c: mem region 5 (idata) added
14439
14440 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
14441
14442         * sdcc/sim/ucsim/globals.cc: New: IXRAM.
14443
14444         * sdcc/sim/ucsim/stypes.h: New: IXRAM.
14445
14446         * sdcc/sim/ucsim/s51.src/uc390.cc: New: IXRAM.
14447
14448 2001-11-07  Michael Hope  <michaelh AT juju.net.nz>
14449
14450         * src/z80/ralloc.c (packRegsForHLUse): Banned IFXs from being packed into HL.
14451         (packRegsForHLUse): Added rule to pack address of/pointer get for itemps into HL for the Z80.
14452         (packRegsForAccUse2): Added rule to pack hbit IFXs into A.
14453
14454         * src/z80/main.c (_setDefaultOptions): Made float code re-entrant by default.
14455
14456         * src/z80/gen.c (aopGetLitWordLong): Added word support for floats.
14457         (genNotFloat): Added.
14458         (genUminusFloat): Added.
14459
14460         * device/lib/z80/Makefile: Added floating pt stubs.
14461
14462         * device/lib/Makefile.in (Z80SOURCES): Added floating pt support.
14463
14464         * src/z80/gen.c (genIpush): Fixed up a push of one byte when left is in a pair.
14465
14466         * device/lib/_fsadd.c (__fsadd): Fixed up return where the numbers are hugely different.
14467
14468 2001-11-07  Bernhard Held  <bernhard AT bernhardheld.de>
14469
14470         * sdcc/sim/ucsim/s51.src/glob.cc: Minor fix.
14471
14472         * sdcc/sim/ucsim/s51.src/regs51.h: Minor fix.
14473
14474         * sdcc/support/regression/Makefile: Add port ds390.
14475
14476         * sdcc/support/regression/ports/mcs51/spec.mk: Minor change.
14477
14478         * sdcc/support/regression/ports/z80/spec.mk: Minor change.
14479
14480         * sdcc/support/regression/ports/ds390/spec.mk: Added.
14481
14482         * sdcc/support/regression/ports/ds390/support.c: Added.
14483
14484         * sdcc/support/regression/ports/ds390/uCsim.cmd: Added.
14485
14486         * sdcc/support/regression/ports/mcs51/timeout.c: Cut.
14487
14488         * sdcc/support/regression/fwk/lib/timeout.c: Paste.
14489
14490 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
14491
14492         * device/include/malloc.h: Added z80 and gbz80 support.
14493
14494         * device/lib/gbz80/heap.s: Added.
14495
14496         * device/lib/z80/heap.s: Added.
14497
14498         * device/lib/malloc.c: Added z80 and gbz80 support.
14499
14500         * support/regression/tests/malloc.c (testMalloc): Added.
14501
14502         * src/SDCCmain.c (parseCmdLine): Added support for -Wp.
14503
14504         * support/regression/tests/bug-478094.c: Added.
14505
14506         * src/z80/gen.c (commitPair): Fixed silly gbz80/z80 commit to static bug.
14507
14508 2001-11-04  Bernhard Held  <bernhard AT bernhardheld.de>
14509
14510         * sdcc/sim/ucsim/s51.src/uc390cl.h: Improvement for ds390 to run regression tests
14511
14512         * sdcc/sim/ucsim/s51.src/uc390.h: Improvement for ds390 to run regression tests
14513
14514         * sdcc/sim/ucsim/s51.src/regs51.h: Improvement for ds390 to run regression tests
14515
14516         * sdcc/sim/ucsim/s51.src/glob.cc: Improvement for ds390 to run regression tests
14517
14518         * sdcc/support/regression/tests/bug-460010.c: Small change for ds390
14519
14520 2001-11-04  Michael Hope  <michaelh AT juju.net.nz>
14521
14522         * src/z80/peeph-gbz80.def: Removed a bad sub optimisation.
14523
14524 2001-11-03  Michael Hope  <michaelh AT juju.net.nz>
14525
14526         * support/regression/tests/bug-477927.c: Added.
14527
14528         * src/z80/peeph.def: Added minor rules.
14529
14530         * src/z80/gen.c (genPlusIncr): Added an extra plusinc rule.
14531
14532         * src/z80/peeph.def: Added jump optimisation modification.
14533
14534 2001-11-01  Michael Hope  <michaelh AT juju.net.nz>
14535
14536         * src/SDCCmain.c (linkEdit): Added runtime path detection to the mcs51 port.
14537
14538 2001-10-30  Michael Hope  <michaelh AT juju.net.nz>
14539
14540         * support/regression/tests/funptrs.c: Added.
14541
14542 2001-10-29  Michael Hope  <michaelh AT juju.net.nz>
14543
14544         * src/z80/ralloc.c (packRegsForHLUse): Fixed up bad spill due to pushing one byte via HL.
14545
14546 2001-10-28  Michael Hope  <michaelh AT juju.net.nz>
14547
14548         * src/z80/gen.c (genArrayInit): Made it work for on stack arrays.
14549
14550         * src/z80/main.c (gbz80_port =): Added rle support to the gbz80 port.
14551
14552         * src/z80/gen.c (genMinus): Fixed for where the result is one byte.
14553         (movLeft2ResultLong): Created.
14554
14555         * src/z80/ralloc.c (packRegsForHLUse): Added a couple of simple cases for the GB.
14556         (joinPushes): Added.  Joins two char pushes into a word push.
14557
14558 2001-10-27  Michael Hope  <michaelh AT juju.net.nz>
14559
14560         * support/cpp2/Makefile.in (install): Added creation of dest dir.
14561
14562         * support/makebin/Makefile (install): Added creation of dest dir.
14563
14564 2001-10-24 Karl Bongers <karl AT turbobit.com>
14565
14566         * configure.in, configure, Makefile, support/cpp: Removed cpp folder, since we have new cpp2 preprocessor code.
14567
14568 2001-10-21  Michael Hope  <michaelh AT juju.net.nz>
14569
14570         * src/z80/ralloc.c: Turned off faulty pack for one use.
14571
14572         * src/z80/peeph-gbz80.def: Removed redundent restart options.
14573
14574         * src/z80/gen.c (genMult): Added native mul for constants on the z80 and gbz80.
14575
14576 2001-10-21  Bernhard Held  <bernhard AT bernhardheld.de>
14577
14578         * support/regression/Makefile: Improved clean
14579
14580         * support/regression/ports/gbz80/spec.mk: Added clean
14581
14582         * support/regression/ports/host/spec.mk: Added clean
14583
14584         * support/regression/ports/z80/spec.mk: Added clean
14585
14586         * support/regression/ports/mcs51/spec.mk: Added clean, little improvements
14587
14588         * support/regression/ports/mcs51/timeout.c: little improvements
14589
14590 2001-10-17  Michael Hope  <michaelh AT juju.net.nz>
14591
14592         * device/lib/malloc.c (MEMHEADER): Fixed against new pedantic pointers.
14593
14594         * support/regression/fwk/include/testfwk.h: Fixed up to use function pts correctly.
14595
14596         * support/regression/generate-cases.py: Fixed up to use function pts correctly.
14597
14598 2001-10-16  Bernhard Held  <bernhard AT bernhardheld.de>
14599
14600         * support/regression/port/mcs51/spec.mk: add timeout for uCsim
14601
14602         * support/regression/port/mcs51/timeout.c: add timeout for uCsim
14603
14604 2001-10-13  Michael Hope  <michaelh AT juju.net.nz>
14605         * src/z80/gen.c (emitCall): Fixed up missing spill of HL when used to assign the result value.
14606
14607         * src/z80/ralloc.c: Turned off pack for one use as it's quite broken.
14608
14609         * src/SDCCmain.c (linkEdit): Added support for passing a legacy command line through the processor.
14610
14611         * src/mcs51/main.c (_linkCmd): Added bin path to command.
14612
14613         * src/SDCCmain.c (initValues): Added support for when it it called just to link.
14614
14615         * as/mcs51/lklibr.c (libfil;): Turned off 'library file' message.
14616
14617         * src/SDCCval.c (constVal): Fixed usage of 'L' modifier problems on ppc.
14618
14619         * support/regression/tests/longor.c: Added.
14620
14621 2001-10-11  Bernhard Held  <bernhard AT bernhardheld.de>
14622
14623         * as/mcs51/asdata.c: replaced FILENAME_MAX with PATH_MAX
14624
14625         * as/mcs51/aslink.h: define PATH_MAX
14626
14627         * as/mcs51/asm.h: define PATH_MAX
14628
14629         * as/mcs51/asmain.c: replaced FILENAME_MAX with PATH_MAX
14630
14631         * as/mcs51/asnoice.c: replaced FILENAME_MAX with PATH_MAX
14632
14633         * as/mcs51/lklex.c: replaced FILENAME_MAX with PATH_MAX
14634
14635         * as/mcs51/lkmain.c: replaced FILENAME_MAX with PATH_MAX
14636
14637         * src/SDCCglobl.h: define PATH_MAX
14638
14639         * src/SDCCmacro.c: replaced FILENAME_MAX with PATH_MAX
14640
14641         * src/SDCCmain.c: replaced FILENAME_MAX with PATH_MAX
14642
14643 2001-10-11  Michael Hope  <michaelh AT juju.net.nz>
14644
14645         * src/z80/gen.c (gencjneshort): Fixed
14646
14647         * src/z80/ralloc.c (packRegsForHLUse): Added pack into HL for cast then ipush.
14648
14649 2001-10-09  Michael Hope  <michaelh AT juju.net.nz>
14650
14651         * support/regression/tests/bug-469671.c: Added.
14652
14653         * src/z80/gen.c (shiftIntoPair): Fixed up warning.
14654
14655 2001-10-08  Michael Hope  <michaelh AT juju.net.nz>
14656
14657         * src/SDCCmain.c: Added --fommit-frame-pointer option and implemented in the z80 port.
14658
14659         * src/z80/gen.c (genPlus): Fixed to work with extended stack.  Also fixed genMinus, genCmp.  genUMinus is still left.
14660
14661 2001-10-08  Bernhar Held  <bernhard AT bernhardheld.de>
14662
14663         * src/SDCCmain.c (preProcess): added define SDCC_NOOVERLAY
14664
14665         * src/device/lib/_mulint.c  : removed hint: nooverlay bug
14666
14667         * src/device/lib/_mullong.c : removed hint: nooverlay bug
14668
14669         * src/device/lib/_divuint.c : removed hint: nooverlay bug
14670
14671         * src/device/lib/_divulong.c: removed hint: nooverlay bug
14672
14673         * src/device/lib/_moduint.c : removed hint: nooverlay bug
14674
14675         * src/device/lib/_modulong.c: removed hint: nooverlay bug
14676
14677 2001-10-07  Michael Hope  <michaelh AT juju.net.nz>
14678
14679         * 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.
14680
14681         * support/Util/NewAlloc.c (freeTrace): Changed free for the gc case to not free at all.  Fixes runtime segfault.
14682
14683         * support/regression/tests/scott-compare3.c (c_abcd): Fixed up casts.
14684
14685 2001-10-07    <johan AT FRIJA>
14686
14687         * device/lib/gets.c (gets): fixed the return value.
14688
14689 2001-10-06  Michael Hope  <michaelh AT juju.net.nz>
14690         * src/SDCCmain.c (WRITE_SEG_LOC): Fixed up to use Safe_strdup.
14691
14692         * 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.
14693
14694         * 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.
14695
14696         * src/z80/gen.c (genZ80Code): Added de-allocation via trace support.
14697
14698         * src/pic/gen.c: Removed Safe_strdup.
14699
14700         * configure.in: Added option to enable libgc support.
14701
14702         * src/SDCCbitv.c (bitVectnBitsOn): Optimised.
14703         (bitVectUnion): Optimised.
14704         (bitVectIntersect): Optimised.
14705         (bitVectBitsInCommon): Optimised.
14706         (bitVectCplAnd): Optimised.
14707
14708         * support/makebin/makebin.c (usage): Removed getopt as mingw32 doesn't have it.  Sigh.
14709
14710 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
14711
14712         * src/SDCCmain.c: distinguish between assembler debug and plain options
14713
14714         * src/avr/main.c:   remove standard assembler options
14715
14716         * src/ds390/main.c: remove standard assembler options
14717
14718         * src/mcs51/main.c: remove standard assembler options
14719
14720         * src/port.h: removed "PENDING" comment
14721
14722 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
14723
14724         * src/device/lib/_mulint.c  : new, with assember functions
14725
14726         * src/device/lib/_mullong.c : new, with assember functions
14727
14728         * src/device/lib/_divuint.c : with assember functions
14729
14730         * src/device/lib/_divsint.c : with assember functions
14731
14732         * src/device/lib/_divulong.c: with assember functions
14733
14734         * src/device/lib/_divslong.c: with assember functions
14735
14736         * src/device/lib/_moduint.c : with assember functions
14737
14738         * src/device/lib/_modsint.c : with assember functions
14739
14740         * src/device/lib/_modulong.c: with assember functions
14741
14742         * src/device/lib/_modslong.c: with assember functions
14743
14744         * src/device/lib/libint.lib:  replaced _muluint.c  and _mulsint.c  by _mulint.c
14745
14746         * src/device/lib/liblong.lib: replaced _mululong.c and _mulslong.c by _mullong.c
14747
14748         * src/device/lib/Makefile.in: replaced _muluint.c  and _mulsint.c  by _mulint.c
14749                                       replaced _mululong.c and _mulslong.c by _mullong.c
14750
14751 2001-10-03 Bernhard Held <bernhard AT bernhardheld.de>
14752
14753         * src/SDCCsymt.c: sequence of specifiers in pintTypeChain() corrected
14754
14755 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
14756
14757         * src/SDCCglue.c: test, if win32api is available for MINGW
14758
14759 2001-10-01 Bernhard Held <bernhard AT bernhardheld.de>
14760
14761         * src/SDCCsymt.c: no more _modifier in printTypeChain()
14762         * support/regression/tests/driverstruct.c: REENTRANT for mcs51
14763         * support/regression/ports/gbz80/spec.mk: removed GENERIC
14764         * support/regression/ports/host/spec.mk: removed GENERIC
14765         * support/regression/ports/mcs51/spec.mk: removed GENERIC
14766         * support/regression/ports/z80/spec.mk: removed GENERIC
14767
14768 2001-10-01  Michael Hope  <michaelh AT juju.net.nz>
14769
14770         * support/regression/fwk/lib/testfwk.c (__printf): Removed GENERIC.
14771
14772         * support/regression/tests/bug-467035.c: Created.
14773
14774 2001-10-01    <johan AT FRIJA>
14775
14776         * src/SDCC.y: fixed bug #466586 part 1
14777
14778 2001-10-01  Johan Knol <johan.knol AT iduna.nl>
14779
14780         * SDCCicode.c: z80 has no generic pointers
14781         * removed -s from strip in all Makefile(.in)'s. It is not needed, but Solaris chocks on it.
14782
14783 2001-09-30  Michael Hope  <michaelh AT juju.net.nz>
14784
14785         * sim/ucsim/cmd.src/Makefile.in ($(PRJDIR)/libcmd.a): Changed all ar references to $(AR) for Solaris.
14786
14787 2001-09-29  Michael Hope  <michaelh AT juju.net.nz>
14788
14789         * Makefile (sdcc-libs): Added makebin to the list of standard targets.
14790
14791         * support/regression/ports/z80/spec.mk: Updated to use env for sdcc bin dir for automatic regression.
14792
14793 2001-09-25  Michael Hope  <michaelh AT juju.net.nz>
14794
14795         * configure.in: Fixed up so that ucsim is only configured once.
14796
14797         * support/cpp2/configure.in: Fixed to use the program transform to append the .exe for the win32 build.
14798
14799         * src/SDCCutil.c (getPrefixFromBinPath): Fixed up to work with win32 in all of its glory.
14800         (getPathDifference): As above.
14801
14802         * src/SDCCmain.c (preProcess): Changed to use a temporary file in a proper temp directory.  Fixed case where pre-processing only.
14803
14804         * src/SDCCglue.c (tempfilename): Added function for pre-processor.
14805
14806 2001-09-23  Michael Hope  <michaelh AT juju.net.nz>
14807         * .version: Updated to 2.3.1
14808
14809         * src/z80/main.c (z80_port =): Added macro based linker and assembler command line support.
14810         Added copyright header.
14811
14812         * src/SDCCmain.c: Shifted various functions into SDCCutil.c
14813         (assemble): Added support for macro based assembler commands.
14814         (linkEdit): Added support for macro based linker commands.
14815         (preProcess): Changed the pre-processor to use macros.
14816         (_setPaths): Added functionality to autodetect the include, lib and bin dir paths.
14817         (_discoverPaths): Added support for overriding the install directory using the SDCCDIR env variable.
14818
14819         * device/lib/z80/crt0.s: Added module name for debugging.
14820
14821 2001-09-20  Michael Hope  <michaelh AT juju.net.nz>
14822
14823         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
14824
14825         * src/SDCChasht.c (hTabDeleteByKey): Fixed delete as it would delete the last item from a bucket even if it wasn't the real one.
14826
14827         * src/SDCCglue.c: Moved gc_strdup to SDCCutil.c
14828
14829         * src/Makefile.in: Added SDCCmacro and SDCCutil
14830
14831 2001-09-19  Michael Hope  <michaelh AT juju.net.nz>
14832
14833         * src/SDCCmain.c (printVersionInfo): Added the build date to the version info.
14834
14835 2001-09-16    <johan AT FRIJA>
14836
14837         * 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.
14838
14839 2001-09-15    <johan AT FRIJA>
14840
14841         * src/mcs51/ralloc.c: (findAssignToSym): fixed bug #460662 part 1
14842         * src/ds390/ralloc.c (findAssignToSym): fixed bug #460662 part 1
14843
14844 2001-09-11    <johan AT FRIJA>
14845
14846         * src/SDCCval.c (valDiv Mod Minus Plus Shift): keep litteral expressions as small as possible (bug #460010)
14847
14848 2001-09-10  Michael Hope  <michaelh AT juju.net.nz>
14849
14850         * support/regression/tests/bug-460444.c: Added test case.
14851
14852         * src/z80/gen.c (genOr): bug 460444: if (a ^ lit) was broken for &, |, and ^.
14853         (genCast): Added justification for all of the asserts.
14854
14855 2001-09-10  Bernhard Held <bernhard AT bernhardheld.de>
14856
14857         * support/regression/support.c: _xdata replaced by xdata
14858
14859         * support/regression/spec.mk: removed _generic
14860
14861 2001-09-09  Michael Hope  <michaelh AT juju.net.nz>
14862
14863         * src/pic/ralloc.c (debugLogRegType): Removed some old types to get it to compile.
14864
14865         * src/z80/gen.c (shiftR2Left2Result): Improved the case when v = v >> n for small values of n to use less code space and time.
14866         (genrshTwo): Fixed v = v >> n where v is a negative int and n is > 8: bug 460010.
14867
14868         * src/z80/peeph.def: Added a rule to optimise shift then compare.
14869
14870         * support/regression/tests/bug-460000.c (testShiftByParam): Added test case.
14871
14872         * support/regression/tests/bug-460010.c: Added test case.
14873
14874         * support/regression/Makefile (test-host): Removed a silly 'clean' target when testing against gcc.
14875
14876 2001-09-09  Bernhard Held <bernhard AT bernhardheld.de>
14877
14878         * support/regression/Makefile: inter-port-clean adjusted for mcs51
14879
14880         * support/regression/testfwk.c: removed workaround for bug #436344
14881
14882         * support/regression/tests/bp.c: use less memory with mcs51
14883
14884         * support/regression/tests/bug-441448.c: use less memory
14885
14886         * support/regression/tests/ports/mcs51/spec.mk: cleanup, use --stack-after-data
14887
14888         * support/regression/collate-results.py: typo
14889
14890 2001-09-08  Michael Hope  <michaelh AT juju.net.nz>
14891
14892         * support/regression/tests/fetchoverlap.c: Added new test case.
14893
14894         * support/regression/tests/bp.c: Added new test case.
14895
14896         * support/regression/tests/bug-448984.c: Added new test case.
14897
14898         * support/regression/tests/pow2shifts.c: Added new test case.
14899
14900         * src/z80/gen.c: Turned off the noise it normally generates for the release.
14901         (genlshTwo): Fixed right shift for count > 8.
14902
14903         * src/z80/ralloc.c: Disabled most of the ACC packing rules as they weren't getting hit and weren't at all safe.
14904
14905 2001-09-08    <johan AT FRIJA>
14906
14907         * src/SDCCicode.c (geniCodeCall): a CPOINTER can be used as a function
14908
14909 2001-09-07    <johan AT FRIJA>
14910
14911         * src/SDCCicode.c (newiCodeCondition): fixed bug #456235 (1.77)
14912
14913         * src/SDCCglue.c (emitRegularMap): only delete a symbol when it is a symbol
14914
14915 2001-09-06    <johan AT FRIJA>
14916
14917         * src/SDCC.y: this could be a fix for bug #458744 (1.37)
14918         * bernhard noted me at this: "() equals to (void)" (1.38)
14919
14920 2001-09-05    <johan AT FRIJA>
14921
14922         * src/SDCCglue.c (emitRegularMap): a fix for bug #458099/2
14923
14924 2001-09-04    <johan AT FRIJA>
14925
14926         * src/SDCCsymt.c (checkSClass): a fix for bug #458099/1
14927
14928
14929 2001-09-04  Paul Stoffregen  <paul AT pjrc.com>
14930
14931         * pragma noinduction broke memcpy on mcs51 large model.  Moved it inside z80 optimization
14932
14933 2001-09-03  Michael Hope  <michaelh AT juju.net.nz>
14934
14935         * link/z80/aslink.h: Fixed path for PATH_MAX
14936
14937 2001-09-02  Michael Hope  <michaelh AT juju.net.nz>
14938
14939         * src/z80/gen.c (fetchLitPair): Changed so that it properly caches direct space references.
14940
14941         * support/regression/tests/addsub.c: Added cases to cover all the +, - combinations.
14942
14943         * support/regression/tests/uminus.c: Added a test for the unary minus operator.
14944
14945         * 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.
14946
14947 2001-09-01  Michael Hope  <michaelh AT juju.net.nz>
14948
14949         * src/z80/gen.c: Fixed up generator to pass the regresion tests, specifically fixing loads for longs, genCmp, and turned on the map file.
14950         (genCmp): Fixed up genCmp for the GB with longs.
14951
14952         * device/lib/gbz80/Makefile: Fixed up all the libraries to pass the regression tests.
14953
14954         * support/regression/ports/host/spec.mk: Updated to compile with the new type specifiers.
14955
14956         * device/lib/Makefile.in (Z80SOURCES): Removed old _mululong, _mulslong, and unneeded _mulint.
14957
14958         * device/lib/_mullong.c (_mulslong): Changed to actually return a value :)
14959
14960 2001-08-30  Paul Stoffregen  <paul AT pjrc.com>
14961
14962         * added peepholes 223 to 231 to mcs51 port.  These improve code when using large model.
14963
14964 2001-08-30  Michael Hope  <michaelh AT juju.net.nz>
14965
14966         * 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.
14967
14968         * src/z80/gen.c (genPlus): Changed bad long add for gb to a fall through.
14969
14970 2001-08-29  Michael Hope  <michaelh AT juju.net.nz>
14971
14972         * link/z80/aslink.h: Fixed long file name support.  Is now based off PATH_MAX instead of a constant.
14973
14974         * src/z80/gen.c: Fixed add and sub for the case where left or right are in static space.
14975
14976 2001-08-30 Bernhard Held   <bernhard AT bernhardheld.de>
14977
14978   * sim/ucsim/configure:    little improvement of Cygwin-detection
14979   * sim/ucsim/configure.in: little improvement of Cygwin-detection
14980   * sim/ucsim/cmd.src/newcmdcl.h: include <sys/types.h> to define fd_set automated build
14981   * support/regression/tests/bug-221100.c: small changes for mcs51
14982   * support/regression/tests/bug-221168.c: small changes for mcs51
14983   * support/regression/tests/bug-227710.c: small changes for mcs51
14984   * support/regression/tests/staticinit.c: small changes for mcs51
14985   * as/mcs51/aslink.h: accept everything as symbol name in rel-files, bug fix ID 452601
14986   * as/mcs51/lklex.c:  accept everything as symbol name in rel-files, bug fix ID 452601
14987   * as/mcs51/lksym.c:  accept everything as symbol name in rel-files, bug fix ID 452601
14988
14989 $Revision$